예제 #1
0
 protected void StartProcessButton_Click(object sender, EventArgs e)
 {
     try
     {
         string            incidentId       = IncidentId;
         FaArchiveTranfer  faArchiveTranfer = Master.GetFaArchiveTranfer();
         IList <FaProcess> faProcesses      = Master.GetFaProcess();
         ProcessForm       processForm      = ProcessFormService.GetNewProcessForm(ProcessId, incidentId);
         processForm.FaArchiveTranfers.Add(faArchiveTranfer);
         faArchiveTranfer.FaProcesses.AddRange(faProcesses);
         ProcessFormService.Save(processForm);
         Hashtable taskVariation = new Hashtable();
         if (EDoc2Helper.IsUserInUserGroup(EDoc2Helper.GetCurrentUserId(), WebConfig.ManagerGroup))
         {
             taskVariation.Add("fenzhizouxiang", "是");
         }
         else
         {
             taskVariation.Add("fenzhizouxiang", "否");
         }
         StartFa(ProcessId, incidentId, taskVariation);
     }
     catch (Exception ex)
     {
         Edoc2LogHelper.WriteProcessSubmitExceptionLog(ex);
         Dialog("出现异常,请联系管理员。");
     }
 }
        private string GetOperating(long itemId, int userId)
        {
            string editButtonTmp = "";

            if (EDoc2Helper.IsUserInUserGroup(userId, WebConfig.CaiwuDanganGuanliyuan))
            {
                editButtonTmp =
                    "<a name='GuihuanButton' itemId='{itemId}' class='button02' style='cursor:pointer'>" +
                    "<span class='l'></span>" +
                    "<span class='m'>归还</span>" +
                    "<span class='r'></span></a>" +
                    "<a name='EditButton' itemId='{itemId}' class='button02' style='cursor:pointer'>" +
                    "<span class='l'></span>" +
                    "<span class='m'>编辑</span>" +
                    "<span class='r'></span></a>";
            }
            string editButton = editButtonTmp.Replace("{itemId}", FormatHelper.GetLongString(itemId));

            return(editButton);
        }