diff --git a/WebContent/WEB-INF/templates/schedule.ftl b/WebContent/WEB-INF/templates/schedule.ftl index 3456c175b21b76fdf9b5cd58fb8a8382d43c136a..cafcf175c1ced8efb11019069541d0d45215cd9c 100644 --- a/WebContent/WEB-INF/templates/schedule.ftl +++ b/WebContent/WEB-INF/templates/schedule.ftl @@ -5,17 +5,17 @@ Administrator nsow'notepad -2 -1 -2019-04-11T08:26:00Z -2019-04-11T08:26:00Z +3 +0 +2019-04-11T13:53:00Z +2019-04-11T13:53:00Z 1 -43 -248 +107 +611 china -2 +5 1 -290 +717 15 @@ -6840,11 +6840,10 @@ - + - @@ -6866,14 +6865,14 @@ - + - + @@ -6882,14 +6881,14 @@ - + - + @@ -6929,8 +6928,10 @@ + + @@ -6939,15 +6940,19 @@ + + + + @@ -6970,6 +6975,7 @@ + @@ -6995,6 +7001,7 @@ + @@ -7002,18 +7009,20 @@ - + + + @@ -7023,6 +7032,7 @@ + @@ -7053,6 +7063,7 @@ + @@ -7076,7 +7087,7 @@ - + @@ -7085,6 +7096,7 @@ + @@ -7100,6 +7112,7 @@ + @@ -7126,6 +7139,7 @@ + @@ -7217,6 +7231,7 @@ + @@ -7238,12 +7253,14 @@ + + @@ -7256,10 +7273,12 @@ + + @@ -7304,6 +7323,7 @@ + @@ -7311,6 +7331,7 @@ + @@ -7403,14 +7424,14 @@ - - - - + + + + - + @@ -7741,7 +7762,7 @@ - + @@ -7774,7 +7795,7 @@ - + @@ -7928,7 +7949,7 @@ - + @@ -8062,7 +8083,7 @@ - + @@ -8094,7 +8115,7 @@ - + @@ -8126,7 +8147,7 @@ - + @@ -8158,7 +8179,7 @@ - + @@ -8220,8 +8241,9 @@ -<#list maps as map> - +<#list semester1.course as course> +<#if course_index==0> + @@ -8233,21 +8255,21 @@ - + - + - + - + @@ -8368,7 +8390,7 @@ - + @@ -8391,7 +8413,7 @@ -1 +${course.identifier} @@ -8401,7 +8423,7 @@ - + @@ -8423,7 +8445,7 @@ -${map.name} +${course.name} @@ -8455,7 +8477,7 @@ - + @@ -8478,17 +8500,17 @@ -s +${course.score} - + - + @@ -8511,17 +8533,17 @@ -Time +${course.time} - + - + @@ -8535,28 +8557,26 @@ - - + -th +${course.theoretical} - - + - + @@ -8579,17 +8599,17 @@ -ex +${course.experiement} - + - + @@ -8603,19 +8623,17 @@ - - + -hpw +${course.hpw} - @@ -8646,7 +8664,7 @@ - + @@ -8662,20 +8680,31 @@ - + -f-l +${course.start}-${course.end} + + + + + + + + + + + - - +<#elseif course_index!=0> + @@ -8687,7 +8716,7 @@ - + @@ -8706,11 +8735,13 @@ + - + + @@ -8724,56 +8755,66 @@ - - + - + + - + - + - - - + + + - +${course.identifier} - + + + + + + + + + + + + - - - + + + - - - + + - + - + - +${course.name} @@ -8783,15 +8824,16 @@ - + + - + @@ -8804,14 +8846,14 @@ - + + - @@ -8827,17 +8869,17 @@ -s1 +${course.score} - + - + @@ -8845,7 +8887,6 @@ - @@ -8856,23 +8897,22 @@ - -time1 +${course.time} - + - + @@ -8880,7 +8920,6 @@ - @@ -8891,35 +8930,22 @@ - - - - - - -t - - - - - - -h1 +${course.theoretical} - + - + @@ -8927,7 +8953,6 @@ - @@ -8936,37 +8961,24 @@ - - - - - - - - -e - - - - -x1 +${course.experiement} - + - + @@ -8974,7 +8986,6 @@ - @@ -8985,25 +8996,12 @@ - - - - - - -h - - - - - - -pw1 +${course.hpw} @@ -9013,7 +9011,7 @@ - + @@ -9021,8 +9019,8 @@ - + @@ -9035,23 +9033,48 @@ - + + - + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + - + + + @@ -9063,7 +9086,7 @@ - + @@ -9080,15 +9103,13 @@ - + - - + - @@ -9098,70 +9119,61 @@ - - - - - - - - -春季学期 - - + + - + - + - - + - + + + + + + + + + + + + + - -2 + - - - - - - - - - - - - + - + + - - + + @@ -9170,16 +9182,15 @@ - + - + - @@ -9192,7 +9203,7 @@ - + @@ -9200,43 +9211,34 @@ + - - - - - - - - - - - - - + - + + - +${semester1.total.score} + - + - + @@ -9244,43 +9246,34 @@ + - - - - - - - - - - - - - + + - +${semester1.total.time} + - + - + @@ -9288,43 +9281,34 @@ + - - - - - - - - - - - - - + - - + + + - +${semester1.total.theoretical} + - + - + @@ -9332,16 +9316,109 @@ + + + + + + + + + + + +${semester1.total.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester1.total.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - +<#list semester2.course as course> +<#if course_index==0> + @@ -9353,7 +9430,7 @@ - + @@ -9370,13 +9447,15 @@ - + + - + + @@ -9386,90 +9465,211 @@ + + + + + + + + +春季学期 + - - + - + + - + - + - + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + - + - + + + + + + + + + + +${course.name} - + + + + + + + + + + + + + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} - + + + + + + + + + + + + + - - + + - + + + + + + + + + + +${course.time} - + - + + + + + + + + + + + + +${course.theoretical} + - + - + @@ -9477,22 +9677,32 @@ - + + + + + + + + + +${course.experiement} + - + - + @@ -9500,22 +9710,32 @@ - + + + + + + + + + +${course.hpw} + - + - + @@ -9523,22 +9743,6873 @@ - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + +<#elseif course_index!=0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester2.total.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester2.total.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester2.total.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester2.total.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester2.total.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +<#list semester3.course as course> +<#if course_index==0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +秋季学期 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + +<#elseif course_index!=0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester3.total.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester3.total.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester3.total.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester3.total.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester3.total.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +<#list semester4.course as course> +<#if course_index==0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +春季学期 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + +<#elseif course_index!=0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester4.total.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester4.total.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester4.total.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester4.total.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester4.total.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +软件工程 + + + + + + + + + + + +本科专业 + + + + + + + + + + + +人才 + + + + + + + + + + + +培养方案实施进程表 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +学期 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +课程 + + + + + + + + + + + + + + + + + + + + + + + + +代码 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +课程名称 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +是否 + + + + + + + + + + + + + + + + + + + + + + + + +核心 + + + + + + + + + + + + + + + + + + + + + + + + +课程 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +学分 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +学时 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +周学时 + + + + + + + + + + + + + + + + + + + + + + + + + + + + +(课内) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +考核 + + + + + + + + + + + + + + + + + + + + + + + + +方式 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +备注 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +总学时 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +讲课 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +实践 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +<#list semester5.course as course> +<#if course_index==0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +秋季学期 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + +<#elseif course_index!=0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester5.total.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester5.total.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester5.total.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester5.total.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester5.total.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +<#list semester6.course as course> +<#if course_index==0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +春季学期 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + +<#elseif course_index!=0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester6.total.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester6.total.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester6.total.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester6.total.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${semester6.total.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +<#list semester7.course as course> +<#if course_index==0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +秋季学期 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.experiement} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.hpw} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + + + + +<#elseif course_index!=0> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.identifier} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.score} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.time} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +${course.theoretical} + - + - + @@ -9546,22 +16617,32 @@ - + + + + + + + + + +${course.experiement} + - + - + @@ -9569,13 +16650,23 @@ - + + + + + + + + + +${course.hpw} + @@ -9584,13 +16675,16 @@ - + + - + + + @@ -9603,39 +16697,63 @@ - + + - + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + - + + + + - + - - + - @@ -9645,98 +16763,112 @@ - + + + + + + + + + + + + + - + - - - + + + + + + + + + + + + + + + - - + + - + + - + + - + - - + - - + - - + + - - - - - - - - -秋季学期 - - + - + @@ -9744,6 +16876,7 @@ + @@ -9754,65 +16887,58 @@ + -3 +${semester7.total.score} - + - + + - - + + + - - - - - - - - - - - - - + + - +${semester7.total.time} + - + - + @@ -9820,43 +16946,34 @@ + - - - - - - - - - - - - - + + - +${semester7.total.theoretical} + - + - + @@ -9864,21 +16981,34 @@ + + + + + + + + + + + +${semester7.total.experiement} + - + - + @@ -9886,34 +17016,25 @@ + - - - - - - - - - - - - - + + - +${semester7.total.hpw} + @@ -9922,7 +17043,7 @@ - + @@ -9930,8 +17051,8 @@ + - @@ -9944,16 +17065,15 @@ - + - - - + + + - @@ -9961,10 +17081,11 @@ - +<#list semester8.course as course> +<#if course_index==0> + - @@ -9974,7 +17095,7 @@ - + @@ -9991,13 +17112,15 @@ - + + - + + @@ -10007,60 +17130,80 @@ + + + + + + + + +春季学期 + - - + - + + - + - + - - - + + + - +${course.identifier} - + + + + + + + + + + + + - - - + + + - - - + + - + - + - +${course.name} @@ -10070,15 +17213,16 @@ - + + - + @@ -10091,7 +17235,7 @@ - + @@ -10099,22 +17243,32 @@ - + + + + + + + + + +${course.score} + - + - + @@ -10122,22 +17276,32 @@ - + + + + + + + + + +${course.time} + - + - + @@ -10145,22 +17309,32 @@ - + + + + + + + + + +${course.theoretical} + - + - + @@ -10168,22 +17342,32 @@ - + + + + + + + + + +${course.experiement} + - + - + @@ -10191,13 +17375,23 @@ - + + + + + + + + + +${course.hpw} + @@ -10206,16 +17400,18 @@ - + + + - - - + + - - + + + @@ -10226,23 +17422,47 @@ - + + - + + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + - +<#elseif course_index!=0> + @@ -10254,7 +17474,7 @@ - + @@ -10271,12 +17491,12 @@ - + - + @@ -10289,16 +17509,6 @@ - - - - - - - - -春季学期 - @@ -10307,7 +17517,7 @@ - + @@ -10330,7 +17540,7 @@ -4 +${course.identifier} @@ -10340,7 +17550,7 @@ - + @@ -10353,6 +17563,17 @@ + + + + + + + + + +${course.name} + @@ -10361,7 +17582,7 @@ - + @@ -10383,7 +17604,7 @@ - + @@ -10397,15 +17618,26 @@ + + + + + + + + + +${course.score} + - + - + @@ -10419,15 +17651,26 @@ + + + + + + + + + +${course.time} + - + - + @@ -10441,15 +17684,26 @@ + + + + + + + + + +${course.theoretical} + - + - + @@ -10463,15 +17717,26 @@ + + + + + + + + + +${course.experiement} + - + - + @@ -10485,6 +17750,17 @@ + + + + + + + + + +${course.hpw} + @@ -10493,14 +17769,14 @@ - + - - + + @@ -10515,7 +17791,7 @@ - + @@ -10529,10 +17805,34 @@ + + + + + + + + + +${course.start}-${course.end} + + + + + + + + + + + + - + + + @@ -10544,7 +17844,7 @@ - + @@ -10565,7 +17865,7 @@ - + @@ -10586,7 +17886,7 @@ - + @@ -10640,7 +17940,7 @@ - + @@ -10661,7 +17961,7 @@ - + @@ -10676,15 +17976,27 @@ + + + + + + + + + + +${semester8.total.score} + - + - + @@ -10699,15 +18011,27 @@ + + + + + + + + + + +${semester8.total.time} + - + - + @@ -10722,15 +18046,27 @@ + + + + + + + + + + +${semester8.total.theoretical} + - + - + @@ -10745,15 +18081,27 @@ + + + + + + + + + + +${semester8.total.experiement} + - + - + @@ -10768,6 +18116,18 @@ + + + + + + + + + + +${semester8.total.hpw} + @@ -10776,11 +18136,18 @@ - + + + + + + + + @@ -10791,13 +18158,14 @@ - + + @@ -10897,7 +18265,7 @@ - + diff --git a/WebContent/generatorConfig.xml b/WebContent/generatorConfig.xml index e21b60d424c88b48382276757628e34b2a946354..88ae1274175a11f117d046d61b003ed465a4c2d8 100644 --- a/WebContent/generatorConfig.xml +++ b/WebContent/generatorConfig.xml @@ -100,11 +100,11 @@ --> - +
- +
diff --git a/WebContent/jsp/AddTbUser.jsp b/WebContent/jsp/AddTbUser.jsp index a42886bd8d7469a86e6764b8f8ded3ca3224aef9..da5af04a2e13b54c9304fe963663feeb055099e2 100644 --- a/WebContent/jsp/AddTbUser.jsp +++ b/WebContent/jsp/AddTbUser.jsp @@ -76,16 +76,16 @@
- +
- +
- +
diff --git a/WebContent/jsp/Header.jsp b/WebContent/jsp/Header.jsp index 4807154ab6ef62da6648e2dff59ac18fb54f51ed..cce3f03f052df2a915536a3745acf0df8d5e8b70 100644 --- a/WebContent/jsp/Header.jsp +++ b/WebContent/jsp/Header.jsp @@ -32,7 +32,7 @@ diff --git a/WebContent/jsp/QueryCourse.jsp b/WebContent/jsp/QueryCourse.jsp index f82877256872e4d3ad08205517ed3556cc9ca460..159c33d9b017139760e5ed5ffe62b14945355b7a 100644 --- a/WebContent/jsp/QueryCourse.jsp +++ b/WebContent/jsp/QueryCourse.jsp @@ -24,6 +24,45 @@ location.href = '<%=request.getContextPath()%>/CourseController/DeleteCourse.action?id=' + courseId; } } + + function addCourse(){ + $.ajax({ + url : '<%=request.getContextPath()%>/CourseController/toAddCourse.action', + success : function(data){ + alert(data); + } + }) + } + + function makeCourseCode(){ + $.ajax({ + url : '<%=request.getContextPath()%>/CourseController/MakeCourseCode.action', + async: false, + timeout : 30000,//超时时间:30秒 + dataType : "json",//设置返回数据的格式 + success : function(data){ + console.log(data); + if(data == 'successful'){ + alert("编号成功"); + window.location.href = window.location.href; + }else{ + alert("编号失败"); + } + }, + beforeSend : function() { + //请求前的处理 + $("#mymodal").modal('show'); + }, + complete : function() { + //请求完成的处理 + $("#mymodal").modal('hide'); + }, + error : function() { + //请求出错处理 + $("#mymodal").modal('hide'); + } + }) + } @@ -95,13 +134,50 @@ - 增加课程 + + + + - + + + + + + + \ No newline at end of file diff --git a/WebContent/jsp/QueryCurriculum2.jsp b/WebContent/jsp/QueryCurriculum2.jsp deleted file mode 100644 index a9776fecfd1e4fe3028c414762290f81baf0976e..0000000000000000000000000000000000000000 --- a/WebContent/jsp/QueryCurriculum2.jsp +++ /dev/null @@ -1,110 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=UTF-8" - pageEncoding="UTF-8"%> -<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%> -<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%> - - - - - - - 课程列表 - - - - - - - - - - - - - - -
- - - -
- - -
- -
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - <%-- --%> - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
${curriculum.id }${course.name }${course.identifier }${course.score }${course.theoretical }${course.experiement }${user.id}${curriculum.hpw }${curriculum.start }${curriculum.end } - 更新 - 删除 -
-
- - - - - 增加课程 -
- -
-
- - - - - \ No newline at end of file diff --git a/WebContent/jsp/QueryCurriculum3.jsp b/WebContent/jsp/QueryCurriculum3.jsp deleted file mode 100644 index 396bac34754733de71e1c8fc12f7247f0a95108a..0000000000000000000000000000000000000000 --- a/WebContent/jsp/QueryCurriculum3.jsp +++ /dev/null @@ -1,467 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=UTF-8" - pageEncoding="UTF-8"%> -<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%> -<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%> - - - - - - - 实施进程表 - - - - - - - - - - - - - - - - - -
- - - -
- - -
-
-
-

备选课程

-
-
-
- - -
- - - - -
- - -
- -
- - -
-
-
- -
- - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称
${course.id }${course.name}----${course.score}0${course.theoretical}${course.experiement}0117
-
-
-
-
- - -
- -
-
-

实施进程表

-
-
- - - - -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
##小计----00000--------
${curriculum.id }${course.name }${course.identifier }${course.score }${course.theoretical }${course.experiement }${user.id}${curriculum.hpw }${curriculum.start }${curriculum.end } - 更新 - 删除 -
-
-
-
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
##小计----00000--------
${curriculum.id }${course.name }${course.identifier }${course.score }${course.theoretical }${course.experiement }${user.id}${curriculum.hpw }${curriculum.start }${curriculum.end } - 更新 - 删除 -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- - - -
-
- -
-
- - - - - \ No newline at end of file diff --git a/WebContent/jsp/QueryCurriculums.jsp b/WebContent/jsp/QueryCurriculums.jsp index 1cbf02449a45a2a0a9d57a53e9d6463212505a83..7e99c6f229c2e0e54381d7c005a03af864e9a903 100644 --- a/WebContent/jsp/QueryCurriculums.jsp +++ b/WebContent/jsp/QueryCurriculums.jsp @@ -147,33 +147,43 @@ function compute_total($whichbody){ var total = new Array() var $dest_trs = $whichbody.children('tr'); + //var $dest_trs_avaliable = $(":checkbox:checked").closest("tr"); + var $dest_trs_avaliable =$whichbody.find(":checkbox:checked").closest("tr"); - for(var i = 0; i < $($dest_trs[0]).children().length - 1 ; i++){ + //初始化小计的数量 + for(var i = 0; i < 20 ; i++){ total[i] = 0; } - for(var i = 0;i < $dest_trs.length; i++){ + //先根据理论学时 + 实验学时 计算机总学时 + for(var i = 0;i < $dest_trs.length; i++){//所有行 var $dest_tds = $($dest_trs[i]).children(); if(i < $dest_trs.length - 1){//前面的行 - $dest_tds[4].innerHTML = parseInt($dest_tds[5].innerHTML) + parseInt($dest_tds[6].innerHTML); + ""; - - for(var j = 0; j < $dest_tds.length ; j ++ ){ - if(j >= 3 && j <= 7){ - total[j] += parseInt($dest_tds[j].innerHTML); - } - } + } + } + + //计算开课的小计 + var $dest_tds = undefined; + for(var i = 0;i < $dest_trs_avaliable.length; i++){//所有行 + $dest_tds = $($dest_trs_avaliable[i]).children(); - - }else{//total 行 - for(var j = 0; j < $dest_tds.length ; j ++ ){ - if(j >= 3 && j <= 7){ - $dest_tds[j].innerHTML = total[j] + ""; - } + for(var j = 0; j < $dest_tds.length ; j ++ ){ + if(j >= 3 && j <= 7){ + total[j] += parseInt($dest_tds[j].innerHTML); } } } + + //设置小计的内容 + $dest_tds = $($dest_trs[$dest_trs.length - 1]).children(); + for(var j = 0; j < $dest_tds.length ; j ++ ){ + if(j >= 3 && j <= 7){ + $dest_tds[j].innerHTML = total[j] + ""; + } + } + } function set_button_state(state){ @@ -225,25 +235,13 @@ }) } - function print_all_data(){ - <%-- $.ajax({ - url : '<%=request.getContextPath() %>/CurriculumController/ExportSchedule.action', - type: 'POST', - datatype : 'json',//后台返回的数据 - //contentType : 'application/json', - success : function(data){ - console.log("success : " + data); - } - }) --%> - } - // 保存所有学期的进程表 function save_all_data(){ for(var s = 1; s <= 8; s++){ save_semester_data(s); } - set_button_state(false); + set_button_state(false); } function save_semester_data(no){ @@ -262,13 +260,12 @@ obj['end'] = parseInt($(tds[9]).text()); obj['hpw'] = parseInt($(tds[7]).text()); obj['sort'] = 0; - + obj['available'] = tds[10].firstChild.checked; + // curriculums.push(obj); } } - console.log(JSON.stringify(curriculums)); - $.ajax({ url : '<%=request.getContextPath() %>/CurriculumController/UpdateCurriculum.action', type: 'POST', @@ -278,7 +275,13 @@ success : function(data){ console.log("success : " + data); } - }) + }) + } + + function checkboxOnclick(element){ + var $TBODY = $(element).parent().parent().parent(); + compute_total($TBODY); + set_button_state(true); } @@ -343,6 +346,7 @@ 0 1 17 + @@ -379,16 +383,17 @@ - - - - + + + + + @@ -403,7 +408,11 @@ - + + @@ -417,6 +426,7 @@ +
ID课程名称课程编号学分ID课程名称课程编号学分 学期学时 理论学时 实验学时 周学时 起始周 结束周开课
${curriculum.experiement } ${curriculum.hpw } ${curriculum.start }${curriculum.end }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
0 ---- --------
@@ -426,37 +436,42 @@
- - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + @@ -466,9 +481,10 @@ - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##
## 小计 ---- 00 ---- ----
+ ---- + + +
@@ -476,37 +492,42 @@
- - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + @@ -516,9 +537,10 @@ - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##
## 小计 ---- 00 ---- ----
+ ---- + + +
@@ -526,37 +548,42 @@
- - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + @@ -566,23 +593,220 @@ - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##
## 小计 ---- 00 ---- ----
+ ---- + + +
- <%-- --%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
##小计----00000------------
- <%-- --%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
##小计----00000------------
- <%-- --%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
##小计----00000------------
- <%-- --%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } checked="checked" + onclick="checkboxOnclick(this);" /> +
##小计----00000------------
diff --git a/WebContent/jsp/QuerySchedule.jsp b/WebContent/jsp/QuerySchedule.jsp index 1cbf02449a45a2a0a9d57a53e9d6463212505a83..c806df1ff538e90422c3737d79d46ec2e8b8dc83 100644 --- a/WebContent/jsp/QuerySchedule.jsp +++ b/WebContent/jsp/QuerySchedule.jsp @@ -264,6 +264,8 @@ obj['sort'] = 0; curriculums.push(obj); + + // } } @@ -293,308 +295,96 @@
-
-
-

备选课程

-
-
-
- - -
- - - - -
- - -
- -
- - -
-
+ +
+ + +
+ + +
+
+

${coursetype.coursetypename }

- -
- +
+
- - + + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + +
ID课程名称ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周开课学期
${course.id }${course.name}----${course.score}0${course.theoretical}${course.experiement}0117
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end } + + 已开 + + + 未开 + + + 未定 + + ${curriculum.semester}
##小计----${coursetype.total.score} ${coursetype.total.time}${coursetype.total.theoretical}${coursetype.total.experiement}${coursetype.total.hpw}----------------
+
-
-
- - -
- -
-
-

实施进程表

-
-
- - - - -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##小计----00000--------
-
-
-
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##小计----00000--------
-
- -
-
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##小计----00000--------
-
- -
-
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID课程名称课程编号学分学期学时理论学时实验学时周学时起始周结束周
${curriculum.id }${curriculum.name }${curriculum.identifier }${curriculum.score }${curriculum.time }${curriculum.theoretical }${curriculum.experiement }${curriculum.hpw }${curriculum.start }${curriculum.end }
##小计----00000--------
-
- -
-
- <%-- --%> -
-
- <%-- --%> -
-
- <%-- --%> -
-
- <%-- --%> -
-
- - - - - + -
-
- -
+
+ + +
+
diff --git a/WebContent/jsp/QueryTbUser.jsp b/WebContent/jsp/QueryTbUser.jsp index a761f9bd0caac6e6a48a557d27672cf3bdfa6792..3b61058c704810faa1453126a7ca6fc017afe2d2 100644 --- a/WebContent/jsp/QueryTbUser.jsp +++ b/WebContent/jsp/QueryTbUser.jsp @@ -33,13 +33,6 @@
- -
@@ -56,16 +49,17 @@ ID 登录名 + 操作 - + - ${course.id } - ${course.loginname } + ${user.id } + ${user.loginname } - 更新 - 删除 + 更新 + 删除 diff --git a/build/classes/cn/edu/hrbcu/curriculum/controller/CourseController.class b/build/classes/cn/edu/hrbcu/curriculum/controller/CourseController.class index ff602896133ebbbbf088a08d469e5ab59f0938db..d7fef5a5413306fa540a40660dabeae5162f328e 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/controller/CourseController.class and b/build/classes/cn/edu/hrbcu/curriculum/controller/CourseController.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/controller/CurriculumController.class b/build/classes/cn/edu/hrbcu/curriculum/controller/CurriculumController.class index 846935ee9b65ab134a7b142fa560be986d9f4a96..0b42616bc68e2d6a8e567ea6f8a6d834155a8aae 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/controller/CurriculumController.class and b/build/classes/cn/edu/hrbcu/curriculum/controller/CurriculumController.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml b/build/classes/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml index 90bce91aef54669010fd3857b469c6338fd68191..23e23e55274d4a460b93adc6666531ec3b9f615d 100644 --- a/build/classes/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml +++ b/build/classes/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml @@ -4,6 +4,7 @@ + @@ -64,7 +65,7 @@ - id, name + id, name, code @@ -134,6 +143,9 @@ name = #{record.name,jdbcType=VARCHAR}, + + code = #{record.code,jdbcType=INTEGER}, + @@ -142,7 +154,8 @@ update academy set id = #{record.id,jdbcType=BIGINT}, - name = #{record.name,jdbcType=VARCHAR} + name = #{record.name,jdbcType=VARCHAR}, + code = #{record.code,jdbcType=INTEGER} @@ -153,12 +166,16 @@ name = #{name,jdbcType=VARCHAR}, + + code = #{code,jdbcType=INTEGER}, + where id = #{id,jdbcType=BIGINT} update academy - set name = #{name,jdbcType=VARCHAR} + set name = #{name,jdbcType=VARCHAR}, + code = #{code,jdbcType=INTEGER} where id = #{id,jdbcType=BIGINT} \ No newline at end of file diff --git a/build/classes/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml b/build/classes/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml index e69be59558412658dfca2e7ee3bb929ac3eac079..ce1d93392fc6b57578023b11454a800f64c6d44b 100644 --- a/build/classes/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml +++ b/build/classes/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml @@ -4,6 +4,7 @@ + @@ -64,7 +65,7 @@ - id, name + id, name, code @@ -134,6 +143,9 @@ name = #{record.name,jdbcType=VARCHAR}, + + code = #{record.code,jdbcType=VARCHAR}, + @@ -142,7 +154,8 @@ update coursetype set id = #{record.id,jdbcType=BIGINT}, - name = #{record.name,jdbcType=VARCHAR} + name = #{record.name,jdbcType=VARCHAR}, + code = #{record.code,jdbcType=VARCHAR} @@ -153,12 +166,16 @@ name = #{name,jdbcType=VARCHAR}, + + code = #{code,jdbcType=VARCHAR}, + where id = #{id,jdbcType=BIGINT} update coursetype - set name = #{name,jdbcType=VARCHAR} + set name = #{name,jdbcType=VARCHAR}, + code = #{code,jdbcType=VARCHAR} where id = #{id,jdbcType=BIGINT} \ No newline at end of file diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/Academy.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/Academy.class index b300aa1fee951fd1a400d3b8adad75f0a81c6956..1f8bfb5d5a9bb3b4382a77de736c1ef605aeba21 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/Academy.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/Academy.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criteria.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criteria.class index 8d40068aacaa1ba204fc8831dd5cedaa3c9faac9..ea4791fd8076ef67c964aa3c7e5673d9dfcf1ca2 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criteria.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criteria.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criterion.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criterion.class index 9a1808fa02d0d993b33ed87707f9cadff26fc072..df3a963a9859feca33a91bb0f2b19252d8bbfbcc 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criterion.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$Criterion.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$GeneratedCriteria.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$GeneratedCriteria.class index d7679fd4a2058daea56a7728467ac8030383919a..b8bd828b7bcdc6709b18b5e0826463c5ec628055 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$GeneratedCriteria.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/AcademyExample$GeneratedCriteria.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/Coursetype.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/Coursetype.class index 11e9b25990f313dd045341912fb83cfa7dbd70b5..4f1f4ec236920d769ccdb0640aed542050a14687 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/Coursetype.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/Coursetype.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criteria.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criteria.class index e2b432bdb9ffaeaeb251585cbc26086a71cbc760..c28bac8a66381a84822b5b3d34eb6cbcc8ecb2c5 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criteria.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criteria.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criterion.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criterion.class index 1bba73c90f49b9c996d2a1b315150dc858647d4a..5d9718f896e148bc1bf611d8956f643c45265b3d 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criterion.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$Criterion.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$GeneratedCriteria.class b/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$GeneratedCriteria.class index 72041b8ae049c77611796ecc41243a72ed669db6..7ba2f6b3feecb0a4b7ae5170585c408df9d8b212 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$GeneratedCriteria.class and b/build/classes/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample$GeneratedCriteria.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/service/CourseService.class b/build/classes/cn/edu/hrbcu/curriculum/service/CourseService.class index 28fb1188519ec301a083119a87241c95e2b5a5d5..76cfc9543e403495148378ffee98b71bcd410c6e 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/service/CourseService.class and b/build/classes/cn/edu/hrbcu/curriculum/service/CourseService.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.class b/build/classes/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.class index 7d3632a845115e5b1a75a3b72fe8441ca1a9a7ec..e91c9d6f26e83a981d8bc34bdb463a204d68e68c 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.class and b/build/classes/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumService.class b/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumService.class index 5e4f5f09768684668f1d6cf8776cef3bb2bd79cb..b766f8836e4ff532cb7db0d050f5a49a626dd222 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumService.class and b/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumService.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.class b/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.class index caf561d47160cd4081df0eb948120a2ce3f6e239..4eefef87ccd2036f026c9f0cc06a387a3ba93ba8 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.class and b/build/classes/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/service/TbUserService.class b/build/classes/cn/edu/hrbcu/curriculum/service/TbUserService.class index c3ba3137ff84e57f1522a70931580cebaf3d3c89..3a76580ce50737a0dde4479504251a88faa6209b 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/service/TbUserService.class and b/build/classes/cn/edu/hrbcu/curriculum/service/TbUserService.class differ diff --git a/build/classes/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.class b/build/classes/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.class index aff559cb89f1d0b8d6062b812b0ead17bf7b47b2..c0b2249101e8f1c0bda9018dca9a3efd891880e5 100644 Binary files a/build/classes/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.class and b/build/classes/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.class differ diff --git a/build/classes/cn/edu/hrbcu/shiro/ShiroRealm.class b/build/classes/cn/edu/hrbcu/shiro/ShiroRealm.class index 76b98277ea6c1830c99fa61243162394a89ea36e..7e7fb35011cbc6313edc6f81d7fa5872ad2711f1 100644 Binary files a/build/classes/cn/edu/hrbcu/shiro/ShiroRealm.class and b/build/classes/cn/edu/hrbcu/shiro/ShiroRealm.class differ diff --git a/src/cn/edu/hrbcu/curriculum/controller/CourseController.java b/src/cn/edu/hrbcu/curriculum/controller/CourseController.java index 77bb2abef548b71848bf57c78fcb3e5a87a9864e..b2c4dc052f4a033f5b2726f34b0bfdc7dba96638 100644 --- a/src/cn/edu/hrbcu/curriculum/controller/CourseController.java +++ b/src/cn/edu/hrbcu/curriculum/controller/CourseController.java @@ -2,6 +2,8 @@ package cn.edu.hrbcu.curriculum.controller; import java.util.List; +import org.apache.shiro.SecurityUtils; +import org.apache.shiro.subject.Subject; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; @@ -16,12 +18,16 @@ import cn.edu.hrbcu.curriculum.pojo.Course; import cn.edu.hrbcu.curriculum.pojo.Coursemode; import cn.edu.hrbcu.curriculum.pojo.Coursetype; import cn.edu.hrbcu.curriculum.pojo.Examinationmethod; +import cn.edu.hrbcu.curriculum.pojo.Speciality; +import cn.edu.hrbcu.curriculum.pojo.TbUser; import cn.edu.hrbcu.curriculum.pojo.Teachingmethod; import cn.edu.hrbcu.curriculum.service.AcademyService; import cn.edu.hrbcu.curriculum.service.CourseService; import cn.edu.hrbcu.curriculum.service.CoursemodeService; import cn.edu.hrbcu.curriculum.service.CoursetypeService; import cn.edu.hrbcu.curriculum.service.ExaminationmethodService; +import cn.edu.hrbcu.curriculum.service.SpecialityService; +import cn.edu.hrbcu.curriculum.service.TbUserService; import cn.edu.hrbcu.curriculum.service.TeachingmethodService; @@ -40,6 +46,10 @@ public class CourseController { TeachingmethodService teachingmethodService; @Autowired ExaminationmethodService examinationmethodService; + @Autowired + private SpecialityService specialityService; + @Autowired + private TbUserService tbUserService; @RequestMapping("/QueryCourse.action") public ModelAndView QueryCourse(@RequestParam(value = "currentPage",required=false, defaultValue="1") Integer currentPage){ @@ -142,4 +152,30 @@ public class CourseController { return "forward:/CourseController/QueryCourse.action"; } + + @RequestMapping("/MakeCourseCode.action") + @ResponseBody + public Object MakeCourseCode(){ + Boolean ret = false; + ModelAndView modelAndView = new ModelAndView(); + modelAndView.setViewName("/QueryCourse"); + + //获取专业id + Subject subject = SecurityUtils.getSubject(); + List tbUsers = tbUserService.selectUserByLoginname((String) subject.getPrincipal()); + if (tbUsers != null && tbUsers.size() > 0) { + Speciality speciality = specialityService.selectSpecialityByUserId(tbUsers.get(0).getId()); + if(speciality != null){ + ret = courseService.makeCourseCode(9,speciality.getCode()); + }else{ + ret = false; + } + } + System.out.println("AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + ret); + if(ret){ + return "successful"; + }else{ + return "failure"; + } + } } diff --git a/src/cn/edu/hrbcu/curriculum/controller/CurriculumController.java b/src/cn/edu/hrbcu/curriculum/controller/CurriculumController.java index 4f1ae27e8e85490c89a146c455dcca0da88eb2a7..9d35b3b508c14ec64afe941292bbf70b023250e0 100644 --- a/src/cn/edu/hrbcu/curriculum/controller/CurriculumController.java +++ b/src/cn/edu/hrbcu/curriculum/controller/CurriculumController.java @@ -14,9 +14,7 @@ import org.apache.shiro.SecurityUtils; import org.apache.shiro.subject.Subject; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; -import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.servlet.ModelAndView; @@ -24,15 +22,18 @@ import org.springframework.web.servlet.ModelAndView; import com.github.pagehelper.PageInfo; import cn.edu.hrbcu.curriculum.pojo.Course; +import cn.edu.hrbcu.curriculum.pojo.Coursetype; import cn.edu.hrbcu.curriculum.pojo.Curriculum; import cn.edu.hrbcu.curriculum.pojo.Examinationmethod; import cn.edu.hrbcu.curriculum.pojo.Speciality; import cn.edu.hrbcu.curriculum.pojo.TbUser; import cn.edu.hrbcu.curriculum.service.CourseService; +import cn.edu.hrbcu.curriculum.service.CoursetypeService; import cn.edu.hrbcu.curriculum.service.CurriculumService; import cn.edu.hrbcu.curriculum.service.ExaminationmethodService; import cn.edu.hrbcu.curriculum.service.SpecialityService; import cn.edu.hrbcu.curriculum.service.TbUserService; +import cn.edu.hrbcu.utils.CharacterUtil; import cn.edu.hrbcu.utils.WordUtils; import net.sf.json.JSONArray; import net.sf.json.JSONObject; @@ -50,6 +51,8 @@ public class CurriculumController { private SpecialityService specialityService; @Autowired private TbUserService tbUserService; + @Autowired + CoursetypeService coursetypeService; @RequestMapping("/QueryCurriculum.action") public ModelAndView QueryCurriculum( @@ -100,6 +103,7 @@ public class CurriculumController { c.put("hpw", curriculum.getHpw()); c.put("start", curriculum.getStart()); c.put("end", curriculum.getEnd()); + c.put("avaliable", curriculum.getAvailable()); curriculums.add(c); } @@ -116,7 +120,22 @@ public class CurriculumController { public ModelAndView CheckCurriculums(Long specialityid) { ModelAndView modelAndView = new ModelAndView(); modelAndView.setViewName("/CheckCurriculums"); - + // 获取专业id + if (specialityid == null) { + Subject subject = SecurityUtils.getSubject(); + List tbUsers = tbUserService.selectUserByLoginname((String) subject.getPrincipal()); + if (tbUsers != null && tbUsers.size() > 0) { + Speciality speciality = specialityService.selectSpecialityByUserId(tbUsers.get(0).getId()); + if (speciality == null) { + return null; + } else { + specialityid = speciality.getId(); + } + } else { + return null; + } + } + ///////////////////////////////////////////// if (specialityid == null) { return modelAndView; } @@ -143,7 +162,8 @@ public class CurriculumController { c.put("hpw", curriculum.getHpw()); c.put("start", curriculum.getStart()); c.put("end", curriculum.getEnd()); - + c.put("avaliable", curriculum.getAvailable()); + curriculums.add(c); } } @@ -153,6 +173,40 @@ public class CurriculumController { return modelAndView; } // + + @RequestMapping("/QuerySchedule.action") + public ModelAndView QuerySchedule(Long specialityid) { + ModelAndView modelAndView = new ModelAndView(); + modelAndView.setViewName("/QuerySchedule"); + //获取专业id + if(specialityid == null){ + Subject subject = SecurityUtils.getSubject(); + List tbUsers = tbUserService.selectUserByLoginname((String) subject.getPrincipal()); + if (tbUsers != null && tbUsers.size() > 0) { + Speciality speciality = specialityService.selectSpecialityByUserId(tbUsers.get(0).getId()); + if (speciality == null) { + return modelAndView; + }else{ + specialityid = speciality.getId(); + } + } else { + return modelAndView; + } + } + ///////////////////////////////////////////// + if (specialityid == null) { + return modelAndView; + } + //////////////////////////////////////////// + List coursetypes = coursetypeService.selectAllCoursetype(); + modelAndView.addObject("coursetypes", coursetypes); + + List> curriculums = queryCurriculumsByCoursetype(specialityid); + modelAndView.addObject("allcurriculums", curriculums); + + return modelAndView; + } + @RequestMapping(value = "/UpdateCurriculum.action") @ResponseBody @@ -189,7 +243,7 @@ public class CurriculumController { return "successful"; } - private Map queryCurriculumsBySemester(Long specialityId) { + private Map queryCurriculumsBySemester(Long specialityId, boolean available) { Map all_curriculums = new HashMap(); for (int i = 1; i <= 8; i++) { @@ -221,8 +275,15 @@ public class CurriculumController { t[4] += (curriculum.getHpw()==null) ? 0 : curriculum.getHpw(); c.put("start", curriculum.getStart()); c.put("end", curriculum.getEnd()); - - curriculums.add(c); + c.put("available", curriculum.getAvailable()); + + if(available){//若果只查已开课的 + if(curriculum.getAvailable()){ + curriculums.add(c); + } + }else{//所有课程全部查询 + curriculums.add(c); + } } } //保存学期的小计信息 @@ -242,18 +303,91 @@ public class CurriculumController { return all_curriculums; } + private List> queryCurriculumsByCoursetype(Long specialityId) { + //Map all_curriculums = new HashMap(); + List> all_curriculums = new ArrayList>(); + + List coursetypes = coursetypeService.selectAllCoursetype(); + if(coursetypes != null && coursetypes.size() > 0){ + for (Coursetype coursetype : coursetypes) { + //保存每个课程类型所有的课程和小计信息 + Map type_ = new HashMap(); + //保存每个课程类型所有的课程 + List> curriculums = new ArrayList>(); + //保存小计信息 + Map total = new HashMap(); + double[] t = new double[10]; + + List curriculums_ = curriculumService.selectAllCurriculumBySpecialityandCourseType(specialityId, coursetype.getId()); + if (curriculums_ != null && curriculums_.size() > 0) { + for (Curriculum curriculum : curriculums_) { + Map c = new HashMap(); + Course course = courseService.selectCourseById(curriculum.getCourseid()); + c.put("id", course.getId()); + c.put("name", course.getName()); + c.put("identifier", course.getIdentifier()); + c.put("score", course.getScore()); + t[0] += (course.getScore()==null) ? 0 : course.getScore(); + c.put("time", course.getTheoretical() + course.getExperiement()); + t[1] += (course.getTheoretical() == null || course.getExperiement() == null) ? 0 : course.getTheoretical() + course.getExperiement() ; + c.put("theoretical", course.getTheoretical()); + t[2] += (course.getTheoretical()==null) ? 0 : course.getTheoretical(); + c.put("experiement", course.getExperiement()); + t[3] += (course.getExperiement()==null) ? 0 : course.getExperiement(); + c.put("hpw", curriculum.getHpw()); + t[4] += (curriculum.getHpw()==null) ? 0 : curriculum.getHpw(); + c.put("start", curriculum.getStart()); + c.put("end", curriculum.getEnd()); + c.put("available", curriculum.getAvailable()); + c.put("semester", CharacterUtil.num2roman(curriculum.getSemester())); + + curriculums.add(c); + } + } + //保存学期的小计信息 + total.put("score", t[0]); + total.put("time", t[1]); + total.put("theoretical", t[2]); + total.put("experiement", t[3]); + total.put("hpw", t[4]); + + + type_.put("curriculums", curriculums); + type_.put("total", total); + type_.put("coursetypename", coursetype.getName()); + + + //all_curriculums.put("coursetype" + coursetype.getId(), type_); + all_curriculums.add(type_); + } + } + + return all_curriculums; + } + + @RequestMapping("/ExportSchedule") public @ResponseBody void ExportSchedule(HttpServletRequest req, HttpServletResponse resp){ - Map dataMap = queryCurriculumsBySemester(3L); - - try { - WordUtils.exportMillCertificateWord(req, resp, dataMap, "本科专业人才培养方案实施进程表","schedule_12.ftl"); - //WordUtils.exportTestWord(req, resp, data, "本科专业人才培养方案实施进程表","test1.ftl"); - - } catch (IOException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } + // 获取专业id + Speciality speciality = null; + Subject subject = SecurityUtils.getSubject(); + List tbUsers = tbUserService.selectUserByLoginname((String) subject.getPrincipal()); + if (tbUsers != null && tbUsers.size() > 0) { + speciality = specialityService.selectSpecialityByUserId(tbUsers.get(0).getId()); + + Map dataMap = queryCurriculumsBySemester(speciality.getId(),true); + + try { + //WordUtils.exportMillCertificateWord(req, resp, dataMap, "本科专业人才培养方案实施进程表","schedule_12.ftl"); + WordUtils.exportMillCertificateWord(req, resp, dataMap, "本科专业人才培养方案实施进程表","schedule.ftl"); + //WordUtils.exportTestWord(req, resp, data, "本科专业人才培养方案实施进程表","test1.ftl"); + + } catch (IOException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + } } } diff --git a/src/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml b/src/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml index 90bce91aef54669010fd3857b469c6338fd68191..23e23e55274d4a460b93adc6666531ec3b9f615d 100644 --- a/src/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml +++ b/src/cn/edu/hrbcu/curriculum/mapper/AcademyMapper.xml @@ -4,6 +4,7 @@ + @@ -64,7 +65,7 @@ - id, name + id, name, code @@ -134,6 +143,9 @@ name = #{record.name,jdbcType=VARCHAR}, + + code = #{record.code,jdbcType=INTEGER}, + @@ -142,7 +154,8 @@ update academy set id = #{record.id,jdbcType=BIGINT}, - name = #{record.name,jdbcType=VARCHAR} + name = #{record.name,jdbcType=VARCHAR}, + code = #{record.code,jdbcType=INTEGER} @@ -153,12 +166,16 @@ name = #{name,jdbcType=VARCHAR}, + + code = #{code,jdbcType=INTEGER}, + where id = #{id,jdbcType=BIGINT} update academy - set name = #{name,jdbcType=VARCHAR} + set name = #{name,jdbcType=VARCHAR}, + code = #{code,jdbcType=INTEGER} where id = #{id,jdbcType=BIGINT} \ No newline at end of file diff --git a/src/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml b/src/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml index e69be59558412658dfca2e7ee3bb929ac3eac079..ce1d93392fc6b57578023b11454a800f64c6d44b 100644 --- a/src/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml +++ b/src/cn/edu/hrbcu/curriculum/mapper/CoursetypeMapper.xml @@ -4,6 +4,7 @@ + @@ -64,7 +65,7 @@ - id, name + id, name, code @@ -134,6 +143,9 @@ name = #{record.name,jdbcType=VARCHAR}, + + code = #{record.code,jdbcType=VARCHAR}, + @@ -142,7 +154,8 @@ update coursetype set id = #{record.id,jdbcType=BIGINT}, - name = #{record.name,jdbcType=VARCHAR} + name = #{record.name,jdbcType=VARCHAR}, + code = #{record.code,jdbcType=VARCHAR} @@ -153,12 +166,16 @@ name = #{name,jdbcType=VARCHAR}, + + code = #{code,jdbcType=VARCHAR}, + where id = #{id,jdbcType=BIGINT} update coursetype - set name = #{name,jdbcType=VARCHAR} + set name = #{name,jdbcType=VARCHAR}, + code = #{code,jdbcType=VARCHAR} where id = #{id,jdbcType=BIGINT} \ No newline at end of file diff --git a/src/cn/edu/hrbcu/curriculum/mapper/SpecialityMapper.xml b/src/cn/edu/hrbcu/curriculum/mapper/SpecialityMapper.xml index 3110934090f39a40b06a57f9b0f74215133cffc1..07db0bba2f51f9823d6237240a79b7e0aa8183cf 100644 --- a/src/cn/edu/hrbcu/curriculum/mapper/SpecialityMapper.xml +++ b/src/cn/edu/hrbcu/curriculum/mapper/SpecialityMapper.xml @@ -5,6 +5,7 @@ + @@ -65,7 +66,7 @@ - id, name, tbuserid + id, name, tbuserid, code @@ -146,6 +153,9 @@ tbuserid = #{record.tbuserid,jdbcType=BIGINT}, + + code = #{record.code,jdbcType=INTEGER}, + @@ -155,7 +165,8 @@ update speciality set id = #{record.id,jdbcType=BIGINT}, name = #{record.name,jdbcType=VARCHAR}, - tbuserid = #{record.tbuserid,jdbcType=BIGINT} + tbuserid = #{record.tbuserid,jdbcType=BIGINT}, + code = #{record.code,jdbcType=INTEGER} @@ -169,13 +180,17 @@ tbuserid = #{tbuserid,jdbcType=BIGINT}, + + code = #{code,jdbcType=INTEGER}, + where id = #{id,jdbcType=BIGINT} update speciality set name = #{name,jdbcType=VARCHAR}, - tbuserid = #{tbuserid,jdbcType=BIGINT} + tbuserid = #{tbuserid,jdbcType=BIGINT}, + code = #{code,jdbcType=INTEGER} where id = #{id,jdbcType=BIGINT} \ No newline at end of file diff --git a/src/cn/edu/hrbcu/curriculum/pojo/Academy.java b/src/cn/edu/hrbcu/curriculum/pojo/Academy.java index 2471182e54ecb807d182b912c9d789a5592823fa..d2b9513096e72ff0eef355ee26b830a22cc2f95e 100644 --- a/src/cn/edu/hrbcu/curriculum/pojo/Academy.java +++ b/src/cn/edu/hrbcu/curriculum/pojo/Academy.java @@ -7,6 +7,8 @@ public class Academy implements Serializable { private String name; + private Integer code; + private static final long serialVersionUID = 1L; public Long getId() { @@ -24,4 +26,12 @@ public class Academy implements Serializable { public void setName(String name) { this.name = name == null ? null : name.trim(); } + + public Integer getCode() { + return code; + } + + public void setCode(Integer code) { + this.code = code; + } } \ No newline at end of file diff --git a/src/cn/edu/hrbcu/curriculum/pojo/AcademyExample.java b/src/cn/edu/hrbcu/curriculum/pojo/AcademyExample.java index e74df68cbefc2a2b2cb2e00aded2f612228f5b05..421c3c45a0805f956e1ff48ed474e115dc293a25 100644 --- a/src/cn/edu/hrbcu/curriculum/pojo/AcademyExample.java +++ b/src/cn/edu/hrbcu/curriculum/pojo/AcademyExample.java @@ -233,6 +233,66 @@ public class AcademyExample { addCriterion("name not between", value1, value2, "name"); return (Criteria) this; } + + public Criteria andCodeIsNull() { + addCriterion("code is null"); + return (Criteria) this; + } + + public Criteria andCodeIsNotNull() { + addCriterion("code is not null"); + return (Criteria) this; + } + + public Criteria andCodeEqualTo(Integer value) { + addCriterion("code =", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotEqualTo(Integer value) { + addCriterion("code <>", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeGreaterThan(Integer value) { + addCriterion("code >", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeGreaterThanOrEqualTo(Integer value) { + addCriterion("code >=", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLessThan(Integer value) { + addCriterion("code <", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLessThanOrEqualTo(Integer value) { + addCriterion("code <=", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeIn(List values) { + addCriterion("code in", values, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotIn(List values) { + addCriterion("code not in", values, "code"); + return (Criteria) this; + } + + public Criteria andCodeBetween(Integer value1, Integer value2) { + addCriterion("code between", value1, value2, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotBetween(Integer value1, Integer value2) { + addCriterion("code not between", value1, value2, "code"); + return (Criteria) this; + } } public static class Criteria extends GeneratedCriteria { diff --git a/src/cn/edu/hrbcu/curriculum/pojo/Coursetype.java b/src/cn/edu/hrbcu/curriculum/pojo/Coursetype.java index d95f07210018d87534a2a6407a62de3dc4a979ad..735326d2b023ce9407b5ab57073c0c2745e8f45e 100644 --- a/src/cn/edu/hrbcu/curriculum/pojo/Coursetype.java +++ b/src/cn/edu/hrbcu/curriculum/pojo/Coursetype.java @@ -7,6 +7,8 @@ public class Coursetype implements Serializable { private String name; + private String code; + private static final long serialVersionUID = 1L; public Long getId() { @@ -24,4 +26,12 @@ public class Coursetype implements Serializable { public void setName(String name) { this.name = name == null ? null : name.trim(); } + + public String getCode() { + return code; + } + + public void setCode(String code) { + this.code = code == null ? null : code.trim(); + } } \ No newline at end of file diff --git a/src/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample.java b/src/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample.java index 7a174f48e13870344f02085de83f693a1791def8..27500b66a48c10e3669ff72d171e070e774dbc92 100644 --- a/src/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample.java +++ b/src/cn/edu/hrbcu/curriculum/pojo/CoursetypeExample.java @@ -233,6 +233,76 @@ public class CoursetypeExample { addCriterion("name not between", value1, value2, "name"); return (Criteria) this; } + + public Criteria andCodeIsNull() { + addCriterion("code is null"); + return (Criteria) this; + } + + public Criteria andCodeIsNotNull() { + addCriterion("code is not null"); + return (Criteria) this; + } + + public Criteria andCodeEqualTo(String value) { + addCriterion("code =", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotEqualTo(String value) { + addCriterion("code <>", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeGreaterThan(String value) { + addCriterion("code >", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeGreaterThanOrEqualTo(String value) { + addCriterion("code >=", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLessThan(String value) { + addCriterion("code <", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLessThanOrEqualTo(String value) { + addCriterion("code <=", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLike(String value) { + addCriterion("code like", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotLike(String value) { + addCriterion("code not like", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeIn(List values) { + addCriterion("code in", values, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotIn(List values) { + addCriterion("code not in", values, "code"); + return (Criteria) this; + } + + public Criteria andCodeBetween(String value1, String value2) { + addCriterion("code between", value1, value2, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotBetween(String value1, String value2) { + addCriterion("code not between", value1, value2, "code"); + return (Criteria) this; + } } public static class Criteria extends GeneratedCriteria { diff --git a/src/cn/edu/hrbcu/curriculum/pojo/Speciality.java b/src/cn/edu/hrbcu/curriculum/pojo/Speciality.java index 8849d54432ea003555a490f475fca2d6aa82769a..b47f60dd806b4eddaa85f00f327827e111a55e8b 100644 --- a/src/cn/edu/hrbcu/curriculum/pojo/Speciality.java +++ b/src/cn/edu/hrbcu/curriculum/pojo/Speciality.java @@ -9,6 +9,8 @@ public class Speciality implements Serializable { private Long tbuserid; + private Integer code; + private static final long serialVersionUID = 1L; public Long getId() { @@ -34,4 +36,12 @@ public class Speciality implements Serializable { public void setTbuserid(Long tbuserid) { this.tbuserid = tbuserid; } + + public Integer getCode() { + return code; + } + + public void setCode(Integer code) { + this.code = code; + } } \ No newline at end of file diff --git a/src/cn/edu/hrbcu/curriculum/pojo/SpecialityExample.java b/src/cn/edu/hrbcu/curriculum/pojo/SpecialityExample.java index fcf097ce33fec0420597370b9e1f8ec1d2010e5b..f81f89301c16abad5ca3e2328d38d907f021a8fd 100644 --- a/src/cn/edu/hrbcu/curriculum/pojo/SpecialityExample.java +++ b/src/cn/edu/hrbcu/curriculum/pojo/SpecialityExample.java @@ -293,6 +293,66 @@ public class SpecialityExample { addCriterion("tbuserid not between", value1, value2, "tbuserid"); return (Criteria) this; } + + public Criteria andCodeIsNull() { + addCriterion("code is null"); + return (Criteria) this; + } + + public Criteria andCodeIsNotNull() { + addCriterion("code is not null"); + return (Criteria) this; + } + + public Criteria andCodeEqualTo(Integer value) { + addCriterion("code =", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotEqualTo(Integer value) { + addCriterion("code <>", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeGreaterThan(Integer value) { + addCriterion("code >", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeGreaterThanOrEqualTo(Integer value) { + addCriterion("code >=", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLessThan(Integer value) { + addCriterion("code <", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeLessThanOrEqualTo(Integer value) { + addCriterion("code <=", value, "code"); + return (Criteria) this; + } + + public Criteria andCodeIn(List values) { + addCriterion("code in", values, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotIn(List values) { + addCriterion("code not in", values, "code"); + return (Criteria) this; + } + + public Criteria andCodeBetween(Integer value1, Integer value2) { + addCriterion("code between", value1, value2, "code"); + return (Criteria) this; + } + + public Criteria andCodeNotBetween(Integer value1, Integer value2) { + addCriterion("code not between", value1, value2, "code"); + return (Criteria) this; + } } public static class Criteria extends GeneratedCriteria { diff --git a/src/cn/edu/hrbcu/curriculum/service/CourseService.java b/src/cn/edu/hrbcu/curriculum/service/CourseService.java index 4bdf8533876f286d03258c9f37b86cebce451369..32663086f044f7931a82a3e35ef5979db027f9b8 100644 --- a/src/cn/edu/hrbcu/curriculum/service/CourseService.java +++ b/src/cn/edu/hrbcu/curriculum/service/CourseService.java @@ -21,5 +21,7 @@ public interface CourseService { int updateCourse(Course course); void deleteCourse(Course course); + + Boolean makeCourseCode(int academyCode, int pecialityCode); } diff --git a/src/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.java b/src/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.java index b799969bf73d764b9f11bbefdb83b59075c99770..c81c9f5758738487f305a6c060fd7069dee6d796 100644 --- a/src/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.java +++ b/src/cn/edu/hrbcu/curriculum/service/CourseServiceImpl.java @@ -5,14 +5,18 @@ import org.springframework.stereotype.Service; import com.github.pagehelper.PageHelper; import java.util.List; import cn.edu.hrbcu.curriculum.dao.CourseMapper; +import cn.edu.hrbcu.curriculum.dao.CoursetypeMapper; import cn.edu.hrbcu.curriculum.pojo.Course; import cn.edu.hrbcu.curriculum.pojo.CourseExample; +import cn.edu.hrbcu.curriculum.pojo.Coursetype; import cn.edu.hrbcu.utils.Common; @Service public class CourseServiceImpl implements CourseService { @Autowired private CourseMapper courseMapper; + @Autowired + private CoursetypeService coursetypeService; public int insertCourse(Course course) { @@ -85,5 +89,35 @@ public class CourseServiceImpl implements CourseService { List list = courseMapper.selectByExample(example); return list; } + + + @Override + public Boolean makeCourseCode(int academyCode, int specialityCode) { + // TODO Auto-generated method stub + List coursetypes = coursetypeService.selectAllCoursetype(); + if(coursetypes != null && coursetypes.size() > 0){ + for (Coursetype coursetype : coursetypes) { + if(coursetype.getId() >= 4L){//只有自己的课程编号 + Course c = new Course(); + c.setCoursetypeid(coursetype.getId()); + List courses = selectCourseBy(c); + if(courses != null && courses.size() > 0){ + for(int index = 0;index < courses.size() ; index++ ){ + courses.get(index).setIdentifier( + coursetype.getCode() + + String.format("%02d", academyCode) + + String.format("%01d",specialityCode) + + String.format("%02d",index + 1) + ); + + updateCourse(courses.get(index)); + } + } + } + } + return true; + } + return false; + } } diff --git a/src/cn/edu/hrbcu/curriculum/service/CurriculumService.java b/src/cn/edu/hrbcu/curriculum/service/CurriculumService.java index 0fe96bf0891c56a9a1713ebf199b183e3d41c6b8..d108e5ca94957f74f35e674ac284633d1c8ad419 100644 --- a/src/cn/edu/hrbcu/curriculum/service/CurriculumService.java +++ b/src/cn/edu/hrbcu/curriculum/service/CurriculumService.java @@ -14,6 +14,8 @@ public interface CurriculumService { Curriculum selectCurriculumById(Curriculum curriculum); List selectAllCurriculumBySpecialityandSemester(Long specialityid, int semester); + + List selectAllCurriculumBySpecialityandCourseType(Long specialityid, Long coursetypeId); List selectCurriculums(int currentPage); diff --git a/src/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.java b/src/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.java index b4733bb71e82741285dbc35375b4285f1248fe2a..8665a47d6a1c39cde195ad445ae1fce129cfa094 100644 --- a/src/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.java +++ b/src/cn/edu/hrbcu/curriculum/service/CurriculumServiceImpl.java @@ -10,6 +10,7 @@ import org.springframework.stereotype.Service; import com.github.pagehelper.PageHelper; import cn.edu.hrbcu.curriculum.dao.CurriculumMapper; +import cn.edu.hrbcu.curriculum.pojo.Course; import cn.edu.hrbcu.curriculum.pojo.Curriculum; import cn.edu.hrbcu.curriculum.pojo.CurriculumExample; import cn.edu.hrbcu.utils.Common; @@ -28,6 +29,8 @@ import cn.edu.hrbcu.utils.Common; public class CurriculumServiceImpl implements CurriculumService{ @Autowired private CurriculumMapper curriculumMapper; + @Autowired + CourseService courseService; @Override public int insertCurriculum(Curriculum curriculum) { @@ -93,6 +96,7 @@ public class CurriculumServiceImpl implements CurriculumService{ curriculum_update.setStart(curriculum_all_new.getStart()); curriculum_update.setEnd(curriculum_all_new.getEnd()); curriculum_update.setHpw(curriculum_all_new.getHpw()); + curriculum_update.setAvailable(curriculum_all_new.getAvailable()); foundSame = true; break; } @@ -222,10 +226,29 @@ public class CurriculumServiceImpl implements CurriculumService{ List add_ids = new ArrayList(); add_ids.addAll(new_ids); add_ids.removeAll(exist_ids); - - System.out.println(remove_ids.get(0) + ":" + remove_ids.size()); - System.out.println(update_ids.get(0) + ":" + update_ids.size()); - System.out.println(add_ids.get(0) + ":" + add_ids.size()); + } + @Override + public List selectAllCurriculumBySpecialityandCourseType(Long specialityid, Long coursetypeId) { + List curriculums = new ArrayList(); + + List courseids_ = new ArrayList(); + Course c = new Course(); + c.setCoursetypeid(coursetypeId); + List courses_ = courseService.selectCourseBy(c); + for (Course course : courses_) { + courseids_.add(course.getId()); + } + + CurriculumExample example = new CurriculumExample(); + CurriculumExample.Criteria criteria = example.createCriteria(); + criteria.andSpecialityidEqualTo(specialityid); + + if(courseids_ != null && courseids_.size() > 0){ + criteria.andCourseidIn(courseids_); + curriculums = curriculumMapper.selectByExample(example); + } + + return curriculums; } } diff --git a/src/cn/edu/hrbcu/curriculum/service/TbUserService.java b/src/cn/edu/hrbcu/curriculum/service/TbUserService.java index 525a6a393d19e91c26a8cd1d02c0610c068f2b49..4aea5cdba8a715863685f2562afd56eaf7fdde9c 100644 --- a/src/cn/edu/hrbcu/curriculum/service/TbUserService.java +++ b/src/cn/edu/hrbcu/curriculum/service/TbUserService.java @@ -5,7 +5,7 @@ import cn.edu.hrbcu.curriculum.pojo.TbUser; public interface TbUserService { - int insertUser(TbUser user); + Boolean insertUser(TbUser user); List selectUserByLoginname(String username); @@ -18,5 +18,7 @@ public interface TbUserService { List selectTbUsers(int currentPage); List selectAllUser(); + + boolean registerData(TbUser user); } diff --git a/src/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.java b/src/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.java index ec78cad3f7f2d1ed2071d8df55a1327b6f41a2b3..f5fd7287bb28298b7a87295254e5b25e7b253c68 100644 --- a/src/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.java +++ b/src/cn/edu/hrbcu/curriculum/service/TbUserServiceImpl.java @@ -1,7 +1,11 @@ package cn.edu.hrbcu.curriculum.service; +import java.util.HashMap; import java.util.List; +import java.util.Map; +import org.apache.shiro.crypto.hash.SimpleHash; +import org.apache.shiro.util.ByteSource; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @@ -11,6 +15,7 @@ import cn.edu.hrbcu.curriculum.dao.TbUserMapper; import cn.edu.hrbcu.curriculum.pojo.TbUser; import cn.edu.hrbcu.curriculum.pojo.TbUserExample; import cn.edu.hrbcu.utils.Common; +import cn.edu.hrbcu.utils.UuidUtil; @Service @@ -20,9 +25,9 @@ public class TbUserServiceImpl implements TbUserService{ TbUserMapper bUserMapper; @Override - public int insertUser(TbUser user) { + public Boolean insertUser(TbUser user) { // TODO Auto-generated method stub - return bUserMapper.insert(user); + return registerData(user); } @Override @@ -75,5 +80,32 @@ public class TbUserServiceImpl implements TbUserService{ } + @Override + public boolean registerData(TbUser user) { + // 生成uuid + String id = UuidUtil.get32UUID(); + + // 将用户名作为盐值 + ByteSource salt = ByteSource.Util.bytes(user.getLoginname()); + /* + * MD5加密: + * 使用SimpleHash类对原始密码进行加密。 + * 第一个参数代表使用MD5方式加密 + * 第二个参数为原始密码 + * 第三个参数为盐值,即用户名 + * 第四个参数为加密次数 + * 最后用toHex()方法将加密后的密码转成String + * */ + String newPs = new SimpleHash("MD5", user.getPassword(), salt, 1024).toHex(); + + user.setPassword(newPs); + // 看数据库中是否存在该账户 + List userInfo = selectUserByLoginname(user.getLoginname()); + if(userInfo == null || userInfo.size() == 0) { + bUserMapper.insert(user); + return true; + } + return false; + } } diff --git a/src/cn/edu/hrbcu/shiro/ShiroRealm.java b/src/cn/edu/hrbcu/shiro/ShiroRealm.java index 4ae45f5843333e50c82d45df606e0a89ecffad41..c302bdbf37d512b66dcebf3917bfd04000a3847b 100644 --- a/src/cn/edu/hrbcu/shiro/ShiroRealm.java +++ b/src/cn/edu/hrbcu/shiro/ShiroRealm.java @@ -26,7 +26,6 @@ public class ShiroRealm extends AuthenticatingRealm{ throws AuthenticationException { //1.强转 UsernamePasswordToken upToken = (UsernamePasswordToken) token; - //2.获取系统管理员账号 String username = upToken.getUsername(); diff --git a/src/cn/edu/hrbcu/utils/CharacterUtil.java b/src/cn/edu/hrbcu/utils/CharacterUtil.java new file mode 100644 index 0000000000000000000000000000000000000000..3795b41aa9a8125758635ab4a236c776049a90da --- /dev/null +++ b/src/cn/edu/hrbcu/utils/CharacterUtil.java @@ -0,0 +1,12 @@ +package cn.edu.hrbcu.utils; + +public class CharacterUtil { + public static final String[] roman_char = { "I", "II", "III", "IV", "V", "VI", "VII", "VIII", "IX"}; + + public static String num2roman(Integer num){ + if(num == null) + return ""; + + return roman_char[num - 1]; + } +} diff --git a/src/cn/edu/hrbcu/utils/UuidUtil.java b/src/cn/edu/hrbcu/utils/UuidUtil.java new file mode 100644 index 0000000000000000000000000000000000000000..a1f884578a083bba8fb482cb3d50d20ac5e75bdd --- /dev/null +++ b/src/cn/edu/hrbcu/utils/UuidUtil.java @@ -0,0 +1,10 @@ +package cn.edu.hrbcu.utils; + +import java.util.UUID; + +public class UuidUtil { + public static String get32UUID() { + String uuid = UUID.randomUUID().toString().trim().replaceAll("-", ""); + return uuid; + } +}