Пример #1
0
    protected void btnSave_Click(object sender, System.EventArgs e)
    {
        string value = this.hfldPrjId.Value;

        if (!string.IsNullOrEmpty(value))
        {
            System.Guid               id = new System.Guid(value);
            PTPrjInfoZTBService       pTPrjInfoZTBService       = new PTPrjInfoZTBService();
            PTPrjInfoZTBDetailService pTPrjInfoZTBDetailService = new PTPrjInfoZTBDetailService();
            PTPrjInfoZTB              byId  = pTPrjInfoZTBService.GetById(id);
            PTPrjInfoZTBDetail        byId2 = pTPrjInfoZTBDetailService.GetById(value);
            TenderInfo.GetById(value);
            System.DateTime?successBidDate = null;
            if (!string.IsNullOrEmpty(this.txtSuccessBidDate.Text))
            {
                successBidDate = new System.DateTime?(System.Convert.ToDateTime(this.txtSuccessBidDate.Text.Trim()));
            }
            byId2.SuccessBidDate = successBidDate;
            decimal?num = null;
            if (!string.IsNullOrEmpty(this.txtSuccessBidPrice.Text))
            {
                num = new decimal?(System.Convert.ToDecimal(this.txtSuccessBidPrice.Text.Trim()));
            }
            byId2.SuccessBidPrice   = num;
            byId2.SuccessBidRemark  = this.txtSuccessBidRemark.Text.Trim();
            byId.PrjCost            = new double?(System.Convert.ToDouble(num));
            byId.PrjStateChangeTime = new System.DateTime?(System.DateTime.Now);
            byId.PrjState           = new int?(int.Parse(ProjectParameter.WinBid));
            byId.ParentTypeCode     = pTPrjInfoZTBService.GetParentTypeCode(this.dropParentProject.SelectedValue);
            pTPrjInfoZTBService.Update(byId);
            pTPrjInfoZTBDetailService.Update(byId2);
            base.RegisterScript("top.ui.alert('中标资料保存成功!');top.ui.closeWin();top.ui.reloadTab();");
        }
    }
Пример #2
0
 protected void btnSave_Click(object sender, System.EventArgs e)
 {
     try
     {
         string value = this.hfldPrjId.Value;
         if (!string.IsNullOrEmpty(value))
         {
             PTPrjInfoZTBService       pTPrjInfoZTBService       = new PTPrjInfoZTBService();
             PTPrjInfoZTBDetailService pTPrjInfoZTBDetailService = new PTPrjInfoZTBDetailService();
             PTPrjInfoZTB       byId  = pTPrjInfoZTBService.GetById(new System.Guid(value));
             PTPrjInfoZTBDetail byId2 = pTPrjInfoZTBDetailService.GetById(value);
             if (!string.IsNullOrEmpty(this.txtApplyDate.Text.Trim()))
             {
                 byId2.ProjApplyDate = new System.DateTime?(System.Convert.ToDateTime(this.txtApplyDate.Text.Trim()));
             }
             if (!string.IsNullOrEmpty(this.txtProjStartDate.Text.Trim()))
             {
                 byId2.ProjStartDate = new System.DateTime?(System.Convert.ToDateTime(this.txtProjStartDate.Text.Trim()));
             }
             byId2.ProjStartRemark   = this.txtStartRemark.Text.Trim();
             byId.PrjState           = new int?(System.Convert.ToInt32(ProjectParameter.Initiate));
             byId.IsGiveUp           = false;
             byId.OldState           = null;
             byId.PrjStateChangeTime = new System.DateTime?(System.DateTime.Now);
             pTPrjInfoZTBService.Update(byId);
             pTPrjInfoZTBDetailService.Update(byId2);
             base.RegisterScript("top.ui.show('报名通过资料保存成功!');top.ui.winSuccess({parentName:'_initiatePass'});");
         }
     }
     catch
     {
         base.RegisterScript("top.ui.alert('报名通过资料保存失败!');top.ui.winSuccess({parentName:'_initiatePass'});");
     }
 }
