当前位置: 首页>>代码示例>>C#>>正文


C# Org_StaffBLL.GetFillProcessDetail方法代码示例

本文整理汇总了C#中Org_StaffBLL.GetFillProcessDetail方法的典型用法代码示例。如果您正苦于以下问题:C# Org_StaffBLL.GetFillProcessDetail方法的具体用法?C# Org_StaffBLL.GetFillProcessDetail怎么用?C# Org_StaffBLL.GetFillProcessDetail使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Org_StaffBLL的用法示例。


在下文中一共展示了Org_StaffBLL.GetFillProcessDetail方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Bind

 private void Bind()
 {
     int StaffID = int.Parse(ViewState["StaffID"].ToString());
     if (StaffID <= 0)
         StaffID = int.Parse(Session["UserID"].ToString());
     Org_StaffBLL _staff = new Org_StaffBLL(StaffID);
     switch (ViewState["Type"].ToString())
     {
         case "4":
             p_headr.InnerText = "已录进货的零售店数(成品)-未完成";
             gv_Detail.DataSource = _staff.GetFillProcessDetail(4);
             break;
         case "5":
             p_headr.InnerText = "已录销量的零售店数(成品)-未完成";
             gv_Detail.DataSource = _staff.GetFillProcessDetail(5);
             break;
         case "2":
             p_headr.InnerText = "返利费用申请门店数-未完成";
             gv_Detail.DataSource = _staff.GetFillProcessDetail(2);
             break;
         case "3":
             p_headr.InnerText = "导购工资申请导购数-未完成";
             gv_Detail.DataSource = _staff.GetFillProcessDetail(3);
             break;
         case "1":
         default:
             p_headr.InnerText = "陈列费用申请门店数-未完成";
             gv_Detail.DataSource = _staff.GetFillProcessDetail(1);
             break;
     }
     gv_Detail.DataBind();
     gv_Detail.BindGrid();
 }
开发者ID:fuhongliang,项目名称:GraduateProject,代码行数:33,代码来源:PopShowProcessDetail.aspx.cs

