public static void WMRemoveFieldFromUserListAtEditTime(string ID) { iProductCategoryMasterClient Message = new iProductCategoryMasterClient(); CustomProfile profile = CustomProfile.GetProfile(); try { Message.DeleteFieldFromListWhenEdit(Convert.ToInt64(ID), profile.DBConnection._constr); } catch { } finally { } }
public void BindObject() { iProductCategoryMasterClient ObjectClient = new iProductCategoryMasterClient(); CustomProfile profile = CustomProfile.GetProfile(); ddlObject.DataSource = ObjectClient.GetObject(profile.DBConnection._constr); ddlObject.DataBind(); ListItem lst = new ListItem(); lst.Text = "--Select--"; lst.Value = "0"; ddlObject.Items.Insert(0, lst); }
protected void AddBtn_Click(object sender, System.EventArgs e) { string Title, Destination, Type, Purpose, Object1; long Sequence, Field1; Title = txtTitle.Text; Destination = ddlDestination.SelectedItem.Text; Type = ddlType.SelectedItem.Text; Purpose = txtPurpose.Text; Object1 = ddlObject.SelectedItem.Text; Field1 = Convert.ToInt64(hdnSelectedField.Value); Sequence = Convert.ToInt64(txtSequence.Text); iProductCategoryMasterClient Message = new iProductCategoryMasterClient(); CustomProfile profile = CustomProfile.GetProfile(); if (hdnState.Value == "Add") { try { //Message.DeleteMessageTemptable(profile.DBConnection._constr); Message.InsertMessageIntoTemptable(Title, Destination, Type, Purpose, Object1, Field1, Sequence, profile.DBConnection._constr); GetFieldList(); txtSequence.Text = ""; ddlObject.SelectedIndex = -1; ddlField.SelectedIndex = -1; } catch { } finally { } } if (hdnState.Value == "Edit") { long MsgHeadID = Convert.ToInt64(hdnMessageID.Value); long Sequence1 = Convert.ToInt64(txtSequence.Text); long Field = Convert.ToInt64(hdnSelectedField.Value); long CreateBy = profile.Personal.UserID; try { Message.InsertMessageDetails(MsgHeadID, Field, Sequence1, CreateBy, profile.DBConnection._constr); GetFieldList(); } catch { } finally { } } }
public static List <mInterfaceMap> PMGetFieldList(string Selectedbject) { iProductCategoryMasterClient ObjectClient = new iProductCategoryMasterClient(); List <mInterfaceMap> FieldList = new List <mInterfaceMap>(); try { CustomProfile profile = CustomProfile.GetProfile(); FieldList = ObjectClient.FieldList(Selectedbject, profile.DBConnection._constr).ToList(); } catch (System.Exception ex) { Login.Profile.ErrorHandling(ex, "User Creation", "PMfillDesignation"); } finally { } return(FieldList); }
protected void GetFieldList() { iProductCategoryMasterClient objService = new iProductCategoryMasterClient(); CustomProfile profile = CustomProfile.GetProfile(); GVFields.DataSource = null; GVFields.DataBind(); DataSet dsFieldList = new DataSet(); if (hdnState.Value == "Add") { dsFieldList = objService.GetFieldDetails(profile.DBConnection._constr); } if (hdnState.Value == "Edit") { dsFieldList = objService.GetFieldDetailsFromMessageTable(Convert.ToInt64(hdnMessageID.Value), profile.DBConnection._constr); } GVFields.DataSource = dsFieldList; GVFields.DataBind(); }
protected void pageAddNew(Object sender, BrilliantWMS.ToolbarService.iUCToolbarClient e) { iProductCategoryMasterClient Message = new iProductCategoryMasterClient(); CustomProfile profile = CustomProfile.GetProfile(); tblInterfaceDefLst.Visible = false; tbTemplateDetail.Visible = true; tabContainerReqTemplate.ActiveTabIndex = 1; hdnState.Value = "Add"; if (hdnState.Value == "Add") { Message.DeleteMessageTemptable(profile.DBConnection._constr); } clear(); //GetProductSpecificationDetailByProductID(); //GetProductTaxDetailByProductID(); //GetProductImagesByProductID(); //GVRateHistory(); //FillInventoryGrid(); //setActiveTab(1); //changePrice1.Attributes.Add("style", "visibility:hidden"); }
protected void pageSave(Object sender, BrilliantWMS.ToolbarService.iUCToolbarClient e) { iProductCategoryMasterClient Message = new iProductCategoryMasterClient(); CustomProfile profile = CustomProfile.GetProfile(); if (hdnState.Value == "Add") { DataSet ds = new DataSet(); long HeaderId = 0; try { ds = Message.GetMessageTempData(profile.DBConnection._constr); for (int i = 0; i < ds.Tables[0].Rows.Count; i++) { if (i < 1) { string Destination = ds.Tables[i].Rows[i]["Destination"].ToString(); string ActionType = ds.Tables[i].Rows[i]["ActionType"].ToString(); string TableName = ds.Tables[i].Rows[i]["TableName"].ToString(); string description = ds.Tables[i].Rows[i]["description"].ToString(); string Remark = ds.Tables[i].Rows[i]["Remark"].ToString(); string sequence = ds.Tables[i].Rows[i]["sequence"].ToString(); string FieldID = ds.Tables[i].Rows[i]["FieldID"].ToString(); long CreatedBy = profile.Personal.UserID; Message.InsertMessageHeader(Destination, ActionType, TableName, description, CreatedBy, Remark, profile.DBConnection._constr); DataSet ds1 = new DataSet(); ds1 = Message.GetMessHeaderID(profile.DBConnection._constr); HeaderId = Convert.ToInt64(ds1.Tables[0].Rows[0][0].ToString()); Message.InsrtIntoMessageHeader(HeaderId, Convert.ToInt64(sequence), Convert.ToInt64(FieldID), CreatedBy, profile.DBConnection._constr); } else { long Sequence = Convert.ToInt64(ds.Tables[0].Rows[i]["sequence"].ToString()); long FieldID = Convert.ToInt64(ds.Tables[0].Rows[i]["FieldID"].ToString()); long CreatedBy = profile.Personal.UserID; Message.InsrtIntoMessageHeader(HeaderId, Sequence, FieldID, CreatedBy, profile.DBConnection._constr); } } Message.DeleteMessageTemptable(profile.DBConnection._constr); WebMsgBox.MsgBox.Show("Record saved successfully"); } catch { } finally { } } else if (hdnState.Value == "Edit") { long MessageID = Convert.ToInt64(hdnMessageID.Value); long ModifyBy = profile.Personal.UserID; string Destination = ddlDestination.SelectedItem.Text; string ActionType = ddlType.SelectedItem.Text; string TableName = ddlObject.SelectedItem.Text; string description = txtTitle.Text; string Remark = txtPurpose.Text; try { Message.UpdateMessageHeader(MessageID, Destination, ActionType, TableName, description, ModifyBy, Remark, profile.DBConnection._constr); WebMsgBox.MsgBox.Show("Record Update successfully"); clear(); } catch { } finally { } } }