Пример #3
0
    protected void btnSaveData_Click(object sender, System.EventArgs e)
    {
        string b = this.ViewState["prjState"].ToString();

        this.ViewState["prjGuId"].ToString();
        if (this.drpDLstState.SelectedValue == b)
        {
            base.RegisterScript("top.ui.alert('项目状态没有改变!')");
            return;
        }
        if (string.IsNullOrEmpty(this.drpDLstState.SelectedValue))
        {
            base.RegisterScript("top.ui.alert('调整项目状态不能为空!')");
            return;
        }
        PTPrjInfoStateChange pTPrjInfoStateChange = new PTPrjInfoStateChange();

        if (this.ViewState["PrjChgStID"] != null)
        {
            string id = this.ViewState["PrjChgStID"].ToString();
            pTPrjInfoStateChange              = this.prjInfoStatChgSev.GetById(id);
            pTPrjInfoStateChange.OldState     = new int?(int.Parse(this.ViewState["prjState"].ToString()));
            pTPrjInfoStateChange.ChangeState  = new int?(int.Parse(this.drpDLstState.SelectedValue));
            pTPrjInfoStateChange.ChangeTime   = new System.DateTime?(System.DateTime.Parse(this.adjTime.Text));
            pTPrjInfoStateChange.ChangeReason = this.adjReason.Text.Trim();
            pTPrjInfoStateChange.ChangeUser   = this.hfldUserCode.Value.Trim();
            pTPrjInfoStateChange.Note         = this.remark.Text;
            pTPrjInfoStateChange.FlowState    = new int?(-1);
            pTPrjInfoStateChange.InputDate    = new System.DateTime?(System.DateTime.Now);
            pTPrjInfoStateChange.InputUser    = base.UserCode;
            this.prjInfoStatChgSev.Update(pTPrjInfoStateChange);
        }
        else
        {
            pTPrjInfoStateChange.Id           = System.Guid.NewGuid().ToString();
            pTPrjInfoStateChange.PrjId        = this.ViewState["prjGuId"].ToString();
            pTPrjInfoStateChange.OldState     = new int?(int.Parse(this.ViewState["prjState"].ToString()));
            pTPrjInfoStateChange.ChangeState  = new int?(int.Parse(this.drpDLstState.SelectedValue));
            pTPrjInfoStateChange.ChangeTime   = new System.DateTime?(System.DateTime.Parse(this.adjTime.Text));
            pTPrjInfoStateChange.ChangeReason = this.adjReason.Text.Trim();
            pTPrjInfoStateChange.ChangeUser   = this.hfldUserCode.Value.Trim();
            pTPrjInfoStateChange.Note         = this.remark.Text;
            pTPrjInfoStateChange.FlowState    = new int?(-1);
            pTPrjInfoStateChange.InputDate    = new System.DateTime?(System.DateTime.Now);
            pTPrjInfoStateChange.InputUser    = base.UserCode;
            this.prjInfoStatChgSev.Add(pTPrjInfoStateChange);
            PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
            PTPrjInfoZTB        byId = pTPrjInfoZTBService.GetById(new System.Guid(this.ViewState["prjGuId"].ToString()));
            byId.ChangeFlowSate = -1;
            pTPrjInfoZTBService.Update(byId);
        }
        base.RegisterScript("top.ui.show('保存成功!');top.ui.winSuccess({parentName:'_prjStateAdjust'});");
    }
Пример #4
0
        public void CommitEvent(object key)
        {
            Guid id = new Guid(key.ToString());
            PTPrjInfoZTBService service  = new PTPrjInfoZTBService();
            PTPrjInfoService    service2 = new PTPrjInfoService();
            PTPrjInfoZTB        byId     = service.GetById(id);

            if (byId.PrjState.ToString() == ProjectParameter.WinBid)
            {
                service2.ChangePrjInfo(byId, 5, 1);
            }
        }
Пример #5
0
        public void CommitEvent(object key)
        {
            string prjId = key.ToString();
            PTPrjInfoStateChangeService service        = new PTPrjInfoStateChangeService();
            PTPrjInfoZTBService         service2       = new PTPrjInfoZTBService();
            PTPrjInfoStateChange        byPrjIdByOrder = service.GetByPrjIdByOrder(prjId, -1);

            if (byPrjIdByOrder != null)
            {
                service.ChangeFlowStateInfo(prjId, -1, 1);
                service2.UpdatePrjStateAtStateChange(prjId, byPrjIdByOrder.OldState.Value, byPrjIdByOrder.ChangeState.Value);
            }
        }
Пример #6
0
 protected void initPageInfo()
 {
     if (!string.IsNullOrEmpty(base.Request["PrjId"]))
     {
         string       g    = base.Request["PrjId"];
         PTPrjInfoZTB byId = new PTPrjInfoZTBService().GetById(new System.Guid(g));
         if (byId.ParentTypeCode != null)
         {
             PTPrjInfo entityByTypeCode = new PTPrjInfoService().GetEntityByTypeCode(byId.ParentTypeCode);
             if (entityByTypeCode != null)
             {
                 this.dropParentProject.Items.FindByText(entityByTypeCode.PrjName).Selected = true;
             }
         }
     }
 }
Пример #7
0
    protected void BindProject(string prjId)
    {
        PTPrjInfoZTB byId = new PTPrjInfoZTBService().GetById(new System.Guid(prjId));

        if (byId != null)
        {
            this.txtPrjName.Text    = byId.PrjName;
            this.hfldPrjState.Value = byId.PrjState.ToString();
        }
        PTPrjInfo byId2 = new PTPrjInfoService().GetById(prjId);

        if (byId2 != null)
        {
            this.txtPrjName.Text    = byId2.PrjName;
            this.hfldPrjState.Value = byId2.PrjState.ToString();
        }
    }
Пример #8
0
 private void BindPrjName()
 {
     if (this.year != "zzjg")
     {
         PTPrjInfoService pTPrjInfoService = new PTPrjInfoService();
         PTPrjInfo        byId             = pTPrjInfoService.GetById(this.prjId);
         if (byId != null)
         {
             this.hfldPrjName.Value = byId.PrjName;
             return;
         }
         PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
         PTPrjInfoZTB        byId2 = pTPrjInfoZTBService.GetById(this.prjId);
         if (byId2 != null)
         {
             this.hfldPrjName.Value = byId2.PrjName;
         }
     }
 }
