예제 #1
0
        public ActionResult Save(Quotation_Group group)
        {
            //if (group.Id == 0)
            //{
            //    group.IndateTime = DateTime.Now;
            //    group.InUserId = UserInfo.UserId;
            //    db.Quotation_Group.Add(group);
            //}
            //else
            //{
            //    group = db.Quotation_Group.Find(group.Id);
            //    TryUpdateModel<Quotation_Group>(group);
            //}
            //db.SaveChanges();
            string[] groupNameList = group.QuotationGroupName.Split('-');
            if (groupNameList.Length == 1)
            {
                group.QuotationGroupName = group.QuotationGroupName + "-" + DateTime.Now.ToString("yyyyMMddHHmmss");
            }
            quotationService.QuotationGroupSave(group.Id.ToString(), group.ProjectId.ToString(), group.QuotationGroupName, UserInfo.UserId, group.SettlementChk, group.RequirementGroupId.ToString());

            return(Json(group));
        }
예제 #2
0
 //public ActionResult RequirementSearchByProjectId(string projectId, string province, string city)
 //{
 //    List<RequiremetMstDto> list = requirementService.RequirementMstByProjectIdSearch(projectId, province, city);
 //    return PartialView("_PartialDemandBookSelect", list);
 //}
 //public ActionResult RequirementSearchByProjectIdSearch(string projectId, string province, string city)
 //{
 //    List<RequiremetMstDto> list = requirementService.RequirementMstByProjectIdSearch(projectId, province, city);
 //    return Json(new { List = list });
 //}
 #endregion
 public ActionResult SettlementUpdate(Quotation_Group group)
 {
     quotationService.QuotationGroupSettlementUpdate(group.ProjectId.ToString(), group.Id.ToString(), group.SettlementChk.Value);
     return(Json(group));
 }
예제 #3
0
 public ActionResult GetSettlementChk(Quotation_Group group)
 {
     group = db.Quotation_Group.Where(x => x.ProjectId == group.ProjectId && x.SettlementChk == group.SettlementChk).FirstOrDefault();
     return(Json(new { Data = group }));
 }