Beispiel #1
0
        public List <T_OA_HOUSEINFO> GetHireAppHouseListPaging(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, LoginUserInfo loginUserInfo)
        {
            //if (checkState != ((int)CheckStates.WaittingApproval).ToString())
            //{
            //    IQueryable<T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, null, checkState, loginUserInfo.userID);
            //    return ent.Count() > 0 ? ent.ToList() : null;
            //}
            //else
            //{
            //    FLOW_FLOWRECORDDETAIL_T[] flowList = workFlowWS.GetFlowInfo("", "", "0", "housingHireApp", loginUserInfo.companyID, loginUserInfo.userID);
            //    if (flowList == null)
            //    {
            //        return null;
            //    }
            //    List<V_FlowAPP> flowAppList = new List<V_FlowAPP>();
            //    for (int i = 0; i < flowList.Length; i++)
            //    {

            //        V_FlowAPP App = new V_FlowAPP();
            //        App.Guid = flowList[i].GUID;
            //        App.FormID = flowList[i].FormID;
            //        App.EditUserID = flowList[i].EditUserID;
            //        App.EditUserName = flowList[i].EditUserName;
            //        flowAppList.Add(App);
            //    }
            //    checkState = ((int)CheckStates.Approving).ToString();
            //    IQueryable<T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, flowAppList, checkState, loginUserInfo.userID);
            //    return ent.Count() > 0 ? ent.ToList() : null;
            //}
            using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
            {
                IQueryable <T_OA_HOUSEINFO> ent = houseHireAppBll.GetHireAppHouseInfoQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, loginUserInfo.userID);
                return(ent != null?ent.ToList() : null);
            }
        }
Beispiel #2
0
 public List <T_OA_HIREAPP> GetHireAppListPaging(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, string checkState, LoginUserInfo loginUserInfo)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         if (checkState != ((int)CheckStates.WaittingApproval).ToString())
         {
             IQueryable <T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, null, checkState, loginUserInfo.userID);
             return(ent.Count() > 0 ? ent.ToList() : null);
         }
         else
         {
             FLOW_FLOWRECORDDETAIL_T[] flowList = workFlowWS.GetFlowInfo("", "", "", "0", "houseHireApp", loginUserInfo.companyID, loginUserInfo.userID);
             if (flowList == null)
             {
                 return(null);
             }
             List <V_FlowAPP> flowAppList = new List <V_FlowAPP>();
             for (int i = 0; i < flowList.Length; i++)
             {
                 V_FlowAPP App = new V_FlowAPP();
                 App.Guid         = flowList[i].FLOWRECORDDETAILID;
                 App.FormID       = flowList[i].FLOW_FLOWRECORDMASTER_T.FORMID;
                 App.EditUserID   = flowList[i].EDITUSERID;
                 App.EditUserName = flowList[i].EDITUSERNAME;
                 flowAppList.Add(App);
             }
             checkState = ((int)CheckStates.Approving).ToString();
             IQueryable <T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, flowAppList, checkState, loginUserInfo.userID);
             return(ent.Count() > 0 ? ent.ToList() : null);
         }
     }
 }
Beispiel #3
0
 public List <V_HouseHireList> GetHireAppByHouseListID(string ListID)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable <V_HouseHireList> ent = houseHireAppBll.GetHireAppInfoByHouseListId(ListID);
         return(ent.Count() > 0 ? ent.ToList() : null);
     }
 }
Beispiel #4
0
 public List <T_OA_HIREAPP> GetHireAppByID(string hireAppID)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable <T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppById(hireAppID);
         return(ent.Count() > 0 ? ent.ToList() : null);
     }
 }
Beispiel #5
0
 //获取发布的房源信息
 public List <V_HouseHireList> GetMemberHireHouseAppListPaging(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, LoginUserInfo loginUserInfo)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable <V_HouseHireList> ent = houseHireAppBll.GetHireAppHouseInfoListQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, loginUserInfo.userID);
         return(ent != null?ent.ToList() : null);
     }
 }
Beispiel #6
0
 public string DeleteHireApp(string[] hireAppID)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         string returnStr = "";
         if (!houseHireAppBll.DeleteHireApp(hireAppID))
         {
             returnStr = "删除数据失败";
         }
         return(returnStr);
     }
 }
Beispiel #7
0
 public string UpdateHireApp(T_OA_HIREAPP hireAppObj)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         string returnStr = "";
         if (!houseHireAppBll.UpdateHireApp(hireAppObj))
         {
             returnStr = "修改数据失败";
         }
         return(returnStr);
     }
 }
Beispiel #8
0
        public string AddHireApp(T_OA_HIREAPP hireAppObj)
        {
            using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
            {
                string returnStr = "";

                if (!houseHireAppBll.IsHired(hireAppObj.T_OA_HOUSELIST, hireAppObj.OWNERID))
                {
                    returnStr = houseHireAppBll.AddHireApp(hireAppObj);
                }
                else
                {
                    returnStr = "HOUSEISOKNOTHIRE";
                }
                return(returnStr);
            }
        }