Пример #9
0
    protected void btnSave_Click(object sender, System.EventArgs e)
    {
        string value = this.hfldPrjId.Value;

        System.Guid         id = new System.Guid(value);
        PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
        PTPrjInfoZTB        byId = pTPrjInfoZTBService.GetById(id);

        byId.GiveUpTime   = Common2.ConverToDateTime(this.txtGiveUpTime.Text.Trim());
        byId.OldState     = new int?(System.Convert.ToInt32(ProjectParameter.Initiate));
        byId.IsGiveUp     = true;
        byId.GiveUpReason = this.txtGiveUPReason.Text.Trim();
        byId.GiveUpNote   = this.txtNote.Text.Trim();
        byId.PrjState     = new int?(System.Convert.ToInt32(ProjectParameter.GiveUpState));
        byId.Operator     = this.hfldOperator.Value;
        pTPrjInfoZTBService.Update(byId);
        this.bindGv();
        base.RegisterShow("系统提示", "保存成功");
    }
Пример #10
0
 protected void btnSave_Click(object sender, System.EventArgs e)
 {
     try
     {
         string              g  = base.Request["prjId"].ToString();
         System.Guid         id = new System.Guid(g);
         PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
         PTPrjInfoZTB        byId = pTPrjInfoZTBService.GetById(id);
         if (byId != null)
         {
             byId.GiveUpTime = Common2.ConverToDateTime(this.txtGiveUpTime.Text.Trim());
             if (byId.PrjState.ToString() != ProjectParameter.GiveUpState)
             {
                 byId.OldState = byId.PrjState;
                 if (byId.PrjState.ToString() == ProjectParameter.Initiate || byId.PrjState.ToString() == ProjectParameter.InitiateFail || byId.PrjState.ToString() == ProjectParameter.Approval)
                 {
                     byId.OldState = new int?(int.Parse(ProjectParameter.Approval));
                 }
                 if (byId.InitiateFlowState.ToString() == "1" && (byId.PrjState.ToString() == ProjectParameter.Initiate || byId.PrjState.ToString() == ProjectParameter.Prequalification || byId.PrjState.ToString() == ProjectParameter.QualificationPass || byId.PrjState.ToString() == ProjectParameter.QualificationFail))
                 {
                     byId.OldState = new int?(int.Parse(ProjectParameter.Initiate));
                 }
                 if (byId.PftFlowState.ToString() == "1" && (byId.PrjState.ToString() == ProjectParameter.QualificationPass || byId.PrjState.ToString() == ProjectParameter.Bid))
                 {
                     byId.OldState = new int?(int.Parse(ProjectParameter.QualificationPass));
                 }
             }
             byId.PrjState           = new int?(System.Convert.ToInt32(ProjectParameter.GiveUpState));
             byId.GiveUpReason       = this.txtGiveUPReason.Text.Trim();
             byId.GiveUpNote         = this.txtNote.Text.Trim();
             byId.Operator           = this.hfldOperator.Value;
             byId.PrjStateChangeTime = new System.DateTime?(System.DateTime.Now);
             byId.IsGiveUp           = true;
             pTPrjInfoZTBService.Update(byId);
             base.RegisterScript("top.ui.show('保存成功!');top.ui.winSuccess({parentName:'_GiveUpInfo'});");
         }
     }
     catch
     {
         base.RegisterScript("top.ui.closeWin();top.ui.alert('保存失败!');");
     }
 }
Пример #11
0
    private string GetPrjCode(string prjId)
    {
        string           result           = string.Empty;
        PTPrjInfoService pTPrjInfoService = new PTPrjInfoService();
        PTPrjInfo        byId             = pTPrjInfoService.GetById(prjId);

        if (byId != null)
        {
            result = byId.PrjCode;
        }
        else
        {
            PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
            PTPrjInfoZTB        byId2 = pTPrjInfoZTBService.GetById(prjId);
            if (byId2 != null)
            {
                result = byId2.PrjCode;
            }
        }
        return(result);
    }
Пример #12
0
    protected void BindProject()
    {
        ProjectInfo byId = ProjectInfo.GetById(this.prjId);

        this.txtPrjName.Text    = byId.PrjName;
        this.hfldPrjGuid.Value  = this.prjId;
        this.hfldPrjState.Value = this.prjState;
        System.Guid  id    = new System.Guid(this.prjId);
        PTPrjInfoZTB byId2 = new PTPrjInfoZTBService().GetById(id);

        if (byId2 != null)
        {
            this.txtMainPrincipal.Text = byId2.WorkUnit;
        }
        PTPrjInfo byId3 = new PTPrjInfoService().GetById(this.prjId);

        if (byId3 != null)
        {
            this.txtMainPrincipal.Text = byId3.WorkUnit;
        }
    }
Пример #13
0
 protected void btnDelete_Click(object sender, System.EventArgs e)
 {
     try
     {
         PTPrjInfoZTBService pTPrjInfoZTBService        = new PTPrjInfoZTBService();
         PTPrjInfoService    pTPrjInfoService           = new PTPrjInfoService();
         System.Collections.Generic.IList <string> list = CsvHelper.ToList(this.hfldCheckedIds.Value);
         for (int i = 0; i < list.Count; i++)
         {
             string id = list[i];
             pTPrjInfoZTBService.Delete(id);
             pTPrjInfoService.Delete(id);
         }
         this.bindGv();
         base.RegisterScript("top.ui.show('删除成功');");
     }
     catch (System.Exception)
     {
         base.RegisterScript("top.ui.show('删除失败');");
     }
 }
