From e99324b70510afdff4175a484e976cb0e804411b Mon Sep 17 00:00:00 2001
From: luo <2855143437@qq.com>
Date: 星期一, 25 九月 2023 16:18:45 +0800
Subject: [PATCH] 9.25
---
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java | 29
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord2.html | 57 +
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java | 23
cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html | 2
package-lock.json | 207 +++++
cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml | 7
cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js | 62 +
cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java | 60 +
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html | 3
cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml | 1
cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java | 2
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord3.html | 57 +
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js | 13
.idea/workspace.xml | 115 ++
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html | 4
cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml | 3
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord3.js | 259 ++++++
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js | 18
cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java | 2
cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html | 9
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js | 27
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html | 34
cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java | 1
cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java | 2
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html | 85 +
cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java | 4
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html | 2
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js | 66 +
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html | 393 ++++++---
cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java | 2
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js | 2
cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java | 8
cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java | 11
cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java | 6
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java | 163 +++
cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html | 38
cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java | 9
cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord2.js | 259 ++++++
package.json | 6
cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java | 8
cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java | 2
cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon1.html | 79 +
cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java | 2
cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html | 285 +++---
44 files changed, 1,978 insertions(+), 449 deletions(-)
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 3dda1b2..12c2504 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -22,7 +22,45 @@
<select />
</component>
<component name="ChangeListManager">
- <list default="true" id="cb08d02f-fd4f-4fa2-85fe-abd508fa83ac" name="Default Changelist" comment="学员2" />
+ <list default="true" id="cb08d02f-fd4f-4fa2-85fe-abd508fa83ac" name="Default Changelist" comment="学员4">
+ <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js" afterDir="false" />
+ <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js" afterDir="false" />
+ </list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
@@ -56,6 +94,9 @@
</MavenGeneralSettings>
</option>
</component>
+ <component name="PackageJsonUpdateNotifier">
+ <dismissed value="$PROJECT_DIR$/package.json" />
+ </component>
<component name="ProjectId" id="2T0poWYlZShlnPso29uxjn4gQQo" />
<component name="ProjectLevelVcsManager" settingsEditedManually="true">
<ConfirmationsSetting value="1" id="Add" />
@@ -64,39 +105,42 @@
<option name="hideEmptyMiddlePackages" value="true" />
<option name="showLibraryContents" value="true" />
</component>
- <component name="PropertiesComponent">{
- "keyToString": {
- "DefaultHtmlFileTemplate": "HTML File",
- "RequestMappingsPanelOrder0": "0",
- "RequestMappingsPanelOrder1": "1",
- "RequestMappingsPanelWidth0": "75",
- "RequestMappingsPanelWidth1": "75",
- "WebServerToolWindowFactoryState": "false",
- "git-widget-placeholder": "master",
- "ignore.virus.scanning.warn.message": "true",
- "last_opened_file_path": "D:/JavaTool/PlayPai1/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent",
- "node.js.detected.package.eslint": "true",
- "node.js.detected.package.tslint": "true",
- "node.js.selected.package.eslint": "(autodetect)",
- "node.js.selected.package.tslint": "(autodetect)",
- "nodejs_package_manager_path": "npm",
- "project.structure.last.edited": "模块",
- "project.structure.proportion": "0.15",
- "project.structure.side.proportion": "0.54367816",
- "settings.editor.selected.configurable": "MavenSettings",
- "spring.configuration.checksum": "b0c8222ba40624e179f539b98c2e8cad",
- "vue.rearranger.settings.migration": "true"
+ <component name="PropertiesComponent"><![CDATA[{
+ "keyToString": {
+ "DefaultHtmlFileTemplate": "HTML File",
+ "RequestMappingsPanelOrder0": "0",
+ "RequestMappingsPanelOrder1": "1",
+ "RequestMappingsPanelWidth0": "75",
+ "RequestMappingsPanelWidth1": "75",
+ "RunOnceActivity.OpenProjectViewOnStart": "true",
+ "RunOnceActivity.ShowReadmeOnStart": "true",
+ "WebServerToolWindowFactoryState": "false",
+ "git-widget-placeholder": "master",
+ "ignore.virus.scanning.warn.message": "true",
+ "last_opened_file_path": "D:/JavaTool/PlayPai1/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage",
+ "node.js.detected.package.eslint": "true",
+ "node.js.detected.package.tslint": "true",
+ "node.js.selected.package.eslint": "(autodetect)",
+ "node.js.selected.package.tslint": "(autodetect)",
+ "nodejs_package_manager_path": "npm",
+ "project.structure.last.edited": "模块",
+ "project.structure.proportion": "0.15",
+ "project.structure.side.proportion": "0.54367816",
+ "service.view.auto.scroll.to.source": "true",
+ "settings.editor.selected.configurable": "MavenSettings",
+ "spring.configuration.checksum": "b0c8222ba40624e179f539b98c2e8cad",
+ "vue.rearranger.settings.migration": "true"
}
-}</component>
+}]]></component>
<component name="ReactorSettings">
<option name="notificationShown" value="true" />
</component>
<component name="RecentsManager">
<key name="CopyFile.RECENT_KEYS">
- <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\WEB-INF\view\system\tStudent" />
- <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\static\modular\system\coursePackage" />
- <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\static\modular\system\tCoupon" />
<recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\WEB-INF\view\system\coursePackage" />
+ <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\static\modular\system\coursePackage" />
+ <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\WEB-INF\view\system\tStudent" />
+ <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\static\modular\system\tCoupon" />
<recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\WEB-INF\view\system" />
</key>
<key name="MoveFile.RECENT_KEYS">
@@ -272,7 +316,9 @@
<workItem from="1695255303249" duration="37521000" />
<workItem from="1695342171677" duration="37810000" />
<workItem from="1695430054273" duration="24454000" />
- <workItem from="1695461202457" duration="322000" />
+ <workItem from="1695461202457" duration="3973000" />
+ <workItem from="1695520475699" duration="28522000" />
+ <workItem from="1695602623205" duration="20433000" />
</task>
<task id="LOCAL-00001" summary="后台代码删除">
<created>1690249807612</created>
@@ -389,7 +435,15 @@
<option name="project" value="LOCAL" />
<updated>1695461216122</updated>
</task>
- <option name="localTasksCounter" value="17" />
+ <task id="LOCAL-00017" summary="学员4">
+ <option name="closed" value="true" />
+ <created>1695461535365</created>
+ <option name="number" value="00017" />
+ <option name="presentableId" value="LOCAL-00017" />
+ <option name="project" value="LOCAL" />
+ <updated>1695461535365</updated>
+ </task>
+ <option name="localTasksCounter" value="18" />
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
@@ -412,7 +466,8 @@
<MESSAGE value="9.15" />
<MESSAGE value="学员" />
<MESSAGE value="学员2" />
- <option name="LAST_COMMIT_MESSAGE" value="学员2" />
+ <MESSAGE value="学员4" />
+ <option name="LAST_COMMIT_MESSAGE" value="学员4" />
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
diff --git a/cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java b/cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java
index 631575c..2bd56b6 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/controller/CourseStudentController.java
@@ -105,14 +105,16 @@
//获取可转移学员
@RequestMapping("/getSelect")
@ResponseBody
- public List<SelectDto> getSelect(@RequestParam("payId")Integer payId){
+ public List<SelectDto> getSelect(@RequestParam("payId")Long payId){
List<Integer> studentIds = paymentService.getStudentIds(payId);
System.out.println("=========studentIds=================>"+studentIds);
+ if (studentIds.size()>0){
List<SelectDto> selectDtos = appUserClient.getSelects(studentIds);
- return selectDtos;
+ return selectDtos;}
+ else return null;
}
@@ -214,6 +216,15 @@
moneyBack.setIds(insertBackDto.getIds());
moneyBackService.save(moneyBack);
+ List<TCoursePackagePayment> pays = paymentService.list(new QueryWrapper<TCoursePackagePayment>().in("id", insertBackDto.getIds()));
+ for (TCoursePackagePayment o :pays){
+ o.setStatus(4);
+ o.setAppUserId(null);
+ }
+
+
+
+ paymentService.updateBatchById(pays);
}
@@ -236,6 +247,15 @@
}
+ @RequestMapping("/noStatus")
+ @ResponseBody
+ public void noStatus(@RequestParam("id")Integer id){
+ MoneyBack byId = moneyBackService.getById(id);
+ byId.setStatus(2);
+ moneyBackService.updateById(byId);
+
+ }
+
@RequestMapping("/zeroClass")
@ResponseBody
public void zeroClass(@RequestParam("id")Integer id){
@@ -244,20 +264,47 @@
System.out.println("========split===>"+split);
List<TCoursePackagePayment> id1 = paymentService.list(new QueryWrapper<TCoursePackagePayment>().in("id", split));
for (TCoursePackagePayment o :id1){
+ CourseCounsum courseCounsum = new CourseCounsum();
+ courseCounsum.setNum(o.getLaveClassHours());
+ courseCounsum.setChangeType(0);
+ courseCounsum.setReason("退费");
+ courseCounsum.setPaymentId(o.getId());
+ courseCounsum.setInsertTime(new Date());
+ counsumService.save(courseCounsum);
+
o.setTotalClassHours(0);
o.setLaveClassHours(0);
+ o.setStatus(2);
o.setAppUserId(null);
+
+
+
+
}
paymentService.updateBatchById(id1);
}
+
+ @RequestMapping("/backStausClass")
+ @ResponseBody
+ public void backStausClass(@RequestParam("id")Integer id){
+ MoneyBack byId = moneyBackService.getById(id);
+ String[] split = byId.getIds().split(",");
+ System.out.println("========split===>"+split);
+ List<TCoursePackagePayment> id1 = paymentService.list(new QueryWrapper<TCoursePackagePayment>().in("id", split));
+ for (TCoursePackagePayment o :id1){
+ o.setStatus(1);
+ o.setAppUserId(null);
+ }
+ paymentService.updateBatchById(id1);
+ }
@RequestMapping("/cancel")
@ResponseBody
public void cancel(@RequestParam("ids")String ids){
String[] split = ids.split(",");
List<CoursePackageStudent> coursePackagePaymentId = studentService.list(new QueryWrapper<CoursePackageStudent>().in("coursePackagePaymentId", split));
for (CoursePackageStudent student :coursePackagePaymentId){
- student.setReservationStatus(2);
+ student.setReservationStatus(3);
student.setAppUserId(null);
}
studentService.updateBatchById(coursePackagePaymentId);
@@ -290,12 +337,16 @@
orinPay.setTotalClassHours(0);
orinPay.setLaveClassHours(0);
+ orinPay.setStatus(5);
orinPay.setAppUserId(null);
paymentService.updateById(orinPay);
CourseCounsum courseCounsum = new CourseCounsum();
courseCounsum.setInsertTime(new Date());
- courseCounsum.setReason("转课");
+ if (orinPay.getAppUserId()!=studentPay.getAppUserId()){
+ courseCounsum.setReason("赠课");
+ }else { courseCounsum.setReason("转课");
+ }
courseCounsum.setNum(laveClassHours);
courseCounsum.setChangeType(0);
courseCounsum.setPaymentId(orinPay.getId());
@@ -326,6 +377,7 @@
orinPay.setTotalClassHours(0);
orinPay.setLaveClassHours(0);
orinPay.setAppUserId(null);
+ orinPay.setStudentId(6);
paymentService.updateById(orinPay);
diff --git a/cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java b/cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java
index e9c4168..9158eac 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/entity/TCoursePackage.java
@@ -169,10 +169,12 @@
private Integer type;
@TableField("needNum")
private Integer needNum;
+
+ @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
@TableField("startTime")
- @JsonFormat(pattern = "yyyy.MM.dd", timezone = "GMT+8")
private Date startTime;
+
+ @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
@TableField("endTime")
- @JsonFormat(pattern = "yyyy.MM.dd", timezone = "GMT+8")
private Date endTime;
}
diff --git a/cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java b/cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java
index ea49194..b596bce 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/entity/dto/ConsumeQuery.java
@@ -14,5 +14,5 @@
String reason;
- Integer payId;
+ Long payId;
}
diff --git a/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java b/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java
index 6881ae8..6cf9d59 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java
@@ -61,7 +61,7 @@
void updateUseTime(@Param("id")Long id, @Param("date") Date date);
- List<Integer> getStudentIds(@Param("id")Integer payId);
+ List<Integer> getStudentIds(@Param("id")Long payId);
boolean updateHoursById(@Param("id") Long id, @Param("i") int i);
}
diff --git a/cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java b/cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java
index 2f28104..b9668dd 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/model/dto/ToClassDto.java
@@ -4,6 +4,6 @@
@Data
public class ToClassDto {
- Integer id;
+ Long id;
Integer toStudentId;
}
diff --git a/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java b/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java
index fbb40ef..f017ec9 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java
@@ -119,7 +119,7 @@
void updateUseTime(Long id, Date date);
- List<Integer> getStudentIds(Integer payId);
+ List<Integer> getStudentIds(Long payId);
boolean updateHoursById(TCoursePackagePayment byId, int i);
diff --git a/cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java b/cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java
index 97cab75..7715d66 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/service/impl/CoursePackageSchedulingServiceImpl.java
@@ -52,8 +52,10 @@
for (Map<String, Object> map : list) {
Long id = Long.valueOf(map.get("id").toString());
int count = coursePackageStudentService.count(new QueryWrapper<CoursePackageStudent>().eq("coursePackageSchedulingId", id).eq("reservationStatus", 1));
- map.put("registered", count);
+// map.put("registered", count);
int count1 = coursePackageStudentService.count(new QueryWrapper<CoursePackageStudent>().eq("coursePackageSchedulingId", id).eq("signInOrNot", 1));
+ int count2 = coursePackageStudentService.count(new QueryWrapper<CoursePackageStudent>().eq("coursePackageSchedulingId", id).eq("signInOrNot", 2));
+ map.put("registered", count2);
map.put("actualArrival", count1);
map.put("nonArrival", count - count1);
}
diff --git a/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java b/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java
index 0dbc7eb..4ab628d 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java
@@ -724,6 +724,7 @@
}
List<Map<String, Object>> list = this.baseMapper.queryRegistrationRecord(page, coursePackageId, userIds, studentIds);
for (Map<String, Object> map : list) {
+
Long id = Long.valueOf(map.get("id").toString());
Integer appUserId = Integer.valueOf(map.get("appUserId").toString());
Integer studentId = Integer.valueOf(map.get("studentId").toString());
@@ -733,8 +734,12 @@
Student student = studentClient.queryStudentById(studentId);
map.put("studentName", null != student ? student.getName() : "");
Integer integer = cpsMapper.selectCount(new QueryWrapper<CoursePackageStudent>().eq("appUserId", appUserId)
- .eq("studentId", studentId).eq("coursePackagePaymentId", id).eq("signInOrNot", 1));
+ .eq("studentId", studentId).eq("coursePackagePaymentId", id).eq("signInOrNot", 2));
map.put("already", integer);
+// if (student != null && student.getName().equals("杨锴1")) {
+// map.put("totalClassHours", "测试");
+// }
+ ;
}
return list;
}
@@ -1032,7 +1037,7 @@
}
@Override
- public List<Integer> getStudentIds(Integer payId) {
+ public List<Integer> getStudentIds(Long payId) {
return this.baseMapper.getStudentIds(payId);
}
diff --git a/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java b/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java
index 47cb089..ee64ebb 100644
--- a/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java
+++ b/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java
@@ -1213,6 +1213,7 @@
@Override
public Integer addCoursePackage(TCoursePackage coursePackage) {
try {
+ coursePackage.setAuditStatus(2);
this.baseMapper.insert(coursePackage);
//生成排课数据
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
diff --git a/cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml b/cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml
index 72b98e5..e142ec7 100644
--- a/cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml
+++ b/cloud-server-course/src/main/resources/mapper/CoursePackageStudentMapper.xml
@@ -14,6 +14,7 @@
signInOrNot,
reservationStatus
from t_course_package_student where coursePackageSchedulingId = #{coursePackageSchedulingId}
+ and reservationStatus != 3
<if test="null != userId">
and appUserId in
<foreach collection="appUserId" item="item" index="index" separator="," open="(" close=")">
diff --git a/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml b/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml
index 8fc1230..fed58b5 100644
--- a/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml
+++ b/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml
@@ -65,7 +65,8 @@
CONCAT('购买后', a.validDays, '天内有效') as validDays,
a.sort,
a.`status`,
- a.state
+ a.state,
+ a.type
from t_course_package a
left join t_course_package_type b on (a.coursePackageTypeId = b.id)
where a.state != 3 and a.auditStatus = 2
diff --git a/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml b/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml
index 64e77bc..74a7466 100644
--- a/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml
+++ b/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml
@@ -73,6 +73,7 @@
studentId,
DATE_FORMAT(insertTime, '%Y-%m-%d %H:%i') as insertTime,
totalClassHours,
+ laveClassHours,
absencesNumber,
`status`
from t_course_package_payment where payStatus = 2 and state = 1
@@ -91,7 +92,11 @@
#{item}
</foreach>
</if>
- order by insertTime desc
+ order by
+ CASE
+ WHEN laveClassHours < 3 THEN 0
+ ELSE 1
+ END, insertTime DESC
</select>
diff --git a/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java b/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java
index c7528fb..30dd1e0 100644
--- a/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java
+++ b/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseStuddentClient.java
@@ -69,7 +69,7 @@
* @return
*/
@RequestMapping("/courdent/getSelect")
- List<SelectDto> getSelect(@RequestParam("payId") Integer payId);
+ List<SelectDto> getSelect(@RequestParam("payId") Long payId);
/**
* 转移课程
* @param toClassDto
@@ -111,8 +111,14 @@
@RequestMapping("/courdent/changeStatus")
void changeStatus(@RequestParam("id")Integer id);
+
+ @RequestMapping("/courdent/noStatus")
+ void noStatus(@RequestParam("id")Integer id);
@RequestMapping("/courdent/cancel")
void cancel(@RequestParam("ids")String ids);
@RequestMapping("/courdent/zeroClass")
void zeroClass(@RequestParam("id")Integer id);
+
+ @RequestMapping("/courdent/backStausClass")
+ void backStausClass(@RequestParam("id")Integer id);
}
diff --git a/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java b/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java
index 2f040b1..2a4dd9f 100644
--- a/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java
+++ b/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/model/TCoursePackage.java
@@ -128,4 +128,12 @@
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date insertTime;
+
+ private Integer type;
+ private String holitime;
+ @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
+ private Date startTime;
+ @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
+
+ private Date endTime;
}
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java
index fcef6e6..d7a784b 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TCoursePackageController.java
@@ -28,6 +28,9 @@
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
+import java.text.DateFormat;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
import java.util.*;
/**
@@ -144,7 +147,9 @@
List<Coach> coaches = coachClient.queryCoachByCity(code1);
model.addAttribute("coach", coaches);
-// System.out.println("========type========"+type);
+
+ model.addAttribute("type",type);
+ System.out.println("========type========"+type);
// if (type ==1){
// return PREFIX + "coursePackage_edit.html";
// }
@@ -162,6 +167,36 @@
public String openEditCoursePackage(Model model, Integer id){
TCoursePackage tCoursePackage = coursePackageService.queryById(id);
model.addAttribute("item", tCoursePackage);
+ model.addAttribute("type", tCoursePackage.getType());
+
+ String classStartTime = tCoursePackage.getClassStartTime();
+ String classEndTime = tCoursePackage.getClassEndTime();
+
+ if (tCoursePackage.getStartTime()!=null) {
+ SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
+ String dateString = sdf.format(tCoursePackage.getStartTime());
+ String dateString1 = sdf.format(tCoursePackage.getEndTime());
+ model.addAttribute("holi", dateString + " - " + dateString1);
+ }
+ String[] split1 = classStartTime.split(",");
+ String[] split2 = classEndTime.split(",");
+
+ List<String> listtime = new ArrayList<>();
+
+ for (int i = 0; i < split1.length; i++) {
+ String o = split1[i]+"-"+split2[i];
+ listtime.add(o);
+ }
+
+
+ model.addAttribute("time1",listtime.remove(0));
+ if (listtime.size()!=0) {
+ model.addAttribute("times", listtime);
+ }
+
+
+
+
model.addAttribute("classTime", tCoursePackage.getClassStartTime() + ":00 - " + tCoursePackage.getClassEndTime() + ":00");
String[] split = tCoursePackage.getClassWeeks().split(";");
List<String> list5 = Arrays.asList("周一", "周二", "周三", "周四", "周五", "周六", "周日");
@@ -193,10 +228,17 @@
List<Coach> coaches = coachClient.queryCoachByCity(cityCode);
model.addAttribute("coach", coaches);
List<CoursePackagePaymentConfig> list4 = coursePackagePaymentConfigClient.queryCoursePackagePaymentConfigList(id);
+
+
System.out.println("========couponIds=========>"+list4.get(0).getCouponIds());
model.addAttribute("couponIds", list4.get(0).getCouponIds());
model.addAttribute("coursePackagePaymentConfig", list4.remove(0));
+ for (int i = 0; i < list4.size(); i++) {
+ list4.get(i).setId(i+2);
+ }
+
model.addAttribute("coursePackagePaymentConfigs", list4);
+ model.addAttribute("index", 1);
CoursePackagePaymentConfig coursePackagePaymentConfig = list4.get(0);
// if (list4.size()!=0) {
model.addAttribute("cashPayment", coursePackagePaymentConfig.getCashPayment() == 0 ? false : true);
@@ -218,6 +260,36 @@
public String showCoursePackageDetails(Model model, Integer id){
TCoursePackage tCoursePackage = coursePackageService.queryById(id);
model.addAttribute("item", tCoursePackage);
+ model.addAttribute("type", tCoursePackage.getType());
+
+ String classStartTime = tCoursePackage.getClassStartTime();
+ String classEndTime = tCoursePackage.getClassEndTime();
+
+ if (tCoursePackage.getStartTime()!=null) {
+ SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
+ String dateString = sdf.format(tCoursePackage.getStartTime());
+ String dateString1 = sdf.format(tCoursePackage.getEndTime());
+ model.addAttribute("holi", dateString + " - " + dateString1);
+ }
+ String[] split1 = classStartTime.split(",");
+ String[] split2 = classEndTime.split(",");
+
+ List<String> listtime = new ArrayList<>();
+
+ for (int i = 0; i < split1.length; i++) {
+ String o = split1[i]+"-"+split2[i];
+ listtime.add(o);
+ }
+
+
+ model.addAttribute("time1",listtime.remove(0));
+ if (listtime.size()!=0) {
+ model.addAttribute("times", listtime);
+ }
+
+
+
+
model.addAttribute("classTime", tCoursePackage.getClassStartTime() + ":00 - " + tCoursePackage.getClassEndTime() + ":00");
String[] split = tCoursePackage.getClassWeeks().split(";");
List<String> list5 = Arrays.asList("周一", "周二", "周三", "周四", "周五", "周六", "周日");
@@ -249,12 +321,24 @@
List<Coach> coaches = coachClient.queryCoachByCity(cityCode);
model.addAttribute("coach", coaches);
List<CoursePackagePaymentConfig> list4 = coursePackagePaymentConfigClient.queryCoursePackagePaymentConfigList(id);
+
+
+ System.out.println("========couponIds=========>"+list4.get(0).getCouponIds());
+ model.addAttribute("couponIds", list4.get(0).getCouponIds());
model.addAttribute("coursePackagePaymentConfig", list4.remove(0));
+ for (int i = 0; i < list4.size(); i++) {
+ list4.get(i).setId(i+2);
+ }
+
model.addAttribute("coursePackagePaymentConfigs", list4);
+ model.addAttribute("index", 1);
CoursePackagePaymentConfig coursePackagePaymentConfig = list4.get(0);
+// if (list4.size()!=0) {
model.addAttribute("cashPayment", coursePackagePaymentConfig.getCashPayment() == 0 ? false : true);
model.addAttribute("playPaiCoin", coursePackagePaymentConfig.getPlayPaiCoin() == 0 ? false : true);
-// model.addAttribute("couponIds", coursePackagePaymentConfig.getCouponIds());
+ System.out.println("=========coursePackagePaymentConfig=============>" + coursePackagePaymentConfig);
+// model.addAttribute("couponIds", "3,2");
+// }
return PREFIX + "coursePackage_info.html";
}
@@ -314,7 +398,12 @@
model.addAttribute("index",id);
model.addAttribute("conpund",conpunids);
- return PREFIX + "TCouponEdit.html";
+
+ if (conpunids!=null){
+ return PREFIX + "TCoupon1.html";
+ }
+
+ return PREFIX + "TCoupon.html";
}
/**
@@ -324,10 +413,19 @@
* @return
*/
@GetMapping("/registrationRecord")
- public String registrationRecord(Model model, Integer id){
+ public String registrationRecord(Model model, Integer id,Integer type){
TCoursePackage tCoursePackage = coursePackageService.queryById(id);
model.addAttribute("item", tCoursePackage);
- return PREFIX + "registrationRecord.html";
+ model.addAttribute("type", type);
+ if (type ==1){
+ return PREFIX + "registrationRecord.html";}
+ if (type == 2){
+ return PREFIX + "registrationRecord2.html";
+ }
+ if (type == 3){
+ return PREFIX + "registrationRecord3.html";
+ }
+ return "registrationRecord.html";
}
@@ -552,9 +650,24 @@
*/
@ResponseBody
@PostMapping("/addCoursePackage")
- public ResultUtil addCoursePackage(TCoursePackage coursePackage, String coursePackagePaymentConfig){
+ public ResultUtil addCoursePackage(TCoursePackage coursePackage, String coursePackagePaymentConfig) throws ParseException {
String classStartTime = coursePackage.getClassStartTime();
// String classEndTime = coursePackage.getClassEndTime();
+ Date startDate = null;
+ Date endDate =null ;
+
+ String holitime = coursePackage.getHolitime();
+ if (holitime!=null&&holitime!="") {
+ String[] dateParts = holitime.split(" - ");
+ String startDateString = dateParts[0];
+ String endDateString = dateParts[1];
+
+ DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
+ startDate = dateFormat.parse(startDateString);
+ endDate = dateFormat.parse(endDateString);
+
+ }
+
System.out.println("=======getClassStartTime============"+classStartTime);
String startTime = coursePackage.getClassStartTime();
@@ -579,6 +692,10 @@
System.out.println("=========secondString========>"+secondString);
// classStartTime = classStartTime.substring(0, classStartTime.lastIndexOf(":"));
// classEndTime = classEndTime.substring(0, classEndTime.lastIndexOf(":"));
+
+ coursePackage.setStartTime(startDate);
+ coursePackage.setEndTime(endDate);
+
coursePackage.setClassStartTime(firstString);
coursePackage.setClassEndTime(secondString);
coursePackage.setAuditStatus(1);
@@ -599,12 +716,34 @@
@ResponseBody
@PostMapping("/updateCoursePackage")
public ResultUtil updateCoursePackage(TCoursePackage coursePackage, String coursePackagePaymentConfig){
- String classStartTime = coursePackage.getClassStartTime();
- String classEndTime = coursePackage.getClassEndTime();
- classStartTime = classStartTime.substring(0, classStartTime.lastIndexOf(":"));
- classEndTime = classEndTime.substring(0, classEndTime.lastIndexOf(":"));
- coursePackage.setClassStartTime(classStartTime);
- coursePackage.setClassEndTime(classEndTime);
+
+// System.out.println("=======getClassStartTime============"+classStartTime);
+ String startTime = coursePackage.getClassStartTime();
+ JSONArray jsonArray = JSON.parseArray(startTime);
+ System.out.println("=======jsonArray==========="+jsonArray);
+
+ List<String> first = new ArrayList<>();
+ List<String> second = new ArrayList<>();
+ for (int i = 0; i < jsonArray.size(); i++) {
+// JSONObject jsonObject = JSON.parseObject(jsonArray.getString(i));
+
+ String jsonString = jsonArray.getString(i);
+ String[] split = jsonString.split("-");
+ first.add(split[0]);
+ second.add(split[1]);
+
+ }
+ String firstString = String.join(",",first);
+ String secondString = String.join(",",second);
+ System.out.println("=========firstString========>"+firstString);
+
+ System.out.println("=========secondString========>"+secondString);
+// String classStartTime = coursePackage.getClassStartTime();
+// String classEndTime = coursePackage.getClassEndTime();
+// classStartTime = classStartTime.substring(0, classStartTime.lastIndexOf(":"));
+// classEndTime = classEndTime.substring(0, classEndTime.lastIndexOf(":"));
+ coursePackage.setClassStartTime(firstString);
+ coursePackage.setClassEndTime(secondString);
coursePackageService.updateCoursePackage(coursePackage, coursePackagePaymentConfig);
return ResultUtil.success();
}
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java
index 5373667..7ac3954 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/TStudentController.java
@@ -104,7 +104,7 @@
*/
@RequestMapping("/changelist/{payId}")
@ResponseBody
- public ResultUtil changelist(@PathVariable("payId") Integer payId, ConsumeQuery consumeQuery) {
+ public ResultUtil changelist(@PathVariable("payId") Long payId, ConsumeQuery consumeQuery) {
consumeQuery.setPayId(payId);
System.out.println("=======changelist==========="+consumeQuery);
List<CourseCounsum> courseCounsums = courseStuddentClient.queryCounsum(consumeQuery);
@@ -360,6 +360,8 @@
return ResultUtil.success();
}
+//同意退款
+
@RequestMapping("/changeStatus/{id}")
@ResponseBody
public ResultUtil changeStatus(@PathVariable Integer id) {
@@ -375,6 +377,21 @@
return new ResultUtil<>(0,0,"同意成功",null,null);
}
+ @RequestMapping("/noStatus/{id}")
+ @ResponseBody
+ public ResultUtil noStatus(@PathVariable Integer id) {
+// InsertBackDto insertBackDto= new InsertBackDto();
+// insertBackDto.setId(id);
+//// insertBackDto.setIds(ids);
+// System.out.println("=====insertBackDto========"+insertBackDto);
+
+ courseStuddentClient.changeStatus(id);
+ courseStuddentClient.backStausClass(id);
+// courseStuddentClient.zeroClass(id);
+
+ System.out.println("============学员查询接口=========");
+ return new ResultUtil<>(0,0,"同意成功",null,null);
+ }
/**
* 学员修改
@@ -430,7 +447,7 @@
historyClient.createHistory(historyDto);
- return ResultUtil.success();
+ return new ResultUtil<>(0,0,"更改成功",null,null);
}
@@ -453,7 +470,7 @@
*/
@RequestMapping(value = "/getUserSlect/{id}")
@ResponseBody
- public ResultUtil getUserSlect(@PathVariable("id") Integer payId) {
+ public ResultUtil getUserSlect(@PathVariable("id") Long payId) {
List<SelectDto> selectDtos = courseStuddentClient.getSelect(payId);
Map<String,List<SelectDto>> map = new HashMap<>();
@@ -466,7 +483,7 @@
*/
@RequestMapping(value = "/toClass")
@ResponseBody
- public ResultUtil toClass( Integer id,Integer toStudentId) {
+ public ResultUtil toClass( Long id,Integer toStudentId) {
ToClassDto toClassDto = new ToClassDto();
toClassDto.setToStudentId(toStudentId);
toClassDto.setId(id);
@@ -536,7 +553,7 @@
System.out.println("========ToHoliDto========="+resultUtil);
- if (resultUtil==""){
+ if (resultUtil==""||resultUtil==null){
return new ResultUtil<>(0,0,"报名成功");
}else
return new ResultUtil<>(0,0,"报名成功,以下学员剩余课时不足"+resultUtil);
@@ -570,7 +587,7 @@
@RequestMapping(value = "/giftTo")
@ResponseBody
- public ResultUtil toClagiftToss( Integer id,Integer toStudentId) {
+ public ResultUtil toClagiftToss( Long id,Integer toStudentId) {
ToClassDto toClassDto = new ToClassDto();
toClassDto.setToStudentId(toStudentId);
toClassDto.setId(id);
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java
index eac0099..6c71237 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/UserMgrController.java
@@ -389,6 +389,29 @@
return pictureName;
}
+ /**
+ * 上传图片
+ */
+ /**
+ * 上传图片Amis
+ */
+ @RequestMapping(method = RequestMethod.POST, path = "/uploadImgAmis")
+ @ResponseBody
+ public ResultUtil uploadImgAmis(@RequestPart("file") MultipartFile picture, HttpServletResponse response) {
+ String value = "";
+ try {
+ value = OssUploadUtil.ossUpload("img/", picture);
+ }catch (Exception e){
+ e.printStackTrace();
+ }
+ System.out.println("图片返回地址-------"+value);
+ Map<String, String> map = new HashMap<>();
+ map.put("value",value);
+// return ResultUtil.success(0,map);
+ return ResultUtil.getResult(0,null,null,map);
+ }
+
+
@RequestMapping(method = RequestMethod.POST, path = "/uploadFile")
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java
index cb17e8b..b75ae45 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ConsumeQuery.java
@@ -15,5 +15,5 @@
String reason;
- Integer payId;
+ Long payId;
}
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java
index 5ac720f..171f747 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/dto/ToClassDto.java
@@ -5,6 +5,6 @@
@Data
public class ToClassDto {
- Integer id;
+ Long id;
Integer toStudentId;
}
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java
index 5fa98fd..91de37d 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/service/impl/CoursePackageService.java
@@ -461,10 +461,17 @@
continue;
}
TCoursePackagePayment tCoursePackagePayment = coursePackagePaymentClient.queryCoursePackagePaymentById(coursePackageStudent.getCoursePackagePaymentId());
+
+ if(tCoursePackagePayment.getLaveClassHours() - deductClassHour<0){
+ coursePackageStudentClient.editCoursePackageStudent(coursePackageStudent);
+ continue;
+ }
tCoursePackagePayment.setLaveClassHours(tCoursePackagePayment.getLaveClassHours() - deductClassHour);
-// if(coursePackageStudent.getSignInOrNot() == 0){
+
+
+ if(coursePackageStudent.getSignInOrNot() == 0){
tCoursePackagePayment.setAbsencesNumber(tCoursePackagePayment.getAbsencesNumber() + 1);
-// }
+ }
coursePackagePaymentClient.editCoursePackagePayment(tCoursePackagePayment);
CancelledClasses cancelledClasses = new CancelledClasses();
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html
index 670f376..16670f0 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon.html
@@ -67,7 +67,7 @@
<!-- <#button name="领取记录" icon="fa-remove" clickFun="TCoupon.openCollectionRecord()" space="true" hidden='hidden'/>-->
<!-- </div>-->
<#table id="TCouponTable"/>
- <div style="display: flex"> <#button name="添加" icon="fa-plus" clickFun="TCoupon.backids(${index})"/>
+ <div style="display: flex"> <#button name="保存" icon="fa-plus" clickFun="TCoupon.backids(${index})"/>
</div>
</div>
</div>
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon1.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon1.html
new file mode 100644
index 0000000..d0127fa
--- /dev/null
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/TCoupon1.html
@@ -0,0 +1,79 @@
+@layout("/common/_container.html"){
+<div class="row">
+ <div class="col-sm-12">
+ <div class="ibox float-e-margins">
+ <div class="ibox-title">
+ <h5>优惠券管理</h5>
+ </div>
+ <div class="ibox-content">
+
+ <div class="row row-lg">
+ <div class="col-sm-12">
+ <div class="row">
+ <div class="col-sm-3">
+ <#NameCon id="name" name="优惠券名称" />
+ <input type="hidden" id="index" value="${index}">
+ </div>
+<!-- <div class="col-sm-3">-->
+<!-- <#SelectCon id="type" name="优惠券类型" >-->
+<!-- <option value="">全部</option>-->
+<!-- <option value="1">满减券</option>-->
+<!-- <option value="2">折扣券</option>-->
+<!-- <option value="3">体验券</option>-->
+<!-- </#SelectCon>-->
+<!-- </div>-->
+<!-- <div class="col-sm-3">-->
+<!-- <#SelectCon id="distributionMethod" name="发放方式" >-->
+<!-- <option value="">全部</option>-->
+<!-- <option value="1">积分购买</option>-->
+<!-- <option value="2">注册赠送</option>-->
+<!-- <option value="3">自动发券</option>-->
+<!-- </#SelectCon>-->
+<!-- </div>-->
+<!-- <div class="col-sm-3">-->
+<!-- <#SelectCon id="userPopulation" name="用户人群" >-->
+<!-- <option value="">全部</option>-->
+<!-- <option value="1">全部用户</option>-->
+<!-- <option value="2">年度会员</option>-->
+<!-- <option value="3">已有学员用户</option>-->
+<!-- </#SelectCon>-->
+<!-- </div>-->
+<!-- <div class="col-sm-3">-->
+<!-- <#SelectCon id="status" name="活动状态" >-->
+<!-- <option value="">全部</option>-->
+<!-- <option value="1">未开始</option>-->
+<!-- <option value="2">已开始</option>-->
+<!-- <option value="3">已结束</option>-->
+<!-- </#SelectCon>-->
+<!-- </div>-->
+<!-- <div class="col-sm-3">-->
+<!-- <#SelectCon id="state" name="可售状态" >-->
+<!-- <option value="">全部</option>-->
+<!-- <option value="1">已上架</option>-->
+<!-- <option value="2">已下架</option>-->
+<!-- </#SelectCon>-->
+<!-- </div>-->
+<!-- <div class="col-sm-3">-->
+ <#button name="搜索" icon="fa-search" clickFun="TCoupon.search()"/>
+<!-- <#button name="重置" icon="fa-trash" clickFun="TCoupon.resetSearch()"/>-->
+ </div>
+ </div>
+<!-- <div class="hidden-xs" id="TCouponTableToolbar" role="group">-->
+<!-- <#button name="添加" icon="fa-plus" clickFun="TCoupon.backids(${index})" />-->
+<!-- <#button name="编辑" icon="fa-edit" clickFun="TCoupon.openChange()" space="true" hidden='hidden'/>-->
+<!-- <#button name="上架" icon="fa-remove" clickFun="TCoupon.onShelf(1)" space="true" hidden='hidden'/>-->
+<!-- <#button name="下架" icon="fa-remove" clickFun="TCoupon.onShelf(2)" space="true" hidden='hidden'/>-->
+<!-- <#button name="查看详情" icon="fa-remove" clickFun="TCoupon.openDetail()" space="true" hidden='hidden'/>-->
+<!-- <#button name="领取记录" icon="fa-remove" clickFun="TCoupon.openCollectionRecord()" space="true" hidden='hidden'/>-->
+<!-- </div>-->
+ <#table id="TCouponTable"/>
+ <div style="display: flex">
+ </div>
+ </div>
+ </div>
+
+ </div>
+ </div>
+</div>
+<script src="${ctxPath}/modular/system/coursePackage/TCoupon.js"></script>
+@}
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html
index 0500b54..9c6494b 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage.html
@@ -63,9 +63,9 @@
</div>
</div>
<div class="hidden-xs" id="managerTableToolbar" role="group">
- <#button name="测试添加" icon="fa-plus" clickFun="CoursePackage.addCoursePackage1()"/>
+ <#button name="添加" icon="fa-plus" clickFun="CoursePackage.addCoursePackage1()"/>
- <#button name="添加" icon="fa-plus" clickFun="CoursePackage.addCoursePackage()"/>
+<!-- <#button name="添加" icon="fa-plus" clickFun="CoursePackage.addCoursePackage()"/>-->
<#button name="编辑" icon="fa-edit" clickFun="CoursePackage.editCoursePackage()" space="true"/>
<#button name="上架" icon="fa-refresh" clickFun="CoursePackage.editCoursePackageState(1)" space="true"/>
<#button name="下架" icon="fa-warning" clickFun="CoursePackage.editCoursePackageState(2)" space="true"/>
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html
index dd050df..d2a1140 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_add.html
@@ -4,6 +4,7 @@
<div class="form-horizontal">
<div class="row">
<div class="form-group">
+ <input type="hidden" value="${type}" id="type" name="type">
<label class="col-sm-3 control-label">*所在省:</label>
<div class="col-sm-4">
<select class="form-control" id="provinceCode" name="provinceCode">
@@ -43,6 +44,13 @@
</select>
</div>
</div>
+
+ <div class="form-group" ${type == 1||type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label">*假期有效期:</label>
+ <div class="col-sm-4">
+ <input class="form-control" id="holitime" name="holitime">
+ </div>
+ </div>
<div class="form-group">
<label class="col-sm-3 control-label">*课包名称:</label>
<div class="col-sm-4">
@@ -70,14 +78,14 @@
</select>
</div>
</div>
- <div class="form-group">
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''}>
<label class="col-sm-3 control-label">*最多预约人数:</label>
<div class="col-sm-4">
<input class="form-control" id="maxSubscribeNumber" name="maxSubscribeNumber" type="number" min="0" placeholder="请输入最多预约人数">
</div>
</div>
- <div class="form-group">
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''}>
<label class="col-sm-3 control-label">*上课时间:</label>
<div class="col-sm-4">
<input type="checkbox" name="classWeeks" value="周一"> 周一
@@ -89,7 +97,7 @@
<input type="checkbox" name="classWeeks" value="周日"> 周日
</div>
</div>
- <div class="form-group" >
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''} >
<label class="col-sm-3 control-label"></label>
<div class="form-group" style="display: flex; align-items: center;" id = "dayTime" >
@@ -104,7 +112,7 @@
</div>
- <div class="form-group">
+ <div class="form-group" ${type == 2||type == 3 ? 'hidden=hidden' : ''}>
<label class="col-sm-3 control-label">*扣除课时数:</label>
<div class="col-sm-4">
<input class="form-control" id="codeTime" name="codeTime" type="number" min="0" placeholder="请输入每节课扣除课时数">
@@ -192,14 +200,14 @@
</div>
<div id="price">
<div class="form-group">
- <label class="col-sm-3 control-label">*课时数:</label>
+ <label class="col-sm-3 control-label" >${type == 2||type == 3 ? '' : '*课时数:'}</label>
<div class="col-sm-8">
- <span class="classNumber_span"><input class="classNumber" type="number" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
- <span class="cash_span"></span>
+ <span class="classNumber_span" ${type == 2||type == 3 ? 'hidden=hidden' : ''}><input class="classNumber" type="number" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
+ <span class="cash_span" ></span>
<span class="paiCoin_span"></span>
<#button btnCss="info" name="优惠卷" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.openDia(1)"/>
- <i class="fa fa-plus-circle" style="font-size:24px" onclick="addPrice()"></i>
- <input type="text" id = "counpons1" class="counpons" >
+ <i class="fa fa-plus-circle" style="font-size:24px" onclick="addPrice(${type})"></i>
+ <input type="text" id = "counpons1" class="counpons" hidden="hidden" >
</div>
</div>
</div>
@@ -221,6 +229,12 @@
,type: 'time'
,range: true
});
+
+ laydate.render({
+ elem: '#holitime'
+ ,range: true //或 range: '~' 来自定义分割字符
+ });
+
var avatarUp = new $WebUpload("coverDrawing");
avatarUp.setUploadBarId("progressBar");
avatarUp.init();
@@ -237,7 +251,7 @@
let htmlStr =' <div style="display:flex">\n' +
' <input class="form-control" id="classStartTime'+i+'" name="classStartTime" placeholder="请选择" style="width: 200px;">\n' +
- ' <i class="fa fa-plus-circle" style="font-size: 24px; margin-left: 10px;" onclick="addTime()"></i>\n' +
+ ' <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice1(this)"></i>\n' +
' </div>'
$('#dayTime').append(htmlStr);
console.log("========="+i)
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html
index 2fe98b4..9f4d080 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_edit.html
@@ -4,6 +4,7 @@
<div class="form-horizontal">
<div class="row">
<input type="hidden" id="id" value="${item.id}">
+ <input type="hidden" id="type" name="type" value="${type}">
<div class="form-group">
<label class="col-sm-3 control-label">*所在省:</label>
<div class="col-sm-4">
@@ -44,6 +45,16 @@
</select>
</div>
</div>
+ <div class="form-group" ${type == 1||type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label">*假期有效期:</label>
+ <div class="col-sm-4">
+ <input class="form-control" id="holitime" name="holitime" value="${holi!}">
+ </div>
+ </div>
+
+
+
+
<div class="form-group">
<label class="col-sm-3 control-label">*课包名称:</label>
<div class="col-sm-4">
@@ -71,28 +82,44 @@
</select>
</div>
</div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*最多预约人数:</label>
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label" >*最多预约人数:</label>
<div class="col-sm-4">
<input class="form-control" id="maxSubscribeNumber" name="maxSubscribeNumber" value="${item.maxSubscribeNumber}" type="number" min="0" placeholder="请输入最多预约人数">
</div>
</div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*上课时间:</label>
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label" >*上课时间:</label>
<div class="col-sm-4">
- <input class="form-control" id="classStartTime" name="classStartTime" value="${classTime}" placeholder="请选择">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label"></label>
- <div class="col-sm-8">
+
@for(obj in classWeeks){
<input type="checkbox" name="classWeeks" value="${obj.value}" ${obj.checked ? 'checked' : ''}> ${obj.value}
@}
+<!-- <input class="form-control" id="classStartTime" name="classStartTime" value="${classTime}" placeholder="请选择">-->
</div>
</div>
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''} >
+ <label class="col-sm-3 control-label"></label>
- <div class="form-group">
+ <div class="form-group" style="display: flex; align-items: center;" id = "dayTime" >
+
+
+ <div style="display:flex">
+ <input class="form-control" value="${time1}" id="classStartTime" name="classStartTime" placeholder="请选择" style="width: 200px;">
+ <i class="fa fa-plus-circle" style="font-size: 24px; margin-left: 10px;" onclick="addTime()"></i>
+ </div>
+ @for(o in times!){
+
+ <div style="display:flex">
+ <input class="form-control" value="${o}" id="classStartTime" name="classStartTime" placeholder="请选择" style="width: 200px;">
+ <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice1(this)"></i>
+ </div>
+ @}
+ </div>
+
+ </div>
+
+ <div class="form-group" ${type == 2||type == 3 ? 'hidden=hidden' : ''}>
<label class="col-sm-3 control-label">*扣除课时数:</label>
<div class="col-sm-4">
<input class="form-control" id="codeTime" name="codeTime" value="${item.codeTime}" type="number" min="0" placeholder="请输入每节课扣除课时数">
@@ -180,9 +207,9 @@
</div>
<div id="price">
<div class="form-group">
- <label class="col-sm-3 control-label">*课时数:</label>
+ <label class="col-sm-3 control-label" >${type == 2||type == 3 ? '' : '*课时数:'}</label>
<div class="col-sm-8">
- <span class="classNumber_span"><input class="classNumber" type="number" value="${coursePackagePaymentConfig.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
+ <span class="classNumber_span" ${type == 2||type == 3 ? 'hidden=hidden' : ''}><input class="classNumber" type="number" value="${coursePackagePaymentConfig.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
<span class="cash_span">
@if(cashPayment){
现金支付:<input class="cash" type="number" value="${coursePackagePaymentConfig.cashPayment}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> ¥
@@ -193,16 +220,16 @@
玩湃币支付:<input class="paiCoin" type="number" value="${coursePackagePaymentConfig.playPaiCoin}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> 币
@}
</span>
- <input type="text" id="counpons1" value="${couponIds}" class="counpons">
- <#button btnCss="info" name="优惠卷" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.openDia1(1)"/>
- <i class="fa fa-plus-circle" style="font-size:24px" onclick="addPrice()"></i>
+ <input type="hidden" id="counpons1" value="${couponIds}" class="counpons">
+ <#button btnCss="info" name="优惠卷" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.openDia(1)"/>
+ <i class="fa fa-plus-circle" style="font-size:24px" onclick="addPrice(${type})"></i>
</div>
</div>
@for(obj in coursePackagePaymentConfigs){
<div class="form-group">
- <label class="col-sm-3 control-label">*课时数:</label>
+ <label class="col-sm-3 control-label">${type == 2||type == 3 ? '' : '*课时数:'}</label>
<div class="col-sm-8">
- <span class="classNumber_span"><input class="classNumber" type="number" value="${obj.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
+ <span class="classNumber_span" ${type == 2||type == 3 ? 'hidden=hidden' : ''}><input class="classNumber" type="number" value="${obj.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
<span class="cash_span">
@if(cashPayment){
现金支付:<input class="cash" type="number" value="${obj.cashPayment}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> ¥
@@ -213,6 +240,7 @@
玩湃币支付:<input class="paiCoin" type="number" value="${obj.playPaiCoin}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> 币
@}
</span>
+ <input type="hidden" id="counpons${obj.id}" value="${obj.couponIds}" class="counpons"> <#button btnCss="info" name="优惠卷" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.openDia(${obj.id})"/>
<i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice(4, this)"></i>
</div>
</div>
@@ -237,6 +265,11 @@
,type: 'time'
,range: true
});
+
+ laydate.render({
+ elem: '#holitime'
+ ,range: true //或 range: '~' 来自定义分割字符
+ });
var avatarUp = new $WebUpload("coverDrawing");
avatarUp.setUploadBarId("progressBar");
avatarUp.init();
@@ -248,5 +281,21 @@
var avatarUp1 = new $WebUpload("introduceDrawing");
avatarUp1.setUploadBarId("progressBar");
avatarUp1.init();
+
+ function addTime(){
+ var i = $('#dayTime > div').length
+
+ let htmlStr =' <div style="display:flex">\n' +
+ ' <input class="form-control" id="classStartTime'+i+'" name="classStartTime" placeholder="请选择" style="width: 200px;">\n' +
+ ' <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice1(this)"></i>\n' +
+ ' </div>'
+ $('#dayTime').append(htmlStr);
+ console.log("========="+i)
+ laydate.render({
+ elem: '#classStartTime'+i,
+ type: 'time',
+ range: true
+ });
+ }
</script>
@}
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html
index 6cc25f2..c7345e9 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/coursePackage_info.html
@@ -4,6 +4,7 @@
<div class="form-horizontal">
<div class="row">
<input type="hidden" id="id" value="${item.id}">
+ <input type="hidden" id="type" name="type" value="${type}">
<div class="form-group">
<label class="col-sm-3 control-label">*所在省:</label>
<div class="col-sm-4">
@@ -44,159 +45,257 @@
</select>
</div>
</div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*课包名称:</label>
- <div class="col-sm-4">
- <input class="form-control" id="name" name="name" value="${item.name}" readonly>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*上课场地:</label>
- <div class="col-sm-4">
- <select class="form-control" id="siteId" name="siteId" disabled>
- @for(obj in site){
- <option value="${obj.id}" ${item.siteId == obj.id ? 'selected' : ''}>${obj.name}</option>
- @}
- </select>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*授课教师:</label>
- <div class="col-sm-4">
- <select class="form-control" id="coachId" name="coachId" disabled>
- <option value="">请选择</option>
- @for(obj in coach){
- <option value="${obj.id}" ${item.coachId == obj.id ? 'selected' : ''}>${obj.name}</option>
- @}
- </select>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*最多预约人数:</label>
- <div class="col-sm-4">
- <input class="form-control" id="maxSubscribeNumber" name="maxSubscribeNumber" value="${item.maxSubscribeNumber}" type="number" min="0" placeholder="请输入最多预约人数" readonly>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*上课时间:</label>
- <div class="col-sm-4">
- <input class="form-control" id="classStartTime" name="classStartTime" value="${classTime}" placeholder="请选择" readonly>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label"></label>
- <div class="col-sm-8">
- @for(obj in classWeeks){
- <input type="checkbox" name="classWeeks" value="${obj.value}" ${obj.checked ? 'checked' : ''}> ${obj.value}
- @}
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*课包封面:</label>
- <div class="col-sm-4">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label head-scu-label">*列表页</label>
- <div class="col-sm-2">
- <div id="coverDrawingPreId">
- <div><img width="100px" height="100px" src="${item.coverDrawing}"></div>
- </div>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label head-scu-label"></label>
- <label>推荐像素:210x280px</label>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label head-scu-label">*详情页</label>
- <div class="col-sm-2">
- <div id="detailDrawingPreId">
- <div><img width="100px" height="100px" src="${item.detailDrawing}"></div>
- </div>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label head-scu-label"></label>
- <label>推荐像素:780x440px</label>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label head-scu-label">*课包介绍</label>
- <div class="col-sm-2">
- <div id="introduceDrawingPreId">
- <div><img width="100px" height="100px" src="${item.introduceDrawing}"></div>
- </div>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label head-scu-label"></label>
- <label>推荐像素:宽780x</label>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">排序:</label>
- <div class="col-sm-4">
- <input class="form-control" id="sort" name="sort" value="${item.sort}" type="number" placeholder="请输入排序">
- </div>
- </div>
- <div class="hr-line-dashed"></div>
- <h3>课时设置</h3>
- <div class="form-group">
- <label class="col-sm-3 control-label">*支付方式:</label>
- <div class="col-sm-4" style="margin-top: 6px;">
- <input type="checkbox" name="payType" value="1" ${cashPayment ? 'checked' : ''}> 现金
- <input type="checkbox" name="payType" value="2" ${playPaiCoin ? 'checked' : ''}> 玩湃币
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-3 control-label">*课时有效期:</label>
- <div class="col-sm-4">
- 购买后 <input id="validDays" name="validDays" type="number" value="${item.validDays}" min="0" placeholder="天数" style="width: 80px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> 天内有效
- </div>
- </div>
- <div id="price">
- <div class="form-group">
- <label class="col-sm-3 control-label">*课时数:</label>
- <div class="col-sm-8">
- <span class="classNumber_span"><input class="classNumber" type="number" value="${coursePackagePaymentConfig.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> </span>
- <span class="cash_span">
- @if(cashPayment){
- 现金支付:<input class="cash" type="number" value="${coursePackagePaymentConfig.cashPayment}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> ¥
- @}
- </span>
- <span class="paiCoin_span">
- @if(playPaiCoin){
- 玩湃币支付:<input class="paiCoin" type="number" value="${coursePackagePaymentConfig.playPaiCoin}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> 币
- @}
- </span>
- </div>
- </div>
- @for(obj in coursePackagePaymentConfigs){
- <div class="form-group">
- <label class="col-sm-3 control-label">*课时数:</label>
- <div class="col-sm-8">
- <span class="classNumber_span"><input class="classNumber" type="number" value="${obj.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> </span>
- <span class="cash_span">
- @if(cashPayment){
- 现金支付:<input class="cash" type="number" value="${obj.cashPayment}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> ¥
- @}
- </span>
- <span class="paiCoin_span">
- @if(playPaiCoin){
- 玩湃币支付:<input class="paiCoin" type="number" value="${obj.playPaiCoin}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;" readonly> 币
- @}
- </span>
- </div>
- </div>
- @}
+ <div class="form-group" ${type == 1||type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label">*假期有效期:</label>
+ <div class="col-sm-4">
+ <input class="form-control" id="holitime" name="holitime" value="${holi!}" disabled>
</div>
</div>
- <div class="row btn-group-m-t">
- <div class="col-sm-10">
- <#button btnCss="danger" name="关闭" id="cancel" icon="fa-eraser" clickFun="CoursePackageInfo.close()"/>
+
+
+
+
+ <div class="form-group">
+ <label class="col-sm-3 control-label">*课包名称:</label>
+ <div class="col-sm-4">
+ <input class="form-control" id="name" name="name" value="${item.name}" disabled>
</div>
+ </div>
+ <div class="form-group">
+ <label class="col-sm-3 control-label">*上课场地:</label>
+ <div class="col-sm-4">
+ <select class="form-control" id="siteId" name="siteId" disabled>
+ @for(obj in site){
+ <option value="${obj.id}" ${item.siteId == obj.id ? 'selected' : ''}>${obj.name}</option>
+ @}
+ </select>
+ </div>
+ </div>
+ <div class="form-group">
+ <label class="col-sm-3 control-label">*授课教师:</label>
+ <div class="col-sm-4">
+ <select class="form-control" id="coachId" name="coachId" disabled>
+ <option value="">请选择</option>
+ @for(obj in coach){
+ <option value="${obj.id}" ${item.coachId == obj.id ? 'selected' : ''}>${obj.name}</option>
+ @}
+ </select>
+ </div>
+ </div>
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label" >*最多预约人数:</label>
+ <div class="col-sm-4">
+ <input class="form-control" id="maxSubscribeNumber" name="maxSubscribeNumber" value="${item.maxSubscribeNumber}" type="number" min="0" placeholder="请输入最多预约人数" disabled>
</div>
</div>
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''}>
+ <label class="col-sm-3 control-label" >*上课时间:</label>
+ <div class="col-sm-4">
+
+ @for(obj in classWeeks){
+ <input type="checkbox" disabled name="classWeeks" value="${obj.value}" ${obj.checked ? 'checked' : ''}> ${obj.value}
+ @}
+ <!-- <input class="form-control" id="classStartTime" name="classStartTime" value="${classTime}" placeholder="请选择">-->
+ </div>
+ </div>
+ <div class="form-group" ${type == 3 ? 'hidden=hidden' : ''} >
+ <label class="col-sm-3 control-label"></label>
+
+ <div class="form-group" style="display: flex; align-items: center;" id = "dayTime" >
+
+
+ <div style="display:flex">
+ <input class="form-control" value="${time1}" id="classStartTime" name="classStartTime" placeholder="请选择" style="width: 200px;" disabled>
+ <i class="fa fa-plus-circle" style="font-size: 24px; margin-left: 10px;" onclick="addTime()" disabled></i>
+ </div>
+ @for(o in times!){
+
+ <div style="display:flex">
+ <input class="form-control" value="${o}" id="classStartTime" name="classStartTime" placeholder="请选择" style="width: 200px;" disabled>
+ <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice1(this)" disabled></i>
+ </div>
+ @}
+ </div>
+
+</div>
+
+<div class="form-group" ${type == 2||type == 3 ? 'hidden=hidden' : ''}>
+<label class="col-sm-3 control-label">*扣除课时数:</label>
+<div class="col-sm-4">
+ <input class="form-control" disabled id="codeTime" name="codeTime" value="${item.codeTime}" type="number" min="0" placeholder="请输入每节课扣除课时数">
+</div>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label">*课包封面:</label>
+ <div class="col-sm-4">
</div>
</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label head-scu-label">*列表页</label>
+ <div class="col-sm-2">
+ <div id="coverDrawingPreId">
+ <div><img width="100px" height="100px" src="${item.coverDrawing}" disabled></div>
+ </div>
+ </div>
+ <div class="col-sm-2">
+<!-- <div class="head-scu-btn upload-btn" id="coverDrawingBtnId">-->
+<!--<!– <i class="fa fa-upload" disabled></i> 上传–>-->
+<!-- </div>-->
+ </div>
+ <input type="hidden" id="coverDrawing" value="${item.coverDrawing}" disabled/>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label head-scu-label"></label>
+ <label>推荐像素:210x280px</label>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label head-scu-label">*详情页</label>
+ <div class="col-sm-2">
+ <div id="detailDrawingPreId">
+ <div><img width="100px" height="100px" src="${item.detailDrawing}" disabled></div>
+ </div>
+ </div>
+ <div class="col-sm-2">
+<!-- <div class="head-scu-btn upload-btn" id="detailDrawingBtnId" disabled>-->
+<!-- <i class="fa fa-upload" disabled></i> 上传-->
+<!-- </div>-->
+ </div>
+ <input type="hidden" id="detailDrawing" value="${item.detailDrawing}" disabled/>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label head-scu-label"></label>
+ <label>推荐像素:780x440px</label>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label head-scu-label">*课包介绍</label>
+ <div class="col-sm-2">
+ <div id="introduceDrawingPreId">
+ <div><img width="100px" height="100px" src="${item.introduceDrawing}" disabled></div>
+ </div>
+ </div>
+ <div class="col-sm-2">
+<!-- <div class="head-scu-btn upload-btn" id="introduceDrawingBtnId" disabled>-->
+<!-- <i class="fa fa-upload" disabled></i> 上传-->
+<!-- </div>-->
+ </div>
+ <input type="hidden" id="introduceDrawing" value="${item.introduceDrawing}"/>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label head-scu-label"></label>
+ <label>推荐像素:宽780x</label>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label">排序:</label>
+ <div class="col-sm-4">
+ <input class="form-control" disabled id="sort" name="sort" value="${item.sort}" type="number" placeholder="请输入排序">
+ </div>
+</div>
+<div class="hr-line-dashed"></div>
+<h3>课时设置</h3>
+<div class="form-group">
+ <label class="col-sm-3 control-label">*支付方式:</label>
+ <div class="col-sm-4" style="margin-top: 6px;">
+ <input type="checkbox" disabled name="payType" value="1" ${cashPayment ? 'checked' : ''}> 现金
+ <input type="checkbox" disabled name="payType" value="2" ${playPaiCoin ? 'checked' : ''}> 玩湃币
+ </div>
+</div>
+<div class="form-group">
+ <label class="col-sm-3 control-label">*课时有效期:</label>
+ <div class="col-sm-4">
+ 购买后 <input id="validDays" disabled name="validDays" type="number" value="${item.validDays}" min="0" placeholder="天数" style="width: 80px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> 天内有效
+ </div>
+</div>
+<div id="price">
+ <div class="form-group">
+ <label class="col-sm-3 control-label" >${type == 2||type == 3 ? '' : '*课时数:'}</label>
+ <div class="col-sm-8">
+ <span class="classNumber_span" disabled ${type == 2||type == 3 ? 'hidden=hidden' : ''}><input class="classNumber" type="number" value="${coursePackagePaymentConfig.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
+ <span class="cash_span" disabled>
+ @if(cashPayment){
+ 现金支付:<input class="cash" type="number" value="${coursePackagePaymentConfig.cashPayment}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> ¥
+ @}
+ </span>
+ <span class="paiCoin_span" disabled>
+ @if(playPaiCoin){
+ 玩湃币支付:<input class="paiCoin" type="number" value="${coursePackagePaymentConfig.playPaiCoin}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> 币
+ @}
+ </span>
+ <input type="hidden" id="counpons1" value="${couponIds}" class="counpons">
+ <#button btnCss="info" name="优惠卷" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.openDia1(1)"/>
+ <i class="fa fa-plus-circle" style="font-size:24px" onclick="addPrice(${type})" disabled></i>
+ </div>
+ </div>
+ @for(obj in coursePackagePaymentConfigs){
+ <div class="form-group">
+ <label class="col-sm-3 control-label">${type == 2||type == 3 ? '' : '*课时数:'}</label>
+ <div class="col-sm-8">
+ <span class="classNumber_span" disabled ${type == 2||type == 3 ? 'hidden=hidden' : ''}><input class="classNumber" type="number" value="${obj.classHours}" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span>
+ <span class="cash_span" disabled>
+ @if(cashPayment){
+ 现金支付:<input class="cash" type="number" value="${obj.cashPayment}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> ¥
+ @}
+ </span>
+ <span class="paiCoin_span" disabled>
+ @if(playPaiCoin){
+ 玩湃币支付:<input class="paiCoin" type="number" value="${obj.playPaiCoin}" min="0" placeholder="请输入金额" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> 币
+ @}
+ </span>
+ <input type="hidden" id="counpons${obj.id}" value="${obj.couponIds}" class="counpons"> <#button btnCss="info" name="优惠卷" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.openDia1(${obj.id})"/>
+ <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice(4, this)" disabled></i>
+ </div>
+ </div>
+ @}
+</div>
+</div>
+<div class="row btn-group-m-t">
+ <div class="col-sm-10">
+ <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="CoursePackageInfo.editSubmit()"/>
+ <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="CoursePackageInfo.close()"/>
+ </div>
+</div>
+</div>
+</div>
+</div>
<script src="${ctxPath}/modular/system/coursePackage/coursePackage_info.js"></script>
+<script type="text/javascript">
+
+ console.log("============>"+`${couponIds}`)
+ laydate.render({
+ elem: '#classStartTime'
+ ,type: 'time'
+ ,range: true
+ });
+
+ laydate.render({
+ elem: '#holitime'
+ ,range: true //或 range: '~' 来自定义分割字符
+ });
+ var avatarUp = new $WebUpload("coverDrawing");
+ avatarUp.setUploadBarId("progressBar");
+ avatarUp.init();
+
+ var avatarUp1 = new $WebUpload("detailDrawing");
+ avatarUp1.setUploadBarId("progressBar");
+ avatarUp1.init();
+
+ var avatarUp1 = new $WebUpload("introduceDrawing");
+ avatarUp1.setUploadBarId("progressBar");
+ avatarUp1.init();
+
+ function addTime(){
+ var i = $('#dayTime > div').length
+
+ let htmlStr =' <div style="display:flex">\n' +
+ ' <input class="form-control" id="classStartTime'+i+'" name="classStartTime" placeholder="请选择" style="width: 200px;">\n' +
+ ' <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice1(this)"></i>\n' +
+ ' </div>'
+ $('#dayTime').append(htmlStr);
+ console.log("========="+i)
+ laydate.render({
+ elem: '#classStartTime'+i,
+ type: 'time',
+ range: true
+ });
+ }
+</script>
@}
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html
index eb94bdd..0c3bf46 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord.html
@@ -7,6 +7,7 @@
<div class="row row-lg">
<div class="col-sm-12">
<div class="row">
+ <input type="text" id="type" value="${type}">
<input type="hidden" id="id" value="${item.id}">
<input type="hidden" id="name" value="${item.name}">
<div class="col-lg-10 col-sm-9">
@@ -30,7 +31,7 @@
</div>
<div class="hidden-xs" id="managerTableToolbar" role="group">
<#button name="上课记录" icon="fa-plus" clickFun="RegistrationRecord.classRecord()"/>
- <#button name="退课" icon="fa-edit" clickFun="RegistrationRecord.dropClass()" space="true"/>
+<!-- <#button name="退课" icon="fa-edit" clickFun="RegistrationRecord.dropClass()" space="true"/>-->
<#button name="补课" icon="fa-refresh" clickFun="RegistrationRecord.makeUpMissedLessons()" space="true"/>
<#button name="更换假期班" icon="fa-refresh" clickFun="RegistrationRecord.holiClass()" space="true"/>
<#button name="换课" icon="fa-refresh" clickFun="RegistrationRecord.transClass()" space="true"/>
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord2.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord2.html
new file mode 100644
index 0000000..4a22f03
--- /dev/null
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord2.html
@@ -0,0 +1,57 @@
+@layout("/common/_container.html"){
+<link rel="stylesheet" href="${ctxPath}/layui/css/layui.css" media="all">
+<div class="row">
+ <div class="col-sm-12">
+ <div class="ibox float-e-margins">
+ <div class="ibox-content">
+ <div class="row row-lg">
+ <div class="col-sm-12">
+ <div class="row">
+ <input type="text" id="type" value="${type}">
+ <input type="hidden" id="id" value="${item.id}">
+ <input type="hidden" id="name" value="${item.name}">
+ <div class="col-lg-10 col-sm-9">
+ <div class="row">
+ <div class="col-lg-4 col-sm-12">
+ <#NameCon id="userName" name="购买用户"/>
+ </div>
+ <div class="col-lg-4 col-sm-12">
+ <#NameCon id="studentName" name="购买学员"/>
+ </div>
+ </div>
+ </div>
+ <div class="col-lg-2 col-sm-3">
+ <div class="row">
+ <div class="col-lg-12 col-sm-12">
+ <#button name="搜索" icon="fa-search" clickFun="RegistrationRecord.search()"/>
+ <#button name="重置" icon="fa-trash" clickFun="RegistrationRecord.resetSearch()" space="true"/>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="hidden-xs" id="managerTableToolbar" role="group">
+ <#button name="上课记录" icon="fa-plus" clickFun="RegistrationRecord.classRecord()"/>
+<!-- <#button name="退课" icon="fa-edit" clickFun="RegistrationRecord.dropClass()" space="true"/>-->
+<!-- <#button name="补课" icon="fa-refresh" clickFun="RegistrationRecord.makeUpMissedLessons()" space="true"/>-->
+<!-- <#button name="更换假期班" icon="fa-refresh" clickFun="RegistrationRecord.holiClass()" space="true"/>-->
+<!-- <#button name="换课" icon="fa-refresh" clickFun="RegistrationRecord.transClass()" space="true"/>-->
+
+ </div>
+ <#table id="managerTable"/>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+<script src="${ctxPath}/modular/system/coursePackage/registrationRecord2.js"></script>
+<script src="${ctxPath}/layui/layui.js" charset="utf-8"></script>
+<script>
+ laydate.render({
+ elem: '#beginTime'
+ });
+ laydate.render({
+ elem: '#endTime'
+ });
+</script>
+@}
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord3.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord3.html
new file mode 100644
index 0000000..5f422d4
--- /dev/null
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/coursePackage/registrationRecord3.html
@@ -0,0 +1,57 @@
+@layout("/common/_container.html"){
+<link rel="stylesheet" href="${ctxPath}/layui/css/layui.css" media="all">
+<div class="row">
+ <div class="col-sm-12">
+ <div class="ibox float-e-margins">
+ <div class="ibox-content">
+ <div class="row row-lg">
+ <div class="col-sm-12">
+ <div class="row">
+ <input type="text" id="type" value="${type}">
+ <input type="hidden" id="id" value="${item.id}">
+ <input type="hidden" id="name" value="${item.name}">
+ <div class="col-lg-10 col-sm-9">
+ <div class="row">
+ <div class="col-lg-4 col-sm-12">
+ <#NameCon id="userName" name="购买用户"/>
+ </div>
+ <div class="col-lg-4 col-sm-12">
+ <#NameCon id="studentName" name="购买学员"/>
+ </div>
+ </div>
+ </div>
+ <div class="col-lg-2 col-sm-3">
+ <div class="row">
+ <div class="col-lg-12 col-sm-12">
+ <#button name="搜索" icon="fa-search" clickFun="RegistrationRecord.search()"/>
+ <#button name="重置" icon="fa-trash" clickFun="RegistrationRecord.resetSearch()" space="true"/>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="hidden-xs" id="managerTableToolbar" role="group">
+<!-- <#button name="上课记录" icon="fa-plus" clickFun="RegistrationRecord.classRecord()"/>-->
+<!-- <#button name="退课" icon="fa-edit" clickFun="RegistrationRecord.dropClass()" space="true"/>-->
+<!-- <#button name="补课" icon="fa-refresh" clickFun="RegistrationRecord.makeUpMissedLessons()" space="true"/>-->
+<!-- <#button name="更换假期班" icon="fa-refresh" clickFun="RegistrationRecord.holiClass()" space="true"/>-->
+<!-- <#button name="换课" icon="fa-refresh" clickFun="RegistrationRecord.transClass()" space="true"/>-->
+
+ </div>
+ <#table id="managerTable"/>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+<script src="${ctxPath}/modular/system/coursePackage/registrationRecord2.js"></script>
+<script src="${ctxPath}/layui/layui.js" charset="utf-8"></script>
+<script>
+ laydate.render({
+ elem: '#beginTime'
+ });
+ laydate.render({
+ elem: '#endTime'
+ });
+</script>
+@}
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html
index a148919..8e61277 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/banckmoney.html
@@ -2,7 +2,7 @@
<html lang="zh">
<head>
<meta charset="UTF-8" />
- <title>amis demo</title>
+ <title>学员退费单</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta
name="viewport"
@@ -45,6 +45,7 @@
{
"type": "form",
"title": "表单",
+ "hidden": true,
"body": [
{
"label": "文本",
@@ -299,12 +300,16 @@
{
"type": "button",
"id": "u:6c0b8f917bf7",
- "label": "导出",
+ "label": "保存",
"level":"info",
"onEvent": {
"click": {
"actions": [
{
+ "componentId": "u:6c0b8f917bf7",
+ "actionType": "hidden"
+ },
+ {
"script": "\r\nwindow.print()",
"actionType": "custom"
},
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html
index 5fbc47d..60ad4ac 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/classelct.html
@@ -41,6 +41,15 @@
"body": [
{
"type": "form",
+ "id": "u:339c517e4f3c",
+ "api": {
+ "url": "/coursePackage/openAddCoursePackage?$radios",
+ "method": "get",
+ "requestAdaptor": "",
+ "adaptor": "",
+ "messages": {
+ }
+ },
"title": "",
"body": [
{
@@ -233,35 +242,10 @@
"tpl": "                                                                                                  ",
"inline": true,
"wrapperComponent": ""
- },
- {
- "type": "button",
- "label": "确认",
- "onEvent": {
- "click": {
- "actions": [
- {
- "actionType": "url",
- "args": {
- "url": "/coursePackage/openAddCoursePackage?type=$radios",
- "blank": false
- }
- }
- ]
- }
- },
- "id": "u:5b4f1fa2ae10"
}
],
- "id": "u:339c517e4f3c",
- "api": {
- "url": "/coursePackage/openAddCoursePackage?$radios",
- "method": "get",
- "requestAdaptor": "",
- "adaptor": "",
- "messages": {
- }
- }
+ "actions": [
+ ]
}
],
"id": "u:039339c3720d"
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html
index 1c0bba5..7e17084 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudent.html
@@ -39,7 +39,7 @@
@if(shiro.hasPermission("/tStudent/delete")){
<#button name="删除" icon="fa-remove" clickFun="TStudent.delete()" space="true"/>
@}
- <button id="exportButton">TTTTTTTTTT</button>
+<!-- <button id="exportButton">TTTTTTTTTT</button>-->
</div>
<#table id="TStudentTable"/>
</div>
diff --git a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html
index ced5d12..229b1df 100644
--- a/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html
+++ b/cloud-server-management/src/main/webapp/WEB-INF/view/system/tStudent/tStudentEdit.html
@@ -343,7 +343,7 @@
"id": "u:5126d1e417f2",
"valueFormat": "YYYY-MM-DD",
"format": "YYYY-MM-DD",
- "name":"useTime"
+ "name": "useTime"
},
{
"type": "tpl",
@@ -408,7 +408,8 @@
"receiver": {
"url": "/mgr/uploadImgAmis",
"method": "post"
- }
+ },
+ "required": true
},
{
"type": "input-image",
@@ -425,7 +426,8 @@
"receiver": {
"url": "/mgr/uploadImgAmis",
"method": "post"
- }
+ },
+ "required": true
},
{
"type": "container",
@@ -494,10 +496,24 @@
"method": "post",
"requestAdaptor": "",
"adaptor": "",
- "messages": {},
+ "messages": {
+ },
"dataType": "form-data"
},
- "actions": []
+ "actions": [
+ ],
+ "onEvent": {
+ "submitSucc": {
+ "weight": 0,
+ "actions": [
+ {
+ "componentId": "u:59d68a32f7fd",
+ "actionType": "reload",
+ "dataMergeMode": "merge"
+ }
+ ]
+ }
+ }
}
],
"showCloseButton": true,
@@ -506,13 +522,9 @@
"className": "app-popover",
"id": "u:044fac037276",
"closeOnEsc": false,
- "actions": []
+ "actions": [
+ ]
}
- },
- {
- "componentId": "u:59d68a32f7fd",
- "actionType": "reload",
- "data": null
}
]
}
@@ -773,9 +785,8 @@
"actionType": "dialog",
"dialog": {
"type": "dialog",
- "title": "弹框标题",
+ "title": "退费列表",
"body": [
-
{
"type": "input-text",
"id": "u:895313026d71",
@@ -786,7 +797,7 @@
{
"type": "crud",
"syncLocation": false,
- "name":"crud",
+ "name": "crud",
"api": {
"method": "get",
"url": "/tStudent/getBackList/$id"
@@ -836,16 +847,14 @@
}
},
"id": "u:38a6f5402e72",
- "level": "link",
- "actionType": "ajax"
+ "level": "link"
},
{
"type": "button",
"label": "同意",
"onEvent": {
"click": {
- "actions": [
- ],
+ "actions": [],
"weight": 0
}
},
@@ -857,7 +866,26 @@
"method": "post",
"url": "/tStudent/changeStatus/$id"
},
- "reload": "pay"
+ "reload": "pay,crud"
+ },
+ {
+ "type": "button",
+ "label": "拒绝",
+ "onEvent": {
+ "click": {
+ "actions": [],
+ "weight": 0
+ }
+ },
+ "id": "u:4450de076e9f",
+ "level": "link",
+ "actionType": "ajax",
+ "hiddenOn": "this.status === 1 || this.status === 2",
+ "api": {
+ "method": "post",
+ "url": "/tStudent/noStatus/$id"
+ },
+ "reload": "pay,crud"
}
],
"placeholder": "-",
@@ -871,13 +899,39 @@
"delete"
],
"id": "u:a4ce7e3ae181"
+ },
+ {
+ "type": "flex",
+ "className": "p-1",
+ "items": [
+ {
+ "type": "button",
+ "id": "u:2cb16767ded5",
+ "label": "关闭",
+ "onEvent": {
+ "click": {
+ "actions": [
+ {
+ "actionType": "closeDialog"
+ }
+ ]
+ }
+ },
+ "level": "enhance"
+ }
+ ],
+ "style": {
+ "position": "relative"
+ },
+ "id": "u:a0b6e9312424"
}
],
"showCloseButton": true,
"showErrorMsg": true,
"showLoading": true,
"className": "app-popover",
- "id": "u:b91085026056"
+ "id": "u:b91085026056",
+ "actions": []
}
}
]
@@ -887,12 +941,15 @@
},
{
"type": "crud",
- "name":"pay",
- "syncLocation": false,
- "api": {
- "method": "get",
- "url": "/tStudent/classList/$id"
+ "id": "u:88517068101f",
+ "messages": {
},
+ "api": {
+ "url": "/tStudent/classList/$id",
+ "method": "get"
+ },
+ "name": "pay",
+ "syncLocation": false,
"columns": [
{
"name": "className",
@@ -952,7 +1009,7 @@
"actionType": "dialog",
"dialog": {
"type": "form",
- "title": "弹框标题",
+ "title": "",
"body": [
{
"type": "form",
@@ -1048,6 +1105,21 @@
"messages": {
},
"dataType": "form-data"
+ },
+ "onEvent": {
+ "submitSucc": {
+ "weight": 0,
+ "actions": [
+ {
+ "componentId": "u:88517068101f",
+ "actionType": "reload",
+ "args": {
+ "resetPage": true
+ },
+ "dataMergeMode": "merge"
+ }
+ ]
+ }
}
}
],
@@ -1063,14 +1135,30 @@
}
},
"actions": [
- ]
+ ],
+ "onEvent": {
+ "submitSucc": {
+ "weight": 0,
+ "actions": [
+ {
+ "componentId": "u:88517068101f",
+ "actionType": "reload",
+ "args": {
+ "resetPage": true
+ },
+ "dataMergeMode": "merge"
+ }
+ ]
+ }
+ }
}
}
]
}
},
"id": "u:fcd7f36c5f88",
- "level": "link"
+ "level": "link",
+ "disabledOn": "this.laveClassHours === 0"
},
{
"type": "button",
@@ -1140,14 +1228,16 @@
"valueField": "id"
}
],
- "messages": {},
+ "messages": {
+ },
"loadingConfig": {
"show": true
},
"api": {
"url": "/tStudent/giftSelect",
"method": "post",
- "messages": {},
+ "messages": {
+ },
"requestAdaptor": "",
"adaptor": "",
"dataType": "form-data",
@@ -1226,15 +1316,33 @@
"method": "post",
"requestAdaptor": "",
"adaptor": "",
- "messages": {},
+ "messages": {
+ },
"dataType": "form-data"
},
- "actions": []
+ "actions": [
+ ],
+ "onEvent": {
+ "submitSucc": {
+ "weight": 0,
+ "actions": [
+ {
+ "componentId": "u:88517068101f",
+ "actionType": "reload",
+ "args": {
+ "resetPage": true
+ },
+ "dataMergeMode": "merge"
+ }
+ ]
+ }
+ }
},
{
"id": "u:59d68a32f7fd",
"type": "container",
- "body": [],
+ "body": [
+ ],
"style": {
"position": "static",
"display": "block"
@@ -1246,7 +1354,8 @@
"showLoading": true,
"className": "app-popover",
"id": "u:552bd1b3464d",
- "actions": [],
+ "actions": [
+ ],
"canAccessSuperData": false
}
}
@@ -1254,7 +1363,8 @@
}
},
"id": "u:ae1e6e73beb9",
- "level": "link"
+ "level": "link",
+ "disabledOn": "this.laveClassHours === 0"
},
{
"type": "button",
@@ -1505,7 +1615,6 @@
"id": "u:dd3110deaf9d",
"level": "link"
}
-
]
}
],
@@ -1539,104 +1648,6 @@
]
}
}
- },
- {
- "type": "button",
- "label": "退费申请",
- "id": "u:4b1f37ea569c",
- "level": "info",
- "onEvent": {
- "click": {
- "weight": 0,
- "actions": [
- {
- "actionType": "dialog",
- "dialog": {
- "type": "dialog",
- "title": "弹框标题",
- "body": [
- {
- "type": "tpl",
- "tpl": "对,你刚刚点击了",
- "wrapperComponent": "",
- "inline": false,
- "id": "u:d72b44ae6de4"
- },
- {
- "type": "crud",
- "syncLocation": false,
- "api": {
- "method": "get",
- "url": "/tStudent/getBackList/$id"
- },
- "columns": [
- {
- "name": "inserTtime",
- "label": "申请时间",
- "type": "date",
- "id": "u:6948dfe01afd"
- },
- {
- "name": "status",
- "label": "审核状态",
- "type": "mapping",
- "id": "u:1f2a09737a98"
- },
- {
- "type": "operation",
- "id": "u:b0e34eccd864",
- "buttons": [
- {
- "type": "button",
- "label": "退费",
- "onEvent": {
- "click": {
- "actions": [
- {
- "actionType": "url",
- "args": {
- "url": "/tStudent/backmoney",
- "params": {
- "ids": "$ids",
- "id": "$id"
- }
- }
- }
- ],
- "weight": 0
- }
- },
- "id": "u:38a6f5402e72",
- "actionType": "ajax",
- "level": "info"
- }
- ]
- }
- ],
- "bulkActions": [],
- "itemActions": [],
- "features": [
- "view",
- "delete"
- ],
- "id": "u:a4ce7e3ae181"
- }
- ],
- "showCloseButton": true,
- "showErrorMsg": true,
- "showLoading": true,
- "className": "app-popover",
- "id": "u:b91085026056"
- }
- }
- ]
- }
- }
- },
- {
- "label": "退费",
- "type": "button",
- "id": "u:6997f0c17d7b"
}
],
"itemActions": [
@@ -1647,12 +1658,9 @@
"bulkUpdate",
"delete"
],
- "id": "u:88517068101f",
"perPageAvailable": [
10
],
- "messages": {
- },
"headerToolbar": [
{
"type": "bulk-actions",
@@ -1661,7 +1669,8 @@
],
"columnsTogglable": false,
"affixHeader": true,
- "source": ""
+ "source": "",
+ "itemCheckableOn": "this.classType === 1 &&this.laveClassHours > 0"
},
{
"type": "container",
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js
index 962bc3d..2e5962f 100644
--- a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/TCoupon.js
@@ -93,7 +93,19 @@
TCoupon.backids = function (i) {
console.log("aaaaaa"+i)
- if (this.check()) {
+
+ var selected = $('#' + this.id).bootstrapTable('getSelections');
+ // if(selected.length == 0){
+ // Feng.info("请先选中表格中的某一记录!");
+ // return false;
+ // }else{
+
+
+ // return true;
+ // }
+ if (selected.length != 0) {
+ TCoupon.seItem = selected[0];
+ TCoupon.seItem1 = selected;
var ids = TCoupon.seItem1.map(function(item) {
return item.id;
@@ -110,6 +122,10 @@
//
// }
window.parent.layer.closeAll();
+ }else {
+ window.parent.document.getElementById("counpons"+i).value = "";
+ window.parent.layer.closeAll();
+
}
};
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js
index 06f15c7..fe7937e 100644
--- a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/classRecord.js
@@ -16,7 +16,7 @@
{field: 'selectItem', radio: true},
{title: 'id', field: 'id', visible: false, align: 'center', valign: 'middle'},
{title: '日期', field: 'classDate', align: 'center', valign: 'middle'},
- {title: '报名学员', field: 'registered', align: 'center', valign: 'middle'},
+ {title: '请假学员', field: 'registered', align: 'center', valign: 'middle'},
{title: '实到学员', field: 'actualArrival', align: 'center', valign: 'middle',
formatter: function (v, row) {
if (row.absencesNumber === undefined) {
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js
index d65fccd..413b667 100644
--- a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage.js
@@ -1,7 +1,7 @@
/**
* 系统管理--用户管理的单例对象
*/
-let CoursePackage = {
+var CoursePackage = {
id: "managerTable",//表格id
seItem: null, //选中的条目
table: null,
@@ -18,6 +18,23 @@
{title: 'id', field: 'id', visible: false, align: 'center', valign: 'middle'},
{title: '所在省市', field: 'city', align: 'center', valign: 'middle'},
{title: '所属门店', field: 'store', align: 'center', valign: 'middle'},
+ {
+ title: '课包种类',
+ field: 'type',
+ align: 'center',
+ valign: 'middle',
+ formatter: function(value) {
+ if (value === 1) {
+ return '常规课';
+ } else if (value === 2) {
+ return '假期课';
+ } else if (value === 3) {
+ return '体验课';
+ } else {
+ return '';
+ }
+ }
+ },
{title: '课包类型', field: 'coursePackageType', align: 'center', valign: 'middle'},
{title: '课包名称', field: 'name', align: 'center', valign: 'middle'},
{title: '最多预约人数', field: 'maxSubscribeNumber', align: 'center', valign: 'middle'},
@@ -53,6 +70,10 @@
return columns;
};
+
+CoursePackage.close = function () {
+ window.close()
+};
/**
* 检查是否选中
*/
@@ -207,12 +228,12 @@
area: ['100%', '100%'], //宽高
fix: false, //不固定
maxmin: true,
- content: Feng.ctxPath + '/coursePackage/registrationRecord?id=' + this.seItem.id
+ content: Feng.ctxPath + '/coursePackage/registrationRecord?id=' + this.seItem.id+'&type='+this.seItem.type
});
this.layerIndex = index;
}
-};
+};
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js
index 9c0e374..c52d5aa 100644
--- a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/coursePackage_info.js
@@ -57,6 +57,9 @@
let coachId = $('#coachId').val();
let maxSubscribeNumber = $('#maxSubscribeNumber').val();
let codeTime = $('#codeTime').val();
+ let type = $('#type').val();
+ let holitime = $('#holitime').val();
+
// let classStartTime = JSON.stringify($('#classStartTime').val());
@@ -120,10 +123,10 @@
Feng.error("最多预约人数不能为空");
return
}
- if(null == codeTime || '' == codeTime){
- Feng.error("最多预约人数不能为空");
- return
- }
+ // if(null == codeTime || '' == codeTime){
+ // Feng.error("扣除课时数不能为空不能为空");
+ // return
+ // }
if(null == classStartTime || '' == classStartTime){
Feng.error("上课时间不能为空");
return
@@ -172,7 +175,9 @@
introduceDrawing: introduceDrawing,
sort: sort,
validDays: validDays,
- coursePackagePaymentConfig: JSON.stringify(price)
+ coursePackagePaymentConfig: JSON.stringify(price),
+ type:type,
+ holitime:holitime
}
//提交信息
@@ -207,8 +212,16 @@
let coachId = $('#coachId').val();
let maxSubscribeNumber = $('#maxSubscribeNumber').val();
let codeTime = $('#codeTime').val();
+ let type = $('#type').val();
- let classStartTime = $('#classStartTime').val();
+ let holitime = $('#holitime').val();
+
+ var inputElements = document.querySelectorAll('input[name="classStartTime"]');
+ let classStartTime = JSON.stringify(Array.from(inputElements).map(function(element) {
+ return element.value;
+ }))
+
+ // let classStartTime = $('#classStartTime').val();
let classWeeks = '';
$('input[name="classWeeks"]:checked').each(function (index, e) {
classWeeks += $(e).val() + ";";
@@ -310,17 +323,20 @@
coachId: coachId,
maxSubscribeNumber: maxSubscribeNumber,
codeTime: codeTime,
-
- classStartTime: classStartTime.split(" - ")[0],
- classEndTime: classStartTime.split(" - ")[1],
+ type:type,
+ classStartTime: classStartTime,
+ // classEndTime: classStartTime.split(" - ")[1],
classWeeks: classWeeks,
coverDrawing: coverDrawing,
detailDrawing: detailDrawing,
introduceDrawing: introduceDrawing,
sort: sort,
validDays: validDays,
- coursePackagePaymentConfig: JSON.stringify(price)
+ coursePackagePaymentConfig: JSON.stringify(price),
+ holitime:holitime
}
+
+ console.log("======="+obj)
//提交信息
var ajax = new $ax(Feng.ctxPath + "/coursePackage/updateCoursePackage", function (data) {
@@ -389,7 +405,8 @@
}
-function addPrice(){
+function addPrice(y){
+ console.log("===="+y)
let cash = false;
let paiCoin = false;
$('input[name="payType"]:checked').each(function (index, e) {
@@ -402,7 +419,25 @@
}
})
var i = $('#price > div').length+1
- let htmlStr = '' +
+ let htmlStr = ''
+
+
+ if (y===1){
+
+ htmlStr += '<div class="form-group">\n' +
+ ' <label class="col-sm-3 control-label">*课时数:</label>\n' +
+ ' <div class="col-sm-8">\n' +
+ ' <span class="classNumber_span"><input class="classNumber" type="number" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span> <span class="cash_span">\n';
+
+ }
+ if (y===2){
+
+ htmlStr += '<div class="form-group">\n' +
+ ' <label class="col-sm-3 control-label"></label>\n' +
+ ' <div class="col-sm-8">\n' +
+ ' <span class="classNumber_span" hidden="hidden"><input class="classNumber" type="number" min="0" placeholder="请输入" style="width: 110px;background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"> </span> <span class="cash_span">\n';
+
+ }
'<div class="form-group">\n' +
' <label class="col-sm-3 control-label">*课时数:</label>\n' +
' <div class="col-sm-8">\n' +
@@ -419,7 +454,7 @@
'</button>';
htmlStr += '</span> <i class="fa fa-trash-o" style="font-size:24px" onclick="removePrice(this)"></i>\n' +
- '</div>\n' +'<input type="text" class = "counpons" id = "counpons'+i+'" >'+i+
+ '</div>\n' +'<input type="text" hidden="hidden" class = "counpons" id = "counpons'+i+'" >'+i+
'</div>';
$('#price').append(htmlStr);
}
@@ -431,6 +466,11 @@
$(e).parent('div').parent('div').remove();
}
+function removePrice1(e){
+ $(e).parent('div').remove();
+}
+
+
$(function () {
$('#provinceCode').change(function () {
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js
index 1e07b58..991e711 100644
--- a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord.js
@@ -19,8 +19,19 @@
{title: '联系方式', field: 'phone', align: 'center', valign: 'middle'},
{title: '购课学员', field: 'studentName', align: 'center', valign: 'middle'},
{title: '报名时间', field: 'insertTime', align: 'center', valign: 'middle'},
+ {title: '总课时数', field: 'totalClassHours', align: 'center', valign: 'middle'},
+ {title: '剩余课时数', field: 'laveClassHours', align: 'center', valign: 'middle',rowStyle: function(row, index) {
+ // 参数说明:
+ //row, 行,row.xxx,能获取某个字段的值
+ //index,索引,第几行
+
+ // 逻辑判断
+ // .....
+ return {"background-color":'rgba(208,9,9,0.7)'};
+ }
+ },
{title: '已上课时数', field: 'already', align: 'center', valign: 'middle'},
- {title: '缺课次数', field: 'absencesNumber', align: 'center', valign: 'middle'},
+ {title: '请假次数', field: 'absencesNumber', align: 'center', valign: 'middle'},
{title: '状态', field: 'status', align: 'center', valign: 'middle',
formatter: function (v) {
switch (v) {
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord2.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord2.js
new file mode 100644
index 0000000..e7b35e4
--- /dev/null
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord2.js
@@ -0,0 +1,259 @@
+/**
+ * 系统管理--用户管理的单例对象
+ */
+let RegistrationRecord = {
+ id: "managerTable",//表格id
+ seItem: null, //选中的条目
+ table: null,
+ layerIndex: -1
+};
+let language =$("#language").val()
+/**
+ * 初始化表格的列
+ */
+RegistrationRecord.initColumn = function () {
+ let columns = [
+ {field: 'selectItem', checkbox: true},
+ {title: 'id', field: 'id', visible: false, align: 'center', valign: 'middle'},
+ {title: '购买用户', field: 'userName', align: 'center', valign: 'middle'},
+ {title: '联系方式', field: 'phone', align: 'center', valign: 'middle'},
+ {title: '购课学员', field: 'studentName', align: 'center', valign: 'middle'},
+ {title: '报名时间', field: 'insertTime', align: 'center', valign: 'middle'},
+ // {title: '总课时数', field: 'totalClassHours', align: 'center', valign: 'middle'},
+ // {title: '剩余课时数', field: 'laveClassHours', align: 'center', valign: 'middle',rowStyle: function(row, index) {
+ // // 参数说明:
+ // //row, 行,row.xxx,能获取某个字段的值
+ // //index,索引,第几行
+ //
+ // // 逻辑判断
+ // // .....
+ // return {"background-color":'rgba(208,9,9,0.7)'};
+ // }
+ // },
+ // {title: '已上课时数', field: 'already', align: 'center', valign: 'middle'},
+ {title: '请假次数', field: 'absencesNumber', align: 'center', valign: 'middle'},
+ {title: '状态', field: 'status', align: 'center', valign: 'middle',
+ formatter: function (v) {
+ switch (v) {
+ case 1:
+ return '正常';
+ case 2:
+ return '<a href="#" onclick="">已退课-查看凭证</a>';
+ }
+ }
+ }
+ ];
+ return columns;
+};
+
+/**
+ * 检查是否选中
+ */
+RegistrationRecord.check = function () {
+ let selected = $('#' + this.id).bootstrapTable('getSelections');
+ if (selected.length == 0) {
+ Feng.info("请先选中表格中的某一记录!");
+ return false;
+ } else {
+ RegistrationRecord.seItem = selected[0];
+ RegistrationRecord.seItem1 = selected;
+
+ return true;
+ }
+};
+
+/**
+ * 上课记录
+ */
+RegistrationRecord.classRecord = function () {
+ let index = layer.open({
+ type: 2,
+ title: '上课记录',
+ area: ['100%', '100%'], //宽高
+ fix: false, //不固定
+ maxmin: true,
+ content: Feng.ctxPath + '/coursePackage/openClassRecord?id=' + $('#id').val()
+ });
+ this.layerIndex = index;
+};
+
+
+RegistrationRecord.holiClass = function () {
+ if (this.check()) {
+ var ids = RegistrationRecord.seItem1.map(function(item) {
+ return item.id;
+ }).join(",");
+ let index = layer.open({
+ type: 2,
+ title: '报名信息',
+ area: ['50%', '50%'], //宽高
+ fix: false, //不固定
+ maxmin: true,
+ content: Feng.ctxPath + '/tStudent/TTT?ids='+ids+'&id='+$('#id').val()
+ });
+ this.layerIndex = index;
+ }
+};
+
+RegistrationRecord.transClass = function () {
+ if (this.check()) {
+ var ids = RegistrationRecord.seItem1.map(function(item) {
+ return item.id;
+ }).join(",");
+ let index = layer.open({
+ type: 2,
+ title: '报名信息',
+ area: ['50%', '50%'], //宽高
+ fix: false, //不固定
+ maxmin: true,
+ content: Feng.ctxPath + '/tStudent/trans?ids='+ids+'&id='+$('#id').val()
+ });
+ this.layerIndex = index;
+ }
+};
+
+
+/**
+ * 点击修改按钮时
+ * @param userId 管理员id
+ */
+RegistrationRecord.dropClass = function () {
+ if (this.check()) {
+ if(ClassRecord.seItem.status == 2){
+ Feng.error("不能重复退课");
+ return
+ }
+ let htmlStr =
+ '<div class="form-horizontal">' +
+ ' <div class="col-sm-11">' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">课程名称:' + $("#name").text() + '</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">用户姓名:' + ClassRecord.seItem.userName + '</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">学员姓名:' + ClassRecord.seItem.studentName + '</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">*上传凭证:</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <div class="col-sm-8">\n' +
+ ' <img id="certificate" src="" style="height: 100px;">' +
+ ' <input type="file" id="file" style="display: none;"/>' +
+ ' <button onclick="uploadImgs()" style="width: 20px;padding: 10px; color: white;background-color: #0d8ddb;border-radius: 5px;"> 上传 </button>' +
+ ' </div>\n' +
+ ' </div>' +
+ ' </div>' +
+ '</div>';
+ layer.open({
+ type: 1
+ , title: '退课'
+ , area: ['50%', '50%']
+ , offset: 'auto' //具体配置参考:http://www.layui.com/doc/modules/layer.html#offset
+ , id: 'layerDemo' //防止重复弹出cge
+ , content: htmlStr
+ , btn: ['保存', '关闭']
+ , btnAlign: 'c' //按钮居中
+ , shade: 0.5 //不显示遮罩
+ , yes: function () {
+ let certificate = $('#certificate').attr('img');
+ if(null == certificate || '' == certificate){
+ Feng.error("请上传凭证图片");
+ return
+ }
+ let ajax = new $ax(Feng.ctxPath + "/coursePackage/dropTheClass", function (res) {
+ if(res.code == 200){
+ Feng.success("退课成功!");
+ layer.closeAll();
+ RegistrationRecord.table.refresh();
+ }else{
+ Feng.error(res.msg);
+ }
+ }, function (data) {
+ Feng.error("退课失败!" + data.responseJSON.message + "!");
+ });
+ ajax.set("coursePackagePaymentId", ClassRecord.seItem.id);
+ ajax.set("certificate", certificate);
+ ajax.start();
+ },
+ });
+
+ $('#file').on('change', function () {
+ var formData = new FormData() //创建一个forData
+ formData.append('file', $('#file')[0].files[0]) //把file添加进去 name命名为img
+ layer.load(); //上传loading
+ $.ajax({
+ url: Feng.ctxPath + '/mgr/uploadImg',
+ data: formData,
+ type: "POST",
+ async: true,
+ cache: false,
+ contentType: false,
+ processData: false,
+ success: function(res) {
+ layer.closeAll('loading'); //关闭loading
+ $('#file').val('');
+ $('#certificate').attr('src', res);
+ }
+ })
+ })
+ }
+};
+
+
+
+function uploadImgs(){
+ $('#file').click();
+}
+
+
+/**
+ * 删除用户
+ */
+RegistrationRecord.makeUpMissedLessons = function () {
+ if (this.check()) {
+ let operation = function(){
+ let ajax = new $ax(Feng.ctxPath + "/coursePackage/makeUpMissedLessons", function () {
+ Feng.success("补课成功!");
+ RegistrationRecord.table.refresh();
+ }, function (data) {
+ Feng.error("补课失败!" + data.responseJSON.message + "!");
+ });
+ ajax.set("id", RegistrationRecord.seItem.id);
+ ajax.start();
+ };
+
+ Feng.confirm("是否补课",operation);
+ }
+};
+
+
+
+
+RegistrationRecord.resetSearch = function () {
+ $("#userName").val("");
+ $("#studentName").val("");
+ RegistrationRecord.search();
+}
+
+RegistrationRecord.search = function () {
+ let queryData = {};
+ queryData['userName'] = $("#userName").val();
+ queryData['studentName'] = $("#studentName").val();
+ queryData['id'] = $('#id').val();
+ RegistrationRecord.table.refresh({query: queryData});
+}
+
+
+$(function () {
+ let defaultColunms = RegistrationRecord.initColumn();
+ let table = new BSTable(RegistrationRecord.id, "/coursePackage/queryRegistrationRecord", defaultColunms);
+ // 设置物理分页server(逻辑分页client)
+ table.setPaginationType("server");
+ table.setQueryParams({
+ id: $('#id').val()
+ })
+ RegistrationRecord.table = table.init();
+});
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord3.js b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord3.js
new file mode 100644
index 0000000..f75cd67
--- /dev/null
+++ b/cloud-server-management/src/main/webapp/static/modular/system/coursePackage/registrationRecord3.js
@@ -0,0 +1,259 @@
+/**
+ * 系统管理--用户管理的单例对象
+ */
+let RegistrationRecord = {
+ id: "managerTable",//表格id
+ seItem: null, //选中的条目
+ table: null,
+ layerIndex: -1
+};
+let language =$("#language").val()
+/**
+ * 初始化表格的列
+ */
+RegistrationRecord.initColumn = function () {
+ let columns = [
+ {field: 'selectItem', checkbox: true},
+ {title: 'id', field: 'id', visible: false, align: 'center', valign: 'middle'},
+ {title: '购买用户', field: 'userName', align: 'center', valign: 'middle'},
+ {title: '联系方式', field: 'phone', align: 'center', valign: 'middle'},
+ {title: '购课学员', field: 'studentName', align: 'center', valign: 'middle'},
+ {title: '购买时间', field: 'insertTime', align: 'center', valign: 'middle'},
+ // {title: '总课时数', field: 'totalClassHours', align: 'center', valign: 'middle'},
+ // {title: '剩余课时数', field: 'laveClassHours', align: 'center', valign: 'middle',rowStyle: function(row, index) {
+ // // 参数说明:
+ // //row, 行,row.xxx,能获取某个字段的值
+ // //index,索引,第几行
+ //
+ // // 逻辑判断
+ // // .....
+ // return {"background-color":'rgba(208,9,9,0.7)'};
+ // }
+ // },
+ // // {title: '已上课时数', field: 'already', align: 'center', valign: 'middle'},
+ // {title: '请假次数', field: 'absencesNumber', align: 'center', valign: 'middle'},
+ // {title: '状态', field: 'status', align: 'center', valign: 'middle',
+ // formatter: function (v) {
+ // switch (v) {
+ // case 1:
+ // return '正常';
+ // case 2:
+ // return '<a href="#" onclick="">已退课-查看凭证</a>';
+ // }
+ // }
+ // }
+ ];
+ return columns;
+};
+
+/**
+ * 检查是否选中
+ */
+RegistrationRecord.check = function () {
+ let selected = $('#' + this.id).bootstrapTable('getSelections');
+ if (selected.length == 0) {
+ Feng.info("请先选中表格中的某一记录!");
+ return false;
+ } else {
+ RegistrationRecord.seItem = selected[0];
+ RegistrationRecord.seItem1 = selected;
+
+ return true;
+ }
+};
+
+/**
+ * 上课记录
+ */
+RegistrationRecord.classRecord = function () {
+ let index = layer.open({
+ type: 2,
+ title: '上课记录',
+ area: ['100%', '100%'], //宽高
+ fix: false, //不固定
+ maxmin: true,
+ content: Feng.ctxPath + '/coursePackage/openClassRecord?id=' + $('#id').val()
+ });
+ this.layerIndex = index;
+};
+
+
+RegistrationRecord.holiClass = function () {
+ if (this.check()) {
+ var ids = RegistrationRecord.seItem1.map(function(item) {
+ return item.id;
+ }).join(",");
+ let index = layer.open({
+ type: 2,
+ title: '报名信息',
+ area: ['50%', '50%'], //宽高
+ fix: false, //不固定
+ maxmin: true,
+ content: Feng.ctxPath + '/tStudent/TTT?ids='+ids+'&id='+$('#id').val()
+ });
+ this.layerIndex = index;
+ }
+};
+
+RegistrationRecord.transClass = function () {
+ if (this.check()) {
+ var ids = RegistrationRecord.seItem1.map(function(item) {
+ return item.id;
+ }).join(",");
+ let index = layer.open({
+ type: 2,
+ title: '报名信息',
+ area: ['50%', '50%'], //宽高
+ fix: false, //不固定
+ maxmin: true,
+ content: Feng.ctxPath + '/tStudent/trans?ids='+ids+'&id='+$('#id').val()
+ });
+ this.layerIndex = index;
+ }
+};
+
+
+/**
+ * 点击修改按钮时
+ * @param userId 管理员id
+ */
+RegistrationRecord.dropClass = function () {
+ if (this.check()) {
+ if(ClassRecord.seItem.status == 2){
+ Feng.error("不能重复退课");
+ return
+ }
+ let htmlStr =
+ '<div class="form-horizontal">' +
+ ' <div class="col-sm-11">' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">课程名称:' + $("#name").text() + '</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">用户姓名:' + ClassRecord.seItem.userName + '</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">学员姓名:' + ClassRecord.seItem.studentName + '</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <label class="col-sm-8 control-label">*上传凭证:</label>\n' +
+ ' </div>' +
+ ' <div class="form-group">\n' +
+ ' <div class="col-sm-8">\n' +
+ ' <img id="certificate" src="" style="height: 100px;">' +
+ ' <input type="file" id="file" style="display: none;"/>' +
+ ' <button onclick="uploadImgs()" style="width: 20px;padding: 10px; color: white;background-color: #0d8ddb;border-radius: 5px;"> 上传 </button>' +
+ ' </div>\n' +
+ ' </div>' +
+ ' </div>' +
+ '</div>';
+ layer.open({
+ type: 1
+ , title: '退课'
+ , area: ['50%', '50%']
+ , offset: 'auto' //具体配置参考:http://www.layui.com/doc/modules/layer.html#offset
+ , id: 'layerDemo' //防止重复弹出cge
+ , content: htmlStr
+ , btn: ['保存', '关闭']
+ , btnAlign: 'c' //按钮居中
+ , shade: 0.5 //不显示遮罩
+ , yes: function () {
+ let certificate = $('#certificate').attr('img');
+ if(null == certificate || '' == certificate){
+ Feng.error("请上传凭证图片");
+ return
+ }
+ let ajax = new $ax(Feng.ctxPath + "/coursePackage/dropTheClass", function (res) {
+ if(res.code == 200){
+ Feng.success("退课成功!");
+ layer.closeAll();
+ RegistrationRecord.table.refresh();
+ }else{
+ Feng.error(res.msg);
+ }
+ }, function (data) {
+ Feng.error("退课失败!" + data.responseJSON.message + "!");
+ });
+ ajax.set("coursePackagePaymentId", ClassRecord.seItem.id);
+ ajax.set("certificate", certificate);
+ ajax.start();
+ },
+ });
+
+ $('#file').on('change', function () {
+ var formData = new FormData() //创建一个forData
+ formData.append('file', $('#file')[0].files[0]) //把file添加进去 name命名为img
+ layer.load(); //上传loading
+ $.ajax({
+ url: Feng.ctxPath + '/mgr/uploadImg',
+ data: formData,
+ type: "POST",
+ async: true,
+ cache: false,
+ contentType: false,
+ processData: false,
+ success: function(res) {
+ layer.closeAll('loading'); //关闭loading
+ $('#file').val('');
+ $('#certificate').attr('src', res);
+ }
+ })
+ })
+ }
+};
+
+
+
+function uploadImgs(){
+ $('#file').click();
+}
+
+
+/**
+ * 删除用户
+ */
+RegistrationRecord.makeUpMissedLessons = function () {
+ if (this.check()) {
+ let operation = function(){
+ let ajax = new $ax(Feng.ctxPath + "/coursePackage/makeUpMissedLessons", function () {
+ Feng.success("补课成功!");
+ RegistrationRecord.table.refresh();
+ }, function (data) {
+ Feng.error("补课失败!" + data.responseJSON.message + "!");
+ });
+ ajax.set("id", RegistrationRecord.seItem.id);
+ ajax.start();
+ };
+
+ Feng.confirm("是否补课",operation);
+ }
+};
+
+
+
+
+RegistrationRecord.resetSearch = function () {
+ $("#userName").val("");
+ $("#studentName").val("");
+ RegistrationRecord.search();
+}
+
+RegistrationRecord.search = function () {
+ let queryData = {};
+ queryData['userName'] = $("#userName").val();
+ queryData['studentName'] = $("#studentName").val();
+ queryData['id'] = $('#id').val();
+ RegistrationRecord.table.refresh({query: queryData});
+}
+
+
+$(function () {
+ let defaultColunms = RegistrationRecord.initColumn();
+ let table = new BSTable(RegistrationRecord.id, "/coursePackage/queryRegistrationRecord", defaultColunms);
+ // 设置物理分页server(逻辑分页client)
+ table.setPaginationType("server");
+ table.setQueryParams({
+ id: $('#id').val()
+ })
+ RegistrationRecord.table = table.init();
+});
diff --git a/cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js b/cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js
index c25024a..bd1eca8 100644
--- a/cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js
+++ b/cloud-server-management/src/main/webapp/static/modular/system/tStudent/tStudent.js
@@ -14,21 +14,53 @@
TStudent.initColumn = function () {
return [
{field: 'selectItem', radio: true},
- {title: '主键', field: 'id', visible: true, align: 'center', valign: 'middle'},
- {title: '用户id', field: 'appUserId', visible: true, align: 'center', valign: 'middle'},
- {title: '学员姓名', field: 'name', visible: true, align: 'center', valign: 'middle'},
- {title: '学员电话', field: 'phone', visible: true, align: 'center', valign: 'middle'},
- {title: '生日', field: 'birthday', visible: true, align: 'center', valign: 'middle'},
- {title: '性别(1=男,2=女)', field: 'sex', visible: true, align: 'center', valign: 'middle'},
- {title: '身高', field: 'height', visible: true, align: 'center', valign: 'middle'},
- {title: '体重', field: 'weight', visible: true, align: 'center', valign: 'middle'},
- {title: 'bmi健康值', field: 'bmi', visible: true, align: 'center', valign: 'middle'},
- {title: '身份证号', field: 'idCard', visible: true, align: 'center', valign: 'middle'},
- {title: '体侧表', field: 'lateralSurface', visible: true, align: 'center', valign: 'middle'},
- {title: '状态(1=正常,2=冻结,3=删除)', field: 'state', visible: true, align: 'center', valign: 'middle'},
- {title: '添加时间', field: 'insertTime', visible: true, align: 'center', valign: 'middle'},
- {title: '是否默认 1默认 2不是默认', field: 'isDefault', visible: true, align: 'center', valign: 'middle'},
- {title: '学员头像', field: 'headImg', visible: true, align: 'center', valign: 'middle'}
+ {title: '主键', field: 'id', visible: false, align: 'center', valign: 'middle'},
+ {title: '所属用户', field: 'userName', visible: true, align: 'center', valign: 'middle'},
+ {title: '姓名', field: 'name', visible: true, align: 'center', valign: 'middle'},
+ {title: '联系电话电话', field: 'phone', visible: true, align: 'center', valign: 'middle'},
+ { title: '生日', field: 'birthday', visible: true, align: 'center', valign: 'middle', formatter: function(value) {
+ return new Date(value).toLocaleDateString();
+ }},
+ {
+ title: '性别',
+ field: 'sex',
+ visible: true,
+ align: 'center',
+ valign: 'middle',
+ formatter: function(value) {
+ if (value === 1) {
+ return '男';
+ } else if (value === 2) {
+ return '女';
+ } else {
+ return '';
+ }
+ }
+ },
+ {title: '身高(cm)', field: 'height', visible: true, align: 'center', valign: 'middle'},
+ {title: '体重(kg)', field: 'weight', visible: true, align: 'center', valign: 'middle'},
+ {title: 'bmi健康值', field: 'bmi', visible: false, align: 'center', valign: 'middle'},
+ {title: '身份证号', field: 'idCard', visible: false, align: 'center', valign: 'middle'},
+ {title: '体侧表', field: 'lateralSurface', visible: false, align: 'center', valign: 'middle'},
+ {
+ title: '状态',
+ field: 'state',
+ visible: true,
+ align: 'center',
+ valign: 'middle',
+ formatter: function(value) {
+ if (value === 1) {
+ return '正常';
+ } else if (value === 2) {
+ return '冻结';
+ } else {
+ return '';
+ }
+ }
+ },
+ {title: '添加时间', field: 'insertTime', visible: false, align: 'center', valign: 'middle'},
+ {title: '是否默认 1默认 2不是默认', field: 'isDefault', visible: false, align: 'center', valign: 'middle'},
+ {title: '学员头像', field: 'headImg', visible: false, align: 'center', valign: 'middle'}
];
};
diff --git a/package-lock.json b/package-lock.json
new file mode 100644
index 0000000..cb09dcd
--- /dev/null
+++ b/package-lock.json
@@ -0,0 +1,207 @@
+{
+ "name": "PlayPai1",
+ "lockfileVersion": 3,
+ "requires": true,
+ "packages": {
+ "": {
+ "dependencies": {
+ "html2canvas": "^1.4.1",
+ "jspdf": "^2.5.1"
+ }
+ },
+ "node_modules/@babel/runtime": {
+ "version": "7.22.15",
+ "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.22.15.tgz",
+ "integrity": "sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==",
+ "dependencies": {
+ "regenerator-runtime": "^0.14.0"
+ },
+ "engines": {
+ "node": ">=6.9.0"
+ }
+ },
+ "node_modules/@types/raf": {
+ "version": "3.4.0",
+ "resolved": "https://registry.npmjs.org/@types/raf/-/raf-3.4.0.tgz",
+ "integrity": "sha512-taW5/WYqo36N7V39oYyHP9Ipfd5pNFvGTIQsNGj86xV88YQ7GnI30/yMfKDF7Zgin0m3e+ikX88FvImnK4RjGw==",
+ "optional": true
+ },
+ "node_modules/atob": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
+ "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==",
+ "bin": {
+ "atob": "bin/atob.js"
+ },
+ "engines": {
+ "node": ">= 4.5.0"
+ }
+ },
+ "node_modules/base64-arraybuffer": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/base64-arraybuffer/-/base64-arraybuffer-1.0.2.tgz",
+ "integrity": "sha512-I3yl4r9QB5ZRY3XuJVEPfc2XhZO6YweFPI+UovAzn+8/hb3oJ6lnysaFcjVpkCPfVWFUDvoZ8kmVDP7WyRtYtQ==",
+ "engines": {
+ "node": ">= 0.6.0"
+ }
+ },
+ "node_modules/btoa": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/btoa/-/btoa-1.2.1.tgz",
+ "integrity": "sha512-SB4/MIGlsiVkMcHmT+pSmIPoNDoHg+7cMzmt3Uxt628MTz2487DKSqK/fuhFBrkuqrYv5UCEnACpF4dTFNKc/g==",
+ "bin": {
+ "btoa": "bin/btoa.js"
+ },
+ "engines": {
+ "node": ">= 0.4.0"
+ }
+ },
+ "node_modules/canvg": {
+ "version": "3.0.10",
+ "resolved": "https://registry.npmjs.org/canvg/-/canvg-3.0.10.tgz",
+ "integrity": "sha512-qwR2FRNO9NlzTeKIPIKpnTY6fqwuYSequ8Ru8c0YkYU7U0oW+hLUvWadLvAu1Rl72OMNiFhoLu4f8eUjQ7l/+Q==",
+ "optional": true,
+ "dependencies": {
+ "@babel/runtime": "^7.12.5",
+ "@types/raf": "^3.4.0",
+ "core-js": "^3.8.3",
+ "raf": "^3.4.1",
+ "regenerator-runtime": "^0.13.7",
+ "rgbcolor": "^1.0.1",
+ "stackblur-canvas": "^2.0.0",
+ "svg-pathdata": "^6.0.3"
+ },
+ "engines": {
+ "node": ">=10.0.0"
+ }
+ },
+ "node_modules/canvg/node_modules/regenerator-runtime": {
+ "version": "0.13.11",
+ "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz",
+ "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==",
+ "optional": true
+ },
+ "node_modules/core-js": {
+ "version": "3.32.2",
+ "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz",
+ "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==",
+ "hasInstallScript": true,
+ "optional": true,
+ "funding": {
+ "type": "opencollective",
+ "url": "https://opencollective.com/core-js"
+ }
+ },
+ "node_modules/css-line-break": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/css-line-break/-/css-line-break-2.1.0.tgz",
+ "integrity": "sha512-FHcKFCZcAha3LwfVBhCQbW2nCNbkZXn7KVUJcsT5/P8YmfsVja0FMPJr0B903j/E69HUphKiV9iQArX8SDYA4w==",
+ "dependencies": {
+ "utrie": "^1.0.2"
+ }
+ },
+ "node_modules/dompurify": {
+ "version": "2.4.7",
+ "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-2.4.7.tgz",
+ "integrity": "sha512-kxxKlPEDa6Nc5WJi+qRgPbOAbgTpSULL+vI3NUXsZMlkJxTqYI9wg5ZTay2sFrdZRWHPWNi+EdAhcJf81WtoMQ==",
+ "optional": true
+ },
+ "node_modules/fflate": {
+ "version": "0.4.8",
+ "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.4.8.tgz",
+ "integrity": "sha512-FJqqoDBR00Mdj9ppamLa/Y7vxm+PRmNWA67N846RvsoYVMKB4q3y/de5PA7gUmRMYK/8CMz2GDZQmCRN1wBcWA=="
+ },
+ "node_modules/html2canvas": {
+ "version": "1.4.1",
+ "resolved": "https://registry.npmjs.org/html2canvas/-/html2canvas-1.4.1.tgz",
+ "integrity": "sha512-fPU6BHNpsyIhr8yyMpTLLxAbkaK8ArIBcmZIRiBLiDhjeqvXolaEmDGmELFuX9I4xDcaKKcJl+TKZLqruBbmWA==",
+ "dependencies": {
+ "css-line-break": "^2.1.0",
+ "text-segmentation": "^1.0.3"
+ },
+ "engines": {
+ "node": ">=8.0.0"
+ }
+ },
+ "node_modules/jspdf": {
+ "version": "2.5.1",
+ "resolved": "https://registry.npmjs.org/jspdf/-/jspdf-2.5.1.tgz",
+ "integrity": "sha512-hXObxz7ZqoyhxET78+XR34Xu2qFGrJJ2I2bE5w4SM8eFaFEkW2xcGRVUss360fYelwRSid/jT078kbNvmoW0QA==",
+ "dependencies": {
+ "@babel/runtime": "^7.14.0",
+ "atob": "^2.1.2",
+ "btoa": "^1.2.1",
+ "fflate": "^0.4.8"
+ },
+ "optionalDependencies": {
+ "canvg": "^3.0.6",
+ "core-js": "^3.6.0",
+ "dompurify": "^2.2.0",
+ "html2canvas": "^1.0.0-rc.5"
+ }
+ },
+ "node_modules/performance-now": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz",
+ "integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==",
+ "optional": true
+ },
+ "node_modules/raf": {
+ "version": "3.4.1",
+ "resolved": "https://registry.npmjs.org/raf/-/raf-3.4.1.tgz",
+ "integrity": "sha512-Sq4CW4QhwOHE8ucn6J34MqtZCeWFP2aQSmrlroYgqAV1PjStIhJXxYuTgUIfkEk7zTLjmIjLmU5q+fbD1NnOJA==",
+ "optional": true,
+ "dependencies": {
+ "performance-now": "^2.1.0"
+ }
+ },
+ "node_modules/regenerator-runtime": {
+ "version": "0.14.0",
+ "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz",
+ "integrity": "sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA=="
+ },
+ "node_modules/rgbcolor": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/rgbcolor/-/rgbcolor-1.0.1.tgz",
+ "integrity": "sha512-9aZLIrhRaD97sgVhtJOW6ckOEh6/GnvQtdVNfdZ6s67+3/XwLS9lBcQYzEEhYVeUowN7pRzMLsyGhK2i/xvWbw==",
+ "optional": true,
+ "engines": {
+ "node": ">= 0.8.15"
+ }
+ },
+ "node_modules/stackblur-canvas": {
+ "version": "2.6.0",
+ "resolved": "https://registry.npmjs.org/stackblur-canvas/-/stackblur-canvas-2.6.0.tgz",
+ "integrity": "sha512-8S1aIA+UoF6erJYnglGPug6MaHYGo1Ot7h5fuXx4fUPvcvQfcdw2o/ppCse63+eZf8PPidSu4v1JnmEVtEDnpg==",
+ "optional": true,
+ "engines": {
+ "node": ">=0.1.14"
+ }
+ },
+ "node_modules/svg-pathdata": {
+ "version": "6.0.3",
+ "resolved": "https://registry.npmjs.org/svg-pathdata/-/svg-pathdata-6.0.3.tgz",
+ "integrity": "sha512-qsjeeq5YjBZ5eMdFuUa4ZosMLxgr5RZ+F+Y1OrDhuOCEInRMA3x74XdBtggJcj9kOeInz0WE+LgCPDkZFlBYJw==",
+ "optional": true,
+ "engines": {
+ "node": ">=12.0.0"
+ }
+ },
+ "node_modules/text-segmentation": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/text-segmentation/-/text-segmentation-1.0.3.tgz",
+ "integrity": "sha512-iOiPUo/BGnZ6+54OsWxZidGCsdU8YbE4PSpdPinp7DeMtUJNJBoJ/ouUSTJjHkh1KntHaltHl/gDs2FC4i5+Nw==",
+ "dependencies": {
+ "utrie": "^1.0.2"
+ }
+ },
+ "node_modules/utrie": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/utrie/-/utrie-1.0.2.tgz",
+ "integrity": "sha512-1MLa5ouZiOmQzUbjbu9VmjLzn1QLXBhwpUa7kdLUQK+KQ5KA9I1vk5U4YHe/X2Ch7PYnJfWuWT+VbuxbGwljhw==",
+ "dependencies": {
+ "base64-arraybuffer": "^1.0.2"
+ }
+ }
+ }
+}
diff --git a/package.json b/package.json
new file mode 100644
index 0000000..2a784d8
--- /dev/null
+++ b/package.json
@@ -0,0 +1,6 @@
+{
+ "dependencies": {
+ "html2canvas": "^1.4.1",
+ "jspdf": "^2.5.1"
+ }
+}
--
Gitblit v1.7.1