Beispiel #9
0
 public List<V_HouseHireApp> GetHireAppListPagingByMember(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, string checkState, LoginUserInfo loginUserInfo)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable<V_HouseHireApp> ent = houseHireAppBll.GetHireAppQueryWithPagingByHouseInfoOrList(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, null, checkState, loginUserInfo.userID);
         return ent!=null ? ent.ToList() : null;
     }
     
 }
Beispiel #10
0
 //获取发布的房源信息
 public List<V_HouseHireList> GetMemberHireHouseAppListPaging(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, LoginUserInfo loginUserInfo)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable<V_HouseHireList> ent = houseHireAppBll.GetHireAppHouseInfoListQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, loginUserInfo.userID);
         return ent != null ? ent.ToList() : null;
     }
 }
Beispiel #11
0
        public List<T_OA_HOUSEINFO> GetHireAppHouseListPaging(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, LoginUserInfo loginUserInfo)
        {          
            //if (checkState != ((int)CheckStates.WaittingApproval).ToString())
            //{
            //    IQueryable<T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, null, checkState, loginUserInfo.userID);
            //    return ent.Count() > 0 ? ent.ToList() : null;
            //}
            //else
            //{
            //    FLOW_FLOWRECORDDETAIL_T[] flowList = workFlowWS.GetFlowInfo("", "", "0", "housingHireApp", loginUserInfo.companyID, loginUserInfo.userID);
            //    if (flowList == null)
            //    {
            //        return null;
            //    }
            //    List<V_FlowAPP> flowAppList = new List<V_FlowAPP>();
            //    for (int i = 0; i < flowList.Length; i++)
            //    {

            //        V_FlowAPP App = new V_FlowAPP();
            //        App.Guid = flowList[i].GUID;
            //        App.FormID = flowList[i].FormID;
            //        App.EditUserID = flowList[i].EditUserID;
            //        App.EditUserName = flowList[i].EditUserName;
            //        flowAppList.Add(App);
            //    }
            //    checkState = ((int)CheckStates.Approving).ToString();
            //    IQueryable<T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, flowAppList, checkState, loginUserInfo.userID);
            //    return ent.Count() > 0 ? ent.ToList() : null;
            //}
            using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
            {
                IQueryable<T_OA_HOUSEINFO> ent = houseHireAppBll.GetHireAppHouseInfoQueryWithPaging(pageIndex, pageSize, sort, filterString, paras, ref pageCount, loginUserInfo.userID);
                return ent != null ? ent.ToList() : null;
            }
        }
Beispiel #12
0
 public string DeleteHireApp(string[] hireAppID)
 {
     
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         string returnStr = "";
         if (!houseHireAppBll.DeleteHireApp(hireAppID))
         {
             returnStr = "删除数据失败";
         }
         return returnStr;
     }
 }
Beispiel #13
0
 public string UpdateHireApp(T_OA_HIREAPP hireAppObj)
 {
     
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         string returnStr = "";
         if (!houseHireAppBll.UpdateHireApp(hireAppObj))
         {
             returnStr = "修改数据失败";
         }
         return returnStr;
     }
 }
Beispiel #14
0
        public string AddHireApp(T_OA_HIREAPP hireAppObj)
        {
            using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
            {
                string returnStr = "";

                if (!houseHireAppBll.IsHired(hireAppObj.T_OA_HOUSELIST, hireAppObj.OWNERID))
                {
                    returnStr = houseHireAppBll.AddHireApp(hireAppObj);

                }
                else
                {
                    returnStr = "HOUSEISOKNOTHIRE";
                }
                return returnStr;
            }
        }
Beispiel #15
0
 public List<V_HouseHireList> GetHireAppByHouseListID(string ListID)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable<V_HouseHireList> ent = houseHireAppBll.GetHireAppInfoByHouseListId(ListID);
         return ent.Count() > 0 ? ent.ToList() : null;
     }
 }
Beispiel #16
0
 public List<T_OA_HIREAPP> GetHireAppByID(string hireAppID)
 {
     using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
     {
         IQueryable<T_OA_HIREAPP> ent = houseHireAppBll.GetHireAppById(hireAppID);
         return ent.Count() > 0 ? ent.ToList() : null;
     }
 }
