Commit 6cdedff9 by Cat
parents c9d607c2 8cca9710
...@@ -126,6 +126,12 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter ...@@ -126,6 +126,12 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
.antMatchers( "/dd/school/**").permitAll() .antMatchers( "/dd/school/**").permitAll()
//打印下载接口放行 //打印下载接口放行
.antMatchers("/school/student/queryOne/**","/school/studentStatus/proofStatus/**").permitAll() .antMatchers("/school/student/queryOne/**","/school/studentStatus/proofStatus/**").permitAll()
//打印设备条码信息
.antMatchers("/equipmentLedger/getEquipmentledger/**").permitAll()
.antMatchers("/school/studentStatus/exportStatus/**","/school/student/queryAllInfo/**").permitAll()
//网页注册登录接口放行 //网页注册登录接口放行
.antMatchers( "/web/artStudent/register","/web/artStudent/login").permitAll() .antMatchers( "/web/artStudent/register","/web/artStudent/login").permitAll()
// 静态资源,可匿名访问 // 静态资源,可匿名访问
......
...@@ -34,6 +34,10 @@ ...@@ -34,6 +34,10 @@
<groupId>com.ruoyi</groupId> <groupId>com.ruoyi</groupId>
<artifactId>ruoyi-common</artifactId> <artifactId>ruoyi-common</artifactId>
</dependency> </dependency>
<dependency>
<groupId>com.ruoyi</groupId>
<artifactId>smart-campus</artifactId>
</dependency>
</dependencies> </dependencies>
......
package com.ruoyi.quartz.task; package com.ruoyi.quartz.task;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import com.ruoyi.common.utils.StringUtils; import com.ruoyi.common.utils.StringUtils;
import yangtz.cs.liu.dingding.controller.DingJiaXiaoController;
/** /**
* 定时任务调度测试 * 定时任务调度测试
...@@ -11,6 +13,9 @@ import com.ruoyi.common.utils.StringUtils; ...@@ -11,6 +13,9 @@ import com.ruoyi.common.utils.StringUtils;
@Component("ryTask") @Component("ryTask")
public class RyTask public class RyTask
{ {
@Autowired
DingJiaXiaoController dingJiaXiaoController;
public void ryMultipleParams(String s, Boolean b, Long l, Double d, Integer i) public void ryMultipleParams(String s, Boolean b, Long l, Double d, Integer i)
{ {
System.out.println(StringUtils.format("执行多参方法: 字符串类型{},布尔类型{},长整型{},浮点型{},整形{}", s, b, l, d, i)); System.out.println(StringUtils.format("执行多参方法: 字符串类型{},布尔类型{},长整型{},浮点型{},整形{}", s, b, l, d, i));
...@@ -25,4 +30,14 @@ public class RyTask ...@@ -25,4 +30,14 @@ public class RyTask
{ {
System.out.println("执行无参方法"); System.out.println("执行无参方法");
} }
public void updateLabClassYear(){
dingJiaXiaoController.updateLabClassYear();
}
public void updateLabUser(){
dingJiaXiaoController.updateLabUser();
}
} }
...@@ -57,8 +57,15 @@ export function deleteEquipmentLedger(id) { ...@@ -57,8 +57,15 @@ export function deleteEquipmentLedger(id) {
**/ **/
export function getUserList(params) { export function getUserList(params) {
return request({ return request({
url: '/equipmentLedger/getUser', url: "/equipmentLedger/getUser",
method: "GET", method: "GET",
params params,
});
}
//获取打印设备条码信息
export function equipmentPrint(ids) {
return request({
url: `/equipmentLedger/getEquipmentledger/${ids}`,
method: "get",
}); });
} }
...@@ -2,22 +2,21 @@ ...@@ -2,22 +2,21 @@
<div class="app-container fixed-scroll-error"> <div class="app-container fixed-scroll-error">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="4" :xs="24"> <el-col :span="4" :xs="24">
<el-card shadow="never" :style="{ height: clientHeight }"> <el-card class="scrollable-card" shadow="never" :style="{ height: clientHeight }">
<template slot="header"> <template slot="header">
<div style="display:flex; justify-content: space-between"> <div style="display:flex; justify-content: space-between">
<div style="display:flex; align-items: center"> <div style="display:flex; align-items: center">
<span>班级列表</span> <span>班级列表</span>
</div> </div>
<el-select v-model="queryParams.schoolYear" style="width: 100px;" size="small" @change="handleYearChange"> <el-select v-model="queryParams.schoolYear" style="width: 100px;" size="small" @change="handleYearChange">
<el-option v-for="item in yearList" :key="item.value" :value="item.value" <el-option v-for="item in yearList" :key="item.value" :value="item.value" :label="item.label"></el-option>
:label="item.label"></el-option>
</el-select> </el-select>
</div> </div>
</template> </template>
<div class="head-container"> <div class="head-container">
<el-tree :data="leftOptions.treeOptions" :props="leftOptions.defaultProps" :expand-on-click-node="false" <el-tree :data="leftOptions.treeOptions" :props="leftOptions.defaultProps" :expand-on-click-node="false"
:filter-node-method="filterNode" ref="tree" node-key="id" default-expand-all highlight-current :filter-node-method="filterNode" ref="tree" node-key="id" default-expand-all highlight-current
@node-click="handleNodeClick"/> @node-click="handleNodeClick" />
</div> </div>
</el-card> </el-card>
</el-col> </el-col>
...@@ -36,86 +35,86 @@ ...@@ -36,86 +35,86 @@
<div class="classes-info-table el-table el-table--enable-row-hover el-table--medium"> <div class="classes-info-table el-table el-table--enable-row-hover el-table--medium">
<table cellspacing="0" style="width: 100%"> <table cellspacing="0" style="width: 100%">
<tbody> <tbody>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班级 :</div> <div class="cell">班级 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.className }}</div> <div class="cell">{{ classInfo.className }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">类别 :</div> <div class="cell">类别 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ resolveGradeType(classInfo.classType) }}</div> <div class="cell">{{ resolveGradeType(classInfo.classType) }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">年级 :</div> <div class="cell">年级 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.gradeName }}</div> <div class="cell">{{ classInfo.gradeName }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班主任 :</div> <div class="cell">班主任 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.teacherName }}</div> <div class="cell">{{ classInfo.teacherName }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">别名 :</div> <div class="cell">别名 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.classAlias }}</div> <div class="cell">{{ classInfo.classAlias }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">联系电话 :</div> <div class="cell">联系电话 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.teacherTel }}</div> <div class="cell">{{ classInfo.teacherTel }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">开始学年 :</div> <div class="cell">开始学年 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.schoolYear }}</div> <div class="cell">{{ classInfo.schoolYear }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班级口号 :</div> <div class="cell">班级口号 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.classSlogan }}</div> <div class="cell">{{ classInfo.classSlogan }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">所在教学楼 :</div> <div class="cell">所在教学楼 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.houseName }}</div> <div class="cell">{{ classInfo.houseName }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班主任寄语 :</div> <div class="cell">班主任寄语 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.teacherWord }}</div> <div class="cell">{{ classInfo.teacherWord }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
...@@ -138,41 +137,39 @@ ...@@ -138,41 +137,39 @@
<el-radio-button :label="Types.TEACHER">老师信息</el-radio-button> <el-radio-button :label="Types.TEACHER">老师信息</el-radio-button>
</el-radio-group> </el-radio-group>
<el-table v-if="activeName === Types.STUDENT" stripe v-loading="studentLoading" width="100%" <el-table v-if="activeName === Types.STUDENT" stripe v-loading="studentLoading" width="100%"
:cell-style="customCellStyle" :data="rightData.studentList" :key="Types.STUDENT"> :cell-style="customCellStyle" :data="rightData.studentList" :key="Types.STUDENT">
<el-table-column type="selection" width="55" align="center"/> <el-table-column type="selection" width="55" align="center" />
<el-table-column fixed="left" key="avatar" align="center" prop="avatar" label="头像"> <el-table-column fixed="left" key="avatar" align="center" prop="avatar" label="头像">
<template slot-scope="scope"> <template slot-scope="scope">
<ListImage :image-url="isEmptyAvatar(scope.row.avatar, scope.row.sex)"></ListImage> <ListImage :image-url="isEmptyAvatar(scope.row.avatar, scope.row.sex)"></ListImage>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName" <el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName" label="姓名" />
label="姓名"/> <el-table-column key="score" min-width="80" align="center" prop="score" label="积分" />
<el-table-column key="score" min-width="80" align="center" prop="score" label="积分"/> <el-table-column key="grade" min-width="100px" align="center" prop="classAlias" label="班级" />
<el-table-column key="grade" min-width="100px" align="center" prop="classAlias" label="班级"/>
<el-table-column key="sex" min-width="50px" align="center" prop="sex" label="性别"> <el-table-column key="sex" min-width="50px" align="center" prop="sex" label="性别">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"></dict-tag> <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="nation" width="100" align="center" prop="nation" label="民族"/> <el-table-column key="nation" width="100" align="center" prop="nation" label="民族" />
<el-table-column key="nativePlace" min-width="100" header-align="center" align="center" prop="nativePlace" <el-table-column key="nativePlace" min-width="100" header-align="center" align="center" prop="nativePlace"
label="籍贯" show-overflow-tooltip></el-table-column> label="籍贯" show-overflow-tooltip></el-table-column>
<el-table-column key="idCard" width="180" align="center" prop="idCard" label="身份证号"/> <el-table-column key="idCard" width="180" align="center" prop="idCard" label="身份证号" />
<el-table-column key="stuTelephone" width="130" align="center" prop="stuTelephone" label="联系电话"/> <el-table-column key="stuTelephone" width="130" align="center" prop="stuTelephone" label="联系电话" />
<el-table-column key="birthAddress" width="150" align="center" prop="birthAddress" label="出生地"/> <el-table-column key="birthAddress" width="150" align="center" prop="birthAddress" label="出生地" />
<el-table-column key="postalCode" width="150" align="center" prop="postalCode" label="邮政编码"/> <el-table-column key="postalCode" width="150" align="center" prop="postalCode" label="邮政编码" />
<el-table-column key="enrollmentYear" width="100" align="center" prop="enrollmentYear" label="级/届"/> <el-table-column key="enrollmentYear" width="100" align="center" prop="enrollmentYear" label="级/届" />
<el-table-column key="enrollmentTime" min-width="100" header-align="center" align="center" <el-table-column key="enrollmentTime" min-width="100" header-align="center" align="center"
prop="enrollmentTime" label="入学时间" show-overflow-tooltip></el-table-column> prop="enrollmentTime" label="入学时间" show-overflow-tooltip></el-table-column>
<el-table-column key="platform" width="180" align="center" prop="platform" label="平台"/> <el-table-column key="platform" width="180" align="center" prop="platform" label="平台" />
<el-table-column key="studentType" width="130" align="center" prop="studentType" label="学生类型"> <el-table-column key="studentType" width="130" align="center" prop="studentType" label="学生类型">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag> <dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber" <el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber" label="省学籍辅号" />
label="省学籍辅号"/> <el-table-column key="nationalNumber" width="150" align="center" prop="nationalNumber" label="全国学籍号" />
<el-table-column key="nationalNumber" width="150" align="center" prop="nationalNumber" label="全国学籍号"/>
<el-table-column key="studentStatus" width="80" align="center" prop="studentStatus" label="学生状态"> <el-table-column key="studentStatus" width="80" align="center" prop="studentStatus" label="学生状态">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.child_state" :value="scope.row.studentStatus"></dict-tag> <dict-tag :options="dict.type.child_state" :value="scope.row.studentStatus"></dict-tag>
...@@ -183,43 +180,41 @@ ...@@ -183,43 +180,41 @@
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag> <dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="schoolNo" width="100" align="center" prop="schoolNo" label="注册序号"/> <el-table-column key="schoolNo" width="100" align="center" prop="schoolNo" label="注册序号" />
<el-table-column key="registeredAddress" min-width="100" header-align="center" align="center" <el-table-column key="registeredAddress" min-width="100" header-align="center" align="center"
prop="registeredAddress" label="户口所在地" show-overflow-tooltip></el-table-column> prop="registeredAddress" label="户口所在地" show-overflow-tooltip></el-table-column>
<el-table-column key="registeredType" width="180" align="center" prop="registeredType" label="户口性质"> <el-table-column key="registeredType" width="180" align="center" prop="registeredType" label="户口性质">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.regist_type" :value="scope.row.registeredType"/> <dict-tag :options="dict.type.regist_type" :value="scope.row.registeredType" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="juniorSchool" width="130" align="center" prop="juniorSchool" label="初中学校"/> <el-table-column key="juniorSchool" width="130" align="center" prop="juniorSchool" label="初中学校" />
<el-table-column key="region" width="150" align="center" prop="region" label="国家地区"/> <el-table-column key="region" width="150" align="center" prop="region" label="国家地区" />
<el-table-column key="foreignLanguages" width="150" align="center" prop="foreignLanguages" <el-table-column key="foreignLanguages" width="150" align="center" prop="foreignLanguages" label="外语语种" />
label="外语语种"/>
<el-table-column key="appearance" width="150" align="center" prop="appearance" label="政治面貌"> <el-table-column key="appearance" width="150" align="center" prop="appearance" label="政治面貌">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.politics_tatus" :value="scope.row.appearance"></dict-tag> <dict-tag :options="dict.type.politics_tatus" :value="scope.row.appearance"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="birthday" width="120" sortable align="center" prop="birthday" <el-table-column key="birthday" width="120" sortable align="center" prop="birthday"
label="出生日期"></el-table-column> label="出生日期"></el-table-column>
<el-table-column key="homeAddress" min-width="200" align="center" prop="homeAddress" label="家庭住址" <el-table-column key="homeAddress" min-width="200" align="center" prop="homeAddress" label="家庭住址"
show-overflow-tooltip> show-overflow-tooltip>
<template v-slot="scope"> <template v-slot="scope">
<span class="one-line-omit"> <span class="one-line-omit">
{{ scope.row.homeAddress }} {{ scope.row.homeAddress }}
</span> </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="bloodType" width="100" align="center" prop="bloodType" label="血型"/> <el-table-column key="bloodType" width="100" align="center" prop="bloodType" label="血型" />
<el-table-column key="health" min-width="100" header-align="center" align="center" prop="health" <el-table-column key="health" min-width="100" header-align="center" align="center" prop="health" label="健康状况"
label="健康状况" show-overflow-tooltip></el-table-column>
show-overflow-tooltip></el-table-column> <el-table-column key="otherRegions" width="180" align="center" prop="otherRegions" label="港澳台侨" />
<el-table-column key="otherRegions" width="180" align="center" prop="otherRegions" label="港澳台侨"/>
<el-table-column key="floatingPopulation" width="130" align="center" prop="floatingPopulation" <el-table-column key="floatingPopulation" width="130" align="center" prop="floatingPopulation"
label="流动人口状况"/> label="流动人口状况" />
<el-table-column key="onlyChild" width="150" align="center" prop="onlyChild" label="独生子女"> <el-table-column key="onlyChild" width="150" align="center" prop="onlyChild" label="独生子女">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.only_child" :value="scope.row.onlyChild"/> <dict-tag :options="dict.type.only_child" :value="scope.row.onlyChild" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="nature" width="150" align="center" prop="nature" label="性质"> <el-table-column key="nature" width="150" align="center" prop="nature" label="性质">
...@@ -227,8 +222,7 @@ ...@@ -227,8 +222,7 @@
<dict-tag :options="dict.type.student_nature" :value="scope.row.nature"></dict-tag> <dict-tag :options="dict.type.student_nature" :value="scope.row.nature"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="support" width="150" align="center" prop="support" <el-table-column key="support" width="150" align="center" prop="support" label="接收资助情况"></el-table-column>
label="接收资助情况"></el-table-column>
<el-table-column label="操作" align="center" min-width="200px" fixed="right"> <el-table-column label="操作" align="center" min-width="200px" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<!-- <el-button--> <!-- <el-button-->
...@@ -246,37 +240,36 @@ ...@@ -246,37 +240,36 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-table v-else v-loading="teacherLoading" stripe border style="width: 100%;" :cell-style="customCellStyle" <el-table v-else v-loading="teacherLoading" stripe border style="width: 100%;" :cell-style="customCellStyle"
:data="rightData.teacherList" :key="Types.TEACHER"> :data="rightData.teacherList" :key="Types.TEACHER">
<el-table-column label="头像" align="center" width="100" prop="picUrl"> <el-table-column label="头像" align="center" width="100" prop="picUrl">
<template slot-scope="scope"> <template slot-scope="scope">
<ListImage :image-url="isEmptyAvatar(scope.row.picUrl, scope.row.sex)"></ListImage> <ListImage :image-url="isEmptyAvatar(scope.row.picUrl, scope.row.sex)"></ListImage>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="老师名称" align="center" prop="teacherName"/> <el-table-column label="老师名称" align="center" prop="teacherName" />
<el-table-column label="性别" align="center" width="55" prop="sex"> <el-table-column label="性别" align="center" width="55" prop="sex">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"/> <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="工作编号" width="180px" align="center" prop="teacherCode"/> <el-table-column label="工作编号" width="180px" align="center" prop="teacherCode" />
<el-table-column label="老师电话" width="180px" align="center" prop="teacherTel"/> <el-table-column label="老师电话" width="180px" align="center" prop="teacherTel" />
<el-table-column label="任教课程" align="center" prop="courseName"></el-table-column> <el-table-column label="任教课程" align="center" prop="courseName"></el-table-column>
<el-table-column label="学历" align="center" prop="education"> <el-table-column label="学历" align="center" prop="education">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.education" :value="scope.row.education"/> <dict-tag :options="dict.type.education" :value="scope.row.education" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center"> <el-table-column label="操作" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" size="mini" icon="el-icon-search" <el-button type="text" size="mini" icon="el-icon-search"
@click="getTeacherDetail(scope.row.teacherId)">老师详情 @click="getTeacherDetail(scope.row.teacherId)">老师详情
</el-button> </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<ExPagination :total="activeName === Types.STUDENT ? studentTotal : teacherTotal" <ExPagination :total="activeName === Types.STUDENT ? studentTotal : teacherTotal"
:limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum" @pagination="getClassDetails">
@pagination="getClassDetails">
</ExPagination> </ExPagination>
</el-row> </el-row>
</el-col> </el-col>
...@@ -285,10 +278,10 @@ ...@@ -285,10 +278,10 @@
<el-form v-if="personDetail.isStudent" ref="studentForm" :model="studentForm" disabled label-width="114px"> <el-form v-if="personDetail.isStudent" ref="studentForm" :model="studentForm" disabled label-width="114px">
<el-form-item prop="avatar" label-width="0" style="display: flex; justify-content: center;"> <el-form-item prop="avatar" label-width="0" style="display: flex; justify-content: center;">
<el-image :src="studentForm.avatar" :preview-src-list="[studentForm.avatar]" <el-image :src="studentForm.avatar" :preview-src-list="[studentForm.avatar]"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
<div slot="error"> <div slot="error">
<img :src="isEmptyAvatar(studentForm.avatar, studentForm.sex)" <img :src="isEmptyAvatar(studentForm.avatar, studentForm.sex)"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
</div> </div>
</el-image> </el-image>
</el-form-item> </el-form-item>
...@@ -307,7 +300,7 @@ ...@@ -307,7 +300,7 @@
<el-form-item label="性别:" prop="sex"> <el-form-item label="性别:" prop="sex">
<el-select v-model="studentForm.sex" placeholder="请输入性别" style="width: 100%;"> <el-select v-model="studentForm.sex" placeholder="请输入性别" style="width: 100%;">
<el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -322,16 +315,15 @@ ...@@ -322,16 +315,15 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="出生日期:" prop="birthday"> <el-form-item label="出生日期:" prop="birthday">
<el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd" <el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd" placeholder="请选择出生日期"
placeholder="请选择出生日期" style="width: 100%;"></el-date-picker>
style="width: 100%;"></el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<!-- <el-input v-model="studentForm.className" clearable></el-input>--> <!-- <el-input v-model="studentForm.className" clearable></el-input>-->
<el-form-item label="班级:" prop="classAlias"> <el-form-item label="班级:" prop="classAlias">
<el-input v-model="studentForm.classAlias" placeholder="请选择班级" readonly @focus="selectClass" <el-input v-model="studentForm.classAlias" placeholder="请选择班级" readonly @focus="selectClass"
style="width: 100%"></el-input> style="width: 100%"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -341,7 +333,7 @@ ...@@ -341,7 +333,7 @@
<el-form-item label="学生状态:" prop="studentStatus"> <el-form-item label="学生状态:" prop="studentStatus">
<el-select v-model="studentForm.studentStatus" placeholder="请输入学生状态" style="width: 100%;"> <el-select v-model="studentForm.studentStatus" placeholder="请输入学生状态" style="width: 100%;">
<el-option v-for="dict in dict.type.child_state" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.child_state" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -350,7 +342,7 @@ ...@@ -350,7 +342,7 @@
<el-form-item label="学生类型:" prop="studentType"> <el-form-item label="学生类型:" prop="studentType">
<el-select v-model="studentForm.studentType" placeholder="请输入学生类型" style="width: 100%;"> <el-select v-model="studentForm.studentType" placeholder="请输入学生类型" style="width: 100%;">
<el-option v-for="dict in dict.type.student_type" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.student_type" :key="dict.value" :label="dict.label"
:value="dict.value">{{ dict.label }} :value="dict.value">{{ dict.label }}
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -375,8 +367,7 @@ ...@@ -375,8 +367,7 @@
<el-col :span="8"> <el-col :span="8">
<el-form-item label="民族:" prop="nation"> <el-form-item label="民族:" prop="nation">
<el-select v-model="studentForm.nation" placeholder="请选择民族" style="width: 100%"> <el-select v-model="studentForm.nation" placeholder="请选择民族" style="width: 100%">
<el-option v-for="item in Nations" :key="item.label" :label="item.label" <el-option v-for="item in Nations" :key="item.label" :label="item.label" :value="item.label"></el-option>
:value="item.label"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -402,15 +393,13 @@ ...@@ -402,15 +393,13 @@
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="8"> <el-col :span="8">
<el-form-item label="级/届:" prop="enrollmentYear"> <el-form-item label="级/届:" prop="enrollmentYear">
<el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year" <el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year" placeholder="选择入学年">
placeholder="选择入学年">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="入学时间:" prop="enrollmentTime"> <el-form-item label="入学时间:" prop="enrollmentTime">
<el-date-picker v-model="studentForm.enrollmentTime" style="width: 100%" type="date" <el-date-picker v-model="studentForm.enrollmentTime" style="width: 100%" type="date" placeholder="选择入学时间">
placeholder="选择入学时间">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -453,10 +442,7 @@ ...@@ -453,10 +442,7 @@
<el-col :span="8"> <el-col :span="8">
<el-form-item label="户口性质:" prop="registeredType"> <el-form-item label="户口性质:" prop="registeredType">
<el-select v-model="studentForm.registeredType" style="width: 100%" placeholder="请输入户口性质"> <el-select v-model="studentForm.registeredType" style="width: 100%" placeholder="请输入户口性质">
<el-option <el-option v-for="dict in dict.type.regist_type" :key="dict.value" :label="dict.label"
v-for="dict in dict.type.regist_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
...@@ -479,7 +465,7 @@ ...@@ -479,7 +465,7 @@
<el-form-item label="政治面貌:" prop="appearance"> <el-form-item label="政治面貌:" prop="appearance">
<el-select v-model="studentForm.appearance" style="width: 100%" placeholder="请选择政治面貌"> <el-select v-model="studentForm.appearance" style="width: 100%" placeholder="请选择政治面貌">
<el-option v-for="dict in dict.type.politics_tatus" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.politics_tatus" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -511,11 +497,7 @@ ...@@ -511,11 +497,7 @@
<el-col :span="8"> <el-col :span="8">
<el-form-item label="独生子女:" prop="onlyChild"> <el-form-item label="独生子女:" prop="onlyChild">
<el-select v-model="studentForm.onlyChild" style="width: 100%" placeholder="请选择是否为独生子女"> <el-select v-model="studentForm.onlyChild" style="width: 100%" placeholder="请选择是否为独生子女">
<el-option <el-option v-for="dict in dict.type.only_child" :key="dict.value" :label="dict.label" :value="dict.value">
v-for="dict in dict.type.only_child"
:key="dict.value"
:label="dict.label"
:value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -525,7 +507,7 @@ ...@@ -525,7 +507,7 @@
<el-form-item label="性质:" prop="nature"> <el-form-item label="性质:" prop="nature">
<el-select v-model="studentForm.nature" placeholder="请选择学生性质" style="width: 100%;"> <el-select v-model="studentForm.nature" placeholder="请选择学生性质" style="width: 100%;">
<el-option v-for="dict in dict.type.student_nature" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.student_nature" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -548,19 +530,19 @@ ...@@ -548,19 +530,19 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="教师名称" prop="teacherName"> <el-form-item label="教师名称" prop="teacherName">
<el-input v-model="teacherForm.teacherName" placeholder=""/> <el-input v-model="teacherForm.teacherName" placeholder="" />
</el-form-item> </el-form-item>
<el-form-item label="性别" prop="sex"> <el-form-item label="性别" prop="sex">
<el-select v-model="teacherForm.sex" style="width: 100%" placeholder=""> <el-select v-model="teacherForm.sex" style="width: 100%" placeholder="">
<el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label"
:value="dict.value"></el-option> :value="dict.value"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="身份证号" prop="idCard"> <el-form-item label="身份证号" prop="idCard">
<el-input v-model.trim="teacherForm.idCard" placeholder=""/> <el-input v-model.trim="teacherForm.idCard" placeholder="" />
</el-form-item> </el-form-item>
<el-form-item label="手机号码" prop="teacherTel"> <el-form-item label="手机号码" prop="teacherTel">
<el-input v-model="teacherForm.teacherTel" placeholder=""/> <el-input v-model="teacherForm.teacherTel" placeholder="" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
...@@ -568,10 +550,10 @@ ...@@ -568,10 +550,10 @@
<template slot-scope="scope"> <template slot-scope="scope">
<!--<AvatarUploud :imgSrc="teacherForm.picUrl"></AvatarUploud>--> <!--<AvatarUploud :imgSrc="teacherForm.picUrl"></AvatarUploud>-->
<el-image :src="teacherForm.picUrl" :preview-src-list="[teacherForm.picUrl]" <el-image :src="teacherForm.picUrl" :preview-src-list="[teacherForm.picUrl]"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
<div slot="error"> <div slot="error">
<img :src="isEmptyTeacherUrl(teacherForm.avatar, teacherForm.sex)" <img :src="isEmptyTeacherUrl(teacherForm.avatar, teacherForm.sex)"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
</div> </div>
</el-image> </el-image>
</template> </template>
...@@ -592,7 +574,7 @@ ...@@ -592,7 +574,7 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="工作编号" prop="teacherCode"> <el-form-item label="工作编号" prop="teacherCode">
<el-input v-model="teacherForm.teacherCode" placeholder=""/> <el-input v-model="teacherForm.teacherCode" placeholder="" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
...@@ -611,16 +593,14 @@ ...@@ -611,16 +593,14 @@
<el-col :span="12"> <el-col :span="12">
<el-form-item label="岗位" prop="postId"> <el-form-item label="岗位" prop="postId">
<el-select multiple v-model="teacherForm.postId" placeholder="" style="width: 100%;"> <el-select multiple v-model="teacherForm.postId" placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.postId" :label="item.postName" <el-option v-for="item in []" :key="item.postId" :label="item.postName" :value="item.postId"></el-option>
:value="item.postId"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="角色" prop="roleId"> <el-form-item label="角色" prop="roleId">
<el-select v-model="teacherForm.roleId" multiple placeholder="" style="width: 100%;"> <el-select v-model="teacherForm.roleId" multiple placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.roleId" :label="item.roleName" <el-option v-for="item in []" :key="item.roleId" :label="item.roleName" :value="item.roleId"></el-option>
:value="item.roleId"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -629,15 +609,14 @@ ...@@ -629,15 +609,14 @@
<el-col :span="12"> <el-col :span="12">
<el-form-item label="生日" prop="birthday"> <el-form-item label="生日" prop="birthday">
<el-date-picker clearable v-model="teacherForm.birthday" type="date" style="width: 100%" <el-date-picker clearable v-model="teacherForm.birthday" type="date" style="width: 100%"
value-format="yyyy-MM-dd" placeholder=""> value-format="yyyy-MM-dd" placeholder="">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="民族" prop="nation"> <el-form-item label="民族" prop="nation">
<el-select v-model="teacherForm.nation" style="width: 100%" placeholder=""> <el-select v-model="teacherForm.nation" style="width: 100%" placeholder="">
<el-option v-for="item in Nations" :key="item.label" :label="item.label" <el-option v-for="item in Nations" :key="item.label" :label="item.label" :value="item.label"></el-option>
:value="item.label"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -647,13 +626,13 @@ ...@@ -647,13 +626,13 @@
<el-form-item label="学历" prop="education"> <el-form-item label="学历" prop="education">
<el-select v-model="teacherForm.education" style="width: 100%" placeholder="请选择学历"> <el-select v-model="teacherForm.education" style="width: 100%" placeholder="请选择学历">
<el-option v-for="dict in dict.type.education" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.education" :key="dict.value" :label="dict.label"
:value="dict.value"></el-option> :value="dict.value"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="家庭住址" prop="homeAddress"> <el-form-item label="家庭住址" prop="homeAddress">
<el-input v-model="teacherForm.homeAddress" placeholder=""/> <el-input v-model="teacherForm.homeAddress" placeholder="" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -674,13 +653,13 @@ import { ...@@ -674,13 +653,13 @@ import {
getStudentList, getStudentList,
getTeacherList getTeacherList
} from "@/api/smartSchool/classAdviser/classView"; } from "@/api/smartSchool/classAdviser/classView";
import {getFirstLeafNode, handleTreeData} from "@/utils/utilLibrary/getTreeClass"; import { getFirstLeafNode, handleTreeData } from "@/utils/utilLibrary/getTreeClass";
import {getYearList} from "@/utils/utilLibrary/getYearList"; import { getYearList } from "@/utils/utilLibrary/getYearList";
import {CustomCellStyle} from "@/enums/customStyle"; import { CustomCellStyle } from "@/enums/customStyle";
import {getStudent} from "@/api/smartSchool/studentManage"; import { getStudent } from "@/api/smartSchool/studentManage";
import {getInform} from "@/api/smartSchool/teacherManage/teacherInformation"; import { getInform } from "@/api/smartSchool/teacherManage/teacherInformation";
import {Gender, Nations} from "@/enums/common"; import { Gender, Nations } from "@/enums/common";
import {getNewYear} from "@/api/smartSchool/gradeWork/classView"; import { getNewYear } from "@/api/smartSchool/gradeWork/classView";
export default { export default {
name: "ClassAdviserClassView", name: "ClassAdviserClassView",
...@@ -788,7 +767,7 @@ export default { ...@@ -788,7 +767,7 @@ export default {
const id = row.id const id = row.id
this.$router.push({ this.$router.push({
path: '/classAdviser/classView/parentInfo', path: '/classAdviser/classView/parentInfo',
query: {studentId: row.id} query: { studentId: row.id }
}) })
}, },
//学生信息 //学生信息
...@@ -869,31 +848,30 @@ export default { ...@@ -869,31 +848,30 @@ export default {
/** 查询班级信息 */ /** 查询班级信息 */
getClassDetails() { getClassDetails() {
if (this.yearClass != 1) {
if (this.yearClass == 1) { return; // 年级不是1,直接返回,不执行请求数据的操作
this.queryParams.pageNum = 1; }
if (this.activeName === this.Types.STUDENT) { if (this.activeName === this.Types.STUDENT) {
this.studentLoading = true; this.studentLoading = true;
getStudentList(this.queryParams).then(response => { getStudentList(this.queryParams).then(response => {
this.studentLoading = false; this.studentLoading = false;
this.rightData.studentList = response.rows; this.rightData.studentList = response.rows;
this.studentTotal = response.total; this.studentTotal = response.total;
}).catch(error => { }).catch(error => {
this.studentLoading = false; this.studentLoading = false;
}) })
} else { } else {
this.teacherLoading = true; this.teacherLoading = true;
getTeacherList(this.queryParams).then(response => { getTeacherList(this.queryParams).then(response => {
this.teacherLoading = false; this.teacherLoading = false;
this.rightData.teacherList = response.rows; this.rightData.teacherList = response.rows;
this.teacherTotal = response.total; this.teacherTotal = response.total;
}).catch(error => { }).catch(error => {
this.teacherLoading = false; this.teacherLoading = false;
}) })
}
} }
}, },
/** 选择班级(打开对话框) */ /** 选择班级(打开对话框) */
selectClass() { selectClass() {
this.classOptions.open = true this.classOptions.open = true
...@@ -1019,4 +997,8 @@ export default { ...@@ -1019,4 +997,8 @@ export default {
.form-header { .form-header {
margin: 8px 0px 25px 0px; margin: 8px 0px 25px 0px;
} }
.scrollable-card {
overflow: auto;
}
</style> </style>
...@@ -2,17 +2,11 @@ ...@@ -2,17 +2,11 @@
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="名称" prop="xxfbName"> <el-form-item label="名称" prop="xxfbName">
<el-input <el-input v-model="queryParams.xxfbName" placeholder="请输入名称" clearable @keyup.enter.native="handleQuery" />
v-model="queryParams.xxfbName"
placeholder="请输入名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item> </el-form-item>
<el-form-item label="状态" prop="xxfbZt"> <el-form-item label="状态" prop="xxfbZt">
<el-select v-model="queryParams.xxfbZt" placeholder="请选择状态" @keyup.enter.native="handleQuery"> <el-select v-model="queryParams.xxfbZt" placeholder="请选择状态" @keyup.enter.native="handleQuery">
<el-option v-for="dict in dict.type.info_push_state" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.info_push_state" :key="dict.value" :label="dict.label" :value="dict.value">
:value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -31,46 +25,26 @@ ...@@ -31,46 +25,26 @@
</el-row> </el-row>
<el-table v-loading="loading" :data="xxfbList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="xxfbList" @selection-change="handleSelectionChange">
<el-table-column label="序号" align="center" type="index"/> <el-table-column label="序号" align="center" type="index" />
<el-table-column label="名称" min-width="250" align="center" prop="xxfbName"/> <el-table-column label="名称" min-width="250" align="center" prop="xxfbName" />
<el-table-column label="状态" align="center" prop="xxfbZt"> <el-table-column label="状态" align="center" prop="xxfbZt">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.info_push_state" :value="scope.row.xxfbZt"/> <dict-tag :options="dict.type.info_push_state" :value="scope.row.xxfbZt" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="查询次数" align="center" prop="num"/> <el-table-column label="查询次数" align="center" prop="num" />
<el-table-column label="创建时间" align="center" min-width="150" prop="createTime"/> <el-table-column label="创建时间" align="center" min-width="150" prop="createTime" />
<el-table-column label="操作" align="center" min-width="250" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" min-width="250" class-name="small-padding fixed-width">
<template slot-scope="scope"> <template slot-scope="scope">
<template v-if="scope.row.xxfbZt == '1'"> <template v-if="scope.row.xxfbZt == '1'">
<el-button <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
>修改
</el-button> </el-button>
<el-button <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)">删除
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
>删除
</el-button> </el-button>
<el-button <el-button size="mini" type="text" icon="el-icon-search" @click="handleViewDetail(scope.row)">数据
size="mini"
type="text"
icon="el-icon-search"
@click="handleViewDetail(scope.row)"
>数据
</el-button> </el-button>
<el-button <el-button size="mini" type="text" icon="el-icon-s-promotion" @click="handlePublish(scope.row)">发布
size="mini"
type="text"
icon="el-icon-s-promotion"
@click="handlePublish(scope.row)"
>发布
</el-button> </el-button>
...@@ -93,29 +67,14 @@ ...@@ -93,29 +67,14 @@
<!-- </el-dropdown>--> <!-- </el-dropdown>-->
</template> </template>
<template v-if="scope.row.xxfbZt == '2'"> <template v-if="scope.row.xxfbZt == '2'">
<el-button <el-button size="mini" type="text" icon="el-icon-back" @click="handleRecall(scope.row)"
size="mini" v-hasPermi="['system:xxfb:export']">撤回
type="text"
icon="el-icon-back"
@click="handleRecall(scope.row)"
v-hasPermi="['system:xxfb:export']"
>撤回
</el-button> </el-button>
<el-button <el-button size="mini" type="text" icon="el-icon-view" @click="handleViewData(scope.row)"
size="mini" v-hasPermi="['system:xxfb:view']">数据查看
type="text"
icon="el-icon-view"
@click="handleViewData(scope.row)"
v-hasPermi="['system:xxfb:view']"
>数据查看
</el-button> </el-button>
<el-button <el-button size="mini" type="text" icon="el-icon-download" @click="handleExport(scope.row)"
size="mini" v-hasPermi="['system:xxfb:export']">导出
type="text"
icon="el-icon-download"
@click="handleExport(scope.row)"
v-hasPermi="['system:xxfb:export']"
>导出
</el-button> </el-button>
</template> </template>
...@@ -152,34 +111,27 @@ ...@@ -152,34 +111,27 @@
<el-divider></el-divider> <el-divider></el-divider>
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="查询名称" prop="xxfbName"> <el-form-item label="查询名称" prop="xxfbName">
<el-input v-model="form.xxfbName" placeholder="请输入名称"/> <el-input v-model="form.xxfbName" placeholder="请输入名称" />
</el-form-item> </el-form-item>
<el-form-item label="级部" prop="gradeId"> <el-form-item label="级部" prop="gradeId">
<treeselect <treeselect v-model="form.gradeId" :options="gradeTree" :show-count="true" @select="deptIdAndName"
v-model="form.gradeId" :disable-branch-nodes="true" :defaultExpandLevel="2" placeholder="请选择级部" />
:options="gradeTree"
:show-count="true"
@select="deptIdAndName"
:disable-branch-nodes="true"
:defaultExpandLevel="2"
placeholder="请选择级部"
/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<!-- <span style="color: red">*</span>--> <!-- <span style="color: red">*</span>-->
<b>第二步: 上传查询内容</b> <b @click="changeShow" style="color: #ee6877"> <b>第二步: 上传查询内容</b> <b @click="changeShow" style="color: #ee6877">
点击查看示例 )</b> 点击查看示例 )</b>
<el-divider></el-divider> <el-divider></el-divider>
<div v-show="isShow"> <div v-show="isShow">
<div <div
style="font-size: 10px; color: #ed5565; font-weight: 400; background: #d8ecf6; border: 1px solid #03b3f5; padding: 10px"> style="font-size: 10px; color: #ed5565; font-weight: 400; background: #d8ecf6; border: 1px solid #03b3f5; padding: 10px">
注:上传excel文件,第一行为数据表头,不允许合并单元格,列名不要重复,第一列为身份证号,第二列为姓名。后续不限制 注:上传excel文件,第一行为数据表头,不允许合并单元格,列名不要重复,第一列为号,第二列为姓名。后续不限制
</div> </div>
<br/> <br />
<el-table :data="tableData" :border="true" style="width: 100%"> <el-table :data="tableData" :border="true" style="width: 100%">
<!-- <el-table-column type="index" label="序号" width="50">--> <!-- <el-table-column type="index" label="序号" width="50">-->
<!-- </el-table-column>--> <!-- </el-table-column>-->
<el-table-column prop="idCard" min-width="120px" label="身份证号"> <el-table-column prop="schoolNo" min-width="120px" label="学号">
</el-table-column> </el-table-column>
<el-table-column prop="name" label="姓名"> <el-table-column prop="name" label="姓名">
</el-table-column> </el-table-column>
...@@ -198,20 +150,11 @@ ...@@ -198,20 +150,11 @@
<el-table-column label="I"> <el-table-column label="I">
</el-table-column> </el-table-column>
</el-table> </el-table>
<br/> <br/> <br /> <br />
</div> </div>
<el-upload <el-upload style="width: 950px;display: block; margin: 0 auto;" ref="upload" :limit='1' class="upload-demo"
style="width: 950px;display: block; margin: 0 auto;" action="uploadUrl" accept=".xlsx, .xls" :headers="upload.headers" show-file-list
ref="upload" :before-upload="handleBeforeUpload" :http-request="uploadImage">
:limit='1'
class="upload-demo"
action="uploadUrl"
accept=".xlsx, .xls"
:headers="upload.headers"
show-file-list
:before-upload="handleBeforeUpload"
:http-request="uploadImage"
>
<el-button style="width: 950px; display: block; margin: 0 auto; background: #54bbbc; color: white"> <el-button style="width: 950px; display: block; margin: 0 auto; background: #54bbbc; color: white">
点击上传文件 点击上传文件
</el-button> </el-button>
...@@ -227,7 +170,7 @@ ...@@ -227,7 +170,7 @@
<el-dialog :title="title" :visible.sync="edtion" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="edtion" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="60px"> <el-form ref="form" :model="form" :rules="rules" label-width="60px">
<el-form-item label="名称" prop="xxfbName"> <el-form-item label="名称" prop="xxfbName">
<el-input v-model="form.xxfbName" placeholder="请输入名称"/> <el-input v-model="form.xxfbName" placeholder="请输入名称" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
...@@ -256,7 +199,7 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css"; ...@@ -256,7 +199,7 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css";
export default { export default {
name: "Xxfb", name: "Xxfb",
components: {Treeselect}, components: { Treeselect },
dicts: ['info_push_state'], dicts: ['info_push_state'],
data() { data() {
return { return {
...@@ -276,10 +219,10 @@ export default { ...@@ -276,10 +219,10 @@ export default {
}, },
tableData: [{ tableData: [{
idCard: 'xxxxxxxxxxxxx', schoolNo: 'xxxxxxxxxxxxx',
name: 'xxx', name: 'xxx',
}, { }, {
idCard: 'xxxxxxxxxxxxx', schoolNo: 'xxxxxxxxxxxxx',
name: 'xxx', name: 'xxx',
}], }],
uploadUrl: process.env.VUE_APP_BASE_API + "/common/upload", // 上传excel uploadUrl: process.env.VUE_APP_BASE_API + "/common/upload", // 上传excel
...@@ -312,10 +255,10 @@ export default { ...@@ -312,10 +255,10 @@ export default {
// 表单校验 // 表单校验
rules: { rules: {
xxfbName: [ xxfbName: [
{required: true, message: "查询名称不能为空", trigger: "blur"} { required: true, message: "查询名称不能为空", trigger: "blur" }
], ],
gradeId: [ gradeId: [
{required: true, message: "级部不能为空", trigger: "blur"} { required: true, message: "级部不能为空", trigger: "blur" }
], ],
}, },
// 级部树 // 级部树
...@@ -443,9 +386,9 @@ export default { ...@@ -443,9 +386,9 @@ export default {
// this.$refs.upload.clearFiles() // this.$refs.upload.clearFiles()
this.getList(); this.getList();
}).catch(() => { }).catch(() => {
// 关闭遮罩层 // 关闭遮罩层
this.$modal.closeLoading(); this.$modal.closeLoading();
} }
); );
} else { } else {
if (this.uploadFileData) { if (this.uploadFileData) {
...@@ -459,9 +402,9 @@ export default { ...@@ -459,9 +402,9 @@ export default {
// this.$refs.upload.clearFiles() // this.$refs.upload.clearFiles()
this.getList(); this.getList();
}).catch(() => { }).catch(() => {
// 关闭遮罩层 // 关闭遮罩层
this.$modal.closeLoading(); this.$modal.closeLoading();
} }
); );
} }
} }
......
...@@ -183,7 +183,7 @@ export default { ...@@ -183,7 +183,7 @@ export default {
telephone: [{required: true, message: "联系方式不能为空", trigger: "blur"}], telephone: [{required: true, message: "联系方式不能为空", trigger: "blur"}],
relationship: [{required: true, message: "与学生关系不能为空", trigger: "blur"}], relationship: [{required: true, message: "与学生关系不能为空", trigger: "blur"}],
contactAddress: [{required: true, message: "联系地址不能为空", trigger: "blur"}], contactAddress: [{required: true, message: "联系地址不能为空", trigger: "blur"}],
idCard: [{required: true, message: "身份证号不能为空", trigger: "blur"}], // idCard: [{required: true, message: "身份证号不能为空", trigger: "blur"}],
} }
}; };
}, },
......
...@@ -39,12 +39,14 @@ ...@@ -39,12 +39,14 @@
</el-table-column> </el-table-column>
<el-table-column label="证书照片" align="center"> <el-table-column label="证书照片" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div> <el-carousel :interval="4000" height="100px">
<el-image v-for="(accessory, index) in scope.row.schoolAccessoryList" :key="index" <el-carousel-item v-for="(item, index) in scope.row.schoolAccessoryList" :key="index">
style="width: 100px; height: 100px" :src="accessory.accessoryUrl" <el-image style="width: 100px; height: 100px" :src="item.accessoryUrl"
:preview-src-list="[accessory.accessoryUrl]"></el-image> :preview-src-list="[item.accessoryUrl]"></el-image>
</div> </el-carousel-item>
</el-carousel>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="备注1" align="center" prop="remark1" /> <el-table-column label="备注1" align="center" prop="remark1" />
...@@ -118,13 +120,19 @@ ...@@ -118,13 +120,19 @@
<el-row> <el-row>
<el-col :span="10"> <el-col :span="10">
<el-form-item prop="schoolAccessoryList" label="证书照片"> <el-form-item prop="schoolAccessoryList" label="证书照片">
<el-upload v-loading="uploadLoading" class="avatar-uploader" action="#" accept="image/*" <el-upload v-loading="uploadLoading" class="avatar-uploader" :action="uploadFileUrl" accept="image/*"
:show-file-list="false" :on-success="handleAvatarSuccess" :before-upload="beforeAvatarUpload" :show-file-list="false" :on-success="handleAvatarSuccess" :before-upload="beforeAvatarUpload"
:http-request="uploadImage"> :on-remove="handleRemove">
<img v-for="item in form.schoolAccessoryList" :key="item.accessoryUrl" :src="item.accessoryUrl" <div v-if="form.schoolAccessoryList.length === 0">
class="avatar" /> <i class="el-icon-plus avatar-uploader-icon"></i>
<i v-if="form.schoolAccessoryList.length === 0" class="el-icon-plus avatar-uploader-icon"></i> </div>
<div v-else>
<div v-for="(item, index) in form.schoolAccessoryList" :key="index">
<img :src="item.accessoryUrl" class="avatar" />
</div>
</div>
</el-upload> </el-upload>
<i class="el-icon-delete" @click="handleRemove(index)"></i> <!-- 添加删除按钮 -->
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -181,6 +189,7 @@ export default { ...@@ -181,6 +189,7 @@ export default {
components: { picAvatar }, components: { picAvatar },
data() { data() {
return { return {
uploadFileUrl: process.env.VUE_APP_BASE_API + "/common/upload", // 上传的图片服务器地址
//缩略图 //缩略图
srcList: [], srcList: [],
// 图片路径 // 图片路径
...@@ -222,7 +231,7 @@ export default { ...@@ -222,7 +231,7 @@ export default {
schoolYear: [ schoolYear: [
{ required: true, message: "学年不能为空", trigger: "change" } { required: true, message: "学年不能为空", trigger: "change" }
], ],
teacherName: [ teacherId: [
{ required: true, message: "教师名称不能为空", trigger: "change" } { required: true, message: "教师名称不能为空", trigger: "change" }
], ],
entrySubject: [ entrySubject: [
...@@ -271,15 +280,15 @@ export default { ...@@ -271,15 +280,15 @@ export default {
console.log('response', response); console.log('response', response);
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
this.competitionData.forEach(item => { // this.competitionData.forEach(item => {
if (item.schoolAccessoryList) { // if (item.schoolAccessoryList) {
item.previewUrls = [item.schoolAccessoryList.map(accessory => accessory.accessoryUrl)]; // item.previewUrls = [item.schoolAccessoryList.map(accessory => accessory.accessoryUrl)];
item.pictureUrl = item.schoolAccessoryList.map(accessory => accessory.accessoryUrl); // item.pictureUrl = item.schoolAccessoryList.map(accessory => accessory.accessoryUrl);
} else { // } else {
item.previewUrls = []; // item.previewUrls = [];
item.pictureUrl = []; // item.pictureUrl = [];
} // }
}); // });
}); });
...@@ -290,19 +299,21 @@ export default { ...@@ -290,19 +299,21 @@ export default {
this.pic = val this.pic = val
}, },
// 移除图片 // 移除图片
handleRemove() { handleRemove(index) {
this.imageUrl = undefined this.form.schoolAccessoryList.splice(index, 1);
}, },
// 上传成功回调 // 上传成功回调
handleAvatarSuccess(response, file) { handleAvatarSuccess(response, file) {
console.log('response', response);
console.log('file', file);
// 处理上传成功的逻辑 // 处理上传成功的逻辑
const accessoryUrl = response.data.url; // 假设响应中包含了图片的访问URL const accessoryUrl = this.pev + response.fileName; // 假设响应中包含了图片的访问URL
const accessoryName = file.name; // 获取上传文件的名称 const accessoryName = response.originalFilename; // 获取上传文件的名称
this.form.schoolAccessoryList.push({ this.form.schoolAccessoryList.push({
accessoryUrl: accessoryUrl, accessoryUrl: accessoryUrl,
accessoryName: accessoryName accessoryName: accessoryName
}); });
console.log('this.form.schoolAccessoryList', this.form.schoolAccessoryList);
}, },
// 上传前格式和图片大小限制 // 上传前格式和图片大小限制
...@@ -318,27 +329,7 @@ export default { ...@@ -318,27 +329,7 @@ export default {
return type && isLt2M return type && isLt2M
}, },
// 上传图片
uploadImage(file) {
const fileData = file.file
const formData = new FormData()
formData.append('file', fileData)
this.uploadLoading = true
commonUpload(formData)
.then(response => {
this.uploadLoading = false
this.$modal.msgSuccess('上传成功')
this.imageUrl = process.env.VUE_APP_BASE_API + response.url
// 添加以下代码将文件信息添加到 uploadedFiles 数组中
this.uploadedFiles.push({
accessoryUrl: process.env.VUE_APP_BASE_API + response.url,
accessoryName: fileData.name
})
})
.catch(error => {
this.uploadLoading = false
})
},
//重置 //重置
resetQuery() { resetQuery() {
...@@ -430,16 +421,6 @@ export default { ...@@ -430,16 +421,6 @@ export default {
this.$refs['form'].validate(valid => { this.$refs['form'].validate(valid => {
if (valid) { if (valid) {
if (this.form.id != "") { if (this.form.id != "") {
// 清空原有图片
this.form.schoolAccessoryList.splice(0);
for (let i = 0; i < this.uploadedFiles.length; i++) {
const file = this.uploadedFiles[i];
this.form.schoolAccessoryList.push({
accessoryUrl: file.accessoryUrl,
accessoryName: file.accessoryName
});
}
updateCompetition(this.form).then(({ code }) => { updateCompetition(this.form).then(({ code }) => {
if (code == 200) { if (code == 200) {
this.$modal.msgSuccess('修改成功') this.$modal.msgSuccess('修改成功')
...@@ -450,17 +431,6 @@ export default { ...@@ -450,17 +431,6 @@ export default {
this.$modal.msgError("修改失败"); this.$modal.msgError("修改失败");
}); });
} else { } else {
// 清空原有图片
this.form.schoolAccessoryList = [];
for (let i = 0; i < this.uploadedFiles.length; i++) {
const file = this.uploadedFiles[i];
this.form.schoolAccessoryList.push({
accessoryUrl: file.accessoryUrl,
accessoryName: file.accessoryName
});
}
addCompetition(this.form).then(response => { addCompetition(this.form).then(response => {
console.log(this.form, 'this.form'); console.log(this.form, 'this.form');
this.$modal.msgSuccess('新增成功') this.$modal.msgSuccess('新增成功')
......
...@@ -153,7 +153,6 @@ ...@@ -153,7 +153,6 @@
:on-success="handleAvatarSuccess" :on-success="handleAvatarSuccess"
:before-upload="beforeAvatarUpload" :before-upload="beforeAvatarUpload"
> >
<!-- <img v-for="(item,index) in form.file" :key="index" v-if="form.file" :src="item" class="avatar" />-->
<div v-if="form.file"> <div v-if="form.file">
<img <img
v-for="(item, index) in form.file" v-for="(item, index) in form.file"
......
...@@ -21,6 +21,11 @@ ...@@ -21,6 +21,11 @@
<el-table-column label="型号" align="center" prop="model" /> <el-table-column label="型号" align="center" prop="model" />
<el-table-column label="借用日期" align="center" prop="borrowTime" /> <el-table-column label="借用日期" align="center" prop="borrowTime" />
<el-table-column label="借用人" align="center" prop="borrowBy" /> <el-table-column label="借用人" align="center" prop="borrowBy" />
<el-table-column label="归还状态" align="center" prop="returnState">
<template slot-scope="scope">
<dict-tag :options="dict.type.return_state" :value="scope.row.returnState"></dict-tag>
</template>
</el-table-column>
<el-table-column label="用途" align="center" prop="purpose" /> <el-table-column label="用途" align="center" prop="purpose" />
<el-table-column label="借用期限" align="center" prop="deadline" /> <el-table-column label="借用期限" align="center" prop="deadline" />
<el-table-column label="操作" align="center"> <el-table-column label="操作" align="center">
...@@ -80,6 +85,14 @@ ...@@ -80,6 +85,14 @@
<el-input v-model="postForm.deadline" /> <el-input v-model="postForm.deadline" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12">
<el-form-item label="归还状态" prop="returnState">
<el-select v-model="postForm.returnState" clearable style="width: 100%;">
<el-option v-for="dict in dict.type.return_state" :key="dict.value" :label="dict.label"
:value="dict.value" />
</el-select>
</el-form-item>
</el-col>
</el-row> </el-row>
</el-form> </el-form>
...@@ -100,7 +113,7 @@ import { ...@@ -100,7 +113,7 @@ import {
listTeacherjyxq listTeacherjyxq
} from "@/api/smartSchool/personWork/propertyManagement"; } from "@/api/smartSchool/personWork/propertyManagement";
export default { export default {
dicts: ['return_state'],
data() { data() {
return { return {
queryParams: { queryParams: {
......
...@@ -86,8 +86,8 @@ ...@@ -86,8 +86,8 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="报修时间:" prop="reportrepairtime"> <el-form-item label="报修时间:" prop="reportRepairTime">
<el-date-picker v-model="postForm.reportrepairtime" type="date" style="width: 100%;" <el-date-picker v-model="postForm.reportRepairTime" type="date" style="width: 100%;"
value-format="yyyy-MM-dd" clearable></el-date-picker> value-format="yyyy-MM-dd" clearable></el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
......
...@@ -656,7 +656,7 @@ export default { ...@@ -656,7 +656,7 @@ export default {
console.log(encodes, 'encodes'); console.log(encodes, 'encodes');
const printListParam = encodeURIComponent(JSON.stringify(this.printList)); const printListParam = encodeURIComponent(JSON.stringify(this.printList));
dd.biz.util.openLink({ dd.biz.util.openLink({
url: `${baseUrl}?ids=${ids}&encodes=${encodes}&printList=${printListParam}`, url: `${baseUrl}?ids=${ids}`,
onSuccess: () => { onSuccess: () => {
console.log('跳转成功,准备打印'); console.log('跳转成功,准备打印');
// 打印条码 // 打印条码
......
...@@ -50,7 +50,9 @@ import { getToken } from "@/utils/auth"; ...@@ -50,7 +50,9 @@ import { getToken } from "@/utils/auth";
import "@riophae/vue-treeselect/dist/vue-treeselect.css"; import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import QRCode from "qrcodejs2"; // 生成二维码插件 import QRCode from "qrcodejs2"; // 生成二维码插件
import printJS from "print-js"; // 打印插件 import printJS from "print-js"; // 打印插件
import {
equipmentPrint
} from "../../../../api/smartSchool/schoolProperty/equipmenTledger";
export default { export default {
name: "index", name: "index",
...@@ -81,22 +83,28 @@ export default { ...@@ -81,22 +83,28 @@ export default {
}; };
}, },
created() { created() {
const ids = this.$route.query.ids; this.getList();
const encodes = this.$route.query.encodes;
const printList = JSON.parse(decodeURIComponent(this.$route.query.printList));
this.printBarcodes(ids, encodes, printList);
}, },
methods: { methods: {
getList() {
this.loading = true
const ids = this.$route.query.ids;
console.log(ids, 'ids');
equipmentPrint(ids).then(res => {
this.printList = res;
console.log(this.printList, 'this.printList');
this.chooseList = res;
console.log(this.chooseList, 'this.chooseList');
this.loading = false
this.printBarcodes();
})
},
//生成批量打印条码 //生成批量打印条码
printBarcodes(ids, encodes, printList) { printBarcodes() {
this.printDialog = true; this.printDialog = true;
console.log(ids, encodes);
this.printList = [...printList];
this.chooseList = [...this.printList];
console.log(this.chooseList, '122');
this.$nextTick(() => { this.$nextTick(() => {
this.printList.map((item, index) => { this.printList.map((item, index) => {
const domPrint = document.getElementById(`print${index}`).lastElementChild; const domPrint = document.getElementById(`print${index}`).lastElementChild;
......
...@@ -27,14 +27,14 @@ ...@@ -27,14 +27,14 @@
<el-table-column label="借用人" align="center" prop="borrowBy" /> <el-table-column label="借用人" align="center" prop="borrowBy" />
<el-table-column label="用途" align="center" prop="purpose" /> <el-table-column label="用途" align="center" prop="purpose" />
<el-table-column label="借用期限(天)" align="center" prop="deadline" width="140" /> <el-table-column label="借用期限(天)" align="center" prop="deadline" width="140" />
<el-table-column label="归还日期" align="center" prop="returnTime" width="160" /> <el-table-column label="预计使用期限" align="center" prop="yjuseTime" width="160" />
<el-table-column label="归还时设备情况" align="center" prop="returnEquipmentCondition" width="160"> <el-table-column label="归还时设备情况" align="center" prop="returnEquipmentCondition" width="160">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<dict-tag :options="dict.type.equipment_state" :value="row.returnEquipmentCondition" /> <dict-tag :options="dict.type.equipment_state" :value="row.returnEquipmentCondition" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="接收人" align="center" prop="receivedBy" /> <el-table-column label="接收人" align="center" prop="receivedBy" />
<el-table-column label="预计使用时间" align="center" prop="yjuseTime" width="160" /> <el-table-column label="归还日期" align="center" prop="returnTime" width="160" />
<el-table-column label="实际使用时间" align="center" prop="sjuseTime" width="160" /> <el-table-column label="实际使用时间" align="center" prop="sjuseTime" width="160" />
<el-table-column label="备注" align="center" prop="remark" /> <el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="操作" align="center" prop="orgname" width="150" fixed="right"> <el-table-column label="操作" align="center" prop="orgname" width="150" fixed="right">
...@@ -137,17 +137,19 @@ ...@@ -137,17 +137,19 @@
</el-row> </el-row>
<el-row :gutter="30"> <el-row :gutter="30">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="预计使用时间" prop="yjuseTime"> <el-form-item label="预计使用期限" prop="yjuseTime">
<el-date-picker v-model="lendReturnForm.yjuseTime" type="datetime" clearable class="selectWidth" <el-date-picker v-model="lendReturnForm.yjuseTime" type="datetime" clearable class="selectWidth"
placeholder="请选择预计使用时间" value-format="yyyy-MM-dd HH:mm:ss" :disabled="nowType == 2 ? true : false"> placeholder="请选择" value-format="yyyy-MM-dd HH:mm:ss" :disabled="nowType == 2 ? true : false">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="实际使用时间" prop="sjuseTime"> <el-form-item label="实际使用时间" prop="sjuseTime">
<el-date-picker v-model="lendReturnForm.sjuseTime" type="datetime" clearable class="selectWidth" <!-- <el-date-picker v-model="lendReturnForm.sjuseTime" type="datetime" clearable class="selectWidth"
placeholder="请选择实际使用时间" value-format="yyyy-MM-dd HH:mm:ss" :disabled="nowType == 2 ? true : false"> placeholder="请选择实际使用时间" value-format="yyyy-MM-dd HH:mm:ss" :disabled="nowType == 2 ? true : false">
</el-date-picker> </el-date-picker> -->
<el-input v-model="lendReturnForm.sjuseTime" placeholder="请输入" :disabled="nowType == 2 ? true : false"
type="number"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
......
...@@ -2,21 +2,20 @@ ...@@ -2,21 +2,20 @@
<div class="app-container fixed-scroll-error"> <div class="app-container fixed-scroll-error">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="4" :xs="24"> <el-col :span="4" :xs="24">
<el-card shadow="never" :style="{ height: clientHeight }"> <el-card shadow="never" class="scrollable-card" :style="{ height: clientHeight }">
<template slot="header"> <template slot="header">
<div style="display:flex; justify-content: space-between"> <div style="display:flex; justify-content: space-between">
<div style="display:flex; align-items: center"> <div style="display:flex; align-items: center">
<span>班级列表</span> <span>班级列表</span>
</div> </div>
<el-select v-model="queryParams.schoolYear" style="width: 100px;" size="small" @change="handleYearChange"> <el-select v-model="queryParams.schoolYear" style="width: 100px;" size="small" @change="handleYearChange">
<el-option v-for="item in yearList" :key="item.value" :value="item.value" <el-option v-for="item in yearList" :key="item.value" :value="item.value" :label="item.label"></el-option>
:label="item.label"></el-option>
</el-select> </el-select>
</div> </div>
</template> </template>
<div class="head-container"> <div class="head-container">
<el-tree :data="leftOptions.treeOptions" @node-click="handleNodeClick" :props="leftOptions.defaultProps" <el-tree :data="leftOptions.treeOptions" @node-click="handleNodeClick" :props="leftOptions.defaultProps"
:expand-on-click-node="false" ref="tree" node-key="id" default-expand-all highlight-current/> :expand-on-click-node="false" ref="tree" node-key="id" default-expand-all highlight-current />
<!-- :filter-node-method="filterNode"--> <!-- :filter-node-method="filterNode"-->
</div> </div>
</el-card> </el-card>
...@@ -30,86 +29,86 @@ ...@@ -30,86 +29,86 @@
<div class="classes-info-table el-table el-table--enable-row-hover el-table--medium"> <div class="classes-info-table el-table el-table--enable-row-hover el-table--medium">
<table cellspacing="0" style="width: 100%"> <table cellspacing="0" style="width: 100%">
<tbody> <tbody>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班级 :</div> <div class="cell">班级 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.className }}</div> <div class="cell">{{ classInfo.className }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">类别 :</div> <div class="cell">类别 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ resolveGradeType(classInfo.classType) }}</div> <div class="cell">{{ resolveGradeType(classInfo.classType) }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">年级 :</div> <div class="cell">年级 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.gradeName }}</div> <div class="cell">{{ classInfo.gradeName }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班主任 :</div> <div class="cell">班主任 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.teacherName }}</div> <div class="cell">{{ classInfo.teacherName }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">别名 :</div> <div class="cell">别名 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.classAlias }}</div> <div class="cell">{{ classInfo.classAlias }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">联系电话 :</div> <div class="cell">联系电话 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.teacherTel }}</div> <div class="cell">{{ classInfo.teacherTel }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">开始学年 :</div> <div class="cell">开始学年 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.schoolYear }}</div> <div class="cell">{{ classInfo.schoolYear }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班级口号 :</div> <div class="cell">班级口号 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.classSlogan }}</div> <div class="cell">{{ classInfo.classSlogan }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
<tr> <tr>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">所在教学楼 :</div> <div class="cell">所在教学楼 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.houseName }}</div> <div class="cell">{{ classInfo.houseName }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">班主任寄语 :</div> <div class="cell">班主任寄语 :</div>
</td> </td>
<td class="el-table__cell"> <td class="el-table__cell">
<div class="cell">{{ classInfo.teacherWord }}</div> <div class="cell">{{ classInfo.teacherWord }}</div>
<div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div> <div class="cell" v-if="JSON.stringify(classInfo) == '{}'">暂无数据</div>
</td> </td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
...@@ -137,41 +136,39 @@ ...@@ -137,41 +136,39 @@
</el-radio-group> </el-radio-group>
<el-table v-if="activeName === Types.STUDENT" stripe v-loading="studentLoading" width="100%" <el-table v-if="activeName === Types.STUDENT" stripe v-loading="studentLoading" width="100%"
:cell-style="customCellStyle" :data="rightData.studentList" :key="Types.STUDENT"> :cell-style="customCellStyle" :data="rightData.studentList" :key="Types.STUDENT">
<el-table-column type="selection" width="55" align="center"/> <el-table-column type="selection" width="55" align="center" />
<el-table-column fixed="left" key="avatar" width="60" align="center" prop="avatar" label="头像"> <el-table-column fixed="left" key="avatar" width="60" align="center" prop="avatar" label="头像">
<template slot-scope="scope"> <template slot-scope="scope">
<ListImage :image-url="isEmptyAvatar(scope.row.avatar, scope.row.sex)"></ListImage> <ListImage :image-url="isEmptyAvatar(scope.row.avatar, scope.row.sex)"></ListImage>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName" <el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName" label="姓名" />
label="姓名"/>
<!-- <el-table-column key="score" min-width="80" align="center" prop="score" label="积分"/>--> <!-- <el-table-column key="score" min-width="80" align="center" prop="score" label="积分"/>-->
<el-table-column key="grade" min-width="100px" align="center" prop="classAlias" label="班级"/> <el-table-column key="grade" min-width="100px" align="center" prop="classAlias" label="班级" />
<el-table-column key="sex" min-width="50px" align="center" prop="sex" label="性别"> <el-table-column key="sex" min-width="50px" align="center" prop="sex" label="性别">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"></dict-tag> <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="nation" width="100" align="center" prop="nation" label="民族"/> <el-table-column key="nation" width="100" align="center" prop="nation" label="民族" />
<el-table-column key="nativePlace" min-width="100" header-align="center" align="center" prop="nativePlace" <el-table-column key="nativePlace" min-width="100" header-align="center" align="center" prop="nativePlace"
label="籍贯" show-overflow-tooltip></el-table-column> label="籍贯" show-overflow-tooltip></el-table-column>
<el-table-column key="idCard" width="180" align="center" prop="idCard" label="身份证号"/> <el-table-column key="idCard" width="180" align="center" prop="idCard" label="身份证号" />
<el-table-column key="stuTelephone" width="130" align="center" prop="stuTelephone" label="联系电话"/> <el-table-column key="stuTelephone" width="130" align="center" prop="stuTelephone" label="联系电话" />
<el-table-column key="birthAddress" width="150" align="center" prop="birthAddress" label="出生地"/> <el-table-column key="birthAddress" width="150" align="center" prop="birthAddress" label="出生地" />
<el-table-column key="postalCode" width="150" align="center" prop="postalCode" label="邮政编码"/> <el-table-column key="postalCode" width="150" align="center" prop="postalCode" label="邮政编码" />
<el-table-column key="enrollmentYear" width="100" align="center" prop="enrollmentYear" label="级/届"/> <el-table-column key="enrollmentYear" width="100" align="center" prop="enrollmentYear" label="级/届" />
<el-table-column key="enrollmentTime" min-width="100" header-align="center" align="center" <el-table-column key="enrollmentTime" min-width="100" header-align="center" align="center"
prop="enrollmentTime" label="入学时间" show-overflow-tooltip></el-table-column> prop="enrollmentTime" label="入学时间" show-overflow-tooltip></el-table-column>
<el-table-column key="platform" width="180" align="center" prop="platform" label="平台"/> <el-table-column key="platform" width="180" align="center" prop="platform" label="平台" />
<el-table-column key="studentType" width="130" align="center" prop="studentType" label="学生类型"> <el-table-column key="studentType" width="130" align="center" prop="studentType" label="学生类型">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag> <dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber" <el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber" label="省学籍辅号" />
label="省学籍辅号"/> <el-table-column key="nationalNumber" width="150" align="center" prop="nationalNumber" label="全国学籍号" />
<el-table-column key="nationalNumber" width="150" align="center" prop="nationalNumber" label="全国学籍号"/>
<el-table-column key="studentStatus" width="80" align="center" prop="studentStatus" label="学生状态"> <el-table-column key="studentStatus" width="80" align="center" prop="studentStatus" label="学生状态">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.child_state" :value="scope.row.studentStatus"></dict-tag> <dict-tag :options="dict.type.child_state" :value="scope.row.studentStatus"></dict-tag>
...@@ -182,43 +179,41 @@ ...@@ -182,43 +179,41 @@
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag> <dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="schoolNo" width="100" align="center" prop="schoolNo" label="注册序号"/> <el-table-column key="schoolNo" width="100" align="center" prop="schoolNo" label="注册序号" />
<el-table-column key="registeredAddress" min-width="100" header-align="center" align="center" <el-table-column key="registeredAddress" min-width="100" header-align="center" align="center"
prop="registeredAddress" label="户口所在地" show-overflow-tooltip></el-table-column> prop="registeredAddress" label="户口所在地" show-overflow-tooltip></el-table-column>
<el-table-column key="registeredType" width="180" align="center" prop="registeredType" label="户口性质"> <el-table-column key="registeredType" width="180" align="center" prop="registeredType" label="户口性质">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.regist_type" :value="scope.row.registeredType"/> <dict-tag :options="dict.type.regist_type" :value="scope.row.registeredType" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="juniorSchool" width="130" align="center" prop="juniorSchool" label="初中学校"/> <el-table-column key="juniorSchool" width="130" align="center" prop="juniorSchool" label="初中学校" />
<el-table-column key="region" width="150" align="center" prop="region" label="国家地区"/> <el-table-column key="region" width="150" align="center" prop="region" label="国家地区" />
<el-table-column key="foreignLanguages" width="150" align="center" prop="foreignLanguages" <el-table-column key="foreignLanguages" width="150" align="center" prop="foreignLanguages" label="外语语种" />
label="外语语种"/>
<el-table-column key="appearance" width="150" align="center" prop="appearance" label="政治面貌"> <el-table-column key="appearance" width="150" align="center" prop="appearance" label="政治面貌">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.politics_tatus" :value="scope.row.appearance"></dict-tag> <dict-tag :options="dict.type.politics_tatus" :value="scope.row.appearance"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="birthday" width="120" sortable align="center" prop="birthday" <el-table-column key="birthday" width="120" sortable align="center" prop="birthday"
label="出生日期"></el-table-column> label="出生日期"></el-table-column>
<el-table-column key="homeAddress" min-width="200" align="center" prop="homeAddress" label="家庭住址" <el-table-column key="homeAddress" min-width="200" align="center" prop="homeAddress" label="家庭住址"
show-overflow-tooltip> show-overflow-tooltip>
<template v-slot="scope"> <template v-slot="scope">
<span class="one-line-omit"> <span class="one-line-omit">
{{ scope.row.homeAddress }} {{ scope.row.homeAddress }}
</span> </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="bloodType" width="100" align="center" prop="bloodType" label="血型"/> <el-table-column key="bloodType" width="100" align="center" prop="bloodType" label="血型" />
<el-table-column key="health" min-width="100" header-align="center" align="center" prop="health" <el-table-column key="health" min-width="100" header-align="center" align="center" prop="health" label="健康状况"
label="健康状况" show-overflow-tooltip></el-table-column>
show-overflow-tooltip></el-table-column> <el-table-column key="otherRegions" width="180" align="center" prop="otherRegions" label="港澳台侨" />
<el-table-column key="otherRegions" width="180" align="center" prop="otherRegions" label="港澳台侨"/>
<el-table-column key="floatingPopulation" width="130" align="center" prop="floatingPopulation" <el-table-column key="floatingPopulation" width="130" align="center" prop="floatingPopulation"
label="流动人口状况"/> label="流动人口状况" />
<el-table-column key="onlyChild" width="150" align="center" prop="onlyChild" label="独生子女"> <el-table-column key="onlyChild" width="150" align="center" prop="onlyChild" label="独生子女">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.only_child" :value="scope.row.onlyChild"/> <dict-tag :options="dict.type.only_child" :value="scope.row.onlyChild" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="nature" width="150" align="center" prop="nature" label="性质"> <el-table-column key="nature" width="150" align="center" prop="nature" label="性质">
...@@ -226,8 +221,7 @@ ...@@ -226,8 +221,7 @@
<dict-tag :options="dict.type.student_nature" :value="scope.row.nature"></dict-tag> <dict-tag :options="dict.type.student_nature" :value="scope.row.nature"></dict-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column key="support" width="150" align="center" prop="support" <el-table-column key="support" width="150" align="center" prop="support" label="接收资助情况"></el-table-column>
label="接收资助情况"></el-table-column>
<el-table-column label="操作" align="center" min-width="100px" fixed="right"> <el-table-column label="操作" align="center" min-width="100px" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<!-- <el-button--> <!-- <el-button-->
...@@ -243,24 +237,24 @@ ...@@ -243,24 +237,24 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-table v-else v-loading="teacherLoading" stripe border style="width: 100%;" :cell-style="customCellStyle" <el-table v-else v-loading="teacherLoading" stripe border style="width: 100%;" :cell-style="customCellStyle"
:data="rightData.teacherList" :key="Types.TEACHER"> :data="rightData.teacherList" :key="Types.TEACHER">
<el-table-column label="头像" align="center" width="100" prop="picUrl"> <el-table-column label="头像" align="center" width="100" prop="picUrl">
<template slot-scope="scope"> <template slot-scope="scope">
<ListImage :image-url="isEmptyTeacherUrl(scope.row.picUrl, scope.row.sex)"></ListImage> <ListImage :image-url="isEmptyTeacherUrl(scope.row.picUrl, scope.row.sex)"></ListImage>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="老师名称" align="center" prop="teacherName"/> <el-table-column label="老师名称" align="center" prop="teacherName" />
<el-table-column label="性别" align="center" width="55" prop="sex"> <el-table-column label="性别" align="center" width="55" prop="sex">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"/> <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="工作编号" width="180px" align="center" prop="teacherCode"/> <el-table-column label="工作编号" width="180px" align="center" prop="teacherCode" />
<el-table-column label="老师电话" width="180px" align="center" prop="teacherTel"/> <el-table-column label="老师电话" width="180px" align="center" prop="teacherTel" />
<el-table-column label="任教课程" align="center" prop="courseName"></el-table-column> <el-table-column label="任教课程" align="center" prop="courseName"></el-table-column>
<el-table-column label="学历" align="center" prop="education"> <el-table-column label="学历" align="center" prop="education">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.education" :value="scope.row.education"/> <dict-tag :options="dict.type.education" :value="scope.row.education" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center"> <el-table-column label="操作" align="center">
...@@ -272,8 +266,7 @@ ...@@ -272,8 +266,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<ExPagination :total="activeName === Types.STUDENT ? studentTotal : teacherTotal" <ExPagination :total="activeName === Types.STUDENT ? studentTotal : teacherTotal"
:limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum" @pagination="getClassDetails">
@pagination="getClassDetails">
</ExPagination> </ExPagination>
</el-row> </el-row>
</el-col> </el-col>
...@@ -282,31 +275,29 @@ ...@@ -282,31 +275,29 @@
<el-form v-if="personDetail.isStudent" ref="studentForm" :model="studentForm" disabled label-width="114px"> <el-form v-if="personDetail.isStudent" ref="studentForm" :model="studentForm" disabled label-width="114px">
<el-form-item prop="avatar" label-width="0" style="display: flex; justify-content: center;"> <el-form-item prop="avatar" label-width="0" style="display: flex; justify-content: center;">
<el-image :src="studentForm.avatar" :preview-src-list="[studentForm.avatar]" <el-image :src="studentForm.avatar" :preview-src-list="[studentForm.avatar]"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
<div slot="error"> <div slot="error">
<img :src="isEmptyAvatar(studentForm.avatar, studentForm.sex)" <img :src="isEmptyAvatar(studentForm.avatar, studentForm.sex)"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
</div> </div>
</el-image> </el-image>
</el-form-item> </el-form-item>
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="8"> <el-col :span="8">
<el-form-item label="姓名:" prop="studentName"> <el-form-item label="姓名:" prop="studentName">
<el-input placeholder="请输入姓名" :disabled="isEditMode" v-model="studentForm.studentName" <el-input placeholder="请输入姓名" :disabled="isEditMode" v-model="studentForm.studentName" clearable></el-input>
clearable></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="身份证号:" prop="idCard"> <el-form-item label="身份证号:" prop="idCard">
<el-input placeholder="请输入身份证号" :disabled="isEditMode" v-model="studentForm.idCard" <el-input placeholder="请输入身份证号" :disabled="isEditMode" v-model="studentForm.idCard" clearable></el-input>
clearable></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="性别:" prop="sex"> <el-form-item label="性别:" prop="sex">
<el-select v-model="studentForm.sex" placeholder="请输入性别" style="width: 100%;"> <el-select v-model="studentForm.sex" placeholder="请输入性别" style="width: 100%;">
<el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -320,15 +311,14 @@ ...@@ -320,15 +311,14 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="出生日期:" prop="birthday"> <el-form-item label="出生日期:" prop="birthday">
<el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd" <el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd" placeholder="请选择出生日期"
placeholder="请选择出生日期" style="width: 100%;"></el-date-picker>
style="width: 100%;"></el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="班级:" prop="classAlias"> <el-form-item label="班级:" prop="classAlias">
<el-input v-model="studentForm.classAlias" placeholder="请选择班级" readonly @focus="selectClass" <el-input v-model="studentForm.classAlias" placeholder="请选择班级" readonly @focus="selectClass"
style="width: 100%"></el-input> style="width: 100%"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -337,7 +327,7 @@ ...@@ -337,7 +327,7 @@
<el-form-item label="学生状态:" prop="studentStatus"> <el-form-item label="学生状态:" prop="studentStatus">
<el-select v-model="studentForm.studentStatus" placeholder="请输入学生状态" style="width: 100%;"> <el-select v-model="studentForm.studentStatus" placeholder="请输入学生状态" style="width: 100%;">
<el-option v-for="dict in dict.type.child_state" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.child_state" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -346,7 +336,7 @@ ...@@ -346,7 +336,7 @@
<el-form-item label="学生类型:" prop="studentType"> <el-form-item label="学生类型:" prop="studentType">
<el-select v-model="studentForm.studentType" placeholder="请输入学生类型" style="width: 100%;"> <el-select v-model="studentForm.studentType" placeholder="请输入学生类型" style="width: 100%;">
<el-option v-for="dict in dict.type.student_type" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.student_type" :key="dict.value" :label="dict.label"
:value="dict.value">{{ dict.label }} :value="dict.value">{{ dict.label }}
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -371,10 +361,8 @@ ...@@ -371,10 +361,8 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="民族:" prop="nation"> <el-form-item label="民族:" prop="nation">
<el-select :disabled="isEditMode" v-model="studentForm.nation" placeholder="请选择民族" <el-select :disabled="isEditMode" v-model="studentForm.nation" placeholder="请选择民族" style="width: 100%">
style="width: 100%"> <el-option v-for="item in Nations" :key="item.label" :label="item.label" :value="item.label"></el-option>
<el-option v-for="item in Nations" :key="item.label" :label="item.label"
:value="item.label"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -407,8 +395,7 @@ ...@@ -407,8 +395,7 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="级/届:" prop="enrollmentYear"> <el-form-item label="级/届:" prop="enrollmentYear">
<el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year" <el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year" placeholder="选择入学年">
placeholder="选择入学年">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
...@@ -416,7 +403,7 @@ ...@@ -416,7 +403,7 @@
<el-col :span="8"> <el-col :span="8">
<el-form-item label="入学时间:" prop="enrollmentTime"> <el-form-item label="入学时间:" prop="enrollmentTime">
<el-date-picker v-model="studentForm.enrollmentTime" value-format="yyyy-MM-dd" style="width: 100%" <el-date-picker v-model="studentForm.enrollmentTime" value-format="yyyy-MM-dd" style="width: 100%"
type="date" placeholder="选择入学时间"> type="date" placeholder="选择入学时间">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -457,10 +444,7 @@ ...@@ -457,10 +444,7 @@
<el-col :span="8"> <el-col :span="8">
<el-form-item label="户口性质:" prop="registeredType"> <el-form-item label="户口性质:" prop="registeredType">
<el-select v-model="studentForm.registeredType" style="width: 100%" placeholder="请输入户口性质"> <el-select v-model="studentForm.registeredType" style="width: 100%" placeholder="请输入户口性质">
<el-option <el-option v-for="dict in dict.type.regist_type" :key="dict.value" :label="dict.label"
v-for="dict in dict.type.regist_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
...@@ -483,7 +467,7 @@ ...@@ -483,7 +467,7 @@
<el-form-item label="政治面貌:" prop="appearance"> <el-form-item label="政治面貌:" prop="appearance">
<el-select v-model="studentForm.appearance" style="width: 100%" placeholder="请选择政治面貌"> <el-select v-model="studentForm.appearance" style="width: 100%" placeholder="请选择政治面貌">
<el-option v-for="dict in dict.type.politics_tatus" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.politics_tatus" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -515,11 +499,7 @@ ...@@ -515,11 +499,7 @@
<el-col :span="8"> <el-col :span="8">
<el-form-item label="独生子女:" prop="onlyChild"> <el-form-item label="独生子女:" prop="onlyChild">
<el-select v-model="studentForm.onlyChild" style="width: 100%" placeholder="请选择是否为独生子女"> <el-select v-model="studentForm.onlyChild" style="width: 100%" placeholder="请选择是否为独生子女">
<el-option <el-option v-for="dict in dict.type.only_child" :key="dict.value" :label="dict.label" :value="dict.value">
v-for="dict in dict.type.only_child"
:key="dict.value"
:label="dict.label"
:value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -529,7 +509,7 @@ ...@@ -529,7 +509,7 @@
<el-form-item label="性质:" prop="nature"> <el-form-item label="性质:" prop="nature">
<el-select v-model="studentForm.nature" placeholder="请选择学生性质" style="width: 100%;"> <el-select v-model="studentForm.nature" placeholder="请选择学生性质" style="width: 100%;">
<el-option v-for="dict in dict.type.student_nature" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.student_nature" :key="dict.value" :label="dict.label"
:value="dict.value"> :value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -547,30 +527,30 @@ ...@@ -547,30 +527,30 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="教师名称" prop="teacherName"> <el-form-item label="教师名称" prop="teacherName">
<el-input v-model="teacherForm.teacherName" placeholder=""/> <el-input v-model="teacherForm.teacherName" placeholder="" />
</el-form-item> </el-form-item>
<el-form-item label="性别" prop="sex"> <el-form-item label="性别" prop="sex">
<el-select v-model="teacherForm.sex" style="width: 100%" placeholder=""> <el-select v-model="teacherForm.sex" style="width: 100%" placeholder="">
<el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.sys_user_sex" :key="dict.value" :label="dict.label"
:value="dict.value"></el-option> :value="dict.value"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="身份证号" prop="idCard"> <el-form-item label="身份证号" prop="idCard">
<el-input v-model.trim="teacherForm.idCard" placeholder=""/> <el-input v-model.trim="teacherForm.idCard" placeholder="" />
</el-form-item> </el-form-item>
<el-form-item label="手机号码" prop="teacherTel"> <el-form-item label="手机号码" prop="teacherTel">
<el-input v-model="teacherForm.teacherTel" placeholder=""/> <el-input v-model="teacherForm.teacherTel" placeholder="" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item prop="picUrl"> <el-form-item prop="picUrl">
<template slot-scope="scope"> <template slot-scope="scope">
<el-image :src="isEmptyTeacherUrl(teacherForm.picUrl, teacherForm.sex)" <el-image :src="isEmptyTeacherUrl(teacherForm.picUrl, teacherForm.sex)"
:preview-src-list="[isEmptyTeacherUrl(teacherForm.picUrl, teacherForm.sex)]" :preview-src-list="[isEmptyTeacherUrl(teacherForm.picUrl, teacherForm.sex)]"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
<div slot="error"> <div slot="error">
<img :src="isEmptyTeacherUrl(teacherForm.picUrl, teacherForm.sex)" <img :src="isEmptyTeacherUrl(teacherForm.picUrl, teacherForm.sex)"
style="width: 178px; height: 178px; border-radius: 50%"> style="width: 178px; height: 178px; border-radius: 50%">
</div> </div>
</el-image> </el-image>
</template> </template>
...@@ -591,7 +571,7 @@ ...@@ -591,7 +571,7 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="工作编号" prop="teacherCode"> <el-form-item label="工作编号" prop="teacherCode">
<el-input v-model="teacherForm.teacherCode" placeholder=""/> <el-input v-model="teacherForm.teacherCode" placeholder="" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
...@@ -610,16 +590,14 @@ ...@@ -610,16 +590,14 @@
<el-col :span="12"> <el-col :span="12">
<el-form-item label="岗位" prop="postId"> <el-form-item label="岗位" prop="postId">
<el-select multiple v-model="teacherForm.postId" placeholder="" style="width: 100%;"> <el-select multiple v-model="teacherForm.postId" placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.postId" :label="item.postName" <el-option v-for="item in []" :key="item.postId" :label="item.postName" :value="item.postId"></el-option>
:value="item.postId"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="角色" prop="roleId"> <el-form-item label="角色" prop="roleId">
<el-select v-model="teacherForm.roleId" multiple placeholder="" style="width: 100%;"> <el-select v-model="teacherForm.roleId" multiple placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.roleId" :label="item.roleName" <el-option v-for="item in []" :key="item.roleId" :label="item.roleName" :value="item.roleId"></el-option>
:value="item.roleId"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -628,15 +606,14 @@ ...@@ -628,15 +606,14 @@
<el-col :span="12"> <el-col :span="12">
<el-form-item label="生日" prop="birthday"> <el-form-item label="生日" prop="birthday">
<el-date-picker clearable v-model="teacherForm.birthday" type="date" style="width: 100%" <el-date-picker clearable v-model="teacherForm.birthday" type="date" style="width: 100%"
value-format="yyyy-MM-dd" placeholder=""> value-format="yyyy-MM-dd" placeholder="">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="民族" prop="nation"> <el-form-item label="民族" prop="nation">
<el-select v-model="teacherForm.nation" style="width: 100%" placeholder=""> <el-select v-model="teacherForm.nation" style="width: 100%" placeholder="">
<el-option v-for="item in Nations" :key="item.label" :label="item.label" <el-option v-for="item in Nations" :key="item.label" :label="item.label" :value="item.label"></el-option>
:value="item.label"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -646,13 +623,13 @@ ...@@ -646,13 +623,13 @@
<el-form-item label="学历" prop="education"> <el-form-item label="学历" prop="education">
<el-select v-model="teacherForm.education" style="width: 100%" placeholder="请选择学历"> <el-select v-model="teacherForm.education" style="width: 100%" placeholder="请选择学历">
<el-option v-for="dict in dict.type.education" :key="dict.value" :label="dict.label" <el-option v-for="dict in dict.type.education" :key="dict.value" :label="dict.label"
:value="dict.value"></el-option> :value="dict.value"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="家庭住址" prop="homeAddress"> <el-form-item label="家庭住址" prop="homeAddress">
<el-input v-model="teacherForm.homeAddress" placeholder=""/> <el-input v-model="teacherForm.homeAddress" placeholder="" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -673,12 +650,12 @@ import { ...@@ -673,12 +650,12 @@ import {
getStudentList, getStudentList,
getTeacherList getTeacherList
} from "@/api/smartSchool/teachAffairAdministration/affairClassView"; } from "@/api/smartSchool/teachAffairAdministration/affairClassView";
import {getFirstLeafNode, handleTreeData} from "@/utils/utilLibrary/getTreeClass"; import { getFirstLeafNode, handleTreeData } from "@/utils/utilLibrary/getTreeClass";
import {getYearList} from "@/utils/utilLibrary/getYearList"; import { getYearList } from "@/utils/utilLibrary/getYearList";
import {CustomCellStyle} from "@/enums/customStyle"; import { CustomCellStyle } from "@/enums/customStyle";
import {getStudent} from "@/api/smartSchool/studentManage"; import { getStudent } from "@/api/smartSchool/studentManage";
import {getInform} from "@/api/smartSchool/teacherManage/teacherInformation"; import { getInform } from "@/api/smartSchool/teacherManage/teacherInformation";
import {Gender, Nations} from "@/enums/common"; import { Gender, Nations } from "@/enums/common";
export default { export default {
name: "index", name: "index",
...@@ -843,7 +820,6 @@ export default { ...@@ -843,7 +820,6 @@ export default {
/** 查询班级信息 */ /** 查询班级信息 */
getClassDetails() { getClassDetails() {
if (this.yearClass == 1) { if (this.yearClass == 1) {
this.queryParams.pageNum = 1;
if (this.activeName === this.Types.STUDENT) { if (this.activeName === this.Types.STUDENT) {
this.studentLoading = true; this.studentLoading = true;
getStudentList(this.queryParams).then(response => { getStudentList(this.queryParams).then(response => {
...@@ -987,4 +963,8 @@ export default { ...@@ -987,4 +963,8 @@ export default {
.form-header { .form-header {
margin: 8px 0px 25px 0px; margin: 8px 0px 25px 0px;
} }
.scrollable-card {
overflow: auto;
}
</style> </style>
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div class="app-container"> <div class="app-container">
<el-row> <el-row>
<el-col :span="4"> <el-col :span="4">
<el-card style="height: 950px"> <el-card style="height: 950px" class="scrollable-card">
<el-form :model="queryParams" style="border-bottom: 1px solid #dfe6ec; padding: 10px 0 0 5px"> <el-form :model="queryParams" style="border-bottom: 1px solid #dfe6ec; padding: 10px 0 0 5px">
<el-form-item label="班级信息" prop="schoolYear"> <el-form-item label="班级信息" prop="schoolYear">
<el-select v-model="queryParams.schoolYear" @change="getTreeData" style="width: 100%" size="mini"> <el-select v-model="queryParams.schoolYear" @change="getTreeData" style="width: 100%" size="mini">
...@@ -678,6 +678,10 @@ export default { ...@@ -678,6 +678,10 @@ export default {
padding-right: 0px; padding-right: 0px;
} }
.scrollable-card {
overflow: auto;
}
/*.dragBox[data-v-86c11aba] {*/ /*.dragBox[data-v-86c11aba] {*/
/* font-size: 20px;*/ /* font-size: 20px;*/
/* width: 100%;*/ /* width: 100%;*/
......
...@@ -2,33 +2,20 @@ ...@@ -2,33 +2,20 @@
<div class="activity-result app-container"> <div class="activity-result app-container">
<el-tabs tab-position="left" style="height: 100%;"> <el-tabs tab-position="left" style="height: 100%;">
<el-tab-pane label="明细数据"> <el-tab-pane label="明细数据">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">
label-width="80px">
<el-form-item label="姓名" prop="studentName"> <el-form-item label="姓名" prop="studentName">
<el-input v-model="queryParams.studentName" placeholder="请输入姓名" clearable <el-input v-model="queryParams.studentName" placeholder="请输入姓名" clearable @keyup.enter.native="handleQuery">
@keyup.enter.native="handleQuery">
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item label="填写状态" prop="ryZdzt"> <el-form-item label="填写状态" prop="ryZdzt">
<el-select v-model="queryParams.ryZdzt" style="width: 100%" placeholder="请选择问卷填写状态"> <el-select v-model="queryParams.ryZdzt" style="width: 100%" placeholder="请选择问卷填写状态">
<el-option <el-option v-for="dict in dict.type.quiz_txzt" :key="dict.value" :label="dict.label" :value="dict.value">
v-for="dict in dict.type.quiz_txzt"
:key="dict.value"
:label="dict.label"
:value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="填写时间"> <el-form-item label="填写时间">
<el-date-picker <el-date-picker v-model="dateRange" style="width: 240px" value-format="yyyy-MM-dd" type="daterange"
v-model="dateRange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
style="width: 240px"
value-format="yyyy-MM-dd"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button> <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
...@@ -48,31 +35,26 @@ ...@@ -48,31 +35,26 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row> </el-row>
<el-table v-loading="loading" :data="activityList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="activityList" @selection-change="handleSelectionChange">
<el-table-column type="index" label="序号" width="55" align="center"/> <el-table-column type="index" label="序号" width="55" align="center" />
<el-table-column v-if="pubType==0" label="班级" align="center" prop="classAlias"/> <el-table-column v-if="pubType == 0" label="班级" align="center" prop="classAlias" />
<el-table-column label="姓名" align="center" prop="studentName"/> <el-table-column label="姓名" align="center" prop="studentName" />
<el-table-column label="填写状态" align="center" prop="ryZdzt"> <el-table-column label="填写状态" align="center" prop="ryZdzt">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.ryZdzt == 0 ? '未填写' : '已填写' }} </span> <span>{{ scope.row.ryZdzt == 0 ? '未填写' : '已填写' }} </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="填写时间" align="center" min-width="120px" prop="ryCtime"/> <el-table-column label="填写时间" align="center" min-width="120px" prop="ryCtime" />
<el-table-column v-for="(item,index) in dynamicTitle" :label="item" min-width="150px" align="center"> <el-table-column v-for="(item, index) in dynamicTitle" :label="item" min-width="150px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<ListImage v-if="scope.row[dynamicProp[index]] && scope.row[dynamicProp[index]].type==3" <ListImage v-if="scope.row[dynamicProp[index]] && scope.row[dynamicProp[index]].type == 3"
:image-url=" scope.row[dynamicProp[index]] && baseUrl+scope.row[dynamicProp[index]].datas" :image-url="scope.row[dynamicProp[index]] && baseUrl + scope.row[dynamicProp[index]].datas"
style="height: 50px"></ListImage> style="height: 50px"></ListImage>
<span v-else> {{ scope.row[dynamicProp[index]] && scope.row[dynamicProp[index]].datas }}</span> <span v-else> {{ scope.row[dynamicProp[index]] && scope.row[dynamicProp[index]].datas }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" min-width="80" key="operate"> <el-table-column label="操作" align="center" min-width="80" key="operate">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">查看
size="mini"
type="text"
icon="el-icon-view"
@click="handleDetail(scope.row)"
>查看
</el-button> </el-button>
</template> </template>
</el-table-column> </el-table-column>
...@@ -80,15 +62,14 @@ ...@@ -80,15 +62,14 @@
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="统计"> <el-tab-pane label="统计">
<el-card style="width: 900px; height: 900px; margin:auto"> <el-card style="width: 900px; height: 900px; margin:auto">
<div v-if="countList.length!=0" v-for="(item,index) in countList" :key="item.title" <div v-if="countList.length != 0" v-for="(item, index) in countList" :key="item.title"
style="height:270px ;width:800px;margin: 20px 0 0 0 ;"> style="height:270px ;width:800px;margin: 20px 0 0 0 ;">
<b>{{ item.title }}</b> <b>{{ item.title }}</b>
<br/> <br/> <br /> <br />
<el-table v-loading="loading" :data="item.detailsLit" <el-table v-loading="loading" :data="item.detailsLit" :summary-method="(res) => getSummaries(res, index)"
:summary-method="(res)=>getSummaries(res,index )" show-summary show-summary>
> <el-table-column label="选项" align="center" prop="selects" />
<el-table-column label="选项" align="center" prop="selects"/> <el-table-column label="小计" align="center" prop="selectNum" />
<el-table-column label="小计" align="center" prop="selectNum"/>
<el-table-column label="比例" align="center" sortable prop="proportion"> <el-table-column label="比例" align="center" sortable prop="proportion">
<template slot-scope="scope"> <template slot-scope="scope">
<el-progress :percentage="scope.row.proportion"></el-progress> <el-progress :percentage="scope.row.proportion"></el-progress>
...@@ -101,9 +82,9 @@ ...@@ -101,9 +82,9 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<el-dialog title="调查问卷" :visible.sync="dialogQuestionire" width="860" append-to-body> <el-dialog title="调查问卷" :visible.sync="dialogQuestionire" width="860" append-to-body>
<el-form ref="form" disabled label-width="90px" <el-form ref="form" disabled label-width="90px" style="width: 100%; margin: auto">
style="width: 100%; margin: auto">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="班级"> <el-form-item label="班级">
...@@ -111,26 +92,18 @@ ...@@ -111,26 +92,18 @@
</el-form-item> </el-form-item>
<el-form-item label="填写状态" prop="ryZdzt"> <el-form-item label="填写状态" prop="ryZdzt">
<el-select v-model="formFix.ryZdzt" style="width: 100%" placeholder="请选择问卷填写状态"> <el-select v-model="formFix.ryZdzt" style="width: 100%" placeholder="请选择问卷填写状态">
<el-option <el-option v-for="dict in dict.type.quiz_txzt" :key="dict.value" :label="dict.label" :value="dict.value">
v-for="dict in dict.type.quiz_txzt"
:key="dict.value"
:label="dict.label"
:value="dict.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="姓名" prop="studentName"> <el-form-item label="姓名" prop="studentName">
<el-input :value="formFix.studentName"/> <el-input :value="formFix.studentName" />
</el-form-item> </el-form-item>
<el-form-item label="填写时间"> <el-form-item label="填写时间">
<el-date-picker <el-date-picker v-model="formFix.ryCtime" style="width: 100%" value-format="yyyy-MM-dd HH:mm"
v-model="formFix.ryCtime" type="date"></el-date-picker>
style="width: 100%"
value-format="yyyy-MM-dd HH:mm"
type="date"
></el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -139,28 +112,29 @@ ...@@ -139,28 +112,29 @@
<el-row v-for="item in formFlex "> <el-row v-for="item in formFlex ">
( (
<dict-tag style="display: inline-block; font-weight: bold" :options="dict.type.quiz_type" <dict-tag style="display: inline-block; font-weight: bold" :options="dict.type.quiz_type"
:value="item.type"></dict-tag> :value="item.type"></dict-tag>
) )
<b>{{ item.title }}</b> <b>{{ item.title }}</b>
<br/><br/> <br /><br />
<el-image v-if="item.type==3" :src="baseUrl+item.datas"></el-image> <el-image v-if="item.type == 3" :src="baseUrl + item.datas"></el-image>
<b v-else>{{ item.datas }}</b> <b v-else>{{ item.datas }}</b>
<el-divider></el-divider> <el-divider></el-divider>
</el-row> </el-row>
</el-form> </el-form>
</el-dialog> </el-dialog>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
</div> </div>
</template> </template>
<script> <script>
import {activityTypesEnum, departmentEnum} from "@/enums/questionnaire/content"; import { activityTypesEnum, departmentEnum } from "@/enums/questionnaire/content";
import { import {
getList, getList,
getCount, getCount,
getQuestionResultQueryOne getQuestionResultQueryOne
} from "@/api/smartSchool/teachAffairAdministration/questionnaireManagement/ActivityResult/request.js"; } from "@/api/smartSchool/teachAffairAdministration/questionnaireManagement/ActivityResult/request.js";
import {closeCurrentTab} from "@/utils/utilLibrary/routerBatch/routerBatch.js"; import { closeCurrentTab } from "@/utils/utilLibrary/routerBatch/routerBatch.js";
export default { export default {
name: "QuestionnaireResult", name: "QuestionnaireResult",
...@@ -191,7 +165,7 @@ export default { ...@@ -191,7 +165,7 @@ export default {
// 显示搜索条件 // 显示搜索条件
showSearch: true, showSearch: true,
// 总条数 // 总条数
// total: 0, total: 0,
// 办公申购表格数据 // 办公申购表格数据
activityList: [], activityList: [],
// 弹出层标题 // 弹出层标题
...@@ -241,6 +215,8 @@ export default { ...@@ -241,6 +215,8 @@ export default {
this.loading = true; this.loading = true;
getList(this.addDateRange(this.queryParams, this.dateRange), this.dcwjId).then(response => { getList(this.addDateRange(this.queryParams, this.dateRange), this.dcwjId).then(response => {
this.activityList = response.data this.activityList = response.data
this.total = response.total;
console.log(response, 'response');
//获取标题 //获取标题
let title = Object.values(response.titles) let title = Object.values(response.titles)
this.dynamicTitle = title.filter((item) => { this.dynamicTitle = title.filter((item) => {
...@@ -360,7 +336,7 @@ export default { ...@@ -360,7 +336,7 @@ export default {
//查看按钮 //查看按钮
handleDetail(row) { handleDetail(row) {
this.dialogQuestionire = true this.dialogQuestionire = true
let {classAlias, ryZdzt, studentName, ryCtime} = row let { classAlias, ryZdzt, studentName, ryCtime } = row
this.formFix.classAlias = classAlias this.formFix.classAlias = classAlias
this.formFix.ryZdzt = ryZdzt this.formFix.ryZdzt = ryZdzt
this.formFix.studentName = studentName this.formFix.studentName = studentName
...@@ -391,7 +367,7 @@ export default { ...@@ -391,7 +367,7 @@ export default {
}, },
getSummaries(param, index) { getSummaries(param, index) {
// console.log(index,778) // console.log(index,778)
const {columns, data} = param; const { columns, data } = param;
const sums = []; const sums = [];
columns.forEach((column, columnIndex) => { columns.forEach((column, columnIndex) => {
if (columnIndex === 0) { if (columnIndex === 0) {
...@@ -410,6 +386,5 @@ export default { ...@@ -410,6 +386,5 @@ export default {
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
div.activity-result { div.activity-result {}
}
</style> </style>
<template> <template>
<div class="questionnaire-activity app-container"> <div class="questionnaire-activity app-container">
<el-form <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="68px"
>
<el-form-item label="问卷名称" prop="dcwjName"> <el-form-item label="问卷名称" prop="dcwjName">
<el-input v-model="queryParams.dcwjName" <el-input v-model="queryParams.dcwjName" placeholder="请输入问卷名称" clearable @keyup.enter.native="handleQuery">
placeholder="请输入问卷名称"
clearable
@keyup.enter.native="handleQuery"
>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item label="问卷状态" prop="dcwjZt"> <el-form-item label="问卷状态" prop="dcwjZt">
...@@ -29,13 +18,7 @@ ...@@ -29,13 +18,7 @@
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd">新 增
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
>新 增
</el-button> </el-button>
<!-- v-show="queryParams.dcwjZt==='0'"--> <!-- v-show="queryParams.dcwjZt==='0'"-->
</el-col> </el-col>
...@@ -78,89 +61,55 @@ ...@@ -78,89 +61,55 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row> </el-row>
<el-table v-loading="loading" :data="activityList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="activityList" @selection-change="handleSelectionChange">
<el-table-column type="selection" min-width="55" align="center"/> <el-table-column type="selection" min-width="55" align="center" />
<el-table-column type="index" label="序号" min-width="55" align="center"/> <el-table-column type="index" label="序号" min-width="55" align="center" />
<el-table-column label="范围" align="center" prop="scope" min-width="200px" show-overflow-tooltip> <el-table-column label="范围" align="center" prop="scope" min-width="200px" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.scope }} {{ scope.row.scope }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="问卷名称" align="center" prop="dcwjName" min-width="150px" show-overflow-tooltip/> <el-table-column label="问卷名称" align="center" prop="dcwjName" min-width="150px" show-overflow-tooltip />
<el-table-column label="状态" align="center" prop="dcwjZt"> <el-table-column label="状态" align="center" prop="dcwjZt">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.quest_state" :value="scope.row.dcwjZt"/> <dict-tag :options="dict.type.quest_state" :value="scope.row.dcwjZt" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="开始时间" sortable align="center" min-width="150px" prop="dcwjKssj"/> <el-table-column label="开始时间" sortable align="center" min-width="150px" prop="dcwjKssj" />
<el-table-column label="结束时间" sortable align="center" min-width="150px" prop="dcwjJssj"/> <el-table-column label="结束时间" sortable align="center" min-width="150px" prop="dcwjJssj" />
<el-table-column label="描述" align="center" min-width="200px" show-overflow-tooltip prop="dcwjMs"/> <el-table-column label="描述" align="center" min-width="200px" show-overflow-tooltip prop="dcwjMs" />
<el-table-column label="操作" align="center" min-width="270px"> <el-table-column label="操作" align="center" min-width="270px">
<template v-slot="scope"> <template v-slot="scope">
<el-button <el-button v-show="scope.row.dcwjZt === '1'" size="mini" type="text" @click="handleUpdate(scope.row)">修改
v-show="scope.row.dcwjZt==='1'"
size="mini"
type="text"
@click="handleUpdate(scope.row)"
>修改
</el-button> </el-button>
<el-button <el-button size="mini" type="text"
size="mini" @click="jumpTo(QuestionnaireContent(scope.row.id, scope.row.dcwjZt, scope.row.dcwjName))">问卷内容
type="text"
@click="jumpTo(QuestionnaireContent(scope.row.id, scope.row.dcwjZt,scope.row.dcwjName))"
>问卷内容
</el-button> </el-button>
<el-button v-show="scope.row.dcwjZt==='1'" <el-button v-show="scope.row.dcwjZt === '1'" size="mini" type="text" @click="publishExamExecute(scope.row)">发布
size="mini"
type="text"
@click="publishExamExecute(scope.row)"
>发布
</el-button> </el-button>
<el-button v-show="scope.row.dcwjZt==='2'" <el-button v-show="scope.row.dcwjZt === '2'" size="mini" type="text"
size="mini" @click="toQuestionResult(scope.row.id, scope.row.pubType)">问卷结果
type="text"
@click="toQuestionResult(scope.row.id,scope.row.pubType)"
>问卷结果
</el-button> </el-button>
<!-- @click="jumpTo(ActivityResult(scope.row.id,scope.row.pubType))"--> <!-- @click="jumpTo(ActivityResult(scope.row.id,scope.row.pubType))"-->
<el-button v-show="scope.row.dcwjZt==='1'" <el-button v-show="scope.row.dcwjZt === '1'" size="mini" type="text" @click="handleDelete(scope.row)">删除
size="mini"
type="text"
@click="handleDelete(scope.row)"
>删除
</el-button> </el-button>
<el-button <el-button v-show="scope.row.dcwjZt === '2'" size="mini" type="text" @click="recallExamExecute(scope.row)">撤回
v-show="scope.row.dcwjZt==='2'"
size="mini"
type="text"
@click="recallExamExecute(scope.row)"
>撤回
</el-button> </el-button>
<el-button <el-button size="mini" type="text" @click="handleCheck(scope.row)">查看
size="mini"
type="text"
@click="handleCheck(scope.row)"
>查看
</el-button> </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<ExPagination <ExPagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
v-show="total>0" @pagination="getList" />
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改问卷调查活动对话框 --> <!-- 添加或修改问卷调查活动对话框 -->
<el-dialog :title="title" :visible.sync="open" width="650px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="650px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="auto" class="add-edit-dialog" <el-form ref="form" :model="form" :rules="rules" label-width="auto" class="add-edit-dialog" :disabled="!isEditable">
:disabled="!isEditable">
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item label="问卷名称" prop="dcwjName"> <el-form-item label="问卷名称" prop="dcwjName">
<el-input v-model="form.dcwjName" placeholder="请输入活动名称"/> <el-input v-model="form.dcwjName" placeholder="请输入活动名称" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
...@@ -169,25 +118,15 @@ ...@@ -169,25 +118,15 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="开始时间" prop="dcwjKssj"> <el-form-item label="开始时间" prop="dcwjKssj">
<el-date-picker clearable <el-date-picker clearable v-model="form.dcwjKssj" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
v-model="form.dcwjKssj" placeholder="请选择开始时间" :picker-options="StartPickerOptions">
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择开始时间"
:picker-options="StartPickerOptions"
>
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="" prop="dcwjJssj" label-width="0px"> <el-form-item label="" prop="dcwjJssj" label-width="0px">
<el-date-picker clearable <el-date-picker clearable v-model="form.dcwjJssj" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
v-model="form.dcwjJssj" placeholder="请选择结束时间" :picker-options="EndPickerOptions">
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择结束时间"
:picker-options="EndPickerOptions"
>
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -195,42 +134,31 @@ ...@@ -195,42 +134,31 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="学年" prop="schoolYear"> <el-form-item label="学年" prop="schoolYear">
<el-input v-model="form.schoolYear" placeholder="请输入学年" disabled/> <el-input v-model="form.schoolYear" placeholder="请输入学年" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-form-item label="问卷描述" prop="dcwjMs"> <el-form-item label="问卷描述" prop="dcwjMs">
<el-input type="textarea" v-model="form.dcwjMs" placeholder="请输入问卷描述"/> <el-input type="textarea" v-model="form.dcwjMs" placeholder="请输入问卷描述" />
</el-form-item> </el-form-item>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="接收人类型" prop="pubType"> <el-form-item label="接收人类型" prop="pubType">
<el-select v-model="form.pubType" @change="receiveChange" placeholder="请选择接收人类型"> <el-select v-model="form.pubType" @change="receiveChange" placeholder="请选择接收人类型">
<el-option <el-option v-for="item in [{
v-for="item in [{
value: '1', value: '1',
label: '教师'},{ label: '教师'
}, {
value: '0', value: '0',
label: '家长' label: '家长'
}]" }]" :key="item.value" :label="item.label" :value="item.value">
:key="item.value"
:label="item.label"
:value="item.value">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="级部" prop="gradeIds"> <el-form-item label="级部" prop="gradeIds">
<treeselect <treeselect v-model="form.gradeIds" :disabled="gradeDisabled || !isEditable" multiple :options="gradeTree"
v-model="form.gradeIds" :show-count="true" :defaultExpandLevel="2" :disable-branch-nodes="true" placeholder="请选择级部" />
:disabled="gradeDisabled || !isEditable"
multiple
:options="gradeTree"
:show-count="true"
:defaultExpandLevel="2"
:disable-branch-nodes="true"
placeholder="请选择级部"
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-form> </el-form>
...@@ -258,8 +186,8 @@ import { ...@@ -258,8 +186,8 @@ import {
getQueryOne getQueryOne
} from "@/api/smartSchool/teachAffairAdministration/questionnaireManagement/QuestionnaireActivity/request.js"; } from "@/api/smartSchool/teachAffairAdministration/questionnaireManagement/QuestionnaireActivity/request.js";
import {jumpTo, Path_Destination} from "@/utils/utilLibrary/routerBatch/routerBatch"; import { jumpTo, Path_Destination } from "@/utils/utilLibrary/routerBatch/routerBatch";
import {QUESTION_STATE} from "@/enums/questionnaire/content"; import { QUESTION_STATE } from "@/enums/questionnaire/content";
import Treeselect from "@riophae/vue-treeselect"; import Treeselect from "@riophae/vue-treeselect";
import '@riophae/vue-treeselect/dist/vue-treeselect.css' import '@riophae/vue-treeselect/dist/vue-treeselect.css'
...@@ -315,11 +243,11 @@ export default { ...@@ -315,11 +243,11 @@ export default {
}, },
// 表单校验 // 表单校验
rules: { rules: {
dcwjName: [{required: true, message: '问卷名称不能为空', trigger: 'blur'}], dcwjName: [{ required: true, message: '问卷名称不能为空', trigger: 'blur' }],
dcwjKssj: [{required: true, message: '开始时间不能为空', trigger: 'blur'}], dcwjKssj: [{ required: true, message: '开始时间不能为空', trigger: 'blur' }],
dcwjJssj: [{required: true, message: '结束不能为空', trigger: 'blur'}], dcwjJssj: [{ required: true, message: '结束不能为空', trigger: 'blur' }],
gradeId: [{required: true, message: '范围不能为空', trigger: 'blur'}], gradeId: [{ required: true, message: '范围不能为空', trigger: 'blur' }],
pubType: [{required: true, message: '接收人类型不能为空', trigger: 'blur'}], pubType: [{ required: true, message: '接收人类型不能为空', trigger: 'blur' }],
}, },
StartPickerOptions: { StartPickerOptions: {
disabledDate: (time) => { disabledDate: (time) => {
...@@ -338,7 +266,7 @@ export default { ...@@ -338,7 +266,7 @@ export default {
title title
}), }),
//问卷结果 //问卷结果
ActivityResult: (examId, pubType) => new Path_Destination(`/teachAffairQuestion/result/${examId}`, {pubType: pubType}), ActivityResult: (examId, pubType) => new Path_Destination(`/teachAffairQuestion/result/${examId}`, { pubType: pubType }),
}; };
}, },
created() { created() {
...@@ -560,8 +488,9 @@ div.questionnaire-activity { ...@@ -560,8 +488,9 @@ div.questionnaire-activity {
} }
} }
form.add-edit-dialog ::v-deep .el-input__inner, form.add-edit-dialog ::v-deep .el-date-editor, form.add-edit-dialog ::v-deep .el-select--medium { form.add-edit-dialog ::v-deep .el-input__inner,
form.add-edit-dialog ::v-deep .el-date-editor,
form.add-edit-dialog ::v-deep .el-select--medium {
width: 98.5%; width: 98.5%;
} }
</style> </style>
package yangtz.cs.liu.campus.controller.SchoolEquipment; package yangtz.cs.liu.campus.controller.SchoolEquipment;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.ruoyi.common.annotation.Log; import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
...@@ -7,17 +8,21 @@ import com.ruoyi.common.core.domain.entity.SysUser; ...@@ -7,17 +8,21 @@ import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType; import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import yangtz.cs.liu.campus.domain.schoolEquipment.SchoolEquipmentLedger; import yangtz.cs.liu.campus.domain.schoolEquipment.SchoolEquipmentLedger;
import yangtz.cs.liu.campus.service.schoolEquipment.IEquipmentLedgerService; import yangtz.cs.liu.campus.service.schoolEquipment.IEquipmentLedgerService;
import yangtz.cs.liu.campus.vo.curricula.CurriculaStudentVo; import yangtz.cs.liu.campus.vo.curricula.CurriculaStudentVo;
import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolEquipmentLedgerDcVo;
import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolEquipmentLedgerVo; import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolEquipmentLedgerVo;
import yangtz.cs.liu.campus.vo.student.SchoolStudentScoreVo; import yangtz.cs.liu.campus.vo.student.SchoolStudentScoreVo;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Map;
/** /**
* 设备基础信息 * 设备基础信息
...@@ -58,8 +63,17 @@ public class EquipmentLedgerController extends BaseController { ...@@ -58,8 +63,17 @@ public class EquipmentLedgerController extends BaseController {
public void export(HttpServletResponse response, SchoolEquipmentLedgerVo schoolEquipmentLedgerVo) public void export(HttpServletResponse response, SchoolEquipmentLedgerVo schoolEquipmentLedgerVo)
{ {
List<SchoolEquipmentLedger> list = equipmentLedgerService.selectSchoolEquipmentLedgerList(schoolEquipmentLedgerVo); List<SchoolEquipmentLedger> list = equipmentLedgerService.selectSchoolEquipmentLedgerList(schoolEquipmentLedgerVo);
ExcelUtil<SchoolEquipmentLedger> util = new ExcelUtil<SchoolEquipmentLedger>(SchoolEquipmentLedger.class); List<SchoolEquipmentLedgerDcVo> list1 = new ArrayList<>();
util.exportExcel(response, list, "设备台账数据"); int i = 1;
for (SchoolEquipmentLedger schoolEquipmentLedger : list) {
SchoolEquipmentLedgerDcVo schoolEquipmentLedgerDcVo = new SchoolEquipmentLedgerDcVo();
BeanUtils.copyProperties(schoolEquipmentLedger,schoolEquipmentLedgerDcVo);
schoolEquipmentLedgerDcVo.setSerialNumber(i);
list1.add(schoolEquipmentLedgerDcVo);
i++;
}
ExcelUtil<SchoolEquipmentLedgerDcVo> util = new ExcelUtil<SchoolEquipmentLedgerDcVo>(SchoolEquipmentLedgerDcVo.class);
util.exportExcel(response, list1, "设备台账数据");
} }
/** /**
...@@ -138,4 +152,13 @@ public class EquipmentLedgerController extends BaseController { ...@@ -138,4 +152,13 @@ public class EquipmentLedgerController extends BaseController {
public TableDataInfo getUser(SysUser sysUser){ public TableDataInfo getUser(SysUser sysUser){
return getDataTable(equipmentLedgerService.getUser(sysUser)); return getDataTable(equipmentLedgerService.getUser(sysUser));
} }
/**
* 打印设备条码信息
*/
@GetMapping("/getEquipmentledger/{ids}")
public AjaxResult getEquipmentledger(@PathVariable Long[] ids){
List<Map<String,Object>> mapList = equipmentLedgerService.getEquipmentledger(ids);
return AjaxResult.success(mapList);
}
} }
...@@ -69,6 +69,18 @@ public class SchoolOrganizationFcController extends BaseController ...@@ -69,6 +69,18 @@ public class SchoolOrganizationFcController extends BaseController
@PostMapping @PostMapping
public AjaxResult add(@RequestBody SchoolOrganizationFc schoolOrganizationFc) public AjaxResult add(@RequestBody SchoolOrganizationFc schoolOrganizationFc)
{ {
//先将file的前缀去掉
String file = schoolOrganizationFc.getFile();
if (file!=null){
String str ="";
String[] split = file.split(",");
for (int i = 0; i < split.length; i++) {
String substring = split[i].substring(8, split[i].length());
str = str+","+substring;
}
schoolOrganizationFc.setFile(str.substring(1, str.length()));
}
return toAjax(schoolOrganizationFcService.save(schoolOrganizationFc)); return toAjax(schoolOrganizationFcService.save(schoolOrganizationFc));
} }
......
package yangtz.cs.liu.campus.controller.organization; package yangtz.cs.liu.campus.controller.organization;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.ruoyi.common.utils.SecurityUtils; import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils; import com.ruoyi.common.utils.StringUtils;
...@@ -20,8 +21,15 @@ import com.ruoyi.common.enums.BusinessType; ...@@ -20,8 +21,15 @@ import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.core.page.TableDataInfo;
import yangtz.cs.liu.campus.domain.organization.SchoolOrganizationInfo; import yangtz.cs.liu.campus.domain.organization.SchoolOrganizationInfo;
import yangtz.cs.liu.campus.domain.organization.SchoolOrganizationMember; import yangtz.cs.liu.campus.domain.organization.SchoolOrganizationMember;
import yangtz.cs.liu.campus.domain.organization.SchoolOrganizationSignin;
import yangtz.cs.liu.campus.domain.schoolClass.SchoolClass;
import yangtz.cs.liu.campus.domain.student.SchoolStudentClassRelation;
import yangtz.cs.liu.campus.domain.student.SchoolStudentClasses;
import yangtz.cs.liu.campus.domain.student.SchoolStudentParent; import yangtz.cs.liu.campus.domain.student.SchoolStudentParent;
import yangtz.cs.liu.campus.service.organization.ISchoolOrganizationMemberService; import yangtz.cs.liu.campus.service.organization.ISchoolOrganizationMemberService;
import yangtz.cs.liu.campus.service.schoolClass.ISchoolClassService;
import yangtz.cs.liu.campus.service.student.ISchoolStudentClassRelationService;
import yangtz.cs.liu.campus.service.student.ISchoolStudentClassesService;
import yangtz.cs.liu.campus.service.student.ISchoolStudentParentService; import yangtz.cs.liu.campus.service.student.ISchoolStudentParentService;
import yangtz.cs.liu.campus.vo.organization.MemberListVo; import yangtz.cs.liu.campus.vo.organization.MemberListVo;
...@@ -44,6 +52,15 @@ public class SchoolOrganizationMemberController extends BaseController ...@@ -44,6 +52,15 @@ public class SchoolOrganizationMemberController extends BaseController
@Autowired @Autowired
private ISchoolStudentParentService schoolStudentParentService; private ISchoolStudentParentService schoolStudentParentService;
@Autowired
private ISchoolStudentClassesService schoolStudentClassesService;
@Autowired
private ISchoolStudentClassRelationService schoolStudentClassRelationService;
@Autowired
private ISchoolClassService schoolClassService;
/** /**
* 查询社团成员列表 * 查询社团成员列表
*/ */
...@@ -58,6 +75,21 @@ public class SchoolOrganizationMemberController extends BaseController ...@@ -58,6 +75,21 @@ public class SchoolOrganizationMemberController extends BaseController
.orderByDesc(SchoolOrganizationMember::getCreateTime); .orderByDesc(SchoolOrganizationMember::getCreateTime);
startPage(); startPage();
List<SchoolOrganizationMember> list = schoolOrganizationMemberService.list(wrapper); List<SchoolOrganizationMember> list = schoolOrganizationMemberService.list(wrapper);
//查询社团成员时 应根据当前这个学生 去动态查询那个班级
if (list!=null){
for (int i = 0; i < list.size(); i++) {
Long userId = list.get(i).getUserId();
LambdaQueryWrapper<SchoolStudentClassRelation> wrapper1 = Wrappers.lambdaQuery();
wrapper1.eq(SchoolStudentClassRelation::getStudentId,userId);
SchoolStudentClassRelation one = schoolStudentClassRelationService.getOne(wrapper1);
LambdaQueryWrapper<SchoolClass> wrapper2 = Wrappers.lambdaQuery();
wrapper2.eq(SchoolClass::getId,one.getClassId());
SchoolClass res = schoolClassService.getOne(wrapper2);
list.get(i).setGrade(res.getGradeName());
list.get(i).setClasses(res.getClassName());
}
}
return getDataTable(list); return getDataTable(list);
} }
...@@ -82,7 +114,8 @@ public class SchoolOrganizationMemberController extends BaseController ...@@ -82,7 +114,8 @@ public class SchoolOrganizationMemberController extends BaseController
// wrapper.eq(SchoolStudentParent::getIdCard,schoolOrganizationMember.getCardid()); // wrapper.eq(SchoolStudentParent::getIdCard,schoolOrganizationMember.getCardid());
// SchoolStudentParent one = schoolStudentParentService.getOne(wrapper); // SchoolStudentParent one = schoolStudentParentService.getOne(wrapper);
// schoolOrganizationMember.setUserId(one.getUserId()); // schoolOrganizationMember.setUserId(one.getUserId());
return toAjax(schoolOrganizationMemberService.save(schoolOrganizationMember)); boolean save = schoolOrganizationMemberService.save(schoolOrganizationMember);
return toAjax(save);
} }
/** /**
......
...@@ -106,7 +106,8 @@ public class SchoolOrganizationSigninController extends BaseController ...@@ -106,7 +106,8 @@ public class SchoolOrganizationSigninController extends BaseController
boolean save = schoolOrganizationMemberService.save(member); boolean save = schoolOrganizationMemberService.save(member);
System.out.println(save); System.out.println(save);
} }
return toAjax(schoolOrganizationSigninService.updateById(so)); boolean b = schoolOrganizationSigninService.updateById(so);
return toAjax(b);
} }
/** /**
......
...@@ -41,6 +41,7 @@ import yangtz.cs.liu.campus.domain.schoolDcwj.*; ...@@ -41,6 +41,7 @@ import yangtz.cs.liu.campus.domain.schoolDcwj.*;
import yangtz.cs.liu.campus.domain.schoolDuty.SchoolDuty; import yangtz.cs.liu.campus.domain.schoolDuty.SchoolDuty;
import yangtz.cs.liu.campus.domain.schoolgrade.SchoolGrade; import yangtz.cs.liu.campus.domain.schoolgrade.SchoolGrade;
import yangtz.cs.liu.campus.domain.student.SchoolStudent; import yangtz.cs.liu.campus.domain.student.SchoolStudent;
import yangtz.cs.liu.campus.mapper.schoolDcwj.SchoolDcwjPushMapper;
import yangtz.cs.liu.campus.service.schoolClass.ISchoolClassService; import yangtz.cs.liu.campus.service.schoolClass.ISchoolClassService;
import yangtz.cs.liu.campus.service.schoolDcwj.*; import yangtz.cs.liu.campus.service.schoolDcwj.*;
import yangtz.cs.liu.campus.service.schoolgrade.ISchoolGradeMentorService; import yangtz.cs.liu.campus.service.schoolgrade.ISchoolGradeMentorService;
...@@ -88,6 +89,7 @@ public class SchoolDcwjController extends BaseController { ...@@ -88,6 +89,7 @@ public class SchoolDcwjController extends BaseController {
@Autowired @Autowired
private ISchoolDcwjPushService pushService; private ISchoolDcwjPushService pushService;
@Value("${server.port}") @Value("${server.port}")
private String p; private String p;
...@@ -513,9 +515,122 @@ public class SchoolDcwjController extends BaseController { ...@@ -513,9 +515,122 @@ public class SchoolDcwjController extends BaseController {
ajax.put("titles", titlesVo); ajax.put("titles", titlesVo);
//获取内容 //获取内容
List<SchoolDcwjAnVo> list = schoolDcwjRyService.getSenateAnData(dcwjId, vo); // List<SchoolDcwjAnVo> list = schoolDcwjRyService.getSenateAnData(dcwjId, vo);
//判断是推送给教师还是家长
LambdaQueryWrapper<SchoolDcwjPush> pushLqw = new LambdaQueryWrapper<>();
pushLqw.eq(SchoolDcwjPush::getDcwjId,dcwjId);
List<SchoolDcwjPush> pushes = pushService.list(pushLqw);
if(DcwjType.PUSHT.equals(pushes.get(0).getPubType())){
//教师
//获取固定列的值,,获取到的list的id为ry表的id
startPage();
List<SchoolDcwjAnVo> list = schoolDcwjRyService.getTeaAnData(dcwjId, vo);
//获取问卷调查题目
LambdaQueryWrapper<SchoolDcwjNr> nrlqw = new LambdaQueryWrapper<>();
nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime);
List<SchoolDcwjNr> nrs = schoolDcwjNrService.list(nrlqw);
LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
lqw
.eq(SchoolDcwjAn::getDcwjId, dcwjId)
;
//a里要么有1个值,要么没有值
List<SchoolDcwjAn> a = schoolDcwjAnService.list(lqw);
//教师调查问卷回答的内容
for (SchoolDcwjAnVo anVo : list) {
List<SchoolDcwjAn> ans = new ArrayList<>();
//设置空对象,是为了,通俗的说就是站位,如果不占位的话,就目前来说,如果用户第一题没写,第二题写了,那么第2题的答案会显示在第1题的位置
SchoolDcwjAn entity = new SchoolDcwjAn();
//获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值
for(SchoolDcwjNr nr : nrs){
// LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
// lqw
// .eq(SchoolDcwjAn::getDcwjId, dcwjId)
// .eq(SchoolDcwjAn::getRyId, anVo.getId())
// .eq(SchoolDcwjAn::getNrId, nr.getId())
// ;
// //a里要么有1个值,要么没有值
// List<SchoolDcwjAn> a = anMapper.selectList(lqw);
for (SchoolDcwjAn schoolDcwjAn : a) {
if (schoolDcwjAn.getRyId().equals(anVo.getId()) && schoolDcwjAn.getNrId().equals(nr.getId())){
ans.add(schoolDcwjAn);
}else {
ans.add(entity);
}
}
// if(StringUtils.isNotNull(a) && a.size() > 0){
// ans.add(a.get(0));
// }else {
// ans.add(entity);
// }
}
anVo.setList(ans);
}
List<ViewDataVo> voList = schoolDcwjNrService.turnData(list);
ajax.put("data", voList);
ajax.put("total",getDataTable(list).getTotal());
return ajax;
}
//推送类型为学生家长
//获取固定列的值,,获取到的list的id为ry表的id
startPage();
List<SchoolDcwjAnVo> list = schoolDcwjRyService.getAnData1(dcwjId, vo);
//获取问卷调查题目
LambdaQueryWrapper<SchoolDcwjNr> nrlqw = new LambdaQueryWrapper<>();
nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime);
List<SchoolDcwjNr> nrs = schoolDcwjNrService.list(nrlqw);
LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
lqw
.eq(SchoolDcwjAn::getDcwjId, dcwjId)
;
//a里要么有1个值,要么没有值
List<SchoolDcwjAn> a = schoolDcwjAnService.list(lqw);
//学生家长调查问卷回答的内容
for (SchoolDcwjAnVo anVo : list) {
List<SchoolDcwjAn> ans = new ArrayList<>();
//设置空对象,是为了,通俗的说就是站位,如果不占位的话,就目前来说,如果用户第一题没写,第二题写了,那么第2题的答案会显示在第1题的位置
SchoolDcwjAn entity = new SchoolDcwjAn();
//获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值
for(SchoolDcwjNr nr : nrs){
// LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
// lqw
// .eq(SchoolDcwjAn::getDcwjId, dcwjId)
// .eq(SchoolDcwjAn::getRyId, anVo.getId())
// .eq(SchoolDcwjAn::getNrId, nr.getId())
// ;
// //a里要么有1个值,要么没有值
// List<SchoolDcwjAn> a = anMapper.selectList(lqw);
for (SchoolDcwjAn schoolDcwjAn : a) {
if (schoolDcwjAn.getRyId().equals(anVo.getId()) && schoolDcwjAn.getNrId().equals(nr.getId())){
ans.add(schoolDcwjAn);
}else {
ans.add(entity);
}
}
// if(StringUtils.isNotNull(a) && a.size() > 0){
// ans.add(a.get(0));
// }else {
// ans.add(entity);
// }
}
anVo.setList(ans);
}
List<ViewDataVo> voList = schoolDcwjNrService.turnData(list); List<ViewDataVo> voList = schoolDcwjNrService.turnData(list);
ajax.put("data", voList); ajax.put("data", voList);
ajax.put("total",getDataTable(list).getTotal());
return ajax; return ajax;
} }
......
...@@ -122,7 +122,9 @@ public class StudentStatusController { ...@@ -122,7 +122,9 @@ public class StudentStatusController {
map.put("avatar", image); map.put("avatar", image);
} }
map.put("idCard",baseInfo.getIdCard()); map.put("idCard",baseInfo.getIdCard());
map.put("birthday",new SimpleDateFormat("yyyy-MM-dd").format(baseInfo.getBirthday())); if (StringUtils.isNotNull(baseInfo.getBirthday())){
map.put("birthday",new SimpleDateFormat("yyyy-MM-dd").format(baseInfo.getBirthday()));
}
map.put("nation",baseInfo.getNation()); map.put("nation",baseInfo.getNation());
map.put("stuTelephone",baseInfo.getStuTelephone()); map.put("stuTelephone",baseInfo.getStuTelephone());
map.put("postalCode",baseInfo.getPostalCode()); map.put("postalCode",baseInfo.getPostalCode());
...@@ -285,7 +287,9 @@ public class StudentStatusController { ...@@ -285,7 +287,9 @@ public class StudentStatusController {
}else{ }else{
map.put("sex","女"); map.put("sex","女");
} }
map.put("birthday",new SimpleDateFormat("yyyy-MM-dd").format(baseInfo.getBirthday())); if (StringUtils.isNotNull(baseInfo.getBirthday())){
map.put("birthday",new SimpleDateFormat("yyyy-MM-dd").format(baseInfo.getBirthday()));
}
map.put("idCard",baseInfo.getIdCard()); map.put("idCard",baseInfo.getIdCard());
// 图片 // 图片
//路径去掉/profile //路径去掉/profile
......
...@@ -238,49 +238,65 @@ public class SchoolTeacherController extends BaseController { ...@@ -238,49 +238,65 @@ public class SchoolTeacherController extends BaseController {
//查询设备号 //查询设备号
if(StringUtils.isNotNull(schoolTeacher.getDeviceNum())){ if(StringUtils.isNotNull(schoolTeacher.getDeviceNum())){
LambdaQueryWrapper<SchoolTeacher> lqw1 = new LambdaQueryWrapper<>(); LambdaQueryWrapper<SchoolTeacher> lqw1 = new LambdaQueryWrapper<>();
lqw1.eq(SchoolTeacher::getDeviceNum,schoolTeacher.getDeviceNum()); lqw1.notIn(SchoolTeacher::getId,schoolTeacher.getId())
.eq(SchoolTeacher::getDeviceNum,schoolTeacher.getDeviceNum());
SchoolTeacher teacher = schoolTeacherService.getOne(lqw1); SchoolTeacher teacher = schoolTeacherService.getOne(lqw1);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) { if (StringUtils.isNotNull(teacher)){
}else if(schoolTeacher.getDeviceNum().equals(teacher.getDeviceNum())){
throw new ServiceException("设备号已存在"); throw new ServiceException("设备号已存在");
} }
// if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
//
// }else if(schoolTeacher.getDeviceNum().equals(teacher.getDeviceNum())){
// throw new ServiceException("设备号已存在");
// }
} }
//查询身份证号 //查询身份证号
if(StringUtils.isNotNull(schoolTeacher.getIdCard())){ if(StringUtils.isNotNull(schoolTeacher.getIdCard())){
LambdaQueryWrapper<SchoolTeacher> lqw2 = new LambdaQueryWrapper<>(); LambdaQueryWrapper<SchoolTeacher> lqw2 = new LambdaQueryWrapper<>();
lqw2.eq(SchoolTeacher::getIdCard,schoolTeacher.getIdCard()); lqw2.notIn(SchoolTeacher::getId,schoolTeacher.getId())
.eq(SchoolTeacher::getIdCard,schoolTeacher.getIdCard());
SchoolTeacher teacher = schoolTeacherService.getOne(lqw2); SchoolTeacher teacher = schoolTeacherService.getOne(lqw2);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) { if (StringUtils.isNotNull(teacher)){
}else if(schoolTeacher.getIdCard().equals(teacher.getIdCard())){
throw new ServiceException("身份证号已存在"); throw new ServiceException("身份证号已存在");
} }
// if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
//
// }else if(schoolTeacher.getIdCard().equals(teacher.getIdCard())){
// throw new ServiceException("身份证号已存在");
// }
} }
//查询编号 //查询编号
if(StringUtils.isNotNull(schoolTeacher.getTeacherCode())){ if(StringUtils.isNotNull(schoolTeacher.getTeacherCode())){
LambdaQueryWrapper<SchoolTeacher> lqw3 = new LambdaQueryWrapper<>(); LambdaQueryWrapper<SchoolTeacher> lqw3 = new LambdaQueryWrapper<>();
lqw3.eq(SchoolTeacher::getTeacherCode,schoolTeacher.getTeacherCode()); lqw3.notIn(SchoolTeacher::getId,schoolTeacher.getId())
.eq(SchoolTeacher::getTeacherCode,schoolTeacher.getTeacherCode());
SchoolTeacher teacher = schoolTeacherService.getOne(lqw3); SchoolTeacher teacher = schoolTeacherService.getOne(lqw3);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) { if (StringUtils.isNotNull(teacher)){
}else if(schoolTeacher.getTeacherCode().equals(teacher.getTeacherCode())){
throw new ServiceException("编号已存在"); throw new ServiceException("编号已存在");
} }
// if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
//
// }else if(schoolTeacher.getTeacherCode().equals(teacher.getTeacherCode())){
// throw new ServiceException("编号已存在");
// }
} }
//查询电话号码 //查询电话号码
if(StringUtils.isNotNull(schoolTeacher.getTeacherCode())){ if(StringUtils.isNotNull(schoolTeacher.getTeacherCode())){
LambdaQueryWrapper<SchoolTeacher> lqw4 = new LambdaQueryWrapper<>(); LambdaQueryWrapper<SchoolTeacher> lqw4 = new LambdaQueryWrapper<>();
lqw4.eq(SchoolTeacher::getTeacherTel,schoolTeacher.getTeacherTel()); lqw4.notIn(SchoolTeacher::getId,schoolTeacher.getId())
.eq(SchoolTeacher::getTeacherTel,schoolTeacher.getTeacherTel());
SchoolTeacher teacher = schoolTeacherService.getOne(lqw4); SchoolTeacher teacher = schoolTeacherService.getOne(lqw4);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) { if (StringUtils.isNotNull(teacher)){
}else if(schoolTeacher.getTeacherTel().equals(teacher.getTeacherTel())){
throw new ServiceException("电话号码已存在"); throw new ServiceException("电话号码已存在");
} }
// if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
//
// }else if(schoolTeacher.getTeacherTel().equals(teacher.getTeacherTel())){
// throw new ServiceException("电话号码已存在");
// }
} }
......
...@@ -9,6 +9,7 @@ import com.ruoyi.common.utils.poi.ExcelUtil; ...@@ -9,6 +9,7 @@ import com.ruoyi.common.utils.poi.ExcelUtil;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import yangtz.cs.liu.campus.controller.A;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFiles; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFiles;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice;
import yangtz.cs.liu.campus.service.teacherFiles.ITeacherFilesService; import yangtz.cs.liu.campus.service.teacherFiles.ITeacherFilesService;
...@@ -60,12 +61,34 @@ public class TeacherFilesController extends BaseController ...@@ -60,12 +61,34 @@ public class TeacherFilesController extends BaseController
} }
/** /**
* 老师查看自己的档案任务 * 新增教师档案
* @param
* @return
*/
@GetMapping("/teacherAdd/{ids}")
public AjaxResult teacherAdd(Long[] ids){
return AjaxResult.success(teacherFilesService.teacherAdd(ids));
}
/**
* 获取教师列表
* @param
* @return
*/
@GetMapping("/getTeacherRocer/{tId}")
public AjaxResult getTeacherRocer(@PathVariable("tId") String tId){
return AjaxResult.success(teacherFilesService.getTeacherRocer(tId));
}
/**
*
* @param userId
* @param
* @return
*/ */
@GetMapping("getTeachList/{userId}") @GetMapping("getTeachList/{userId}")
public TableDataInfo teachList(@PathVariable("userId") Long userId){ public TableDataInfo teachList(@PathVariable("userId") Long userId,TeacherFilesNotice teacherFilesNotice){
startPage(); startPage();
List<TeacherFilesNotice> teacherFilesNotices = teacherFilesService.selctTeacherByUserId(userId); List<TeacherFilesNotice> teacherFilesNotices = teacherFilesService.selctTeacherByUserId(userId,teacherFilesNotice);
return getDataTable(teacherFilesNotices); return getDataTable(teacherFilesNotices);
} }
...@@ -127,7 +150,6 @@ public class TeacherFilesController extends BaseController ...@@ -127,7 +150,6 @@ public class TeacherFilesController extends BaseController
return toAjax(teacherFilesService.deleteTeacherFilesByIds(ids)); return toAjax(teacherFilesService.deleteTeacherFilesByIds(ids));
} }
/** /**
* 教师档案同步 * 教师档案同步
*/ */
...@@ -139,27 +161,34 @@ public class TeacherFilesController extends BaseController ...@@ -139,27 +161,34 @@ public class TeacherFilesController extends BaseController
return toAjax(teacherFilesService.synchronous(id)); return toAjax(teacherFilesService.synchronous(id));
} }
@PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')") @PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')")
@Log(title = "教师档案审核通过", businessType = BusinessType.UPDATE) @Log(title = "教师档案审核通过", businessType = BusinessType.UPDATE)
@PutMapping("/passThrough/{id}") @PutMapping("/passThrough/{id}")
public AjaxResult passThrough(@PathVariable("id") Long id) public AjaxResult passThrough(@PathVariable("id") Long[] id)
{ {
Integer date = null;
for (int i = 0 ; i< id.length ; i++){
TeacherFiles teacherFiles = new TeacherFiles(); TeacherFiles teacherFiles = new TeacherFiles();
teacherFiles.setId(id); teacherFiles.setId(id[i]);
teacherFiles.setState("5"); teacherFiles.setState("5");
return toAjax(teacherFilesService.updateTeacherFiles(teacherFiles)); date = teacherFilesService.updateTeacherFiles(teacherFiles);
}
return toAjax(date);
} }
@PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')") @PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')")
@Log(title = "教师档案审核驳回", businessType = BusinessType.UPDATE) @Log(title = "教师档案审核驳回", businessType = BusinessType.UPDATE)
@PutMapping("/reject/{id}") @PutMapping("/reject/{id}")
public AjaxResult reject(@PathVariable("id") Long id) public AjaxResult reject(@PathVariable("id") Long[] id)
{ {
TeacherFiles teacherFiles = new TeacherFiles(); Integer date = null;
teacherFiles.setId(id); for (int i = 0 ; i< id.length ; i++){
teacherFiles.setState("9"); TeacherFiles teacherFiles = new TeacherFiles();
return toAjax(teacherFilesService.updateTeacherFiles(teacherFiles)); teacherFiles.setId(id[i]);
teacherFiles.setState("9");
date = teacherFilesService.updateTeacherFiles(teacherFiles);
}
return toAjax(date);
} }
@PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')") @PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')")
......
...@@ -3,6 +3,7 @@ package yangtz.cs.liu.campus.domain.organization; ...@@ -3,6 +3,7 @@ package yangtz.cs.liu.campus.domain.organization;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
import com.core.domain.OurBaseEntity; import com.core.domain.OurBaseEntity;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data; import lombok.Data;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
...@@ -13,12 +14,11 @@ import com.ruoyi.common.annotation.Excel; ...@@ -13,12 +14,11 @@ import com.ruoyi.common.annotation.Excel;
* @date 2023-09-06 * @date 2023-09-06
*/ */
@Data @Data
public class SchoolOrganizationSignin extends OurBaseEntity public class SchoolOrganizationSignin extends BaseEntity
{ {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
/** id */
@TableId(value = "id", type = IdType.AUTO) @TableId(value = "id", type = IdType.AUTO)
@Excel(name = "id")
private Long id; private Long id;
/** 姓名 */ /** 姓名 */
......
package yangtz.cs.liu.campus.domain.schoolEquipment; package yangtz.cs.liu.campus.domain.schoolEquipment;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
import java.math.BigDecimal;
import java.util.Date; import java.util.Date;
import com.core.domain.OurBaseEntity; import com.core.domain.OurBaseEntity;
...@@ -52,13 +54,12 @@ public class SchoolCirculation extends OurBaseEntity ...@@ -52,13 +54,12 @@ public class SchoolCirculation extends OurBaseEntity
/** 接收人 */ /** 接收人 */
private String receivedBy; private String receivedBy;
/** 预计使用时间 */ /** 预计使用期限 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date yjuseTime; private Date yjuseTime;
/** 实际使用时间 */ /** 实际使用时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") private String sjuseTime;
private Date sjuseTime;
/** 备注 */ /** 备注 */
private String remark; private String remark;
......
...@@ -48,6 +48,10 @@ public class SchoolEquipmentRepair extends OurBaseEntity ...@@ -48,6 +48,10 @@ public class SchoolEquipmentRepair extends OurBaseEntity
/** 修理人 */ /** 修理人 */
private String repairName; private String repairName;
/**
* 地点
*/
private String place;
/** 修理人联系方式 */ /** 修理人联系方式 */
private Long repairPhone; private Long repairPhone;
......
...@@ -33,7 +33,6 @@ public class SchoolGradeMentor extends OurBaseEntity { ...@@ -33,7 +33,6 @@ public class SchoolGradeMentor extends OurBaseEntity {
private String type; private String type;
/** 职务 */ /** 职务 */
@NotBlank(message = "职务不能为空")
private String teacherPost; private String teacherPost;
/** 学科组(1物理学科组,2化学学科组,3生物学科组) */ /** 学科组(1物理学科组,2化学学科组,3生物学科组) */
......
...@@ -40,9 +40,14 @@ public class SchoolTeacherWages extends OurBaseEntity { ...@@ -40,9 +40,14 @@ public class SchoolTeacherWages extends OurBaseEntity {
private BigDecimal basePay; private BigDecimal basePay;
/** /**
* 教师电话
*/
@Excel(name = "教师联系方式")
private String teacherTel;
/**
* 身份证号 * 身份证号
*/ */
@Excel(name = "身份证号")
private String idCard; private String idCard;
/** /**
......
...@@ -46,4 +46,8 @@ public class ShebeiJy extends OurBaseEntity { ...@@ -46,4 +46,8 @@ public class ShebeiJy extends OurBaseEntity {
@Excel(name = "借用期限") @Excel(name = "借用期限")
private int deadline; private int deadline;
//归还状态(1已归还,0未归还)
@Excel(name = "归还状态", readConverterExp = "1=已归还,0=未归还", combo = {"已归还","未归还"})
private String returnState;
} }
...@@ -52,4 +52,8 @@ public class TeacherJy extends OurBaseEntity { ...@@ -52,4 +52,8 @@ public class TeacherJy extends OurBaseEntity {
@Excel(name = "借用期限") @Excel(name = "借用期限")
private int deadline; private int deadline;
//归还状态(1已归还,0未归还)
@Excel(name = "归还状态", readConverterExp = "1=已归还,0=未归还", combo = {"已归还","未归还"})
private String returnState;
} }
package yangtz.cs.liu.campus.domain.teacherFiles;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
/**
* 教师档案删除对象 TeacherFilesDeletRecord
*
* @author ruoyi
* @date 2023-09-05
*/
@Data
public class TeacherFilesDeletRecord extends BaseEntity
{
private static final long serialVersionUID = 1L;
/**
* id
*/
private Long id;
/**
* 用户id
*/
private Long userId;
/**
* 通知id
*/
private String tId;
/**
* 级部id
*/
private Long gId;
/**
* 身份证
*/
private String tel;
/**
* 级部
*/
private String gruoName;
/**
*用户名称
*/
private String userName;
}
...@@ -50,9 +50,12 @@ public interface CirculationMapper extends BaseMapper<SchoolCirculation> { ...@@ -50,9 +50,12 @@ public interface CirculationMapper extends BaseMapper<SchoolCirculation> {
SchoolCirculationVo getSchoolCirculationVoById(@Param("id")Long id); SchoolCirculationVo getSchoolCirculationVoById(@Param("id")Long id);
@Select("SELECT sc.id,el.encode,sc.equipment_id,el.equipment_name,el.model,sc.borrow_time,sc.borrow_by_id,sc.borrow_by,sc.purpose,sc.deadline,sc.return_state,el.is_lend,sc.return_time,sc.return_equipment_condition,sc.received_by_id,sc.received_by,sc.yjuse_time,sc.sjuse_time,sc.remark from school_equipment_ledger el LEFT JOIN school_circulation sc on el.id = sc.equipment_id \n" @Select("SELECT sc.id,el.encode,sc.equipment_id,el.equipment_name,el.model,sc.borrow_time,sc.borrow_by_id,sc.borrow_by,sc.purpose,sc.deadline,sc.return_state,sc.yjuse_time,sc.sjuse_time,el.is_lend,sc.return_time,sc.return_equipment_condition,sc.received_by_id,sc.received_by,sc.yjuse_time,sc.sjuse_time,sc.remark from school_equipment_ledger el LEFT JOIN school_circulation sc on el.id = sc.equipment_id \n"
+ "WHERE el.encode = #{encode} AND sc.return_state=0 and el.del_flag=0") + "WHERE el.encode = #{encode} AND sc.return_state=0 and el.del_flag=0")
SchoolCirculationVo getSchoolCirculationVoByenCode(@Param("encode")String encode); SchoolCirculationVo getSchoolCirculationVoByenCode(@Param("encode")String encode);
@Select("SELECT sc.id,el.encode,sc.equipment_id,el.equipment_name,sc.return_equipment_condition ,el.model,sc.borrow_time,sc.borrow_by_id,sc.borrow_by,sc.purpose,sc.deadline,sc.return_state,el.is_lend,sc.return_time,sc.return_equipment_condition,sc.received_by_id,sc.received_by,sc.yjuse_time,sc.sjuse_time,sc.remark from school_circulation sc LEFT JOIN school_equipment_ledger el on el.id = sc.equipment_id WHERE sc.id=#{id} and el.del_flag=0")
SchoolCirculationVo getReturningEquipmentById(@Param("id")String id);
} }
...@@ -35,4 +35,11 @@ public interface EquipmentLedgerMapper extends BaseMapper<SchoolEquipmentLedger> ...@@ -35,4 +35,11 @@ public interface EquipmentLedgerMapper extends BaseMapper<SchoolEquipmentLedger>
* @return * @return
*/ */
List<SchoolEquipmentLedger> selectSchoolEquipmentLedgerListGr(SchoolEquipmentLedgerVo schoolEquipmentLedgerVo); List<SchoolEquipmentLedger> selectSchoolEquipmentLedgerListGr(SchoolEquipmentLedgerVo schoolEquipmentLedgerVo);
/**
* 打印设备条码信息
* @param ids
* @return
*/
List<Map<String, Object>> getEquipmentledger(Long[] ids);
} }
...@@ -14,7 +14,7 @@ import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolReceiveQuery; ...@@ -14,7 +14,7 @@ import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolReceiveQuery;
public interface EquipmentRepairMapper extends BaseMapper<SchoolEquipmentRepair> { public interface EquipmentRepairMapper extends BaseMapper<SchoolEquipmentRepair> {
@Select("SELECT er.id,er.equipment_id,el.encode,el.equipment_name,er.dispose_state,el.model,el.date_of_production,el.place ,\n" @Select("SELECT er.id,er.equipment_id,el.encode,el.equipment_name,er.dispose_state,er.place,el.model,el.date_of_production,el.place ,\n"
+ "el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,\n" + "el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,\n"
+ "er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark\n" + "er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark\n"
+ "FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id WHERE er.id=#{id} and er.del_flag=0") + "FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id WHERE er.id=#{id} and er.del_flag=0")
...@@ -24,7 +24,7 @@ public interface EquipmentRepairMapper extends BaseMapper<SchoolEquipmentRepair> ...@@ -24,7 +24,7 @@ public interface EquipmentRepairMapper extends BaseMapper<SchoolEquipmentRepair>
public List<SchoolEquipmentRepairVo> getMaintenanceList(SchoolReceiveQuery schoolReceiveQuery); public List<SchoolEquipmentRepairVo> getMaintenanceList(SchoolReceiveQuery schoolReceiveQuery);
@Select("SELECT er.id,er.equipment_id,el.encode,er.dispose_state,el.equipment_name,el.model,el.date_of_production,el.place ,\n" @Select("SELECT er.id,er.equipment_id,el.encode,er.dispose_state,el.equipment_name,el.model,el.date_of_production,el.place ,\n"
+ "el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,\n" + "el.classification_code,er.report_repair_time,er.place,er.report_repair_id,er.report_repair,er.problem,\n"
+ "er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark\n" + "er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark\n"
+ "FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id where er.del_flag=0 ") + "FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id where er.del_flag=0 ")
public List<SchoolEquipmentRepairVo> getlist(); public List<SchoolEquipmentRepairVo> getlist();
......
...@@ -13,4 +13,11 @@ public interface SchoolTeacherWagesMapper extends BaseMapper<SchoolTeacherWages> ...@@ -13,4 +13,11 @@ public interface SchoolTeacherWagesMapper extends BaseMapper<SchoolTeacherWages>
List<SchoolTeacherWages> query(SchoolTeacherWages schoolTeacherWages); List<SchoolTeacherWages> query(SchoolTeacherWages schoolTeacherWages);
/**
* 批量新增教师工资
* @param list
* @return
*/
int batchInsertTeacherWages(List<SchoolTeacherWages> list);
} }
package yangtz.cs.liu.campus.mapper.teacherFiles;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFiles;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesDeletRecord;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesVO;
import java.util.List;
import java.util.Map;
/**
* 教师档案删除记录mapper
*
* @author ruoyi
* @date 2023-09-06
*/
@Mapper
public interface TeacherFilesDeletRecordMapper
{
/**
* 添加记录
*/
@Insert("insert into teacher_file_delet_record (user_id,tel,gruo_name,user_name,t_id,g_id) VALUES (#{userId},#{tel},#{gruoName},#{userName},#{tId},#{gId}) ")
public Integer addTeacherFilesDeletRecord(TeacherFilesDeletRecord teacherFilesDeletRecord);
/**
* 删除记录
*/
@Delete("delete from teacher_file_delet_record where id =#{id} ")
public Integer deletRecord(Long id);
/**
* 查询老师
* @param tId
* @return
*/
@Select("select * from teacher_file_delet_record where t_id =#{tId} ")
public List<TeacherFilesDeletRecord> getTeacherRocer(String tId);
@Select("select * from teacher_file_delet_record where id =#{id} ")
public TeacherFilesDeletRecord getByid(Long id);
}
...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.mapper.teacherFiles; ...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.mapper.teacherFiles;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select; import org.apache.ibatis.annotations.Select;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFiles;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNoticeTotal; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNoticeTotal;
import yangtz.cs.liu.campus.vo.teacherFiles.SchoolClassByGradeVo; import yangtz.cs.liu.campus.vo.teacherFiles.SchoolClassByGradeVo;
...@@ -42,8 +43,7 @@ public interface TeacherFilesNoticeMapper ...@@ -42,8 +43,7 @@ public interface TeacherFilesNoticeMapper
public int insertTeacherFilesNotice(TeacherFilesNotice teacherFilesNotice); public int insertTeacherFilesNotice(TeacherFilesNotice teacherFilesNotice);
@Select("SELECT fn.*,tf.state,tf.id as fId from teacher_files tf LEFT JOIN teacher_files_notice fn on fn.id= tf.notice_id WHERE tf.teacher_id = #{userId} and fn.notice_state = 2") public List<TeacherFilesNotice> selctTeacherByUserId(@Param("userId") Long userId, @Param("teacherFiles") TeacherFilesNotice teacherFiles);
public List<TeacherFilesNotice> selctTeacherByUserId(Long userId);
/** /**
* 修改教师档案通知 * 修改教师档案通知
......
...@@ -582,6 +582,7 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch ...@@ -582,6 +582,7 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch
@Override @Override
public List<ViewDataVo> turnData(List<SchoolDcwjAnVo> list) { public List<ViewDataVo> turnData(List<SchoolDcwjAnVo> list) {
List<ViewDataVo> voList = new ArrayList<>(); List<ViewDataVo> voList = new ArrayList<>();
List<SchoolDcwjNr> schoolDcwjNrs = schoolDcwjNrMapper.selectSchoolDcwjNrList(new SchoolDcwjNr());
for (SchoolDcwjAnVo anVo : list) { for (SchoolDcwjAnVo anVo : list) {
ViewDataVo vo = new ViewDataVo(); ViewDataVo vo = new ViewDataVo();
BeanUtils.copyProperties(anVo, vo); BeanUtils.copyProperties(anVo, vo);
...@@ -591,313 +592,623 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch ...@@ -591,313 +592,623 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch
i++; i++;
continue; continue;
} }
SchoolDcwjNr nr = schoolDcwjNrMapper.selectById(an.getNrId()); // SchoolDcwjNr nr = schoolDcwjNrMapper.selectById(an.getNrId());
DataTVo tVo = new DataTVo(); for (SchoolDcwjNr nr : schoolDcwjNrs) {
tVo.setDatas(an.getUserAnswer()); if (nr.getId().equals(an.getNrId())){
tVo.setType(nr.getNrLx()); DataTVo tVo = new DataTVo();
switch (i) { tVo.setDatas(an.getUserAnswer());
case 1: tVo.setType(nr.getNrLx());
vo.setT1(tVo); switch (i) {
break; case 1:
case 2: vo.setT1(tVo);
vo.setT2(tVo); break;
break; case 2:
case 3: vo.setT2(tVo);
vo.setT3(tVo); break;
break; case 3:
case 4: vo.setT3(tVo);
vo.setT4(tVo); break;
break; case 4:
case 5: vo.setT4(tVo);
vo.setT5(tVo); break;
break; case 5:
case 6: vo.setT5(tVo);
vo.setT6(tVo); break;
break; case 6:
case 7: vo.setT6(tVo);
vo.setT7(tVo); break;
break; case 7:
case 8: vo.setT7(tVo);
vo.setT8(tVo); break;
break; case 8:
case 9: vo.setT8(tVo);
vo.setT9(tVo); break;
break; case 9:
case 10: vo.setT9(tVo);
vo.setT10(tVo); break;
break; case 10:
case 11: vo.setT10(tVo);
vo.setT11(tVo); break;
break; case 11:
case 12: vo.setT11(tVo);
vo.setT12(tVo); break;
break; case 12:
case 13: vo.setT12(tVo);
vo.setT13(tVo); break;
break; case 13:
case 14: vo.setT13(tVo);
vo.setT14(tVo); break;
break; case 14:
case 15: vo.setT14(tVo);
vo.setT15(tVo); break;
break; case 15:
case 16: vo.setT15(tVo);
vo.setT16(tVo); break;
break; case 16:
case 17: vo.setT16(tVo);
vo.setT17(tVo); break;
break; case 17:
case 18: vo.setT17(tVo);
vo.setT18(tVo); break;
break; case 18:
case 19: vo.setT18(tVo);
vo.setT19(tVo); break;
break; case 19:
case 20: vo.setT19(tVo);
vo.setT20(tVo); break;
break; case 20:
case 21: vo.setT20(tVo);
vo.setT21(tVo); break;
break; case 21:
case 22: vo.setT21(tVo);
vo.setT22(tVo); break;
break; case 22:
case 23: vo.setT22(tVo);
vo.setT23(tVo); break;
break; case 23:
case 24: vo.setT23(tVo);
vo.setT24(tVo); break;
break; case 24:
case 25: vo.setT24(tVo);
vo.setT25(tVo); break;
break; case 25:
case 26: vo.setT25(tVo);
vo.setT26(tVo); break;
break; case 26:
case 27: vo.setT26(tVo);
vo.setT27(tVo); break;
break; case 27:
case 28: vo.setT27(tVo);
vo.setT28(tVo); break;
break; case 28:
case 29: vo.setT28(tVo);
vo.setT29(tVo); break;
break; case 29:
case 30: vo.setT29(tVo);
vo.setT30(tVo); break;
break; case 30:
case 31: vo.setT30(tVo);
vo.setT31(tVo); break;
break; case 31:
case 32: vo.setT31(tVo);
vo.setT32(tVo); break;
break; case 32:
case 33: vo.setT32(tVo);
vo.setT33(tVo); break;
break; case 33:
case 34: vo.setT33(tVo);
vo.setT34(tVo); break;
break; case 34:
case 35: vo.setT34(tVo);
vo.setT35(tVo); break;
break; case 35:
case 36: vo.setT35(tVo);
vo.setT36(tVo); break;
break; case 36:
case 37: vo.setT36(tVo);
vo.setT37(tVo); break;
break; case 37:
case 38: vo.setT37(tVo);
vo.setT38(tVo); break;
break; case 38:
case 39: vo.setT38(tVo);
vo.setT39(tVo); break;
break; case 39:
case 40: vo.setT39(tVo);
vo.setT40(tVo); break;
break; case 40:
case 41: vo.setT40(tVo);
vo.setT41(tVo); break;
break; case 41:
case 42: vo.setT41(tVo);
vo.setT42(tVo); break;
break; case 42:
case 43: vo.setT42(tVo);
vo.setT43(tVo); break;
break; case 43:
case 44: vo.setT43(tVo);
vo.setT44(tVo); break;
break; case 44:
case 45: vo.setT44(tVo);
vo.setT45(tVo); break;
break; case 45:
case 46: vo.setT45(tVo);
vo.setT46(tVo); break;
break; case 46:
case 47: vo.setT46(tVo);
vo.setT47(tVo); break;
break; case 47:
case 48: vo.setT47(tVo);
vo.setT48(tVo); break;
break; case 48:
case 49: vo.setT48(tVo);
vo.setT49(tVo); break;
break; case 49:
case 50: vo.setT49(tVo);
vo.setT50(tVo); break;
break; case 50:
case 51: vo.setT50(tVo);
vo.setT51(tVo); break;
break; case 51:
case 52: vo.setT51(tVo);
vo.setT52(tVo); break;
break; case 52:
case 53: vo.setT52(tVo);
vo.setT53(tVo); break;
break; case 53:
case 54: vo.setT53(tVo);
vo.setT54(tVo); break;
break; case 54:
case 55: vo.setT54(tVo);
vo.setT55(tVo); break;
break; case 55:
case 56: vo.setT55(tVo);
vo.setT56(tVo); break;
break; case 56:
case 57: vo.setT56(tVo);
vo.setT57(tVo); break;
break; case 57:
case 58: vo.setT57(tVo);
vo.setT58(tVo); break;
break; case 58:
case 59: vo.setT58(tVo);
vo.setT59(tVo); break;
break; case 59:
case 60: vo.setT59(tVo);
vo.setT60(tVo); break;
break; case 60:
case 61: vo.setT60(tVo);
vo.setT61(tVo); break;
break; case 61:
case 62: vo.setT61(tVo);
vo.setT62(tVo); break;
break; case 62:
case 63: vo.setT62(tVo);
vo.setT63(tVo); break;
break; case 63:
case 64: vo.setT63(tVo);
vo.setT64(tVo); break;
break; case 64:
case 65: vo.setT64(tVo);
vo.setT65(tVo); break;
break; case 65:
case 66: vo.setT65(tVo);
vo.setT66(tVo); break;
break; case 66:
case 67: vo.setT66(tVo);
vo.setT67(tVo); break;
break; case 67:
case 68: vo.setT67(tVo);
vo.setT68(tVo); break;
break; case 68:
case 69: vo.setT68(tVo);
vo.setT69(tVo); break;
break; case 69:
case 70: vo.setT69(tVo);
vo.setT70(tVo); break;
break; case 70:
case 71: vo.setT70(tVo);
vo.setT71(tVo); break;
break; case 71:
case 72: vo.setT71(tVo);
vo.setT72(tVo); break;
break; case 72:
case 73: vo.setT72(tVo);
vo.setT73(tVo); break;
break; case 73:
case 74: vo.setT73(tVo);
vo.setT74(tVo); break;
break; case 74:
case 75: vo.setT74(tVo);
vo.setT75(tVo); break;
break; case 75:
case 76: vo.setT75(tVo);
vo.setT76(tVo); break;
break; case 76:
case 77: vo.setT76(tVo);
vo.setT77(tVo); break;
break; case 77:
case 78: vo.setT77(tVo);
vo.setT78(tVo); break;
break; case 78:
case 79: vo.setT78(tVo);
vo.setT79(tVo); break;
break; case 79:
case 80: vo.setT79(tVo);
vo.setT80(tVo); break;
break; case 80:
case 81: vo.setT80(tVo);
vo.setT81(tVo); break;
break; case 81:
case 82: vo.setT81(tVo);
vo.setT82(tVo); break;
break; case 82:
case 83: vo.setT82(tVo);
vo.setT83(tVo); break;
break; case 83:
case 84: vo.setT83(tVo);
vo.setT84(tVo); break;
break; case 84:
case 85: vo.setT84(tVo);
vo.setT85(tVo); break;
break; case 85:
case 86: vo.setT85(tVo);
vo.setT86(tVo); break;
break; case 86:
case 87: vo.setT86(tVo);
vo.setT87(tVo); break;
break; case 87:
case 88: vo.setT87(tVo);
vo.setT88(tVo); break;
break; case 88:
case 89: vo.setT88(tVo);
vo.setT89(tVo); break;
break; case 89:
case 90: vo.setT89(tVo);
vo.setT90(tVo); break;
break; case 90:
case 91: vo.setT90(tVo);
vo.setT91(tVo); break;
break; case 91:
case 92: vo.setT91(tVo);
vo.setT92(tVo); break;
break; case 92:
case 93: vo.setT92(tVo);
vo.setT93(tVo); break;
break; case 93:
case 94: vo.setT93(tVo);
vo.setT94(tVo); break;
break; case 94:
case 95: vo.setT94(tVo);
vo.setT95(tVo); break;
break; case 95:
case 96: vo.setT95(tVo);
vo.setT96(tVo); break;
break; case 96:
case 97: vo.setT96(tVo);
vo.setT97(tVo); break;
break; case 97:
case 98: vo.setT97(tVo);
vo.setT98(tVo); break;
break; case 98:
case 99: vo.setT98(tVo);
vo.setT99(tVo); break;
break; case 99:
case 100: vo.setT99(tVo);
vo.setT100(tVo); break;
break; case 100:
vo.setT100(tVo);
break;
}
i++;
}
} }
i++; // DataTVo tVo = new DataTVo();
// tVo.setDatas(an.getUserAnswer());
// tVo.setType(nr.getNrLx());
// switch (i) {
// case 1:
// vo.setT1(tVo);
// break;
// case 2:
// vo.setT2(tVo);
// break;
// case 3:
// vo.setT3(tVo);
// break;
// case 4:
// vo.setT4(tVo);
// break;
// case 5:
// vo.setT5(tVo);
// break;
// case 6:
// vo.setT6(tVo);
// break;
// case 7:
// vo.setT7(tVo);
// break;
// case 8:
// vo.setT8(tVo);
// break;
// case 9:
// vo.setT9(tVo);
// break;
// case 10:
// vo.setT10(tVo);
// break;
// case 11:
// vo.setT11(tVo);
// break;
// case 12:
// vo.setT12(tVo);
// break;
// case 13:
// vo.setT13(tVo);
// break;
// case 14:
// vo.setT14(tVo);
// break;
// case 15:
// vo.setT15(tVo);
// break;
// case 16:
// vo.setT16(tVo);
// break;
// case 17:
// vo.setT17(tVo);
// break;
// case 18:
// vo.setT18(tVo);
// break;
// case 19:
// vo.setT19(tVo);
// break;
// case 20:
// vo.setT20(tVo);
// break;
// case 21:
// vo.setT21(tVo);
// break;
// case 22:
// vo.setT22(tVo);
// break;
// case 23:
// vo.setT23(tVo);
// break;
// case 24:
// vo.setT24(tVo);
// break;
// case 25:
// vo.setT25(tVo);
// break;
// case 26:
// vo.setT26(tVo);
// break;
// case 27:
// vo.setT27(tVo);
// break;
// case 28:
// vo.setT28(tVo);
// break;
// case 29:
// vo.setT29(tVo);
// break;
// case 30:
// vo.setT30(tVo);
// break;
// case 31:
// vo.setT31(tVo);
// break;
// case 32:
// vo.setT32(tVo);
// break;
// case 33:
// vo.setT33(tVo);
// break;
// case 34:
// vo.setT34(tVo);
// break;
// case 35:
// vo.setT35(tVo);
// break;
// case 36:
// vo.setT36(tVo);
// break;
// case 37:
// vo.setT37(tVo);
// break;
// case 38:
// vo.setT38(tVo);
// break;
// case 39:
// vo.setT39(tVo);
// break;
// case 40:
// vo.setT40(tVo);
// break;
// case 41:
// vo.setT41(tVo);
// break;
// case 42:
// vo.setT42(tVo);
// break;
// case 43:
// vo.setT43(tVo);
// break;
// case 44:
// vo.setT44(tVo);
// break;
// case 45:
// vo.setT45(tVo);
// break;
// case 46:
// vo.setT46(tVo);
// break;
// case 47:
// vo.setT47(tVo);
// break;
// case 48:
// vo.setT48(tVo);
// break;
// case 49:
// vo.setT49(tVo);
// break;
// case 50:
// vo.setT50(tVo);
// break;
// case 51:
// vo.setT51(tVo);
// break;
// case 52:
// vo.setT52(tVo);
// break;
// case 53:
// vo.setT53(tVo);
// break;
// case 54:
// vo.setT54(tVo);
// break;
// case 55:
// vo.setT55(tVo);
// break;
// case 56:
// vo.setT56(tVo);
// break;
// case 57:
// vo.setT57(tVo);
// break;
// case 58:
// vo.setT58(tVo);
// break;
// case 59:
// vo.setT59(tVo);
// break;
// case 60:
// vo.setT60(tVo);
// break;
// case 61:
// vo.setT61(tVo);
// break;
// case 62:
// vo.setT62(tVo);
// break;
// case 63:
// vo.setT63(tVo);
// break;
// case 64:
// vo.setT64(tVo);
// break;
// case 65:
// vo.setT65(tVo);
// break;
// case 66:
// vo.setT66(tVo);
// break;
// case 67:
// vo.setT67(tVo);
// break;
// case 68:
// vo.setT68(tVo);
// break;
// case 69:
// vo.setT69(tVo);
// break;
// case 70:
// vo.setT70(tVo);
// break;
// case 71:
// vo.setT71(tVo);
// break;
// case 72:
// vo.setT72(tVo);
// break;
// case 73:
// vo.setT73(tVo);
// break;
// case 74:
// vo.setT74(tVo);
// break;
// case 75:
// vo.setT75(tVo);
// break;
// case 76:
// vo.setT76(tVo);
// break;
// case 77:
// vo.setT77(tVo);
// break;
// case 78:
// vo.setT78(tVo);
// break;
// case 79:
// vo.setT79(tVo);
// break;
// case 80:
// vo.setT80(tVo);
// break;
// case 81:
// vo.setT81(tVo);
// break;
// case 82:
// vo.setT82(tVo);
// break;
// case 83:
// vo.setT83(tVo);
// break;
// case 84:
// vo.setT84(tVo);
// break;
// case 85:
// vo.setT85(tVo);
// break;
// case 86:
// vo.setT86(tVo);
// break;
// case 87:
// vo.setT87(tVo);
// break;
// case 88:
// vo.setT88(tVo);
// break;
// case 89:
// vo.setT89(tVo);
// break;
// case 90:
// vo.setT90(tVo);
// break;
// case 91:
// vo.setT91(tVo);
// break;
// case 92:
// vo.setT92(tVo);
// break;
// case 93:
// vo.setT93(tVo);
// break;
// case 94:
// vo.setT94(tVo);
// break;
// case 95:
// vo.setT95(tVo);
// break;
// case 96:
// vo.setT96(tVo);
// break;
// case 97:
// vo.setT97(tVo);
// break;
// case 98:
// vo.setT98(tVo);
// break;
// case 99:
// vo.setT99(tVo);
// break;
// case 100:
// vo.setT100(tVo);
// break;
// }
// i++;
} }
//当学生未填写调查问卷上,如果传给前端的t1.t2等字段未Null,会出错。。。。 //当学生未填写调查问卷上,如果传给前端的t1.t2等字段未Null,会出错。。。。
/* if(StringUtils.isNull(anVo.getList()) || anVo.getList().size() == 0){ /* if(StringUtils.isNull(anVo.getList()) || anVo.getList().size() == 0){
......
...@@ -179,6 +179,13 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch ...@@ -179,6 +179,13 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime); nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime);
List<SchoolDcwjNr> nrs = nrMapper.selectList(nrlqw); List<SchoolDcwjNr> nrs = nrMapper.selectList(nrlqw);
LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
lqw
.eq(SchoolDcwjAn::getDcwjId, dcwjId)
;
//a里要么有1个值,要么没有值
List<SchoolDcwjAn> a = anMapper.selectList(lqw);
//教师调查问卷回答的内容 //教师调查问卷回答的内容
for (SchoolDcwjAnVo anVo : list) { for (SchoolDcwjAnVo anVo : list) {
List<SchoolDcwjAn> ans = new ArrayList<>(); List<SchoolDcwjAn> ans = new ArrayList<>();
...@@ -187,19 +194,28 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch ...@@ -187,19 +194,28 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
//获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值 //获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值
for(SchoolDcwjNr nr : nrs){ for(SchoolDcwjNr nr : nrs){
LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>(); // LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
lqw // lqw
.eq(SchoolDcwjAn::getDcwjId, dcwjId) // .eq(SchoolDcwjAn::getDcwjId, dcwjId)
.eq(SchoolDcwjAn::getRyId, anVo.getId()) // .eq(SchoolDcwjAn::getRyId, anVo.getId())
.eq(SchoolDcwjAn::getNrId, nr.getId()) // .eq(SchoolDcwjAn::getNrId, nr.getId())
; // ;
//a里要么有1个值,要么没有值 // //a里要么有1个值,要么没有值
List<SchoolDcwjAn> a = anMapper.selectList(lqw); // List<SchoolDcwjAn> a = anMapper.selectList(lqw);
if(StringUtils.isNotNull(a) && a.size() > 0){
ans.add(a.get(0)); for (SchoolDcwjAn schoolDcwjAn : a) {
}else { if (schoolDcwjAn.getRyId().equals(anVo.getId()) && schoolDcwjAn.getNrId().equals(nr.getId())){
ans.add(entity); ans.add(schoolDcwjAn);
}else {
ans.add(entity);
}
} }
// if(StringUtils.isNotNull(a) && a.size() > 0){
// ans.add(a.get(0));
// }else {
// ans.add(entity);
// }
} }
anVo.setList(ans); anVo.setList(ans);
} }
...@@ -215,6 +231,13 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch ...@@ -215,6 +231,13 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime); nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime);
List<SchoolDcwjNr> nrs = nrMapper.selectList(nrlqw); List<SchoolDcwjNr> nrs = nrMapper.selectList(nrlqw);
LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
lqw
.eq(SchoolDcwjAn::getDcwjId, dcwjId)
;
//a里要么有1个值,要么没有值
List<SchoolDcwjAn> a = anMapper.selectList(lqw);
//学生家长调查问卷回答的内容 //学生家长调查问卷回答的内容
for (SchoolDcwjAnVo anVo : list) { for (SchoolDcwjAnVo anVo : list) {
List<SchoolDcwjAn> ans = new ArrayList<>(); List<SchoolDcwjAn> ans = new ArrayList<>();
...@@ -223,19 +246,28 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch ...@@ -223,19 +246,28 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
//获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值 //获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值
for(SchoolDcwjNr nr : nrs){ for(SchoolDcwjNr nr : nrs){
LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>(); // LambdaQueryWrapper<SchoolDcwjAn> lqw = new LambdaQueryWrapper<>();
lqw // lqw
.eq(SchoolDcwjAn::getDcwjId, dcwjId) // .eq(SchoolDcwjAn::getDcwjId, dcwjId)
.eq(SchoolDcwjAn::getRyId, anVo.getId()) // .eq(SchoolDcwjAn::getRyId, anVo.getId())
.eq(SchoolDcwjAn::getNrId, nr.getId()) // .eq(SchoolDcwjAn::getNrId, nr.getId())
; // ;
//a里要么有1个值,要么没有值 // //a里要么有1个值,要么没有值
List<SchoolDcwjAn> a = anMapper.selectList(lqw); // List<SchoolDcwjAn> a = anMapper.selectList(lqw);
if(StringUtils.isNotNull(a) && a.size() > 0){
ans.add(a.get(0)); for (SchoolDcwjAn schoolDcwjAn : a) {
}else { if (schoolDcwjAn.getRyId().equals(anVo.getId()) && schoolDcwjAn.getNrId().equals(nr.getId())){
ans.add(entity); ans.add(schoolDcwjAn);
}else {
ans.add(entity);
}
} }
// if(StringUtils.isNotNull(a) && a.size() > 0){
// ans.add(a.get(0));
// }else {
// ans.add(entity);
// }
} }
anVo.setList(ans); anVo.setList(ans);
} }
...@@ -2060,4 +2092,14 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch ...@@ -2060,4 +2092,14 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
} }
return list; return list;
} }
@Override
public List<SchoolDcwjAnVo> getTeaAnData(Long dcwjId, SchoolDcwjAnVo vo) {
return schoolDcwjRyMapper.getTeaAnData(dcwjId,vo);
}
@Override
public List<SchoolDcwjAnVo> getAnData1(Long dcwjId, SchoolDcwjAnVo vo) {
return schoolDcwjRyMapper.getAnData(dcwjId,vo);
}
} }
...@@ -50,6 +50,10 @@ public class CirculationServiceImpl extends ServiceImpl<CirculationMapper, Schoo ...@@ -50,6 +50,10 @@ public class CirculationServiceImpl extends ServiceImpl<CirculationMapper, Schoo
public SchoolCirculationVo getSchoolCirculationVoByenCode(String enCode) { public SchoolCirculationVo getSchoolCirculationVoByenCode(String enCode) {
return circulationMapper.getSchoolCirculationVoByenCode(enCode); return circulationMapper.getSchoolCirculationVoByenCode(enCode);
} }
@Override
public SchoolCirculationVo getReturningEquipmentById(String id) {
return circulationMapper.getReturningEquipmentById(id);
}
/** /**
...@@ -101,6 +105,9 @@ public class CirculationServiceImpl extends ServiceImpl<CirculationMapper, Schoo ...@@ -101,6 +105,9 @@ public class CirculationServiceImpl extends ServiceImpl<CirculationMapper, Schoo
public int insertSchoolCirculation(SchoolCirculation schoolCirculation) { public int insertSchoolCirculation(SchoolCirculation schoolCirculation) {
//判断该设备是否允许借出 //判断该设备是否允许借出
SchoolEquipmentLedger schoolEquipmentLedger1 = equipmentLedgerMapper.selectById(schoolCirculation.getEquipmentId()); SchoolEquipmentLedger schoolEquipmentLedger1 = equipmentLedgerMapper.selectById(schoolCirculation.getEquipmentId());
if (StringUtils.isNull(schoolEquipmentLedger1)){
throw new ServiceException("未查询到该设备,请重新输入!");
}
if (schoolEquipmentLedger1.getIsAllowLend().equals("0")){ if (schoolEquipmentLedger1.getIsAllowLend().equals("0")){
throw new ServiceException("该设备不允许借出"); throw new ServiceException("该设备不允许借出");
} }
......
...@@ -19,8 +19,10 @@ import yangtz.cs.liu.campus.mapper.schoolEquipment.*; ...@@ -19,8 +19,10 @@ import yangtz.cs.liu.campus.mapper.schoolEquipment.*;
import yangtz.cs.liu.campus.service.schoolEquipment.IEquipmentLedgerService; import yangtz.cs.liu.campus.service.schoolEquipment.IEquipmentLedgerService;
import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolEquipmentLedgerVo; import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolEquipmentLedgerVo;
import java.text.SimpleDateFormat;
import java.time.LocalDate; import java.time.LocalDate;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Date;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -223,16 +225,6 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe ...@@ -223,16 +225,6 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe
}else if(schoolEquipmentLedger.getClassificationCode().length() < 4){ }else if(schoolEquipmentLedger.getClassificationCode().length() < 4){
failureNum++; failureNum++;
failureMsg.append("<br/>" + failureNum + "、分类编码长度最少为4位,请你核对后重新输入!"); failureMsg.append("<br/>" + failureNum + "、分类编码长度最少为4位,请你核对后重新输入!");
}else if(StringUtils.isNotNull(schoolEquipmentLedger.getClassificationCode())){
//查询分类编码是否重复
LambdaQueryWrapper<SchoolProductCategory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolProductCategory::getClassificationCode,schoolEquipmentLedger.getClassificationCode())
.eq(SchoolProductCategory::getDelFlag,"0");
List<SchoolProductCategory> schoolProductCategories = productCategoryMapper.selectList(wrapper);
if (schoolProductCategories.size()<=0) {
failureNum++;
failureMsg.append("<br/>" + failureNum + "、分类编码不存在,请你重新输入!");
}
}else if (StringUtils.isNull(schoolEquipmentLedger.getUnit())){ }else if (StringUtils.isNull(schoolEquipmentLedger.getUnit())){
failureNum++; failureNum++;
failureMsg.append("<br/>" + failureNum + "、单位为空,请你重新输入!"); failureMsg.append("<br/>" + failureNum + "、单位为空,请你重新输入!");
...@@ -260,6 +252,31 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe ...@@ -260,6 +252,31 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe
}else if (StringUtils.isNull(schoolEquipmentLedger.getPlace())){ }else if (StringUtils.isNull(schoolEquipmentLedger.getPlace())){
failureNum++; failureNum++;
failureMsg.append("<br/>" + failureNum + "、地点为空,请你重新输入!"); failureMsg.append("<br/>" + failureNum + "、地点为空,请你重新输入!");
}else {
try {
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
Date dateOfProduction = schoolEquipmentLedger.getDateOfProduction();
sdf.format(dateOfProduction);
} catch (Exception e) {
throw new ServiceException("格式不对,请检查日期格式");
}
try {
Integer.parseInt(schoolEquipmentLedger.getPlace());
throw new ServiceException("地点输入错误,请重新输入!");
} catch (NumberFormatException e) {
e.printStackTrace();
}
}
if(StringUtils.isNotNull(schoolEquipmentLedger.getClassificationCode())){
//查询分类编码是否重复
LambdaQueryWrapper<SchoolProductCategory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolProductCategory::getClassificationCode,schoolEquipmentLedger.getClassificationCode())
.eq(SchoolProductCategory::getDelFlag,"0");
List<SchoolProductCategory> schoolProductCategories = productCategoryMapper.selectList(wrapper);
if (schoolProductCategories.size()<=0) {
failureNum++;
failureMsg.append("<br/>" + failureNum + "、分类编码不存在,请你重新输入!");
}
} }
} }
if (failureNum > 0) { if (failureNum > 0) {
...@@ -276,4 +293,14 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe ...@@ -276,4 +293,14 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe
public List<Map<String, Object>> getUser(SysUser sysUser) { public List<Map<String, Object>> getUser(SysUser sysUser) {
return equipmentLedgerMapper.getUser(sysUser); return equipmentLedgerMapper.getUser(sysUser);
} }
/**
* 打印设备条码信息
* @param ids
* @return
*/
@Override
public List<Map<String, Object>> getEquipmentledger(Long[] ids) {
return equipmentLedgerMapper.getEquipmentledger(ids);
}
} }
...@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; ...@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.annotation.DataScope; import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.core.domain.entity.SysRole; import com.ruoyi.common.core.domain.entity.SysRole;
import com.ruoyi.common.core.domain.entity.SysUser; import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.exception.ServiceException;
import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.SecurityUtils; import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils; import com.ruoyi.common.utils.StringUtils;
...@@ -144,7 +145,11 @@ public class EquipmentRepairServiceImpl extends ServiceImpl<EquipmentRepairMappe ...@@ -144,7 +145,11 @@ public class EquipmentRepairServiceImpl extends ServiceImpl<EquipmentRepairMappe
@Override @Override
public Map<String, String> getEquipment(String encode) { public Map<String, String> getEquipment(String encode) {
// Long userId = SecurityUtils.getLoginUser().getUser().getUserId(); // Long userId = SecurityUtils.getLoginUser().getUser().getUserId();
return equipmentRepairMapper.getEquipment(encode); Map<String, String> equipment = equipmentRepairMapper.getEquipment(encode);
if (StringUtils.isNull(equipment)){
throw new ServiceException("未查询到设备信息,请重新输入设备编号!");
}
return equipment;
} }
/** /**
......
...@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; ...@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.annotation.DataScope; import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.core.domain.entity.SysRole; import com.ruoyi.common.core.domain.entity.SysRole;
import com.ruoyi.common.core.domain.entity.SysUser; import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.exception.ServiceException;
import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.SecurityUtils; import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils; import com.ruoyi.common.utils.StringUtils;
...@@ -71,6 +72,14 @@ public class ReceiveServiceImpl extends ServiceImpl<ReceiveMapper, SchoolReceive ...@@ -71,6 +72,14 @@ public class ReceiveServiceImpl extends ServiceImpl<ReceiveMapper, SchoolReceive
*/ */
@Override @Override
public int insertSchoolReceive(SchoolReceive schoolReceive) { public int insertSchoolReceive(SchoolReceive schoolReceive) {
//判断该设备是否允许借出
SchoolEquipmentLedger schoolEquipmentLedger1 = equipmentLedgerMapper.selectById(schoolReceive.getEquipmentId());
if (StringUtils.isNull(schoolEquipmentLedger1)){
throw new ServiceException("未查询到该设备,请重新输入!");
}
if (schoolEquipmentLedger1.getIsAllowLend().equals("0")){
throw new ServiceException("该设备不允许借出");
}
if (StringUtils.isNotNull(schoolReceive.getRecipientById())){ if (StringUtils.isNotNull(schoolReceive.getRecipientById())){
String userName = sysUserMapper.selectUserById(schoolReceive.getRecipientById()).getUserName(); String userName = sysUserMapper.selectUserById(schoolReceive.getRecipientById()).getUserName();
schoolReceive.setRecipientBy(userName); schoolReceive.setRecipientBy(userName);
......
...@@ -10,9 +10,12 @@ import com.ruoyi.system.mapper.SysUserMapper; ...@@ -10,9 +10,12 @@ import com.ruoyi.system.mapper.SysUserMapper;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabClassYearMapper;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabMapper; import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabMapper;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherExperimentApplyVo;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
...@@ -33,6 +36,8 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab> ...@@ -33,6 +36,8 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab>
@Autowired @Autowired
private SysUserMapper sysUserMapper; private SysUserMapper sysUserMapper;
@Autowired
private SchoolLabClassYearMapper schoolLabClassYearMapper;
/** /**
* 查询实验室 * 查询实验室
* *
......
...@@ -139,8 +139,8 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta ...@@ -139,8 +139,8 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta
} }
boolean isMerge = isMergedRegion(sheet, i, 0); boolean isMerge = isMergedRegion(sheet, i, 0);
//schoolBudgetDetails.setBudgetDetailed(row.getCell(6).getStringCellValue()); //schoolBudgetDetails.setBudgetDetailed(row.getCell(6).getStringCellValue());
schoolBudgetDetails.setBudgetDetailed(TemplateExcelUtils.getCellValue(row.getCell(6), workbook)); schoolBudgetDetails.setBudgetDetailed(TemplateExcelUtils.getCellValue(row.getCell(7), workbook));
schoolBudgetDetails.setMoneyDetailed(new BigDecimal(new DataFormatter().formatCellValue(row.getCell(7)))); schoolBudgetDetails.setMoneyDetailed(new BigDecimal(new DataFormatter().formatCellValue(row.getCell(8))));
if(isMerge){ //如果是合并单元格 if(isMerge){ //如果是合并单元格
isSameCell = isSameMergeRegion(sheet,i,0); //判断与上一行是否为同一单元格 isSameCell = isSameMergeRegion(sheet,i,0); //判断与上一行是否为同一单元格
if(!isSameCell){ if(!isSameCell){
...@@ -157,14 +157,14 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta ...@@ -157,14 +157,14 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta
schoolBudget.setBudgetName(budgetName); schoolBudget.setBudgetName(budgetName);
giveMoney = getMergedRegionValue(sheet, row.getRowNum(), 3); giveMoney = getMergedRegionValue(sheet, row.getRowNum(), 3);
schoolBudget.setGiveMoney(new BigDecimal(giveMoney)); schoolBudget.setGiveMoney(new BigDecimal(giveMoney));
isGov = getMergedRegionValue(sheet, row.getRowNum(), 4); isGov = getMergedRegionValue(sheet, row.getRowNum(), 5);
if(isGov.equals("是")){ if(isGov.equals("是")){
schoolBudget.setIsGov("0"); schoolBudget.setIsGov("0");
} }
if(isGov.equals("否")){ if(isGov.equals("否")){
schoolBudget.setIsGov("1"); schoolBudget.setIsGov("1");
} }
remark = getMergedRegionValue(sheet, row.getRowNum(), 5); remark = getMergedRegionValue(sheet, row.getRowNum(), 6);
schoolBudget.setRemark(remark); schoolBudget.setRemark(remark);
schoolBudgetMapper.insert(schoolBudget); schoolBudgetMapper.insert(schoolBudget);
budgetId = schoolBudget.getId(); budgetId = schoolBudget.getId();
...@@ -182,14 +182,14 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta ...@@ -182,14 +182,14 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta
schoolBudget.setDeptId(deptId); schoolBudget.setDeptId(deptId);
schoolBudget.setBudgetName(new DataFormatter().formatCellValue(row.getCell(2))); schoolBudget.setBudgetName(new DataFormatter().formatCellValue(row.getCell(2)));
schoolBudget.setGiveMoney(new BigDecimal(new DataFormatter().formatCellValue(row.getCell(3)))); schoolBudget.setGiveMoney(new BigDecimal(new DataFormatter().formatCellValue(row.getCell(3))));
isGov = new DataFormatter().formatCellValue(row.getCell(4)); isGov = new DataFormatter().formatCellValue(row.getCell(5));
if(isGov.equals("是")){ if(isGov.equals("是")){
schoolBudget.setIsGov("0"); schoolBudget.setIsGov("0");
} }
if(isGov.equals("否")){ if(isGov.equals("否")){
schoolBudget.setIsGov("1"); schoolBudget.setIsGov("1");
} }
schoolBudget.setRemark(new DataFormatter().formatCellValue(row.getCell(5))); schoolBudget.setRemark(new DataFormatter().formatCellValue(row.getCell(6)));
schoolBudgetMapper.insert(schoolBudget); schoolBudgetMapper.insert(schoolBudget);
schoolBudgetDetails.setBudgetId(schoolBudget.getId()); schoolBudgetDetails.setBudgetId(schoolBudget.getId());
schoolBudgetDetailsMapper.insert(schoolBudgetDetails); schoolBudgetDetailsMapper.insert(schoolBudgetDetails);
......
...@@ -116,15 +116,24 @@ public class SchoolStudentServiceImpl extends ServiceImpl<SchoolStudentMapper, S ...@@ -116,15 +116,24 @@ public class SchoolStudentServiceImpl extends ServiceImpl<SchoolStudentMapper, S
if (isNull(list) || list.size() == 0) { if (isNull(list) || list.size() == 0) {
return new ArrayList<>(); return new ArrayList<>();
} }
//获取所有学生家长
LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
lqw.orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> studentParentList = schoolStudentParentMapper.selectList(lqw);
for (SchoolStudentVO vo : list) { for (SchoolStudentVO vo : list) {
LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>(); // LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
lqw.eq(SchoolStudentParent::getStudentId, vo.getId()) // lqw.eq(SchoolStudentParent::getStudentId, vo.getId())
.orderByDesc(SchoolStudentParent::getCreateTime); // .orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> parentList = schoolStudentParentMapper.selectList(lqw); // List<SchoolStudentParent> parentList = schoolStudentParentMapper.selectList(lqw);
List<SchoolStudentParent> parentList = new ArrayList<>();
for (SchoolStudentParent studentParent : studentParentList) {
if (vo.getId().equals(studentParent.getStudentId())){
parentList.add(studentParent);
}
}
if (isNull(parentList) || parentList.size() == 0) { if (isNull(parentList) || parentList.size() == 0) {
continue; continue;
} }
//获取学生家长,至多2人 //获取学生家长,至多2人
int i = 1; int i = 1;
for (SchoolStudentParent parent : parentList) { for (SchoolStudentParent parent : parentList) {
...@@ -172,22 +181,46 @@ public class SchoolStudentServiceImpl extends ServiceImpl<SchoolStudentMapper, S ...@@ -172,22 +181,46 @@ public class SchoolStudentServiceImpl extends ServiceImpl<SchoolStudentMapper, S
List<SchoolStudentVO> list = new ArrayList<>(); List<SchoolStudentVO> list = new ArrayList<>();
List<SchoolStudent> studentList = schoolStudentMapper.selectBatchIds(ids); List<SchoolStudent> studentList = schoolStudentMapper.selectBatchIds(ids);
//获取所有班级
List<SchoolClass> schoolClasses = schoolClassMapper.selectList(new LambdaQueryWrapper<>());
//获取所有家长
LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
lqw.orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> studentParentList = schoolStudentParentMapper.selectList(lqw);
for (SchoolStudent student : studentList) { for (SchoolStudent student : studentList) {
SchoolStudentVO vo = new SchoolStudentVO(); SchoolStudentVO vo = new SchoolStudentVO();
BeanUtils.copyProperties(student, vo); BeanUtils.copyProperties(student, vo);
//学年年级班级 for (SchoolClass schoolClass : schoolClasses) {
SchoolClass theClass = schoolClassMapper.selectById(student.getClassId()); if (schoolClass.getId().equals(student.getClassId())){
if (isNotNull(theClass)) { vo.setSchoolYear(schoolClass.getSchoolYear());
vo.setSchoolYear(theClass.getSchoolYear()); vo.setGradeValue(schoolClass.getGradeValue());
vo.setGradeValue(theClass.getGradeValue()); vo.setClassValue(schoolClass.getClassValue());
vo.setClassValue(theClass.getClassValue()); }
} }
// //学年年级班级
// SchoolClass theClass = schoolClassMapper.selectById(student.getClassId());
// if (isNotNull(theClass)) {
// vo.setSchoolYear(theClass.getSchoolYear());
// vo.setGradeValue(theClass.getGradeValue());
// vo.setClassValue(theClass.getClassValue());
// }
//家长信息 //家长信息
LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>(); // LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
lqw.eq(SchoolStudentParent::getStudentId, student.getId()) // lqw.eq(SchoolStudentParent::getStudentId, student.getId())
.orderByDesc(SchoolStudentParent::getCreateTime); // .orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> parentList = schoolStudentParentMapper.selectList(lqw); // List<SchoolStudentParent> parentList = schoolStudentParentMapper.selectList(lqw);
List<SchoolStudentParent> parentList = new ArrayList<>();
for (SchoolStudentParent studentParent : studentParentList) {
if (vo.getId().equals(studentParent.getStudentId())){
parentList.add(studentParent);
}
}
if (isNull(parentList) || parentList.size() == 0) { if (isNull(parentList) || parentList.size() == 0) {
list.add(vo); list.add(vo);
continue; continue;
......
...@@ -16,6 +16,7 @@ import yangtz.cs.liu.campus.mapper.teacher.SchoolTeacherWagesMapper; ...@@ -16,6 +16,7 @@ import yangtz.cs.liu.campus.mapper.teacher.SchoolTeacherWagesMapper;
import yangtz.cs.liu.campus.service.teacher.ISchoolTeacherWagesService; import yangtz.cs.liu.campus.service.teacher.ISchoolTeacherWagesService;
import yangtz.cs.liu.campus.vo.student.SchoolTeacherWagesVO; import yangtz.cs.liu.campus.vo.student.SchoolTeacherWagesVO;
import java.math.BigDecimal;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
...@@ -123,7 +124,7 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage ...@@ -123,7 +124,7 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
public int insertByTeacherId(Long teacherId,SchoolTeacherWages schoolTeacherWages) { public int insertByTeacherId(Long teacherId,SchoolTeacherWages schoolTeacherWages) {
SchoolTeacher schoolTeacher = schoolTeacherMapper.selectById(teacherId); SchoolTeacher schoolTeacher = schoolTeacherMapper.selectById(teacherId);
schoolTeacherWages.setTeacherName(schoolTeacher.getTeacherName()); schoolTeacherWages.setTeacherName(schoolTeacher.getTeacherName());
schoolTeacherWages.setIdCard(schoolTeacher.getIdCard()); schoolTeacherWages.setTeacherTel(schoolTeacher.getTeacherTel());
return schoolTeacherWagesMapper.insert(schoolTeacherWages); return schoolTeacherWagesMapper.insert(schoolTeacherWages);
} }
...@@ -143,12 +144,10 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage ...@@ -143,12 +144,10 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
if (StringUtils.isEmpty(schoolTeacherWages.getTeacherName())) { if (StringUtils.isEmpty(schoolTeacherWages.getTeacherName())) {
failureNum++; failureNum++;
failureMsg.append("<br/>" + failureNum + "、教师姓名为空,请您重新输入! "); failureMsg.append("<br/>" + failureNum + "、教师姓名为空,请您重新输入! ");
} } else if (StringUtils.isEmpty(schoolTeacherWages.getTeacherTel())) {
// else if (StringUtils.isEmpty(schoolTeacherWages.getIdCard())) { failureNum++;
// failureNum++; failureMsg.append("<br/>" + failureNum + "、教师联系方式为空,请您重新输入! ");
// failureMsg.append("<br/>" + failureNum + "、身份证号为空,请您重新输入! "); } else if (StringUtils.isNull(schoolTeacherWages.getWagesTime())) {
// }
else if (StringUtils.isNull(schoolTeacherWages.getWagesTime())) {
failureNum++; failureNum++;
failureMsg.append("<br/>" + failureNum + "、工资日期为空,请您重新输入!"); failureMsg.append("<br/>" + failureNum + "、工资日期为空,请您重新输入!");
} else if (isNotNull(schoolTeacherWages.getWagesTime())) { } else if (isNotNull(schoolTeacherWages.getWagesTime())) {
...@@ -159,15 +158,62 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage ...@@ -159,15 +158,62 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
} catch (Exception e) { } catch (Exception e) {
throw new ServiceException("格式不对,请检查日期格式"); throw new ServiceException("格式不对,请检查日期格式");
} }
}
// else {
// LambdaQueryWrapper<SchoolTeacherWages> lqw = new LambdaQueryWrapper<>();
// lqw
// .eq(SchoolTeacherWages::getTeacherTel, schoolTeacherWages.getTeacherTel());
// SchoolTeacherWages teacherWages = schoolTeacherWagesMapper.selectOne(lqw);
// if (isNull(teacherWages)){
// failureNum++;
// failureMsg.append("<br/>" + failureNum + "、该老师不存在,请您重新输入! ");
// }
// }
if (StringUtils.isNull(schoolTeacherWages.getBasePay())) {
schoolTeacherWages.setBasePay(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getBonus())) {
schoolTeacherWages.setBonus(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getPension())) {
schoolTeacherWages.setPension(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getAccumulationFund())) {
schoolTeacherWages.setAccumulationFund(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getMedicalInsurance())) {
schoolTeacherWages.setMedicalInsurance(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getFareSubsidy())) {
schoolTeacherWages.setFareSubsidy(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getTelephoneSubsidy())) {
schoolTeacherWages.setTelephoneSubsidy(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getMealAllowance())) {
schoolTeacherWages.setMealAllowance(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getIncomeTax())) {
schoolTeacherWages.setIncomeTax(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getUnemploymentBenefits())) {
schoolTeacherWages.setUnemploymentBenefits(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getOvertimePay())) {
schoolTeacherWages.setOvertimePay(new BigDecimal(0));
}
if (StringUtils.isNull(schoolTeacherWages.getRemarks())) {
schoolTeacherWages.setRemarks("");
}
LambdaQueryWrapper<SchoolTeacher> lqw = new LambdaQueryWrapper<>();
lqw
.eq(SchoolTeacher::getTeacherTel, schoolTeacherWages.getTeacherTel());
SchoolTeacher schoolTeacher = schoolTeacherMapper.selectOne(lqw);
if (isNull(schoolTeacher)){
failureNum++;
failureMsg.append("<br/>" + failureNum + "、该老师不存在,请您重新输入! ");
}else { }else {
LambdaQueryWrapper<SchoolTeacherWages> lqw = new LambdaQueryWrapper<>(); schoolTeacherWages.setTeacherId(schoolTeacher.getId());
lqw
.eq(SchoolTeacherWages::getIdCard, schoolTeacherWages.getIdCard());
SchoolTeacherWages teacherWages = schoolTeacherWagesMapper.selectOne(lqw);
if (isNull(teacherWages)){
failureNum++;
failureMsg.append("<br/>" + failureNum + "、该老师不存在,请您重新输入! ");
}
} }
} }
if (failureNum > 0) { if (failureNum > 0) {
...@@ -186,16 +232,19 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage ...@@ -186,16 +232,19 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
// 准备记录日志数据 // 准备记录日志数据
int successNum = 0; int successNum = 0;
StringBuilder successMsg = new StringBuilder(); StringBuilder successMsg = new StringBuilder();
for (SchoolTeacherWages schoolTeacherWages : list) {
try { schoolTeacherWagesMapper.batchInsertTeacherWages(list);
schoolTeacherWagesMapper.insert(schoolTeacherWages);
successNum++; // for (SchoolTeacherWages schoolTeacherWages : list) {
successMsg.append("<br/>" + successNum + "数据" + " 导入成功"); // try {
} catch (Exception e) { // schoolTeacherWagesMapper.insert(schoolTeacherWages);
throw new ServiceException("导入失败"); // successNum++;
} // successMsg.append("<br/>" + successNum + "数据" + " 导入成功");
} // } catch (Exception e) {
successMsg.insert(0, "恭喜您,数据已导入成功!共有 " + successNum + " 条,数据如下:"); // throw new ServiceException("导入失败");
// }
// }
successMsg.insert(0, "恭喜您,数据已导入成功!");
return successMsg.toString(); return successMsg.toString();
} }
......
package yangtz.cs.liu.campus.service.impl.teacherFiles; package yangtz.cs.liu.campus.service.impl.teacherFiles;
import com.ruoyi.common.core.domain.entity.SchoolTeacher;
import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.common.utils.TermRange; import com.ruoyi.common.utils.TermRange;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.award.Award; import yangtz.cs.liu.campus.domain.award.Award;
import yangtz.cs.liu.campus.domain.material.Material; import yangtz.cs.liu.campus.domain.material.Material;
import yangtz.cs.liu.campus.domain.schoolClass.SchoolClass;
import yangtz.cs.liu.campus.domain.schoolClass.SchoolClassMentor;
import yangtz.cs.liu.campus.domain.teacherFiles.*; import yangtz.cs.liu.campus.domain.teacherFiles.*;
import yangtz.cs.liu.campus.domain.thesis.Thesis; import yangtz.cs.liu.campus.domain.thesis.Thesis;
import yangtz.cs.liu.campus.domain.training.Training; import yangtz.cs.liu.campus.domain.training.Training;
import yangtz.cs.liu.campus.mapper.schoolClass.SchoolClassMapper;
import yangtz.cs.liu.campus.mapper.schoolClass.SchoolClassMentorMapper;
import yangtz.cs.liu.campus.mapper.schoolgrade.SchoolGradeMapper;
import yangtz.cs.liu.campus.mapper.teacher.SchoolTeacherMapper;
import yangtz.cs.liu.campus.mapper.teacherFiles.*; import yangtz.cs.liu.campus.mapper.teacherFiles.*;
import yangtz.cs.liu.campus.service.teacherFiles.ITeacherFilesService; import yangtz.cs.liu.campus.service.teacherFiles.ITeacherFilesService;
import yangtz.cs.liu.wechat.vo.schoolClass.SchoolClassVo;
import java.util.HashMap; import java.text.SimpleDateFormat;
import java.util.List; import java.util.*;
import java.util.Map;
/** /**
...@@ -44,7 +52,18 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService ...@@ -44,7 +52,18 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService
@Autowired @Autowired
private TeacherFilesNoticeMapper teacherFilesNoticeMapper; private TeacherFilesNoticeMapper teacherFilesNoticeMapper;
@Autowired
private TeacherFilesDeletRecordMapper teacherFilesDeletRecordMapper;
@Autowired
private SchoolClassMapper schoolClassMapper;
@Autowired
private SchoolTeacherMapper schoolTeacherMapper;
@Autowired
private SchoolGradeMapper gradeMapper;
@Autowired
private SchoolClassMentorMapper classMentorMapper;
/** /**
* 查询教师档案 * 查询教师档案
* *
...@@ -76,8 +95,8 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService ...@@ -76,8 +95,8 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService
@Override @Override
public List<TeacherFilesNotice> selctTeacherByUserId(Long userId) { public List<TeacherFilesNotice> selctTeacherByUserId(Long userId,TeacherFilesNotice teacherFiles) {
return teacherFilesNoticeMapper.selctTeacherByUserId(userId); return teacherFilesNoticeMapper.selctTeacherByUserId(userId,teacherFiles);
} }
/** /**
...@@ -113,7 +132,91 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService ...@@ -113,7 +132,91 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService
@Override @Override
public int deleteTeacherFilesByIds(Long[] ids) public int deleteTeacherFilesByIds(Long[] ids)
{ {
return teacherFilesMapper.deleteTeacherFilesByIds(ids); //1.保留人员到删除信息表中
for (int i=0 ; i < ids.length ;i++){
TeacherFilesVO teacherFilesVO = teacherFilesMapper.selectTeacherFilesById(ids[i]);
TeacherFilesDeletRecord teacherFilesDeletRecord = new TeacherFilesDeletRecord();
teacherFilesDeletRecord.setTel(teacherFilesVO.getIdCard() == null ? "" : teacherFilesVO.getIdCard());
teacherFilesDeletRecord.setUserName(teacherFilesVO.getTeacherName());
teacherFilesDeletRecord.setGruoName(teacherFilesVO.getGradeName());
teacherFilesDeletRecord.setUserId(teacherFilesVO.getTeacherId());
teacherFilesDeletRecord.setTId(teacherFilesVO.getNoticeId());
teacherFilesDeletRecord.setGId(teacherFilesVO.getGradeId());
teacherFilesDeletRecordMapper.addTeacherFilesDeletRecord(teacherFilesDeletRecord);
}
//2.删除人员
int i = teacherFilesMapper.deleteTeacherFilesByIds(ids);
return i;
}
/**
* 查询老师
* @param tId
* @return
*/
@Override
public List<TeacherFilesDeletRecord> getTeacherRocer(String tId) {
List<TeacherFilesDeletRecord> teacherRocer = teacherFilesDeletRecordMapper.getTeacherRocer(tId);
return teacherRocer;
}
/**
* 新增老师数据
* @param ids
* @return
*/
@Override
public Integer teacherAdd(Long[] ids) {
List<TeacherFiles> teacherFilesList = new ArrayList<>();
for (int i =0; i< ids.length ;i++){
TeacherFilesDeletRecord byid = teacherFilesDeletRecordMapper.getByid(ids[i]);
TeacherFilesNotice teacherFilesNotice = teacherFilesNoticeMapper.selectTeacherFilesNoticeById(byid.getTId().toString());
List<SchoolClassVo> schoolClassVos = schoolClassMapper.selectTeacherByTeachId(byid.getUserId());
String teahClassName = null;
String className = null;
//只取第一个
if (!schoolClassVos.isEmpty()){
teahClassName = schoolClassVos.get(0).getClassName();
className = schoolClassVos.get(0).getClassName();
}
//班主任信息
TeacherFiles teacherFiles = new TeacherFiles();
teacherFiles.setTeacherId(byid.getUserId());
teacherFiles = teacherFilesAddXx(teacherFiles);
teacherFiles.setNoticeId(byid.getTId().toString());
teacherFiles.setFilesSemester(teacherFilesNotice.getNoticeYear()+"学年"+teacherFilesNotice.getNoticeSemester());
teacherFiles.setGradeId(byid.getGId());
teacherFiles.setGradeName(byid.getGruoName());
teacherFiles.setBzrClassName(teahClassName);
teacherFiles.setState("2");
teacherFiles = teacherFilesAddXx(teacherFiles); //老师个人信息
//找到老师课程
// TODO 修改最新学年
int schoolYear = gradeMapper.isNewSchoolYear();
List<SchoolClassMentor> mentorByTeacherId = classMentorMapper.getMentorByTeacherId(byid.getUserId(), schoolYear);
if (!mentorByTeacherId.isEmpty()){
teacherFiles.setCourseName(mentorByTeacherId.get(0).getCourseName());
if (StringUtils.isEmpty(className)){
//根据课程关联找寻班级
SchoolClass schoolClass = schoolClassMapper.selectById(mentorByTeacherId.get(0).getClassId());
className = schoolClass.getClassName();
}
}
teacherFiles.setClassName(className);
teacherFilesList.add(teacherFiles);
teacherFilesDeletRecordMapper.deletRecord(ids[i]);
}
//导入数据库
teacherFilesList.forEach(date->{
teacherFilesMapper.insertTeacherFiles(date);
});
//删除id
return 1;
} }
/** /**
...@@ -185,4 +288,24 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService ...@@ -185,4 +288,24 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService
public List<Long> getGradeId(Long teacherId) { public List<Long> getGradeId(Long teacherId) {
return teacherFilesMapper.getGradeId(teacherId); return teacherFilesMapper.getGradeId(teacherId);
} }
TeacherFiles teacherFilesAddXx(TeacherFiles teacherFiles){
SchoolTeacher schoolTeacher = schoolTeacherMapper.selectSchoolTeacherById(teacherFiles.getTeacherId());
teacherFiles.setTeacherName(schoolTeacher.getTeacherName());
teacherFiles.setIdCard(schoolTeacher.getIdCard());
teacherFiles.setSex(schoolTeacher.getSex());
teacherFiles.setEducation(schoolTeacher.getEducation());
Date birthday = schoolTeacher.getBirthday();
if(birthday!=null){
SimpleDateFormat dateFormat= new SimpleDateFormat("yyyy");
Integer birthdayYear = Integer.valueOf(dateFormat.format(birthday));
Date date = new Date();
Integer nowYear = Integer.valueOf(dateFormat.format(date));
teacherFiles.setAge(nowYear-birthdayYear);
}
teacherFiles.setTitle("");
teacherFiles.setAppearance("");
return teacherFiles;
}
} }
...@@ -91,4 +91,8 @@ public interface ISchoolDcwjRyService extends IService<SchoolDcwjRy> ...@@ -91,4 +91,8 @@ public interface ISchoolDcwjRyService extends IService<SchoolDcwjRy>
//班主任-问卷结果-统计 //班主任-问卷结果-统计
public List<DataCountVo> getHeaderCount(Long id,List<Long> studentIds); public List<DataCountVo> getHeaderCount(Long id,List<Long> studentIds);
List<SchoolDcwjAnVo> getTeaAnData(Long dcwjId, SchoolDcwjAnVo vo);
List<SchoolDcwjAnVo> getAnData1(Long dcwjId, SchoolDcwjAnVo vo);
} }
...@@ -15,6 +15,9 @@ public interface ICirculationService extends IService<SchoolCirculation> { ...@@ -15,6 +15,9 @@ public interface ICirculationService extends IService<SchoolCirculation> {
SchoolCirculationVo getSchoolCirculationVoById(Long id); SchoolCirculationVo getSchoolCirculationVoById(Long id);
SchoolCirculationVo getSchoolCirculationVoByenCode(String enCode); SchoolCirculationVo getSchoolCirculationVoByenCode(String enCode);
SchoolCirculationVo getReturningEquipmentById(String id);
/** /**
* 查看设备借出归还列表 * 查看设备借出归还列表
* @param schoolCirculationVo * @param schoolCirculationVo
......
...@@ -70,4 +70,10 @@ public interface IEquipmentLedgerService extends IService<SchoolEquipmentLedger> ...@@ -70,4 +70,10 @@ public interface IEquipmentLedgerService extends IService<SchoolEquipmentLedger>
*/ */
List<Map<String,Object>> getUser(SysUser sysUser); List<Map<String,Object>> getUser(SysUser sysUser);
/**
* 打印设备条码信息
* @param ids
* @return
*/
List<Map<String, Object>> getEquipmentledger(Long[] ids);
} }
package yangtz.cs.liu.campus.service.teacherFiles; package yangtz.cs.liu.campus.service.teacherFiles;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFiles; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFiles;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesDeletRecord;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice;
import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesVO; import yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesVO;
...@@ -29,7 +30,15 @@ public interface ITeacherFilesService ...@@ -29,7 +30,15 @@ public interface ITeacherFilesService
* @return 教师档案集合 * @return 教师档案集合
*/ */
public List<TeacherFiles> selectTeacherFilesList(TeacherFiles teacherFiles); public List<TeacherFiles> selectTeacherFilesList(TeacherFiles teacherFiles);
public List<TeacherFilesNotice> selctTeacherByUserId(Long userId); public List<TeacherFilesNotice> selctTeacherByUserId(Long userId,TeacherFilesNotice teacherFiles);
public List<TeacherFilesDeletRecord> getTeacherRocer(String tId);
/**
* 新增教师档案
* @param ids
* @return
*/
public Integer teacherAdd(Long[] ids);
/** /**
* 新增教师档案 * 新增教师档案
......
...@@ -86,13 +86,12 @@ public class SchoolCirculationVo extends BaseEntity ...@@ -86,13 +86,12 @@ public class SchoolCirculationVo extends BaseEntity
/** 预计使用时间 */ /** 预计使用时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "预计使用时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") @Excel(name = "预计使用期限", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
private Date yjuseTime; private Date yjuseTime;
/** 实际使用时间 */ /** 实际使用时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @Excel(name = "实际使用时间")
@Excel(name = "实际使用时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") private String sjuseTime;
private Date sjuseTime;
/** 备注 */ /** 备注 */
@Excel(name = "备注") @Excel(name = "备注")
......
package yangtz.cs.liu.campus.vo.schoolEquipment;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.core.domain.OurBaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import java.math.BigDecimal;
import java.util.Date;
/**
* 设备台账对象 school_equipment_ledger
*
* @author ruoyi
* @date 2023-08-09
*/
@Data
public class SchoolEquipmentLedgerDcVo extends OurBaseEntity
{
@Excel(name = "序号")
private Integer serialNumber;
/** 自编码 */
@Excel(name = "设备名称")
private String encode;
/** 设备名称 */
@Excel(name = "设备名称")
private String equipmentName;
/** 型号 */
@Excel(name = "型号")
private String model;
/** 规格 */
@Excel(name = "规格")
private String specification;
/** 分类编码 */
@Excel(name = "分类编码")
private String classificationCode;
/** 单位 */
@Excel(name = "单位")
private String unit;
/** 归属类型(1公共区域,2信息中心,3个人) */
@Excel(name = "归属类型", readConverterExp = "1=公共区域,2=信息中心,3=个人", combo = {"公共区域","信息中心","个人"})
private String affiliationType;
/** 设备状态(1完好,2损坏,3报废) */
@Excel(name = "设备状态", readConverterExp = "1=完好,2=损坏,3=报废", combo = {"完好","损坏","报废"})
private String equipmentState;
/** 是否允许借出(1是,0否) */
@Excel(name = "是否允许借出", readConverterExp = "1=是,0=否", combo = {"是","否"})
private String isAllowLend;
/** 是否已借出(1是,0否) */
@Excel(name = "是否已借出", readConverterExp = "1=是,0=否", combo = {"是","否"})
private String isLend;
/** 投产日期 */
@JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "投产日期", width = 30, dateFormat = "yyyy-MM-dd")
private Date dateOfProduction;
/** 价格 */
@Excel(name = "价格(元)")
private BigDecimal price;
/** 效用年限(年) */
@Excel(name = "效用年限(年)")
private String lifeOfUtility;
/** 地点 */
@Excel(name = "地点")
private String place;
/** 使用人id */
@TableField(fill = FieldFill.UPDATE)
private Long useId;
/** 使用人 */
@TableField(fill = FieldFill.UPDATE)
@Excel(name = "使用人")
private String useName;
/** 备注 */
@Excel(name = "备注")
private String remark;
}
...@@ -104,6 +104,7 @@ public class StudentLeaveVO extends ProcessBaseEntity { ...@@ -104,6 +104,7 @@ public class StudentLeaveVO extends ProcessBaseEntity {
private String handUserName; private String handUserName;
/** 创建时间 */ /** 创建时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date createTime; private Date createTime;
......
...@@ -5,6 +5,7 @@ import cn.hutool.http.HttpUtil; ...@@ -5,6 +5,7 @@ import cn.hutool.http.HttpUtil;
import com.alibaba.fastjson2.JSONArray; import com.alibaba.fastjson2.JSONArray;
import com.alibaba.fastjson2.JSONObject; import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.ruoyi.common.core.domain.entity.SchoolTeacher; import com.ruoyi.common.core.domain.entity.SchoolTeacher;
import com.ruoyi.common.core.domain.entity.SysUser; import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.utils.SecurityUtils; import com.ruoyi.common.utils.SecurityUtils;
...@@ -116,7 +117,7 @@ public class DingJiaXiaoController { ...@@ -116,7 +117,7 @@ public class DingJiaXiaoController {
//更新年级与班级 //更新年级与班级
@GetMapping("/updateLabClassYear") @GetMapping("/updateLabClassYear")
private String updateLabClassYear(){ public String updateLabClassYear(){
String token = accessTokenUtils.getToken(); String token = accessTokenUtils.getToken();
//年级 //年级
List<SchoolGrade> schoolGradeCopies = new ArrayList<>(); List<SchoolGrade> schoolGradeCopies = new ArrayList<>();
...@@ -273,7 +274,7 @@ public class DingJiaXiaoController { ...@@ -273,7 +274,7 @@ public class DingJiaXiaoController {
//更新追加人员信息 //更新追加人员信息
@GetMapping("/updateLabUser") @GetMapping("/updateLabUser")
private String updateLabUser(){ public String updateLabUser(){
//查找当前学年 所有的班级 //查找当前学年 所有的班级
String nowSchoolYear = schoolGradeService.selectUpToYear(); String nowSchoolYear = schoolGradeService.selectUpToYear();
SchoolClass schoolClass = new SchoolClass(); SchoolClass schoolClass = new SchoolClass();
...@@ -304,11 +305,19 @@ public class DingJiaXiaoController { ...@@ -304,11 +305,19 @@ public class DingJiaXiaoController {
} }
SchoolTeacher classHeadTeacher = schoolTeacherCopies.get(0); SchoolTeacher classHeadTeacher = schoolTeacherCopies.get(0);
if ("1".equals(teachDate.getIsAdviser())){ if ("1".equals(teachDate.getIsAdviser())){
//当前老师是班主任 记录班主任跟班级关系 //查询数据库中是否有 没有新增
SchoolClassHeadmaster schoolClassHeadmaster = new SchoolClassHeadmaster(); LambdaQueryWrapper<SchoolClassHeadmaster> lqw=new LambdaQueryWrapper<>();
schoolClassHeadmaster.setTeacherId(classHeadTeacher.getId()); lqw.eq(SchoolClassHeadmaster::getTeacherId,classHeadTeacher.getId());
schoolClassHeadmaster.setClassId(date.getId()); lqw.eq(SchoolClassHeadmaster::getClassId,date.getId());
iSchoolClassHeadmasterService.save(schoolClassHeadmaster); List<SchoolClassHeadmaster> list = iSchoolClassHeadmasterService.list(lqw);
if (list.isEmpty()){
//当前老师是班主任 记录班主任跟班级关系
SchoolClassHeadmaster schoolClassHeadmaster = new SchoolClassHeadmaster();
schoolClassHeadmaster.setTeacherId(classHeadTeacher.getId());
schoolClassHeadmaster.setClassId(date.getId());
iSchoolClassHeadmasterService.save(schoolClassHeadmaster);
}
//设置班级 班主任信息 //设置班级 班主任信息
SchoolClass schoolClassss = new SchoolClass(); SchoolClass schoolClassss = new SchoolClass();
schoolClassss.setId(date.getId()); schoolClassss.setId(date.getId());
...@@ -317,44 +326,89 @@ public class DingJiaXiaoController { ...@@ -317,44 +326,89 @@ public class DingJiaXiaoController {
schoolClassss.setTeacherTel(classHeadTeacher.getTeacherTel()); schoolClassss.setTeacherTel(classHeadTeacher.getTeacherTel());
iSchoolClassService.updateById(schoolClassss); iSchoolClassService.updateById(schoolClassss);
}else { }else {
//查找部门 课程没有编写 //查找部门 课程没有编写
SysUser sysUser = sysUserService.selectUserById(classHeadTeacher.getId()); SysUser sysUser = sysUserService.selectUserById(classHeadTeacher.getId());
String deptName = sysUser.getDept().getDeptName(); String deptName = sysUser.getDept().getDeptName();
//根据部门查找课程信息 //根据部门查找课程信息
SchoolCurriculum schoolCurriculum = schoolCurriculumMapper.selectCourseName(deptName); SchoolCurriculum schoolCurriculum = schoolCurriculumMapper.selectCourseName(deptName);
//任课老师 跟班级关系
SchoolClassMentor schoolClassMentor = new SchoolClassMentor(); LambdaQueryWrapper<SchoolClassMentor> lqw=new LambdaQueryWrapper<>();
schoolClassMentor.setTeacherId(classHeadTeacher.getId()); lqw.eq(SchoolClassMentor::getTeacherId,classHeadTeacher.getId());
schoolClassMentor.setClassId(date.getId()); lqw.eq(SchoolClassMentor::getClassId,date.getId());
schoolClassMentor.setCourseName(schoolCurriculum.getCourseName()); List<SchoolClassMentor> list = schoolClassMentorService.list(lqw);
schoolClassMentor.setCourseId(schoolCurriculum.getId()); if (list.isEmpty()){
schoolClassMentorService.save(schoolClassMentor); //任课老师 跟班级关系
SchoolClassMentor schoolClassMentor = new SchoolClassMentor();
schoolClassMentor.setTeacherId(classHeadTeacher.getId());
schoolClassMentor.setClassId(date.getId());
schoolClassMentor.setCourseName(schoolCurriculum.getCourseName());
schoolClassMentor.setCourseId(schoolCurriculum.getId());
schoolClassMentorService.save(schoolClassMentor);
}else {
SchoolClassMentor schoolClassMentor = list.get(0);
schoolClassMentor.setCourseName(schoolCurriculum.getCourseName());
schoolClassMentor.setCourseId(schoolCurriculum.getId());
schoolClassMentorService.updateById(schoolClassMentor);
}
} }
} }
} else if (type.equals("student")) { } else if (type.equals("student")) {
//学生 //学生
studentUserInfos = this.addUserList(token, type, date.getDdClassId()); studentUserInfos = this.addUserList(token, type, date.getDdClassId());
for (DingJiaXiaoVo.StudentUserInfo studentDte : studentUserInfos) { for (DingJiaXiaoVo.StudentUserInfo studentDte : studentUserInfos) {
//学生信息 //当前是否有这个学生
SchoolStudent schoolStudent = new SchoolStudent(); Long ddUserId = null;
schoolStudent.setStudentName(studentDte.getName()); ddUserId = schoolStudentService.getDdUserId(studentDte.getUserId());
schoolStudent.setClassId(date.getId()); if (null == ddUserId ){
schoolStudent.setStudentStatus("1"); //学生信息
schoolStudent.setDdUserId(studentDte.getUserId()); SchoolStudent schoolStudent = new SchoolStudent();
schoolStudentService.save(schoolStudent); schoolStudent.setStudentName(studentDte.getName());
//学生班级信息 schoolStudent.setClassId(date.getId());
SchoolStudentClassRelation schoolStudentClassRelation = new SchoolStudentClassRelation(); schoolStudent.setStudentStatus("1");
schoolStudentClassRelation.setStudentId(schoolStudent.getId()); schoolStudent.setDdUserId(studentDte.getUserId());
schoolStudentClassRelation.setClassId(date.getId()); schoolStudentService.save(schoolStudent);
iSchoolStudentClassRelationService.save(schoolStudentClassRelation); ddUserId = schoolStudent.getId();
}else {
SchoolStudent schoolStudent = new SchoolStudent();
schoolStudent.setStudentName(studentDte.getName());
schoolStudent.setClassId(date.getId());
schoolStudent.setStudentStatus("1");
schoolStudent.setDdUserId(studentDte.getUserId());
schoolStudent.setId(ddUserId);
schoolStudentService.updateStudent(schoolStudent);
}
LambdaQueryWrapper<SchoolStudentClassRelation> lqw=new LambdaQueryWrapper<>();
lqw.eq(SchoolStudentClassRelation::getStudentId,ddUserId);
lqw.eq(SchoolStudentClassRelation::getClassId,date.getId());
List<SchoolStudentClassRelation> list = iSchoolStudentClassRelationService.list();
if (list.isEmpty()){
//学生班级信息
SchoolStudentClassRelation schoolStudentClassRelation = new SchoolStudentClassRelation();
schoolStudentClassRelation.setStudentId(ddUserId);
schoolStudentClassRelation.setClassId(date.getId());
iSchoolStudentClassRelationService.save(schoolStudentClassRelation);
}
//学生与班级历史关系 //学生与班级历史关系
SchoolClass school= iSchoolClassService.selectSchoolClassById(date.getId()); SchoolClass school= iSchoolClassService.selectSchoolClassById(date.getId());
SchoolStudentClasses schoolStudentClasses = new SchoolStudentClasses();
schoolStudentClasses.setStudentId(schoolStudent.getId());
schoolStudentClasses.setGrade(school.getGradeName()); LambdaQueryWrapper<SchoolStudentClasses> lsqw=new LambdaQueryWrapper<>();
schoolStudentClasses.setClasses(school.getClassName()); lsqw.eq(SchoolStudentClasses::getStudentId,ddUserId);
schoolStudentClasses.setTeacherName(school.getTeacherName()); lsqw.eq(SchoolStudentClasses:: getGrade,school.getGradeName());
schoolStudentClassesService.save(schoolStudentClasses); lsqw.eq(SchoolStudentClasses:: getClasses,school.getClassName());
lsqw.eq(SchoolStudentClasses:: getTeacherName,school.getTeacherName());
List<SchoolStudentClasses> list1 = schoolStudentClassesService.list(lsqw);
if (list1.isEmpty()){
SchoolStudentClasses schoolStudentClasses = new SchoolStudentClasses();
schoolStudentClasses.setStudentId(ddUserId);
schoolStudentClasses.setGrade(school.getGradeName());
schoolStudentClasses.setClasses(school.getClassName());
schoolStudentClasses.setTeacherName(school.getTeacherName());
schoolStudentClassesService.save(schoolStudentClasses);
}
} }
} else if (type.equals("guardian")) { } else if (type.equals("guardian")) {
//监护人 //监护人
...@@ -363,31 +417,63 @@ public class DingJiaXiaoController { ...@@ -363,31 +417,63 @@ public class DingJiaXiaoController {
//找寻学生 //找寻学生
String toUserId = this.getToUserId(token, guarDate.getUserId(), date.getDdClassId()); String toUserId = this.getToUserId(token, guarDate.getUserId(), date.getDdClassId());
Long ddUserId = schoolStudentService.getDdUserId(toUserId); Long ddUserId = schoolStudentService.getDdUserId(toUserId);
Long userId = null;
//创建用户user表 //查找监护人
SysUser jUser = new SysUser(); SysUser sysUser = sysUserService.selectUserByDdUserId(ddUserId.toString());
jUser.setLoginName(guarDate.getName()); if (null == sysUser){
jUser.setUserName(guarDate.getName()); //创建用户user表
jUser.setUserType("01"); SysUser jUser = new SysUser();
jUser.setUserLoginType("1"); jUser.setLoginName(guarDate.getName());
jUser.setPhonenumber(guarDate.getMobile()); jUser.setUserName(guarDate.getName());
jUser.setPassword(SecurityUtils.encryptPassword("123#@!")); jUser.setUserType("01");
jUser.setStatus("0"); jUser.setUserLoginType("1");
jUser.setDelFlag("0"); jUser.setPhonenumber(guarDate.getMobile());
jUser.setUnionId(guarDate.getUnionid()); jUser.setPassword(SecurityUtils.encryptPassword("123#@!"));
jUser.setDdUserId(guarDate.getUserId()); jUser.setStatus("0");
jUser.setRoleIds(new Long[]{111L}); jUser.setDelFlag("0");
jUser.setStudentId(ddUserId); jUser.setUnionId(guarDate.getUnionid());
sysUserService.insertUser(jUser); jUser.setDdUserId(guarDate.getUserId());
jUser.setRoleIds(new Long[]{111L});
jUser.setStudentId(ddUserId);
sysUserService.insertUser(jUser);
userId = jUser.getUserId();
}else {
userId = sysUser.getUserId();
sysUser.setLoginName(guarDate.getName());
sysUser.setUserName(guarDate.getName());
sysUser.setUserType("01");
sysUser.setUserLoginType("1");
sysUser.setPhonenumber(guarDate.getMobile());
sysUser.setStatus("0");
sysUser.setUnionId(guarDate.getUnionid());
sysUser.setDdUserId(guarDate.getUserId());
sysUser.setStudentId(ddUserId);
sysUserService.updateUser(sysUser);
}
//家长表 //家长表
SchoolStudentParent schoolStudentParent = new SchoolStudentParent() ; LambdaQueryWrapper<SchoolStudentParent> lsqw=new LambdaQueryWrapper<>();
schoolStudentParent.setStudentId(ddUserId); lsqw.eq(SchoolStudentParent::getUserId,userId);
schoolStudentParent.setUserId(jUser.getUserId()); lsqw.eq(SchoolStudentParent::getStudentId,ddUserId);
schoolStudentParent.setParentName(guarDate.getName()); List<SchoolStudentParent> list = iSchoolStudentParentService.list(lsqw);
schoolStudentParent.setTelephone(guarDate.getMobile()); if (list.isEmpty()){
Integer patriarch = this.getPatriarch(guarDate.getName().substring(guarDate.getName().length() - 2)); SchoolStudentParent schoolStudentParent = new SchoolStudentParent() ;
schoolStudentParent.setRelationship(String.valueOf(patriarch)); schoolStudentParent.setStudentId(ddUserId);
iSchoolStudentParentService.save(schoolStudentParent); schoolStudentParent.setUserId(userId);
schoolStudentParent.setParentName(guarDate.getName());
schoolStudentParent.setTelephone(guarDate.getMobile());
Integer patriarch = this.getPatriarch(guarDate.getName().substring(guarDate.getName().length() - 2));
schoolStudentParent.setRelationship(String.valueOf(patriarch));
iSchoolStudentParentService.save(schoolStudentParent);
}else {
SchoolStudentParent schoolStudentParent1 = list.get(0);
schoolStudentParent1.setStudentId(ddUserId);
schoolStudentParent1.setUserId(userId);
schoolStudentParent1.setParentName(guarDate.getName());
schoolStudentParent1.setTelephone(guarDate.getMobile());
Integer patriarch = this.getPatriarch(guarDate.getName().substring(guarDate.getName().length() - 2));
schoolStudentParent1.setRelationship(String.valueOf(patriarch));
iSchoolStudentParentService.updateById(schoolStudentParent1);
}
} }
} }
} }
......
...@@ -93,7 +93,7 @@ public class EquipmentLeaseController { ...@@ -93,7 +93,7 @@ public class EquipmentLeaseController {
calendar.add(Calendar.DATE,Integer.valueOf(deadline.toString())); calendar.add(Calendar.DATE,Integer.valueOf(deadline.toString()));
Date targetDate = calendar.getTime(); Date targetDate = calendar.getTime();
schoolCirculation.setReturnState("0"); schoolCirculation.setReturnState("0");
schoolCirculation.setReturnTime(targetDate); schoolCirculation.setYjuseTime(targetDate);
boolean save = iCirculationService.save(schoolCirculation); boolean save = iCirculationService.save(schoolCirculation);
//修改设备表借出状态 //修改设备表借出状态
SchoolEquipmentLedger byId = iEquipmentService.getById(schoolCirculation.getEquipmentId()); SchoolEquipmentLedger byId = iEquipmentService.getById(schoolCirculation.getEquipmentId());
...@@ -258,29 +258,37 @@ public class EquipmentLeaseController { ...@@ -258,29 +258,37 @@ public class EquipmentLeaseController {
* 管理员查看详情 * 管理员查看详情
*/ */
@GetMapping("/getReturningEquipmentByList/{encode}") @GetMapping("/getReturningEquipmentByList/{encode}")
private AjaxResult getReturningEquipmentByList(@PathVariable("encode") String encode){ private AjaxResult getReturningEquipmentByList(@PathVariable("encode") String encode) {
SchoolCirculationVo schoolCirculationVo = new SchoolCirculationVo(); SchoolCirculationVo schoolCirculationVo = new SchoolCirculationVo();
//先查询物品表有没有借出去 //先查询物品表有没有借出去
LambdaQueryWrapper<SchoolEquipmentLedger> wrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<SchoolEquipmentLedger> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolEquipmentLedger::getEncode,encode); wrapper.eq(SchoolEquipmentLedger::getEncode, encode);
SchoolEquipmentLedger one = iEquipmentService.getOne(wrapper); SchoolEquipmentLedger one = iEquipmentService.getOne(wrapper);
if (one.getIsLend().equals("0")){ if (one.getIsLend().equals("0")) {
//未借出 //未借出
schoolCirculationVo.setEquipmentId(one.getId()); schoolCirculationVo.setEquipmentId(one.getId());
schoolCirculationVo.setEquipmentName(one.getEquipmentName()); schoolCirculationVo.setEquipmentName(one.getEquipmentName());
schoolCirculationVo.setModel(one.getModel()); schoolCirculationVo.setModel(one.getModel());
schoolCirculationVo.setIsLend(one.getIsLend()); schoolCirculationVo.setIsLend(one.getIsLend());
return AjaxResult.success(schoolCirculationVo); return AjaxResult.success(schoolCirculationVo);
}else { } else {
//已借出 //已借出
SchoolCirculationVo schoolCirculationVoByenCode = iCirculationService SchoolCirculationVo schoolCirculationVoByenCode = iCirculationService
.getSchoolCirculationVoByenCode(encode); .getSchoolCirculationVoByenCode(encode);
//根据管理员信息查看信息详情 //根据管理员信息查看信息详情
return AjaxResult.success(schoolCirculationVoByenCode); return AjaxResult.success(schoolCirculationVoByenCode);
}
}
}
@GetMapping("/getReturningEquipmentById/{id}")
public AjaxResult getReturningEquipmentById(@PathVariable("id") String id){
SchoolCirculationVo schoolCirculationVoByenCode = iCirculationService
.getReturningEquipmentById(id);
//根据管理员信息查看信息详情
return AjaxResult.success(schoolCirculationVoByenCode);
} }
/** /**
* 管理员归还操作 * 管理员归还操作
*/ */
...@@ -291,6 +299,7 @@ public class EquipmentLeaseController { ...@@ -291,6 +299,7 @@ public class EquipmentLeaseController {
//修改设备表借出状态 //修改设备表借出状态
SchoolEquipmentLedger byId = iEquipmentService.getById(schoolCirculation.getEquipmentId()); SchoolEquipmentLedger byId = iEquipmentService.getById(schoolCirculation.getEquipmentId());
byId.setIsLend("0"); byId.setIsLend("0");
byId.setEquipmentState(schoolCirculation.getReturnEquipmentCondition());
iEquipmentService.updateById(byId); iEquipmentService.updateById(byId);
return AjaxResult.success(b); return AjaxResult.success(b);
} }
......
...@@ -5,6 +5,7 @@ import com.ruoyi.common.core.controller.BaseController; ...@@ -5,6 +5,7 @@ import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
import java.text.ParseException; import java.text.ParseException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date; import java.util.Date;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
...@@ -54,8 +55,12 @@ public class ExperimentAdministratorsControoler extends BaseController { ...@@ -54,8 +55,12 @@ public class ExperimentAdministratorsControoler extends BaseController {
@GetMapping("/classYear/list") @GetMapping("/classYear/list")
public AjaxResult classYearList(SchoolLabClassYearVo schoolLabClassYearVo) public AjaxResult classYearList(SchoolLabClassYearVo schoolLabClassYearVo)
{ {
schoolLabClassYearVo.setSub(schoolLabClassYearService.getSub()); schoolLabClassYearVo.setSub(schoolLabClassYearService.getSub());
List<String> listSt =new ArrayList<>();
listSt.add("1");
listSt.add("2");
listSt.add("3");
schoolLabClassYearVo.setDeclareStates(listSt);
return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYearVo)); return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYearVo));
} }
......
...@@ -8,9 +8,10 @@ import com.ruoyi.common.core.domain.entity.SysDept; ...@@ -8,9 +8,10 @@ import com.ruoyi.common.core.domain.entity.SysDept;
import com.ruoyi.common.core.domain.entity.SysUser; import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType; import com.ruoyi.common.enums.BusinessType;
import java.util.Calendar;
import java.util.List;
import java.util.*;
import com.ruoyi.framework.util.UserInfoUtil;
import com.ruoyi.system.service.ISysDeptService; import com.ruoyi.system.service.ISysDeptService;
import com.ruoyi.system.service.ISysUserService; import com.ruoyi.system.service.ISysUserService;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -20,6 +21,7 @@ import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply; ...@@ -20,6 +21,7 @@ import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
import yangtz.cs.liu.campus.domain.schoolgrade.SchoolGrade; import yangtz.cs.liu.campus.domain.schoolgrade.SchoolGrade;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherLabApplyMapper; import yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherLabApplyMapper;
import yangtz.cs.liu.campus.service.schoolClass.ISchoolClassMentorService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolExperimentPlanService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolExperimentPlanService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService;
...@@ -30,6 +32,7 @@ import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo; ...@@ -30,6 +32,7 @@ import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
import java.util.List; import java.util.List;
import java.util.stream.Collectors;
/** /**
* 实验室 级部申请 * 实验室 级部申请
...@@ -57,6 +60,11 @@ public class ExperimentLevelController extends BaseController { ...@@ -57,6 +60,11 @@ public class ExperimentLevelController extends BaseController {
@Autowired @Autowired
private ISysDeptService deptService; private ISysDeptService deptService;
@Autowired
UserInfoUtil userInfoUtil;
@Autowired
private ISchoolClassMentorService schoolClassMentorService;
/** /**
* 获取当前学年+学期 * 获取当前学年+学期
*/ */
...@@ -154,7 +162,17 @@ public class ExperimentLevelController extends BaseController { ...@@ -154,7 +162,17 @@ public class ExperimentLevelController extends BaseController {
@GetMapping("/list") @GetMapping("/list")
public AjaxResult list(SchoolLabClassYearVo schoolLabClassYear) public AjaxResult list(SchoolLabClassYearVo schoolLabClassYear)
{ {
schoolLabClassYear.setApplyId(schoolLabClassYear.getUserId()); Long userId = userInfoUtil.getMpLoginUser().getUserId();
Long gradeId = schoolGradeService.getGradeId(userId);
//根据当前角色查看对应的学科
//获取学科
Map<String, String> map = schoolClassMentorService.selectTeacherGroupMentot(userId);
String s = map.get("courseId");
List<String> list = Arrays.asList(s.split(","));
List<String> myList = list.stream().distinct().collect(Collectors.toList());
List<String> strings = schoolLabClassYearService.convertMentor(myList);
schoolLabClassYear.setSubs(strings);
schoolLabClassYear.setGradeId(gradeId);
return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYear)); return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYear));
} }
...@@ -205,6 +223,9 @@ public class ExperimentLevelController extends BaseController { ...@@ -205,6 +223,9 @@ public class ExperimentLevelController extends BaseController {
*/ */
@GetMapping("/getexperimentList") @GetMapping("/getexperimentList")
public AjaxResult getexperimentList(ClassSituationVo classSituationVo){ public AjaxResult getexperimentList(ClassSituationVo classSituationVo){
//获取管理员学科
String sub = schoolLabClassYearService.getSub();
classSituationVo.setSub(sub);
List<ClassSituationVo> classSituationVos = schoolLabClassYearService.getexperimentList( List<ClassSituationVo> classSituationVos = schoolLabClassYearService.getexperimentList(
classSituationVo); classSituationVo);
return AjaxResult.success(classSituationVos); return AjaxResult.success(classSituationVos);
......
...@@ -29,9 +29,7 @@ import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo; ...@@ -29,9 +29,7 @@ import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherExperimentApplyVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherExperimentApplyVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
import java.util.Arrays; import java.util.*;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors; import java.util.stream.Collectors;
/** /**
...@@ -145,7 +143,10 @@ public class TeacherExperimentController extends BaseController { ...@@ -145,7 +143,10 @@ public class TeacherExperimentController extends BaseController {
*/ */
@GetMapping(value = "/list") @GetMapping(value = "/list")
public AjaxResult list(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo) public AjaxResult list(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
Long userId = userInfoUtil.getMpLoginUser().getUserId();
schoolTeacherLabApplyVo.setApplyId(userId);
return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo)); return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo));
} }
/** /**
...@@ -183,21 +184,25 @@ public class TeacherExperimentController extends BaseController { ...@@ -183,21 +184,25 @@ public class TeacherExperimentController extends BaseController {
@GetMapping("/getSubject") @GetMapping("/getSubject")
public AjaxResult getSubject(){ public AjaxResult getSubject(){
Long userId = userInfoUtil.getMpLoginUser().getUserId(); Long userId = userInfoUtil.getMpLoginUser().getUserId();
List<SysRole> sysRoles = roleService.selectRolesByUserIdDdApp(userId); Map<String,String> mapList = new HashMap<>();
for (SysRole role : sysRoles) { //设置级部
if (role.getRoleKey().equals("phy_lab_admin")){ //获取学科
return AjaxResult.success(dictDataService.selectDictLabel("lab_sub","1")); Map<String, String> map = schoolClassMentorService.selectTeacherGroupMentot(userId);
}else if (role.getRoleKey().equals("che_lab_admin")){ String s = map.get("courseId");
return AjaxResult.success(dictDataService.selectDictLabel("lab_sub","2")); List<String> list = Arrays.asList(s.split(","));
}else if (role.getRoleKey().equals("bio_lab_admin")){ List<String> myList = list.stream().distinct().collect(Collectors.toList());
return AjaxResult.success(dictDataService.selectDictLabel("lab_sub","3")); List<String> strings = schoolLabClassYearService.convertMentor(myList);
for (String date : strings){
if (date.equals("1")){
mapList.put("物理","1");
}else if (date.equals("2")){
mapList.put("化学","2");
}else if (date.equals("3")){
mapList.put("生物","3");
} }
} }
return AjaxResult.success("当前用户未分配学科角色"); return AjaxResult.success(mapList);
} }
/** /**
*新增申请 *新增申请
*/ */
......
...@@ -8,6 +8,7 @@ import com.ruoyi.common.enums.BusinessType; ...@@ -8,6 +8,7 @@ import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.framework.util.UserInfoUtil; import com.ruoyi.framework.util.UserInfoUtil;
import java.util.List; import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
...@@ -18,7 +19,9 @@ import org.springframework.web.bind.annotation.RequestBody; ...@@ -18,7 +19,9 @@ import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab;
import yangtz.cs.liu.campus.service.impl.schoolLab.SchoolLabClassYearServiceImpl;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
/** /**
...@@ -33,16 +36,17 @@ public class WxSchoolLabControoler extends BaseController { ...@@ -33,16 +36,17 @@ public class WxSchoolLabControoler extends BaseController {
@Autowired @Autowired
private UserInfoUtil userInfoUtil; private UserInfoUtil userInfoUtil;
@Autowired
private SchoolLabClassYearServiceImpl schoolLabClassYearService;
/** /**
* 查询实验室列表 * 查询实验室列表
*/ */
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(SchoolLabVo schoolLabVo) public AjaxResult list(SchoolLabClassYearVo schoolLabClassYearVo)
{ {
startPage(); List<Map<String, Object>> labList = schoolLabClassYearService.getLabList(schoolLabClassYearVo);
Long teacherUserId = userInfoUtil.getMpLoginUser().getUserId(); return AjaxResult.success(labList);
List<SchoolLabVo> list = schoolLabService.selectSchoolLabList(schoolLabVo,teacherUserId);
return getDataTable(list);
} }
/** /**
......
...@@ -155,8 +155,7 @@ public class WxSchoolOrganizationController extends BaseController { ...@@ -155,8 +155,7 @@ public class WxSchoolOrganizationController extends BaseController {
//根据当前登录人 查询当前社团的报名状态 //根据当前登录人 查询当前社团的报名状态
LambdaQueryWrapper<SchoolOrganizationSignin> wrapper = Wrappers.lambdaQuery(); LambdaQueryWrapper<SchoolOrganizationSignin> wrapper = Wrappers.lambdaQuery();
wrapper.eq(SchoolOrganizationSignin::getUserId,userId) wrapper.eq(SchoolOrganizationSignin::getUserId,userId)
.eq(SchoolOrganizationSignin::getCid,vo.getCid()) .eq(SchoolOrganizationSignin::getCid,vo.getCid());
.eq(SchoolOrganizationSignin::getDelFlag,"0");
SchoolOrganizationSignin one = schoolOrganizationSigninService.getOne(wrapper); SchoolOrganizationSignin one = schoolOrganizationSigninService.getOne(wrapper);
if (one==null){ if (one==null){
//根据studentId 获取当前登录人信息 返回给前端 //根据studentId 获取当前登录人信息 返回给前端
......
...@@ -63,6 +63,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -63,6 +63,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
<if test="borrowTime != null">and DATE_FORMAT(c.borrow_time,'%Y-%m-%d') = DATE_FORMAT(#{borrowTime},'%Y-%m-%d')</if> <if test="borrowTime != null">and DATE_FORMAT(c.borrow_time,'%Y-%m-%d') = DATE_FORMAT(#{borrowTime},'%Y-%m-%d')</if>
<if test="borrowById != null">and c.borrow_by_id = #{borrowById}</if> <if test="borrowById != null">and c.borrow_by_id = #{borrowById}</if>
order by c.create_time DESC
</select> </select>
<select id="selectSchoolCirculationVoListGr" parameterType="SchoolCirculationVo" resultMap="schoolCirculationVoResult"> <select id="selectSchoolCirculationVoListGr" parameterType="SchoolCirculationVo" resultMap="schoolCirculationVoResult">
...@@ -99,6 +100,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -99,6 +100,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
<if test="borrowTime != null">and DATE_FORMAT(c.borrow_time,,'%Y-%m-%d') = DATE_FORMAT(#{borrowTime},'%Y-%m-%d')</if> <if test="borrowTime != null">and DATE_FORMAT(c.borrow_time,,'%Y-%m-%d') = DATE_FORMAT(#{borrowTime},'%Y-%m-%d')</if>
<if test="borrowById != null">and c.borrow_by_id = #{borrowById}</if> <if test="borrowById != null">and c.borrow_by_id = #{borrowById}</if>
order by c.create_time DESC
</select> </select>
<select id="selectSchoolCirculationVoById" parameterType="Long" resultMap="schoolCirculationVoResult"> <select id="selectSchoolCirculationVoById" parameterType="Long" resultMap="schoolCirculationVoResult">
......
...@@ -42,6 +42,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -42,6 +42,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''" >and el.equipment_state = #{equipmentState}</if> <if test="equipmentState != null and equipmentState != ''" >and el.equipment_state = #{equipmentState}</if>
<if test="affiliationType != null and affiliationType != ''" >and el.affiliation_type = #{affiliationType}</if> <if test="affiliationType != null and affiliationType != ''" >and el.affiliation_type = #{affiliationType}</if>
order by el.create_time DESC
</select> </select>
<select id="selectSchoolEquipmentLedgerListGr" parameterType="SchoolEquipmentLedgerVo" resultMap="schoolEquipmentLedgerResult"> <select id="selectSchoolEquipmentLedgerListGr" parameterType="SchoolEquipmentLedgerVo" resultMap="schoolEquipmentLedgerResult">
...@@ -56,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -56,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''" >and el.equipment_state = #{equipmentState}</if> <if test="equipmentState != null and equipmentState != ''" >and el.equipment_state = #{equipmentState}</if>
<if test="affiliationType != null and affiliationType != ''" >and el.affiliation_type = #{affiliationType}</if> <if test="affiliationType != null and affiliationType != ''" >and el.affiliation_type = #{affiliationType}</if>
order by el.create_time DESC
</select> </select>
<update id="outSchoolEquipmentLedger" parameterType="String"> <update id="outSchoolEquipmentLedger" parameterType="String">
...@@ -79,4 +81,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -79,4 +81,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND user_name like concat('%', #{userName}, '%') AND user_name like concat('%', #{userName}, '%')
</if> </if>
</select> </select>
<select id="getEquipmentledger" parameterType="String" resultType="Map">
select id as id, encode as encode, equipment_name as equipmentName, model as model, place as place from school_equipment_ledger where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</select>
</mapper> </mapper>
...@@ -30,6 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -30,6 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by" /> <result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="delFalg" column="del_flag" /> <result property="delFalg" column="del_flag" />
<result property="place" column="place" />
</resultMap> </resultMap>
<select id="selectSchoolEquipmentRepairVoList" parameterType="SchoolEquipmentRepairVo" resultMap="schoolEquipmentRepairVoResult"> <select id="selectSchoolEquipmentRepairVoList" parameterType="SchoolEquipmentRepairVo" resultMap="schoolEquipmentRepairVoResult">
...@@ -40,7 +41,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -40,7 +41,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
el.equipment_name, el.equipment_name,
el.model, el.model,
el.date_of_production, el.date_of_production,
el.place, er.place,
el.classification_code, el.classification_code,
er.report_repair_time, er.report_repair_time,
er.report_repair_id, er.report_repair_id,
...@@ -65,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -65,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="repairState != null and repairState != ''">and er.repair_state = #{repairState}</if> <if test="repairState != null and repairState != ''">and er.repair_state = #{repairState}</if>
<if test="disposeState != null and disposeState != ''">and er.dispose_state = #{disposeState}</if> <if test="disposeState != null and disposeState != ''">and er.dispose_state = #{disposeState}</if>
order by er.create_time DESC
</select> </select>
<select id="selectSchoolEquipmentRepairVoListGr" parameterType="SchoolEquipmentRepairVo" resultMap="schoolEquipmentRepairVoResult"> <select id="selectSchoolEquipmentRepairVoListGr" parameterType="SchoolEquipmentRepairVo" resultMap="schoolEquipmentRepairVoResult">
...@@ -75,7 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -75,7 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
el.equipment_name, el.equipment_name,
el.model, el.model,
el.date_of_production, el.date_of_production,
el.place, er.place,
el.classification_code, el.classification_code,
er.report_repair_time, er.report_repair_time,
er.report_repair_id, er.report_repair_id,
...@@ -100,27 +102,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -100,27 +102,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''" >and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="repairState != null and repairState != ''">and er.repair_state = #{repairState}</if> <if test="repairState != null and repairState != ''">and er.repair_state = #{repairState}</if>
<if test="disposeState != null and disposeState != ''">and er.dispose_state = #{disposeState}</if> <if test="disposeState != null and disposeState != ''">and er.dispose_state = #{disposeState}</if>
order by er.create_time DESC
</select> </select>
<select id="getMaintenanceUserList" parameterType="SchoolReceiveQuery" resultMap="schoolEquipmentRepairVoResult"> <select id="getMaintenanceUserList" parameterType="SchoolReceiveQuery" resultMap="schoolEquipmentRepairVoResult">
SELECT er.id,er.equipment_id,el.encode,er.dispose_state,el.equipment_name,el.model,el.date_of_production,el.place , SELECT er.id,er.equipment_id,el.encode,er.dispose_state,er.place,el.equipment_name,el.model,el.date_of_production,el.place ,
el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem, el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,
er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark
FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id
where er.del_flag=0 where er.del_flag=0 and er.dispose_state = 0
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
</select> </select>
<select id="getMaintenanceList" parameterType="SchoolReceiveQuery" resultMap="schoolEquipmentRepairVoResult"> <select id="getMaintenanceList" parameterType="SchoolReceiveQuery" resultMap="schoolEquipmentRepairVoResult">
SELECT er.id,er.equipment_id,el.encode,er.dispose_state,el.equipment_name,el.model,el.date_of_production,el.place , SELECT er.id,er.equipment_id,el.encode,er.dispose_state,er.place,el.equipment_name,el.model,el.date_of_production,el.place ,
el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem, el.classification_code,er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,
er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark er.repair_id,er.evaluate,er.repair_name,er.repair_phone,er.repair_time,er.repair_state,er.remark
FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id WHERE er.report_repair_id=#{reportRepairid} and er.del_flag=0 FROM school_equipment_repair er LEFT JOIN school_equipment_ledger el ON er.equipment_id=el.id WHERE er.report_repair_id=#{reportRepairid} and er.del_flag=0
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
ORDER BY er.report_repair_time DESC
</select> </select>
...@@ -133,7 +135,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -133,7 +135,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
el.equipment_name, el.equipment_name,
el.model, el.model,
el.date_of_production, el.date_of_production,
el.place, er.place,
el.classification_code, el.classification_code,
er.report_repair_time, er.report_repair_time,
er.report_repair_id, er.report_repair_id,
...@@ -155,12 +157,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -155,12 +157,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getAdminList" parameterType="SchoolReceiveQuery" resultMap="schoolEquipmentRepairVoResult"> <select id="getAdminList" parameterType="SchoolReceiveQuery" resultMap="schoolEquipmentRepairVoResult">
SELECT er.id,er.equipment_id,el.encode,el.equipment_name,el.model,el.date_of_production,el.place,el.classification_code, SELECT er.id,er.equipment_id,el.encode,el.equipment_name,el.model,el.date_of_production,er.place,el.place,el.classification_code,
er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,er.repair_id,er.repair_name,er.repair_phone, er.report_repair_time,er.report_repair_id,er.report_repair,er.problem,er.repair_id,er.repair_name,er.repair_phone,
er.repair_time,er.repair_state,er.dispose_state,er.evaluate,er.remark FROM school_equipment_repair er LEFT JOIN er.repair_time,er.repair_state,er.dispose_state,er.evaluate,er.remark FROM school_equipment_repair er LEFT JOIN
school_equipment_ledger el on er.equipment_id = el.id LEFT JOIN school_product_category pc school_equipment_ledger el on er.equipment_id = el.id LEFT JOIN school_product_category pc
on pc.classification_code = el.classification_code WHERE pc.admin_id=#{reportRepairid} AND er.del_flag=0 on pc.classification_code = el.classification_code WHERE pc.admin_id=#{reportRepairid} AND er.del_flag=0
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
ORDER BY er.report_repair_time DESC
</select> </select>
...@@ -177,6 +180,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -177,6 +180,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
school_equipment_ledger school_equipment_ledger
WHERE WHERE
encode = #{encode} encode = #{encode}
and del_flag = '0'
</select> </select>
......
...@@ -67,6 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -67,6 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if> <if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if>
<if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if> <if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by i.create_time DESC
</select> </select>
<select id="selectSchoolInStockVoListGr" parameterType="SchoolInStockVo" resultMap="schoolInStockVoResult"> <select id="selectSchoolInStockVoListGr" parameterType="SchoolInStockVo" resultMap="schoolInStockVoResult">
...@@ -105,6 +106,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -105,6 +106,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if> <if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if>
<if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if> <if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by i.create_time DESC
</select> </select>
<select id="selectSchoolInStockVoById" parameterType="Long" resultMap="schoolInStockVoResult"> <select id="selectSchoolInStockVoById" parameterType="Long" resultMap="schoolInStockVoResult">
......
...@@ -67,6 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -67,6 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if> <if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if>
<if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if> <if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by create_time DESC
</select> </select>
<select id="selectSchoolOutStockVoListGr" parameterType="SchoolOutStockVo" resultMap="schoolOutStockVoResult"> <select id="selectSchoolOutStockVoListGr" parameterType="SchoolOutStockVo" resultMap="schoolOutStockVoResult">
...@@ -105,6 +106,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -105,6 +106,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if> <if test="affiliationType != null and affiliationType != ''">and el.affiliation_type = #{affiliationType}</if>
<if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if> <if test="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if> <if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by create_time DESC
</select> </select>
<select id="selectSchoolOutStockVoById" parameterType="Long" resultMap="schoolOutStockVoResult"> <select id="selectSchoolOutStockVoById" parameterType="Long" resultMap="schoolOutStockVoResult">
......
...@@ -57,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -57,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
r.del_flag = '0' r.del_flag = '0'
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
<if test="recipientBy != null and recipientBy != ''">and r.recipient_by like concat('%', #{recipientBy}, '%')</if> <if test="recipientBy != null and recipientBy != ''">and r.recipient_by like concat('%', #{recipientBy}, '%')</if>
order by r.create_time DESC
</select> </select>
<select id="selectSchoolReceiveVoListGr" parameterType="SchoolReceiveVo" resultMap="schoolReceiveVoResult"> <select id="selectSchoolReceiveVoListGr" parameterType="SchoolReceiveVo" resultMap="schoolReceiveVoResult">
...@@ -89,6 +90,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -89,6 +90,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
r.del_flag = '0' and u.user_id = #{adminId} r.del_flag = '0' and u.user_id = #{adminId}
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if> <if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
<if test="recipientBy != null and recipientBy != ''">and r.recipient_by like concat('%', #{recipientBy}, '%')</if> <if test="recipientBy != null and recipientBy != ''">and r.recipient_by like concat('%', #{recipientBy}, '%')</if>
order by r.create_time DESC
</select> </select>
<select id="selectSchoolReceiveVoById" parameterType="Long" resultMap="schoolReceiveVoResult"> <select id="selectSchoolReceiveVoById" parameterType="Long" resultMap="schoolReceiveVoResult">
......
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
AND gm.teacher_id = #{teacherId} AND gm.teacher_id = #{teacherId}
</if> </if>
</where> </where>
order by create_time DESC order by cy.create_time DESC
</select> </select>
<select id="selectExperimentPlanListAdmin" parameterType="SchoolExperimentPlanVo" resultMap="SchoolExperimentPlanVoResult"> <select id="selectExperimentPlanListAdmin" parameterType="SchoolExperimentPlanVo" resultMap="SchoolExperimentPlanVoResult">
......
...@@ -86,6 +86,12 @@ ...@@ -86,6 +86,12 @@
#{declareState} #{declareState}
</foreach> </foreach>
</if> </if>
<if test="subs != null">
and lcy.sub in
<foreach item="sub" collection="subs" open="(" separator="," close=")">
#{sub}
</foreach>
</if>
</where> </where>
order by create_time DESC order by create_time DESC
</select> </select>
...@@ -339,6 +345,7 @@ ...@@ -339,6 +345,7 @@
LEFT JOIN school_lab_class_year cy on cy.experiment_plan_id = ep.id LEFT JOIN school_lab_class_year cy on cy.experiment_plan_id = ep.id
WHERE ep.school_year = #{schoolYear} AND ep.semester =#{semester} AND ep.del_flag = 0 AND pc.del_flag=0 WHERE ep.school_year = #{schoolYear} AND ep.semester =#{semester} AND ep.del_flag = 0 AND pc.del_flag=0
<if test="querText != null "> and concat(ep.experiment_name,ep.grade ) like concat('%', #{querText}, '%') </if> <if test="querText != null "> and concat(ep.experiment_name,ep.grade ) like concat('%', #{querText}, '%') </if>
<if test="sub != null "> and ep.sub = #{sub} </if>
GROUP BY ep.id GROUP BY ep.id
</select> </select>
</mapper> </mapper>
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
<result property="id" column="id" /> <result property="id" column="id" />
<result property="teacherId" column="teacher_id" /> <result property="teacherId" column="teacher_id" />
<result property="teacherName" column="teacher_name" /> <result property="teacherName" column="teacher_name" />
<result property="teacherTel" column="teacher_tel" />
<result property="idCard" column="id_card" /> <result property="idCard" column="id_card" />
<result property="basePay" column="base_pay" /> <result property="basePay" column="base_pay" />
<result property="bonus" column="bonus" /> <result property="bonus" column="bonus" />
...@@ -29,7 +30,7 @@ ...@@ -29,7 +30,7 @@
</resultMap> </resultMap>
<sql id="selectSchoolTeacherWagesVo"> <sql id="selectSchoolTeacherWagesVo">
select id, teacher_id, teacher_name, id_card, base_pay, bonus, pension, accumulation_fund, medical_insurance, fare_subsidy, telephone_subsidy, meal_allowance, income_tax, unemployment_benefits, overtime_pay, pay_slip_url, wages_time, remarks from school_teacher_wages select id, teacher_id, teacher_name, teacher_tel, id_card, base_pay, bonus, pension, accumulation_fund, medical_insurance, fare_subsidy, telephone_subsidy, meal_allowance, income_tax, unemployment_benefits, overtime_pay, pay_slip_url, wages_time, remarks from school_teacher_wages
</sql> </sql>
<select id="queryList" parameterType="SchoolTeacherWages" resultMap="SchoolTeacherWagesResult"> <select id="queryList" parameterType="SchoolTeacherWages" resultMap="SchoolTeacherWagesResult">
...@@ -55,4 +56,15 @@ ...@@ -55,4 +56,15 @@
order by create_time desc order by create_time desc
</select> </select>
<insert id="batchInsertTeacherWages">
insert into school_teacher_wages(teacher_id, teacher_name, teacher_tel, base_pay, bonus, pension, accumulation_fund, medical_insurance,
fare_subsidy, telephone_subsidy, meal_allowance, income_tax, unemployment_benefits, overtime_pay, wages_time, remarks, create_by, create_time )
values
<foreach collection="list" item="item" separator=",">
(#{item.teacherId}, #{item.teacherName}, #{item.teacherTel}, #{item.basePay}, #{item.bonus}, #{item.pension}, #{item.accumulationFund},
#{item.medicalInsurance}, #{item.fareSubsidy}, #{item.telephoneSubsidy}, #{item.mealAllowance}, #{item.incomeTax}, #{item.unemploymentBenefits},
#{item.overtimePay}, #{item.wagesTime}, #{item.remarks}, #{item.createBy}, #{item.createTime})
</foreach>
</insert>
</mapper> </mapper>
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
<select id="shebeilist2" parameterType="ShebeiBx" resultMap="ShebeiBxResult"> <select id="shebeilist2" parameterType="ShebeiBx" resultMap="ShebeiBxResult">
SELECT ser.id,encode,equipment_name,model,date_of_production,place,report_repair_time,problem,repair_name,repair_id,repair_time,repair_state,evaluate,ser.remark SELECT ser.id,encode,report_repair_id,equipment_name,model,date_of_production,ser.place,report_repair_time,report_repair,problem,repair_name,repair_id,repair_time,repair_state,evaluate,ser.remark
FROM school_equipment_repair ser FROM school_equipment_repair ser
JOIN school_equipment_ledger sel JOIN school_equipment_ledger sel
ON ser.equipment_id=sel.id ON ser.equipment_id=sel.id
......
...@@ -14,11 +14,12 @@ ...@@ -14,11 +14,12 @@
<result property="borrowBy" column="borrow_by"/> <result property="borrowBy" column="borrow_by"/>
<result property="purpose" column="purpose"/> <result property="purpose" column="purpose"/>
<result property="deadline" column="deadline"/> <result property="deadline" column="deadline"/>
<result property="returnState" column="return_state"/>
</resultMap> </resultMap>
<select id="shebeilist" parameterType="ShebeiJy" resultMap="ShebeiJyResult"> <select id="shebeilist" parameterType="ShebeiJy" resultMap="ShebeiJyResult">
SELECT ss.id,encode,equipment_name,model,borrow_time,borrow_by_id,borrow_by,deadline,purpose SELECT ss.id,encode,equipment_name,model,borrow_time,borrow_by_id,borrow_by,deadline,purpose,ss.return_state
FROM school_circulation ss FROM school_circulation ss
JOIN school_equipment_ledger ssc JOIN school_equipment_ledger ssc
ON ss.equipment_id=ssc.id ON ss.equipment_id=ssc.id
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</resultMap> </resultMap>
<select id="querylistbx" parameterType="TeacherBx" resultMap="TeacherBxResult"> <select id="querylistbx" parameterType="TeacherBx" resultMap="TeacherBxResult">
SELECT ser.id,encode,equipment_name,model,date_of_production,place,report_repair_time,report_repair,problem,repair_name,repair_id,repair_time,repair_state,evaluate,ser.remark SELECT ser.id,encode,equipment_name,model,date_of_production,ser.place,report_repair_time,report_repair,problem,repair_name,repair_id,repair_time,repair_state,evaluate,ser.remark
FROM school_equipment_repair ser FROM school_equipment_repair ser
JOIN school_equipment_ledger sel JOIN school_equipment_ledger sel
ON ser.equipment_id=sel.id ON ser.equipment_id=sel.id
......
...@@ -12,10 +12,11 @@ ...@@ -12,10 +12,11 @@
<result property="borrowBy" column="borrow_by"/> <result property="borrowBy" column="borrow_by"/>
<result property="purpose" column="purpose"/> <result property="purpose" column="purpose"/>
<result property="deadline" column="deadline"/> <result property="deadline" column="deadline"/>
<result property="returnState" column="return_state"/>
</resultMap> </resultMap>
<select id="queryList" parameterType="TeacherJy" resultMap="TeacherJyResult"> <select id="queryList" parameterType="TeacherJy" resultMap="TeacherJyResult">
SELECT ss.id,encode,equipment_name,model,borrow_time,borrow_by_id,borrow_by,deadline,purpose SELECT ss.id,encode,equipment_name,model,borrow_time,borrow_by_id,borrow_by,deadline,purpose,ss.return_state
FROM school_circulation ss FROM school_circulation ss
JOIN school_equipment_ledger ssc JOIN school_equipment_ledger ssc
ON ss.equipment_id=ssc.id ON ss.equipment_id=ssc.id
......
...@@ -44,6 +44,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -44,6 +44,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where> </where>
</select> </select>
<select id="selctTeacherByUserId" resultType="yangtz.cs.liu.campus.domain.teacherFiles.TeacherFilesNotice">
SELECT fn.*,tf.state,tf.id as fId from teacher_files tf LEFT JOIN teacher_files_notice fn on fn.id= tf.notice_id WHERE tf.teacher_id = #{userId}
and fn.notice_state = 2
<if test="noticeRange != null and noticeRange != ''"> and fn.notice_range = #{teacherFiles.noticeRange}</if>
<if test="noticeYear != null and noticeYear != ''"> and fn.notice_year = #{teacherFiles.noticeYear}</if>
<if test="noticeSemester != null and noticeSemester != ''"> and fn.notice_semester = #{teacherFiles.noticeSemester}</if>
<if test="noticeName != null and noticeName != ''"> and fn.notice_name like concat('%', #{teacherFiles.noticeName}, '%')</if>
<if test="noticeState != null and noticeState != ''"> and fn.notice_state = #{teacherFiles.noticeState}</if>
<if test="startTime != null "> and start_time = #{teacherFiles.startTime}</if>
<if test="endTime != null "> and end_time = #{teacherFiles.endTime}</if>
</select>
<select id="selectTeacherFilesNoticeListByUser" parameterType="TeacherFilesNotice" resultType="TeacherFilesNoticeTotal"> <select id="selectTeacherFilesNoticeListByUser" parameterType="TeacherFilesNotice" resultType="TeacherFilesNoticeTotal">
<include refid="selectTeacherFilesNoticeTotalVo"/> <include refid="selectTeacherFilesNoticeTotalVo"/>
<where> <where>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment