- using System;
- using System.Data;
- using System.Configuration;
- using System.Collections.Generic;
- using System.Web;
- using System.Web.Security;
- using System.Web.UI;
- using System.Web.UI.WebControls;
- using System.Web.UI.WebControls.WebParts;
- using System.Web.UI.HtmlControls;
- public partial class WorkFlow_WorkFlowManager : System.Web.UI.Page
- {
- /// <summary>
- /// 模板
- /// </summary>
- Model.FlowBase MR = new Model.FlowBase();
- /// <summary>
- /// 业务
- /// </summary>
- BLL.FlowBase BR = new BLL.FlowBase();
- protected void Page_Load(object sender, EventArgs e)
- {
- LoginLogic.MatchLoad("../", "WorkFlow_WorkFlowManager");
- if (!IsPostBack)
- {
- MyDataBind();
- }
- }
- protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
- {
- for (int i = 0; i < GridView1.Rows.Count; i++)
- {
- //首先判断是否是数据行
- if (e.Row.RowType == DataControlRowType.DataRow)
- {
- //当鼠标停留时更改背景色
- e.Row.Attributes.Add("onmouseover", "c=this.style.backgroundColor;this.style.backgroundColor='#F0F0F0'");
- //当鼠标移开时还原背景色
- e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor=c");
- }
- }
- }
- /// <summary>
- /// 获取信息
- /// </summary>
- /// <param name="pidx">页号</param>
- public void MyDataBind()
- {
- List<Model.FlowBase> LRData = BR.GetList();
- if (LRData.Count == 0)
- {
- Model.FlowBase MR = new Model.FlowBase();
- LRData.Add(MR);
- }
- GridView1.DataSource = LRData;
- GridView1.DataBind();
- }
- /// <summary>
- /// 操作
- /// </summary>
- /// <returns></returns>
- public string CaoZuo()
- {
- string Id = Eval("Id").ToString();
- string BDID = Eval("BDID").ToString();
- string LCFL = Eval("LCFL").ToString();
- string Rtstr = @" <a href=""WorkFlowEdit.aspx?id=" + Id + @""">
- <img align=""absMiddle"" border=""0"" height=""18"" src=""../images/edit.gif"" width=""18"" /><span
- style=""color: #0000ff; text-decoration: underline""> 基本属性</span></a>
- <!--固定流程有流程编辑器选项 -->
- <a href=""WorkFlowStepSetting.aspx?lcflid=" + LCFL + "&lcid=" + Id + "&bdid=" + BDID + @""">
- <img align=""absMiddle"" border=""0"" height=""13"" src=""../images/arrow_down.gif"" width=""11"" /><span
- style=""color: #0000ff; text-decoration: underline""> 流程设计器 </span></a>
- ";
- //<img align=""absMiddle"" border=""0"" src=""../images/query.gif"" /><a href=""#""><span style=""color: #0000ff;
- // text-decoration: underline"">删除</span>
- return Rtstr;
- }
- /// <summary>
- /// 流程
- /// </summary>
- /// <returns></returns>
- public string LiuCheng()
- {
- string Rtstr = "人事";
- string Id = Eval("LCFL").ToString();
- Rtstr = EnumGet.GetFlowBaseTypeName(int.Parse(Id));
- return Rtstr;
- }
- /// <summary>
- /// 表单
- /// </summary>
- /// <returns></returns>
- public string BiaoDan()
- {
- string Rtstr = "请假";
- string Id = Eval("BDID").ToString();
- Rtstr = EnumGet.GetFlowBaseFormName(int.Parse(Id));
- Rtstr = "<a href='WebBrowserFlowForm.aspx?id=" + Id + "' target='_blank'>" + Rtstr + "</a> ";
- return Rtstr;
- }
- }