예제 #1
0
        protected void LoadContent()
        {
            string database = Session["DatabaseName"].ToString();
            string ListStr  = "";
            string ListStr1 = "";

            ViewState["edition"] = true;
            StringBuilder tmpStr1 = new StringBuilder();
            StringBuilder tmpStr2 = new StringBuilder();

            //if (CheckBoxList2.SelectedValue == "")
            //{ <td class=""auto-style46"" rowspan=""2"">單價分析</td>
            ListStr  = @"
                                <td class=""auto-style45"" colspan=""{0}"" rowspan=""2"">項次</td>
                                <td class=""auto-style45"" rowspan=""2"">工項名稱</td>
                                <td class=""auto-style45"" rowspan=""2"">單位</td>
                               
                                <td class=""auto-style45"" colspan=""3"">原執行預算&nbsp;<img src="" ../img/UNLock.jpg""  style=""visibility:{1};width:30px"" ><img src="" ../img/Lock.jpg""  style=""visibility:{2};width:30px"" ></td>";
            ListStr1 = @" <td class=""auto-style45"" rowspan=""2"">變更設計<br />
                                    追加減金額</td>
                        <td class=""auto-style45"" rowspan=""2"">備註</td></tr>
                        <tr class=""TableTop""> 
                                <td class=""auto-style90"">數量</td>
                                <td class=""auto-style90"">單價</td>
                                <td class=""auto-style90"">複價</td>";

            int LayerNum = WebModel.MaxLayerSNum(database, "EBudget_WBS", Session["ProjectCode"].ToString());
            int Lock     = WebModel.BudgetLock(database, "ProjectM0", Session["ProjectCode"].ToString(), "EBudgetLock");

            string Img  = Lock != 1 ? "visible" : "hidden";
            string Img1 = Lock == 1 ? "visible" : "hidden";


            tmpStr1.AppendLine(string.Format(ListStr, LayerNum, Img, Img1));
            tmpStr2.AppendLine(string.Format(ListStr1));

            Literal1.Text = tmpStr1.ToString();
            Literal2.Text = tmpStr2.ToString();
            //}
            //else
            //{



            //}
            DataContent();
            //Reload_Click(this, null);
        }