Пример #14
0
    private void BindData()
    {
        string text = base.Request["ic"].ToString();
        PTPrjInfoStateChange byPrjIdByOrder;

        if (string.IsNullOrEmpty(base.Request["pass"]))
        {
            byPrjIdByOrder = new PTPrjInfoStateChangeService().GetByPrjIdByOrder(text, 1);
        }
        else
        {
            byPrjIdByOrder = new PTPrjInfoStateChangeService().GetByPrjIdByOrder(text, -1);
        }
        BasicCodeListService basicCodeListService = new BasicCodeListService();

        System.Guid  id   = new System.Guid(text);
        PTPrjInfoZTB byId = new PTPrjInfoZTBService().GetById(id);

        if (byPrjIdByOrder != null)
        {
            if (!string.IsNullOrEmpty(byPrjIdByOrder.ChangeUser))
            {
                PTyhmc byId2 = new PTYhmcService().GetById(byPrjIdByOrder.ChangeUser);
                this.lblChangeMan.Text = byId2.v_xm;
            }
            this.lblChangeTime.Text      = Common2.GetTime(byPrjIdByOrder.ChangeTime.ToString());
            this.lblOldState.Text        = basicCodeListService.GetNameByTypeAndCode("ProjectState", byPrjIdByOrder.OldState.Value);
            this.lblChangeState.Text     = basicCodeListService.GetNameByTypeAndCode("ProjectState", byPrjIdByOrder.ChangeState.Value);
            this.lblprjChangeReason.Text = byPrjIdByOrder.ChangeReason;
            this.lblPrjRemark.Text       = byPrjIdByOrder.Note;
        }
        if (byId != null)
        {
            this.lblPrjCode.Text   = byId.PrjCode;
            this.lblPrjName.Text   = byId.PrjName;
            this.lblStartDate.Text = Common2.GetTime(byId.StartDate).ToString();
            this.lblEndDate.Text   = Common2.GetTime(byId.EndDate).ToString();
        }
    }
Пример #15
0
 public static void ClearPTPrjInfo(object o)
 {
     try
     {
         Log4netHelper.Error(new Exception("ClearPTPrjInfo 开始执行"), "ClearPTPrjInfo", "bery");
         BasicConfigService service = new BasicConfigService();
         BasicConfig        byName  = service.GetByName("IsClearPTPrjInfo");
         if (byName == null)
         {
             byName = new BasicConfig {
                 Id        = Guid.NewGuid().ToString(),
                 ParaName  = "IsClearPTPrjInfo",
                 ParaValue = "0",
                 Note      = "是否已经把PT_PrjInfo_ZTB表的数据导入PT_PrjInfo表中"
             };
             service.Add(byName);
         }
         if (byName.ParaValue != "1")
         {
             string cmdText = "SELECT PrjGuid FROM PT_PrjInfo_ZTB WHERE PrjGuid Not IN (SELECT PrjGuid FROM PT_PrjInfo)";
             foreach (DataRow row in SqlHelper.ExecuteQuery(CommandType.Text, cmdText, new SqlParameter[0]).Rows)
             {
                 Guid id = new Guid(row[0].ToString());
                 PTPrjInfoZTBService service2 = new PTPrjInfoZTBService();
                 PTPrjInfoService    service3 = new PTPrjInfoService();
                 PTPrjInfoZTB        byId     = service2.GetById(id);
                 service3.ChangePrjInfo(byId, 2, 1);
             }
             byName.ParaValue = "1";
             service.Update(byName);
         }
     }
     catch (Exception exception)
     {
         Log4netHelper.Error(exception, "ClearPTPrjInfo", "bery");
     }
 }
Пример #16
0
    protected void btnSave_Click(object sender, System.EventArgs e)
    {
        string value = this.hfldPrjId.Value;

        if (!string.IsNullOrEmpty(value))
        {
            TenderInfo      byId       = TenderInfo.GetById(value);
            System.DateTime?outBidDate = null;
            if (!string.IsNullOrEmpty(this.txtOutBidDate.Text))
            {
                outBidDate = new System.DateTime?(System.Convert.ToDateTime(this.txtOutBidDate.Text));
            }
            byId.OutBidDate = outBidDate;
            bool?outBidIsReturn = null;
            if (this.RblOutBidIsReturn.SelectedValue == "0")
            {
                outBidIsReturn = new bool?(false);
            }
            else
            {
                if (this.RblOutBidIsReturn.SelectedValue == "1")
                {
                    outBidIsReturn = new bool?(true);
                }
            }
            byId.OutBidIsReturn = outBidIsReturn;
            byId.OutBidRemark   = this.txtOutBidRemark.Text;
            byId.PrjState       = int.Parse(ProjectParameter.OutBid);
            PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
            PTPrjInfoZTB        byId2 = pTPrjInfoZTBService.GetById(new System.Guid(value));
            byId2.PrjStateChangeTime = new System.DateTime?(System.DateTime.Now);
            pTPrjInfoZTBService.Update(byId2);
            byId.UpdatePart(byId, ProjectParameter.OutBid);
            base.RegisterScript("top.ui.alert('落标资料保存成功!');top.ui.closeWin();top.ui.reloadTab();");
        }
    }
