Commit 6f109867 by zhaopanyu

Merge branch 'master' of 49.232.152.146:xhxy/smart_school

parents 1222aa5b b6ae2d23
<template>
<div>
<!-- 搜索条件 -->
<el-form
:model="queryForm"
ref="queryForm"
size="small"
:inline="true"
label-width="68px"
>
<el-form-item label="仪器名称">
<el-input
v-model="queryForm.name"
placeholder="请输入"
clearable
></el-input>
</el-form-item>
<el-form-item label="仪器分类">
<el-select
v-model="queryForm.name"
placeholder="请选择"
clearable
>
<el-option> </el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="getList"
>搜索</el-button
>
<el-button
icon="el-icon-refresh"
size="mini"
@click="resetQuery"
>重置</el-button
>
</el-form-item>
</el-form>
<!-- 操作按钮 -->
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handAdd()"
v-hasPermi="['system:student:add']"
>新增
</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['system:student:edit']"
>编辑
</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
size="mini"
icon="el-icon-view"
:disabled="single"
@click="handleDelete"
>删除
</el-button>
</el-col>
</el-row>
<!-- 表格 -->
<el-table
:data="tableData"
style="width: 100%"
row-key="name"
border
lazy
:load="load"
:tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
v-model="selectedRows"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55"></el-table-column>
<el-table-column
align="center"
type="index"
label="序号"
width="55"
/>
<el-table-column prop="name" label="仪器名称" width="180" />
<el-table-column prop="name" label="排序" width="180" />
<el-table-column prop="name" label="是否为消耗品" />
<el-table-column prop="name" label="备注" />
<el-table-column align="center" fixed="right" label="操作">
<template slot-scope="scope">
<el-button
@click="handleUpdate(scope.row)"
type="text"
size="small"
>编辑</el-button
>
<el-button
@click="handleDelete(scope.row)"
type="text"
size="small"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<!-- 弹窗 -->
<el-dialog
:title="title"
:visible.sync="dialogTableVisible"
width="30%"
show-close
>
<el-form :model="form" ref="form" size="small" label-width="108px">
<el-row>
<el-col :span="20">
<el-form-item label="上级分类">
<el-input
v-model="form.name"
placeholder="请输入"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="20">
<el-form-item label="仪器名称">
<el-input
v-model="form.name"
placeholder="请输入"
clearable
>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="20">
<el-form-item label="排序">
<el-input
v-model="form.name"
placeholder="请输入"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="20">
<el-form-item label="是否为消耗品">
<el-radio-group v-model="form.resource">
<el-radio label="是"></el-radio>
<el-radio label="否"></el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="20">
<el-form-item label="备注">
<el-input
v-model="form.name"
placeholder="请输入"
type="textarea"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer">
<el-button type="primary" @click="submitparentForm"
>确定</el-button
>
<el-button @click="cancel">取 消</el-button>
</div>
</el-dialog>
<!-- 分页 -->
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryForm.pageNum"
:limit.sync="queryForm.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
export default {
name: 'instrumentClassification',
data() {
return {
queryForm: {
pageNum: 1,
pageSize: 10,
name: ''
},
selectedRows: [], // 用于存储选择的行数据
//表格数据
tableData: [
{
name: '1'
},
{
name: '2222'
},
{
name: '33',
hasChildren: true
},
{
name: '444'
}
],
title: '',
// 弹窗
form: {},
// 总计
total: 0,
single: false, // 添加 single 属性并设置初始值
multiple: false,
dialogTableVisible: false
}
},
methods: {
// 搜索
getList() {},
// 重置
resetQuery() {},
//
load(tree, treeNode, resolve) {
setTimeout(() => {
resolve([
{
name: '5555'
},
{
name: '666'
}
])
}, 1000)
},
// 新增
handAdd() {
this.dialogTableVisible = true
this.title = '仪器药品新增'
},
// 编辑
handleUpdate() {
this.dialogTableVisible = true
this.title = '仪器药品编辑'
},
// 删除
handleDelete() {},
// 确定
submitparentForm() {
this.dialogTableVisible = false
},
// 取消
cancel() {
this.dialogTableVisible = false
},
// 多选框选中数据
handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
}
}
}
</script>
<style lang="scss" scoped>
.el-form {
margin-top: 15px;
margin-left: 10px;
}
.el-table {
margin-left: 10px;
}
</style>
\ No newline at end of file
<template>
<div>
<el-form
:model="queryForm"
ref="queryForm"
size="small"
:inline="true"
label-width="68px"
>
<el-form-item label="仪器名称">
<el-input
v-model="queryForm.name"
placeholder="请输入"
clearable
></el-input>
</el-form-item>
<el-form-item label="仪器分类">
<el-select
v-model="queryForm.name"
placeholder="请选择"
clearable
>
<el-option> </el-option>
</el-select>
</el-form-item>
<el-form-item label="变更日期">
<el-date-picker
v-model="queryForm.name"
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="getList"
>搜索</el-button
>
<el-button
icon="el-icon-refresh"
size="mini"
@click="resetQuery"
>重置</el-button
>
</el-form-item>
</el-form>
<!-- 表格 -->
<el-table stripe :data="tableData" border style="width: 98%">
<el-table-column
align="center"
type="index"
label="序号"
width="55"
/>
<el-table-column align="center" prop="name" label="仪器名称" />
<el-table-column align="center" prop="name" label="仪器分类" />
<el-table-column align="center" prop="name" label="仪器型号" />
<el-table-column align="center" prop="name" label="变动类型" />
<el-table-column align="center" prop="name" label="变动数量" />
<el-table-column align="center" prop="name" label="旧库存数量" />
<el-table-column align="center" prop="name" label="新库存数量" />
<el-table-column align="center" prop="name" label="变更时间" />
<el-table-column align="center" prop="name" label="备注" />
</el-table>
<!-- 分页 -->
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryForm.pageNum"
:limit.sync="queryForm.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
export default {
name: 'instrumentDetails',
data() {
return {
queryForm: {
pageNum: 1,
pageSize: 10,
name: ''
},
//表格数据
tableData: [
{
name: 111222
}
],
// 总计
total: 0
}
},
methods: {
// 搜索
getList() {},
// 重置
resetQuery() {}
}
}
</script>
<style lang="scss" scoped>
.el-form {
margin-top: 15px;
margin-left: 10px;
}
.el-table {
margin-left: 10px;
}
</style>
\ No newline at end of file
<template>
<div>社团报名审核</div>
</template>
<script>
export default {
name: "clubRegistrationReview"
}
</script>
<style scoped>
</style>
<template>
<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="picName">
<el-input v-model="queryParams.picName" placeholder="请输入年级" clearable/>
</el-form-item>
<el-form-item label="班级:" prop="picName">
<el-input v-model="queryParams.picName" placeholder="请输入班级" clearable/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAdd">新增
</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="danger" icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete">删除
</el-button>
</el-col>
</el-row>
<el-table v-loading="loading" ref="table" :data="picList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/>
<el-table-column label="序号" align="center" prop="seqencing" width="80"/>
<el-table-column label="身份证号" align="center" prop="picName"/>
<el-table-column label="年级" align="center" prop="picName"/>
<el-table-column label="班级" align="center" prop="picName"/>
<el-table-column label="社团部门" align="center" prop="picName"/>
<el-table-column label="社团职位" align="center" prop="picName"/>
<el-table-column label="联系方式" align="center" prop="picName"/>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<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>
</template>
</el-table-column>
</el-table>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList"/>
<!-- 添加或修改社团主题对话框 -->
<el-dialog :title="title" :visible.sync="open" width="30%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="90px" >
<el-form-item label="姓名:" prop="picName">
<el-select v-model="form.value" style="width: 100%;" filterable placeholder="请选择姓名">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item label="性别:" prop="picName">
<el-input readonly v-model="form.picName" placeholder="请输入性别:"/>
</el-form-item>
<el-form-item label="身份证号:" prop="picName">
<el-input readonly v-model="form.picName" placeholder="请输入身份证号"/>
</el-form-item>
<el-form-item label="年级:" prop="picName">
<el-input readonly v-model="form.picName" placeholder="请输入年级"/>
</el-form-item>
<el-form-item label="班级:" prop="picName">
<el-input readonly v-model="form.picName" placeholder="请输入班级"/>
</el-form-item>
<el-form-item label="联系方式:" prop="picName">
<el-input v-model="form.picName" placeholder="请输入联系方式"/>
</el-form-item>
<el-form-item label="社团部门:" prop="picName">
<el-input v-model="form.picName" placeholder="请输入社团部门"/>
</el-form-item>
<el-form-item label="社团职位:" prop="picName">
<el-input v-model="form.picName" placeholder="请输入社团职位"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm">确 定</el-button>
<el-button @click="cancel">取 消</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import {listPic, getPic, delPic, addPic, updatePic, updateState} from '@/api/smartSchool/schoolManage/introduce/pic'
import picAvatar from '@/views/smartSchool/schoolManage/introduce/schoolInfo/profile/picAvatar'
import {changeUserStatus} from '@/api/system/user'
import {uploadImage as commonUpload} from '@/api/common'
import {ExportType, TEXT_SIZE} from '@/enums/common'
export default {
name: 'communityStyle',
components: {picAvatar},
data() {
return {
pev: process.env.VUE_APP_BASE_API,
// 输入框字数限制
TEXT_SIZE,
// 遮罩层
loading: true,
// 选中数组
ids: [],
// 非单个禁用
single: true,
// 非多个禁用
multiple: true,
// 显示搜索条件
showSearch: true,
// 总条数
total: 0,
// 弹出层标题
title: '',
// 是否显示弹出层
open: false,
// 查询参数
queryParams: {
pageNum: 1,
pageSize: 10,
picName: null
},
// 表单参数
form: {},
// 表单校验
rules: {
picName: [{required: true, message: '请输入相片名称', trigger: 'blur'}],
seqencing: [{required: true, message: '请输入排序', trigger: 'blur'}],
remark: [{max: TEXT_SIZE, message: '备注信息在0到200字之间', trigger: 'blur'}]
},
options: [{
value: '选项1',
label: '黄金糕'
}, {
value: '选项2',
label: '双皮奶'
}, {
value: '选项3',
label: '蚵仔煎'
}, {
value: '选项4',
label: '龙须面'
}, {
value: '选项5',
label: '北京烤鸭'
}],
}
},
created() {
this.getList()
},
methods: {
/** 查询园区照片列表 */
getList() {
this.loading = true
this.picList = []
listPic(this.queryParams).then(response => {
this.picList = response.rows
this.total = response.total
this.loading = false
})
},
// 取消按钮
cancel() {
this.open = false
this.reset()
},
// 表单重置
reset() {
this.form = {
params: {},
id: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
delFlag: null,
picName: null,
picUrl: null,
seqencing: null,
isShow: 0
}
this.imageUrl = ''
this.resetForm('form')
},
/** 搜索按钮操作 */
handleQuery() {
this.throttle(() => {
this.queryParams.pageNum = 1
this.getList()
})
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm('queryForm')
this.handleQuery()
},
// 多选框选中数据
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset()
this.open = true
this.title = '新增社团成员'
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset()
const ids = row.id || this.ids
getPic(ids).then(response => {
this.form = response.data
this.imageUrl = this.pev + this.form.picUrl
this.open = true
this.title = '修改社团成员信息'
})
},
/** 提交按钮 */
submitForm() {
this.$refs['form'].validate(valid => {
if (valid) {
this.$modal.loading('正在上传数据,请稍等...')
if (this.form.id != null) {
updatePic({
...this.form
})
.then(response => {
this.$modal.closeLoading()
this.$modal.msgSuccess('修改成功')
this.open = false
this.getList()
})
.catch(error => {
this.$modal.closeLoading()
})
} else {
addPic({
...this.form,
isShow: '0'
})
.then(response => {
this.$modal.closeLoading()
this.$modal.msgSuccess('新增成功')
this.open = false
this.getList()
})
.catch(error => {
this.$modal.closeLoading()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids
if (ids) {
this.$modal
.confirm(`是否确认删除选中的${Object.hasOwnProperty.call(ids, 'length') ? ids.length : 1}条数据?`)
.then(() => {
this.$modal.loading('正在处理数据,请稍等...')
return delPic(ids)
})
.then(() => {
this.$modal.closeLoading()
this.getList()
this.$modal.msgSuccess('删除成功')
})
.catch(() => {
this.$modal.closeLoading()
})
}
},
}
}
</script>
<style scoped>
.avatar,
.avatar-uploader,
.el-icon-plus {
width: 650px;
}
</style>
<template>
<div>
<el-form style="margin-top: 20px;margin-left: 20px;" :inline="true" :model="queryForm" class="demo-form-inline">
<el-form-item label="级部:">
<el-input v-model="queryForm.level" placeholder="请输入级部"></el-input>
</el-form-item>
<el-form-item label="姓名:">
<el-input v-model="queryForm.name" placeholder="请输入姓名"></el-input>
</el-form-item>
<el-form-item label="进度:">
<el-select v-model="queryForm.region" placeholder="请选择进度">
<el-option label="区域一" value="shanghai"></el-option>
<el-option label="区域二" value="beijing"></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button size="mini" icon="el-icon-search" type="primary" @click="handleQuery">搜索</el-button>
<el-button size="mini" icon="el-icon-refresh" @click="resetQuery">重置</el-button>
<el-button size="mini" icon="el-icon-plus" :disabled="status == '已结束' ? true:false" type="success" @click="handleAdd">新增</el-button>
</el-form-item>
</el-form>
<el-table style="margin-top: 20px;" border :data="tableData">
<el-table-column type="index" label="序号" width="55" align="center"/>
<el-table-column label="学年学期" align="center" prop="schoolYear" min-width="200"/>
<el-table-column label="级部" align="center" prop="level" min-width="150"/>
<el-table-column label="姓名" align="center" min-width="150" prop="name"/>
<el-table-column label="身份证号" align="center" min-width="200" prop="IDNum"/>
<el-table-column label="进度" align="center" min-width="150" prop="schedule"/>
<el-table-column fixed="right" label="操作" align="center">
<template slot-scope="scope">
<el-button
:disabled="status == '已结束' ? true:false"
size="mini"
type="text"
@click="handleDelete(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryForm.pageNum"
:limit.sync="queryForm.pageSize"
@pagination="getList"
/>
<!--弹窗-->
<el-dialog
title='新增接收人'
:visible.sync="dialogVisible"
width="60%">
<el-table
ref="multipleTable"
:data="dialogTableData"
tooltip-effect="dark"
@selection-change="handleSelectionChange">
<el-table-column
align="center"
type="selection">
</el-table-column>
<el-table-column
align="center"
label="级部"
prop="level">
</el-table-column>
<el-table-column
align="center"
prop="name"
label="姓名">
</el-table-column>
<el-table-column
align="center"
prop="ID"
label="身份证号">
</el-table-column>
</el-table>
<span style="display: flex;justify-content: center" slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="confirmDialog">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
export default {
name: "dataReceiver",
data() {
return {
// 遮罩层
loading: true,
// 总条数
total: 0,
queryForm: {
level: '',
name: '',
region: ''
},
tableData: [{
schoolYear: '2022学年上学期',
level: '2022级部',
name: '张三',
IDNum: '121212121212121212',
schedule: '未填写'
}],
dialogVisible: false,
form: {},
status : this.$route.query.status,
dialogTableData:[{
level:'2022',
name:'李四',
ID:'12121212121212'
}]
}
},
mounted() {
console.log('id', this.$route.query.id)
console.log('status',this.status)
},
methods: {
/** 查询信息列表 */
getList() {
this.loading = true;
//接口
// listUser(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
// this.userList = response.rows;
// this.total = response.total;
// this.loading = false;
// }
},
// 搜索按钮
handleQuery() {
this.queryParams.pageNum = 1;
this.getList()
},
// 重置按钮
resetQuery() {
this.queryForm = {
pageNum: 1,
pageSize: 10,
level: '',
name: '',
region: ''
}
this.handleQuery()
},
// 新增按钮
handleAdd() {
this.dialogVisible = true
},
//弹窗确定按钮
confirmDialog() {
this.dialogVisible = false
},
//多选按钮
handleSelectionChange(select){
console.log('select',select)
},
// 删除按钮
handleDelete(row) {
//判断,如果进度是未填写可以直接删除不需要提醒
//如果是其他状态需要提示相应的状态
this.$confirm('此操作将永久删除该文件, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.$message({
type: 'success',
message: '删除成功!'
});
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
});
});
}
}
}
</script>
<style scoped>
</style>
<template>
<div style="margin-top: 20px;margin-left: 20px">
<el-form ref="queryForm" :inline="true" :model="queryForm" class="demo-form-inline">
<el-form-item label="任务名称:">
<el-input v-model="queryForm.user" placeholder="请输入任务名称"></el-input>
</el-form-item>
<el-form-item label="任务状态:">
<el-select v-model="queryForm.region" placeholder="请选择任务状态">
<el-option label="区域一" value="shanghai"></el-option>
<el-option label="区域二" value="beijing"></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button icon="el-icon-search" size="mini" type="primary" @click="handleQuery">搜索</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
<el-button icon="el-icon-plus" size="mini" type="success" @click="handleAdd">新增</el-button>
<!-- <el-button size="small" type="warning">修改</el-button>-->
<!-- <el-button size="small" type="primary">查看</el-button>-->
<el-button icon="el-icon-delete" size="mini" type="danger" @click="handleDeleteMuti">删除</el-button>
</el-form-item>
</el-form>
<div>
</div>
<el-table style="margin-top: 20px;" border :data="tableData" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/>
<el-table-column type="index" label="序号" width="55" align="center"/>
<el-table-column label="范围" align="center" prop="range" min-width="100"/>
<el-table-column label="任务名称" align="center" prop="name" min-width="220"/>
<el-table-column label="开始时间" align="center" min-width="100" prop="statrtTime"/>
<el-table-column label="结束时间" align="center" min-width="100" prop="endTime"/>
<el-table-column label="教师人数" align="center" min-width="100" prop="teacherNum"/>
<el-table-column label="填写人数" align="center" min-width="100" prop="fillNum"/>
<el-table-column label="级部确认" align="center" min-width="100" prop="levelConfirm"/>
<el-table-column label="状态" align="center" min-width="100" prop="status"/>
<el-table-column fixed="right" label="操作" align="center" min-width="280">
<template slot-scope="scope">
<div>
<el-button
type="text"
size="mini"
@click="handleEdit(scope.row)">修改
</el-button>
<el-button
size="mini"
type="text"
@click="handleDelete(scope.row)">删除
</el-button>
<el-button
size="mini"
type="text"
@click="handlePublish(scope.row)">发布
</el-button>
</div>
<div>
<el-button
size="mini"
type="text"
@click="dataReceiver(scope.row)">数据接收人员
</el-button>
<el-button
size="mini"
type="text"
@click="dataMaintenance(scope.row)">数据维护
</el-button>
<el-button
size="mini"
type="text"
@click="handleExport(scope.row)">导出
</el-button>
<el-button
size="mini"
type="text"
@click="handleRevocation(scope.row)">撤回
</el-button>
<el-button
size="mini"
type="text"
@click="handleFinish(scope.row)">结束
</el-button>
</div>
<div>
<el-button
size="mini"
type="text"
@click="dataReceiver(scope.row)">数据接收人员
</el-button>
<el-button
size="mini"
type="text"
@click="dataMaintenance(scope.row)">数据维护
</el-button>
<el-button
size="mini"
type="text"
@click="handleExport(scope.row)">导出
</el-button>
</div>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryForm.pageNum"
:limit.sync="queryForm.pageSize"
@pagination="getList"
/>
<!--弹窗-->
<el-dialog
:title=title
:visible.sync="dialogVisible"
width="30%">
<el-form ref="form" :model="form" label-width="120px">
<el-form-item label="任务名称:">
<el-input style="width: 220px;" v-model="form.name"></el-input>
</el-form-item>
<el-form-item label="范围:">
<el-input style="width: 220px;" readonly v-model="form.range"></el-input>
</el-form-item>
<el-form-item label="开始时间:">
<el-date-picker
v-model="form.startTime"
type="date"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
<el-form-item label="结束时间:">
<el-date-picker
v-model="form.endTime"
type="date"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-form>
<span style="display: flex;justify-content: center" slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="confirmDialog">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
export default {
name: "teacherElectronicRecord",
data() {
return {
// 遮罩层
loading: true,
// 总条数
total: 0,
queryForm: {
pageNum: 1,
pageSize: 10,
user: '',
region: ''
},
tableData: [{
id: 1,
range: '全体教师',
name: '2022学年上学期教师档案填写',
statrtTime: '2023/08/30',
endTime: '2023/08/30',
teacherNum: '124',
fillNum: '50',
levelConfirm: '40',
status: '未发布',
}],
// 选中数组
ids: [],
// 非单个禁用
single: true,
// 非多个禁用
multiple: true,
// 弹窗
dialogVisible: false,
// 弹窗标题
title: '',
form: {},
}
},
created() {
this.getList()
},
methods: {
/** 查询信息列表 */
getList() {
this.loading = true;
//接口
// listUser(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
// this.userList = response.rows;
// this.total = response.total;
// this.loading = false;
// }
},
//搜索按钮
handleQuery() {
this.queryParams.pageNum = 1;
this.getList()
},
// 表单重置
reset() {
this.form = {
name: '',
range: '全体教师',
startTime: '',
endTime: ''
};
this.resetForm("form");
},
//重置按钮
resetQuery() {
this.queryForm.user = '',
this.queryForm.region = '',
this.handleQuery();
},
// 多选框选中数据
handleSelectionChange(selection) {
console.log('selection', selection)
this.ids = selection.map(item => item.id)
console.log('this.ids', this.ids)
this.single = selection.length !== 1
this.multiple = !selection.length
},
//新增按钮
handleAdd() {
this.reset()
this.form.name = '2023'
this.title = '新增任务'
this.dialogVisible = true
},
//弹窗确定按钮
confirmDialog() {
this.dialogVisible = false
},
//多选删除按钮
handleDeleteMuti() {
console.log('delete ids', this.ids)
// 接口
},
//修改按钮
handleEdit(row) {
this.title = '修改任务'
this.dialogVisible = true
},
// 删除按钮
handleDelete(row) {
},
// 发布按钮
handlePublish(row) {
},
// 数据接收人员按钮
dataReceiver(row) {
//传值状态,如果是已结束跳过去只能查看,已发布可以新增或者删除
console.log('row', row)
this.$router.push({
path: '/teachAffairAdministration/smartSchool/teachAffairAdministration/electronicRecord/dataReceiver',
query: {
id: row.id,
status:row.status
}
})
},
// 数据维护按钮
dataMaintenance(row) {
console.log('数据维护按钮row', row)
//传值状态,如果是已结束跳过去只能查看,已发布可以新增或者删除
this.$router.push({
path: '/teachAffairAdministration/smartSchool/teachAffairAdministration/electronicRecord/dataMaintenance',
query: {
id: row.id,
status:row.status
}
})
},
// 导出按钮
handleExport(row) {
},
// 撤回按钮
handleRevocation(row) {
},
// 结束按钮
handleFinish(row) {
}
}
}
</script>
<style scoped>
</style>
...@@ -19,6 +19,7 @@ import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition; ...@@ -19,6 +19,7 @@ import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabCompetitionService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabCompetitionService;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.core.page.TableDataInfo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabCompetitionVo;
/** /**
* 实验室竞赛Controller * 实验室竞赛Controller
...@@ -37,10 +38,10 @@ public class SchoolLabCompetitionController extends BaseController ...@@ -37,10 +38,10 @@ public class SchoolLabCompetitionController extends BaseController
* 查询实验室竞赛列表 * 查询实验室竞赛列表
*/ */
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(SchoolLabCompetition schoolLabCompetition) public TableDataInfo list(SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
startPage(); startPage();
List<SchoolLabCompetition> list = schoolLabCompetitionService.selectSchoolLabCompetitionList(schoolLabCompetition); List<SchoolLabCompetitionVo> list = schoolLabCompetitionService.selectSchoolLabCompetitionList(schoolLabCompetitionVo);
return getDataTable(list); return getDataTable(list);
} }
...@@ -49,10 +50,10 @@ public class SchoolLabCompetitionController extends BaseController ...@@ -49,10 +50,10 @@ public class SchoolLabCompetitionController extends BaseController
*/ */
@Log(title = "实验室竞赛", businessType = BusinessType.EXPORT) @Log(title = "实验室竞赛", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, SchoolLabCompetition schoolLabCompetition) public void export(HttpServletResponse response, SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
List<SchoolLabCompetition> list = schoolLabCompetitionService.selectSchoolLabCompetitionList(schoolLabCompetition); List<SchoolLabCompetitionVo> list = schoolLabCompetitionService.selectSchoolLabCompetitionList(schoolLabCompetitionVo);
ExcelUtil<SchoolLabCompetition> util = new ExcelUtil<SchoolLabCompetition>(SchoolLabCompetition.class); ExcelUtil<SchoolLabCompetitionVo> util = new ExcelUtil<SchoolLabCompetitionVo>(SchoolLabCompetitionVo.class);
util.exportExcel(response, list, "实验室竞赛数据"); util.exportExcel(response, list, "实验室竞赛数据");
} }
...@@ -70,9 +71,9 @@ public class SchoolLabCompetitionController extends BaseController ...@@ -70,9 +71,9 @@ public class SchoolLabCompetitionController extends BaseController
*/ */
@Log(title = "实验室竞赛", businessType = BusinessType.INSERT) @Log(title = "实验室竞赛", businessType = BusinessType.INSERT)
@PostMapping("/add") @PostMapping("/add")
public AjaxResult add(@RequestBody SchoolLabCompetition schoolLabCompetition) public AjaxResult add(@RequestBody SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
return toAjax(schoolLabCompetitionService.insertSchoolLabCompetition(schoolLabCompetition)); return toAjax(schoolLabCompetitionService.insertSchoolLabCompetition(schoolLabCompetitionVo));
} }
/** /**
...@@ -80,9 +81,9 @@ public class SchoolLabCompetitionController extends BaseController ...@@ -80,9 +81,9 @@ public class SchoolLabCompetitionController extends BaseController
*/ */
@Log(title = "实验室竞赛", businessType = BusinessType.UPDATE) @Log(title = "实验室竞赛", businessType = BusinessType.UPDATE)
@PutMapping("/edit") @PutMapping("/edit")
public AjaxResult edit(@RequestBody SchoolLabCompetition schoolLabCompetition) public AjaxResult edit(@RequestBody SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
return toAjax(schoolLabCompetitionService.updateSchoolLabCompetition(schoolLabCompetition)); return toAjax(schoolLabCompetitionService.updateSchoolLabCompetition(schoolLabCompetitionVo));
} }
/** /**
......
...@@ -10,6 +10,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -10,6 +10,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.util.List; import java.util.List;
...@@ -32,10 +33,10 @@ public class SchoolLabController extends BaseController ...@@ -32,10 +33,10 @@ public class SchoolLabController extends BaseController
* 查询实验室列表 * 查询实验室列表
*/ */
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(SchoolLab schoolLab) public TableDataInfo list(SchoolLabVo schoolLabVo)
{ {
startPage(); startPage();
List<SchoolLab> list = schoolLabService.selectSchoolLabList(schoolLab); List<SchoolLabVo> list = schoolLabService.selectSchoolLabList(schoolLabVo);
return getDataTable(list); return getDataTable(list);
} }
...@@ -44,10 +45,10 @@ public class SchoolLabController extends BaseController ...@@ -44,10 +45,10 @@ public class SchoolLabController extends BaseController
*/ */
@Log(title = "实验室", businessType = BusinessType.EXPORT) @Log(title = "实验室", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, SchoolLab schoolLab) public void export(HttpServletResponse response, SchoolLabVo schoolLabVo)
{ {
List<SchoolLab> list = schoolLabService.selectSchoolLabList(schoolLab); List<SchoolLabVo> list = schoolLabService.selectSchoolLabList(schoolLabVo);
ExcelUtil<SchoolLab> util = new ExcelUtil<SchoolLab>(SchoolLab.class); ExcelUtil<SchoolLabVo> util = new ExcelUtil<SchoolLabVo>(SchoolLabVo.class);
util.exportExcel(response, list, "实验室数据"); util.exportExcel(response, list, "实验室数据");
} }
...@@ -100,7 +101,7 @@ public class SchoolLabController extends BaseController ...@@ -100,7 +101,7 @@ public class SchoolLabController extends BaseController
} }
/** /**
* 获取学科下拉框 * 实验室管理员-获取学科下拉框
* @return * @return
*/ */
@GetMapping("/getSub") @GetMapping("/getSub")
......
...@@ -2,6 +2,10 @@ package yangtz.cs.liu.campus.controller.schoolLab; ...@@ -2,6 +2,10 @@ package yangtz.cs.liu.campus.controller.schoolLab;
import java.util.List; import java.util.List;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.utils.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
...@@ -15,10 +19,13 @@ import com.ruoyi.common.annotation.Log; ...@@ -15,10 +19,13 @@ import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.enums.BusinessType; import com.ruoyi.common.enums.BusinessType;
import yangtz.cs.liu.campus.domain.accessory.SchoolAccessory;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
import yangtz.cs.liu.campus.service.accessory.IAccessoryService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.core.page.TableDataInfo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
/** /**
* 教师实验室申请Controller * 教师实验室申请Controller
...@@ -32,16 +39,59 @@ public class SchoolTeacherLabApplyController extends BaseController ...@@ -32,16 +39,59 @@ public class SchoolTeacherLabApplyController extends BaseController
{ {
@Autowired @Autowired
private ISchoolTeacherLabApplyService schoolTeacherLabApplyService; private ISchoolTeacherLabApplyService schoolTeacherLabApplyService;
@Autowired
private IAccessoryService accessoryService;
/** /**
* 查询教师实验室申请列表 * 查询教师实验室申请列表
*/ */
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(SchoolTeacherLabApply schoolTeacherLabApply) public TableDataInfo list(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
//获取登录用户
SysUser user = SecurityUtils.getLoginUser().getUser();
if (user.isAdmin()){
startPage();
List<SchoolTeacherLabApplyVo> schoolTeacherLabApplyVos = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo);
for (SchoolTeacherLabApplyVo teacherLabApplyVo : schoolTeacherLabApplyVos) {
LambdaQueryWrapper<SchoolAccessory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolAccessory::getBusinessId,teacherLabApplyVo.getId())
.eq(SchoolAccessory::getAccessoryType,"教师实验室附件");
List<SchoolAccessory> schoolAccessories = accessoryService.list(wrapper);
if (schoolAccessories.size() > 0){
teacherLabApplyVo.setSchoolAccessoryList(schoolAccessories);
}
String semester = "";
if (teacherLabApplyVo.getSemester().equals("1")){
semester = "上学期";
}else {
semester = "下学期";
}
teacherLabApplyVo.setSchoolYearSemester(teacherLabApplyVo.getSchoolYear() + semester);
}
return getDataTable(schoolTeacherLabApplyVos);
}
//普通教师通道
schoolTeacherLabApplyVo.setApplyId(user.getUserId());
startPage(); startPage();
List<SchoolTeacherLabApply> list = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApply); List<SchoolTeacherLabApplyVo> schoolTeacherLabApplyVos = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo);
return getDataTable(list); for (SchoolTeacherLabApplyVo teacherLabApplyVo : schoolTeacherLabApplyVos) {
LambdaQueryWrapper<SchoolAccessory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolAccessory::getBusinessId,teacherLabApplyVo.getId())
.eq(SchoolAccessory::getAccessoryType,"教师实验室附件");
List<SchoolAccessory> schoolAccessories = accessoryService.list(wrapper);
if (schoolAccessories.size() > 0){
teacherLabApplyVo.setSchoolAccessoryList(schoolAccessories);
}
String semester = "";
if (teacherLabApplyVo.getSemester().equals("1")){
semester = "上学期";
}else {
semester = "下学期";
}
teacherLabApplyVo.setSchoolYearSemester(teacherLabApplyVo.getSchoolYear() + semester);
}
return getDataTable(schoolTeacherLabApplyVos);
} }
/** /**
...@@ -49,10 +99,10 @@ public class SchoolTeacherLabApplyController extends BaseController ...@@ -49,10 +99,10 @@ public class SchoolTeacherLabApplyController extends BaseController
*/ */
@Log(title = "教师实验室申请", businessType = BusinessType.EXPORT) @Log(title = "教师实验室申请", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, SchoolTeacherLabApply schoolTeacherLabApply) public void export(HttpServletResponse response, SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
List<SchoolTeacherLabApply> list = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApply); List<SchoolTeacherLabApplyVo> list = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo);
ExcelUtil<SchoolTeacherLabApply> util = new ExcelUtil<SchoolTeacherLabApply>(SchoolTeacherLabApply.class); ExcelUtil<SchoolTeacherLabApplyVo> util = new ExcelUtil<SchoolTeacherLabApplyVo>(SchoolTeacherLabApplyVo.class);
util.exportExcel(response, list, "教师实验室申请数据"); util.exportExcel(response, list, "教师实验室申请数据");
} }
...@@ -62,7 +112,22 @@ public class SchoolTeacherLabApplyController extends BaseController ...@@ -62,7 +112,22 @@ public class SchoolTeacherLabApplyController extends BaseController
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) public AjaxResult getInfo(@PathVariable("id") Long id)
{ {
return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyById(id)); SchoolTeacherLabApplyVo schoolTeacherLabApplyVo = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyById(id);
LambdaQueryWrapper<SchoolAccessory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolAccessory::getBusinessId,id)
.eq(SchoolAccessory::getAccessoryType,"教师实验室附件");
List<SchoolAccessory> schoolAccessories = accessoryService.list(wrapper);
if (schoolAccessories.size() > 0){
schoolTeacherLabApplyVo.setSchoolAccessoryList(schoolAccessories);
}
String semester = "";
if (schoolTeacherLabApplyVo.getSemester().equals("1")){
semester = "上学期";
}else {
semester = "下学期";
}
schoolTeacherLabApplyVo.setSchoolYearSemester(schoolTeacherLabApplyVo.getSchoolYear() + semester);
return AjaxResult.success(schoolTeacherLabApplyVo);
} }
/** /**
...@@ -70,9 +135,9 @@ public class SchoolTeacherLabApplyController extends BaseController ...@@ -70,9 +135,9 @@ public class SchoolTeacherLabApplyController extends BaseController
*/ */
@Log(title = "教师实验室申请", businessType = BusinessType.INSERT) @Log(title = "教师实验室申请", businessType = BusinessType.INSERT)
@PostMapping("/add") @PostMapping("/add")
public AjaxResult add(@RequestBody SchoolTeacherLabApply schoolTeacherLabApply) public AjaxResult add(@RequestBody SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
return toAjax(schoolTeacherLabApplyService.insertSchoolTeacherLabApply(schoolTeacherLabApply)); return toAjax(schoolTeacherLabApplyService.insertSchoolTeacherLabApplyVo(schoolTeacherLabApplyVo));
} }
/** /**
...@@ -80,9 +145,9 @@ public class SchoolTeacherLabApplyController extends BaseController ...@@ -80,9 +145,9 @@ public class SchoolTeacherLabApplyController extends BaseController
*/ */
@Log(title = "教师实验室申请", businessType = BusinessType.UPDATE) @Log(title = "教师实验室申请", businessType = BusinessType.UPDATE)
@PutMapping("/edit") @PutMapping("/edit")
public AjaxResult edit(@RequestBody SchoolTeacherLabApply schoolTeacherLabApply) public AjaxResult edit(@RequestBody SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
return toAjax(schoolTeacherLabApplyService.updateSchoolTeacherLabApply(schoolTeacherLabApply)); return toAjax(schoolTeacherLabApplyService.updateSchoolTeacherLabApplyVo(schoolTeacherLabApplyVo));
} }
/** /**
...@@ -94,4 +159,47 @@ public class SchoolTeacherLabApplyController extends BaseController ...@@ -94,4 +159,47 @@ public class SchoolTeacherLabApplyController extends BaseController
{ {
return toAjax(schoolTeacherLabApplyService.deleteSchoolTeacherLabApplyByIds(ids)); return toAjax(schoolTeacherLabApplyService.deleteSchoolTeacherLabApplyByIds(ids));
} }
/**
* 获取实验室使用状态
* @return
*/
@GetMapping("/getTeacherLab")
public AjaxResult getTeacherLab(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo){
return AjaxResult.success(schoolTeacherLabApplyService.getTeacherLab(schoolTeacherLabApplyVo));
}
/**
* 获取班级
*/
@GetMapping("/getTeacherClass")
public AjaxResult getTeacherClass(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo){
return AjaxResult.success(schoolTeacherLabApplyService.getTeacherClass(schoolTeacherLabApplyVo));
}
/**
* 上传附件
*/
@PutMapping("/attachment")
public AjaxResult attachment(@RequestBody SchoolTeacherLabApplyVo schoolTeacherLabApplyVo){
return toAjax(schoolTeacherLabApplyService.updateTeacherLab(schoolTeacherLabApplyVo));
}
/**
* 实验室管理-教师申请列表
*/
@GetMapping("/getTeacherLabApplyList")
public TableDataInfo getTeacherLabApplyList(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo){
startPage();
List<SchoolTeacherLabApplyVo> list = schoolTeacherLabApplyService.getTeacherLabApplyList(schoolTeacherLabApplyVo);
return getDataTable(list);
}
/**
* 实验室管理-教师申请审批确认
*/
@PutMapping("/updateState")
public AjaxResult updateState(@RequestBody SchoolTeacherLabApply schoolTeacherLabApply){
return toAjax(schoolTeacherLabApplyService.updateState(schoolTeacherLabApply));
}
} }
package yangtz.cs.liu.campus.domain.accessory; package yangtz.cs.liu.campus.domain.accessory;
import com.core.domain.OurBaseEntity;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle; import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
import java.util.Date;
/** /**
* 附件对象 accessory * 附件对象 accessory
* *
* @author ruoyi * @author ruoyi
* @date 2023-07-24 * @date 2023-07-24
*/ */
public class SchoolAccessory @Data
public class SchoolAccessory extends OurBaseEntity
{ {
/** 附件主键id */
private Long id;
/** 业务id */ /** 业务id */
@Excel(name = "业务id") @Excel(name = "业务id")
private Long businessId; private Long businessId;
...@@ -35,71 +37,4 @@ public class SchoolAccessory ...@@ -35,71 +37,4 @@ public class SchoolAccessory
/** 附件名称 */ /** 附件名称 */
@Excel(name = "附件名称") @Excel(name = "附件名称")
private String accessoryName; private String accessoryName;
public void setId(Long id)
{
this.id = id;
}
public Long getId()
{
return id;
}
public void setBusinessId(Long businessId)
{
this.businessId = businessId;
}
public Long getBusinessId()
{
return businessId;
}
public void setModuleName(String moduleName)
{
this.moduleName = moduleName;
}
public String getModuleName()
{
return moduleName;
}
public void setAccessoryType(String accessoryType)
{
this.accessoryType = accessoryType;
}
public String getAccessoryType()
{
return accessoryType;
}
public void setAccessoryUrl(String accessoryUrl)
{
this.accessoryUrl = accessoryUrl;
}
public String getAccessoryUrl()
{
return accessoryUrl;
}
public void setAccessoryName(String accessoryName)
{
this.accessoryName = accessoryName;
}
public String getAccessoryName()
{
return accessoryName;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("businessId", getBusinessId())
.append("moduleName", getModuleName())
.append("accessoryType", getAccessoryType())
.append("accessoryUrl", getAccessoryUrl())
.append("accessoryName", getAccessoryName())
.toString();
}
} }
...@@ -19,17 +19,18 @@ public class SchoolLabClassYear extends OurBaseEntity ...@@ -19,17 +19,18 @@ public class SchoolLabClassYear extends OurBaseEntity
{ {
/** 实验计划id */ /** 实验计划id */
private String experimentPlanId; private Long experimentPlanId;
/** 实验名称 */
private String experimentName;
/** 级部id */
private Long gradeId;
/** 级部 */ /** 级部 */
@Excel(name = "级部") @Excel(name = "级部")
private String grade; private String grade;
/**
* 级部id
*/
private Integer gradeId;
/** 学年 */ /** 学年 */
@Excel(name = "学年") @Excel(name = "学年")
private String schoolYear; private String schoolYear;
......
...@@ -24,6 +24,9 @@ public class SchoolLabClassYearRelation ...@@ -24,6 +24,9 @@ public class SchoolLabClassYearRelation
/** 实验室id */ /** 实验室id */
private Long labId; private Long labId;
/** 实验室名称 */
private String labName;
/** 删除状态 */ /** 删除状态 */
private String delFlag; private String delFlag;
} }
...@@ -37,9 +37,13 @@ public class SchoolTeacherExperimentApply extends OurBaseEntity ...@@ -37,9 +37,13 @@ public class SchoolTeacherExperimentApply extends OurBaseEntity
@Excel(name = "学期") @Excel(name = "学期")
private String semester; private String semester;
/** 规划时间 */ /** 规划开始时间 */
@Excel(name = "规划时间") @Excel(name = "规划开始时间")
private String plannedTime; private String plannedStartTime;
/** 规划结束时间 */
@Excel(name = "规划结束时间")
private String plannedEndTime;
/** 实验名称 */ /** 实验名称 */
@Excel(name = "实验名称") @Excel(name = "实验名称")
...@@ -53,14 +57,6 @@ public class SchoolTeacherExperimentApply extends OurBaseEntity ...@@ -53,14 +57,6 @@ public class SchoolTeacherExperimentApply extends OurBaseEntity
@Excel(name = "实验用品") @Excel(name = "实验用品")
private String experimentUseGoods; private String experimentUseGoods;
/** 实验室id */
@Excel(name = "实验室id")
private String labId;
/** 实验室名称 */
@Excel(name = "实验室名称")
private String labName;
/** 申报状态(0未申报,1已申报,2已阅读,3已分配) */ /** 申报状态(0未申报,1已申报,2已阅读,3已分配) */
@Excel(name = "申报状态", readConverterExp = "0=未申报,1=已申报,2=已阅读,3=已分配") @Excel(name = "申报状态", readConverterExp = "0=未申报,1=已申报,2=已阅读,3=已分配")
private String declareState; private String declareState;
......
package yangtz.cs.liu.campus.domain.schoolLab;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
@Data
public class SchoolTeacherExperimentApplyLabs {
/** 主键id */
@TableId(value = "id", type = IdType.AUTO)
private Long id;
/** 教师个人实验申请主键id */
private Long teacherExperimentApplyId;
/** 实验室id */
private Long labId;
/** 实验室名称 */
private String labName;
/** 删除状态 */
private String delFlag;
}
...@@ -25,10 +25,19 @@ public class SchoolTeacherLabApply extends OurBaseEntity ...@@ -25,10 +25,19 @@ public class SchoolTeacherLabApply extends OurBaseEntity
@Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验") @Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验")
private String experimentClassify; private String experimentClassify;
/** 实验计划id */
private Long experimentPlanId;
/** 实验名称 */
private String experimentName;
/** 学科(1物理,2化学,3生物) */ /** 学科(1物理,2化学,3生物) */
@Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物") @Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物")
private String sub; private String sub;
/** 级部id */
private Long gradeId;
/** 级部 */ /** 级部 */
@Excel(name = "级部") @Excel(name = "级部")
private String grade; private String grade;
...@@ -87,13 +96,6 @@ public class SchoolTeacherLabApply extends OurBaseEntity ...@@ -87,13 +96,6 @@ public class SchoolTeacherLabApply extends OurBaseEntity
@Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd") @Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date applyTime; private Date applyTime;
/** /** 实验室是否使用完成 (0未完成,1完成) */
* 实验室是否使用完成 (0未完成,1完成)
*/
private String state; private String state;
/**
* 备注
*/
private String remark;
} }
...@@ -32,4 +32,7 @@ public class SchoolGradeMentor extends OurBaseEntity { ...@@ -32,4 +32,7 @@ public class SchoolGradeMentor extends OurBaseEntity {
/** 职务 */ /** 职务 */
@NotBlank(message = "职务不能为空") @NotBlank(message = "职务不能为空")
private String teacherPost; private String teacherPost;
/** 学科组(1物理学科组,2化学学科组,3生物学科组) */
private String subGroup;
} }
...@@ -37,13 +37,6 @@ public interface SchoolClassMapper extends BaseMapper<SchoolClass> { ...@@ -37,13 +37,6 @@ public interface SchoolClassMapper extends BaseMapper<SchoolClass> {
SchoolClass getUserClassByParent(Long studentId); SchoolClass getUserClassByParent(Long studentId);
/** /**
* 跟进classid获取班级名称
* @param studentId
* @return
*/
String getClassName(Long classId);
/**
* 微信公众号(老师查看班级) * 微信公众号(老师查看班级)
* *
* @param teacherId * @param teacherId
......
...@@ -37,10 +37,10 @@ public interface SchoolExperimentPlanMapper extends BaseMapper<SchoolExperimentP ...@@ -37,10 +37,10 @@ public interface SchoolExperimentPlanMapper extends BaseMapper<SchoolExperimentP
/** /**
* 新增实验计划 * 新增实验计划
* *
* @param schoolExperimentPlan 实验计划 * @param schoolExperimentPlanVo 实验计划
* @return 结果 * @return 结果
*/ */
public int insertSchoolExperimentPlan(SchoolExperimentPlan schoolExperimentPlan); public int insertSchoolExperimentPlan(SchoolExperimentPlanVo schoolExperimentPlanVo);
/** /**
* 修改实验计划 * 修改实验计划
...@@ -96,12 +96,26 @@ public interface SchoolExperimentPlanMapper extends BaseMapper<SchoolExperimentP ...@@ -96,12 +96,26 @@ public interface SchoolExperimentPlanMapper extends BaseMapper<SchoolExperimentP
* @param schoolYear * @param schoolYear
* @return * @return
*/ */
List<Map<String, String>> getGrade(@Param("schoolYear") int schoolYear,@Param("userId") Long userId); List<Map<String, Object>> getGrade(@Param("schoolYear") int schoolYear,@Param("userId") Long userId);
/** /**
* 根据级部查询对应班级 * 根据级部查询对应班级
* @param gradeId * @param gradeId
* @return * @return
*/ */
List<Map<String, String>> getSchoolClass(@Param("gradeId") Long gradeId); List<Map<String, Object>> getSchoolClass(@Param("gradeId") Long gradeId);
/**
* 实验室管理-级部实验计划查看列表
* @param schoolExperimentPlanVo
* @return
*/
List<SchoolExperimentPlanVo> getExperimentList(SchoolExperimentPlanVo schoolExperimentPlanVo);
/**
* 领导-查看实验室完成情况列表
* @param schoolExperimentPlanVo
* @return
*/
List<Map<String, Object>> countExperiment(SchoolExperimentPlanVo schoolExperimentPlanVo);
} }
package yangtz.cs.liu.campus.mapper.schoolLab; package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import io.lettuce.core.dynamic.annotation.Param; import org.apache.ibatis.annotations.Param;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYearRelation; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYearRelation;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import java.util.List; import java.util.List;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
/** /**
* 年级实验室预约Mapper接口 * 年级实验室预约Mapper接口
...@@ -23,24 +24,15 @@ public interface SchoolLabClassYearMapper extends BaseMapper<SchoolLabClassYear> ...@@ -23,24 +24,15 @@ public interface SchoolLabClassYearMapper extends BaseMapper<SchoolLabClassYear>
* @param id 年级实验室预约主键 * @param id 年级实验室预约主键
* @return 年级实验室预约 * @return 年级实验室预约
*/ */
public SchoolLabClassYear selectSchoolLabClassYearById(Long id); public SchoolLabClassYearVo selectSchoolLabClassYearById(Long id);
/** /**
* 查询年级实验室预约列表 * 查询年级实验室预约列表
* *
* @param schoolLabClassYear 年级实验室预约 * @param schoolLabClassYearVo 年级实验室预约
* @return 年级实验室预约集合 * @return 年级实验室预约集合
*/ */
public List<SchoolLabClassYear> selectSchoolLabClassYearList(SchoolLabClassYear schoolLabClassYear); public List<SchoolLabClassYearVo> selectSchoolLabClassYearList(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* 获取年级 班级完成情况信息
* @param
* @return
*/
public List<ClassSituationVo> classSituation(ClassSituationVo classSituationVo);
public List<ClassSituationVo> getexperimentList(ClassSituationVo classSituationVo);
/** /**
* 新增年级实验室预约 * 新增年级实验室预约
...@@ -98,4 +90,41 @@ public interface SchoolLabClassYearMapper extends BaseMapper<SchoolLabClassYear> ...@@ -98,4 +90,41 @@ public interface SchoolLabClassYearMapper extends BaseMapper<SchoolLabClassYear>
* @return 结果 * @return 结果
*/ */
public int deleteSchoolLabClassYearRelationByLabClassYearId(Long id); public int deleteSchoolLabClassYearRelationByLabClassYearId(Long id);
/**
* 实验室管理-年级实验室预约列表
* @param schoolLabClassYearVo
* @return
*/
List<SchoolLabClassYearVo> getLabClassYear(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* 获取实验室id
* @param labClassYearIds
* @return
*/
List<Long> seletLabId(@Param("labClassYearIds") List<Long> labClassYearIds);
/**
* 实验室管理-年级实验室预约查看详情
* @param id
* @return
*/
SchoolLabClassYearVo getLabClassYearById(Long id);
/**
* 教师-实验室安排列表
* @param schoolLabClassYearVo
* @return
*/
List<SchoolLabClassYearVo> getTeacherLabList(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* 获取年级 班级完成情况信息
* @param
* @return
*/
public List<ClassSituationVo> classSituation(ClassSituationVo classSituationVo);
public List<ClassSituationVo> getexperimentList(ClassSituationVo classSituationVo);
} }
package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYearRelation;
public interface SchoolLabClassYearRelationMapper extends BaseMapper<SchoolLabClassYearRelation> {
}
package yangtz.cs.liu.campus.mapper.schoolLab; package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import yangtz.cs.liu.campus.domain.accessory.SchoolAccessory;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabCompetitionVo;
import java.util.List; import java.util.List;
...@@ -20,31 +22,31 @@ public interface SchoolLabCompetitionMapper extends BaseMapper<SchoolLabCompetit ...@@ -20,31 +22,31 @@ public interface SchoolLabCompetitionMapper extends BaseMapper<SchoolLabCompetit
* @param id 实验室竞赛主键 * @param id 实验室竞赛主键
* @return 实验室竞赛 * @return 实验室竞赛
*/ */
public SchoolLabCompetition selectSchoolLabCompetitionById(Long id); public SchoolLabCompetitionVo selectSchoolLabCompetitionById(Long id);
/** /**
* 查询实验室竞赛列表 * 查询实验室竞赛列表
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 实验室竞赛集合 * @return 实验室竞赛集合
*/ */
public List<SchoolLabCompetition> selectSchoolLabCompetitionList(SchoolLabCompetition schoolLabCompetition); public List<SchoolLabCompetitionVo> selectSchoolLabCompetitionList(SchoolLabCompetitionVo schoolLabCompetitionVo);
/** /**
* 新增实验室竞赛 * 新增实验室竞赛
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 结果 * @return 结果
*/ */
public int insertSchoolLabCompetition(SchoolLabCompetition schoolLabCompetition); public int insertSchoolLabCompetition(SchoolLabCompetitionVo schoolLabCompetitionVo);
/** /**
* 修改实验室竞赛 * 修改实验室竞赛
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 结果 * @return 结果
*/ */
public int updateSchoolLabCompetition(SchoolLabCompetition schoolLabCompetition); public int updateSchoolLabCompetition(SchoolLabCompetitionVo schoolLabCompetitionVo);
/** /**
* 删除实验室竞赛 * 删除实验室竞赛
...@@ -61,4 +63,25 @@ public interface SchoolLabCompetitionMapper extends BaseMapper<SchoolLabCompetit ...@@ -61,4 +63,25 @@ public interface SchoolLabCompetitionMapper extends BaseMapper<SchoolLabCompetit
* @return 结果 * @return 结果
*/ */
public int deleteSchoolLabCompetitionByIds(Long[] ids); public int deleteSchoolLabCompetitionByIds(Long[] ids);
/**
* 新增证书照片
* @param list
* @return
*/
int batchSchoolAccessory(List<SchoolAccessory> list);
/**
* 批量删除证书照片
* @param ids
* @return
*/
int deleteSchoolAccessoryByBusinessIds(Long[] ids);
/**
* 删除证书照片
* @param id
* @return
*/
int deleteSchoolAccessoryByBusinessId(Long id);
} }
...@@ -3,6 +3,7 @@ package yangtz.cs.liu.campus.mapper.schoolLab; ...@@ -3,6 +3,7 @@ package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -22,15 +23,15 @@ public interface SchoolLabMapper extends BaseMapper<SchoolLab> ...@@ -22,15 +23,15 @@ public interface SchoolLabMapper extends BaseMapper<SchoolLab>
* @param id 实验室主键 * @param id 实验室主键
* @return 实验室 * @return 实验室
*/ */
public SchoolLab selectSchoolLabById(Long id); public SchoolLabVo selectSchoolLabById(Long id);
/** /**
* 查询实验室列表 * 查询实验室列表
* *
* @param schoolLab 实验室 * @param schoolLabVo 实验室
* @return 实验室集合 * @return 实验室集合
*/ */
public List<SchoolLab> selectSchoolLabList(SchoolLab schoolLab); public List<SchoolLabVo> selectSchoolLabList(SchoolLabVo schoolLabVo);
/** /**
* 新增实验室 * 新增实验室
......
...@@ -2,6 +2,8 @@ package yangtz.cs.liu.campus.mapper.schoolLab; ...@@ -2,6 +2,8 @@ package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApplyLabs;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherExperimentApplyVo;
import java.util.List; import java.util.List;
...@@ -20,31 +22,31 @@ public interface SchoolTeacherExperimentApplyMapper extends BaseMapper<SchoolTea ...@@ -20,31 +22,31 @@ public interface SchoolTeacherExperimentApplyMapper extends BaseMapper<SchoolTea
* @param id 教师个人实验申请主键 * @param id 教师个人实验申请主键
* @return 教师个人实验申请 * @return 教师个人实验申请
*/ */
public SchoolTeacherExperimentApply selectSchoolTeacherExperimentApplyById(Long id); public SchoolTeacherExperimentApplyVo selectSchoolTeacherExperimentApplyById(Long id);
/** /**
* 查询教师个人实验申请列表 * 查询教师个人实验申请列表
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 教师个人实验申请集合 * @return 教师个人实验申请集合
*/ */
public List<SchoolTeacherExperimentApply> selectSchoolTeacherExperimentApplyList(SchoolTeacherExperimentApply schoolTeacherExperimentApply); public List<SchoolTeacherExperimentApplyVo> selectSchoolTeacherExperimentApplyList(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo);
/** /**
* 新增教师个人实验申请 * 新增教师个人实验申请
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 结果 * @return 结果
*/ */
public int insertSchoolTeacherExperimentApply(SchoolTeacherExperimentApply schoolTeacherExperimentApply); public int insertSchoolTeacherExperimentApply(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo);
/** /**
* 修改教师个人实验申请 * 修改教师个人实验申请
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 结果 * @return 结果
*/ */
public int updateSchoolTeacherExperimentApply(SchoolTeacherExperimentApply schoolTeacherExperimentApply); public int updateSchoolTeacherExperimentApply(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo);
/** /**
* 删除教师个人实验申请 * 删除教师个人实验申请
...@@ -61,4 +63,19 @@ public interface SchoolTeacherExperimentApplyMapper extends BaseMapper<SchoolTea ...@@ -61,4 +63,19 @@ public interface SchoolTeacherExperimentApplyMapper extends BaseMapper<SchoolTea
* @return 结果 * @return 结果
*/ */
public int deleteSchoolTeacherExperimentApplyByIds(Long[] ids); public int deleteSchoolTeacherExperimentApplyByIds(Long[] ids);
/**
* 批量新增教师个人实验申请实验室
*/
public int batchSchoolTeacherExperimentApplyLabs(List<SchoolTeacherExperimentApplyLabs> schoolTeacherExperimentApplyLabsList);
/**
* 批量删除教师个人实验申请实验室
*/
public int deleteSchoolTeacherExperimentApplyLabsIds(Long[] ids);
/**
* 删除教师个人实验申请实验室
*/
public int deleteSchoolTeacherExperimentApplyLabsId(Long id);
} }
package yangtz.cs.liu.campus.mapper.schoolLab; package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import java.util.Map; import yangtz.cs.liu.campus.domain.accessory.SchoolAccessory;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
import java.util.List; import java.util.List;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo; import java.util.Map;
/** /**
* 教师实验室申请Mapper接口 * 教师实验室申请Mapper接口
...@@ -21,38 +23,31 @@ public interface SchoolTeacherLabApplyMapper extends BaseMapper<SchoolTeacherLab ...@@ -21,38 +23,31 @@ public interface SchoolTeacherLabApplyMapper extends BaseMapper<SchoolTeacherLab
* @param id 教师实验室申请主键 * @param id 教师实验室申请主键
* @return 教师实验室申请 * @return 教师实验室申请
*/ */
public SchoolTeacherLabApply selectSchoolTeacherLabApplyById(Long id); public SchoolTeacherLabApplyVo selectSchoolTeacherLabApplyById(Long id);
/** /**
* 查询教师实验室申请列表 * 查询教师实验室申请列表
* *
* @param schoolTeacherLabApply 教师实验室申请 * @param schoolTeacherLabApplyVo 教师实验室申请
* @return 教师实验室申请集合 * @return 教师实验室申请集合
*/ */
public List<SchoolTeacherLabApply> selectSchoolTeacherLabApplyList(SchoolTeacherLabApply schoolTeacherLabApply); public List<SchoolTeacherLabApplyVo> selectSchoolTeacherLabApplyList(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/** /**
* 新增教师实验室申请 * 新增教师实验室申请
* *
* @param schoolTeacherLabApply 教师实验室申请 * @param schoolTeacherLabApplyVo 教师实验室申请
* @return 结果 * @return 结果
*/ */
public int insertSchoolTeacherLabApply(SchoolTeacherLabApply schoolTeacherLabApply); public int insertSchoolTeacherLabApply(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 计算本学年学期完成多少数量
*/
public Integer selectCompletedQuantity(ClassSituationVo classSituationVo);
public List<Map<String, String>> selectTeacherList(SchoolTeacherLabApply schoolTeacherLabApply);
/** /**
* 修改教师实验室申请 * 修改教师实验室申请
* *
* @param schoolTeacherLabApply 教师实验室申请 * @param schoolTeacherLabApplyVo 教师实验室申请
* @return 结果 * @return 结果
*/ */
public int updateSchoolTeacherLabApply(SchoolTeacherLabApply schoolTeacherLabApply); public int updateSchoolTeacherLabApply(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/** /**
* 删除教师实验室申请 * 删除教师实验室申请
...@@ -69,4 +64,74 @@ public interface SchoolTeacherLabApplyMapper extends BaseMapper<SchoolTeacherLab ...@@ -69,4 +64,74 @@ public interface SchoolTeacherLabApplyMapper extends BaseMapper<SchoolTeacherLab
* @return 结果 * @return 结果
*/ */
public int deleteSchoolTeacherLabApplyByIds(Long[] ids); public int deleteSchoolTeacherLabApplyByIds(Long[] ids);
/**
* 获取老师在班级
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> getTeacherClass(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 获取全部班级
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> getTeacherClassAll(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 新增附件信息
* @param list
* @return
*/
int batchSchoolAccessory(List<SchoolAccessory> list);
/**
* 删除附件信息
* @param id
* @return
*/
int deleteSchoolAccessoryByBusinessId(Long id);
/**
* 批量删除附件信息
* @param ids
* @return
*/
int deleteSchoolAccessoryByBusinessIds(Long[] ids);
/**
* 查看班级完成详情
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> getClassDetails(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 教师实验统计
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> getCountTeacher(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 级部-班级完成情况明细
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> gradeCountClass(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 级部-班级完成情况明细-查看班级完成情况详情
* @param schoolTeacherLabApplyVo
* @return
*/
List<SchoolTeacherLabApplyVo> getGradeClassDetails(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 计算本学年学期完成多少数量
*/
public Integer selectCompletedQuantity(ClassSituationVo classSituationVo);
public List<Map<String, String>> selectTeacherList(SchoolTeacherLabApply schoolTeacherLabApply);
} }
package yangtz.cs.liu.campus.mapper.schoolLab;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApplyLabs;
public interface SchoollTeacherExperimentApplyLabsMapper extends BaseMapper<SchoolTeacherExperimentApplyLabs> {
}
package yangtz.cs.liu.campus.service.impl.schoolLab;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYearRelation;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabClassYearRelationMapper;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearRelationService;
@Service
public class SchoolLabClassYearRelationServiceImpl extends ServiceImpl<SchoolLabClassYearRelationMapper, SchoolLabClassYearRelation> implements ISchoolLabClassYearRelationService {
}
package yangtz.cs.liu.campus.service.impl.schoolLab; package yangtz.cs.liu.campus.service.impl.schoolLab;
import java.util.ArrayList;
import java.util.List; import java.util.List;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import yangtz.cs.liu.campus.domain.accessory.SchoolAccessory;
import yangtz.cs.liu.campus.domain.award.Award;
import yangtz.cs.liu.campus.mapper.accessory.AccessoryMapper;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabCompetitionMapper; import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabCompetitionMapper;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabCompetitionService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabCompetitionService;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabCompetitionVo;
/** /**
* 实验室竞赛Service业务层处理 * 实验室竞赛Service业务层处理
...@@ -21,6 +30,8 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet ...@@ -21,6 +30,8 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet
{ {
@Autowired @Autowired
private SchoolLabCompetitionMapper schoolLabCompetitionMapper; private SchoolLabCompetitionMapper schoolLabCompetitionMapper;
@Autowired
private AccessoryMapper accessoryMapper;
/** /**
* 查询实验室竞赛 * 查询实验室竞赛
...@@ -29,47 +40,73 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet ...@@ -29,47 +40,73 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet
* @return 实验室竞赛 * @return 实验室竞赛
*/ */
@Override @Override
public SchoolLabCompetition selectSchoolLabCompetitionById(Long id) public SchoolLabCompetitionVo selectSchoolLabCompetitionById(Long id)
{ {
return schoolLabCompetitionMapper.selectSchoolLabCompetitionById(id); SchoolLabCompetitionVo schoolLabCompetitionVo = schoolLabCompetitionMapper.selectSchoolLabCompetitionById(id);
LambdaQueryWrapper<SchoolAccessory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolAccessory::getBusinessId,schoolLabCompetitionVo.getId())
.eq(SchoolAccessory::getAccessoryType,"证书照片");
List<SchoolAccessory> schoolAccessories = accessoryMapper.selectList(wrapper);
if (schoolAccessories.size() > 0){
schoolLabCompetitionVo.setSchoolAccessoryList(schoolAccessories);
}
return schoolLabCompetitionVo;
} }
/** /**
* 查询实验室竞赛列表 * 查询实验室竞赛列表
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 实验室竞赛 * @return 实验室竞赛
*/ */
@Override @Override
public List<SchoolLabCompetition> selectSchoolLabCompetitionList(SchoolLabCompetition schoolLabCompetition) public List<SchoolLabCompetitionVo> selectSchoolLabCompetitionList(SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
return schoolLabCompetitionMapper.selectSchoolLabCompetitionList(schoolLabCompetition); List<SchoolLabCompetitionVo> schoolLabCompetitionVos = schoolLabCompetitionMapper.selectSchoolLabCompetitionList(schoolLabCompetitionVo);
for (SchoolLabCompetitionVo labCompetitionVo : schoolLabCompetitionVos) {
LambdaQueryWrapper<SchoolAccessory> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SchoolAccessory::getBusinessId,labCompetitionVo.getId())
.eq(SchoolAccessory::getAccessoryType,"证书照片");
List<SchoolAccessory> schoolAccessories = accessoryMapper.selectList(wrapper);
if (schoolAccessories.size() > 0){
labCompetitionVo.setSchoolAccessoryList(schoolAccessories);
}
}
return schoolLabCompetitionVos;
} }
/** /**
* 新增实验室竞赛 * 新增实验室竞赛
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 结果 * @return 结果
*/ */
@Override @Override
public int insertSchoolLabCompetition(SchoolLabCompetition schoolLabCompetition) @Transactional
public int insertSchoolLabCompetition(SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
schoolLabCompetition.setCreateTime(DateUtils.getNowDate()); schoolLabCompetitionVo.setCreateBy(SecurityUtils.getLoginUser().getUser().getUserName());
return schoolLabCompetitionMapper.insertSchoolLabCompetition(schoolLabCompetition); schoolLabCompetitionVo.setCreateTime(DateUtils.getNowDate());
int rows = schoolLabCompetitionMapper.insertSchoolLabCompetition(schoolLabCompetitionVo);
insertSchoolAccessory(schoolLabCompetitionVo);
return rows;
} }
/** /**
* 修改实验室竞赛 * 修改实验室竞赛
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 结果 * @return 结果
*/ */
@Override @Override
public int updateSchoolLabCompetition(SchoolLabCompetition schoolLabCompetition) @Transactional
public int updateSchoolLabCompetition(SchoolLabCompetitionVo schoolLabCompetitionVo)
{ {
schoolLabCompetition.setUpdateTime(DateUtils.getNowDate()); schoolLabCompetitionVo.setUpdateBy(SecurityUtils.getLoginUser().getUser().getUserName());
return schoolLabCompetitionMapper.updateSchoolLabCompetition(schoolLabCompetition); schoolLabCompetitionVo.setUpdateTime(DateUtils.getNowDate());
schoolLabCompetitionMapper.deleteSchoolAccessoryByBusinessId(schoolLabCompetitionVo.getId());
insertSchoolAccessory(schoolLabCompetitionVo);
return schoolLabCompetitionMapper.updateSchoolLabCompetition(schoolLabCompetitionVo);
} }
/** /**
...@@ -79,8 +116,10 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet ...@@ -79,8 +116,10 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet
* @return 结果 * @return 结果
*/ */
@Override @Override
@Transactional
public int deleteSchoolLabCompetitionByIds(Long[] ids) public int deleteSchoolLabCompetitionByIds(Long[] ids)
{ {
schoolLabCompetitionMapper.deleteSchoolAccessoryByBusinessIds(ids);
return schoolLabCompetitionMapper.deleteSchoolLabCompetitionByIds(ids); return schoolLabCompetitionMapper.deleteSchoolLabCompetitionByIds(ids);
} }
...@@ -91,8 +130,37 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet ...@@ -91,8 +130,37 @@ public class SchoolLabCompetitionServiceImpl extends ServiceImpl<SchoolLabCompet
* @return 结果 * @return 结果
*/ */
@Override @Override
@Transactional
public int deleteSchoolLabCompetitionById(Long id) public int deleteSchoolLabCompetitionById(Long id)
{ {
schoolLabCompetitionMapper.deleteSchoolAccessoryByBusinessId(id);
return schoolLabCompetitionMapper.deleteSchoolLabCompetitionById(id); return schoolLabCompetitionMapper.deleteSchoolLabCompetitionById(id);
} }
/**
* 新增证书照片
* @param
*/
public void insertSchoolAccessory(SchoolLabCompetitionVo schoolLabCompetitionVo)
{
List<SchoolAccessory> schoolAccessoryList = schoolLabCompetitionVo.getSchoolAccessoryList();
Long id = schoolLabCompetitionVo.getId();
if (StringUtils.isNotNull(schoolAccessoryList))
{
List<SchoolAccessory> list = new ArrayList<SchoolAccessory>();
for (SchoolAccessory schoolAccessory : schoolAccessoryList)
{
schoolAccessory.setModuleName("实验室竞赛");
schoolAccessory.setAccessoryType("证书照片");
schoolAccessory.setBusinessId(id);
schoolAccessory.setCreateBy(SecurityUtils.getLoginUser().getUser().getUserName());
schoolAccessory.setCreateTime(DateUtils.getNowDate());
list.add(schoolAccessory);
}
if (list.size() > 0)
{
schoolLabCompetitionMapper.batchSchoolAccessory(list);
}
}
}
} }
...@@ -11,6 +11,7 @@ import org.springframework.stereotype.Service; ...@@ -11,6 +11,7 @@ import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabMapper; import yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabMapper;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabService;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
...@@ -36,7 +37,7 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab> ...@@ -36,7 +37,7 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab>
* @return 实验室 * @return 实验室
*/ */
@Override @Override
public SchoolLab selectSchoolLabById(Long id) public SchoolLabVo selectSchoolLabById(Long id)
{ {
return schoolLabMapper.selectSchoolLabById(id); return schoolLabMapper.selectSchoolLabById(id);
} }
...@@ -44,29 +45,44 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab> ...@@ -44,29 +45,44 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab>
/** /**
* 查询实验室列表 * 查询实验室列表
* *
* @param schoolLab 实验室 * @param schoolLabVo 实验室
* @return 实验室 * @return 实验室
*/ */
@Override @Override
public List<SchoolLab> selectSchoolLabList(SchoolLab schoolLab) public List<SchoolLabVo> selectSchoolLabList(SchoolLabVo schoolLabVo)
{ {
List<SchoolLab> list = new ArrayList<>();
List<SchoolLabVo> list = new ArrayList<>();
//获取当前登录用户 //获取当前登录用户
SysUser user = SecurityUtils.getLoginUser().getUser(); SysUser user = SecurityUtils.getLoginUser().getUser();
//获取用户角色集合 //获取用户角色集合
List<SysRole> roles = user.getRoles(); List<SysRole> roles = user.getRoles();
List<String> labSubs = new ArrayList<>();
if (user.isAdmin()){
return schoolLabMapper.selectSchoolLabList(schoolLabVo);
}
for (SysRole role : roles) { for (SysRole role : roles) {
if (role.getRoleKey().equals("admin")){ if (role.getRoleKey().equals("admin")){
return schoolLabMapper.selectSchoolLabList(schoolLab); return schoolLabMapper.selectSchoolLabList(schoolLabVo);
}else if (role.getRoleKey().equals("phy_lab_admin") || role.getRoleKey().equals("che_lab_admin") || role.getRoleKey().equals("bio_lab_admin")){ }
schoolLab.setInChargeId(user.getUserId()); switch (role.getRoleKey()){
return schoolLabMapper.selectSchoolLabList(schoolLab); case "phy_lab_admin":
labSubs.add("1");
break;
case "che_lab_admin":
labSubs.add("2");
break;
case "bio_lab_admin":
labSubs.add("3");
break;
default:break;
} }
} }
if (user.isAdmin()){ schoolLabVo.setLabSubs(labSubs);
return schoolLabMapper.selectSchoolLabList(schoolLab); return schoolLabMapper.selectSchoolLabList(schoolLabVo);
}
return list;
} }
/** /**
...@@ -146,11 +162,15 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab> ...@@ -146,11 +162,15 @@ public class SchoolLabServiceImpl extends ServiceImpl<SchoolLabMapper,SchoolLab>
return schoolLabMapper.getLabAdminAll(); return schoolLabMapper.getLabAdminAll();
} }
if (list.size() <= 0){ if (list.size() <= 0){
throw new ServiceException("查询到您实验室管理员信息"); throw new ServiceException("查询到您实验室管理员信息");
} }
return list; return list;
} }
/**
* 获取学科
* @return
*/
@Override @Override
public List<Map<String, String>> getSub() { public List<Map<String, String>> getSub() {
List<Map<String, String>> list = new ArrayList<>(); List<Map<String, String>> list = new ArrayList<>();
......
package yangtz.cs.liu.campus.service.impl.schoolLab; package yangtz.cs.liu.campus.service.impl.schoolLab;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.List; import java.util.List;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.common.exception.ServiceException;
import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.StringUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApplyLabs;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherExperimentApplyMapper; import yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherExperimentApplyMapper;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoollTeacherExperimentApplyLabsMapper;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherExperimentApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherExperimentApplyService;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherExperimentApplyVo;
/** /**
* 教师个人实验申请Service业务层处理 * 教师个人实验申请Service业务层处理
...@@ -29,7 +40,7 @@ public class SchoolTeacherExperimentApplyServiceImpl extends ServiceImpl<SchoolT ...@@ -29,7 +40,7 @@ public class SchoolTeacherExperimentApplyServiceImpl extends ServiceImpl<SchoolT
* @return 教师个人实验申请 * @return 教师个人实验申请
*/ */
@Override @Override
public SchoolTeacherExperimentApply selectSchoolTeacherExperimentApplyById(Long id) public SchoolTeacherExperimentApplyVo selectSchoolTeacherExperimentApplyById(Long id)
{ {
return schoolTeacherExperimentApplyMapper.selectSchoolTeacherExperimentApplyById(id); return schoolTeacherExperimentApplyMapper.selectSchoolTeacherExperimentApplyById(id);
} }
...@@ -37,39 +48,47 @@ public class SchoolTeacherExperimentApplyServiceImpl extends ServiceImpl<SchoolT ...@@ -37,39 +48,47 @@ public class SchoolTeacherExperimentApplyServiceImpl extends ServiceImpl<SchoolT
/** /**
* 查询教师个人实验申请列表 * 查询教师个人实验申请列表
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 教师个人实验申请 * @return 教师个人实验申请
*/ */
@Override @Override
public List<SchoolTeacherExperimentApply> selectSchoolTeacherExperimentApplyList(SchoolTeacherExperimentApply schoolTeacherExperimentApply) public List<SchoolTeacherExperimentApplyVo> selectSchoolTeacherExperimentApplyList(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo)
{ {
return schoolTeacherExperimentApplyMapper.selectSchoolTeacherExperimentApplyList(schoolTeacherExperimentApply); return schoolTeacherExperimentApplyMapper.selectSchoolTeacherExperimentApplyList(schoolTeacherExperimentApplyVo);
} }
/** /**
* 新增教师个人实验申请 * 新增教师个人实验申请
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 结果 * @return 结果
*/ */
@Override @Override
public int insertSchoolTeacherExperimentApply(SchoolTeacherExperimentApply schoolTeacherExperimentApply) public int insertSchoolTeacherExperimentApply(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo)
{ {
schoolTeacherExperimentApply.setCreateTime(DateUtils.getNowDate()); SysUser user = SecurityUtils.getLoginUser().getUser();
return schoolTeacherExperimentApplyMapper.insertSchoolTeacherExperimentApply(schoolTeacherExperimentApply); schoolTeacherExperimentApplyVo.setApplyId(user.getUserId());
schoolTeacherExperimentApplyVo.setApplyName(user.getUserName());
schoolTeacherExperimentApplyVo.setApplyTime(DateUtils.getNowDate());
schoolTeacherExperimentApplyVo.setCreateBy(user.getUserName());
schoolTeacherExperimentApplyVo.setCreateTime(DateUtils.getNowDate());
int rows = schoolTeacherExperimentApplyMapper.insertSchoolTeacherExperimentApply(schoolTeacherExperimentApplyVo);
return rows;
} }
/** /**
* 修改教师个人实验申请 * 修改教师个人实验申请
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 结果 * @return 结果
*/ */
@Override @Override
public int updateSchoolTeacherExperimentApply(SchoolTeacherExperimentApply schoolTeacherExperimentApply) public int updateSchoolTeacherExperimentApply(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo)
{ {
schoolTeacherExperimentApply.setUpdateTime(DateUtils.getNowDate()); SysUser user = SecurityUtils.getLoginUser().getUser();
return schoolTeacherExperimentApplyMapper.updateSchoolTeacherExperimentApply(schoolTeacherExperimentApply); schoolTeacherExperimentApplyVo.setUpdateBy(user.getUserName());
schoolTeacherExperimentApplyVo.setUpdateTime(DateUtils.getNowDate());
return schoolTeacherExperimentApplyMapper.updateSchoolTeacherExperimentApply(schoolTeacherExperimentApplyVo);
} }
/** /**
...@@ -95,4 +114,28 @@ public class SchoolTeacherExperimentApplyServiceImpl extends ServiceImpl<SchoolT ...@@ -95,4 +114,28 @@ public class SchoolTeacherExperimentApplyServiceImpl extends ServiceImpl<SchoolT
{ {
return schoolTeacherExperimentApplyMapper.deleteSchoolTeacherExperimentApplyById(id); return schoolTeacherExperimentApplyMapper.deleteSchoolTeacherExperimentApplyById(id);
} }
/**
* 实验室管理-教师个人演示实验审批-分配实验室
* @param schoolTeacherExperimentApplyVo
* @return
*/
@Override
public int teacherExperimentLabs(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo) {
List<SchoolTeacherExperimentApplyLabs> schoolTeacherExperimentApplyLabsList = schoolTeacherExperimentApplyVo.getSchoolTeacherExperimentApplyLabsList();
Long id = schoolTeacherExperimentApplyVo.getId();
if (StringUtils.isNull(schoolTeacherExperimentApplyLabsList)){
throw new ServiceException("请选择实验室");
}
List<SchoolTeacherExperimentApplyLabs> list = new ArrayList<>();
for (SchoolTeacherExperimentApplyLabs schoolTeacherExperimentApplyLabs : schoolTeacherExperimentApplyLabsList) {
schoolTeacherExperimentApplyLabs.setTeacherExperimentApplyId(id);
list.add(schoolTeacherExperimentApplyLabs);
}
if (list.size() > 0){
schoolTeacherExperimentApplyMapper.deleteSchoolTeacherExperimentApplyLabsId(id);
schoolTeacherExperimentApplyMapper.batchSchoolTeacherExperimentApplyLabs(list);
}
return schoolTeacherExperimentApplyMapper.updateSchoolTeacherExperimentApply(schoolTeacherExperimentApplyVo);
}
} }
package yangtz.cs.liu.campus.service.impl.schoolLab;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApplyLabs;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoollTeacherExperimentApplyLabsMapper;
import yangtz.cs.liu.campus.service.schoolLab.ISchoollTeacherExperimentApplyLabsService;
@Service
public class SchoollTeacherExperimentApplyLabsServiceImpl extends ServiceImpl<SchoollTeacherExperimentApplyLabsMapper, SchoolTeacherExperimentApplyLabs> implements ISchoollTeacherExperimentApplyLabsService {
}
...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab; ...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolExperimentPlan; import yangtz.cs.liu.campus.domain.schoolLab.SchoolExperimentPlan;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolExperimentPlanMbVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolExperimentPlanVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolExperimentPlanVo;
import java.util.List; import java.util.List;
...@@ -69,12 +70,42 @@ public interface ISchoolExperimentPlanService extends IService<SchoolExperimentP ...@@ -69,12 +70,42 @@ public interface ISchoolExperimentPlanService extends IService<SchoolExperimentP
* @param schoolYear * @param schoolYear
* @return * @return
*/ */
List<Map<String,String>> getGrade(int schoolYear); List<Map<String,Object>> getGrade(int schoolYear,Long userId);
/** /**
* 根据级部查询对应班级 * 根据级部查询对应班级
* @param gradeId * @param gradeId
* @return * @return
*/ */
List<Map<String,String>> getSchoolClass(Long gradeId); List<Map<String,Object>> getSchoolClass(Long gradeId);
List<Map<String,String>> getSub(Long gradeId);
/**
* 实验室管理-级部实验计划查看列表
* @param schoolExperimentPlanVo
* @return
*/
List<SchoolExperimentPlanVo> getExperimentList(SchoolExperimentPlanVo schoolExperimentPlanVo);
/**
* 领导-查看实验室完成情况列表
* @param schoolExperimentPlanVo
* @return
*/
List<Map<String,Object>> countExperiment(SchoolExperimentPlanVo schoolExperimentPlanVo);
/**
* 实验室管理-查看实验室完成情况列表
* @param schoolExperimentPlanVo
* @return
*/
List<Map<String,Object>> countExperimentAdmin(SchoolExperimentPlanVo schoolExperimentPlanVo);
/**
* 级部-实验室完成情况明细
* @param schoolExperimentPlanVo
* @return
*/
List<Map<String, Object>> gradeCountExperiment(SchoolExperimentPlanVo schoolExperimentPlanVo);
} }
package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYearRelation;
public interface ISchoolLabClassYearRelationService extends IService<SchoolLabClassYearRelation> {
}
...@@ -2,9 +2,11 @@ package yangtz.cs.liu.campus.service.schoolLab; ...@@ -2,9 +2,11 @@ package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import java.util.List; import java.util.List;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo; import java.util.Map;
/** /**
* 年级实验室预约Service接口 * 年级实验室预约Service接口
...@@ -21,15 +23,15 @@ public interface ISchoolLabClassYearService extends IService<SchoolLabClassYear> ...@@ -21,15 +23,15 @@ public interface ISchoolLabClassYearService extends IService<SchoolLabClassYear>
* @param id 年级实验室预约主键 * @param id 年级实验室预约主键
* @return 年级实验室预约 * @return 年级实验室预约
*/ */
public SchoolLabClassYear selectSchoolLabClassYearById(Long id); public SchoolLabClassYearVo selectSchoolLabClassYearById(Long id);
/** /**
* 查询年级实验室预约列表 * 查询年级实验室预约列表
* *
* @param schoolLabClassYear 年级实验室预约 * @param schoolLabClassYearVo 年级实验室预约
* @return 年级实验室预约集合 * @return 年级实验室预约集合
*/ */
public List<SchoolLabClassYear> selectSchoolLabClassYearList(SchoolLabClassYear schoolLabClassYear); public List<SchoolLabClassYearVo> selectSchoolLabClassYearList(SchoolLabClassYearVo schoolLabClassYearVo);
/** /**
* 新增年级实验室预约 * 新增年级实验室预约
...@@ -63,8 +65,55 @@ public interface ISchoolLabClassYearService extends IService<SchoolLabClassYear> ...@@ -63,8 +65,55 @@ public interface ISchoolLabClassYearService extends IService<SchoolLabClassYear>
*/ */
public int deleteSchoolLabClassYearById(Long id); public int deleteSchoolLabClassYearById(Long id);
/**
* 实验室管理-年级实验室预约列表
* @param schoolLabClassYearVo
* @return
*/
List<SchoolLabClassYearVo> getLabClassYear(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* 实验室管理-年级实验室-分配实验室
* @param schoolLabClassYearVo
* @return
*/
int updateLabClassYear(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* 获取实验室
* @param schoolLabClassYearVo
* @return
*/
List<Map<String,Object>> getLabList(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* 实验室管理-年级实验室预约查看详情
* @param id
* @return
*/
SchoolLabClassYearVo getLabClassYearById(Long id);
/**
* 教师-实验室安排列表
* @param schoolLabClassYearVo
* @return
*/
List<SchoolLabClassYearVo> getTeacherLabList(SchoolLabClassYearVo schoolLabClassYearVo);
/**
* xwh-新增年级预约
* @param schoolLabClassYear
* @return
*/
int insertSchoolLabClassYearVo(SchoolLabClassYear schoolLabClassYear);
/**
* xwh-修改年级预约
* @param schoolLabClassYear
* @return
*/
int updateSchoolLabClassYearVo(SchoolLabClassYear schoolLabClassYear);
public List<ClassSituationVo> classSituation(ClassSituationVo classSituationVo); public List<ClassSituationVo> classSituation(ClassSituationVo classSituationVo);
public List<ClassSituationVo> getexperimentList(ClassSituationVo classSituationVo); public List<ClassSituationVo> getexperimentList(ClassSituationVo classSituationVo);
} }
...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab; ...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabCompetition;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabCompetitionVo;
import java.util.List; import java.util.List;
...@@ -19,31 +20,31 @@ public interface ISchoolLabCompetitionService extends IService<SchoolLabCompetit ...@@ -19,31 +20,31 @@ public interface ISchoolLabCompetitionService extends IService<SchoolLabCompetit
* @param id 实验室竞赛主键 * @param id 实验室竞赛主键
* @return 实验室竞赛 * @return 实验室竞赛
*/ */
public SchoolLabCompetition selectSchoolLabCompetitionById(Long id); public SchoolLabCompetitionVo selectSchoolLabCompetitionById(Long id);
/** /**
* 查询实验室竞赛列表 * 查询实验室竞赛列表
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 实验室竞赛集合 * @return 实验室竞赛集合
*/ */
public List<SchoolLabCompetition> selectSchoolLabCompetitionList(SchoolLabCompetition schoolLabCompetition); public List<SchoolLabCompetitionVo> selectSchoolLabCompetitionList(SchoolLabCompetitionVo schoolLabCompetitionVo);
/** /**
* 新增实验室竞赛 * 新增实验室竞赛
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 结果 * @return 结果
*/ */
public int insertSchoolLabCompetition(SchoolLabCompetition schoolLabCompetition); public int insertSchoolLabCompetition(SchoolLabCompetitionVo schoolLabCompetitionVo);
/** /**
* 修改实验室竞赛 * 修改实验室竞赛
* *
* @param schoolLabCompetition 实验室竞赛 * @param schoolLabCompetitionVo 实验室竞赛
* @return 结果 * @return 结果
*/ */
public int updateSchoolLabCompetition(SchoolLabCompetition schoolLabCompetition); public int updateSchoolLabCompetition(SchoolLabCompetitionVo schoolLabCompetitionVo);
/** /**
* 批量删除实验室竞赛 * 批量删除实验室竞赛
......
...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab; ...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLab;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabVo;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -21,15 +22,15 @@ public interface ISchoolLabService extends IService<SchoolLab> ...@@ -21,15 +22,15 @@ public interface ISchoolLabService extends IService<SchoolLab>
* @param id 实验室主键 * @param id 实验室主键
* @return 实验室 * @return 实验室
*/ */
public SchoolLab selectSchoolLabById(Long id); public SchoolLabVo selectSchoolLabById(Long id);
/** /**
* 查询实验室列表 * 查询实验室列表
* *
* @param schoolLab 实验室 * @param schoolLabVo 实验室
* @return 实验室集合 * @return 实验室集合
*/ */
public List<SchoolLab> selectSchoolLabList(SchoolLab schoolLab); public List<SchoolLabVo> selectSchoolLabList(SchoolLabVo schoolLabVo);
/** /**
* 新增实验室 * 新增实验室
......
...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab; ...@@ -2,6 +2,7 @@ package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherExperimentApplyVo;
import java.util.List; import java.util.List;
...@@ -19,15 +20,15 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea ...@@ -19,15 +20,15 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea
* @param id 教师个人实验申请主键 * @param id 教师个人实验申请主键
* @return 教师个人实验申请 * @return 教师个人实验申请
*/ */
public SchoolTeacherExperimentApply selectSchoolTeacherExperimentApplyById(Long id); public SchoolTeacherExperimentApplyVo selectSchoolTeacherExperimentApplyById(Long id);
/** /**
* 查询教师个人实验申请列表 * 查询教师个人实验申请列表
* *
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApplyVo 教师个人实验申请
* @return 教师个人实验申请集合 * @return 教师个人实验申请集合
*/ */
public List<SchoolTeacherExperimentApply> selectSchoolTeacherExperimentApplyList(SchoolTeacherExperimentApply schoolTeacherExperimentApply); public List<SchoolTeacherExperimentApplyVo> selectSchoolTeacherExperimentApplyList(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo);
/** /**
* 新增教师个人实验申请 * 新增教师个人实验申请
...@@ -35,7 +36,7 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea ...@@ -35,7 +36,7 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApply 教师个人实验申请
* @return 结果 * @return 结果
*/ */
public int insertSchoolTeacherExperimentApply(SchoolTeacherExperimentApply schoolTeacherExperimentApply); public int insertSchoolTeacherExperimentApply(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApply);
/** /**
* 修改教师个人实验申请 * 修改教师个人实验申请
...@@ -43,7 +44,7 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea ...@@ -43,7 +44,7 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea
* @param schoolTeacherExperimentApply 教师个人实验申请 * @param schoolTeacherExperimentApply 教师个人实验申请
* @return 结果 * @return 结果
*/ */
public int updateSchoolTeacherExperimentApply(SchoolTeacherExperimentApply schoolTeacherExperimentApply); public int updateSchoolTeacherExperimentApply(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApply);
/** /**
* 批量删除教师个人实验申请 * 批量删除教师个人实验申请
...@@ -60,4 +61,12 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea ...@@ -60,4 +61,12 @@ public interface ISchoolTeacherExperimentApplyService extends IService<SchoolTea
* @return 结果 * @return 结果
*/ */
public int deleteSchoolTeacherExperimentApplyById(Long id); public int deleteSchoolTeacherExperimentApplyById(Long id);
/**
* 实验室管理-教师个人演示实验审批-分配实验室
* @param schoolTeacherExperimentApplyVo
* @return
*/
int teacherExperimentLabs(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo);
} }
package yangtz.cs.liu.campus.service.schoolLab; package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import java.util.Map;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
import java.util.List; import java.util.List;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo; import java.util.Map;
/** /**
* 教师实验室申请Service接口 * 教师实验室申请Service接口
...@@ -22,31 +22,31 @@ public interface ISchoolTeacherLabApplyService extends IService<SchoolTeacherLab ...@@ -22,31 +22,31 @@ public interface ISchoolTeacherLabApplyService extends IService<SchoolTeacherLab
* @param id 教师实验室申请主键 * @param id 教师实验室申请主键
* @return 教师实验室申请 * @return 教师实验室申请
*/ */
public SchoolTeacherLabApply selectSchoolTeacherLabApplyById(Long id); public SchoolTeacherLabApplyVo selectSchoolTeacherLabApplyById(Long id);
/** /**
* 查询教师实验室申请列表 * 查询教师实验室申请列表
* *
* @param schoolTeacherLabApply 教师实验室申请 * @param schoolTeacherLabApplyVo 教师实验室申请
* @return 教师实验室申请集合 * @return 教师实验室申请集合
*/ */
public List<SchoolTeacherLabApply> selectSchoolTeacherLabApplyList(SchoolTeacherLabApply schoolTeacherLabApply); public List<SchoolTeacherLabApplyVo> selectSchoolTeacherLabApplyList(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/** /**
* 新增教师实验室申请 * 新增教师实验室申请
* *
* @param schoolTeacherLabApply 教师实验室申请 * @param schoolTeacherLabApplyVo 教师实验室申请
* @return 结果 * @return 结果
*/ */
public int insertSchoolTeacherLabApply(SchoolTeacherLabApply schoolTeacherLabApply); public int insertSchoolTeacherLabApply(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/** /**
* 修改教师实验室申请 * 修改教师实验室申请
* *
* @param schoolTeacherLabApply 教师实验室申请 * @param schoolTeacherLabApplyVo 教师实验室申请
* @return 结果 * @return 结果
*/ */
public int updateSchoolTeacherLabApply(SchoolTeacherLabApply schoolTeacherLabApply); public int updateSchoolTeacherLabApply(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/** /**
* 批量删除教师实验室申请 * 批量删除教师实验室申请
...@@ -64,7 +64,83 @@ public interface ISchoolTeacherLabApplyService extends IService<SchoolTeacherLab ...@@ -64,7 +64,83 @@ public interface ISchoolTeacherLabApplyService extends IService<SchoolTeacherLab
*/ */
public int deleteSchoolTeacherLabApplyById(Long id); public int deleteSchoolTeacherLabApplyById(Long id);
/**
* 获取实验室使用状态
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> getTeacherLab(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 获取班级
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String, Object>> getTeacherClass(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 上传附件
* @param schoolTeacherLabApplyVo
* @return
*/
int updateTeacherLab(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 实验室管理-教师申请列表
* @param schoolTeacherLabApplyVo
* @return
*/
List<SchoolTeacherLabApplyVo> getTeacherLabApplyList(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 实验室管理-教师申请审批确认
* @param schoolTeacherLabApply
* @return
*/
int updateState(SchoolTeacherLabApply schoolTeacherLabApply);
/**
* 查看班级完成详情
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String,Object>> getClassDetails(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 教师实验统计
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String,Object>> getCountTeacher(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 级部-班级完成情况明细
* @param schoolTeacherLabApplyVo
* @return
*/
List<Map<String,Object>> gradeCountClass(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* 级部-班级完成情况明细-查看班级完成情况详情
* @param schoolTeacherLabApplyVo
* @return
*/
List<SchoolTeacherLabApplyVo> getGradeClassDetails(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* xwh-新增教师申请
* @param schoolTeacherLabApplyVo
* @return
*/
int insertSchoolTeacherLabApplyVo(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
/**
* xwh-修改教师申请
* @param schoolTeacherLabApplyVo
* @return
*/
int updateSchoolTeacherLabApplyVo(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo);
List<SchoolTeacherLabApply> getTeacherExperimentList(ClassSituationVo one); List<SchoolTeacherLabApplyVo> getTeacherExperimentList(ClassSituationVo one);
List<Map<String,String>> selectTeacherList(SchoolTeacherLabApply schoolTeacherLabApply); List<Map<String,String>> selectTeacherList(SchoolTeacherLabApply schoolTeacherLabApply);
} }
package yangtz.cs.liu.campus.service.schoolLab;
import com.baomidou.mybatisplus.extension.service.IService;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApplyLabs;
public interface ISchoollTeacherExperimentApplyLabsService extends IService<SchoolTeacherExperimentApplyLabs> {
}
...@@ -8,75 +8,75 @@ import lombok.Data; ...@@ -8,75 +8,75 @@ import lombok.Data;
@Data @Data
public class ClassSituationVo { public class ClassSituationVo {
/** /**
* 实验室计划id * 实验室计划id
*/ */
private Long id; private Long id;
/** /**
* 级部预约id * 级部预约id
*/ */
private Long labClassYearId; private Long labClassYearId;
/** /**
* 级部id * 级部id
*/ */
private Long gradeId; private Long gradeId;
/** /**
* 级部 * 级部
*/ */
private String grade; private String grade;
/** /**
* 班级id * 班级id
*/ */
private Long classId; private Long classId;
/** /**
* 学年 * 学年
*/ */
private String schoolYear; private String schoolYear;
/** /**
* 学期 * 学期
*/ */
private String semester; private String semester;
/** /**
* 班级 * 班级
*/ */
private String className; private String className;
/** /**
* 实验室名称 * 实验室名称
*/ */
private String experimentName; private String experimentName;
/** /**
* 实验室是否使用完成 (0未完成,1完成) * 实验室是否使用完成 (0未完成,1完成)
*/ */
private String state; private String state;
/** /**
* 实验时间 * 实验时间
*/ */
private String experimentTime; private String experimentTime;
/** /**
* 已完成实验数 * 已完成实验数
*/ */
private Integer complete; private Integer complete;
/** /**
* 总数 * 总数
*/ */
private Integer count; private Integer count;
/** /**
* 未完成实验数 * 未完成实验数
*/ */
private Integer incomplete; private Integer incomplete;
/** /**
* 完成比例 * 完成比例
*/ */
private Integer proportion; private Integer proportion;
} }
...@@ -23,11 +23,12 @@ public class SchoolExperimentPlanVo extends BaseEntity ...@@ -23,11 +23,12 @@ public class SchoolExperimentPlanVo extends BaseEntity
private Long id; private Long id;
/** 学科(1物理,2化学,3生物) */ /** 学科(1物理,2化学,3生物) */
@Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物") @Excel(name = "学科", combo = {"物理","化学","生物"}, readConverterExp = "1=物理,2=化学,3=生物")
private String sub; private String sub;
private List<String> subs;
/** 级部id */ /** 级部id */
@Excel(name = "级部id")
private Long gradeId; private Long gradeId;
private List<Long> gradeIds; private List<Long> gradeIds;
...@@ -37,16 +38,18 @@ public class SchoolExperimentPlanVo extends BaseEntity ...@@ -37,16 +38,18 @@ public class SchoolExperimentPlanVo extends BaseEntity
private String grade; private String grade;
/** 学年 */ /** 学年 */
@Excel(name = "学年")
private String schoolYear; private String schoolYear;
/** 学年+学期 */ /** 学年+学期 */
private String schoolYearSemester; private String schoolYearSemester;
/** 学期(1上学期,2下学期) */ /** 学期(1上学期,2下学期) */
@Excel(name = "学期", combo = {"上学期","下学期"}, readConverterExp = "1=上学期,2=下学期")
private String semester; private String semester;
/** 实验分类(1分组实验,2演示实验,3探究实验) */ /** 实验分类(1分组实验,2演示实验,3探究实验) */
@Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验") @Excel(name = "实验分类", combo = {"分组实验","演示实验","探究实验"}, readConverterExp = "1=分组实验,2=演示实验,3=探究实验")
private String experimentClassify; private String experimentClassify;
/** 实验名称 */ /** 实验名称 */
...@@ -58,13 +61,15 @@ public class SchoolExperimentPlanVo extends BaseEntity ...@@ -58,13 +61,15 @@ public class SchoolExperimentPlanVo extends BaseEntity
private String chapterContent; private String chapterContent;
/** 是否已预约 */ /** 是否已预约 */
@Excel(name = "是否已预约", readConverterExp = "0=否,1=是") @Excel(name = "是否已预约", combo = {"是","否"}, readConverterExp = "0=否,1=是")
private String isAppointment; private String isAppointment;
/** 计划开始时间 */ /** 计划开始时间 */
@Excel(name = "计划开始时间")
private String plannedStartTime; private String plannedStartTime;
/** 计划结束时间 */ /** 计划结束时间 */
@Excel(name = "计划结束时间")
private String plannedEndTime; private String plannedEndTime;
/** 计划时间 */ /** 计划时间 */
......
...@@ -26,7 +26,16 @@ public class SchoolLabClassYearVo extends BaseEntity ...@@ -26,7 +26,16 @@ public class SchoolLabClassYearVo extends BaseEntity
private Long id; private Long id;
/** 实验计划id */ /** 实验计划id */
private String experimentPlanId; private Long experimentPlanId;
/** 实验名称 */
private String experimentName;
/** 级部id */
private Long gradeId;
/** 级部id集合 */
private List<Long> gradeIds;
/** 级部 */ /** 级部 */
@Excel(name = "级部") @Excel(name = "级部")
...@@ -36,6 +45,9 @@ public class SchoolLabClassYearVo extends BaseEntity ...@@ -36,6 +45,9 @@ public class SchoolLabClassYearVo extends BaseEntity
@Excel(name = "学年") @Excel(name = "学年")
private String schoolYear; private String schoolYear;
/** 学年+学期 */
private String schoolYearSemester;
/** 学期(1上学期,2下学期) */ /** 学期(1上学期,2下学期) */
@Excel(name = "学期", readConverterExp = "1=上学期,2=下学期") @Excel(name = "学期", readConverterExp = "1=上学期,2=下学期")
private String semester; private String semester;
...@@ -44,6 +56,8 @@ public class SchoolLabClassYearVo extends BaseEntity ...@@ -44,6 +56,8 @@ public class SchoolLabClassYearVo extends BaseEntity
@Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物") @Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物")
private String sub; private String sub;
private List<String> subs;
/** 实验分类(1分组实验,2演示实验,3探究实验) */ /** 实验分类(1分组实验,2演示实验,3探究实验) */
@Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验") @Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验")
private String experimentClassify; private String experimentClassify;
...@@ -58,6 +72,9 @@ public class SchoolLabClassYearVo extends BaseEntity ...@@ -58,6 +72,9 @@ public class SchoolLabClassYearVo extends BaseEntity
@Excel(name = "计划结束时间", width = 30, dateFormat = "yyyy-MM-dd") @Excel(name = "计划结束时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date plannedEndTime; private Date plannedEndTime;
/** 计划时间 */
private String plannedTime;
/** 章节内容 */ /** 章节内容 */
@Excel(name = "章节内容") @Excel(name = "章节内容")
private String chapterContent; private String chapterContent;
......
...@@ -5,6 +5,9 @@ import com.baomidou.mybatisplus.annotation.TableId; ...@@ -5,6 +5,9 @@ import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data; import lombok.Data;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity; import com.ruoyi.common.core.domain.BaseEntity;
import yangtz.cs.liu.campus.domain.accessory.SchoolAccessory;
import java.util.List;
/** /**
* 实验室竞赛对象Vo * 实验室竞赛对象Vo
...@@ -61,4 +64,7 @@ public class SchoolLabCompetitionVo extends BaseEntity ...@@ -61,4 +64,7 @@ public class SchoolLabCompetitionVo extends BaseEntity
/** 备注3 */ /** 备注3 */
@Excel(name = "备注3") @Excel(name = "备注3")
private String remark3; private String remark3;
/** 图片信息集合 */
private List<SchoolAccessory> schoolAccessoryList;
} }
...@@ -6,6 +6,8 @@ import com.ruoyi.common.annotation.Excel; ...@@ -6,6 +6,8 @@ import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity; import com.ruoyi.common.core.domain.BaseEntity;
import lombok.Data; import lombok.Data;
import java.util.List;
/** /**
* 实验室对象Vo * 实验室对象Vo
* *
...@@ -28,6 +30,9 @@ public class SchoolLabVo extends BaseEntity ...@@ -28,6 +30,9 @@ public class SchoolLabVo extends BaseEntity
@Excel(name = "实验室学科", readConverterExp = "1=物理,2=化学,3=生物") @Excel(name = "实验室学科", readConverterExp = "1=物理,2=化学,3=生物")
private String labSub; private String labSub;
/** 实验室学科集合 */
private List<String> labSubs;
/** 负责人id */ /** 负责人id */
private Long inChargeId; private Long inChargeId;
...@@ -42,4 +47,7 @@ public class SchoolLabVo extends BaseEntity ...@@ -42,4 +47,7 @@ public class SchoolLabVo extends BaseEntity
/** 实验室用品 */ /** 实验室用品 */
@Excel(name = "实验室用品") @Excel(name = "实验室用品")
private String labUseGoods; private String labUseGoods;
/** 使用状态 */
private String useState;
} }
package yangtz.cs.liu.campus.vo.schoolLab; package yangtz.cs.liu.campus.vo.schoolLab;
import java.util.Date; import java.util.Date;
import java.util.List;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
...@@ -8,6 +9,7 @@ import com.fasterxml.jackson.annotation.JsonFormat; ...@@ -8,6 +9,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data; import lombok.Data;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity; import com.ruoyi.common.core.domain.BaseEntity;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApplyLabs;
/** /**
* 教师个人实验申请对象Vo * 教师个人实验申请对象Vo
...@@ -29,6 +31,8 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity ...@@ -29,6 +31,8 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity
@Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物") @Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物")
private String sub; private String sub;
private List<String> subs;
/** 级部id */ /** 级部id */
private Long gradeId; private Long gradeId;
...@@ -44,6 +48,19 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity ...@@ -44,6 +48,19 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity
@Excel(name = "学期") @Excel(name = "学期")
private String semester; private String semester;
/** 学年+学期 */
private String schoolYearSemester;
/** 规划开始时间 */
@Excel(name = "规划开始时间")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date plannedStartTime;
/** 规划结束时间 */
@Excel(name = "规划结束时间")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date plannedEndTime;
/** 规划时间 */ /** 规划时间 */
@Excel(name = "规划时间") @Excel(name = "规划时间")
private String plannedTime; private String plannedTime;
...@@ -60,13 +77,6 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity ...@@ -60,13 +77,6 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity
@Excel(name = "实验用品") @Excel(name = "实验用品")
private String experimentUseGoods; private String experimentUseGoods;
/** 实验室id */
private String labId;
/** 实验室名称 */
@Excel(name = "实验室名称")
private String labName;
/** 申报状态(0未申报,1已申报,2已阅读,3已分配) */ /** 申报状态(0未申报,1已申报,2已阅读,3已分配) */
@Excel(name = "申报状态", readConverterExp = "0=未申报,1=已申报,2=已阅读,3=已分配") @Excel(name = "申报状态", readConverterExp = "0=未申报,1=已申报,2=已阅读,3=已分配")
private String declareState; private String declareState;
...@@ -82,4 +92,7 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity ...@@ -82,4 +92,7 @@ public class SchoolTeacherExperimentApplyVo extends BaseEntity
@JsonFormat(pattern = "yyyy-MM-dd") @JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "申报时间", width = 30, dateFormat = "yyyy-MM-dd") @Excel(name = "申报时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date applyTime; private Date applyTime;
/** 教师个人实验申请实验室列表 */
private List<SchoolTeacherExperimentApplyLabs> schoolTeacherExperimentApplyLabsList;
} }
package yangtz.cs.liu.campus.vo.schoolLab; package yangtz.cs.liu.campus.vo.schoolLab;
import java.util.Date; import java.util.Date;
import java.util.List;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
...@@ -8,6 +9,7 @@ import com.fasterxml.jackson.annotation.JsonFormat; ...@@ -8,6 +9,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data; import lombok.Data;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity; import com.ruoyi.common.core.domain.BaseEntity;
import yangtz.cs.liu.campus.domain.accessory.SchoolAccessory;
/** /**
* 教师实验室申请对象Vo * 教师实验室申请对象Vo
...@@ -28,14 +30,31 @@ public class SchoolTeacherLabApplyVo extends BaseEntity ...@@ -28,14 +30,31 @@ public class SchoolTeacherLabApplyVo extends BaseEntity
/** 年级实验室预约主键id */ /** 年级实验室预约主键id */
private String labClassYearId; private String labClassYearId;
/** 教师id */
private Long teacherId;
/** 实验分类(1分组实验,2演示实验,3探究实验) */ /** 实验分类(1分组实验,2演示实验,3探究实验) */
@Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验") @Excel(name = "实验分类", readConverterExp = "1=分组实验,2=演示实验,3=探究实验")
private String experimentClassify; private String experimentClassify;
/** 实验计划id */
private Long experimentPlanId;
/** 实验名称 */
private String experimentName;
/** 学科(1物理,2化学,3生物) */ /** 学科(1物理,2化学,3生物) */
@Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物") @Excel(name = "学科", readConverterExp = "1=物理,2=化学,3=生物")
private String sub; private String sub;
/** 学科集合 */
private List<String> subs;
/** 级部id */
private Long gradeId;
private List<Long> gradeIds;
/** 级部 */ /** 级部 */
@Excel(name = "级部") @Excel(name = "级部")
private String grade; private String grade;
...@@ -48,6 +67,9 @@ public class SchoolTeacherLabApplyVo extends BaseEntity ...@@ -48,6 +67,9 @@ public class SchoolTeacherLabApplyVo extends BaseEntity
@Excel(name = "学期", readConverterExp = "1=上学期,2=下学期") @Excel(name = "学期", readConverterExp = "1=上学期,2=下学期")
private String semester; private String semester;
/** 学年+学期 */
private String schoolYearSemester;
/** 班级id */ /** 班级id */
private String classId; private String classId;
...@@ -90,4 +112,18 @@ public class SchoolTeacherLabApplyVo extends BaseEntity ...@@ -90,4 +112,18 @@ public class SchoolTeacherLabApplyVo extends BaseEntity
@JsonFormat(pattern = "yyyy-MM-dd") @JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd") @Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date applyTime; private Date applyTime;
/** 实验室是否使用完成 (0未完成,1完成) */
private String state;
/** 开始时间 */
@JsonFormat(pattern = "yyyy-MM-dd")
private Date startTime;
/** 结束时间 */
@JsonFormat(pattern = "yyyy-MM-dd")
private Date endTime;
/** 附件信息集合 */
private List<SchoolAccessory> schoolAccessoryList;
} }
...@@ -3,15 +3,8 @@ package yangtz.cs.liu.wechat.controller.experiment; ...@@ -3,15 +3,8 @@ package yangtz.cs.liu.wechat.controller.experiment;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PutMapping;
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.SchoolLabClassYear; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
...@@ -19,6 +12,12 @@ import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService; ...@@ -19,6 +12,12 @@ import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherExperimentApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherExperimentApplyService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo; import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
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.List;
import java.util.Map;
/** /**
* 实验室管理员 * 实验室管理员
...@@ -51,9 +50,9 @@ public class ExperimentAdministratorsControoler extends BaseController { ...@@ -51,9 +50,9 @@ public class ExperimentAdministratorsControoler extends BaseController {
* 年级实验室分分配列表 * 年级实验室分分配列表
*/ */
@GetMapping("/classYear/list") @GetMapping("/classYear/list")
public AjaxResult classYearList(SchoolLabClassYear schoolLabClassYear) public AjaxResult classYearList(SchoolLabClassYearVo schoolLabClassYearVo)
{ {
return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYear)); return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYearVo));
} }
/** /**
...@@ -79,9 +78,9 @@ public class ExperimentAdministratorsControoler extends BaseController { ...@@ -79,9 +78,9 @@ public class ExperimentAdministratorsControoler extends BaseController {
* 教师实验室预约列表 * 教师实验室预约列表
*/ */
@GetMapping(value = "/teacher/list") @GetMapping(value = "/teacher/list")
public AjaxResult teacherList(SchoolTeacherLabApply schoolTeacherLabApply) public AjaxResult teacherList(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApply)); return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo));
} }
/** /**
...@@ -106,9 +105,9 @@ public class ExperimentAdministratorsControoler extends BaseController { ...@@ -106,9 +105,9 @@ public class ExperimentAdministratorsControoler extends BaseController {
*/ */
@GetMapping(value = "/apply/list") @GetMapping(value = "/apply/list")
public AjaxResult applyList(SchoolTeacherExperimentApply schoolTeacherExperimentApply) public AjaxResult applyList(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo)
{ {
return AjaxResult.success(schoolTeacherExperimentApplyService.selectSchoolTeacherExperimentApplyList(schoolTeacherExperimentApply)); return AjaxResult.success(schoolTeacherExperimentApplyService.selectSchoolTeacherExperimentApplyList(schoolTeacherExperimentApplyVo));
} }
/** /**
...@@ -140,7 +139,7 @@ public class ExperimentAdministratorsControoler extends BaseController { ...@@ -140,7 +139,7 @@ public class ExperimentAdministratorsControoler extends BaseController {
} }
/** /**
*实验室完成详情 * 实验室完成详情
*/ */
@GetMapping("/teacherExperimentList") @GetMapping("/teacherExperimentList")
public AjaxResult teacherExperimentList(ClassSituationVo classSituationVo){ public AjaxResult teacherExperimentList(ClassSituationVo classSituationVo){
...@@ -149,7 +148,7 @@ public class ExperimentAdministratorsControoler extends BaseController { ...@@ -149,7 +148,7 @@ public class ExperimentAdministratorsControoler extends BaseController {
SchoolLabClassYear one = schoolLabClassYearService.getOne(lw); SchoolLabClassYear one = schoolLabClassYearService.getOne(lw);
classSituationVo.setLabClassYearId(one.getId()); classSituationVo.setLabClassYearId(one.getId());
List<SchoolTeacherLabApply> teacherExperimentList = schoolTeacherLabApplyService.getTeacherExperimentList( List<SchoolTeacherLabApplyVo> teacherExperimentList = schoolTeacherLabApplyService.getTeacherExperimentList(
classSituationVo); classSituationVo);
return AjaxResult.success(teacherExperimentList); return AjaxResult.success(teacherExperimentList);
} }
......
package yangtz.cs.liu.wechat.controller.experiment; package yangtz.cs.liu.wechat.controller.experiment;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.ruoyi.common.annotation.Log; import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType; import com.ruoyi.common.enums.BusinessType;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
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.SchoolLabClassYear; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
import yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherLabApplyMapper;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolExperimentPlanService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolExperimentPlanService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService;
import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo; import yangtz.cs.liu.campus.vo.schoolLab.ClassSituationVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolExperimentPlanVo; import yangtz.cs.liu.campus.vo.schoolLab.SchoolExperimentPlanVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolLabClassYearVo;
import yangtz.cs.liu.campus.vo.schoolLab.SchoolTeacherLabApplyVo;
import java.util.List;
/** /**
* 实验室 级部申请 * 实验室 级部申请
...@@ -72,7 +64,7 @@ public class ExperimentLevelController extends BaseController { ...@@ -72,7 +64,7 @@ public class ExperimentLevelController extends BaseController {
*获取级部预约列表 *获取级部预约列表
*/ */
@GetMapping("/list") @GetMapping("/list")
public AjaxResult list(SchoolLabClassYear schoolLabClassYear) public AjaxResult list(SchoolLabClassYearVo schoolLabClassYear)
{ {
return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYear)); return AjaxResult.success(schoolLabClassYearService.selectSchoolLabClassYearList(schoolLabClassYear));
} }
...@@ -111,8 +103,8 @@ public class ExperimentLevelController extends BaseController { ...@@ -111,8 +103,8 @@ public class ExperimentLevelController extends BaseController {
* 班级完成详情 * 班级完成详情
*/ */
@GetMapping("/getClassExperimentalDetails") @GetMapping("/getClassExperimentalDetails")
public AjaxResult getClassExperimentalDetails(SchoolTeacherLabApply schoolTeacherLabApply){ public AjaxResult getClassExperimentalDetails(SchoolTeacherLabApplyVo schoolTeacherLabApply){
List<SchoolTeacherLabApply> list = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApply); List<SchoolTeacherLabApplyVo> list = schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApply);
return AjaxResult.success(list); return AjaxResult.success(list);
} }
...@@ -130,18 +122,18 @@ public class ExperimentLevelController extends BaseController { ...@@ -130,18 +122,18 @@ public class ExperimentLevelController extends BaseController {
} }
/** /**
*实验室完成详情 * 实验室完成详情
*/ */
@GetMapping("/teacherExperimentList") @GetMapping("/teacherExperimentList")
public AjaxResult teacherExperimentList(ClassSituationVo classSituationVo){ public AjaxResult teacherExperimentList(ClassSituationVo classSituationVo){
SchoolLabClassYear schoolLabClassYear = new SchoolLabClassYear(); SchoolLabClassYearVo schoolLabClassYear = new SchoolLabClassYearVo();
schoolLabClassYear.setExperimentPlanId(classSituationVo.getId().toString()); schoolLabClassYear.setExperimentPlanId(classSituationVo.getId());
List<SchoolLabClassYear> schoolLabClassYears = schoolLabClassYearService.selectSchoolLabClassYearList( List<SchoolLabClassYearVo> schoolLabClassYears = schoolLabClassYearService.selectSchoolLabClassYearList(
schoolLabClassYear); schoolLabClassYear);
if (!schoolLabClassYears.isEmpty()){ if (!schoolLabClassYears.isEmpty()){
classSituationVo.setLabClassYearId(schoolLabClassYears.get(0).getId()); classSituationVo.setLabClassYearId(schoolLabClassYears.get(0).getId());
} }
List<SchoolTeacherLabApply> teacherExperimentList = schoolTeacherLabApplyService.getTeacherExperimentList( List<SchoolTeacherLabApplyVo> teacherExperimentList = schoolTeacherLabApplyService.getTeacherExperimentList(
classSituationVo); classSituationVo);
return AjaxResult.success(teacherExperimentList); return AjaxResult.success(teacherExperimentList);
} }
......
package yangtz.cs.liu.wechat.controller.experiment; package yangtz.cs.liu.wechat.controller.experiment;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.enums.BusinessType;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
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.SchoolLabClassYear; import yangtz.cs.liu.campus.domain.schoolLab.SchoolLabClassYear;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherExperimentApply;
import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply; import yangtz.cs.liu.campus.domain.schoolLab.SchoolTeacherLabApply;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolLabClassYearService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherExperimentApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherExperimentApplyService;
import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService; import yangtz.cs.liu.campus.service.schoolLab.ISchoolTeacherLabApplyService;
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.List;
/** /**
* 实验室 老师申请 * 实验室 老师申请
...@@ -49,10 +44,10 @@ public class TeacherExperimentController extends BaseController { ...@@ -49,10 +44,10 @@ public class TeacherExperimentController extends BaseController {
*/ */
@GetMapping(value = "/classYear/list") @GetMapping(value = "/classYear/list")
public AjaxResult classYearlist(SchoolLabClassYear schoolLabClassYear) public AjaxResult classYearlist(SchoolLabClassYearVo schoolLabClassYearVo)
{ {
List<SchoolLabClassYear> schoolLabClassYears = schoolLabClassYearService.selectSchoolLabClassYearList( List<SchoolLabClassYearVo> schoolLabClassYears = schoolLabClassYearService.selectSchoolLabClassYearList(
schoolLabClassYear); schoolLabClassYearVo);
return AjaxResult.success(schoolLabClassYears); return AjaxResult.success(schoolLabClassYears);
} }
...@@ -79,9 +74,9 @@ public class TeacherExperimentController extends BaseController { ...@@ -79,9 +74,9 @@ public class TeacherExperimentController extends BaseController {
* 实验室申请记录 * 实验室申请记录
*/ */
@GetMapping(value = "/list") @GetMapping(value = "/list")
public AjaxResult list(SchoolTeacherLabApply schoolTeacherLabApply) public AjaxResult list(SchoolTeacherLabApplyVo schoolTeacherLabApplyVo)
{ {
return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApply)); return AjaxResult.success(schoolTeacherLabApplyService.selectSchoolTeacherLabApplyList(schoolTeacherLabApplyVo));
} }
/** /**
* 实验室申请详情 * 实验室申请详情
...@@ -97,9 +92,9 @@ public class TeacherExperimentController extends BaseController { ...@@ -97,9 +92,9 @@ public class TeacherExperimentController extends BaseController {
*/ */
@GetMapping(value = "/apply/list") @GetMapping(value = "/apply/list")
public AjaxResult applyList(SchoolTeacherExperimentApply schoolTeacherExperimentApply) public AjaxResult applyList(SchoolTeacherExperimentApplyVo schoolTeacherExperimentApplyVo)
{ {
return AjaxResult.success(schoolTeacherExperimentApplyService.selectSchoolTeacherExperimentApplyList(schoolTeacherExperimentApply)); return AjaxResult.success(schoolTeacherExperimentApplyService.selectSchoolTeacherExperimentApplyList(schoolTeacherExperimentApplyVo));
} }
/** /**
......
...@@ -38,14 +38,6 @@ ...@@ -38,14 +38,6 @@
order by g.grade_value, g.class_value order by g.grade_value, g.class_value
</select> </select>
<select id="getClassName" parameterType="Long" resultType="String">
select g.class_name
from school_class g
where g.del_flag = '0' and g.id=#{classId}
</select>
<select id="getUserClassByParent" resultType="SchoolClass"> <select id="getUserClassByParent" resultType="SchoolClass">
SELECT sg.pic_url, SELECT sg.pic_url,
sg.class_value, sg.class_value,
......
...@@ -45,29 +45,60 @@ ...@@ -45,29 +45,60 @@
del_flag = '0' del_flag = '0'
<if test="sub != null and sub != ''"> and sub = #{sub}</if> <if test="sub != null and sub != ''"> and sub = #{sub}</if>
<if test="gradeId != null "> and grade_id = #{gradeId}</if> <if test="gradeId != null "> and grade_id = #{gradeId}</if>
<if test="grade != null and grade != ''"> and grade = #{grade}</if> <if test="grade != null and grade != ''"> and grade like concat('%', #{grade}, '%')</if>
<if test="schoolYear != null and schoolYear != ''"> and school_year = #{schoolYear}</if> <if test="schoolYear != null and schoolYear != ''"> and school_year = #{schoolYear}</if>
<if test="semester != null and semester != ''"> and semester = #{semester}</if> <if test="semester != null and semester != ''"> and semester = #{semester}</if>
<if test="experimentClassify != null and experimentClassify != ''"> and experiment_classify = #{experimentClassify}</if> <if test="experimentClassify != null and experimentClassify != ''"> and experiment_classify = #{experimentClassify}</if>
<if test="experimentName != null and experimentName != ''"> and experiment_name like concat('%', #{experimentName}, '%')</if> <if test="experimentName != null and experimentName != ''"> and experiment_name like concat('%', #{experimentName}, '%')</if>
<if test="chapterContent != null and chapterContent != ''"> and chapter_content = #{chapterContent}</if> <if test="chapterContent != null and chapterContent != ''"> and chapter_content = #{chapterContent}</if>
<if test="isAppointment != null and isAppointment != ''"> and is_appointment = #{isAppointment}</if>
<if test="plannedStartTime != null and plannedStartTime != ''"> and planned_start_time = #{plannedStartTime}</if> <if test="plannedStartTime != null and plannedStartTime != ''"> and planned_start_time = #{plannedStartTime}</if>
<if test="plannedEndTime != null and plannedEndTime != ''"> and planned_end_time = #{plannedEndTime}</if> <if test="plannedEndTime != null and plannedEndTime != ''"> and planned_end_time = #{plannedEndTime}</if>
<if test="experimentUseGoods != null and experimentUseGoods != ''"> and experiment_use_goods = #{experimentUseGoods}</if> <if test="experimentUseGoods != null and experimentUseGoods != ''"> and experiment_use_goods = #{experimentUseGoods}</if>
<if test="gradeIds != null">
and grade_id in
<foreach item="gradeId" collection="gradeIds" open="(" separator="," close=")">
#{gradeId}
</foreach>
</if>
</where>
order by create_time DESC
</select>
<select id="getExperimentList" parameterType="SchoolExperimentPlanVo" resultMap="SchoolExperimentPlanVoResult">
<include refid="selectSchoolExperimentPlanVo"/>
<where>
del_flag = '0'
<if test="sub != null and sub != ''"> and sub = #{sub}</if>
<if test="gradeId != null "> and grade_id = #{gradeId}</if>
<if test="grade != null and grade != ''"> and grade like concat('%', #{grade}, '%')</if>
<if test="schoolYear != null and schoolYear != ''"> and school_year = #{schoolYear}</if>
<if test="semester != null and semester != ''"> and semester = #{semester}</if>
<if test="experimentClassify != null and experimentClassify != ''"> and experiment_classify = #{experimentClassify}</if>
<if test="experimentName != null and experimentName != ''"> and experiment_name like concat('%', #{experimentName}, '%')</if>
<if test="chapterContent != null and chapterContent != ''"> and chapter_content = #{chapterContent}</if>
<if test="plannedStartTime != null and plannedStartTime != ''"> and planned_start_time = #{plannedStartTime}</if>
<if test="plannedEndTime != null and plannedEndTime != ''"> and planned_end_time = #{plannedEndTime}</if>
<if test="experimentUseGoods != null and experimentUseGoods != ''"> and experiment_use_goods = #{experimentUseGoods}</if> <if test="experimentUseGoods != null and experimentUseGoods != ''"> and experiment_use_goods = #{experimentUseGoods}</if>
<if test="gradeIds != null"> and grade in (#{gradeIds})</if> <if test="subs != null ">
and sub in
<foreach item="sub" collection="subs" open="(" separator="," close=")">
#{sub}
</foreach>
</if>
</where> </where>
order by create_time DESC
</select> </select>
<select id="selectSchoolExperimentPlanById" parameterType="Long" resultMap="ExperimentPlanClassResult"> <select id="selectSchoolExperimentPlanById" parameterType="Long" resultMap="ExperimentPlanClassResult">
select a.id, a.sub, a.grade_id, a.grade, a.school_year, a.semester, a.experiment_classify, a.experiment_name, a.chapter_content, a.planned_start_time, a.planned_end_time, a.experiment_use_goods, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, select a.id, a.sub, a.grade_id, a.grade, a.school_year, a.semester, a.experiment_classify, a.experiment_name, a.chapter_content, a.planned_start_time, a.planned_end_time, a.experiment_use_goods, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag,
b.id as sub_id, b.experiment_plan_id as sub_experiment_plan_id, b.class_id as sub_class_id, b.del_flag as sub_del_flag b.id as sub_id, b.experiment_plan_id as sub_experiment_plan_id, b.class_id as sub_class_id, b.del_flag as sub_del_flag
from school_experiment_plan a from school_experiment_plan a
left join school_experiment_plan_class b on b.experiment_plan_id = a.id left join school_experiment_plan_class b on b.experiment_plan_id = a.id
where a.id = #{id} where a.id = #{id}
</select> </select>
<insert id="insertSchoolExperimentPlan" parameterType="SchoolExperimentPlan" useGeneratedKeys="true" keyProperty="id"> <insert id="insertSchoolExperimentPlan" parameterType="SchoolExperimentPlanVo" useGeneratedKeys="true" keyProperty="id">
insert into school_experiment_plan insert into school_experiment_plan
<trim prefix="(" suffix=")" suffixOverrides=","> <trim prefix="(" suffix=")" suffixOverrides=",">
<if test="sub != null">sub,</if> <if test="sub != null">sub,</if>
...@@ -173,10 +204,9 @@ ...@@ -173,10 +204,9 @@
left join school_class_headmaster sch on sch.class_id = sc.id left join school_class_headmaster sch on sch.class_id = sc.id
left join school_grade_mentor sgm on sgm.grade_id = sg.id left join school_grade_mentor sgm on sgm.grade_id = sg.id
WHERE WHERE
sg.del_flag = '0'
<if test="schoolYear != -1">and sg.school_year = #{schoolYear}</if> <if test="schoolYear != -1">and sg.school_year = #{schoolYear}</if>
<if test="userId != null">and scm.teacher_id = #{userId} or sch.teacher_id = #{userId} or sgm.teacher_id = #{userId}</if> <if test="userId != null">and scm.teacher_id = #{userId} or sch.teacher_id = #{userId} or sgm.teacher_id = #{userId}</if>
AND sg.del_flag = '0'
GROUP BY sg.id,sg.school_year,sg.grade_value,sg.grade_year,sg.grade_name GROUP BY sg.id,sg.school_year,sg.grade_value,sg.grade_year,sg.grade_name
ORDER BY sg.grade_year DESC ORDER BY sg.grade_year DESC
</select> </select>
...@@ -184,4 +214,35 @@ ...@@ -184,4 +214,35 @@
<select id="getSchoolClass" parameterType="Long" resultType="Map"> <select id="getSchoolClass" parameterType="Long" resultType="Map">
select id as classId,class_name as className from school_class WHERE grade_id = #{gradeId} and del_flag = '0' select id as classId,class_name as className from school_class WHERE grade_id = #{gradeId} and del_flag = '0'
</select> </select>
<select id="countExperiment" parameterType="SchoolExperimentPlanVo" resultType="Map">
SELECT
ep.id as id, ep.grade_id as gradeId, ep.grade as grade, ep.school_year as schoolYear, ep.semester as semester, ep.experiment_name as experimentName, ep.sub as sub,
COUNT(epc.id) as totalClass,
(SELECT COUNT(tla.id) FROM school_teacher_lab_apply tla WHERE tla.del_flag = '0' AND tla.state = '1' AND tla.lab_class_year_id in (SELECT id FROM school_lab_class_year lcy WHERE lcy.del_flag = '0' AND lcy.experiment_plan_id = ep.id)) as completeClass
FROM
school_experiment_plan ep
LEFT JOIN school_experiment_plan_class epc ON ep.id = epc.experiment_plan_id AND epc.del_flag = '0'
WHERE
ep.del_flag = '0'
<if test="sub != null and sub != ''"> and ep.sub = #{sub}</if>
<if test="gradeId != null "> and ep.grade_id = #{gradeId}</if>
<if test="grade != null and grade != ''"> and ep.grade like concat('%', #{grade}, '%')</if>
<if test="experimentName != null and experimentName != ''"> and ep.experiment_name like concat('%', #{experimentName}, '%')</if>
<if test="schoolYear != null and schoolYear != ''"> and ep.school_year = #{schoolYear}</if>
<if test="semester != null and semester != ''"> and ep.semester = #{semester}</if>
<if test="subs != null ">
and ep.sub in
<foreach item="sub" collection="subs" open="(" separator="," close=")">
#{sub}
</foreach>
</if>
<if test="gradeIds != null">
and ep.grade_id in
<foreach item="gradeId" collection="gradeIds" open="(" separator="," close=")">
#{gradeId}
</foreach>
</if>
GROUP BY ep.id,ep.grade_id,ep.grade,ep.school_year,ep.semester,ep.experiment_name,ep.sub
</select>
</mapper> </mapper>
\ No newline at end of file
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabCompetitionMapper"> <mapper namespace="yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabCompetitionMapper">
<resultMap type="SchoolLabCompetition" id="SchoolLabCompetitionResult"> <resultMap type="SchoolLabCompetitionVo" id="SchoolLabCompetitionVoResult">
<result property="id" column="id" /> <result property="id" column="id" />
<result property="schoolYear" column="school_year" /> <result property="schoolYear" column="school_year" />
<result property="teacherId" column="teacher_id" /> <result property="teacherId" column="teacher_id" />
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
select id, school_year, teacher_id, teacher_name, entry_subject, competition_name, competition_type, competition_level, remark1, remark2, remark3, create_by, create_time, update_by, update_time, del_flag from school_lab_competition select id, school_year, teacher_id, teacher_name, entry_subject, competition_name, competition_type, competition_level, remark1, remark2, remark3, create_by, create_time, update_by, update_time, del_flag from school_lab_competition
</sql> </sql>
<select id="selectSchoolLabCompetitionList" parameterType="SchoolLabCompetition" resultMap="SchoolLabCompetitionResult"> <select id="selectSchoolLabCompetitionList" parameterType="SchoolLabCompetitionVo" resultMap="SchoolLabCompetitionVoResult">
<include refid="selectSchoolLabCompetitionVo"/> <include refid="selectSchoolLabCompetitionVo"/>
<where> <where>
del_flag = '0' del_flag = '0'
...@@ -42,14 +42,15 @@ ...@@ -42,14 +42,15 @@
<if test="remark2 != null and remark2 != ''"> and remark2 = #{remark2}</if> <if test="remark2 != null and remark2 != ''"> and remark2 = #{remark2}</if>
<if test="remark3 != null and remark3 != ''"> and remark3 = #{remark3}</if> <if test="remark3 != null and remark3 != ''"> and remark3 = #{remark3}</if>
</where> </where>
order by create_time DESC
</select> </select>
<select id="selectSchoolLabCompetitionById" parameterType="Long" resultMap="SchoolLabCompetitionResult"> <select id="selectSchoolLabCompetitionById" parameterType="Long" resultMap="SchoolLabCompetitionVoResult">
<include refid="selectSchoolLabCompetitionVo"/> <include refid="selectSchoolLabCompetitionVo"/>
where id = #{id} where id = #{id}
</select> </select>
<insert id="insertSchoolLabCompetition" parameterType="SchoolLabCompetition" useGeneratedKeys="true" keyProperty="id"> <insert id="insertSchoolLabCompetition" parameterType="SchoolLabCompetitionVo" useGeneratedKeys="true" keyProperty="id">
insert into school_lab_competition insert into school_lab_competition
<trim prefix="(" suffix=")" suffixOverrides=","> <trim prefix="(" suffix=")" suffixOverrides=",">
<if test="schoolYear != null">school_year,</if> <if test="schoolYear != null">school_year,</if>
...@@ -87,7 +88,7 @@ ...@@ -87,7 +88,7 @@
</trim> </trim>
</insert> </insert>
<update id="updateSchoolLabCompetition" parameterType="SchoolLabCompetition"> <update id="updateSchoolLabCompetition" parameterType="SchoolLabCompetitionVo">
update school_lab_competition update school_lab_competition
<trim prefix="SET" suffixOverrides=","> <trim prefix="SET" suffixOverrides=",">
<if test="schoolYear != null">school_year = #{schoolYear},</if> <if test="schoolYear != null">school_year = #{schoolYear},</if>
...@@ -119,4 +120,22 @@ ...@@ -119,4 +120,22 @@
#{id} #{id}
</foreach> </foreach>
</update> </update>
<insert id="batchSchoolAccessory">
insert into school_accessory( id, business_id, module_name, accessory_type, accessory_url, accessory_name, create_by,create_time) values
<foreach item="item" index="index" collection="list" separator=",">
( 0, #{item.businessId}, #{item.moduleName}, #{item.accessoryType}, #{item.accessoryUrl}, #{item.accessoryName}, #{item.createBy}, #{item.createTime})
</foreach>
</insert>
<delete id="deleteSchoolAccessoryByBusinessIds" parameterType="String">
delete from school_accessory where accessory_type = "证书照片" and business_id in
<foreach item="businessId" collection="array" open="(" separator="," close=")">
#{businessId}
</foreach>
</delete>
<delete id="deleteSchoolAccessoryByBusinessId" parameterType="Long">
delete from school_accessory where accessory_type = "证书照片" and business_id = #{businessId}
</delete>
</mapper> </mapper>
\ No newline at end of file
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabMapper"> <mapper namespace="yangtz.cs.liu.campus.mapper.schoolLab.SchoolLabMapper">
<resultMap type="SchoolLab" id="SchoolLabResult"> <resultMap type="SchoolLabVo" id="SchoolLabVoResult">
<result property="id" column="id" /> <result property="id" column="id" />
<result property="labName" column="lab_name" /> <result property="labName" column="lab_name" />
<result property="labSub" column="lab_sub" /> <result property="labSub" column="lab_sub" />
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
select id, lab_name, lab_sub, in_charge_id, in_charge_name, lab_state, lab_use_goods, create_by, create_time, update_by, update_time, del_flag from school_lab select id, lab_name, lab_sub, in_charge_id, in_charge_name, lab_state, lab_use_goods, create_by, create_time, update_by, update_time, del_flag from school_lab
</sql> </sql>
<select id="selectSchoolLabList" parameterType="SchoolLab" resultMap="SchoolLabResult"> <select id="selectSchoolLabList" parameterType="SchoolLabVo" resultMap="SchoolLabVoResult">
<include refid="selectSchoolLabVo"/> <include refid="selectSchoolLabVo"/>
<where> <where>
del_flag = '0' del_flag = '0'
...@@ -33,10 +33,17 @@ ...@@ -33,10 +33,17 @@
<if test="inChargeName != null and inChargeName != ''"> and in_charge_name like concat('%', #{inChargeName}, '%')</if> <if test="inChargeName != null and inChargeName != ''"> and in_charge_name like concat('%', #{inChargeName}, '%')</if>
<if test="labState != null and labState != ''"> and lab_state = #{labState}</if> <if test="labState != null and labState != ''"> and lab_state = #{labState}</if>
<if test="labUseGoods != null and labUseGoods != ''"> and lab_use_goods = #{labUseGoods}</if> <if test="labUseGoods != null and labUseGoods != ''"> and lab_use_goods = #{labUseGoods}</if>
<if test="labSubs != null">
and lab_sub in
<foreach item="labSub" collection="labSubs" open="(" separator="," close=")">
#{labSub}
</foreach>
</if>
</where> </where>
order by create_time DESC
</select> </select>
<select id="selectSchoolLabById" parameterType="Long" resultMap="SchoolLabResult"> <select id="selectSchoolLabById" parameterType="Long" resultMap="SchoolLabVoResult">
<include refid="selectSchoolLabVo"/> <include refid="selectSchoolLabVo"/>
where id = #{id} where id = #{id}
</select> </select>
...@@ -112,6 +119,7 @@ ...@@ -112,6 +119,7 @@
r.role_key = "phy_lab_admin" r.role_key = "phy_lab_admin"
or r.role_key = "che_lab_admin" or r.role_key = "che_lab_admin"
or r.role_key = "bio_lab_admin" or r.role_key = "bio_lab_admin"
group by u.user_id,u.user_name
</select> </select>
<select id="getLabAdmin" parameterType="String" resultType="Map"> <select id="getLabAdmin" parameterType="String" resultType="Map">
......
...@@ -4,19 +4,18 @@ ...@@ -4,19 +4,18 @@
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherExperimentApplyMapper"> <mapper namespace="yangtz.cs.liu.campus.mapper.schoolLab.SchoolTeacherExperimentApplyMapper">
<resultMap type="SchoolTeacherExperimentApply" id="SchoolTeacherExperimentApplyResult"> <resultMap type="SchoolTeacherExperimentApplyVo" id="SchoolTeacherExperimentApplyVoResult">
<result property="id" column="id" /> <result property="id" column="id" />
<result property="sub" column="sub" /> <result property="sub" column="sub" />
<result property="gradeId" column="grade_id" /> <result property="gradeId" column="grade_id" />
<result property="grade" column="grade" /> <result property="grade" column="grade" />
<result property="schoolYear" column="school_year" /> <result property="schoolYear" column="school_year" />
<result property="semester" column="semester" /> <result property="semester" column="semester" />
<result property="plannedTime" column="planned_time" /> <result property="plannedStartTime" column="planned_start_time" />
<result property="plannedEndTime" column="planned_end_time" />
<result property="experimentName" column="experiment_name" /> <result property="experimentName" column="experiment_name" />
<result property="experimentClassify" column="experiment_classify" /> <result property="experimentClassify" column="experiment_classify" />
<result property="experimentUseGoods" column="experiment_use_goods" /> <result property="experimentUseGoods" column="experiment_use_goods" />
<result property="labId" column="lab_id" />
<result property="labName" column="lab_name" />
<result property="declareState" column="declare_state" /> <result property="declareState" column="declare_state" />
<result property="applyId" column="apply_id" /> <result property="applyId" column="apply_id" />
<result property="applyName" column="apply_name" /> <result property="applyName" column="apply_name" />
...@@ -29,10 +28,10 @@ ...@@ -29,10 +28,10 @@
</resultMap> </resultMap>
<sql id="selectSchoolTeacherExperimentApplyVo"> <sql id="selectSchoolTeacherExperimentApplyVo">
select id, sub, grade_id, grade, school_year, semester, planned_time, experiment_name, experiment_classify, experiment_use_goods, lab_id, lab_name, declare_state, apply_id, apply_name, apply_time, create_by, create_time, update_by, update_time, del_flag from school_teacher_experiment_apply select id, sub, grade_id, grade, school_year, semester, planned_start_time, planned_end_time, experiment_name, experiment_classify, experiment_use_goods, declare_state, apply_id, apply_name, apply_time, create_by, create_time, update_by, update_time, del_flag from school_teacher_experiment_apply
</sql> </sql>
<select id="selectSchoolTeacherExperimentApplyList" parameterType="SchoolTeacherExperimentApply" resultMap="SchoolTeacherExperimentApplyResult"> <select id="selectSchoolTeacherExperimentApplyList" parameterType="SchoolTeacherExperimentApplyVo" resultMap="SchoolTeacherExperimentApplyVoResult">
<include refid="selectSchoolTeacherExperimentApplyVo"/> <include refid="selectSchoolTeacherExperimentApplyVo"/>
<where> <where>
del_flag = '0' del_flag = '0'
...@@ -41,25 +40,32 @@ ...@@ -41,25 +40,32 @@
<if test="grade != null and grade != ''"> and grade = #{grade}</if> <if test="grade != null and grade != ''"> and grade = #{grade}</if>
<if test="schoolYear != null and schoolYear != ''"> and school_year = #{schoolYear}</if> <if test="schoolYear != null and schoolYear != ''"> and school_year = #{schoolYear}</if>
<if test="semester != null and semester != ''"> and semester = #{semester}</if> <if test="semester != null and semester != ''"> and semester = #{semester}</if>
<if test="plannedTime != null and plannedTime != ''"> and planned_time = #{plannedTime}</if> <if test="plannedStartTime != null and plannedEndTime != null">
and planned_start_time between #{plannedStartTime} and #{plannedEndTime}
and planned_end_time between #{plannedStartTime} and #{plannedEndTime}
</if>
<if test="experimentName != null and experimentName != ''"> and experiment_name like concat('%', #{experimentName}, '%')</if> <if test="experimentName != null and experimentName != ''"> and experiment_name like concat('%', #{experimentName}, '%')</if>
<if test="experimentClassify != null and experimentClassify != ''"> and experiment_classify = #{experimentClassify}</if> <if test="experimentClassify != null and experimentClassify != ''"> and experiment_classify = #{experimentClassify}</if>
<if test="experimentUseGoods != null and experimentUseGoods != ''"> and experiment_use_goods = #{experimentUseGoods}</if> <if test="experimentUseGoods != null and experimentUseGoods != ''"> and experiment_use_goods = #{experimentUseGoods}</if>
<if test="labId != null and labId != ''"> and lab_id = #{labId}</if>
<if test="labName != null and labName != ''"> and lab_name like concat('%', #{labName}, '%')</if>
<if test="declareState != null and declareState != ''"> and declare_state = #{declareState}</if> <if test="declareState != null and declareState != ''"> and declare_state = #{declareState}</if>
<if test="applyId != null "> and apply_id = #{applyId}</if> <if test="applyId != null "> and apply_id = #{applyId}</if>
<if test="applyName != null and applyName != ''"> and apply_name like concat('%', #{applyName}, '%')</if> <if test="applyName != null and applyName != ''"> and apply_name like concat('%', #{applyName}, '%')</if>
<if test="applyTime != null "> and apply_time = #{applyTime}</if> <if test="applyTime != null "> and apply_time = #{applyTime}</if>
<if test="subs != null ">
and sub in
<foreach item="sub" collection="subs" open="(" separator="," close=")">
#{sub}
</foreach>
</if>
</where> </where>
</select> </select>
<select id="selectSchoolTeacherExperimentApplyById" parameterType="Long" resultMap="SchoolTeacherExperimentApplyResult"> <select id="selectSchoolTeacherExperimentApplyById" parameterType="Long" resultMap="SchoolTeacherExperimentApplyVoResult">
<include refid="selectSchoolTeacherExperimentApplyVo"/> <include refid="selectSchoolTeacherExperimentApplyVo"/>
where id = #{id} where id = #{id}
</select> </select>
<insert id="insertSchoolTeacherExperimentApply" parameterType="SchoolTeacherExperimentApply" useGeneratedKeys="true" keyProperty="id"> <insert id="insertSchoolTeacherExperimentApply" parameterType="SchoolTeacherExperimentApplyVo" useGeneratedKeys="true" keyProperty="id">
insert into school_teacher_experiment_apply insert into school_teacher_experiment_apply
<trim prefix="(" suffix=")" suffixOverrides=","> <trim prefix="(" suffix=")" suffixOverrides=",">
<if test="sub != null">sub,</if> <if test="sub != null">sub,</if>
...@@ -67,12 +73,11 @@ ...@@ -67,12 +73,11 @@
<if test="grade != null">grade,</if> <if test="grade != null">grade,</if>
<if test="schoolYear != null">school_year,</if> <if test="schoolYear != null">school_year,</if>
<if test="semester != null">semester,</if> <if test="semester != null">semester,</if>
<if test="plannedTime != null">planned_time,</if> <if test="plannedStartTime != null">planned_start_time,</if>
<if test="plannedEndTime != null">planned_end_time,</if>
<if test="experimentName != null">experiment_name,</if> <if test="experimentName != null">experiment_name,</if>
<if test="experimentClassify != null">experiment_classify,</if> <if test="experimentClassify != null">experiment_classify,</if>
<if test="experimentUseGoods != null">experiment_use_goods,</if> <if test="experimentUseGoods != null">experiment_use_goods,</if>
<if test="labId != null">lab_id,</if>
<if test="labName != null">lab_name,</if>
<if test="declareState != null">declare_state,</if> <if test="declareState != null">declare_state,</if>
<if test="applyId != null">apply_id,</if> <if test="applyId != null">apply_id,</if>
<if test="applyName != null">apply_name,</if> <if test="applyName != null">apply_name,</if>
...@@ -89,12 +94,11 @@ ...@@ -89,12 +94,11 @@
<if test="grade != null">#{grade},</if> <if test="grade != null">#{grade},</if>
<if test="schoolYear != null">#{schoolYear},</if> <if test="schoolYear != null">#{schoolYear},</if>
<if test="semester != null">#{semester},</if> <if test="semester != null">#{semester},</if>
<if test="plannedTime != null">#{plannedTime},</if> <if test="plannedStartTime != null">#{plannedStartTime},</if>
<if test="plannedEndTime != null">#{plannedEndTime},</if>
<if test="experimentName != null">#{experimentName},</if> <if test="experimentName != null">#{experimentName},</if>
<if test="experimentClassify != null">#{experimentClassify},</if> <if test="experimentClassify != null">#{experimentClassify},</if>
<if test="experimentUseGoods != null">#{experimentUseGoods},</if> <if test="experimentUseGoods != null">#{experimentUseGoods},</if>
<if test="labId != null">#{labId},</if>
<if test="labName != null">#{labName},</if>
<if test="declareState != null">#{declareState},</if> <if test="declareState != null">#{declareState},</if>
<if test="applyId != null">#{applyId},</if> <if test="applyId != null">#{applyId},</if>
<if test="applyName != null">#{applyName},</if> <if test="applyName != null">#{applyName},</if>
...@@ -107,7 +111,7 @@ ...@@ -107,7 +111,7 @@
</trim> </trim>
</insert> </insert>
<update id="updateSchoolTeacherExperimentApply" parameterType="SchoolTeacherExperimentApply"> <update id="updateSchoolTeacherExperimentApply" parameterType="SchoolTeacherExperimentApplyVo">
update school_teacher_experiment_apply update school_teacher_experiment_apply
<trim prefix="SET" suffixOverrides=","> <trim prefix="SET" suffixOverrides=",">
<if test="sub != null">sub = #{sub},</if> <if test="sub != null">sub = #{sub},</if>
...@@ -115,12 +119,11 @@ ...@@ -115,12 +119,11 @@
<if test="grade != null">grade = #{grade},</if> <if test="grade != null">grade = #{grade},</if>
<if test="schoolYear != null">school_year = #{schoolYear},</if> <if test="schoolYear != null">school_year = #{schoolYear},</if>
<if test="semester != null">semester = #{semester},</if> <if test="semester != null">semester = #{semester},</if>
<if test="plannedTime != null">planned_time = #{plannedTime},</if> <if test="plannedStartTime != null">planned_start_time = #{plannedStartTime},</if>
<if test="plannedEndTime != null">planned_end_time = #{plannedEndTime},</if>
<if test="experimentName != null">experiment_name = #{experimentName},</if> <if test="experimentName != null">experiment_name = #{experimentName},</if>
<if test="experimentClassify != null">experiment_classify = #{experimentClassify},</if> <if test="experimentClassify != null">experiment_classify = #{experimentClassify},</if>
<if test="experimentUseGoods != null">experiment_use_goods = #{experimentUseGoods},</if> <if test="experimentUseGoods != null">experiment_use_goods = #{experimentUseGoods},</if>
<if test="labId != null">lab_id = #{labId},</if>
<if test="labName != null">lab_name = #{labName},</if>
<if test="declareState != null">declare_state = #{declareState},</if> <if test="declareState != null">declare_state = #{declareState},</if>
<if test="applyId != null">apply_id = #{applyId},</if> <if test="applyId != null">apply_id = #{applyId},</if>
<if test="applyName != null">apply_name = #{applyName},</if> <if test="applyName != null">apply_name = #{applyName},</if>
...@@ -144,4 +147,22 @@ ...@@ -144,4 +147,22 @@
#{id} #{id}
</foreach> </foreach>
</update> </update>
<update id="deleteSchoolTeacherExperimentApplyLabsIds" parameterType="String">
update school_teacher_experiment_apply_labs set del_flag = '1' where teacher_experiment_apply_id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</update>
<delete id="deleteSchoolTeacherExperimentApplyLabsId" parameterType="Long">
delete from school_teacher_experiment_apply_labs where teacher_experiment_apply_id = #{id}
</delete>
<insert id="batchSchoolTeacherExperimentApplyLabs">
insert into school_teacher_experiment_apply_labs( id, teacher_experiment_apply_id, lab_id, lab_name) values
<foreach item="item" index="index" collection="list" separator=",">
( #{item.id}, #{item.teacherExperimentApplyId}, #{item.labId},#{item.labName})
</foreach>
</insert>
</mapper> </mapper>
\ No newline at end of file
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