// GET: ProjectCharge/Details/5 public ActionResult Details(int?id, string action) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } var test = from ad in ab.vw_gxprojectProfile where (ad.projectID == id) select ad; vw_gxprojectProfile gxprojectProfile = test.First(); if (gxprojectProfile == null) { return(HttpNotFound()); } if (action == "返回") { return(RedirectToAction("projectchargeindex", "gxProjectCharge")); } return(View(gxprojectProfile)); }
public ActionResult ChargeItem(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } var test = from ad in ab.vw_gxprojectProfile where ad.projectID == id select ad; vw_gxprojectProfile charge = test.First(); long projectNo = Convert.ToInt32(charge.projectID); var ch = from c in db.vw_charge where c.searchNo == projectNo && c.fromDepartment == "7" select c; //费用转向 List <SelectListItem> list = new List <SelectListItem> { new SelectListItem { Text = "转向复印室", Value = "0" }, new SelectListItem { Text = "转向财务科", Value = "1" }, }; var classid = test.First().classifyID.Trim(); ViewBag.whereTransfer = new SelectList(list, "Value", "Text", "1"); ViewBag.classname = ab.gxClassType.Where(a => a.classTypeID == classid).First().classTypeName; if (charge.buildingArea == null) { charge.buildingArea = 0; } //显示档案馆整理费 if (charge.buildingArea < 3000) { ViewData["Urbansettle"] = 3000; } else { ViewData["Urbansettle"] = charge.buildingArea; } ViewData["Department"] = 3000; if (ch.Count() != 0) //费用已收 { ViewData["checkname"] = 1; //说明此工程费用已经收取 if (ch.First().chargeExtra == "1") //1.档案馆整理,2报送单位整理 { ViewBag.radiobutton = 1; ViewData["Urbansettle"] = ch.First().totalExpense; } else { ViewBag.radiobutton = 2; ViewData["Department"] = ch.First().totalExpense; } if (ch.First().isCharge == true)//财务科已收费,不允许业务科再修改 { ViewData["queding"] = true; } else//业务科可以修改 { ViewData["queding"] = false; } ViewData["txtremarx"] = ch.First().remarks; } return(View(charge)); }
public ActionResult SeeReceive(long?id, string action) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } List <SelectListItem> list = new List <SelectListItem> { new SelectListItem { Text = "否", Value = "false" }, new SelectListItem { Text = "是", Value = "true" }, }; var test = from ad in bb.vw_gxprojectProfile where (ad.projectID == id) select ad; ViewBag.yidi = new SelectList(list, "Value", "Text", test.First().isYD); vw_gxprojectProfile projectProfile = test.First(); string a = projectProfile.status, b = projectProfile.securityID, e = projectProfile.retentionPeriodNo; if (a != null && a != "") { switch (a.Trim()) { case "1": projectProfile.status = "接收档案"; break; case "2": projectProfile.status = "审核"; break; case "3": projectProfile.status = "通过审核"; break; case "4": projectProfile.status = "整理"; break; case "5": projectProfile.status = "编号"; break; case "6": projectProfile.status = "录入"; break; case "7": projectProfile.status = "入库"; break; case "8": projectProfile.status = "补录"; break; case "9": projectProfile.status = "等待编号"; break; case "10": projectProfile.status = "等待入库"; break; } } if (b != null && b != "") { switch (b) { case "1": projectProfile.securityID = "机密"; break; case "2": projectProfile.securityID = "秘密"; break; case "3": projectProfile.securityID = "绝密"; break; case "4": projectProfile.securityID = "一般"; break; case "5": projectProfile.securityID = "内部"; break; case "6": projectProfile.securityID = "公开/内部"; break; } } if (e != null && e != "") { switch (e) { case "1": projectProfile.retentionPeriodNo = "长期"; break; case "2": projectProfile.retentionPeriodNo = "永久"; break; case "3": projectProfile.retentionPeriodNo = "短期"; break; } } if (action == "返回") { //return RedirectToAction("StatisticalAndAnalysis"); return(RedirectToAction("AllArchives")); } if (action == "文件下载") { return(RedirectToAction("DownLoadFile", "ProjectManagement", new { id = id })); } if (projectProfile == null) { return(HttpNotFound()); } return(View(projectProfile)); }