Пример #17
0
 protected void btnSave_Click(object sender, System.EventArgs e)
 {
     try
     {
         string prjGuid = this.hfldPrjId.Value;
         if (!string.IsNullOrEmpty(prjGuid))
         {
             TenderInfo      byId                  = TenderInfo.GetById(prjGuid);
             System.DateTime?projApplyDate         = null;
             System.DateTime?qualificationFailData = null;
             if (!string.IsNullOrEmpty(this.txtApplyDate1.Text.Trim()))
             {
                 projApplyDate = new System.DateTime?(System.Convert.ToDateTime(this.txtApplyDate1.Text.Trim()));
             }
             byId.ProjApplyDate = projApplyDate;
             System.DateTime?projApprovalDate = null;
             if (!string.IsNullOrEmpty(this.txtApprovalDate1.Text.Trim()))
             {
                 projApprovalDate = new System.DateTime?(System.Convert.ToDateTime(this.txtApprovalDate1.Text.Trim()));
             }
             byId.ProjApprovalDate = projApprovalDate;
             System.DateTime?projTenderDate = null;
             if (!string.IsNullOrEmpty(this.txtTenderDate1.Text))
             {
                 projTenderDate = new System.DateTime?(System.Convert.ToDateTime(this.txtTenderDate1.Text.Trim()));
             }
             byId.ProjTenderDate = projTenderDate;
             if (!string.IsNullOrEmpty(this.txtRegistDeadline1.Text.Trim()))
             {
                 byId.ProjRegistDeadline = new int?(System.Convert.ToInt32(this.txtRegistDeadline1.Text.Trim()));
             }
             byId.ProgAgent = this.hfldAgent1.Value;
             byId.PrequalificationRequire = this.txtPrequalificationRequire1.Text.Trim();
             if (!string.IsNullOrWhiteSpace(this.txtQualificationMargin1.Text))
             {
                 byId.QualificationMargin = System.Convert.ToDecimal(this.txtQualificationMargin1.Text.Trim());
             }
             byId.QualificationReadOne = this.hfldQualificationReadOne1.Value;
             if (!string.IsNullOrEmpty(this.txtFailDate.Text))
             {
                 qualificationFailData = new System.DateTime?(System.Convert.ToDateTime(this.txtFailDate.Text.Trim()));
             }
             byId.QualificationFailData   = qualificationFailData;
             byId.QualificationFailReason = this.txtFailReason.Text.Trim();
             if (!string.IsNullOrEmpty(byId.QualificationReadOne))
             {
                 PTDBSJService pTDBSJService = new PTDBSJService();
                 pTDBSJService.Add(new PTDBSJ
                 {
                     I_XGID     = byId.PrjGuid.ToString(),
                     V_LXBM     = "024",
                     V_YHDM     = byId.QualificationReadOne,
                     DTM_DBSJ   = new System.DateTime?(System.DateTime.Now),
                     C_OpenFlag = "0",
                     V_Content  = "项目:" + byId.PrjName + "已经开始预审失败",
                     V_DBLJ     = "TenderManage/InfoView.aspx?ic=" + byId.PrjGuid.ToString(),
                     V_TPLJ     = "new_Mail.gif"
                 });
             }
             if (!string.IsNullOrEmpty(this.txtApplyDate1.Text.Trim()))
             {
                 PTDBSJTodayService pTDBSJTodayService = new PTDBSJTodayService();
                 System.Collections.Generic.List <PTDBSJToday> list = (
                     from dbsj in pTDBSJTodayService
                     where dbsj.I_XGID == prjGuid
                     select dbsj).ToList <PTDBSJToday>();
                 foreach (PTDBSJToday current in list)
                 {
                     pTDBSJTodayService.Delete(current);
                 }
                 //System.Collections.Generic.List<TenderUser> byId2 = TenderUser.GetById(byId.PrjGuid.ToString());
                 string          str   = @"with t as (select m.*,yh.v_xm from PT_PrjInfo_ZTB_User m left join PT_yhmc yh on m.UserCode = yh.v_yhdm where  m.PrjGuid ='" + byId.PrjGuid.ToString() + "') select Id, PrjGuid, UserCode, v_xm UserName from t";
                 DataSet         ds    = publicDbOpClass.DataSetQuary(str);
                 System.DateTime value = System.Convert.ToDateTime(this.txtApplyDate1.Text.Trim()).AddDays((double)(-(double)System.Convert.ToInt32(this.SignUpWarnDay)));
                 //foreach (TenderUser current2 in byId2)
                 foreach (DataRow current2 in ds.Tables[0].Rows)
                 {
                     pTDBSJTodayService.Add(new PTDBSJToday
                     {
                         I_XGID     = prjGuid,
                         V_LXBM     = "027",
                         V_YHDM     = current2["UserCode"].ToString(),                        //current2.UserCode,
                         DTM_DBSJ   = new System.DateTime?(value),
                         V_TPLJ     = "",
                         V_DBLJ     = "TenderManage/InfoView.aspx?ic=" + prjGuid,
                         V_Content  = "名称为:" + byId.PrjName + "的项目已经开始预审失败。",
                         C_OpenFlag = "1"
                     });
                 }
             }
             PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
             PTPrjInfoZTB        byId3 = pTPrjInfoZTBService.GetById(new System.Guid(prjGuid));
             byId3.PrjStateChangeTime = new System.DateTime?(System.DateTime.Now);
             pTPrjInfoZTBService.Update(byId3);
             byId.UpdatePart(byId, ProjectParameter.QualificationFail);
             base.RegisterScript("top.ui.show('预审失败资料保存成功!');top.ui.winSuccess({parentName:'_QulifcationFail'});");
         }
     }
     catch
     {
         base.RegisterScript("top.ui.alert('预审失败资料保存失败!');top.ui.winSuccess({parentName:'_QulifcationFail'});");
     }
 }
