Commit 6cdedff9 by Cat
parents c9d607c2 8cca9710
......@@ -126,6 +126,12 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
.antMatchers( "/dd/school/**").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()
// 静态资源,可匿名访问
......
......@@ -34,6 +34,10 @@
<groupId>com.ruoyi</groupId>
<artifactId>ruoyi-common</artifactId>
</dependency>
<dependency>
<groupId>com.ruoyi</groupId>
<artifactId>smart-campus</artifactId>
</dependency>
</dependencies>
......
package com.ruoyi.quartz.task;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import com.ruoyi.common.utils.StringUtils;
import yangtz.cs.liu.dingding.controller.DingJiaXiaoController;
/**
* 定时任务调度测试
......@@ -11,6 +13,9 @@ import com.ruoyi.common.utils.StringUtils;
@Component("ryTask")
public class RyTask
{
@Autowired
DingJiaXiaoController dingJiaXiaoController;
public void ryMultipleParams(String s, Boolean b, Long l, Double d, Integer i)
{
System.out.println(StringUtils.format("执行多参方法: 字符串类型{},布尔类型{},长整型{},浮点型{},整形{}", s, b, l, d, i));
......@@ -25,4 +30,14 @@ public class RyTask
{
System.out.println("执行无参方法");
}
public void updateLabClassYear(){
dingJiaXiaoController.updateLabClassYear();
}
public void updateLabUser(){
dingJiaXiaoController.updateLabUser();
}
}
......@@ -57,8 +57,15 @@ export function deleteEquipmentLedger(id) {
**/
export function getUserList(params) {
return request({
url: '/equipmentLedger/getUser',
url: "/equipmentLedger/getUser",
method: "GET",
params
params,
});
}
//获取打印设备条码信息
export function equipmentPrint(ids) {
return request({
url: `/equipmentLedger/getEquipmentledger/${ids}`,
method: "get",
});
}
......@@ -2,22 +2,21 @@
<div class="app-container fixed-scroll-error">
<el-row :gutter="20">
<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">
<div style="display:flex; justify-content: space-between">
<div style="display:flex; align-items: center">
<span>班级列表</span>
</div>
<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"
:label="item.label"></el-option>
<el-option v-for="item in yearList" :key="item.value" :value="item.value" :label="item.label"></el-option>
</el-select>
</div>
</template>
<div class="head-container">
<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
@node-click="handleNodeClick"/>
@node-click="handleNodeClick" />
</div>
</el-card>
</el-col>
......@@ -139,40 +138,38 @@
</el-radio-group>
<el-table v-if="activeName === Types.STUDENT" stripe v-loading="studentLoading" width="100%"
: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="头像">
<template slot-scope="scope">
<ListImage :image-url="isEmptyAvatar(scope.row.avatar, scope.row.sex)"></ListImage>
</template>
</el-table-column>
<el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName"
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 fixed="left" key="studentName" min-width="80" align="center" prop="studentName" 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="sex" min-width="50px" align="center" prop="sex" label="性别">
<template slot-scope="scope">
<dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"></dict-tag>
</template>
</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"
label="籍贯" show-overflow-tooltip></el-table-column>
<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="birthAddress" width="150" align="center" prop="birthAddress" 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="idCard" width="180" align="center" prop="idCard" 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="postalCode" width="150" align="center" prop="postalCode" 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"
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="学生类型">
<template slot-scope="scope">
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template>
</el-table-column>
<el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber"
label="省学籍辅号"/>
<el-table-column key="nationalNumber" width="150" align="center" prop="nationalNumber" label="全国学籍号"/>
<el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber" 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="学生状态">
<template slot-scope="scope">
<dict-tag :options="dict.type.child_state" :value="scope.row.studentStatus"></dict-tag>
......@@ -183,18 +180,17 @@
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template>
</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"
prop="registeredAddress" label="户口所在地" show-overflow-tooltip></el-table-column>
<el-table-column key="registeredType" width="180" align="center" prop="registeredType" label="户口性质">
<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>
</el-table-column>
<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="foreignLanguages" width="150" align="center" prop="foreignLanguages"
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="foreignLanguages" width="150" align="center" prop="foreignLanguages" label="外语语种" />
<el-table-column key="appearance" width="150" align="center" prop="appearance" label="政治面貌">
<template slot-scope="scope">
<dict-tag :options="dict.type.politics_tatus" :value="scope.row.appearance"></dict-tag>
......@@ -210,16 +206,15 @@
</span>
</template>
</el-table-column>
<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"
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" label="健康状况"
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"
label="流动人口状况"/>
label="流动人口状况" />
<el-table-column key="onlyChild" width="150" align="center" prop="onlyChild" label="独生子女">
<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>
</el-table-column>
<el-table-column key="nature" width="150" align="center" prop="nature" label="性质">
......@@ -227,8 +222,7 @@
<dict-tag :options="dict.type.student_nature" :value="scope.row.nature"></dict-tag>
</template>
</el-table-column>
<el-table-column key="support" width="150" align="center" prop="support"
label="接收资助情况"></el-table-column>
<el-table-column key="support" width="150" align="center" prop="support" label="接收资助情况"></el-table-column>
<el-table-column label="操作" align="center" min-width="200px" fixed="right">
<template slot-scope="scope">
<!-- <el-button-->
......@@ -252,18 +246,18 @@
<ListImage :image-url="isEmptyAvatar(scope.row.picUrl, scope.row.sex)"></ListImage>
</template>
</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">
<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>
</el-table-column>
<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="teacherCode" />
<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="education">
<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>
</el-table-column>
<el-table-column label="操作" align="center">
......@@ -275,8 +269,7 @@
</el-table-column>
</el-table>
<ExPagination :total="activeName === Types.STUDENT ? studentTotal : teacherTotal"
:limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum"
@pagination="getClassDetails">
:limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum" @pagination="getClassDetails">
</ExPagination>
</el-row>
</el-col>
......@@ -322,8 +315,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="出生日期:" prop="birthday">
<el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd"
placeholder="请选择出生日期"
<el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd" placeholder="请选择出生日期"
style="width: 100%;"></el-date-picker>
</el-form-item>
</el-col>
......@@ -375,8 +367,7 @@
<el-col :span="8">
<el-form-item label="民族:" prop="nation">
<el-select v-model="studentForm.nation" placeholder="请选择民族" 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-form-item>
</el-col>
......@@ -402,15 +393,13 @@
<el-row :gutter="20">
<el-col :span="8">
<el-form-item label="级/届:" prop="enrollmentYear">
<el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year"
placeholder="选择入学年">
<el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year" placeholder="选择入学年">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="入学时间:" prop="enrollmentTime">
<el-date-picker v-model="studentForm.enrollmentTime" style="width: 100%" type="date"
placeholder="选择入学时间">
<el-date-picker v-model="studentForm.enrollmentTime" style="width: 100%" type="date" placeholder="选择入学时间">
</el-date-picker>
</el-form-item>
</el-col>
......@@ -453,10 +442,7 @@
<el-col :span="8">
<el-form-item label="户口性质:" prop="registeredType">
<el-select v-model="studentForm.registeredType" style="width: 100%" placeholder="请输入户口性质">
<el-option
v-for="dict in dict.type.regist_type"
:key="dict.value"
:label="dict.label"
<el-option v-for="dict in dict.type.regist_type" :key="dict.value" :label="dict.label"
:value="dict.value">
</el-option>
</el-select>
......@@ -511,11 +497,7 @@
<el-col :span="8">
<el-form-item label="独生子女:" prop="onlyChild">
<el-select v-model="studentForm.onlyChild" style="width: 100%" placeholder="请选择是否为独生子女">
<el-option
v-for="dict in dict.type.only_child"
:key="dict.value"
:label="dict.label"
:value="dict.value">
<el-option v-for="dict in dict.type.only_child" :key="dict.value" :label="dict.label" :value="dict.value">
</el-option>
</el-select>
</el-form-item>
......@@ -548,7 +530,7 @@
<el-row>
<el-col :span="12">
<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 label="性别" prop="sex">
<el-select v-model="teacherForm.sex" style="width: 100%" placeholder="">
......@@ -557,10 +539,10 @@
</el-select>
</el-form-item>
<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 label="手机号码" prop="teacherTel">
<el-input v-model="teacherForm.teacherTel" placeholder=""/>
<el-input v-model="teacherForm.teacherTel" placeholder="" />
</el-form-item>
</el-col>
<el-col :span="12">
......@@ -592,7 +574,7 @@
<el-row>
<el-col :span="12">
<el-form-item label="工作编号" prop="teacherCode">
<el-input v-model="teacherForm.teacherCode" placeholder=""/>
<el-input v-model="teacherForm.teacherCode" placeholder="" />
</el-form-item>
</el-col>
<el-col :span="12">
......@@ -611,16 +593,14 @@
<el-col :span="12">
<el-form-item label="岗位" prop="postId">
<el-select multiple v-model="teacherForm.postId" placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.postId" :label="item.postName"
:value="item.postId"></el-option>
<el-option v-for="item in []" :key="item.postId" :label="item.postName" :value="item.postId"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="角色" prop="roleId">
<el-select v-model="teacherForm.roleId" multiple placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.roleId" :label="item.roleName"
:value="item.roleId"></el-option>
<el-option v-for="item in []" :key="item.roleId" :label="item.roleName" :value="item.roleId"></el-option>
</el-select>
</el-form-item>
</el-col>
......@@ -636,8 +616,7 @@
<el-col :span="12">
<el-form-item label="民族" prop="nation">
<el-select v-model="teacherForm.nation" style="width: 100%" placeholder="">
<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-form-item>
</el-col>
......@@ -653,7 +632,7 @@
</el-col>
<el-col :span="12">
<el-form-item label="家庭住址" prop="homeAddress">
<el-input v-model="teacherForm.homeAddress" placeholder=""/>
<el-input v-model="teacherForm.homeAddress" placeholder="" />
</el-form-item>
</el-col>
</el-row>
......@@ -674,13 +653,13 @@ import {
getStudentList,
getTeacherList
} from "@/api/smartSchool/classAdviser/classView";
import {getFirstLeafNode, handleTreeData} from "@/utils/utilLibrary/getTreeClass";
import {getYearList} from "@/utils/utilLibrary/getYearList";
import {CustomCellStyle} from "@/enums/customStyle";
import {getStudent} from "@/api/smartSchool/studentManage";
import {getInform} from "@/api/smartSchool/teacherManage/teacherInformation";
import {Gender, Nations} from "@/enums/common";
import {getNewYear} from "@/api/smartSchool/gradeWork/classView";
import { getFirstLeafNode, handleTreeData } from "@/utils/utilLibrary/getTreeClass";
import { getYearList } from "@/utils/utilLibrary/getYearList";
import { CustomCellStyle } from "@/enums/customStyle";
import { getStudent } from "@/api/smartSchool/studentManage";
import { getInform } from "@/api/smartSchool/teacherManage/teacherInformation";
import { Gender, Nations } from "@/enums/common";
import { getNewYear } from "@/api/smartSchool/gradeWork/classView";
export default {
name: "ClassAdviserClassView",
......@@ -788,7 +767,7 @@ export default {
const id = row.id
this.$router.push({
path: '/classAdviser/classView/parentInfo',
query: {studentId: row.id}
query: { studentId: row.id }
})
},
//学生信息
......@@ -869,9 +848,9 @@ export default {
/** 查询班级信息 */
getClassDetails() {
if (this.yearClass == 1) {
this.queryParams.pageNum = 1;
if (this.yearClass != 1) {
return; // 年级不是1,直接返回,不执行请求数据的操作
}
if (this.activeName === this.Types.STUDENT) {
this.studentLoading = true;
getStudentList(this.queryParams).then(response => {
......@@ -891,9 +870,8 @@ export default {
this.teacherLoading = false;
})
}
}
},
/** 选择班级(打开对话框) */
selectClass() {
this.classOptions.open = true
......@@ -1019,4 +997,8 @@ export default {
.form-header {
margin: 8px 0px 25px 0px;
}
.scrollable-card {
overflow: auto;
}
</style>
......@@ -2,17 +2,11 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="名称" prop="xxfbName">
<el-input
v-model="queryParams.xxfbName"
placeholder="请输入名称"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.xxfbName" placeholder="请输入名称" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="状态" prop="xxfbZt">
<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"
:value="dict.value">
<el-option v-for="dict in dict.type.info_push_state" :key="dict.value" :label="dict.label" :value="dict.value">
</el-option>
</el-select>
</el-form-item>
......@@ -31,46 +25,26 @@
</el-row>
<el-table v-loading="loading" :data="xxfbList" @selection-change="handleSelectionChange">
<el-table-column label="序号" align="center" type="index"/>
<el-table-column label="名称" min-width="250" align="center" prop="xxfbName"/>
<el-table-column label="序号" align="center" type="index" />
<el-table-column label="名称" min-width="250" align="center" prop="xxfbName" />
<el-table-column label="状态" align="center" prop="xxfbZt">
<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>
</el-table-column>
<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" prop="num" />
<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">
<template slot-scope="scope">
<template v-if="scope.row.xxfbZt == '1'">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
>修改
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
>删除
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)">删除
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-search"
@click="handleViewDetail(scope.row)"
>数据
<el-button size="mini" type="text" icon="el-icon-search" @click="handleViewDetail(scope.row)">数据
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-s-promotion"
@click="handlePublish(scope.row)"
>发布
<el-button size="mini" type="text" icon="el-icon-s-promotion" @click="handlePublish(scope.row)">发布
</el-button>
......@@ -93,29 +67,14 @@
<!-- </el-dropdown>-->
</template>
<template v-if="scope.row.xxfbZt == '2'">
<el-button
size="mini"
type="text"
icon="el-icon-back"
@click="handleRecall(scope.row)"
v-hasPermi="['system:xxfb:export']"
>撤回
<el-button size="mini" type="text" icon="el-icon-back" @click="handleRecall(scope.row)"
v-hasPermi="['system:xxfb:export']">撤回
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-view"
@click="handleViewData(scope.row)"
v-hasPermi="['system:xxfb:view']"
>数据查看
<el-button size="mini" type="text" icon="el-icon-view" @click="handleViewData(scope.row)"
v-hasPermi="['system:xxfb:view']">数据查看
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-download"
@click="handleExport(scope.row)"
v-hasPermi="['system:xxfb:export']"
>导出
<el-button size="mini" type="text" icon="el-icon-download" @click="handleExport(scope.row)"
v-hasPermi="['system:xxfb:export']">导出
</el-button>
</template>
......@@ -152,18 +111,11 @@
<el-divider></el-divider>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<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 label="级部" prop="gradeId">
<treeselect
v-model="form.gradeId"
:options="gradeTree"
:show-count="true"
@select="deptIdAndName"
:disable-branch-nodes="true"
:defaultExpandLevel="2"
placeholder="请选择级部"
/>
<treeselect v-model="form.gradeId" :options="gradeTree" :show-count="true" @select="deptIdAndName"
:disable-branch-nodes="true" :defaultExpandLevel="2" placeholder="请选择级部" />
</el-form-item>
</el-form>
<!-- <span style="color: red">*</span>-->
......@@ -173,13 +125,13 @@
<div v-show="isShow">
<div
style="font-size: 10px; color: #ed5565; font-weight: 400; background: #d8ecf6; border: 1px solid #03b3f5; padding: 10px">
注:上传excel文件,第一行为数据表头,不允许合并单元格,列名不要重复,第一列为身份证号,第二列为姓名。后续不限制
注:上传excel文件,第一行为数据表头,不允许合并单元格,列名不要重复,第一列为号,第二列为姓名。后续不限制
</div>
<br/>
<br />
<el-table :data="tableData" :border="true" style="width: 100%">
<!-- <el-table-column type="index" label="序号" width="50">-->
<!-- </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 prop="name" label="姓名">
</el-table-column>
......@@ -198,20 +150,11 @@
<el-table-column label="I">
</el-table-column>
</el-table>
<br/> <br/>
<br /> <br />
</div>
<el-upload
style="width: 950px;display: block; margin: 0 auto;"
ref="upload"
:limit='1'
class="upload-demo"
action="uploadUrl"
accept=".xlsx, .xls"
:headers="upload.headers"
show-file-list
:before-upload="handleBeforeUpload"
:http-request="uploadImage"
>
<el-upload style="width: 950px;display: block; margin: 0 auto;" ref="upload" :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>
......@@ -227,7 +170,7 @@
<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-item label="名称" prop="xxfbName">
<el-input v-model="form.xxfbName" placeholder="请输入名称"/>
<el-input v-model="form.xxfbName" placeholder="请输入名称" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
......@@ -256,7 +199,7 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css";
export default {
name: "Xxfb",
components: {Treeselect},
components: { Treeselect },
dicts: ['info_push_state'],
data() {
return {
......@@ -276,10 +219,10 @@ export default {
},
tableData: [{
idCard: 'xxxxxxxxxxxxx',
schoolNo: 'xxxxxxxxxxxxx',
name: 'xxx',
}, {
idCard: 'xxxxxxxxxxxxx',
schoolNo: 'xxxxxxxxxxxxx',
name: 'xxx',
}],
uploadUrl: process.env.VUE_APP_BASE_API + "/common/upload", // 上传excel
......@@ -312,10 +255,10 @@ export default {
// 表单校验
rules: {
xxfbName: [
{required: true, message: "查询名称不能为空", trigger: "blur"}
{ required: true, message: "查询名称不能为空", trigger: "blur" }
],
gradeId: [
{required: true, message: "级部不能为空", trigger: "blur"}
{ required: true, message: "级部不能为空", trigger: "blur" }
],
},
// 级部树
......
......@@ -183,7 +183,7 @@ export default {
telephone: [{required: true, message: "联系方式不能为空", trigger: "blur"}],
relationship: [{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 @@
</el-table-column>
<el-table-column label="证书照片" align="center">
<template slot-scope="scope">
<div>
<el-image v-for="(accessory, index) in scope.row.schoolAccessoryList" :key="index"
style="width: 100px; height: 100px" :src="accessory.accessoryUrl"
:preview-src-list="[accessory.accessoryUrl]"></el-image>
</div>
<el-carousel :interval="4000" height="100px">
<el-carousel-item v-for="(item, index) in scope.row.schoolAccessoryList" :key="index">
<el-image style="width: 100px; height: 100px" :src="item.accessoryUrl"
:preview-src-list="[item.accessoryUrl]"></el-image>
</el-carousel-item>
</el-carousel>
</template>
</el-table-column>
<el-table-column label="备注1" align="center" prop="remark1" />
......@@ -118,13 +120,19 @@
<el-row>
<el-col :span="10">
<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"
:http-request="uploadImage">
<img v-for="item in form.schoolAccessoryList" :key="item.accessoryUrl" :src="item.accessoryUrl"
class="avatar" />
<i v-if="form.schoolAccessoryList.length === 0" class="el-icon-plus avatar-uploader-icon"></i>
:on-remove="handleRemove">
<div v-if="form.schoolAccessoryList.length === 0">
<i 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>
<i class="el-icon-delete" @click="handleRemove(index)"></i> <!-- 添加删除按钮 -->
</el-form-item>
</el-col>
......@@ -181,6 +189,7 @@ export default {
components: { picAvatar },
data() {
return {
uploadFileUrl: process.env.VUE_APP_BASE_API + "/common/upload", // 上传的图片服务器地址
//缩略图
srcList: [],
// 图片路径
......@@ -222,7 +231,7 @@ export default {
schoolYear: [
{ required: true, message: "学年不能为空", trigger: "change" }
],
teacherName: [
teacherId: [
{ required: true, message: "教师名称不能为空", trigger: "change" }
],
entrySubject: [
......@@ -271,15 +280,15 @@ export default {
console.log('response', response);
this.total = response.total;
this.loading = false;
this.competitionData.forEach(item => {
if (item.schoolAccessoryList) {
item.previewUrls = [item.schoolAccessoryList.map(accessory => accessory.accessoryUrl)];
item.pictureUrl = item.schoolAccessoryList.map(accessory => accessory.accessoryUrl);
} else {
item.previewUrls = [];
item.pictureUrl = [];
}
});
// this.competitionData.forEach(item => {
// if (item.schoolAccessoryList) {
// item.previewUrls = [item.schoolAccessoryList.map(accessory => accessory.accessoryUrl)];
// item.pictureUrl = item.schoolAccessoryList.map(accessory => accessory.accessoryUrl);
// } else {
// item.previewUrls = [];
// item.pictureUrl = [];
// }
// });
});
......@@ -290,19 +299,21 @@ export default {
this.pic = val
},
// 移除图片
handleRemove() {
this.imageUrl = undefined
handleRemove(index) {
this.form.schoolAccessoryList.splice(index, 1);
},
// 上传成功回调
handleAvatarSuccess(response, file) {
console.log('response', response);
console.log('file', file);
// 处理上传成功的逻辑
const accessoryUrl = response.data.url; // 假设响应中包含了图片的访问URL
const accessoryName = file.name; // 获取上传文件的名称
const accessoryUrl = this.pev + response.fileName; // 假设响应中包含了图片的访问URL
const accessoryName = response.originalFilename; // 获取上传文件的名称
this.form.schoolAccessoryList.push({
accessoryUrl: accessoryUrl,
accessoryName: accessoryName
});
console.log('this.form.schoolAccessoryList', this.form.schoolAccessoryList);
},
// 上传前格式和图片大小限制
......@@ -318,27 +329,7 @@ export default {
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() {
......@@ -430,16 +421,6 @@ export default {
this.$refs['form'].validate(valid => {
if (valid) {
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 }) => {
if (code == 200) {
this.$modal.msgSuccess('修改成功')
......@@ -450,17 +431,6 @@ export default {
this.$modal.msgError("修改失败");
});
} 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 => {
console.log(this.form, 'this.form');
this.$modal.msgSuccess('新增成功')
......
......@@ -153,7 +153,6 @@
:on-success="handleAvatarSuccess"
: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">
<img
v-for="(item, index) in form.file"
......
......@@ -21,6 +21,11 @@
<el-table-column label="型号" align="center" prop="model" />
<el-table-column label="借用日期" align="center" prop="borrowTime" />
<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="deadline" />
<el-table-column label="操作" align="center">
......@@ -80,6 +85,14 @@
<el-input v-model="postForm.deadline" />
</el-form-item>
</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-form>
......@@ -100,7 +113,7 @@ import {
listTeacherjyxq
} from "@/api/smartSchool/personWork/propertyManagement";
export default {
dicts: ['return_state'],
data() {
return {
queryParams: {
......
......@@ -86,8 +86,8 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="报修时间:" prop="reportrepairtime">
<el-date-picker v-model="postForm.reportrepairtime" type="date" style="width: 100%;"
<el-form-item label="报修时间:" prop="reportRepairTime">
<el-date-picker v-model="postForm.reportRepairTime" type="date" style="width: 100%;"
value-format="yyyy-MM-dd" clearable></el-date-picker>
</el-form-item>
</el-col>
......
......@@ -656,7 +656,7 @@ export default {
console.log(encodes, 'encodes');
const printListParam = encodeURIComponent(JSON.stringify(this.printList));
dd.biz.util.openLink({
url: `${baseUrl}?ids=${ids}&encodes=${encodes}&printList=${printListParam}`,
url: `${baseUrl}?ids=${ids}`,
onSuccess: () => {
console.log('跳转成功,准备打印');
// 打印条码
......
......@@ -50,7 +50,9 @@ import { getToken } from "@/utils/auth";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import QRCode from "qrcodejs2"; // 生成二维码插件
import printJS from "print-js"; // 打印插件
import {
equipmentPrint
} from "../../../../api/smartSchool/schoolProperty/equipmenTledger";
export default {
name: "index",
......@@ -81,22 +83,28 @@ export default {
};
},
created() {
const ids = this.$route.query.ids;
const encodes = this.$route.query.encodes;
const printList = JSON.parse(decodeURIComponent(this.$route.query.printList));
this.printBarcodes(ids, encodes, printList);
this.getList();
},
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;
console.log(ids, encodes);
this.printList = [...printList];
this.chooseList = [...this.printList];
console.log(this.chooseList, '122');
this.$nextTick(() => {
this.printList.map((item, index) => {
const domPrint = document.getElementById(`print${index}`).lastElementChild;
......
......@@ -27,14 +27,14 @@
<el-table-column label="借用人" align="center" prop="borrowBy" />
<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="returnTime" width="160" />
<el-table-column label="预计使用期限" align="center" prop="yjuseTime" width="160" />
<el-table-column label="归还时设备情况" align="center" prop="returnEquipmentCondition" width="160">
<template slot-scope="{ row }">
<dict-tag :options="dict.type.equipment_state" :value="row.returnEquipmentCondition" />
</template>
</el-table-column>
<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="remark" />
<el-table-column label="操作" align="center" prop="orgname" width="150" fixed="right">
......@@ -137,17 +137,19 @@
</el-row>
<el-row :gutter="30">
<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"
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-form-item>
</el-col>
<el-col :span="12">
<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">
</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-col>
</el-row>
......
......@@ -2,21 +2,20 @@
<div class="app-container fixed-scroll-error">
<el-row :gutter="20">
<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">
<div style="display:flex; justify-content: space-between">
<div style="display:flex; align-items: center">
<span>班级列表</span>
</div>
<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"
:label="item.label"></el-option>
<el-option v-for="item in yearList" :key="item.value" :value="item.value" :label="item.label"></el-option>
</el-select>
</div>
</template>
<div class="head-container">
<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"-->
</div>
</el-card>
......@@ -138,40 +137,38 @@
<el-table v-if="activeName === Types.STUDENT" stripe v-loading="studentLoading" width="100%"
: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="头像">
<template slot-scope="scope">
<ListImage :image-url="isEmptyAvatar(scope.row.avatar, scope.row.sex)"></ListImage>
</template>
</el-table-column>
<el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName"
label="姓名"/>
<el-table-column fixed="left" key="studentName" min-width="80" align="center" prop="studentName" 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="性别">
<template slot-scope="scope">
<dict-tag :options="dict.type.sys_user_sex" :value="scope.row.sex"></dict-tag>
</template>
</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"
label="籍贯" show-overflow-tooltip></el-table-column>
<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="birthAddress" width="150" align="center" prop="birthAddress" 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="idCard" width="180" align="center" prop="idCard" 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="postalCode" width="150" align="center" prop="postalCode" 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"
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="学生类型">
<template slot-scope="scope">
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template>
</el-table-column>
<el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber"
label="省学籍辅号"/>
<el-table-column key="nationalNumber" width="150" align="center" prop="nationalNumber" label="全国学籍号"/>
<el-table-column key="provincialNumber" width="150" align="center" prop="provincialNumber" 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="学生状态">
<template slot-scope="scope">
<dict-tag :options="dict.type.child_state" :value="scope.row.studentStatus"></dict-tag>
......@@ -182,18 +179,17 @@
<dict-tag :options="dict.type.student_type" :value="scope.row.studentType"></dict-tag>
</template>
</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"
prop="registeredAddress" label="户口所在地" show-overflow-tooltip></el-table-column>
<el-table-column key="registeredType" width="180" align="center" prop="registeredType" label="户口性质">
<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>
</el-table-column>
<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="foreignLanguages" width="150" align="center" prop="foreignLanguages"
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="foreignLanguages" width="150" align="center" prop="foreignLanguages" label="外语语种" />
<el-table-column key="appearance" width="150" align="center" prop="appearance" label="政治面貌">
<template slot-scope="scope">
<dict-tag :options="dict.type.politics_tatus" :value="scope.row.appearance"></dict-tag>
......@@ -209,16 +205,15 @@
</span>
</template>
</el-table-column>
<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"
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" label="健康状况"
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"
label="流动人口状况"/>
label="流动人口状况" />
<el-table-column key="onlyChild" width="150" align="center" prop="onlyChild" label="独生子女">
<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>
</el-table-column>
<el-table-column key="nature" width="150" align="center" prop="nature" label="性质">
......@@ -226,8 +221,7 @@
<dict-tag :options="dict.type.student_nature" :value="scope.row.nature"></dict-tag>
</template>
</el-table-column>
<el-table-column key="support" width="150" align="center" prop="support"
label="接收资助情况"></el-table-column>
<el-table-column key="support" width="150" align="center" prop="support" label="接收资助情况"></el-table-column>
<el-table-column label="操作" align="center" min-width="100px" fixed="right">
<template slot-scope="scope">
<!-- <el-button-->
......@@ -249,18 +243,18 @@
<ListImage :image-url="isEmptyTeacherUrl(scope.row.picUrl, scope.row.sex)"></ListImage>
</template>
</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">
<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>
</el-table-column>
<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="teacherCode" />
<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="education">
<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>
</el-table-column>
<el-table-column label="操作" align="center">
......@@ -272,8 +266,7 @@
</el-table-column>
</el-table>
<ExPagination :total="activeName === Types.STUDENT ? studentTotal : teacherTotal"
:limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum"
@pagination="getClassDetails">
:limit.sync="queryParams.pageSize" :page.sync="queryParams.pageNum" @pagination="getClassDetails">
</ExPagination>
</el-row>
</el-col>
......@@ -292,14 +285,12 @@
<el-row :gutter="20">
<el-col :span="8">
<el-form-item label="姓名:" prop="studentName">
<el-input placeholder="请输入姓名" :disabled="isEditMode" v-model="studentForm.studentName"
clearable></el-input>
<el-input placeholder="请输入姓名" :disabled="isEditMode" v-model="studentForm.studentName" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="身份证号:" prop="idCard">
<el-input placeholder="请输入身份证号" :disabled="isEditMode" v-model="studentForm.idCard"
clearable></el-input>
<el-input placeholder="请输入身份证号" :disabled="isEditMode" v-model="studentForm.idCard" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="8">
......@@ -320,8 +311,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="出生日期:" prop="birthday">
<el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd"
placeholder="请选择出生日期"
<el-date-picker v-model="studentForm.birthday" type="date" value-format="yyyy-MM-dd" placeholder="请选择出生日期"
style="width: 100%;"></el-date-picker>
</el-form-item>
</el-col>
......@@ -371,10 +361,8 @@
</el-col>
<el-col :span="8">
<el-form-item label="民族:" prop="nation">
<el-select :disabled="isEditMode" v-model="studentForm.nation" placeholder="请选择民族"
style="width: 100%">
<el-option v-for="item in Nations" :key="item.label" :label="item.label"
:value="item.label"></el-option>
<el-select :disabled="isEditMode" v-model="studentForm.nation" placeholder="请选择民族" style="width: 100%">
<el-option v-for="item in Nations" :key="item.label" :label="item.label" :value="item.label"></el-option>
</el-select>
</el-form-item>
</el-col>
......@@ -407,8 +395,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="级/届:" prop="enrollmentYear">
<el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year"
placeholder="选择入学年">
<el-date-picker style="width:100%" v-model="studentForm.enrollmentYear" type="year" placeholder="选择入学年">
</el-date-picker>
</el-form-item>
......@@ -457,10 +444,7 @@
<el-col :span="8">
<el-form-item label="户口性质:" prop="registeredType">
<el-select v-model="studentForm.registeredType" style="width: 100%" placeholder="请输入户口性质">
<el-option
v-for="dict in dict.type.regist_type"
:key="dict.value"
:label="dict.label"
<el-option v-for="dict in dict.type.regist_type" :key="dict.value" :label="dict.label"
:value="dict.value">
</el-option>
</el-select>
......@@ -515,11 +499,7 @@
<el-col :span="8">
<el-form-item label="独生子女:" prop="onlyChild">
<el-select v-model="studentForm.onlyChild" style="width: 100%" placeholder="请选择是否为独生子女">
<el-option
v-for="dict in dict.type.only_child"
:key="dict.value"
:label="dict.label"
:value="dict.value">
<el-option v-for="dict in dict.type.only_child" :key="dict.value" :label="dict.label" :value="dict.value">
</el-option>
</el-select>
</el-form-item>
......@@ -547,7 +527,7 @@
<el-row>
<el-col :span="12">
<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 label="性别" prop="sex">
<el-select v-model="teacherForm.sex" style="width: 100%" placeholder="">
......@@ -556,10 +536,10 @@
</el-select>
</el-form-item>
<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 label="手机号码" prop="teacherTel">
<el-input v-model="teacherForm.teacherTel" placeholder=""/>
<el-input v-model="teacherForm.teacherTel" placeholder="" />
</el-form-item>
</el-col>
<el-col :span="12">
......@@ -591,7 +571,7 @@
<el-row>
<el-col :span="12">
<el-form-item label="工作编号" prop="teacherCode">
<el-input v-model="teacherForm.teacherCode" placeholder=""/>
<el-input v-model="teacherForm.teacherCode" placeholder="" />
</el-form-item>
</el-col>
<el-col :span="12">
......@@ -610,16 +590,14 @@
<el-col :span="12">
<el-form-item label="岗位" prop="postId">
<el-select multiple v-model="teacherForm.postId" placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.postId" :label="item.postName"
:value="item.postId"></el-option>
<el-option v-for="item in []" :key="item.postId" :label="item.postName" :value="item.postId"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="角色" prop="roleId">
<el-select v-model="teacherForm.roleId" multiple placeholder="" style="width: 100%;">
<el-option v-for="item in []" :key="item.roleId" :label="item.roleName"
:value="item.roleId"></el-option>
<el-option v-for="item in []" :key="item.roleId" :label="item.roleName" :value="item.roleId"></el-option>
</el-select>
</el-form-item>
</el-col>
......@@ -635,8 +613,7 @@
<el-col :span="12">
<el-form-item label="民族" prop="nation">
<el-select v-model="teacherForm.nation" style="width: 100%" placeholder="">
<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-form-item>
</el-col>
......@@ -652,7 +629,7 @@
</el-col>
<el-col :span="12">
<el-form-item label="家庭住址" prop="homeAddress">
<el-input v-model="teacherForm.homeAddress" placeholder=""/>
<el-input v-model="teacherForm.homeAddress" placeholder="" />
</el-form-item>
</el-col>
</el-row>
......@@ -673,12 +650,12 @@ import {
getStudentList,
getTeacherList
} from "@/api/smartSchool/teachAffairAdministration/affairClassView";
import {getFirstLeafNode, handleTreeData} from "@/utils/utilLibrary/getTreeClass";
import {getYearList} from "@/utils/utilLibrary/getYearList";
import {CustomCellStyle} from "@/enums/customStyle";
import {getStudent} from "@/api/smartSchool/studentManage";
import {getInform} from "@/api/smartSchool/teacherManage/teacherInformation";
import {Gender, Nations} from "@/enums/common";
import { getFirstLeafNode, handleTreeData } from "@/utils/utilLibrary/getTreeClass";
import { getYearList } from "@/utils/utilLibrary/getYearList";
import { CustomCellStyle } from "@/enums/customStyle";
import { getStudent } from "@/api/smartSchool/studentManage";
import { getInform } from "@/api/smartSchool/teacherManage/teacherInformation";
import { Gender, Nations } from "@/enums/common";
export default {
name: "index",
......@@ -843,7 +820,6 @@ export default {
/** 查询班级信息 */
getClassDetails() {
if (this.yearClass == 1) {
this.queryParams.pageNum = 1;
if (this.activeName === this.Types.STUDENT) {
this.studentLoading = true;
getStudentList(this.queryParams).then(response => {
......@@ -987,4 +963,8 @@ export default {
.form-header {
margin: 8px 0px 25px 0px;
}
.scrollable-card {
overflow: auto;
}
</style>
......@@ -2,7 +2,7 @@
<div class="app-container">
<el-row>
<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-item label="班级信息" prop="schoolYear">
<el-select v-model="queryParams.schoolYear" @change="getTreeData" style="width: 100%" size="mini">
......@@ -678,6 +678,10 @@ export default {
padding-right: 0px;
}
.scrollable-card {
overflow: auto;
}
/*.dragBox[data-v-86c11aba] {*/
/* font-size: 20px;*/
/* width: 100%;*/
......
......@@ -2,33 +2,20 @@
<div class="activity-result app-container">
<el-tabs tab-position="left" style="height: 100%;">
<el-tab-pane label="明细数据">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"
label-width="80px">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">
<el-form-item label="姓名" prop="studentName">
<el-input v-model="queryParams.studentName" placeholder="请输入姓名" clearable
@keyup.enter.native="handleQuery">
<el-input v-model="queryParams.studentName" placeholder="请输入姓名" clearable @keyup.enter.native="handleQuery">
</el-input>
</el-form-item>
<el-form-item label="填写状态" prop="ryZdzt">
<el-select v-model="queryParams.ryZdzt" style="width: 100%" placeholder="请选择问卷填写状态">
<el-option
v-for="dict in dict.type.quiz_txzt"
:key="dict.value"
:label="dict.label"
:value="dict.value">
<el-option v-for="dict in dict.type.quiz_txzt" :key="dict.value" :label="dict.label" :value="dict.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item label="填写时间">
<el-date-picker
v-model="dateRange"
style="width: 240px"
value-format="yyyy-MM-dd"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
<el-date-picker v-model="dateRange" 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-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
......@@ -48,31 +35,26 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="activityList" @selection-change="handleSelectionChange">
<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 label="姓名" align="center" prop="studentName"/>
<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 label="姓名" align="center" prop="studentName" />
<el-table-column label="填写状态" align="center" prop="ryZdzt">
<template slot-scope="scope">
<span>{{ scope.row.ryZdzt == 0 ? '未填写' : '已填写' }} </span>
</template>
</el-table-column>
<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 label="填写时间" align="center" min-width="120px" prop="ryCtime" />
<el-table-column v-for="(item, index) in dynamicTitle" :label="item" min-width="150px" align="center">
<template slot-scope="scope">
<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"
<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"
style="height: 50px"></ListImage>
<span v-else> {{ scope.row[dynamicProp[index]] && scope.row[dynamicProp[index]].datas }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" min-width="80" key="operate">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-view"
@click="handleDetail(scope.row)"
>查看
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">查看
</el-button>
</template>
</el-table-column>
......@@ -80,15 +62,14 @@
</el-tab-pane>
<el-tab-pane label="统计">
<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 ;">
<b>{{ item.title }}</b>
<br/> <br/>
<el-table v-loading="loading" :data="item.detailsLit"
:summary-method="(res)=>getSummaries(res,index )" show-summary
>
<el-table-column label="选项" align="center" prop="selects"/>
<el-table-column label="小计" align="center" prop="selectNum"/>
<br /> <br />
<el-table v-loading="loading" :data="item.detailsLit" :summary-method="(res) => getSummaries(res, index)"
show-summary>
<el-table-column label="选项" align="center" prop="selects" />
<el-table-column label="小计" align="center" prop="selectNum" />
<el-table-column label="比例" align="center" sortable prop="proportion">
<template slot-scope="scope">
<el-progress :percentage="scope.row.proportion"></el-progress>
......@@ -101,9 +82,9 @@
</el-tab-pane>
</el-tabs>
<el-dialog title="调查问卷" :visible.sync="dialogQuestionire" width="860" append-to-body>
<el-form ref="form" disabled label-width="90px"
style="width: 100%; margin: auto">
<el-form ref="form" disabled label-width="90px" style="width: 100%; margin: auto">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="班级">
......@@ -111,26 +92,18 @@
</el-form-item>
<el-form-item label="填写状态" prop="ryZdzt">
<el-select v-model="formFix.ryZdzt" style="width: 100%" placeholder="请选择问卷填写状态">
<el-option
v-for="dict in dict.type.quiz_txzt"
:key="dict.value"
:label="dict.label"
:value="dict.value">
<el-option v-for="dict in dict.type.quiz_txzt" :key="dict.value" :label="dict.label" :value="dict.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="姓名" prop="studentName">
<el-input :value="formFix.studentName"/>
<el-input :value="formFix.studentName" />
</el-form-item>
<el-form-item label="填写时间">
<el-date-picker
v-model="formFix.ryCtime"
style="width: 100%"
value-format="yyyy-MM-dd HH:mm"
type="date"
></el-date-picker>
<el-date-picker v-model="formFix.ryCtime" style="width: 100%" value-format="yyyy-MM-dd HH:mm"
type="date"></el-date-picker>
</el-form-item>
</el-col>
</el-row>
......@@ -142,25 +115,26 @@
:value="item.type"></dict-tag>
)
<b>{{ item.title }}</b>
<br/><br/>
<el-image v-if="item.type==3" :src="baseUrl+item.datas"></el-image>
<br /><br />
<el-image v-if="item.type == 3" :src="baseUrl + item.datas"></el-image>
<b v-else>{{ item.datas }}</b>
<el-divider></el-divider>
</el-row>
</el-form>
</el-dialog>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
</div>
</template>
<script>
import {activityTypesEnum, departmentEnum} from "@/enums/questionnaire/content";
import { activityTypesEnum, departmentEnum } from "@/enums/questionnaire/content";
import {
getList,
getCount,
getQuestionResultQueryOne
} 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 {
name: "QuestionnaireResult",
......@@ -191,7 +165,7 @@ export default {
// 显示搜索条件
showSearch: true,
// 总条数
// total: 0,
total: 0,
// 办公申购表格数据
activityList: [],
// 弹出层标题
......@@ -241,6 +215,8 @@ export default {
this.loading = true;
getList(this.addDateRange(this.queryParams, this.dateRange), this.dcwjId).then(response => {
this.activityList = response.data
this.total = response.total;
console.log(response, 'response');
//获取标题
let title = Object.values(response.titles)
this.dynamicTitle = title.filter((item) => {
......@@ -360,7 +336,7 @@ export default {
//查看按钮
handleDetail(row) {
this.dialogQuestionire = true
let {classAlias, ryZdzt, studentName, ryCtime} = row
let { classAlias, ryZdzt, studentName, ryCtime } = row
this.formFix.classAlias = classAlias
this.formFix.ryZdzt = ryZdzt
this.formFix.studentName = studentName
......@@ -391,7 +367,7 @@ export default {
},
getSummaries(param, index) {
// console.log(index,778)
const {columns, data} = param;
const { columns, data } = param;
const sums = [];
columns.forEach((column, columnIndex) => {
if (columnIndex === 0) {
......@@ -410,6 +386,5 @@ export default {
</script>
<style scoped lang="scss">
div.activity-result {
}
div.activity-result {}
</style>
<template>
<div class="questionnaire-activity 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="dcwjName">
<el-input v-model="queryParams.dcwjName"
placeholder="请输入问卷名称"
clearable
@keyup.enter.native="handleQuery"
>
<el-input v-model="queryParams.dcwjName" placeholder="请输入问卷名称" clearable @keyup.enter.native="handleQuery">
</el-input>
</el-form-item>
<el-form-item label="问卷状态" prop="dcwjZt">
......@@ -29,13 +18,7 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
>新 增
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd">新 增
</el-button>
<!-- v-show="queryParams.dcwjZt==='0'"-->
</el-col>
......@@ -78,89 +61,55 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="activityList" @selection-change="handleSelectionChange">
<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="selection" 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>
<template slot-scope="scope">
{{ scope.row.scope }}
</template>
</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">
<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>
</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="dcwjJssj"/>
<el-table-column label="描述" align="center" min-width="200px" show-overflow-tooltip prop="dcwjMs"/>
<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="描述" align="center" min-width="200px" show-overflow-tooltip prop="dcwjMs" />
<el-table-column label="操作" align="center" min-width="270px">
<template v-slot="scope">
<el-button
v-show="scope.row.dcwjZt==='1'"
size="mini"
type="text"
@click="handleUpdate(scope.row)"
>修改
<el-button v-show="scope.row.dcwjZt === '1'" size="mini" type="text" @click="handleUpdate(scope.row)">修改
</el-button>
<el-button
size="mini"
type="text"
@click="jumpTo(QuestionnaireContent(scope.row.id, scope.row.dcwjZt,scope.row.dcwjName))"
>问卷内容
<el-button size="mini" type="text"
@click="jumpTo(QuestionnaireContent(scope.row.id, scope.row.dcwjZt, scope.row.dcwjName))">问卷内容
</el-button>
<el-button v-show="scope.row.dcwjZt==='1'"
size="mini"
type="text"
@click="publishExamExecute(scope.row)"
>发布
<el-button v-show="scope.row.dcwjZt === '1'" size="mini" type="text" @click="publishExamExecute(scope.row)">发布
</el-button>
<el-button v-show="scope.row.dcwjZt==='2'"
size="mini"
type="text"
@click="toQuestionResult(scope.row.id,scope.row.pubType)"
>问卷结果
<el-button v-show="scope.row.dcwjZt === '2'" size="mini" type="text"
@click="toQuestionResult(scope.row.id, scope.row.pubType)">问卷结果
</el-button>
<!-- @click="jumpTo(ActivityResult(scope.row.id,scope.row.pubType))"-->
<el-button v-show="scope.row.dcwjZt==='1'"
size="mini"
type="text"
@click="handleDelete(scope.row)"
>删除
<el-button v-show="scope.row.dcwjZt === '1'" size="mini" type="text" @click="handleDelete(scope.row)">删除
</el-button>
<el-button
v-show="scope.row.dcwjZt==='2'"
size="mini"
type="text"
@click="recallExamExecute(scope.row)"
>撤回
<el-button v-show="scope.row.dcwjZt === '2'" size="mini" type="text" @click="recallExamExecute(scope.row)">撤回
</el-button>
<el-button
size="mini"
type="text"
@click="handleCheck(scope.row)"
>查看
<el-button size="mini" type="text" @click="handleCheck(scope.row)">查看
</el-button>
</template>
</el-table-column>
</el-table>
<ExPagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<ExPagination v-show="total > 0" :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-form ref="form" :model="form" :rules="rules" label-width="auto" class="add-edit-dialog"
:disabled="!isEditable">
<el-form ref="form" :model="form" :rules="rules" label-width="auto" class="add-edit-dialog" :disabled="!isEditable">
<el-row>
<el-col :span="24">
<el-form-item label="问卷名称" prop="dcwjName">
<el-input v-model="form.dcwjName" placeholder="请输入活动名称"/>
<el-input v-model="form.dcwjName" placeholder="请输入活动名称" />
</el-form-item>
</el-col>
<el-col :span="12">
......@@ -169,25 +118,15 @@
<el-row>
<el-col :span="12">
<el-form-item label="开始时间" prop="dcwjKssj">
<el-date-picker clearable
v-model="form.dcwjKssj"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择开始时间"
:picker-options="StartPickerOptions"
>
<el-date-picker clearable v-model="form.dcwjKssj" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择开始时间" :picker-options="StartPickerOptions">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="" prop="dcwjJssj" label-width="0px">
<el-date-picker clearable
v-model="form.dcwjJssj"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择结束时间"
:picker-options="EndPickerOptions"
>
<el-date-picker clearable v-model="form.dcwjJssj" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择结束时间" :picker-options="EndPickerOptions">
</el-date-picker>
</el-form-item>
</el-col>
......@@ -195,42 +134,31 @@
<el-row>
<el-col :span="12">
<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-col>
</el-row>
<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-col :span="12">
<el-form-item label="接收人类型" prop="pubType">
<el-select v-model="form.pubType" @change="receiveChange" placeholder="请选择接收人类型">
<el-option
v-for="item in [{
<el-option v-for="item in [{
value: '1',
label: '教师'},{
label: '教师'
}, {
value: '0',
label: '家长'
}]"
:key="item.value"
:label="item.label"
:value="item.value">
}]" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="级部" prop="gradeIds">
<treeselect
v-model="form.gradeIds"
:disabled="gradeDisabled || !isEditable"
multiple
:options="gradeTree"
:show-count="true"
:defaultExpandLevel="2"
:disable-branch-nodes="true"
placeholder="请选择级部"
/>
<treeselect v-model="form.gradeIds" :disabled="gradeDisabled || !isEditable" multiple :options="gradeTree"
:show-count="true" :defaultExpandLevel="2" :disable-branch-nodes="true" placeholder="请选择级部" />
</el-form-item>
</el-col>
</el-form>
......@@ -258,8 +186,8 @@ import {
getQueryOne
} from "@/api/smartSchool/teachAffairAdministration/questionnaireManagement/QuestionnaireActivity/request.js";
import {jumpTo, Path_Destination} from "@/utils/utilLibrary/routerBatch/routerBatch";
import {QUESTION_STATE} from "@/enums/questionnaire/content";
import { jumpTo, Path_Destination } from "@/utils/utilLibrary/routerBatch/routerBatch";
import { QUESTION_STATE } from "@/enums/questionnaire/content";
import Treeselect from "@riophae/vue-treeselect";
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
......@@ -315,11 +243,11 @@ export default {
},
// 表单校验
rules: {
dcwjName: [{required: true, message: '问卷名称不能为空', trigger: 'blur'}],
dcwjKssj: [{required: true, message: '开始时间不能为空', trigger: 'blur'}],
dcwjJssj: [{required: true, message: '结束不能为空', trigger: 'blur'}],
gradeId: [{required: true, message: '范围不能为空', trigger: 'blur'}],
pubType: [{required: true, message: '接收人类型不能为空', trigger: 'blur'}],
dcwjName: [{ required: true, message: '问卷名称不能为空', trigger: 'blur' }],
dcwjKssj: [{ required: true, message: '开始时间不能为空', trigger: 'blur' }],
dcwjJssj: [{ required: true, message: '结束不能为空', trigger: 'blur' }],
gradeId: [{ required: true, message: '范围不能为空', trigger: 'blur' }],
pubType: [{ required: true, message: '接收人类型不能为空', trigger: 'blur' }],
},
StartPickerOptions: {
disabledDate: (time) => {
......@@ -338,7 +266,7 @@ export default {
title
}),
//问卷结果
ActivityResult: (examId, pubType) => new Path_Destination(`/teachAffairQuestion/result/${examId}`, {pubType: pubType}),
ActivityResult: (examId, pubType) => new Path_Destination(`/teachAffairQuestion/result/${examId}`, { pubType: pubType }),
};
},
created() {
......@@ -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%;
}
</style>
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.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
......@@ -7,17 +8,21 @@ import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.poi.ExcelUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import yangtz.cs.liu.campus.domain.schoolEquipment.SchoolEquipmentLedger;
import yangtz.cs.liu.campus.service.schoolEquipment.IEquipmentLedgerService;
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.student.SchoolStudentScoreVo;
import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
/**
* 设备基础信息
......@@ -58,8 +63,17 @@ public class EquipmentLedgerController extends BaseController {
public void export(HttpServletResponse response, SchoolEquipmentLedgerVo schoolEquipmentLedgerVo)
{
List<SchoolEquipmentLedger> list = equipmentLedgerService.selectSchoolEquipmentLedgerList(schoolEquipmentLedgerVo);
ExcelUtil<SchoolEquipmentLedger> util = new ExcelUtil<SchoolEquipmentLedger>(SchoolEquipmentLedger.class);
util.exportExcel(response, list, "设备台账数据");
List<SchoolEquipmentLedgerDcVo> list1 = new ArrayList<>();
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 {
public TableDataInfo getUser(SysUser 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
@PostMapping
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));
}
......
package yangtz.cs.liu.campus.controller.organization;
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.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils;
......@@ -20,8 +21,15 @@ import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.core.page.TableDataInfo;
import yangtz.cs.liu.campus.domain.organization.SchoolOrganizationInfo;
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.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.vo.organization.MemberListVo;
......@@ -44,6 +52,15 @@ public class SchoolOrganizationMemberController extends BaseController
@Autowired
private ISchoolStudentParentService schoolStudentParentService;
@Autowired
private ISchoolStudentClassesService schoolStudentClassesService;
@Autowired
private ISchoolStudentClassRelationService schoolStudentClassRelationService;
@Autowired
private ISchoolClassService schoolClassService;
/**
* 查询社团成员列表
*/
......@@ -58,6 +75,21 @@ public class SchoolOrganizationMemberController extends BaseController
.orderByDesc(SchoolOrganizationMember::getCreateTime);
startPage();
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);
}
......@@ -82,7 +114,8 @@ public class SchoolOrganizationMemberController extends BaseController
// wrapper.eq(SchoolStudentParent::getIdCard,schoolOrganizationMember.getCardid());
// SchoolStudentParent one = schoolStudentParentService.getOne(wrapper);
// 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
boolean save = schoolOrganizationMemberService.save(member);
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.*;
import yangtz.cs.liu.campus.domain.schoolDuty.SchoolDuty;
import yangtz.cs.liu.campus.domain.schoolgrade.SchoolGrade;
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.schoolDcwj.*;
import yangtz.cs.liu.campus.service.schoolgrade.ISchoolGradeMentorService;
......@@ -88,6 +89,7 @@ public class SchoolDcwjController extends BaseController {
@Autowired
private ISchoolDcwjPushService pushService;
@Value("${server.port}")
private String p;
......@@ -513,9 +515,122 @@ public class SchoolDcwjController extends BaseController {
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);
ajax.put("data", voList);
ajax.put("total",getDataTable(list).getTotal());
return ajax;
}
......
......@@ -122,7 +122,9 @@ public class StudentStatusController {
map.put("avatar", image);
}
map.put("idCard",baseInfo.getIdCard());
if (StringUtils.isNotNull(baseInfo.getBirthday())){
map.put("birthday",new SimpleDateFormat("yyyy-MM-dd").format(baseInfo.getBirthday()));
}
map.put("nation",baseInfo.getNation());
map.put("stuTelephone",baseInfo.getStuTelephone());
map.put("postalCode",baseInfo.getPostalCode());
......@@ -285,7 +287,9 @@ public class StudentStatusController {
}else{
map.put("sex","女");
}
if (StringUtils.isNotNull(baseInfo.getBirthday())){
map.put("birthday",new SimpleDateFormat("yyyy-MM-dd").format(baseInfo.getBirthday()));
}
map.put("idCard",baseInfo.getIdCard());
// 图片
//路径去掉/profile
......
......@@ -238,49 +238,65 @@ public class SchoolTeacherController extends BaseController {
//查询设备号
if(StringUtils.isNotNull(schoolTeacher.getDeviceNum())){
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);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
}else if(schoolTeacher.getDeviceNum().equals(teacher.getDeviceNum())){
if (StringUtils.isNotNull(teacher)){
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())){
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);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
}else if(schoolTeacher.getIdCard().equals(teacher.getIdCard())){
if (StringUtils.isNotNull(teacher)){
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())){
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);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
}else if(schoolTeacher.getTeacherCode().equals(teacher.getTeacherCode())){
if (StringUtils.isNotNull(teacher)){
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())){
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);
if (StringUtils.isNotNull(schoolTeacher.getId()) && schoolTeacher.getId().equals(teacher.getId())) {
}else if(schoolTeacher.getTeacherTel().equals(teacher.getTeacherTel())){
if (StringUtils.isNotNull(teacher)){
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;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
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.TeacherFilesNotice;
import yangtz.cs.liu.campus.service.teacherFiles.ITeacherFilesService;
......@@ -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}")
public TableDataInfo teachList(@PathVariable("userId") Long userId){
public TableDataInfo teachList(@PathVariable("userId") Long userId,TeacherFilesNotice teacherFilesNotice){
startPage();
List<TeacherFilesNotice> teacherFilesNotices = teacherFilesService.selctTeacherByUserId(userId);
List<TeacherFilesNotice> teacherFilesNotices = teacherFilesService.selctTeacherByUserId(userId,teacherFilesNotice);
return getDataTable(teacherFilesNotices);
}
......@@ -127,7 +150,6 @@ public class TeacherFilesController extends BaseController
return toAjax(teacherFilesService.deleteTeacherFilesByIds(ids));
}
/**
* 教师档案同步
*/
......@@ -139,27 +161,34 @@ public class TeacherFilesController extends BaseController
return toAjax(teacherFilesService.synchronous(id));
}
@PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')")
@Log(title = "教师档案审核通过", businessType = BusinessType.UPDATE)
@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.setId(id);
teacherFiles.setId(id[i]);
teacherFiles.setState("5");
return toAjax(teacherFilesService.updateTeacherFiles(teacherFiles));
date = teacherFilesService.updateTeacherFiles(teacherFiles);
}
return toAjax(date);
}
@PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')")
@Log(title = "教师档案审核驳回", businessType = BusinessType.UPDATE)
@PutMapping("/reject/{id}")
public AjaxResult reject(@PathVariable("id") Long id)
public AjaxResult reject(@PathVariable("id") Long[] id)
{
Integer date = null;
for (int i = 0 ; i< id.length ; i++){
TeacherFiles teacherFiles = new TeacherFiles();
teacherFiles.setId(id);
teacherFiles.setId(id[i]);
teacherFiles.setState("9");
return toAjax(teacherFilesService.updateTeacherFiles(teacherFiles));
date = teacherFilesService.updateTeacherFiles(teacherFiles);
}
return toAjax(date);
}
@PreAuthorize("@ss.hasPermi('teacherFiles:notice:edit')")
......
......@@ -3,6 +3,7 @@ package yangtz.cs.liu.campus.domain.organization;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.core.domain.OurBaseEntity;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import com.ruoyi.common.annotation.Excel;
......@@ -13,12 +14,11 @@ import com.ruoyi.common.annotation.Excel;
* @date 2023-09-06
*/
@Data
public class SchoolOrganizationSignin extends OurBaseEntity
public class SchoolOrganizationSignin extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** id */
@TableId(value = "id", type = IdType.AUTO)
@Excel(name = "id")
private Long id;
/** 姓名 */
......
package yangtz.cs.liu.campus.domain.schoolEquipment;
import com.ruoyi.common.annotation.Excel;
import java.math.BigDecimal;
import java.util.Date;
import com.core.domain.OurBaseEntity;
......@@ -52,13 +54,12 @@ public class SchoolCirculation extends OurBaseEntity
/** 接收人 */
private String receivedBy;
/** 预计使用时间 */
/** 预计使用期限 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date yjuseTime;
/** 实际使用时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date sjuseTime;
private String sjuseTime;
/** 备注 */
private String remark;
......
......@@ -48,6 +48,10 @@ public class SchoolEquipmentRepair extends OurBaseEntity
/** 修理人 */
private String repairName;
/**
* 地点
*/
private String place;
/** 修理人联系方式 */
private Long repairPhone;
......
......@@ -33,7 +33,6 @@ public class SchoolGradeMentor extends OurBaseEntity {
private String type;
/** 职务 */
@NotBlank(message = "职务不能为空")
private String teacherPost;
/** 学科组(1物理学科组,2化学学科组,3生物学科组) */
......
......@@ -40,9 +40,14 @@ public class SchoolTeacherWages extends OurBaseEntity {
private BigDecimal basePay;
/**
* 教师电话
*/
@Excel(name = "教师联系方式")
private String teacherTel;
/**
* 身份证号
*/
@Excel(name = "身份证号")
private String idCard;
/**
......
......@@ -46,4 +46,8 @@ public class ShebeiJy extends OurBaseEntity {
@Excel(name = "借用期限")
private int deadline;
//归还状态(1已归还,0未归还)
@Excel(name = "归还状态", readConverterExp = "1=已归还,0=未归还", combo = {"已归还","未归还"})
private String returnState;
}
......@@ -52,4 +52,8 @@ public class TeacherJy extends OurBaseEntity {
@Excel(name = "借用期限")
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> {
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")
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>
* @return
*/
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;
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"
+ "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")
......@@ -24,7 +24,7 @@ public interface EquipmentRepairMapper extends BaseMapper<SchoolEquipmentRepair>
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"
+ "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"
+ "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();
......
......@@ -13,4 +13,11 @@ public interface SchoolTeacherWagesMapper extends BaseMapper<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;
import org.apache.ibatis.annotations.Param;
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.TeacherFilesNoticeTotal;
import yangtz.cs.liu.campus.vo.teacherFiles.SchoolClassByGradeVo;
......@@ -42,8 +43,7 @@ public interface TeacherFilesNoticeMapper
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(Long userId);
public List<TeacherFilesNotice> selctTeacherByUserId(@Param("userId") Long userId, @Param("teacherFiles") TeacherFilesNotice teacherFiles);
/**
* 修改教师档案通知
......
......@@ -582,6 +582,7 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch
@Override
public List<ViewDataVo> turnData(List<SchoolDcwjAnVo> list) {
List<ViewDataVo> voList = new ArrayList<>();
List<SchoolDcwjNr> schoolDcwjNrs = schoolDcwjNrMapper.selectSchoolDcwjNrList(new SchoolDcwjNr());
for (SchoolDcwjAnVo anVo : list) {
ViewDataVo vo = new ViewDataVo();
BeanUtils.copyProperties(anVo, vo);
......@@ -591,7 +592,9 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch
i++;
continue;
}
SchoolDcwjNr nr = schoolDcwjNrMapper.selectById(an.getNrId());
// SchoolDcwjNr nr = schoolDcwjNrMapper.selectById(an.getNrId());
for (SchoolDcwjNr nr : schoolDcwjNrs) {
if (nr.getId().equals(an.getNrId())){
DataTVo tVo = new DataTVo();
tVo.setDatas(an.getUserAnswer());
tVo.setType(nr.getNrLx());
......@@ -899,6 +902,314 @@ public class SchoolDcwjNrServiceImpl extends ServiceImpl<SchoolDcwjNrMapper, Sch
}
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,会出错。。。。
/* if(StringUtils.isNull(anVo.getList()) || anVo.getList().size() == 0){
......
......@@ -179,6 +179,13 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime);
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) {
List<SchoolDcwjAn> ans = new ArrayList<>();
......@@ -187,20 +194,29 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
//获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值
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);
if(StringUtils.isNotNull(a) && a.size() > 0){
ans.add(a.get(0));
// 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);
}
return list;
......@@ -215,6 +231,13 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
nrlqw.eq(SchoolDcwjNr::getDcwjId, dcwjId).orderByAsc(SchoolDcwjNr::getNrPx).orderByDesc(SchoolDcwjNr::getCreateTime);
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) {
List<SchoolDcwjAn> ans = new ArrayList<>();
......@@ -223,20 +246,29 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
//获取该学生从第一题到最后一题的答案,如果当前题没有答案,,附空值
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);
if(StringUtils.isNotNull(a) && a.size() > 0){
ans.add(a.get(0));
// 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);
}
return list;
......@@ -2060,4 +2092,14 @@ public class SchoolDcwjRyServiceImpl extends ServiceImpl<SchoolDcwjRyMapper, Sch
}
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
public SchoolCirculationVo getSchoolCirculationVoByenCode(String 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
public int insertSchoolCirculation(SchoolCirculation schoolCirculation) {
//判断该设备是否允许借出
SchoolEquipmentLedger schoolEquipmentLedger1 = equipmentLedgerMapper.selectById(schoolCirculation.getEquipmentId());
if (StringUtils.isNull(schoolEquipmentLedger1)){
throw new ServiceException("未查询到该设备,请重新输入!");
}
if (schoolEquipmentLedger1.getIsAllowLend().equals("0")){
throw new ServiceException("该设备不允许借出");
}
......
......@@ -19,8 +19,10 @@ import yangtz.cs.liu.campus.mapper.schoolEquipment.*;
import yangtz.cs.liu.campus.service.schoolEquipment.IEquipmentLedgerService;
import yangtz.cs.liu.campus.vo.schoolEquipment.SchoolEquipmentLedgerVo;
import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;
......@@ -223,16 +225,6 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe
}else if(schoolEquipmentLedger.getClassificationCode().length() < 4){
failureNum++;
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())){
failureNum++;
failureMsg.append("<br/>" + failureNum + "、单位为空,请你重新输入!");
......@@ -260,6 +252,31 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe
}else if (StringUtils.isNull(schoolEquipmentLedger.getPlace())){
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) {
......@@ -276,4 +293,14 @@ public class EquipmentLedgerServiceImpl extends ServiceImpl<EquipmentLedgerMappe
public List<Map<String, Object>> getUser(SysUser 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;
import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.core.domain.entity.SysRole;
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.SecurityUtils;
import com.ruoyi.common.utils.StringUtils;
......@@ -144,7 +145,11 @@ public class EquipmentRepairServiceImpl extends ServiceImpl<EquipmentRepairMappe
@Override
public Map<String, String> getEquipment(String encode) {
// 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;
import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.core.domain.entity.SysRole;
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.SecurityUtils;
import com.ruoyi.common.utils.StringUtils;
......@@ -71,6 +72,14 @@ public class ReceiveServiceImpl extends ServiceImpl<ReceiveMapper, SchoolReceive
*/
@Override
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())){
String userName = sysUserMapper.selectUserById(schoolReceive.getRecipientById()).getUserName();
schoolReceive.setRecipientBy(userName);
......
......@@ -10,9 +10,12 @@ import com.ruoyi.system.mapper.SysUserMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
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.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.SchoolTeacherExperimentApplyVo;
import java.util.ArrayList;
import java.util.List;
......@@ -33,6 +36,8 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab>
@Autowired
private SysUserMapper sysUserMapper;
@Autowired
private SchoolLabClassYearMapper schoolLabClassYearMapper;
/**
* 查询实验室
*
......
......@@ -139,8 +139,8 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta
}
boolean isMerge = isMergedRegion(sheet, i, 0);
//schoolBudgetDetails.setBudgetDetailed(row.getCell(6).getStringCellValue());
schoolBudgetDetails.setBudgetDetailed(TemplateExcelUtils.getCellValue(row.getCell(6), workbook));
schoolBudgetDetails.setMoneyDetailed(new BigDecimal(new DataFormatter().formatCellValue(row.getCell(7))));
schoolBudgetDetails.setBudgetDetailed(TemplateExcelUtils.getCellValue(row.getCell(7), workbook));
schoolBudgetDetails.setMoneyDetailed(new BigDecimal(new DataFormatter().formatCellValue(row.getCell(8))));
if(isMerge){ //如果是合并单元格
isSameCell = isSameMergeRegion(sheet,i,0); //判断与上一行是否为同一单元格
if(!isSameCell){
......@@ -157,14 +157,14 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta
schoolBudget.setBudgetName(budgetName);
giveMoney = getMergedRegionValue(sheet, row.getRowNum(), 3);
schoolBudget.setGiveMoney(new BigDecimal(giveMoney));
isGov = getMergedRegionValue(sheet, row.getRowNum(), 4);
isGov = getMergedRegionValue(sheet, row.getRowNum(), 5);
if(isGov.equals("是")){
schoolBudget.setIsGov("0");
}
if(isGov.equals("否")){
schoolBudget.setIsGov("1");
}
remark = getMergedRegionValue(sheet, row.getRowNum(), 5);
remark = getMergedRegionValue(sheet, row.getRowNum(), 6);
schoolBudget.setRemark(remark);
schoolBudgetMapper.insert(schoolBudget);
budgetId = schoolBudget.getId();
......@@ -182,14 +182,14 @@ public class SchoolBudgetDetailsServiceImpl extends ServiceImpl<SchoolBudgetDeta
schoolBudget.setDeptId(deptId);
schoolBudget.setBudgetName(new DataFormatter().formatCellValue(row.getCell(2)));
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("是")){
schoolBudget.setIsGov("0");
}
if(isGov.equals("否")){
schoolBudget.setIsGov("1");
}
schoolBudget.setRemark(new DataFormatter().formatCellValue(row.getCell(5)));
schoolBudget.setRemark(new DataFormatter().formatCellValue(row.getCell(6)));
schoolBudgetMapper.insert(schoolBudget);
schoolBudgetDetails.setBudgetId(schoolBudget.getId());
schoolBudgetDetailsMapper.insert(schoolBudgetDetails);
......
......@@ -116,15 +116,24 @@ public class SchoolStudentServiceImpl extends ServiceImpl<SchoolStudentMapper, S
if (isNull(list) || list.size() == 0) {
return new ArrayList<>();
}
for (SchoolStudentVO vo : list) {
//获取所有学生家长
LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
lqw.eq(SchoolStudentParent::getStudentId, vo.getId())
.orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> parentList = schoolStudentParentMapper.selectList(lqw);
lqw.orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> studentParentList = schoolStudentParentMapper.selectList(lqw);
for (SchoolStudentVO vo : list) {
// LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
// lqw.eq(SchoolStudentParent::getStudentId, vo.getId())
// .orderByDesc(SchoolStudentParent::getCreateTime);
// 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) {
continue;
}
//获取学生家长,至多2人
int i = 1;
for (SchoolStudentParent parent : parentList) {
......@@ -172,22 +181,46 @@ public class SchoolStudentServiceImpl extends ServiceImpl<SchoolStudentMapper, S
List<SchoolStudentVO> list = new ArrayList<>();
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) {
SchoolStudentVO vo = new SchoolStudentVO();
BeanUtils.copyProperties(student, vo);
//学年年级班级
SchoolClass theClass = schoolClassMapper.selectById(student.getClassId());
if (isNotNull(theClass)) {
vo.setSchoolYear(theClass.getSchoolYear());
vo.setGradeValue(theClass.getGradeValue());
vo.setClassValue(theClass.getClassValue());
for (SchoolClass schoolClass : schoolClasses) {
if (schoolClass.getId().equals(student.getClassId())){
vo.setSchoolYear(schoolClass.getSchoolYear());
vo.setGradeValue(schoolClass.getGradeValue());
vo.setClassValue(schoolClass.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<>();
lqw.eq(SchoolStudentParent::getStudentId, student.getId())
.orderByDesc(SchoolStudentParent::getCreateTime);
List<SchoolStudentParent> parentList = schoolStudentParentMapper.selectList(lqw);
// LambdaQueryWrapper<SchoolStudentParent> lqw = new LambdaQueryWrapper<>();
// lqw.eq(SchoolStudentParent::getStudentId, student.getId())
// .orderByDesc(SchoolStudentParent::getCreateTime);
// 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) {
list.add(vo);
continue;
......
......@@ -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.vo.student.SchoolTeacherWagesVO;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;
......@@ -123,7 +124,7 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
public int insertByTeacherId(Long teacherId,SchoolTeacherWages schoolTeacherWages) {
SchoolTeacher schoolTeacher = schoolTeacherMapper.selectById(teacherId);
schoolTeacherWages.setTeacherName(schoolTeacher.getTeacherName());
schoolTeacherWages.setIdCard(schoolTeacher.getIdCard());
schoolTeacherWages.setTeacherTel(schoolTeacher.getTeacherTel());
return schoolTeacherWagesMapper.insert(schoolTeacherWages);
}
......@@ -143,12 +144,10 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
if (StringUtils.isEmpty(schoolTeacherWages.getTeacherName())) {
failureNum++;
failureMsg.append("<br/>" + failureNum + "、教师姓名为空,请您重新输入! ");
}
// else if (StringUtils.isEmpty(schoolTeacherWages.getIdCard())) {
// failureNum++;
// failureMsg.append("<br/>" + failureNum + "、身份证号为空,请您重新输入! ");
// }
else if (StringUtils.isNull(schoolTeacherWages.getWagesTime())) {
} else if (StringUtils.isEmpty(schoolTeacherWages.getTeacherTel())) {
failureNum++;
failureMsg.append("<br/>" + failureNum + "、教师联系方式为空,请您重新输入! ");
} else if (StringUtils.isNull(schoolTeacherWages.getWagesTime())) {
failureNum++;
failureMsg.append("<br/>" + failureNum + "、工资日期为空,请您重新输入!");
} else if (isNotNull(schoolTeacherWages.getWagesTime())) {
......@@ -159,15 +158,62 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
} catch (Exception e) {
throw new ServiceException("格式不对,请检查日期格式");
}
}else {
LambdaQueryWrapper<SchoolTeacherWages> lqw = new LambdaQueryWrapper<>();
}
// 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(SchoolTeacherWages::getIdCard, schoolTeacherWages.getIdCard());
SchoolTeacherWages teacherWages = schoolTeacherWagesMapper.selectOne(lqw);
if (isNull(teacherWages)){
.eq(SchoolTeacher::getTeacherTel, schoolTeacherWages.getTeacherTel());
SchoolTeacher schoolTeacher = schoolTeacherMapper.selectOne(lqw);
if (isNull(schoolTeacher)){
failureNum++;
failureMsg.append("<br/>" + failureNum + "、该老师不存在,请您重新输入! ");
}
}else {
schoolTeacherWages.setTeacherId(schoolTeacher.getId());
}
}
if (failureNum > 0) {
......@@ -186,16 +232,19 @@ public class SchoolTeacherWagesServiceImpl extends ServiceImpl<SchoolTeacherWage
// 准备记录日志数据
int successNum = 0;
StringBuilder successMsg = new StringBuilder();
for (SchoolTeacherWages schoolTeacherWages : list) {
try {
schoolTeacherWagesMapper.insert(schoolTeacherWages);
successNum++;
successMsg.append("<br/>" + successNum + "数据" + " 导入成功");
} catch (Exception e) {
throw new ServiceException("导入失败");
}
}
successMsg.insert(0, "恭喜您,数据已导入成功!共有 " + successNum + " 条,数据如下:");
schoolTeacherWagesMapper.batchInsertTeacherWages(list);
// for (SchoolTeacherWages schoolTeacherWages : list) {
// try {
// schoolTeacherWagesMapper.insert(schoolTeacherWages);
// successNum++;
// successMsg.append("<br/>" + successNum + "数据" + " 导入成功");
// } catch (Exception e) {
// throw new ServiceException("导入失败");
// }
// }
successMsg.insert(0, "恭喜您,数据已导入成功!");
return successMsg.toString();
}
......
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.StringUtils;
import com.ruoyi.common.utils.TermRange;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.award.Award;
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.thesis.Thesis;
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.service.teacherFiles.ITeacherFilesService;
import yangtz.cs.liu.wechat.vo.schoolClass.SchoolClassVo;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.text.SimpleDateFormat;
import java.util.*;
/**
......@@ -44,7 +52,18 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService
@Autowired
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
@Override
public List<TeacherFilesNotice> selctTeacherByUserId(Long userId) {
return teacherFilesNoticeMapper.selctTeacherByUserId(userId);
public List<TeacherFilesNotice> selctTeacherByUserId(Long userId,TeacherFilesNotice teacherFiles) {
return teacherFilesNoticeMapper.selctTeacherByUserId(userId,teacherFiles);
}
/**
......@@ -113,7 +132,91 @@ public class TeacherFilesServiceImpl implements ITeacherFilesService
@Override
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
public List<Long> getGradeId(Long 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>
//班主任-问卷结果-统计
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> {
SchoolCirculationVo getSchoolCirculationVoById(Long id);
SchoolCirculationVo getSchoolCirculationVoByenCode(String enCode);
SchoolCirculationVo getReturningEquipmentById(String id);
/**
* 查看设备借出归还列表
* @param schoolCirculationVo
......
......@@ -70,4 +70,10 @@ public interface IEquipmentLedgerService extends IService<SchoolEquipmentLedger>
*/
List<Map<String,Object>> getUser(SysUser sysUser);
/**
* 打印设备条码信息
* @param ids
* @return
*/
List<Map<String, Object>> getEquipmentledger(Long[] ids);
}
package yangtz.cs.liu.campus.service.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.TeacherFilesVO;
......@@ -29,7 +30,15 @@ public interface ITeacherFilesService
* @return 教师档案集合
*/
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
/** 预计使用时间 */
@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;
/** 实际使用时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "实际使用时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
private Date sjuseTime;
@Excel(name = "实际使用时间")
private String sjuseTime;
/** 备注 */
@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 {
private String handUserName;
/** 创建时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date createTime;
......
......@@ -5,6 +5,7 @@ import cn.hutool.http.HttpUtil;
import com.alibaba.fastjson2.JSONArray;
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.SysUser;
import com.ruoyi.common.utils.SecurityUtils;
......@@ -116,7 +117,7 @@ public class DingJiaXiaoController {
//更新年级与班级
@GetMapping("/updateLabClassYear")
private String updateLabClassYear(){
public String updateLabClassYear(){
String token = accessTokenUtils.getToken();
//年级
List<SchoolGrade> schoolGradeCopies = new ArrayList<>();
......@@ -273,7 +274,7 @@ public class DingJiaXiaoController {
//更新追加人员信息
@GetMapping("/updateLabUser")
private String updateLabUser(){
public String updateLabUser(){
//查找当前学年 所有的班级
String nowSchoolYear = schoolGradeService.selectUpToYear();
SchoolClass schoolClass = new SchoolClass();
......@@ -304,11 +305,19 @@ public class DingJiaXiaoController {
}
SchoolTeacher classHeadTeacher = schoolTeacherCopies.get(0);
if ("1".equals(teachDate.getIsAdviser())){
//查询数据库中是否有 没有新增
LambdaQueryWrapper<SchoolClassHeadmaster> lqw=new LambdaQueryWrapper<>();
lqw.eq(SchoolClassHeadmaster::getTeacherId,classHeadTeacher.getId());
lqw.eq(SchoolClassHeadmaster::getClassId,date.getId());
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();
schoolClassss.setId(date.getId());
......@@ -317,11 +326,18 @@ public class DingJiaXiaoController {
schoolClassss.setTeacherTel(classHeadTeacher.getTeacherTel());
iSchoolClassService.updateById(schoolClassss);
}else {
//查找部门 课程没有编写
SysUser sysUser = sysUserService.selectUserById(classHeadTeacher.getId());
String deptName = sysUser.getDept().getDeptName();
//根据部门查找课程信息
SchoolCurriculum schoolCurriculum = schoolCurriculumMapper.selectCourseName(deptName);
LambdaQueryWrapper<SchoolClassMentor> lqw=new LambdaQueryWrapper<>();
lqw.eq(SchoolClassMentor::getTeacherId,classHeadTeacher.getId());
lqw.eq(SchoolClassMentor::getClassId,date.getId());
List<SchoolClassMentor> list = schoolClassMentorService.list(lqw);
if (list.isEmpty()){
//任课老师 跟班级关系
SchoolClassMentor schoolClassMentor = new SchoolClassMentor();
schoolClassMentor.setTeacherId(classHeadTeacher.getId());
......@@ -329,12 +345,22 @@ public class DingJiaXiaoController {
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")) {
//学生
studentUserInfos = this.addUserList(token, type, date.getDdClassId());
for (DingJiaXiaoVo.StudentUserInfo studentDte : studentUserInfos) {
//当前是否有这个学生
Long ddUserId = null;
ddUserId = schoolStudentService.getDdUserId(studentDte.getUserId());
if (null == ddUserId ){
//学生信息
SchoolStudent schoolStudent = new SchoolStudent();
schoolStudent.setStudentName(studentDte.getName());
......@@ -342,20 +368,48 @@ public class DingJiaXiaoController {
schoolStudent.setStudentStatus("1");
schoolStudent.setDdUserId(studentDte.getUserId());
schoolStudentService.save(schoolStudent);
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(schoolStudent.getId());
schoolStudentClassRelation.setStudentId(ddUserId);
schoolStudentClassRelation.setClassId(date.getId());
iSchoolStudentClassRelationService.save(schoolStudentClassRelation);
}
//学生与班级历史关系
SchoolClass school= iSchoolClassService.selectSchoolClassById(date.getId());
LambdaQueryWrapper<SchoolStudentClasses> lsqw=new LambdaQueryWrapper<>();
lsqw.eq(SchoolStudentClasses::getStudentId,ddUserId);
lsqw.eq(SchoolStudentClasses:: getGrade,school.getGradeName());
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(schoolStudent.getId());
schoolStudentClasses.setStudentId(ddUserId);
schoolStudentClasses.setGrade(school.getGradeName());
schoolStudentClasses.setClasses(school.getClassName());
schoolStudentClasses.setTeacherName(school.getTeacherName());
schoolStudentClassesService.save(schoolStudentClasses);
}
}
} else if (type.equals("guardian")) {
//监护人
guardianUserInfos = this.addUserList(token, type, date.getDdClassId());
......@@ -363,7 +417,10 @@ public class DingJiaXiaoController {
//找寻学生
String toUserId = this.getToUserId(token, guarDate.getUserId(), date.getDdClassId());
Long ddUserId = schoolStudentService.getDdUserId(toUserId);
Long userId = null;
//查找监护人
SysUser sysUser = sysUserService.selectUserByDdUserId(ddUserId.toString());
if (null == sysUser){
//创建用户user表
SysUser jUser = new SysUser();
jUser.setLoginName(guarDate.getName());
......@@ -379,15 +436,44 @@ public class DingJiaXiaoController {
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);
}
//家长表
LambdaQueryWrapper<SchoolStudentParent> lsqw=new LambdaQueryWrapper<>();
lsqw.eq(SchoolStudentParent::getUserId,userId);
lsqw.eq(SchoolStudentParent::getStudentId,ddUserId);
List<SchoolStudentParent> list = iSchoolStudentParentService.list(lsqw);
if (list.isEmpty()){
SchoolStudentParent schoolStudentParent = new SchoolStudentParent() ;
schoolStudentParent.setStudentId(ddUserId);
schoolStudentParent.setUserId(jUser.getUserId());
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 {
calendar.add(Calendar.DATE,Integer.valueOf(deadline.toString()));
Date targetDate = calendar.getTime();
schoolCirculation.setReturnState("0");
schoolCirculation.setReturnTime(targetDate);
schoolCirculation.setYjuseTime(targetDate);
boolean save = iCirculationService.save(schoolCirculation);
//修改设备表借出状态
SchoolEquipmentLedger byId = iEquipmentService.getById(schoolCirculation.getEquipmentId());
......@@ -258,28 +258,36 @@ public class EquipmentLeaseController {
* 管理员查看详情
*/
@GetMapping("/getReturningEquipmentByList/{encode}")
private AjaxResult getReturningEquipmentByList(@PathVariable("encode") String encode){
private AjaxResult getReturningEquipmentByList(@PathVariable("encode") String encode) {
SchoolCirculationVo schoolCirculationVo = new SchoolCirculationVo();
//先查询物品表有没有借出去
LambdaQueryWrapper<SchoolEquipmentLedger> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolEquipmentLedger::getEncode,encode);
wrapper.eq(SchoolEquipmentLedger::getEncode, encode);
SchoolEquipmentLedger one = iEquipmentService.getOne(wrapper);
if (one.getIsLend().equals("0")){
if (one.getIsLend().equals("0")) {
//未借出
schoolCirculationVo.setEquipmentId(one.getId());
schoolCirculationVo.setEquipmentName(one.getEquipmentName());
schoolCirculationVo.setModel(one.getModel());
schoolCirculationVo.setIsLend(one.getIsLend());
return AjaxResult.success(schoolCirculationVo);
}else {
} else {
//已借出
SchoolCirculationVo schoolCirculationVoByenCode = iCirculationService
.getSchoolCirculationVoByenCode(encode);
//根据管理员信息查看信息详情
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 {
//修改设备表借出状态
SchoolEquipmentLedger byId = iEquipmentService.getById(schoolCirculation.getEquipmentId());
byId.setIsLend("0");
byId.setEquipmentState(schoolCirculation.getReturnEquipmentCondition());
iEquipmentService.updateById(byId);
return AjaxResult.success(b);
}
......
......@@ -5,6 +5,7 @@ import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
......@@ -54,8 +55,12 @@ public class ExperimentAdministratorsControoler extends BaseController {
@GetMapping("/classYear/list")
public AjaxResult classYearList(SchoolLabClassYearVo schoolLabClassYearVo)
{
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));
}
......
......@@ -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.page.TableDataInfo;
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.ISysUserService;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -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.schoolgrade.SchoolGrade;
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.ISchoolLabClassYearService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService;
......@@ -30,6 +32,7 @@ import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
import java.util.List;
import java.util.stream.Collectors;
/**
* 实验室 级部申请
......@@ -57,6 +60,11 @@ public class ExperimentLevelController extends BaseController {
@Autowired
private ISysDeptService deptService;
@Autowired
UserInfoUtil userInfoUtil;
@Autowired
private ISchoolClassMentorService schoolClassMentorService;
/**
* 获取当前学年+学期
*/
......@@ -154,7 +162,17 @@ public class ExperimentLevelController extends BaseController {
@GetMapping("/list")
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));
}
......@@ -205,6 +223,9 @@ public class ExperimentLevelController extends BaseController {
*/
@GetMapping("/getexperimentList")
public AjaxResult getexperimentList(ClassSituationVo classSituationVo){
//获取管理员学科
String sub = schoolLabClassYearService.getSub();
classSituationVo.setSub(sub);
List<ClassSituationVo> classSituationVos = schoolLabClassYearService.getexperimentList(
classSituationVo);
return AjaxResult.success(classSituationVos);
......
......@@ -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.SchoolTeacherLabApplyVo;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.*;
import java.util.stream.Collectors;
/**
......@@ -145,7 +143,10 @@ public class TeacherExperimentController extends BaseController {
*/
@GetMapping(value = "/list")
public AjaxResult list(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{
Long userId = userInfoUtil.getMpLoginUser().getUserId();
schoolTeacherLabApplyVo.setApplyId(userId);
return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo));
}
/**
......@@ -183,21 +184,25 @@ public class TeacherExperimentController extends BaseController {
@GetMapping("/getSubject")
public AjaxResult getSubject(){
Long userId = userInfoUtil.getMpLoginUser().getUserId();
List<SysRole> sysRoles = roleService.selectRolesByUserIdDdApp(userId);
for (SysRole role : sysRoles) {
if (role.getRoleKey().equals("phy_lab_admin")){
return AjaxResult.success(dictDataService.selectDictLabel("lab_sub","1"));
}else if (role.getRoleKey().equals("che_lab_admin")){
return AjaxResult.success(dictDataService.selectDictLabel("lab_sub","2"));
}else if (role.getRoleKey().equals("bio_lab_admin")){
return AjaxResult.success(dictDataService.selectDictLabel("lab_sub","3"));
Map<String,String> mapList = new HashMap<>();
//设置级部
//获取学科
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);
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;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.framework.util.UserInfoUtil;
import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
......@@ -18,7 +19,9 @@ import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
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.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
/**
......@@ -33,16 +36,17 @@ public class WxSchoolLabControoler extends BaseController {
@Autowired
private UserInfoUtil userInfoUtil;
@Autowired
private SchoolLabClassYearServiceImpl schoolLabClassYearService;
/**
* 查询实验室列表
*/
@GetMapping("/list")
public TableDataInfo list(SchoolLabVo schoolLabVo)
public AjaxResult list(SchoolLabClassYearVo schoolLabClassYearVo)
{
startPage();
Long teacherUserId = userInfoUtil.getMpLoginUser().getUserId();
List<SchoolLabVo> list = schoolLabService.selectSchoolLabList(schoolLabVo,teacherUserId);
return getDataTable(list);
List<Map<String, Object>> labList = schoolLabClassYearService.getLabList(schoolLabClassYearVo);
return AjaxResult.success(labList);
}
/**
......
......@@ -155,8 +155,7 @@ public class WxSchoolOrganizationController extends BaseController {
//根据当前登录人 查询当前社团的报名状态
LambdaQueryWrapper<SchoolOrganizationSignin> wrapper = Wrappers.lambdaQuery();
wrapper.eq(SchoolOrganizationSignin::getUserId,userId)
.eq(SchoolOrganizationSignin::getCid,vo.getCid())
.eq(SchoolOrganizationSignin::getDelFlag,"0");
.eq(SchoolOrganizationSignin::getCid,vo.getCid());
SchoolOrganizationSignin one = schoolOrganizationSigninService.getOne(wrapper);
if (one==null){
//根据studentId 获取当前登录人信息 返回给前端
......
......@@ -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="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>
order by c.create_time DESC
</select>
<select id="selectSchoolCirculationVoListGr" parameterType="SchoolCirculationVo" resultMap="schoolCirculationVoResult">
......@@ -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="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>
order by c.create_time DESC
</select>
<select id="selectSchoolCirculationVoById" parameterType="Long" resultMap="schoolCirculationVoResult">
......
......@@ -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="equipmentState != null and equipmentState != ''" >and el.equipment_state = #{equipmentState}</if>
<if test="affiliationType != null and affiliationType != ''" >and el.affiliation_type = #{affiliationType}</if>
order by el.create_time DESC
</select>
<select id="selectSchoolEquipmentLedgerListGr" parameterType="SchoolEquipmentLedgerVo" resultMap="schoolEquipmentLedgerResult">
......@@ -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="equipmentState != null and equipmentState != ''" >and el.equipment_state = #{equipmentState}</if>
<if test="affiliationType != null and affiliationType != ''" >and el.affiliation_type = #{affiliationType}</if>
order by el.create_time DESC
</select>
<update id="outSchoolEquipmentLedger" parameterType="String">
......@@ -79,4 +81,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND user_name like concat('%', #{userName}, '%')
</if>
</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>
......@@ -30,6 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="delFalg" column="del_flag" />
<result property="place" column="place" />
</resultMap>
<select id="selectSchoolEquipmentRepairVoList" parameterType="SchoolEquipmentRepairVo" resultMap="schoolEquipmentRepairVoResult">
......@@ -40,7 +41,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
el.equipment_name,
el.model,
el.date_of_production,
el.place,
er.place,
el.classification_code,
er.report_repair_time,
er.report_repair_id,
......@@ -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="repairState != null and repairState != ''">and er.repair_state = #{repairState}</if>
<if test="disposeState != null and disposeState != ''">and er.dispose_state = #{disposeState}</if>
order by er.create_time DESC
</select>
<select id="selectSchoolEquipmentRepairVoListGr" parameterType="SchoolEquipmentRepairVo" resultMap="schoolEquipmentRepairVoResult">
......@@ -75,7 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
el.equipment_name,
el.model,
el.date_of_production,
el.place,
er.place,
el.classification_code,
er.report_repair_time,
er.report_repair_id,
......@@ -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="repairState != null and repairState != ''">and er.repair_state = #{repairState}</if>
<if test="disposeState != null and disposeState != ''">and er.dispose_state = #{disposeState}</if>
order by er.create_time DESC
</select>
<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,
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.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>
</select>
<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,
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
<if test="equipmentName != null and equipmentName != ''">and el.equipment_name like concat('%', #{equipmentName}, '%')</if>
ORDER BY er.report_repair_time DESC
</select>
......@@ -133,7 +135,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
el.equipment_name,
el.model,
el.date_of_production,
el.place,
er.place,
el.classification_code,
er.report_repair_time,
er.report_repair_id,
......@@ -155,12 +157,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<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.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
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>
ORDER BY er.report_repair_time DESC
</select>
......@@ -177,6 +180,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
school_equipment_ledger
WHERE
encode = #{encode}
and del_flag = '0'
</select>
......
......@@ -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="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by i.create_time DESC
</select>
<select id="selectSchoolInStockVoListGr" parameterType="SchoolInStockVo" resultMap="schoolInStockVoResult">
......@@ -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="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by i.create_time DESC
</select>
<select id="selectSchoolInStockVoById" parameterType="Long" resultMap="schoolInStockVoResult">
......
......@@ -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="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by create_time DESC
</select>
<select id="selectSchoolOutStockVoListGr" parameterType="SchoolOutStockVo" resultMap="schoolOutStockVoResult">
......@@ -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="classificationCode != null and classificationCode != ''">and el.classification_code like concat('%', #{classificationCode}, '%')</if>
<if test="equipmentState != null and equipmentState != ''">and el.equipment_state = #{equipmentState}</if>
order by create_time DESC
</select>
<select id="selectSchoolOutStockVoById" parameterType="Long" resultMap="schoolOutStockVoResult">
......
......@@ -57,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
r.del_flag = '0'
<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>
order by r.create_time DESC
</select>
<select id="selectSchoolReceiveVoListGr" parameterType="SchoolReceiveVo" resultMap="schoolReceiveVoResult">
......@@ -89,6 +90,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
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="recipientBy != null and recipientBy != ''">and r.recipient_by like concat('%', #{recipientBy}, '%')</if>
order by r.create_time DESC
</select>
<select id="selectSchoolReceiveVoById" parameterType="Long" resultMap="schoolReceiveVoResult">
......
......@@ -69,7 +69,7 @@
AND gm.teacher_id = #{teacherId}
</if>
</where>
order by create_time DESC
order by cy.create_time DESC
</select>
<select id="selectExperimentPlanListAdmin" parameterType="SchoolExperimentPlanVo" resultMap="SchoolExperimentPlanVoResult">
......
......@@ -86,6 +86,12 @@
#{declareState}
</foreach>
</if>
<if test="subs != null">
and lcy.sub in
<foreach item="sub" collection="subs" open="(" separator="," close=")">
#{sub}
</foreach>
</if>
</where>
order by create_time DESC
</select>
......@@ -339,6 +345,7 @@
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
<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
</select>
</mapper>
......@@ -6,6 +6,7 @@
<result property="id" column="id" />
<result property="teacherId" column="teacher_id" />
<result property="teacherName" column="teacher_name" />
<result property="teacherTel" column="teacher_tel" />
<result property="idCard" column="id_card" />
<result property="basePay" column="base_pay" />
<result property="bonus" column="bonus" />
......@@ -29,7 +30,7 @@
</resultMap>
<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>
<select id="queryList" parameterType="SchoolTeacherWages" resultMap="SchoolTeacherWagesResult">
......@@ -55,4 +56,15 @@
order by create_time desc
</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>
......@@ -25,7 +25,7 @@
<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
JOIN school_equipment_ledger sel
ON ser.equipment_id=sel.id
......
......@@ -14,11 +14,12 @@
<result property="borrowBy" column="borrow_by"/>
<result property="purpose" column="purpose"/>
<result property="deadline" column="deadline"/>
<result property="returnState" column="return_state"/>
</resultMap>
<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
JOIN school_equipment_ledger ssc
ON ss.equipment_id=ssc.id
......
......@@ -24,7 +24,7 @@
</resultMap>
<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
JOIN school_equipment_ledger sel
ON ser.equipment_id=sel.id
......
......@@ -12,10 +12,11 @@
<result property="borrowBy" column="borrow_by"/>
<result property="purpose" column="purpose"/>
<result property="deadline" column="deadline"/>
<result property="returnState" column="return_state"/>
</resultMap>
<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
JOIN school_equipment_ledger ssc
ON ss.equipment_id=ssc.id
......
......@@ -44,6 +44,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
</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">
<include refid="selectTeacherFilesNoticeTotalVo"/>
<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