Exemple #1
0
 private void LoadData()
 {
     _selSN.StoreId = StoreId;
     SNAction action=new SNAction();
     DataTable dt= action.QueryByStore(StoreId);
     SetListInvoke(dt);
 }
 private void AddSN()
 {
     HandlingResult result = ValidateSNSave();
     if (result.Successed)
     {
         SnModel model = (SnModel)result.Result;
         SNAction action=new SNAction();
         result = action.Add(model);
         if (result.Successed)
         {
             MessageHelper.ShowInformationNotify(this, result.Message);
         }
         else
         {
             MessageHelper.ShowErrorNotify(this, result.Message);
         }
     }
     else
     {
         MessageHelper.ShowErrorNotify(this, result.Message);
     }
 }
Exemple #3
0
 private void Save()
 {
     HandlingResult result = Validate();
     if (result.Successed)
     {
         SNAction action = new SNAction();
         result= action.Update(_selSN);
         if (result.Successed)
         {
             MessageHelper.ShowInformationNotify(this,result.Message);
             LoadData();
         }
         else
         {
             MessageHelper.ShowErrorNotify(this, result.Message);
         }
     }
     else
     {
         MessageHelper.ShowWarningNotify(this,result.Message);
     }
 }