Ejemplo n.º 1
0
 public OutApplicationItem FindOutApplicationItemByItemID(int itemid)
 {
     if (_ApplicationItems == null)
     {
         return(null);
     }
     return(OutApplicationItem.FindOutApplicationItemByID(_ApplicationItems, itemid));
 }
 public static bool IsItemFlowContainStatus(OutApplicationItem outApplicationItem, RequestStatus requeststatus)
 {
     foreach (OutApplicationFlow flow in outApplicationItem.OutApplicationFlow)
     {
         if (flow.Operation.Id == requeststatus.Id)
         {
             return(true);
         }
     }
     return(false);
 }
 ///<summary>
 ///</summary>
 public static bool IsAgreed(OutApplicationItem outApplicationItem)
 {
     foreach (OutApplicationFlow flow in outApplicationItem.OutApplicationFlow)
     {
         if (flow.Operation == RequestStatus.ApprovePass)
         {
             return(true);
         }
     }
     return(false);
 }
        /// <summary>
        /// </summary>
        public bool CanChangeAdjust(DiyProcess diyProcess, OutApplicationItem item)
        {
            if (item.Status.Id == RequestStatus.Cancelled.Id || item.Status.Id == RequestStatus.CancelApproving.Id)
            {
                return(false);
            }
            List <OutApplicationFlow> flowList = item.OutApplicationFlow;

            if (flowList != null && diyProcess != null && diyProcess.DiySteps != null && flowList.Count > 0)
            {
                int step = flowList[flowList.Count - 1].Step;
                if (step == -1)
                {
                    return(false);
                }
                int nowStep = step + 1;
                if (diyProcess.DiySteps[nowStep - 1].Status.Contains("Еїан"))
                {
                    return(true);
                }
            }
            return(false);
        }
Ejemplo n.º 5
0
 /// <summary>
 /// 判断等于
 /// </summary>
 /// <param name="obj"></param>
 /// <returns></returns>
 public bool Equals(OutApplicationItem obj)
 {
     return(obj.FromDate == _FromDate &&
            obj.ToDate == _ToDate &&
            obj.CostTime == _CostTime);
 }