Пример #18
0
 protected void BindInfos()
 {
     this.hfldStartReportId.Value = this.reportId;
     try
     {
         PTStartReport byId = this.startReportServer.GetById(this.reportId);
         if (byId != null)
         {
             this.BindProject(byId.PrjGuid);
             this.txtSingleProjectName.Text = byId.SingleProjectName;
             this.txtProjectPlace.Text      = byId.ProjectPlace;
             this.txtConstructionUnit.Text  = byId.ConstructionUnit;
             if (byId.ApplyStartDate.HasValue)
             {
                 this.txtApplyStartDate.Text = byId.ApplyStartDate.Value.ToString("yyyy-MM-dd");
             }
             if (byId.RealityStartDate.HasValue)
             {
                 this.txtRealityStartDate.Text = byId.RealityStartDate.Value.ToString("yyyy-MM-dd");
             }
             this.txtMainContent.Text           = byId.MainContent;
             this.txtPrepareCondition.Text      = byId.PrepareCondition;
             this.txtExistenceProblem.Text      = byId.ExistenceProblem;
             this.txtSupervisorUnitOpinion.Text = byId.SupervisorUnitOpinion;
             this.txtBuildUnitOpinion.Text      = byId.BuildUnitOpinion;
             this.txtApplyUnit.Text             = byId.ApplyUnit;
             this.txtAuditUnit.Text             = byId.AuditUnit;
             if (!string.IsNullOrEmpty(byId.ImplDep))
             {
                 System.Collections.Generic.IList <XpmCode> list = new System.Collections.Generic.List <XpmCode>();
                 XpmCodeServices xpmCodeServices = new XpmCodeServices();
                 list = xpmCodeServices.GetBySignCode("dd");
                 foreach (XpmCode current in list)
                 {
                     if (current.NoteID == System.Convert.ToInt32(byId.ImplDep))
                     {
                         this.txtImplDep.Text = current.CodeName;
                     }
                 }
             }
             this.lblActualPrincipal.Text = byId.ActualPrincipal;
             System.Guid  id    = new System.Guid(this.prjId);
             PTPrjInfoZTB byId2 = new PTPrjInfoZTBService().GetById(id);
             if (byId2 != null)
             {
                 this.lblMainPrincipal.Text = byId2.WorkUnit;
                 this.txtPrjName.Text       = byId2.PrjName;
                 this.hfldPrjState.Value    = byId2.PrjState.ToString();
             }
             PTPrjInfo byId3 = new PTPrjInfoService().GetById(this.prjId);
             if (byId3 != null)
             {
                 this.lblMainPrincipal.Text = byId3.WorkUnit;
                 this.txtPrjName.Text       = byId3.PrjName;
                 this.hfldPrjState.Value    = byId3.PrjState.ToString();
             }
         }
         else
         {
             this.BindProject(this.reportId);
         }
     }
     catch
     {
         this.BindProject(this.reportId);
     }
 }