示例2: BindGrid

    private void BindGrid()
    {
        int month = int.Parse(ddl_Month.SelectedValue);
        int organizecity = int.Parse(tr_OrganizeCity.SelectValue);
        int state = int.Parse(ddl_State.SelectedValue);
        int RTChannel = int.Parse(ddl_RTChannel.SelectedValue);
        int RTType = int.Parse(ddl_RTType.SelectedValue);

        string condition = "";

        if (tbx_ApplyCost.Text != "0")
            condition = "TotalApplyCost" + ddl_OP.SelectedValue + tbx_ApplyCost.Text;

        if (txt_FeeRate.Text != "0")
        {
            if (condition != "") condition += " AND ";
            condition += "CONVERT(DECIMAL(10,3),REPLACE(ApplyCostRate,'%',''))" + ddl_FeeRateOP.SelectedValue + txt_FeeRate.Text;
        }
        DataTable dtSummary = FNA_FeeApplyBLL.GetRTChannelFLFee
            (month, organizecity, state, int.Parse(Session["UserID"].ToString()), RTChannel, condition, RTType);
        if (dtSummary.Rows.Count == 0)
        {
            gv_List.DataBind();
            return;
        }

        #region 求行小计
        MatrixTable.TableAddRowSubTotal(dtSummary, new string[] { "区域信息→大区", "区域信息→营业部", "区域信息→办事处", "零售店基本情况→费用代垫客户" },
            new string[] { "卖场销售额→上月", "卖场销售额→本月", "费用情况→总费用", "费用情况→我司费用", "费用情况→经销商费用" }, true);
        //计算小计行费率
        foreach (DataRow dr in dtSummary.Rows)
        {
            if (dr[0].ToString() == "总计" ||
                dr[1].ToString() == "小计" ||
                dr[2].ToString() == "小计" ||
                dr[3].ToString() == "小计" ||
                dr[4].ToString() == "小计")
            {
                dr["费用情况→我司费率"] = (decimal)dr["卖场销售额→本月"] == 0 ? "100%" : ((decimal)dr["费用情况→我司费用"] / (decimal)dr["卖场销售额→本月"]).ToString("0.#%");
                dr["费用情况→经销商费率"] = (decimal)dr["卖场销售额→本月"] == 0 ? "100%" : ((decimal)dr["费用情况→经销商费用"] / (decimal)dr["卖场销售额→本月"]).ToString("0.#%");
            }
        }
        #endregion

        gv_List.DataSource = dtSummary;
        gv_List.DataBind();

        if (dtSummary.Columns.Count >= 24)
            gv_List.Width = new Unit(dtSummary.Columns.Count * 60);
        else
            gv_List.Width = new Unit(100, UnitType.Percentage);

        MatrixTable.GridViewMatric(gv_List);

        for (int i = 0; i < 4; i++)
        {
            MatrixTable.GridViewMergSampeValueRow(gv_List, i);
        }

        if (Right_Assign_BLL.GetAccessRight(Session["UserName"].ToString(), 1510, "BatApproveFee"))
        {
            bt_Approve.Visible = (ddl_State.SelectedValue == "1");
            bt_UnApprove.Visible = (ddl_State.SelectedValue == "1");
            bt_ExcludeApplyDetail.Visible = (ddl_State.SelectedValue == "1");

            if (state == 1 && condition == "" && RTChannel == 0 && RTType == 0)
            {
                bt_Approve.Enabled = true;
                bt_UnApprove.Enabled = true;

                #region 判断能否审批

                if (ddl_State.SelectedValue == "1")
                {
                    Org_StaffBLL _staff = new Org_StaffBLL((int)Session["UserID"]);
                    DataTable dt = _staff.GetLowerPositionTask(2, int.Parse(tr_OrganizeCity.SelectValue), month);

                    if (AC_AccountMonthBLL.GetCurrentMonth() - 1 <= int.Parse(ddl_Month.SelectedValue))
                    {
                        string[] allowdays1 = Addr_OrganizeCityParamBLL.GetValueByType(1, 5).Replace(" ", "").Split(new char[] { ',', ',', ';', ';' });
                        string[] allowdays2 = Addr_OrganizeCityParamBLL.GetValueByType(1, 6).Replace(" ", "").Split(new char[] { ',', ',', ';', ';' });
                        string date = DateTime.Now.Day.ToString();
                        if (allowdays1.Contains(date))
                            bt_Approve.Enabled = false;
                        else if (allowdays2.Contains(date))
                        {

                            DataTable dt2 = new DataTable();
                            if (_staff.Model.Position == 210)
                                dt2 = _staff.GetFillProcessDetail(2);
                            if (dt2.Rows.Count > 0)
                            {
                                bt_Approve.Enabled = false;
                            }
                        }
                        else
                        {
                            bt_UnApprove.Enabled = false;
                        }
                    }
//.........这里部分代码省略.........
开发者ID:fuhongliang,项目名称:GraduateProject,代码行数:101,代码来源:GetRTChannelFLFee.aspx.cs

示例3: BindGrid


//.........这里部分代码省略.........
            condition += @"FNA_FeeApply.FeeType=7 AND EXISTS(SELECT 1 FROM MCS_FNA.dbo.FNA_FeeApplyDetail WHERE FNA_FeeApplyDetail.AccountTitle=82
                AND FNA_FeeApplyDetail.ApplyID=FNA_FeeApply.ID AND BeginMonth=" + ddl_Month.SelectedValue + ")";
            if (tr_OrganizeCity.SelectValue != "1")
            {
                Addr_OrganizeCityBLL orgcity = new Addr_OrganizeCityBLL(organizecity);
                string orgcitys = orgcity.GetAllChildNodeIDs();
                if (orgcitys != "") orgcitys += ",";
                orgcitys += organizecity;

                condition += " AND FNA_FeeApply.OrganizeCity IN (" + orgcitys + ")";
            }
            if (state == 0)
                condition += " AND FNA_FeeApply.State IN (2,3) ";
            else if (state == 1)
                condition +=
                @" AND	FNA_FeeApply.State = 2 AND
            EXISTS (
                SELECT EWF_Task_Job.Task
                FROM  MCS_EWF.dbo.EWF_Task_JobDecision INNER JOIN
                    MCS_EWF.dbo.EWF_Task_Job ON EWF_Task_JobDecision.Job = EWF_Task_Job.ID
                     INNER JOIN MCS_EWF.dbo.EWF_Task ON	 EWF_Task_Job.Task= EWF_Task.ID AND EWF_Task.App='4eb9e905-3502-4caf-88d0-aadcfec6e4dd'
                WHERE EWF_Task_JobDecision.RecipientStaff=" + Session["UserID"].ToString() + @" AND
                    EWF_Task_JobDecision.DecisionResult=1 and EWF_Task_Job.Status=3 AND FNA_FeeApply.ApproveTask=EWF_Task_Job.Task)";
            else if (state == 2)
                condition += " AND FNA_FeeApply.State = 3 ";
            else if (state == 3)
            {
                AC_AccountMonth m = new AC_AccountMonthBLL(month).Model;
                condition +=
                @" AND FNA_FeeApply.State IN (2,3) AND EXISTS
            (SELECT EWF_Task_Job.Task FROM  MCS_EWF.dbo.EWF_Task_JobDecision INNER JOIN
            MCS_EWF.dbo.EWF_Task_Job ON EWF_Task_JobDecision.Job = EWF_Task_Job.ID
            INNER JOIN MCS_EWF.dbo.EWF_Task ON=EWF_Task_Job.Task=EWF_Task.ID AND EWF_Task.App='4eb9e905-3502-4caf-88d0-aadcfec6e4dd'
            WHERE EWF_Task_JobDecision.RecipientStaff=" + Session["UserID"].ToString() + @" AND
                EWF_Task_JobDecision.DecisionResult IN(2,5,6) AND FNA_FeeApply.ApproveTask=EWF_Task_Job.Task)";
            }
            #endregion
            gv_DetailList.ConditionString = condition;
            gv_DetailList.BindGrid();

        }

        #region 是否可以批量审批
        if (Right_Assign_BLL.GetAccessRight(Session["UserName"].ToString(), 1510, "BatApproveFee"))
        {
            bt_Approve.Visible = (ddl_State.SelectedValue == "1");
            bt_UnApprove.Visible = (ddl_State.SelectedValue == "1");
            bt_Approve.Enabled = (ddl_State.SelectedValue == "1");
            bt_UnApprove.Enabled = (ddl_State.SelectedValue == "1");

            #region 判断费用申请进度
            if (ddl_State.SelectedValue == "1")
            {
                Org_StaffBLL _staff = new Org_StaffBLL((int)Session["UserID"]);
                DataTable dt = _staff.GetLowerPositionTask(2, int.Parse(tr_OrganizeCity.SelectValue), month);
                if (AC_AccountMonthBLL.GetCurrentMonth() - 1 <= int.Parse(ddl_Month.SelectedValue))
                {

                    string[] allowdays1 = Addr_OrganizeCityParamBLL.GetValueByType(1, 5).Replace(" ", "").Split(new char[] { ',', ',', ';', ';' });
                    string[] allowdays2 = Addr_OrganizeCityParamBLL.GetValueByType(1, 6).Replace(" ", "").Split(new char[] { ',', ',', ';', ';' });
                    string date = DateTime.Now.Day.ToString();
                    if (allowdays1.Contains(date))
                        bt_Approve.Enabled = false;
                    else if (allowdays2.Contains(date))
                    {
                        DataTable dt2 = new DataTable();
                        if (_staff.Model.Position == 210)
                            dt2 = _staff.GetFillProcessDetail(2);
                        if (dt.Rows.Count > 0 || dt2.Rows.Count > 0)
                        {
                            bt_Approve.Enabled = false;
                        }
                    }
                    else
                    {
                        bt_UnApprove.Enabled = false;
                    }

                }
                else
                {
                    bt_UnApprove.Enabled = false;
                }
                if (dt.Rows.Count > 0)
                {
                    ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "message", "<script language='javascript'>var tempid = Math.random() * 10000; \r\n window.showModalDialog('" + Page.ResolveClientUrl("~/SubModule/Pop_ShowLowerPositionTask.aspx") +
                       "?Type=2&StaffID=0&Month=" + ddl_Month.SelectedValue + "&City=" + tr_OrganizeCity.SelectValue + "&tempid='+tempid, window, 'dialogWidth:520px;DialogHeight=600px;status:yes;resizable=no');</script>", false);
                    bt_Approve.Enabled = false;

                }
            }
            #endregion
        }
        else
        {
            bt_Approve.Visible = false;
            bt_UnApprove.Visible = false;
        }
        #endregion
    }
