Ejemplo n.º 1
0
        /// <summary>
        /// 根据条件查询从呼叫中心系统创建的会员申请状态——统计数
        /// </summary>
        /// <param name="query"></param>
        /// <param name="applyForCount"></param>
        /// <param name="createSuccessfulCount"></param>
        /// <param name="createUnsuccessful"></param>
        /// <param name="rejected"></param>
        public void StatProjectTask_DMSMembersBySourceCC(Entities.QueryProjectTask_DMSMember query, out int applyForCount, out int createSuccessfulCount, out int createUnsuccessful, out int rejected)
        {
            DataTable dt = Dal.ProjectTask_DMSMember.Instance.StatProjectTask_DMSMemberBySourceCC(query);

            if (dt != null && dt.Rows.Count > 0)
            {
                applyForCount         = GetStatCountBySyncStatus(dt, (int)BitAuto.YanFa.Crm2009.Entities.EnumDMSSyncStatus.ApplyFor);
                createSuccessfulCount = GetStatCountBySyncStatus(dt, (int)BitAuto.YanFa.Crm2009.Entities.EnumDMSSyncStatus.CreateSuccessful);
                createUnsuccessful    = GetStatCountBySyncStatus(dt, (int)BitAuto.YanFa.Crm2009.Entities.EnumDMSSyncStatus.CreateUnsuccessful);
                rejected = GetStatCountBySyncStatus(dt, (int)BitAuto.YanFa.Crm2009.Entities.EnumDMSSyncStatus.Rejected);
            }
            else
            {
                applyForCount = createSuccessfulCount = createUnsuccessful = rejected = 0;
            }
        }
        private void StatusCountStat(Entities.QueryProjectTask_DMSMember query, int allCount)
        {
            int applyForCount         = 0;
            int createSuccessfulCount = 0;
            int createUnsuccessful    = 0;
            int rejected = 0;

            BLL.ProjectTask_DMSMember.Instance.StatCC_DMSMembersBySourceCC(query, out applyForCount, out createSuccessfulCount, out createUnsuccessful, out rejected);

            sml.InnerHtml  = "总计:";
            sml.InnerHtml += allCount;
            sml.InnerHtml += "&nbsp;&nbsp;&nbsp;审批中:";
            sml.InnerHtml += applyForCount;
            sml.InnerHtml += "&nbsp;&nbsp;&nbsp;通过:";
            sml.InnerHtml += createSuccessfulCount;
            sml.InnerHtml += "&nbsp;&nbsp;&nbsp;失败:";
            sml.InnerHtml += createUnsuccessful;
            sml.InnerHtml += "&nbsp;&nbsp;&nbsp;打回:";
            sml.InnerHtml += rejected;
        }
        public DataTable StatProjectTask_DMSMemberBySourceCC(Entities.QueryProjectTask_DMSMember query)
        {
            string where = GetProjectTask_DMSMemberBySourceCCWhere(query);

            DataSet ds;

            SqlParameter[] parameters =
            {
                new SqlParameter("@where", SqlDbType.VarChar, 8000)
            };

            parameters[0].Value = where;

            ds = SqlHelper.ExecuteDataset(CONNECTIONSTRINGS, CommandType.StoredProcedure, P_PROJECTTASK_DMSMEMBER_SELECT_STATCREATESOURCEBYCC, parameters);
            if (ds != null && ds.Tables.Count > 0 && ds.Tables[0].Rows.Count > 0)
            {
                return(ds.Tables[0]);
            }
            return(null);
        }
Ejemplo n.º 4
0
 /// <summary>
 /// 根据条件查询从呼叫中心系统创建的会员列表
 /// </summary>
 /// <param name="query">查询实体</param>
 /// <param name="order">排序字段</param>
 /// <param name="index">当前页</param>
 /// <param name="pageSize">页大小</param>
 /// <param name="count">总条数</param>
 /// <returns>返回DataTable</returns>
 public DataTable GetProjectTask_DMSMemberBySourceCC(Entities.QueryProjectTask_DMSMember query, string order, int index, int pageSize, out int count)
 {
     return(Dal.ProjectTask_DMSMember.Instance.GetProjectTask_DMSMemberBySourceCC(query, order, index, pageSize, out count));
 }
        //易湃会员信息查询方法
        private void BindDMSData()
        {
            Entities.QueryProjectTask_DMSMember query = new Entities.QueryProjectTask_DMSMember();

            if (!string.IsNullOrEmpty(RequestMemberName))
            {
                query.MemberName = RequestMemberName;
            }
            if (!string.IsNullOrEmpty(RequestMemberAddr))
            {
                query.MemberAbbr = RequestMemberAddr;
            }
            if (!string.IsNullOrEmpty(RequestCustName))
            {
                query.CustName = RequestCustName;
            }
            if (!string.IsNullOrEmpty(RequestCustID))
            {
                query.CustID = RequestCustID;
            }
            if (!string.IsNullOrEmpty(RequestApplyStartTime))
            {
                query.ApplyStartTime = RequestApplyStartTime;
            }
            if (!string.IsNullOrEmpty(RequestApplyEndTime))
            {
                query.ApplyEndTime = RequestApplyEndTime;
            }
            if (!string.IsNullOrEmpty(RequestApplyUserName))
            {
                query.ApplyUserName = RequestApplyUserName;
            }
            if (!string.IsNullOrEmpty(RequestMemberOptStartTime))
            {
                query.MemberOptStartTime = RequestMemberOptStartTime;
            }
            if (!string.IsNullOrEmpty(RequestMemberOptEndTime))
            {
                query.MemberOptEndTime = RequestMemberOptEndTime;
            }
            if (!string.IsNullOrEmpty(RequestDMSSyncStatus))
            {
                query.DMSSyncStatus = RequestDMSSyncStatus;
            }
            else
            {
                query.DMSSyncStatus = "170001,170002,170003,170008";
            }

            if (BLL.UserDataRigth.Instance.IsExistsByUserID(BLL.Util.GetLoginUserID()))
            {
                query.DMSMemberApplyUserID = Constant.INT_INVALID_VALUE;
            }
            else
            {
                query.DMSMemberApplyUserID = BLL.Util.GetLoginUserID();
            }
            if (!string.IsNullOrEmpty(RequestDMSStatus))
            {
                query.DMSStatus = RequestDMSStatus;
            }

            int       count;
            DataTable dt = BLL.ProjectTask_DMSMember.Instance.GetProjectTask_DMSMemberBySourceCC(query, "ApplyTime Desc", BLL.PageCommon.Instance.PageIndex, PageSize, out RecordCount);

            repeaterList.DataSource = dt;
            repeaterList.DataBind();

            litPagerDown.Text = BLL.PageCommon.Instance.LinkStringByPost(BLL.Util.GetUrl(), GroupLength, RecordCount, PageSize, BLL.PageCommon.Instance.PageIndex, 1);

            //AjaxPager_Member.InitPager(count);
            //selectDown.Value = RequestPageSize.ToString();

            StatusCountStat(query, RecordCount);
        }