From c2590420385b738d61d3f268537ca39dd65a966e Mon Sep 17 00:00:00 2001 From: hodong13 Date: Tue, 13 Oct 2020 07:10:18 +0000 Subject: [PATCH] --- BO/Controllers/cmController.cs | 2 +- BO/Controllers/dataController.cs | 2 +- BO/Views/Shared/Partial/Radio.cshtml | 2 +- BO/Views/cm/cmreg.cshtml | 5 +- BO/Views/data/fees.cshtml | 2 +- Dao/DB/DB1.Scheme.txt | 6 +- Dao/DB/DB1.SchemeFK.txt | 1 + Dao/DB/DB2.CommonData.txt | 5 +- Dao/MyBatis/Maps/CM.xml | 4 + Dao/MyBatis/Maps/CRoom.xml | 182 ++++++++++++++------------- Dao/MyBatis/Maps/Lect.xml | 67 +++++----- Dao/MyBatis/Maps/System.xml | 7 ++ FO/Controllers/CRoomController.cs | 2 +- FO/Views/CRoom/Plan.cshtml | 4 +- FO/Views/Course/CertDetail.cshtml | 4 +- FO/Views/Course/CoverDetail.cshtml | 4 +- FO/Views/Course/OffDetail.cshtml | 4 +- FO/Views/Course/OffList.cshtml | 2 +- FO/Views/Course/OnDetail.cshtml | 4 +- Model/CM.cs | 5 +- 20 files changed, 172 insertions(+), 142 deletions(-) diff --git a/BO/Controllers/cmController.cs b/BO/Controllers/cmController.cs index 8d70af2..b6a06c5 100644 --- a/BO/Controllers/cmController.cs +++ b/BO/Controllers/cmController.cs @@ -128,7 +128,7 @@ namespace NP.BO.Controllers vm.CGs = Dao.Get("cm.cgs", new System.Collections.Hashtable() { { "istop", 1 }, { "isdel", 0 }, { "isuse", 1 } }); } vm.Assigns = Dao.Get("users.assigns", new System.Collections.Hashtable() { { "status", 1 }, { "ismain", 1 } }); - vm.ComCodes = GetComCodes("cert,certgrade,job"); + vm.ComCodes = GetComCodes("cert,certgrade,job,studyplace"); vm.userauths = Dao.Get("sys.menu.auths",new System.Collections.Hashtable() { {"isadminprof", 1 } }); return View("cmreg", vm); } diff --git a/BO/Controllers/dataController.cs b/BO/Controllers/dataController.cs index 93e9577..569485f 100644 --- a/BO/Controllers/dataController.cs +++ b/BO/Controllers/dataController.cs @@ -371,7 +371,7 @@ namespace NP.BO.Controllers { return ExportExcel( new String[] { "순번", "상위분류","과정분류", "교육명", "교육일", "교육시간", "교육장명", "강사명", "회원가", "비회원가", "회원사", "비회원사", "회원", "비회원", "교육장사용료", "강사료", "교재인쇄비", "음료및다과", "소모품비", "식대", "기타", "인쇄부수", "전체인원", "담당" }, - new String[] { "rno", "pcgname", "cgname", "cnameclassno", "sssename", "itime", "studyplace", "profnames", "infee", "outfee", "infeetotal", "outfeetotal", "incount", "outcount", "feeloc", + new String[] { "rno", "pcgname", "cgname", "cnameclassno", "sssename", "itime", "studyplacename", "profnames", "infee", "outfee", "infeetotal", "outfeetotal", "incount", "outcount", "feeloc", "pfee", "feebkpr", "feebrt", "feemat", "feefoo", "feeetc", "prtcnt", "totcount", "managers" }, vm.CMCalcs, vm.excelname); diff --git a/BO/Views/Shared/Partial/Radio.cshtml b/BO/Views/Shared/Partial/Radio.cshtml index 1af1f67..4f004a9 100644 --- a/BO/Views/Shared/Partial/Radio.cshtml +++ b/BO/Views/Shared/Partial/Radio.cshtml @@ -64,6 +64,6 @@ else { foreach (var item in Model) { -   +   } } diff --git a/BO/Views/cm/cmreg.cshtml b/BO/Views/cm/cmreg.cshtml index 30eb79f..5844487 100644 --- a/BO/Views/cm/cmreg.cshtml +++ b/BO/Views/cm/cmreg.cshtml @@ -128,8 +128,9 @@
- @Html.TextBoxFor(m => m.CM.studyplace, new { @class = "form-control disp-init", @style = "width: 300px;", @maxlength = "150", @placeholder = "" }) - * 유형이 온라인일 경우 출력되지 않음 + @*@Html.TextBoxFor(m => m.CM.studyplace, new { @class = "form-control disp-init", @style = "width: 300px;", @maxlength = "150", @placeholder = "" })*@ + @Html.Partial("./Partial/Radio", Model.ComCodes.Where(w => w.cgroup == "studyplace"), new ViewDataDictionary() { { "checked", Model.CM.studyplace }, { "name", "CM.studyplace" } }) + ※ 유형이 온라인일 경우 출력되지 않음
diff --git a/BO/Views/data/fees.cshtml b/BO/Views/data/fees.cshtml index 9a5fcc7..46f1da0 100644 --- a/BO/Views/data/fees.cshtml +++ b/BO/Views/data/fees.cshtml @@ -62,7 +62,7 @@ @item.cnameclassno @item.sssename @item.itime - @item.studyplace + @item.studyplacename @Html.Raw(item.profnames ?? "") @item.infee.ToString("#,0") @item.outfee.ToString("#,0") diff --git a/Dao/DB/DB1.Scheme.txt b/Dao/DB/DB1.Scheme.txt index 559c57b..df06644 100644 --- a/Dao/DB/DB1.Scheme.txt +++ b/Dao/DB/DB1.Scheme.txt @@ -385,7 +385,7 @@ create table cm ( ,targethtml text ,goalhtml text ,contenthtml mediumtext - ,studyplace varchar (200) + ,studyplace smallint null ,studytime smallint not null ,certcc smallint ,certgradecc smallint @@ -397,6 +397,10 @@ create table cm ( ,isseq tinyint not null default 1 ,fgnocm bigint null ,fgno bigint + ,typeman varchar(100) null + ,typeedu varchar(100) null + ,typegrade varchar(100) null + ,typejob varchar(100) null ,isdel tinyint not null ,cdt datetime not null,cno bigint not NULL,udt datetime not null,uno bigint not NULL,uip varchar(50) not NULL ,primary key(cmno)); diff --git a/Dao/DB/DB1.SchemeFK.txt b/Dao/DB/DB1.SchemeFK.txt index 75e3d91..49e54d7 100644 --- a/Dao/DB/DB1.SchemeFK.txt +++ b/Dao/DB/DB1.SchemeFK.txt @@ -43,6 +43,7 @@ alter table cm add constraint foreign key fkcmcm(pcmno) references cm(cmno); alter table cm add constraint foreign key fkcmterm (tmno) references term(tmno); alter table cm add constraint foreign key fkcmcc(certcc) references comcode(ccode); alter table cm add constraint foreign key fkcmcc2(certgradecc) references comcode(ccode); +alter table cm add constraint foreign key fkcmccsp(studyplace) references comcode(ccode); alter table cmrelay add constraint foreign key fkcmrelaycm (cmno) references cm(cmno); alter table cmrelay add constraint foreign key fkcmrelaycm2 (rcmno) references cm(cmno); alter table cmncsd add constraint foreign key fkcmncsdcm(cmno) references cm(cmno); diff --git a/Dao/DB/DB2.CommonData.txt b/Dao/DB/DB2.CommonData.txt index a44d445..7b807fe 100644 --- a/Dao/DB/DB2.CommonData.txt +++ b/Dao/DB/DB2.CommonData.txt @@ -56,5 +56,8 @@ insert into comcode(cname, cgroup, cgroupname, isuse, corder,refcode,cdt,cno,udt ('법무','askey','회원주요사키워드',1,7,null,now(),1,now(),1,'127.0.0.1'), ('롯데','askey','회원주요사키워드',1,8,null,now(),1,now(),1,'127.0.0.1'); - +insert into comcode(cname, cgroup, cgroupname, isuse, corder,refcode,cdt,cno,udt,uno,uip) VALUES + ('부산','studyplace','학습장소',1,1,null,now(),1,now(),1,'127.0.0.1'), + ('영천','studyplace','학습장소',1,2,null,now(),1,now(),1,'127.0.0.1'), + ('진주','studyplace','학습장소',1,3,null,now(),1,now(),1,'127.0.0.1'); diff --git a/Dao/MyBatis/Maps/CM.xml b/Dao/MyBatis/Maps/CM.xml index aeca758..03a0640 100644 --- a/Dao/MyBatis/Maps/CM.xml +++ b/Dao/MyBatis/Maps/CM.xml @@ -164,6 +164,7 @@ inner join cg a2 on a2.cgno=a.cgno inner join cg a3 on a3.cgno=a2.pcgno inner join term b on b.tmno=a.tmno + left outer join comcode cc on cc.ccode=a.studyplace where a.cmno=#cmno# @@ -1544,6 +1545,7 @@ ,case when j.ctype < 2 then concat(#contents#,'/', j.ccode, '/', k.srcp) else k.srcp end tasteurlpc ,case when j.ctype < 2 then concat(#contents#,'/', j.ccode, '/', k.srcm) else k.srcm end tasterurlmobile ,m.cname certgradeccname + ,cc.cname studyplacename ,max(case when e.lectno is null then 0 else 1 end) isrequested ,count(f.userno) countlect from cm a @@ -1563,6 +1565,7 @@ left outer join fileinfo jf2 on jf2.fgno=j2.fgnothumb and jf2.isdel=0 left outer join ctpage k on k.ctno=j.ctno and k.pseq=1 left outer join comcode m on m.ccode=a.certgradecc + left outer join comcode cc on cc.ccode=a.studyplace where a.ismaster=0 and a.isuse=1 and a.isdel=0 and a.cmno=#cmno# and year(a.sstime)=#year# @@ -1575,6 +1578,7 @@ ,h.isjoin ,i.cmino ,j.ccode,j.ctype,k.srcp,k.srcm,m.cname + ,cc.cname having count(d.lectno) < a.quota or a.quota=0 order by $orderby$a.sstime,a.setime diff --git a/Dao/MyBatis/Maps/CRoom.xml b/Dao/MyBatis/Maps/CRoom.xml index 3cbc796..90d0547 100644 --- a/Dao/MyBatis/Maps/CRoom.xml +++ b/Dao/MyBatis/Maps/CRoom.xml @@ -46,95 +46,99 @@