Ejemplo n.º 1
0
 void _VM_UpdateVehicleDispatchAndDetailCompleted(object sender, UpdateVehicleDispatchAndDetailCompletedEventArgs e)
 {
     RefreshUI(RefreshedTypes.HideProgressBar);
     if (e.Result > 0)
     {
         if (e.Error != null && e.Error.Message != "")
         {
             Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr(e.Error.Message));
             return;
         }
         Utility.ShowMessageBox("SUBMITAUDITSUCCESSFUL", isSubmitFlow, true);//提交审核成功!
         if (isSubmitFlow)
             saveType = RefreshedTypes.CloseAndReloadData;
         RefreshUI(saveType);
     }
     else
     {
         Utility.ShowMessageBox("AUDITFAILURE", isSubmitFlow, false);//提交审核失败,请重试!
     }
 }
Ejemplo n.º 2
0
 private void UpdateVehicleDispatchAndDetailCompleted(object sender, UpdateVehicleDispatchAndDetailCompletedEventArgs e)
 {
     try
     {
         RefreshUI(RefreshedTypes.HideProgressBar);
         if (e.Error != null && e.Error.Message != "")
         {
             Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr(e.Error.Message));
             return;
         }
         if (e.Result == 1)
         {
             if (e.UserState.ToString() == "Edit")
             {
                 Utility.ShowMessageBox("UPDATE", isSubmitFlow, true);//修改成功!
             }
             if (e.UserState.ToString() == "Audit")
             {
                 Utility.ShowMessageBox("SUCCESSAUDIT", isSubmitFlow, true);//审核成功
                 RefreshUI(RefreshedTypes.CloseAndReloadData);
             }
             else if (e.UserState.ToString() == "Submit")
             {
                 Utility.ShowMessageBox("SUCCESSSUBMITAUDIT", isSubmitFlow, true);//提交审核成功
                 RefreshUI(RefreshedTypes.CloseAndReloadData);
             }
             RefreshUI(RefreshedTypes.All);
             RefreshUI(saveType);
         }
         else
         {
             if (e.UserState.ToString() == "Edit")
             {
                 Utility.ShowMessageBox("UPDATE", isSubmitFlow, false);//修改失败!
             }
             else
             {
                 Utility.ShowMessageBox("AUDITFAILURE", isSubmitFlow, false);//提交审核失败,请重试!
             }
         }
     }
     catch (Exception ex)
     {
         Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), ex.ToString());
         RefreshUI(RefreshedTypes.HideProgressBar);
     }
 }
Ejemplo n.º 3
0
 private void vehicleDispatchManagr_UpdateVehicleDispatchAndDetailCompleted(object sender, UpdateVehicleDispatchAndDetailCompletedEventArgs e)
 {
     try
     {
         RefreshUI(RefreshedTypes.HideProgressBar);
         if (e.Error != null && e.Error.Message != "")
         {
             Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr(e.Error.Message));
             return;
         }
         if (e.Result > 0)
         {
             // by ldx
             // 2011-08-09
             // 将提示信息为提交成功改成审核通过
             //Utility.ShowMessageBox("AUDIT", isSubmitFlow, true);//审核成功
             Utility.ShowCustomMessage(MessageTypes.Message, "成功", "审核通过!");
             RefreshUI(RefreshedTypes.CloseAndReloadData);
         }
         else
         {
             Utility.ShowMessageBox("FAILURETOAPPROVE", isSubmitFlow, false);//审核失败
         }
     }
     catch (Exception ex)
     {
         Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), ex.ToString());
         RefreshUI(RefreshedTypes.HideProgressBar);
     }
 }