Ejemplo n.º 1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            work_id = Convert.ToInt32(Request["work_id"]);
            //wm_id = helper.ExecScalar("select wm_id from Tb_Working_main where ");
            if (!Page.IsPostBack)
            {
                string Sql = "select * from Tb_Working where work_id=@work_id";
                helper.Params.Add("@work_id", work_id);
                dt = helper.ExecDataTable(Sql);
                if (dt.Rows.Count > 0)
                {
                    factory_manager.Text  = dt.Rows[0]["factory_manager"].ToString();
                    our_manager.Text      = dt.Rows[0]["our_manager"].ToString();
                    start_date.Text       = Convert.ToDateTime(dt.Rows[0]["start_date"]).ToShortDateString();
                    end_date.Text         = Convert.ToDateTime(dt.Rows[0]["end_date"]).ToShortDateString();
                    work_remark.Text      = dt.Rows[0]["work_remark"].ToString();
                    int_factory_id        = Convert.ToInt32(dt.Rows[0]["factory_id"]);
                    int_from_warehouse_id = Convert.ToInt32(dt.Rows[0]["warehouse_id"]);
                    work_status_old.Value = Convert.ToString(dt.Rows[0]["work_status"]);
                    bind_status_list(Convert.ToInt32(dt.Rows[0]["work_status"]));
                }
                else
                {
                    Response.Write("数据传递有误");
                    Response.End();
                }
                ProductionHelper.BindFactoryList(factory_id, int_factory_id);
                StorageHelper.BindWarehouseList(from_warehouse_id, int_from_warehouse_id, my_warehouse_id.ToString(), "");

                bindTemplatePro();
                Session["anti_in_refresh"] = "1";
            }
        }
Ejemplo n.º 2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            work_id = Convert.ToInt32(Request["work_id"]);
            if (!Page.IsPostBack)
            {
                Session["anti_refresh"] = "1";
                string Sql = "select * from Tb_Working where work_id=@work_id";
                helper.Params.Add("@work_id", work_id);
                DataTable dt = helper.ExecDataTable(Sql);
                if (dt.Rows.Count > 0)
                {
                    factory_manager.Text  = dt.Rows[0]["factory_manager"].ToString();
                    our_manager.Text      = dt.Rows[0]["our_manager"].ToString();
                    start_date.Text       = Convert.ToDateTime(dt.Rows[0]["start_date"]).ToShortDateString();
                    end_date.Text         = Convert.ToDateTime(dt.Rows[0]["end_date"]).ToShortDateString();
                    work_remark.Text      = dt.Rows[0]["work_remark"].ToString();
                    int_factory_id        = Convert.ToInt32(dt.Rows[0]["factory_id"]);
                    int_from_warehouse_id = Convert.ToInt32(dt.Rows[0]["warehouse_id"]);
                }

                StorageHelper.BindWarehouseList(from_warehouse_id, int_from_warehouse_id, my_warehouse_id.ToString(), "");
                ProductionHelper.BindFactoryList(factory_id, int_factory_id);

                bindTemplatePro();
            }
        }
Ejemplo n.º 3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     SiteHelper.CheckLogin();
     if (!Page.IsPostBack)
     {
         string where = "1=1";
         BindMemberList(SiteHelper.getPage());
         ProductionHelper.BindFactoryList(factory_id, 0);
     }
 }
Ejemplo n.º 4
0
        protected void Page_Load(object sender, EventArgs e)
        {
            id = Convert.ToInt32(Request["id"]);
            if (!Page.IsPostBack)
            {
                Session["anti_refresh"] = "1";
                string Sql = "select * from Tb_template where tpl_id=@id";
                helper.Params.Add("@id", id);
                DataTable dt = helper.ExecDataTable(Sql);
                if (dt.Rows.Count > 0)
                {
                    pro_name.Text   = dt.Rows[0]["pro_name"].ToString();
                    pro_code.Text   = dt.Rows[0]["pro_code"].ToString();
                    do_cost.Text    = dt.Rows[0]["do_cost"].ToString();
                    other_cost.Text = dt.Rows[0]["other_cost"].ToString();
                    remark.Text     = dt.Rows[0]["remark"].ToString();
                    int_factory_id  = Convert.ToInt32(dt.Rows[0]["factory_id"]);
                }
                ProductionHelper.BindFactoryList(factory_id, 0);

                bindTemplatePro(id);
            }
        }