Ejemplo n.º 1
0
 //删除
 protected void btndelinfo_Click(object sender, EventArgs e)
 {
     HyCommon HyCommon = new HyCommon();
     string pageUrl = HyCommon.CombUrlTxt(ls_url, "page={0}&rnd={1}", page.ToString(), System.Guid.NewGuid().ToString());
     string ls_tip = "删除成功!";
     String[] v_uids = this.txtuids.Value.Split(',');
     for (int i = 0; i < v_uids.Length; i++)
     {
         HyFlowLog HyFlowLog = new HyFlowLog();
         HyFlowLog.id = v_uids[i];
         HyFlowLog.Delete();
     }
     //写系统日志
     Response.Write("<script>alert('" + ls_tip + "');window.location='" + pageUrl + "';</script>");
 }
Ejemplo n.º 2
0
 public string CreateCharts()
 {
     HyFlowLog HyFlowLog = new HyFlowLog();
     DataTable dt = new DataTable();
     HyFlowLog.hyuId = this.ddl_user.SelectedValue;
     string test = "";
     dt = HyFlowLog.phoneGetBackAndSubmit(this.operateTime_s.Value, this.operateTime_e.Value, out test);
     //Response.Write(test);
     string strXML = "";
     strXML += "<graph caption='流程审批退回率分析' showNames='1' showValues='1' baseFontSize='12' xAxisName='统计类型' yAxisName='完成数'  decimalPrecision='0' formatNumberScale='0'>";
     if (dt.Rows.Count > 0)
     {
         if (dt.Rows[0]["backTotal"].ToString() == "0")
         {
             strXML += "<set name='文章退回数' value='' color='AFD8F8'  />";
         }
         else
         {
             strXML += "<set name='文章退回数' value='" + Convert.ToDecimal(dt.Rows[0]["backTotal"].ToString()).ToString("F") + "' color='AFD8F8'  />";
         }
         if (dt.Rows[0]["submitTotal"].ToString() == "0")
         {
             strXML += "<set name='文章提交数' value='' color='F6BD0F' />";
         }
         else
         {
             strXML += "<set name='文章提交数' value='" + Convert.ToDecimal(dt.Rows[0]["submitTotal"].ToString()).ToString("F") + "' color='F6BD0F' />";
         }
     }
     else
     {
         strXML += "<set name='文章退回数' value='' color='AFD8F8'  />";
         strXML += "<set name='文章提交数' value='' color='F6BD0F' />";
     }
     strXML += "</graph>";
     return FusionCharts.RenderChartHTML("../FusionCharts/FCF_Column3D.swf", "ChartId", strXML, "myNext", "600", "400", false);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="operationContent">操作内容</param>
 /// <param name="flowID">流程ID</param>
 /// <param name="flowName">流程名</param>
 /// <param name="tacheID">环节ID</param>
 /// <param name="tacheName">环节名</param>
 /// <param name="operationState">操作类型</param>
 private void hyXnxtFlowLogs(string operationContent, string operationState)
 {
     HyFlowLog HyFlowLog = new HyFlowLog();
     HyFlowLog.id = System.Guid.NewGuid().ToString();
     HyFlowLog.hyOperationTime = System.Guid.NewGuid().ToString();
     HyFlowLog.hyuId = this.Session["hyuid"].ToString();
     HyFlowLog.hyuName = this.Session["hyuname"].ToString();
     HyFlowLog.hyuDeptid = this.Session["hydeptid"].ToString();
     HyFlowLog.hyuDeptName = this.Session["hydeptname"].ToString();
     HyFlowLog.hyTableID = this.hy_tableid.Text;
     HyFlowLog.hyTableNmae = this.lbltablename.Text;
     HyFlowLog.hyMudelID = this.hy_mudelid.Text;
     HyFlowLog.hyMudelNmae = hy_mudelname();
     HyFlowLog.hyFlowID = this.hy_flowid.Text;
     HyFlowLog.hyFlowName = this.hy_flowname.Text;
     HyFlowLog.hyTacheID = this.hy_curtacheid.Text;
     HyFlowLog.hyTacheName = this.hy_curtachename.Text;
     HyFlowLog.hyOperationContent = operationContent;
     HyFlowLog.hyOperationId = this.txtdocid.Value;
     HyFlowLog.hyOperationTime = DateTime.Now.ToString();
     HyFlowLog.hyOperationIp = getIp();
     HyFlowLog.hyOperationState = operationState;
     HyFlowLog.hyTacheNextID = this.txtnexttacheid.Value;
     HyFlowLog.hyTacheNextName = this.txtnexttachename.Value;
     string OperationTime = HyFlowLog.getTime(this.txtdocid.Value, this.hy_curtacheid.Text);
     if (OperationTime != "")
     {
         DateTime t1 = new DateTime();
         DateTime t2 = DateTime.Now;
         try
         {
             t1 = Convert.ToDateTime(OperationTime);
         }
         catch
         {
             t1 = DateTime.Now;
         }
         TimeSpan tt1 = new TimeSpan(t1.Ticks);
         TimeSpan tt2 = new TimeSpan(t2.Ticks);
         int diff =Convert.ToInt32(tt2.Subtract(tt1).TotalMinutes.ToString());
         HyFlowLog.hyTimeCount = diff;
     }
     else
     {
         HyFlowLog.hyTimeCount = 0;
     }
     //电脑端登陆
     HyFlowLog.hyLoginType = "0";
     HyFlowLog.Insert();
 }
Ejemplo n.º 4
0
    public string CreateCharts()
    {
        HyFlowLog HyFlowLog = new HyFlowLog();
        DataTable dt = new DataTable();
        //得到选择的部门id
        HyFlowLog.hyuDeptid = this.ddl_dept.SelectedValue;
        string test = "";
        //获取数据集
        dt = HyFlowLog.GetBackAndSubmit(this.operateTime_s.Value, this.operateTime_e.Value, out test);
        //开始画图
        string strXML = "";
        if (this.rd_type.Text == "退回数分析")
        {
            strXML += "<graph caption='流程审批退回数分析' showNames='1' showValues='1' baseFontSize='12' xAxisName='统计类型' yAxisName='完成数'  decimalPrecision='0' formatNumberScale='0'>";
        }
        else if (this.rd_type.Text == "退回率分析")
        {
            strXML += "<graph caption='流程审批退回率分析' showNames='1' showValues='1' baseFontSize='12' xAxisName='统计类型' yAxisName='完成数'  numberSuffix='%25' decimalPrecision='1' formatNumberScale='1'>";
        }
        double intBackCount = 0;
        double intSubmitCount = 0;
        if (dt.Rows.Count > 0)
        {
            intBackCount = Convert.ToDouble(dt.Rows[0]["backTotal"].ToString());
            intSubmitCount = Convert.ToDouble(dt.Rows[0]["submitTotal"].ToString());
            Response.Write((intBackCount / (intBackCount + intSubmitCount)));
            if (this.rd_type.Text == "退回数分析")
            {
                if (intBackCount == 0)
                {
                    strXML += "<set name='流程退回数' value='' color='AFD8F8'  />";
                }
                else
                {
                    strXML += "<set name='流程退回数' value='" + intBackCount + "' color='AFD8F8'  />";
                }
                if (intSubmitCount == 0)
                {
                    strXML += "<set name='流程提交数' value='' color='F6BD0F' />";
                }
                else
                {
                    strXML += "<set name='流程提交数' value='" + intSubmitCount + "' color='F6BD0F' />";
                }
                if ((intSubmitCount + intBackCount) == 0)
                {
                    strXML += "<set name='流程总操作数' value='' color='AFD8F8'  />";
                }
                else
                {
                    strXML += "<set name='流程总操作数' value='" + (intSubmitCount + intBackCount) + "' color='AFD8F8' />";
                }
            }
            else if (this.rd_type.Text == "退回率分析")
            {

                if (intBackCount == 0)
                {
                    strXML += "<set name='流程退回率' value='' color='AFD8F8'  />";
                }
                else
                {
                    strXML += "<set name='流程退回率' value='" + (intBackCount / (intBackCount + intSubmitCount)) * 100 + "' color='AFD8F8'  />";
                }
                if (intSubmitCount == 0)
                {
                    strXML += "<set name='流程提交率' value='' color='F6BD0F' />";
                }
                else
                {
                    strXML += "<set name='流程提交率' value='" + (intSubmitCount / (intBackCount + intSubmitCount)) * 100 + "' color='F6BD0F' />";
                }
            }
        }
        else
        {
            if (this.rd_type.Text == "退回数分析")
            {
                strXML += "<set name='流程退回数' value='' color='AFD8F8'  />";
                strXML += "<set name='流程提交数' value='' color='F6BD0F' />";
                strXML += "<set name='流程总操作数' value='' color='F6BD0F' />";
            }
            else if (this.rd_type.Text == "退回率分析")
            {
                strXML += "<set name='流程退回率' value='' color='AFD8F8'  />";
                strXML += "<set name='流程提交率' value='' color='F6BD0F' />";
            }
        }
        strXML += "</graph>";
        return FusionCharts.RenderChartHTML("../FusionCharts/FCF_Column3D.swf", "ChartId", strXML, "myNext", "600", "400", false);
    }
Ejemplo n.º 5
0
    private void getData()
    {
        HyFlowLog HyFlowLog = new HyFlowLog();
        DataTable dt = new DataTable();
        HyFlowLog.hyuDeptid = this.ddl_dept.SelectedValue;
        string test = "";
        dt = HyFlowLog.GetBackAndSubmit(this.operateTime_s.Value, this.operateTime_e.Value, out test);
        this.lb_show.Text += " <tr height=\"22\" onmouseover=\"this.className='tr_over'\" onmouseout=\"this.className='tr_out'\" class=\"tr_out\">";
        if (this.ddl_dept.SelectedValue == "")
        {
            this.lb_show.Text += "<td align=\"center\" >全体人员</td>";
        }
        else
        {
            this.lb_show.Text += "<td align=\"center\" >" + this.ddl_dept.SelectedItem + "</td>";
        }

        this.lb_show.Text += "<td align=\"center\" >" + dt.Rows[0]["backTotal"].ToString() + "</td>";
        this.lb_show.Text += "<td align=\"center\" >" + dt.Rows[0]["submitTotal"].ToString() + "</td>";
        this.lb_show.Text += "<td align=\"center\" >" + (Convert.ToInt32(dt.Rows[0]["submitTotal"].ToString()) + Convert.ToInt32(dt.Rows[0]["backTotal"].ToString())) + "</td></tr>";
    }
Ejemplo n.º 6
0
 // 数据绑定
 private void RptBind()
 {
     if (this.ddl_dept.SelectedValue != "")
     {
         this.lb_show.Text = " <tr height=\"22\" onmouseover=\"this.className='tr_over'\" onmouseout=\"this.className='tr_out'\" class=\"tr_out\">";
         this.lb_show.Text += "<td align=\"center\">" + this.ddl_dept.SelectedItem + " </td>";
         HyFlowLog hyFlowlog = new HyFlowLog();
         //执行某操作
         DataTable dt = hyFlowlog.getArticleCount("", this.ddl_dept.SelectedValue, this.operateTime_s.Value, this.operateTime_e.v, "提交");
         this.lb_show.Text += "<td align=\"center\"> " + dt.Rows.Count + "</td>";
         //已办结流程
         iOver = hyFlowlog.getArticleCount("", this.ddl_dept.SelectedValue, "", "", "归档").Rows.Count;
         //未办结流程
         iNotOver = dt.Rows.Count - iOver;
         double tracks = 0;
         for (int i = 0; i < dt.Rows.Count; i++)
         {
             tracks += hyFlowlog.getOneArticleLog(dt.Rows[i]["hyOperationId"].ToString());
         }
         this.lb_show.Text += "<td align=\"center\">" + tracks + "分钟</td>";
         this.lb_show.Text += "<td align=\"center\">" + iNotOver + " </td>";
         this.lb_show.Text += "<td align=\"center\">" + iOver + "</td>";
         this.lb_show.Text += "</tr>";
         this.lb_flash.Text += CreateCharts();
     }
 }