开发者ID:fuhongliang,项目名称:GraduateProject,代码行数:101,代码来源:FLFeeApplySummary.aspx.cs

示例4: BindGrid


//.........这里部分代码省略.........
                        condition +=
                        @" AND PM_Salary.State IN (2,3) AND MCS_SYS.dbo.UF_Spilt(PM_Salary.ExtPropertys,'|',1) IN
                (SELECT EWF_Task_Job.Task FROM  MCS_EWF.dbo.EWF_Task_JobDecision INNER JOIN
                    MCS_EWF.dbo.EWF_Task_Job ON EWF_Task_JobDecision.Job = EWF_Task_Job.ID
                 INNER JOIN MCS_EWF.dbo.EWF_Task ON	 EWF_Task_Job.Task= EWF_Task.ID
                 INNER JOIN MCS_EWF.dbo.EWF_Flow_App ON EWF_Task.App=EWF_Flow_App.ID AND EWF_Flow_App.Code='PM_SalaryApplyFlow'
                WHERE EWF_Task_JobDecision.RecipientStaff=" + Session["UserID"].ToString() + @" AND
                    EWF_Task_JobDecision.DecisionResult IN(2,5,6) AND
                    EWF_Task_JobDecision.DecisionTime BETWEEN DATEADD(month,-1,'" + m.BeginDate.ToString("yyyy-MM-dd") + @"') AND
                        DATEADD(month,3,'" + m.BeginDate.ToString("yyyy-MM-dd") + @"'))";
                    }
                    #endregion

                    gv_ListDetail.ConditionString = condition;
                    gv_ListDetail.BindGrid();
                }
                break;
            case "3":
                {
                    DataTable dtSummary = PM_SalaryBLL.GetDetailByState(month, organizecity, level, state, int.Parse(Session["UserID"].ToString()), int.Parse(ddl_SalaryClassify.SelectedValue), rtchannel);
                    if (dtSummary.Rows.Count == 0)
                    {
                        gv_PromotorSalary.DataBind();
                        return;
                    }
                    if (dtSummary.Columns.Count >= 24)
                        gv_PromotorSalary.Width = new Unit(dtSummary.Columns.Count * 65);
                    else
                        gv_PromotorSalary.Width = new Unit(100, UnitType.Percentage);
                    dtSummary.Columns.Add("所在门店").SetOrdinal(6);
                    if (txt_FeeRate.Text != "0")
                    {
                        dtSummary.DefaultView.RowFilter = "[费率A%]" + ddl_FeeRateOP.SelectedValue + txt_FeeRate.Text;
                    }
                    gv_PromotorSalary.DataSource = dtSummary.DefaultView;
                    gv_PromotorSalary.DataBind();
                    MatrixTable.GridViewMatric(gv_PromotorSalary);
                }
                break;
        }

        #region 是否可以批量审批
        if (state != 1)
        {
            gv_List.Columns[0].ItemStyle.Width = new Unit(1);
            bt_Approved.Visible = false;
            bt_UnApproved.Visible = false;
        }
        else
        {
            bt_Approved.Visible = true;
            bt_UnApproved.Visible = true;
            gv_List.Columns[0].ItemStyle.Width = new Unit(68);
            Org_StaffBLL _staff = new Org_StaffBLL((int)Session["UserID"]);
            DataTable dt = _staff.GetLowerPositionTask(3, int.Parse(tr_OrganizeCity.SelectValue), month);

            if (AC_AccountMonthBLL.GetCurrentMonth() - 1 <= int.Parse(ddl_Month.SelectedValue))
            {
                string[] allowday1 = Addr_OrganizeCityParamBLL.GetValueByType(1, 3).Split(new char[] { ',', ',', ';', ';' });
                string[] allowday2 = Addr_OrganizeCityParamBLL.GetValueByType(1, 4).Split(new char[] { ',', ',', ';', ';' });
                int day = DateTime.Now.Day;
                if (allowday1.Contains(day.ToString()))
                    bt_Approved.Visible = false;
                else if (allowday2.Contains(day.ToString()))
                {
                    #region 判断费用申请进度
                    Org_StaffBLL bll = new Org_StaffBLL((int)Session["UserID"]);
                    DataTable dt2 = new DataTable();
                    if (bll.Model.Position == 210)
                        dt2 = bll.GetFillProcessDetail(3);
                    if (dt.Rows.Count > 0)
                    {
                        bt_Approved.Visible = false;
                    }
                    #endregion
                }
                else
                {
                    bt_UnApproved.Enabled = false;
                    bt_Approved.Enabled = dt.Rows.Count == 0;
                }
            }
            else
            {

                bt_UnApproved.Enabled = false;
                bt_Approved.Enabled = dt.Rows.Count == 0;
            }
            if (dt.Rows.Count > 0)
            {

                bt_Approved.Enabled = false;

                ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "message", "<script language='javascript'>var tempid = Math.random() * 10000; \r\n window.showModalDialog('" + Page.ResolveClientUrl("~/SubModule/Pop_ShowLowerPositionTask.aspx") +
                "?Type=3&StaffID=0&Month=" + ddl_Month.SelectedValue + "&City=" + tr_OrganizeCity.SelectValue + "&tempid='+tempid, window, 'dialogWidth:520px;DialogHeight=600px;status:yes;resizable=no');</script>", false);
            }

        }
        #endregion
    }
开发者ID:fuhongliang,项目名称:GraduateProject,代码行数:101,代码来源:PM_PromotorSummary.aspx.cs


注:本文中的Org_StaffBLL.GetFillProcessDetail方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。