public ActionResult DeleteConfirmed(long id)
        {
            PaperArchives paperArchives = db.PaperArchives.Find(id);

            db.PaperArchives.Remove(paperArchives);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "paperProjectSeqNo,projectNo,projectID,firstResponsible,responsibleOther,submitPerson,telphoneSubmitPerson,mobilephoneSubmitPerson,recipient,dateReceived,collator,collationRequirement,qjdyYear,qjdyNo,lqDate,mainCategoryID,subDictionaryID,minorDictionaryID,csyj,csyjPerson,csyjDate,fzryj,fzryjPerson,fzryjDate,zgyj,zgyjPerson,zgyjDate,characterVolumeCount,character2cm,character3cm,character4cm,character5cm,drawingVolumeCount,drawing2cm,drawing3cm,drawing4cm,drawing5cm,dateArchive,transferPerson,transferUnit,transferDate,passingDate,archiveCertificateNo,lqyjsDate,lqperson,transferContent,projectProfile,dateConstructed,archivesCount,InchCountDetail,originalVolumeCount,originalInchCount,originalMoneyAmount,copyInchCount,copyMoneyCount,totalMoney,startArchiveNo,endArchiveNo,startPaijiaNo,endPaijiaNo,startRegisNo,endRegisNo,licenseNo,licenseDate,jgDate,projectStartDate,projectFinishDate,changeLog,keyWords,notearea,remarks,buildingArea,height,underground,overground,structureTypeID,textMaterial,drawing,paijiaRange,prevClassNo,PhotoCount,bianhaoTime,luruTime,shizhengNoStart,shizhengNoEnd")] PaperArchives paperArchives)
 {
     if (ModelState.IsValid)
     {
         db.Entry(paperArchives).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.projectID = new SelectList(db.ProjectInfo, "projectID", "projectName", paperArchives.projectID);
     return(View(paperArchives));
 }
        // GET: PaperArchives/Details/5
        public ActionResult Details(long?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            PaperArchives paperArchives = db.PaperArchives.Find(id);

            if (paperArchives == null)
            {
                return(HttpNotFound());
            }
            return(View(paperArchives));
        }
        // GET: PaperArchives/Edit/5
        public ActionResult Edit(long?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            PaperArchives paperArchives = db.PaperArchives.Find(id);

            if (paperArchives == null)
            {
                return(HttpNotFound());
            }
            ViewBag.projectID = new SelectList(db.ProjectInfo, "projectID", "projectName", paperArchives.projectID);
            return(View(paperArchives));
        }
        [ValidateAntiForgeryToken] //传入

        public ActionResult AddArchive(long paperProjectSeqNo, string action, string registrationNo, string archivesNo, string height, string volNo, string shizhenghao, string licenseNo, string mapsheetNo, string microNo, string securityID, string retentionPeriodNo, string structureTypeID, string buildingArea, string archivesTitle, string firstResponsible, string responsibleOther, string developmentOrganization, string transferUnit, string disignOrganization, string paijiaNo, string constructionOrganization, string textMaterial, string drawing, string photoCount, string archiveThickness, string bianzhiTime, string jgDate, string heigh, string location, string remarks, string newLocation, string overground, string underground, string changeLog, string fazhaoTime, string jungongTime, string kaigongTime, string indexer, string indexDate, string checker, string checkDate, string Typist, string TyperDate)
        {
            if (action == "返回")
            {
                return(RedirectToAction("ArchiveMaga"));
            }
            var papaerarchive = from a in db.PaperArchives
                                where a.paperProjectSeqNo == paperProjectSeqNo
                                select a;
            PaperArchives paperArchives = papaerarchive.First();
            long          ID            = Convert.ToInt32(paperArchives.projectID);
            var           projectInfo   = from b in db.ProjectInfo
                                          where b.projectID == ID
                                          select b;
            ProjectInfo    projects = projectInfo.First();
            ArchivesDetail archive  = new ArchivesDetail();

            archive.registrationNo    = registrationNo;
            archive.archivesNo        = archivesNo;
            archive.paperProjectSeqNo = paperProjectSeqNo;
            if (archive.volNo.ToString().Trim() != "")
            {
                archive.volNo = Int32.Parse(archive.volNo.ToString().Trim());
            }
            archive.paijiaNo         = paijiaNo.Trim();
            archive.archiveThickness = Convert.ToInt32(archiveThickness);

            if (textMaterial.Trim() != "")
            {
                archive.textMaterial = Int32.Parse(textMaterial.Trim()); //文字材料
            }
            archive.archivesTitle    = archivesTitle;                    //案卷提名
            archive.firstResponsible = firstResponsible;                 //第一负责人

            if (drawing.Trim() != "")
            {
                archive.drawing = Int32.Parse(drawing.Trim()); //图纸
            }
            if (photoCount.Trim() != "")                       //照片
            {
                archive.photoCount = Int32.Parse(photoCount.Trim());
            }
            archive.responsibleOther = responsibleOther;//其他责任者


            archive.developmentUnit  = developmentOrganization;
            archive.constructionUnit = constructionOrganization;
            archive.designUnit       = disignOrganization;

            archive.bianzhiTime = bianzhiTime.Trim(); //编制日期
            //archive.bianzhiTime = DateTime.ParseExact(strbianzhiTime, "yyyy-MM-dd", null).Date;
            archive.transferUnit = transferUnit;      //移交单位
            archive.notearea     = location;          //附注改为工程地址
            archive.licenseNo    = licenseNo;         //执照号
            archive.shizhengNo   = shizhenghao;       //市政档案号

            archive.remarks = remarks;                //备注
            string strbiaoyinriqi = indexDate;        //标引日期

            archive.indexDate = DateTime.Parse(strbiaoyinriqi);
            archive.indexer   = indexer;//标引员


            string strshenheriqi = checkDate;//审核日期

            archive.checkDate = DateTime.Parse(strshenheriqi);
            archive.checker   = checker;              //审核员

            archive.kaigongTime = kaigongTime.Trim(); //开工日期
            archive.jungongTime = jungongTime.Trim(); //竣工日期
            archive.fazhaoTime  = fazhaoTime.Trim();  //发照日期
            archive.jgDate      = DateTime.Parse(jgDate.Trim());
            string strlururiqi = TyperDate;           //录入日期

            archive.typerDate = DateTime.Parse(strlururiqi);
            archive.typist    = Typist;//录入员

            archive.isImageExist = "无";
            if (mapsheetNo == "")
            {
                archive.mapsheetNo = "0";
            }
            else
            {
                archive.mapsheetNo = mapsheetNo;//图幅号
            }
            if (microNo == "")
            {
                archive.microNo = "0";
            }
            else
            {
                archive.microNo = microNo;//微缩号
            }



            if (ModelState.IsValid)
            {
                db.ArchivesDetail.Add(archive);


                db.SaveChanges();
            }

            if (projects != null)
            {
                if (projects.developmentOrganization.Trim() != developmentOrganization.Trim() || projects.constructionOrganization.Trim() != constructionOrganization.Trim() || projects.disignOrganization.Trim() != disignOrganization.Trim())
                {
                    if (developmentOrganization.Trim() != "")
                    {
                        projects.developmentOrganization = developmentOrganization.Trim();
                    }
                    if (constructionOrganization.Trim() != "")
                    {
                        projects.constructionOrganization = constructionOrganization.Trim();
                    }
                    if (disignOrganization.Trim() != "")
                    {
                        projects.disignOrganization = disignOrganization.Trim();
                    }
                }
                projects.securityID        = securityID.Trim();
                projects.retentionPeriodNo = retentionPeriodNo.Trim();
                projects.structureTypeID   = structureTypeID.Trim();
                projects.newLocation       = newLocation.Trim();
                if (ModelState.IsValid)
                {
                    db.Entry(projects).State = EntityState.Modified;

                    db.SaveChanges();
                }
            }
            if (paperArchives != null)
            {
                string jinguandata = paperArchives.jgDate.ToString();
                if (jinguandata != jgDate.Trim())
                {
                    paperArchives.jgDate = DateTime.Parse(jgDate.Trim());
                }
                paperArchives.buildingArea = Convert.ToDouble((buildingArea.Trim()));
                paperArchives.underground  = underground.Trim();
                paperArchives.overground   = overground.Trim();
                if (height.Trim() != "")
                {
                    paperArchives.height = Convert.ToDouble((height.Trim()));
                }
                paperArchives.luruTime          = TyperDate.Trim();
                paperArchives.projectStartDate  = kaigongTime.Trim();
                paperArchives.projectFinishDate = jungongTime.Trim();
                paperArchives.licenseNo         = licenseNo.Trim();
                paperArchives.licenseDate       = fazhaoTime.Trim();
                paperArchives.changeLog         = fazhaoTime.Trim();
                //paperArchives.changeLog = ddlChangeLog.Items[ddlChangeLog.SelectedIndex].Text;
                paperArchives.transferUnit = transferUnit;
                if (textMaterial.Trim() != "")
                {
                    if (paperArchives.textMaterial != 0)
                    {
                        paperArchives.textMaterial = paperArchives.textMaterial + Int32.Parse(textMaterial.Trim());
                    }
                    else
                    {
                        paperArchives.textMaterial = Int32.Parse(textMaterial.Trim());
                    }
                }
                if (textMaterial.Trim() != "")
                {
                    if (paperArchives.drawing != 0)
                    {
                        paperArchives.drawing = paperArchives.drawing + Int32.Parse(textMaterial.Trim());
                    }
                    else
                    {
                        paperArchives.drawing = Int32.Parse(textMaterial.Trim());
                    }
                }
                if (photoCount.Trim() != "")
                {
                    if (paperArchives.PhotoCount != 0)
                    {
                        paperArchives.PhotoCount = paperArchives.PhotoCount + Int32.Parse(photoCount.Trim());
                    }
                    else
                    {
                        paperArchives.PhotoCount = Int32.Parse(photoCount.Trim());
                    }
                }
                paperArchives.firstResponsible = firstResponsible.Trim();
                paperArchives.responsibleOther = responsibleOther.Trim();


                string shizhengno = shizhenghao;
                int    volCount   = 0;
                int.TryParse(paperArchives.archivesCount, out volCount);
                int vol = Convert.ToInt32(archive.volNo);

                if (vol == 1)
                {
                    paperArchives.shizhengNoStart = shizhengno;
                }
                if (vol == volCount)
                {
                    paperArchives.shizhengNoEnd = shizhengno;
                }
                if (ModelState.IsValid)
                {
                    db.Entry(paperArchives).State = EntityState.Modified;
                    db.SaveChanges();
                    return(JavaScript("保存成功"));
                }
            }


            return(View());
        }
        public ActionResult SeeSettle([Bind(Include = "InchCountDetail,characterVolumeCount,character1cm,character2cm,character3cm,character4cm,character5cm,originalVolumeCount,originalInchCount,drawingVolumeCount,drawing1cm,drawing2cm,drawing3cm,drawing4cm,drawing5cm,copyInchCount")] vw_archiveQueryList archiveQueryList, string action, long?id, string id2)
        {
            var paper = from ad in db.PaperArchives
                        where (ad.projectID == id)
                        select ad;
            PaperArchives paperArchive = paper.First();
            var           project      = from ac in db.ProjectInfo
                                         where (ac.projectID == id)
                                         select ac;
            ProjectInfo projectinfo = project.First();

            paperArchive.InchCountDetail = archiveQueryList.InchCountDetail;
            paperArchive.character1cm    = archiveQueryList.character1cm;
            paperArchive.character2cm    = archiveQueryList.character2cm;
            paperArchive.character3cm    = archiveQueryList.character3cm;
            paperArchive.character4cm    = archiveQueryList.character4cm;
            paperArchive.character5cm    = archiveQueryList.character5cm;
            //ViewData["characterVolumeCount"] = archiveQueryList.character2cm + archiveQueryList.character3cm + archiveQueryList.character4cm + archiveQueryList.character5cm;
            paperArchive.characterVolumeCount = archiveQueryList.character1cm + archiveQueryList.character2cm + archiveQueryList.character3cm + archiveQueryList.character4cm + archiveQueryList.character5cm;
            paperArchive.drawing1cm           = archiveQueryList.drawing1cm;
            paperArchive.drawing2cm           = archiveQueryList.drawing2cm;
            paperArchive.drawing3cm           = archiveQueryList.drawing3cm;
            paperArchive.drawing4cm           = archiveQueryList.drawing4cm;
            paperArchive.drawing5cm           = archiveQueryList.drawing5cm;
            //ViewData["drawingVolumeCount"] = archiveQueryList.drawing2cm + archiveQueryList.drawing3cm + archiveQueryList.drawing4cm + archiveQueryList.drawing5cm;
            paperArchive.drawingVolumeCount = archiveQueryList.drawing1cm + archiveQueryList.drawing2cm + archiveQueryList.drawing3cm + archiveQueryList.drawing4cm + archiveQueryList.drawing5cm;
            //ViewData["originalVolumeCount"] = paperArchive.characterVolumeCount + paperArchive.drawingVolumeCount;
            //ViewData["originalInchCount"] = (archiveQueryList.character2cm + archiveQueryList.drawing2cm) * 2 + (archiveQueryList.character3cm + archiveQueryList.drawing3cm) * 3 + (archiveQueryList.character4cm + archiveQueryList.drawing4cm) * 4 + (archiveQueryList.character5cm + archiveQueryList.drawing5cm) * 5;
            paperArchive.originalVolumeCount = archiveQueryList.character2cm + archiveQueryList.character3cm + archiveQueryList.character4cm + archiveQueryList.character5cm + archiveQueryList.drawing2cm + archiveQueryList.drawing3cm + archiveQueryList.drawing4cm + archiveQueryList.drawing5cm;
            paperArchive.originalInchCount   = (archiveQueryList.character2cm + archiveQueryList.drawing2cm) * 2 + (archiveQueryList.character3cm + archiveQueryList.drawing3cm) * 3 + (archiveQueryList.character4cm + archiveQueryList.drawing4cm) * 4 + (archiveQueryList.character5cm + archiveQueryList.drawing5cm) * 5;
            paperArchive.copyInchCount       = archiveQueryList.copyInchCount;
            paperArchive.archivesCount       = (paperArchive.characterVolumeCount + paperArchive.drawingVolumeCount).ToString();

            if (action == "修改")
            {
                if (Convert.ToInt32(projectinfo.status) == 3 || Convert.ToInt32(projectinfo.status) == 5)
                {
                    ViewData["onlyread"] = false;
                }
                else
                {
                    ViewData["onlyread"] = true;
                }
                if (Convert.ToInt32(projectinfo.status) == 4)
                {
                    projectinfo.status = "9";
                }

                if (ModelState.IsValid)
                {
                    db.Entry(paperArchive).State = EntityState.Modified;
                    db.Entry(projectinfo).State  = EntityState.Modified;
                    db.SaveChanges();
                    if (id2 == "1")
                    {
                        return(Content("<script >alert('修改成功');window.location.href='../StatisticalAndRetrieval/StatisticalAndAnalysis';</script >"));
                    }
                    if (id2 == "2")
                    {
                        return(Content("<script >alert('修改成功');window.location.href='../StatisticalAndRetrieval/AllArchives';</script >"));
                    }
                }
            }


            if (action == "返回")
            {
                if (id2 == "2")
                {
                    return(RedirectToAction("AllArchives"));
                }
                else
                {
                    return(RedirectToAction("StatisticalAndAnalysis"));
                }
            }
            return(View());
        }
Exemple #7
0
        [ValidateAntiForgeryToken] //传入
        public ActionResult FaFangHeGeZheng(string archiveCertificateNo, long projectID, string workUnit, string lingquPerson, string contractTel, string fafangPeroson, DateTime?lingquDate, string isFafangHegezheng, string action)
        {
            if (action == "返回")
            {
                return(RedirectToAction("MeterialsSend"));
            }

            var project = from b in db.ProjectInfo
                          where b.projectID == projectID
                          select b;
            ProjectInfo d            = project.First();
            var         paperArchive = from f in db.PaperArchives
                                       where f.projectID == projectID
                                       select f;
            PaperArchives g = paperArchive.First();

            if (action == "确定")
            {
                FafangArchiveCertificate fafang = new FafangArchiveCertificate();
                fafang.workUnit      = workUnit;
                fafang.lingquPerson  = lingquPerson;
                fafang.contractTel   = contractTel;
                fafang.fafangPeroson = fafangPeroson;
                string str = Convert.ToDateTime(lingquDate).ToString("yyyy-MM-dd");
                fafang.lingquDate = DateTime.ParseExact(str.Trim(), "yyyy-MM-dd", null).Date;
                fafang.projectID  = projectID;
                var maxid = db.FafangArchiveCertificate.Max(a => a.ID);
                fafang.ID              = maxid + 1;
                d.isFafangHegezheng    = true;
                g.archiveCertificateNo = archiveCertificateNo;
                db.FafangArchiveCertificate.Add(fafang);
                db.Entry(d).State = EntityState.Modified;
                db.Entry(g).State = EntityState.Modified;
                db.SaveChanges();
                return(Content("<script >alert('确认成功');window.location.href='../LaterMaterials/MeterialsSend';</script >"));
            }
            if (action == "更新")
            {
                var vwArchiveList = from a in db.FafangArchiveCertificate
                                    where a.projectID == projectID
                                    select a;
                FafangArchiveCertificate c = vwArchiveList.First();
                if (vwArchiveList.Count() == 0)
                {
                    return(Content("<script >alert('请先领取');window.history.back();</script >"));
                }
                c.workUnit      = workUnit;
                c.lingquPerson  = lingquPerson.Trim();
                c.contractTel   = contractTel.Trim();
                c.fafangPeroson = fafangPeroson.Trim();
                string str = Convert.ToDateTime(lingquDate).ToString("yyyy-MM-dd");
                c.lingquDate = DateTime.ParseExact(str.Trim(), "yyyy-MM-dd", null).Date;

                if (isFafangHegezheng.ToString() == "True")
                {
                    d.isFafangHegezheng = true;
                }
                else
                {
                    d.isFafangHegezheng = false;
                }
                db.Entry(c).State = EntityState.Modified;
                db.Entry(d).State = EntityState.Modified;
                db.SaveChanges();
                return(Content("<script >alert('修改成功');window.history.back();</script >"));
            }


            return(View());
        }
Exemple #8
0
        public ActionResult Index(int id, string uuid)
        {
            //string uuid = "297d413364dc4e7d81e5858c1bfcfbb5";
            var test = from ad in db.ArchivesDetail
                       where (ad.UUID == uuid)
                       select ad;

            if (test.Count() == 0)
            {
                var test1 = from ad in bb.gxArchivesDetail
                            where (ad.UUID == uuid)
                            select ad;

                if (test1.Count() == 0)
                {
                    return(HttpNotFound());;
                }
                //管线数据
                gxArchivesDetail gxArchivesDetail  = test1.First();
                long             paperProjectSeqNo = gxArchivesDetail.paperProjectSeqNo;
                var n = from a in bb.gxPaperArchives
                        where a.paperProjectSeqNo == paperProjectSeqNo
                        select a;
                gxPaperArchives gxPaperArchives = n.First();

                var n1 = from a in bb.gxProjectInfo
                         where a.projectID == gxPaperArchives.projectID
                         where a.isNB == "外部"
                         select a;
                gxProjectInfo gxProjectInfo = n1.First();

                ViewBag.projectName              = gxProjectInfo.projectName;              //工程名称
                ViewBag.location                 = gxProjectInfo.location;                 //工程地点
                ViewBag.developmentOrganization  = gxProjectInfo.developmentOrganization;  //建设单位
                ViewBag.devolonpentOrgContacter  = gxProjectInfo.devolonpentOrgContacter;  //建设单位联系人
                ViewBag.mobilephoneNoDevelopment = gxProjectInfo.mobilephoneNoDevelopment; //建设单位联系人电话

                ViewBag.constructionOrganization = gxProjectInfo.constructionOrganization; //施工单位
                ViewBag.constructionOrgContacter = gxProjectInfo.constructionOrgContacter; //施工单位法人
                ViewBag.telphoneNoDevelopment    = gxProjectInfo.telphoneNoDevelopment;    //施工单位电话

                ViewBag.disignOrganization   = gxProjectInfo.disignOrganization;           //设计单位
                ViewBag.designOrgaContacter  = gxProjectInfo.designOrgaContacter;          //设计单位联系人
                ViewBag.telphoneNoDesignOrga = gxProjectInfo.telphoneNoDesignOrga;         //设计者

                ViewBag.jianliUnit           = gxProjectInfo.jianliUnit;                   //监理单位
                ViewBag.jianliUnitContacter  = gxProjectInfo.jianliUnitContacter;          //监理单位负责人
                ViewBag.telphoneNoJianliUnit = gxProjectInfo.telphoneNoJianliUnit;         //监理者

                ViewBag.Kcdw     = gxProjectInfo.Kcdw;                                     //勘察单位
                ViewBag.Kcdwlxr  = gxProjectInfo.Kcdwlxr;                                  //勘察单位负责人
                ViewBag.Kcdwlxdh = gxProjectInfo.Kcdwlxdh;                                 //勘察单位电话


                //ViewBag.jgdate = Convert.ToDateTime(gxArchivesDetail.jgDate).ToString("yyyy-MM-dd");//进馆时间
                ViewBag.kaigongTime      = Convert.ToDateTime(gxArchivesDetail.kaigongTime).ToString("yyyy-MM-dd"); //开工时间
                ViewBag.jungongTime      = Convert.ToDateTime(gxArchivesDetail.jungongTime).ToString("yyyy-MM-dd"); //竣工时间
                ViewBag.archivesTitle    = gxArchivesDetail.archivesTitle;                                          //案卷题名
                ViewBag.firstResponsible = gxArchivesDetail.firstResponsible;                                       //责任者
                ViewBag.bianzhiTime      = gxArchivesDetail.bianzhiTime;                                            //编制时间
                ViewBag.indexer          = gxArchivesDetail.indexer;                                                //立卷人
                ViewBag.indexDate        = Convert.ToDateTime(gxArchivesDetail.indexDate).ToString("yyyy-MM-dd");;  //立卷时间
                ViewBag.key1             = gxArchivesDetail.key1;                                                   //主题词
                ViewBag.remarks          = gxArchivesDetail.remarks;                                                //备注

                var gxfileInfo = from ad in bb.gxFileInfo
                                 select ad;
                gxfileInfo     = gxfileInfo.Where(ad => ad.archivesNo.ToString().Equals(gxArchivesDetail.archivesNo));//根据档号搜索
                gxfileInfo     = gxfileInfo.OrderBy(s => s.ID).Take(1000);
                ViewBag.result = JsonConvert.SerializeObject(gxfileInfo);
                return(View());
            }
            else
            {
                //竣工数据
                ArchivesDetail ArchivesDetail    = test.First();
                long           paperProjectSeqNo = ArchivesDetail.paperProjectSeqNo;
                var            n = from a in db.PaperArchives
                                   where a.paperProjectSeqNo == paperProjectSeqNo
                                   select a;
                if (n.Count() == 0)
                {
                    return(Content("<script >alert('找不到工程文件!');</script >"));
                }
                PaperArchives PaperArchives = n.First();

                var n1 = from a in db.ProjectInfo
                         where a.projectID == PaperArchives.projectID
                         select a;
                ProjectInfo ProjectInfo = n1.First();

                ViewBag.projectName              = ProjectInfo.projectName;              //工程名称
                ViewBag.location                 = ProjectInfo.location;                 //工程地点
                ViewBag.developmentOrganization  = ProjectInfo.developmentOrganization;  //建设单位
                ViewBag.devolonpentOrgContacter  = ProjectInfo.devolonpentOrgContacter;  //建设单位联系人
                ViewBag.mobilephoneNoDevelopment = ProjectInfo.mobilephoneNoDevelopment; //建设单位联系人电话

                ViewBag.constructionOrganization = ProjectInfo.constructionOrganization; //施工单位
                ViewBag.constructionOrgContacter = ProjectInfo.constructionOrgContacter; //施工单位法人
                ViewBag.telphoneNoDevelopment    = ProjectInfo.telphoneNoDevelopment;    //施工单位电话

                ViewBag.disignOrganization   = ProjectInfo.disignOrganization;           //设计单位
                ViewBag.designOrgaContacter  = ProjectInfo.designOrgaContacter;          //设计单位联系人
                ViewBag.telphoneNoDesignOrga = ProjectInfo.telphoneNoDesignOrga;         //设计者

                ViewBag.jianliUnit           = ProjectInfo.jianliUnit;                   //监理单位
                ViewBag.jianliUnitContacter  = ProjectInfo.jianliUnitContacter;          //监理单位负责人
                ViewBag.telphoneNoJianliUnit = ProjectInfo.telphoneNoJianliUnit;         //监理者

                ViewBag.Kcdw     = ProjectInfo.Kcdw;                                     //勘察单位
                ViewBag.Kcdwlxr  = ProjectInfo.Kcdwlxr;                                  //勘察单位负责人
                ViewBag.Kcdwlxdh = ProjectInfo.Kcdwlxdh;                                 //勘察单位电话


                //ViewBag.jgdate = Convert.ToDateTime(ArchivesDetail.jgDate).ToString("yyyy-MM-dd");//进馆时间
                ViewBag.kaigongTime      = Convert.ToDateTime(ArchivesDetail.kaigongTime).ToString("yyyy-MM-dd"); //开工时间
                ViewBag.jungongTime      = Convert.ToDateTime(ArchivesDetail.jungongTime).ToString("yyyy-MM-dd"); //竣工时间
                ViewBag.archivesTitle    = ArchivesDetail.archivesTitle;                                          //案卷题名
                ViewBag.firstResponsible = ArchivesDetail.firstResponsible;                                       //责任者
                ViewBag.bianzhiTime      = ArchivesDetail.bianzhiTime;                                            //编制时间
                ViewBag.indexer          = ArchivesDetail.indexer;                                                //立卷人
                ViewBag.indexDate        = Convert.ToDateTime(ArchivesDetail.indexDate).ToString("yyyy-MM-dd");;  //立卷时间
                ViewBag.key1             = ArchivesDetail.key1;                                                   //主题词
                ViewBag.remarks          = ArchivesDetail.remarks;                                                //备注

                var fileInfo = from ad in db.FileInfo
                               select ad;
                fileInfo       = fileInfo.Where(ad => ad.archivesNo.ToString().Equals(ArchivesDetail.archivesNo));//根据档号搜索
                fileInfo       = fileInfo.OrderBy(s => s.id).Take(1000);
                ViewBag.result = JsonConvert.SerializeObject(fileInfo);

                if (ArchivesDetail == null)
                {
                    return(HttpNotFound());
                }
                return(View());
            }
        }