Пример #19
0
    private void BindLbl(string PrjId)
    {
        TenderInfo byId  = TenderInfo.GetById(PrjId);
        string     state = byId.PrjState.ToString();

        this.lblOwner.Text             = byId.OwnerName;
        this.lblOwnerLinkMan.Text      = byId.OwnerLinkManName;
        this.lblOwnerLinkManPhone.Text = byId.OwnerLinkPhone;
        this.lblOwnerAddress.Text      = byId.OwnerAddress;
        this.lblCorp.Text  = byId.ProjPeopleCorp;
        this.lblPhone.Text = byId.ProjPeopleTel;
        this.lblDuty.Text  = byId.ProjPeopleDuty;
        this.lblName.Text  = byId.ProjPeopleUserName;
        this.lblForecastProfitRate.Text       = byId.ForecastProfitRate.ToString();
        this.lblEngineeringEstimates.Text     = byId.EngineeringEstimates;
        this.lblApprovalOf.Text               = byId.PrjApprovalOf;
        this.lblManagementMargin.Text         = byId.ManagementMargin.ToString();
        this.lblMigrantQualityMarginRate.Text = byId.MigrantQualityMarginRate.ToString();
        this.lblWithholdingTaxRate.Text       = byId.WithholdingTaxRate.ToString();
        this.lblPerformanceBond.Text          = byId.PerformanceBond.ToString();
        this.lblElseMargin.Text               = byId.ElseMargin.ToString();
        this.lblFundWorkable.Text             = byId.PrjFundWorkable;
        this.lblPrjState.Text    = TypeList.GetTypeName(byId.PrjProperty, "1", "ProjectProperty");
        this.lblBllProducer.Text = byId.GetUserName(base.UserCode);
        this.lblPrintDate.Text   = System.DateTime.Now.ToShortDateString();
        if (!string.IsNullOrEmpty(byId.Province))
        {
            this.lblArea.Text = byId.Province + byId.City;
        }
        this.lblBudgetWay.Text    = TypeList.GetTypeName(byId.BudgetWay, "1", "ysType");
        this.lblBuildingArea.Text = byId.BuildingArea;
        if (byId.EngineeringTypes != null)
        {
            System.Text.StringBuilder stringBuilder = new System.Text.StringBuilder();
            foreach (EngineeringType current in byId.EngineeringTypes)
            {
                stringBuilder.Append(current.ToString()).Append("<br />");
            }
            this.lblBuildingType.Text = stringBuilder.ToString();
        }
        this.lblContractWay.Text = TypeList.GetTypeName(byId.ContractWay, "1", "cbType");
        this.lblCounsellor.Text  = byId.Counsellor;
        this.lblDesigner.Text    = byId.Designer;
        this.lblDuration.Text    = byId.Duration;
        this.lblElseRequest.Text = this.ReplaceTxt(byId.ProjElseRequest);
        this.lblEndDate.Text     = Common2.GetTime(byId.EndDate.ToString());
        if (byId.BuildingTypeNo.ToString() != "0")
        {
            this.lblgrade.Text = byId.BuildingTypeNo.ToString();
        }
        this.lblInfoOrigin.Text     = this.ReplaceTxt(byId.ProjInfoOrigin);
        this.lblInspector.Text      = byId.Inspector;
        this.lblKeyPart.Text        = TypeList.GetTypeName(byId.KeyPart, "1", "primaryGrade");
        this.lblOtherStatement.Text = this.ReplaceTxt(byId.OtherStatement);
        this.lblPayCondition.Text   = TypeList.GetTypeName(byId.PayCondition, "1", "payment");
        this.lblPayWay.Text         = TypeList.GetTypeName(byId.PayWay, "1", "jsType");
        this.lblPhone.Text          = byId.ProjPeopleTel;
        this.lblPrjCode.Text        = byId.PrjCode;
        if (byId.PrjCost.ToString() != "" && byId.PrjCost.ToString() != "0")
        {
            this.lblPrjCost.Text = byId.PrjCost.ToString();
        }
        this.lblPrjFundInfo.Text = byId.PrjFundInfo;
        this.lblPrjInfo.Text     = this.ReplaceTxt(byId.PrjInfo);
        this.lblDutyPerson.Text  = byId.PrjDutyPersonName;
        if (byId.PrjKinds != null)
        {
            System.Text.StringBuilder stringBuilder2 = new System.Text.StringBuilder();
            System.Text.StringBuilder stringBuilder3 = new System.Text.StringBuilder();
            foreach (ProjectKind current2 in byId.PrjKinds)
            {
                stringBuilder2.Append(current2.ProfessionalCost.ToString());
                stringBuilder3.Append(TypeList.GetTypeName(current2.PrjKind, "1", "ProjectType"));
            }
            this.lblPrjProfessionalCost.Text = stringBuilder2.ToString();
            this.lblPrjKindClass.Text        = stringBuilder3.ToString();
        }
        this.lblPrjManager.Text   = byId.PrjManagerName;
        this.lblPrjName.Text      = byId.PrjName;
        this.lblPrjPlace.Text     = byId.PrjPlace;
        this.lblQualityClass.Text = TypeList.GetTypeName(byId.QualityClass, "1", "ProjectQuality");
        if (byId.PrjRanks != null)
        {
            System.Text.StringBuilder stringBuilder4 = new System.Text.StringBuilder();
            foreach (ProjectRank current3 in byId.PrjRanks)
            {
                stringBuilder4.Append(TypeList.GetTypeName(current3.Rank, "1", "zzGrade") + " " + current3.RankLevel).Append("<br />");
            }
            this.lblRank.Text = stringBuilder4.ToString();
        }
        this.lblRemark1.Text         = this.ReplaceTxt(byId.Remark);
        this.lblStartDate.Text       = Common2.GetTime(byId.StartDate.ToString());
        this.lblTelphone.Text        = byId.Telephone;
        this.lblTenderWay.Text       = TypeList.GetTypeName(byId.TenderWay, "1", "zbType");
        this.lblTotalHouseNum.Text   = byId.TotalHouseNum;
        this.lblUndergroundArea.Text = byId.UndergroundArea;
        this.lblUsegrounArea.Text    = byId.UsegrounArea;
        this.lblAfforestArea.Text    = byId.AfforestArea;
        this.lblParkArea.Text        = byId.ParkArea;
        this.lblPrjReadOne.Text      = WebUtil.GetUserNames(byId.PrjReadOne);
        if (byId.WorkUnit != "")
        {
            this.lblWorkUnit.Text = byId.WorkUnitName;
        }
        this.upload.InnerHtml               = this.FilesBind(PrjId + "_" + ProjectParameter.PreApproval);
        this.lblPrjManagerRequire.Text      = byId.PrjManagerRequire;
        this.lblTechnicalLeaderRequire.Text = byId.TechnicalLeaderRequire;
        this.showInfo(byId, state, PrjId);
        PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();

        System.Guid  id    = new System.Guid(PrjId);
        PTPrjInfoZTB byId2 = pTPrjInfoZTBService.GetById(id);

        if (byId2 != null && byId2.PrjState == System.Convert.ToInt32(ProjectParameter.GiveUpState))
        {
            this.tr_fq.Visible = true;
            if (!byId2.GiveUpTime.HasValue)
            {
                this.lbGiveUpTime.Text = string.Empty;
            }
            else
            {
                this.lbGiveUpTime.Text = Common2.GetTime(byId2.GiveUpTime);
            }
            this.lbOperator.Text     = WebUtil.GetUserNames(byId2.Operator);
            this.lbGiveUpReason.Text = byId2.GiveUpReason;
            this.lbGiveUpNote.Text   = byId2.GiveUpNote;
            string state2 = byId2.OldState.ToString();
            this.showInfo(byId, state2, PrjId);
            this.trAudit_giveUp.Visible = true;
            this.file_GiveUp.InnerHtml  = this.FilesBind(PrjId + "_" + ProjectParameter.GiveUpState);
        }
    }