Beispiel #17
0
        /// <summary>
        /// 根据传回的XML,添加租房申请
        /// </summary>
        /// <param name="xele"></param>
        private static string HireappAdd(IEnumerable<XElement> eGFunc)
        {
            try
            {
                if (eGFunc.Count() == 0)
                {
                    return "";
                }
                string strEmployeeID = string.Empty;
                string strOwnerID = string.Empty;
                string strOwnerPostID = string.Empty;
                string strOwnerDepartmentID = string.Empty;
                string strOwnerCompanyID = string.Empty;

                foreach (var q in eGFunc)
                {
                    string strName = q.Attribute("Name").Value;
                    switch (strName)
                    {
                        case "CREATEUSERID":
                            strEmployeeID = q.Attribute("Value").Value;
                            break;
                        case "OWNERID":
                            strOwnerID = q.Attribute("Value").Value;
                            break;
                        case "OWNERPOSTID":
                            strOwnerPostID = q.Attribute("Value").Value;
                            break;
                        case "OWNERDEPARTMENTID":
                            strOwnerDepartmentID = q.Attribute("Value").Value;
                            break;
                        case "OWNERCOMPANYID":
                            strOwnerCompanyID = q.Attribute("Value").Value;
                            break;
                    }
                }

                string employeeid = strEmployeeID.Replace("{", "").Replace("}", "");

                T_OA_HIREAPP entity = new T_OA_HIREAPP();
                HouseInfoManagerBll houseBll = new HouseInfoManagerBll();
                int pageCount = 1;
                List<T_OA_HOUSEINFO> ent = houseBll.QueryWithPaging(1, 1, string.Empty, string.Empty, null, ref  pageCount, strEmployeeID, "T_OA_HOUSEINFO").ToList();
                List<T_OA_HOUSELIST> hlist = ent[0].T_OA_HOUSELIST.ToList();
                entity.T_OA_HOUSELIST = hlist[0];

                entity.HIREAPPID = Guid.NewGuid().ToString();
                entity.CREATEDATE = DateTime.Now;
                entity.OWNERID = strOwnerID;
                entity.OWNERPOSTID = strOwnerPostID;
                entity.OWNERDEPARTMENTID = strOwnerDepartmentID;
                entity.OWNERCOMPANYID = strOwnerCompanyID;
                entity.CREATEUSERID = strOwnerID;
                entity.CREATEPOSTID = strOwnerPostID;
                entity.CREATEDEPARTMENTID = strOwnerDepartmentID;
                entity.CREATECOMPANYID = strOwnerCompanyID;

                List<T_OA_DISTRIBUTEUSER> distributeLists = new List<T_OA_DISTRIBUTEUSER>();

                HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll();
                if (!houseHireAppBll.IsHired(entity.T_OA_HOUSELIST, entity.OWNERID))
                {
                    houseHireAppBll.AddHireApp(entity);
                    return entity.HIREAPPID;
                }
                else
                {
                    string err = "Error";
                    return err;
                }
            }
            catch (Exception e)
            {
                string abc = "<OA>Message=[" + e.Message + "]" + "<OA>Source=[" + e.Source + "]<OA>StackTrace=[" + e.StackTrace + "]<OA>TargetSite=[" + e.TargetSite + "]";
                Tracer.Debug(abc);
                return abc;
            }
        }
Beispiel #18
0
        public List<V_HouseHireApp> GetHireAppListPagingByHouseInfoOrList(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, string checkState, LoginUserInfo loginUserInfo)
        {
            using (HouseHireAppManagementBll houseHireAppBll = new HouseHireAppManagementBll())
            {
                if (checkState != ((int)CheckStates.WaittingApproval).ToString())
                {
                    IQueryable<V_HouseHireApp> ent;
                    if (checkState != ((int)CheckStates.ALL).ToString())
                    {
                        ent = houseHireAppBll.GetHireAppQueryWithPagingByHouseInfoOrList(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, null, checkState, loginUserInfo.userID);
                    }
                    else
                    {
                        ent = houseHireAppBll.GetHireAppQueryWithPagingByHouseInfoOrList(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, null, "", loginUserInfo.userID);
                    }
                    return ent.Count() > 0 ? ent.ToList() : null;
                }
                else
                {
                    FLOW_FLOWRECORDDETAIL_T[] flowList = workFlowWS.GetFlowInfo("", "", "", "0", "houseHireApp", loginUserInfo.companyID, loginUserInfo.userID);
                    if (flowList == null)
                    {
                        return null;
                    }
                    List<V_FlowAPP> flowAppList = new List<V_FlowAPP>();
                    for (int i = 0; i < flowList.Length; i++)
                    {

                        V_FlowAPP App = new V_FlowAPP();
                        App.Guid = flowList[i].FLOWRECORDDETAILID;
                        App.FormID = flowList[i].FLOW_FLOWRECORDMASTER_T.FORMID;
                        App.EditUserID = flowList[i].EDITUSERID;
                        App.EditUserName = flowList[i].EDITUSERNAME;
                        flowAppList.Add(App);
                    }
                    checkState = ((int)CheckStates.Approving).ToString();
                    IQueryable<V_HouseHireApp> ent = houseHireAppBll.GetHireAppQueryWithPagingByHouseInfoOrList(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, flowAppList, checkState, loginUserInfo.userID);
                    return ent.Count() > 0 ? ent.ToList() : null;
                }
            }
        }