Пример #20
0
    protected void btnSave_Click(object sender, System.EventArgs e)
    {
        if (this.txtTenderCostContent.Text.Trim().Length > 500)
        {
            base.RegisterShow("系统提示", "现场费内容不能超过500个字!");
            return;
        }
        if (this.txtTenderContent.Text.Trim().Length > 500)
        {
            base.RegisterShow("系统提示", "标书内容不能超过500个字!");
            return;
        }
        string     text = base.Request["id"];
        TenderInfo byId = TenderInfo.GetById(text);

        if (byId != null)
        {
            byId.ProjTenderBeginDate = new System.DateTime?(System.Convert.ToDateTime(this.txtTenderBeginDate.Text));
            decimal?tenderAverage = null;
            if (!string.IsNullOrEmpty(this.txtTenderAverage.Text))
            {
                tenderAverage = new decimal?(System.Convert.ToDecimal(this.txtTenderAverage.Text));
            }
            byId.TenderAverage = tenderAverage;
            decimal?tenderCeilingPrice = null;
            if (!string.IsNullOrEmpty(this.txtTenderCeilingPrice.Text))
            {
                tenderCeilingPrice = new decimal?(System.Convert.ToDecimal(this.txtTenderCeilingPrice.Text));
            }
            byId.TenderCeilingPrice = tenderCeilingPrice;
            decimal?projTenderEarnestMoney = null;
            if (!string.IsNullOrEmpty(this.txtTenderEarnestMoney.Text))
            {
                projTenderEarnestMoney = new decimal?(System.Convert.ToDecimal(this.txtTenderEarnestMoney.Text));
            }
            byId.ProjTenderEarnestMoney = projTenderEarnestMoney;
            decimal?tenderQuote = null;
            if (!string.IsNullOrEmpty(this.txtTenderQuote.Text))
            {
                tenderQuote = new decimal?(System.Convert.ToDecimal(this.txtTenderQuote.Text));
            }
            byId.TenderQuote           = tenderQuote;
            byId.TenderUnit            = this.txtTenderUnit.Text;
            byId.TenderAppraiseMethod  = this.dropTenderAppraiseMethod.SelectedValue;
            byId.ProjTenderCostContent = this.txtTenderCostContent.Text;
            System.DateTime?projTenderAnswerDate = null;
            if (!string.IsNullOrEmpty(this.txtTenderAnswerDate.Text))
            {
                projTenderAnswerDate = new System.DateTime?(System.Convert.ToDateTime(this.txtTenderAnswerDate.Text));
            }
            byId.ProjTenderAnswerDate = projTenderAnswerDate;
            byId.ProjTenderPayWay     = this.dropTenderPayWay.SelectedValue;
            byId.ProjTenderRemark     = this.txtTenderRemark.Text;
            byId.ProjTenderContent    = this.txtTenderContent.Text;
            byId.PrjManager           = this.txtTenderPrjManager.Text;
            if (!string.IsNullOrWhiteSpace(this.txtTenderProspect.Text))
            {
                byId.TenderProspect = new System.DateTime?(System.Convert.ToDateTime(this.txtTenderProspect.Text));
            }
            if (!string.IsNullOrEmpty(this.hfldTenderReadOne.Value))
            {
                byId.TenderReadOne = this.hfldTenderReadOne.Value;
                PTDBSJService pTDBSJService = new PTDBSJService();
                pTDBSJService.Add(new PTDBSJ
                {
                    I_XGID     = byId.PrjGuid.ToString(),
                    V_LXBM     = "024",
                    V_YHDM     = this.hfldTenderReadOne.Value,
                    DTM_DBSJ   = new System.DateTime?(System.DateTime.Now),
                    C_OpenFlag = "0",
                    V_Content  = "项目:" + byId.PrjName + "已经投标",
                    V_DBLJ     = "TenderManage/InfoView.aspx?ic=" + byId.PrjGuid.ToString(),
                    V_TPLJ     = "new_Mail.gif"
                });
            }
            PTPrjInfoZTBService pTPrjInfoZTBService = new PTPrjInfoZTBService();
            PTPrjInfoZTB        byId2 = pTPrjInfoZTBService.GetById(new System.Guid(text));
            byId2.PrjStateChangeTime = new System.DateTime?(System.DateTime.Now);
            pTPrjInfoZTBService.Update(byId2);
            byId.UpdatePart(byId, "4");
            string str = "BidManage.aspx";
            if (!string.IsNullOrEmpty(base.Request["purl"]))
            {
                str = base.Request["purl"];
            }
            string message = "CancelClick('" + str + "',true);";
            base.RegisterScript(message);
        }
    }