主题整合学期计划

This commit is contained in:
paidaxing444 2020-08-24 16:31:51 +08:00
parent 357c498b01
commit 90b454d7af
16 changed files with 1999 additions and 0 deletions

View File

@ -0,0 +1,53 @@
import request from '@/utils/request'
// 查询主题整合学期计划列表
export function listTermplan(query) {
return request({
url: '/benyi/themetermplan/list',
method: 'get',
params: query
})
}
// 查询主题整合学期计划详细
export function getTermplan(id) {
return request({
url: '/benyi/themetermplan/' + id,
method: 'get'
})
}
// 新增主题整合学期计划
export function addTermplan(data) {
return request({
url: '/benyi/themetermplan',
method: 'post',
data: data
})
}
// 修改主题整合学期计划
export function updateTermplan(data) {
return request({
url: '/benyi/themetermplan',
method: 'put',
data: data
})
}
// 删除主题整合学期计划
export function delTermplan(id) {
return request({
url: '/benyi/themetermplan/' + id,
method: 'delete'
})
}
// 导出主题整合学期计划
export function exportTermplan(query) {
return request({
url: '/benyi/themetermplan/export',
method: 'get',
params: query
})
}

View File

@ -0,0 +1,53 @@
import request from '@/utils/request'
// 查询主题整合学期计划明细列表
export function listTermplanitem(query) {
return request({
url: '/benyi/themetermplanitem/list',
method: 'get',
params: query
})
}
// 查询主题整合学期计划明细详细
export function getTermplanitem(id) {
return request({
url: '/benyi/themetermplanitem/' + id,
method: 'get'
})
}
// 新增主题整合学期计划明细
export function addTermplanitem(data) {
return request({
url: '/benyi/themetermplanitem',
method: 'post',
data: data
})
}
// 修改主题整合学期计划明细
export function updateTermplanitem(data) {
return request({
url: '/benyi/themetermplanitem',
method: 'put',
data: data
})
}
// 删除主题整合学期计划明细
export function delTermplanitem(id) {
return request({
url: '/benyi/themetermplanitem/' + id,
method: 'delete'
})
}
// 导出主题整合学期计划明细
export function exportTermplanitem(query) {
return request({
url: '/benyi/themetermplanitem/export',
method: 'get',
params: query
})
}

View File

@ -0,0 +1,351 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" :inline="true" label-width="68px">
<el-form-item label="所属计划" prop="tpid">
<el-input
v-model="queryParams.tpid"
placeholder="请输入所属计划"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="主题内容" prop="themeconent">
<el-input
v-model="queryParams.themeconent"
placeholder="请输入主题内容"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="创建人" prop="createuserid">
<el-input
v-model="queryParams.createuserid"
placeholder="请输入创建人"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="创建人" prop="创建时间">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="queryParams.创建时间"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择创建人"
></el-date-picker>
</el-form-item>
<el-form-item label="修改人" prop="updateuserid">
<el-input
v-model="queryParams.updateuserid"
placeholder="请输入修改人"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</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"
v-hasPermi="['benyi:themetermplan:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['benyi:themetermplan:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['benyi:themetermplan:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['benyi:themetermplan:export']"
>导出</el-button>
</el-col>
</el-row>
<el-table
v-loading="loading"
:data="termplanitemList"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="编号" align="center" prop="id" />
<el-table-column label="所属计划" align="center" prop="tpid" />
<el-table-column label="主题内容" align="center" prop="themeconent" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="创建人" align="center" prop="createuserid" />
<el-table-column label="创建人" align="center" prop="创建时间" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.创建时间, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="修改人" align="center" prop="updateuserid" />
<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)"
v-hasPermi="['benyi:themetermplan:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['benyi:themetermplan:remove']"
>删除</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="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="所属计划" prop="tpid">
<el-input v-model="form.tpid" placeholder="请输入所属计划" />
</el-form-item>
<el-form-item label="主题内容" prop="themeconent">
<el-input v-model="form.themeconent" placeholder="请输入主题内容" />
</el-form-item>
<el-form-item label="创建人" prop="createuserid">
<el-input v-model="form.createuserid" placeholder="请输入创建人" />
</el-form-item>
<el-form-item label="创建人" prop="创建时间">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="form.创建时间"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择创建人"
></el-date-picker>
</el-form-item>
<el-form-item label="修改人" prop="updateuserid">
<el-input v-model="form.updateuserid" 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 {
listTermplanitem,
getTermplanitem,
delTermplanitem,
addTermplanitem,
updateTermplanitem,
exportTermplanitem,
} from "@/api/benyi/themetermplanitem";
export default {
name: "Termplanitem",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
total: 0,
//
termplanitemList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
tpid: undefined,
themeconent: undefined,
createuserid: undefined,
创建时间: undefined,
updateuserid: undefined,
},
//
form: {},
//
rules: {},
};
},
created() {
this.getList();
},
methods: {
/** 查询主题整合学期计划明细列表 */
getList() {
this.loading = true;
listTermplanitem(this.queryParams).then((response) => {
this.termplanitemList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
tpid: undefined,
themeconent: undefined,
remark: undefined,
createuserid: undefined,
创建时间: undefined,
updateuserid: undefined,
updateTime: undefined,
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
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 id = row.id || this.ids;
getTermplanitem(id).then((response) => {
this.form = response.data;
this.open = true;
this.title = "修改主题整合学期计划明细";
});
},
/** 提交按钮 */
submitForm: function () {
this.$refs["form"].validate((valid) => {
if (valid) {
if (this.form.id != undefined) {
updateTermplanitem(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("修改成功");
this.open = false;
this.getList();
}
});
} else {
addTermplanitem(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("新增成功");
this.open = false;
this.getList();
}
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$confirm(
'是否确认删除主题整合学期计划明细编号为"' + ids + '"的数据项?',
"警告",
{
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}
)
.then(function () {
return delTermplanitem(ids);
})
.then(() => {
this.getList();
this.msgSuccess("删除成功");
})
.catch(function () {});
},
/** 导出按钮操作 */
handleExport() {
const queryParams = this.queryParams;
this.$confirm("是否确认导出所有主题整合学期计划明细数据项?", "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(function () {
return exportTermplanitem(queryParams);
})
.then((response) => {
this.download(response.msg);
})
.catch(function () {});
},
},
};
</script>

View File

@ -0,0 +1,411 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" :inline="true" label-width="68px">
<el-form-item label="学校id" prop="schoolid">
<el-input
v-model="queryParams.schoolid"
placeholder="请输入学校id"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="班级id" prop="classid">
<el-input
v-model="queryParams.classid"
placeholder="请输入班级id"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入名称"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="月份" prop="month">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="queryParams.month"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择月份"
></el-date-picker>
</el-form-item>
<el-form-item label="学年学期" prop="xnxq">
<el-input
v-model="queryParams.xnxq"
placeholder="请输入学年学期"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="创建人" prop="createuserid">
<el-input
v-model="queryParams.createuserid"
placeholder="请输入创建人"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择状态" clearable size="small">
<el-option label="请选择字典生成" value />
</el-select>
</el-form-item>
<el-form-item label="审批人" prop="spr">
<el-input
v-model="queryParams.spr"
placeholder="请输入审批人"
clearable
size="small"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="审批时间" prop="sptime">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="queryParams.sptime"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择审批时间"
></el-date-picker>
</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"
v-hasPermi="['benyi:themetermplan:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['benyi:themetermplan:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['benyi:themetermplan:remove']"
>删除</el-button>
</el-col>
</el-row>
<el-table v-loading="loading" :data="termplanList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="编号" align="center" prop="id" />
<el-table-column label="学校id" align="center" prop="schoolid" />
<el-table-column label="班级id" align="center" prop="classid" />
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="月份" align="center" prop="startmonth" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.startmonth, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="结束月份" align="center" prop="endmonth" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.endmonth, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="学年学期" align="center" prop="xnxq" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="创建人" align="center" prop="createuserid" />
<el-table-column label="状态" align="center" prop="status" />
<el-table-column label="审批人" align="center" prop="spr" />
<el-table-column label="审批时间" align="center" prop="sptime" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.sptime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<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)"
v-hasPermi="['benyi:themetermplan:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['benyi:themetermplan:remove']"
>删除</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="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="学校id" prop="schoolid">
<el-input v-model="form.schoolid" placeholder="请输入学校id" />
</el-form-item>
<el-form-item label="班级id" prop="classid">
<el-input v-model="form.classid" placeholder="请输入班级id" />
</el-form-item>
<el-form-item label="名称" prop="name">
<el-input v-model="form.name" placeholder="请输入名称" />
</el-form-item>
<el-form-item label="月份" prop="startmonth">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="form.startmonth"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择月份"
></el-date-picker>
</el-form-item>
<el-form-item label="结束月份" prop="endmonth">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="form.endmonth"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择结束月份"
></el-date-picker>
</el-form-item>
<el-form-item label="学年学期" prop="xnxq">
<el-input v-model="form.xnxq" placeholder="请输入学年学期" />
</el-form-item>
<el-form-item label="创建人" prop="createuserid">
<el-input v-model="form.createuserid" placeholder="请输入创建人" />
</el-form-item>
<el-form-item label="状态">
<el-radio-group v-model="form.status">
<el-radio label="1">请选择字典生成</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="审批人" prop="spr">
<el-input v-model="form.spr" placeholder="请输入审批人" />
</el-form-item>
<el-form-item label="审批时间" prop="sptime">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="form.sptime"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择审批时间"
></el-date-picker>
</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 {
listTermplan,
getTermplan,
delTermplan,
addTermplan,
updateTermplan,
} from "@/api/benyi/themetermplan";
export default {
name: "Termplan",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
total: 0,
//
termplanList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
schoolid: undefined,
classid: undefined,
name: undefined,
startmonth: undefined,
endmonth: undefined,
xnxq: undefined,
createuserid: undefined,
status: undefined,
spr: undefined,
sptime: undefined,
},
//
form: {},
//
rules: {},
};
},
created() {
this.getList();
},
methods: {
/** 查询主题整合学期计划列表 */
getList() {
this.loading = true;
listTermplan(this.queryParams).then((response) => {
this.termplanList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
schoolid: undefined,
classid: undefined,
name: undefined,
startmonth: undefined,
endmonth: undefined,
xnxq: undefined,
remark: undefined,
createuserid: undefined,
createTime: undefined,
status: "0",
spr: undefined,
sptime: undefined,
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
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 id = row.id || this.ids;
getTermplan(id).then((response) => {
this.form = response.data;
this.open = true;
this.title = "修改主题整合学期计划";
});
},
/** 提交按钮 */
submitForm: function () {
this.$refs["form"].validate((valid) => {
if (valid) {
if (this.form.id != undefined) {
updateTermplan(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("修改成功");
this.open = false;
this.getList();
}
});
} else {
addTermplan(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("新增成功");
this.open = false;
this.getList();
}
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$confirm(
'是否确认删除主题整合学期计划编号为"' + ids + '"的数据项?',
"警告",
{
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}
)
.then(function () {
return delTermplan(ids);
})
.then(() => {
this.getList();
this.msgSuccess("删除成功");
})
.catch(function () {});
},
},
};
</script>

View File

@ -0,0 +1,103 @@
package com.ruoyi.project.benyi.controller;
import java.util.List;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.ruoyi.framework.aspectj.lang.annotation.Log;
import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
import com.ruoyi.project.benyi.domain.ByThemeTermplan;
import com.ruoyi.project.benyi.service.IByThemeTermplanService;
import com.ruoyi.framework.web.controller.BaseController;
import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.framework.web.page.TableDataInfo;
/**
* 主题整合学期计划Controller
*
* @author tsbz
* @date 2020-08-24
*/
@RestController
@RequestMapping("/benyi/themetermplan")
public class ByThemeTermplanController extends BaseController
{
@Autowired
private IByThemeTermplanService byThemeTermplanService;
/**
* 查询主题整合学期计划列表
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:list')")
@GetMapping("/list")
public TableDataInfo list(ByThemeTermplan byThemeTermplan)
{
startPage();
List<ByThemeTermplan> list = byThemeTermplanService.selectByThemeTermplanList(byThemeTermplan);
return getDataTable(list);
}
/**
* 导出主题整合学期计划列表
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:export')")
@Log(title = "主题整合学期计划", businessType = BusinessType.EXPORT)
@GetMapping("/export")
public AjaxResult export(ByThemeTermplan byThemeTermplan)
{
List<ByThemeTermplan> list = byThemeTermplanService.selectByThemeTermplanList(byThemeTermplan);
ExcelUtil<ByThemeTermplan> util = new ExcelUtil<ByThemeTermplan>(ByThemeTermplan.class);
return util.exportExcel(list, "themetermplan");
}
/**
* 获取主题整合学期计划详细信息
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id)
{
return AjaxResult.success(byThemeTermplanService.selectByThemeTermplanById(id));
}
/**
* 新增主题整合学期计划
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:add')")
@Log(title = "主题整合学期计划", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody ByThemeTermplan byThemeTermplan)
{
return toAjax(byThemeTermplanService.insertByThemeTermplan(byThemeTermplan));
}
/**
* 修改主题整合学期计划
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:edit')")
@Log(title = "主题整合学期计划", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody ByThemeTermplan byThemeTermplan)
{
return toAjax(byThemeTermplanService.updateByThemeTermplan(byThemeTermplan));
}
/**
* 删除主题整合学期计划
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:remove')")
@Log(title = "主题整合学期计划", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{
return toAjax(byThemeTermplanService.deleteByThemeTermplanByIds(ids));
}
}

View File

@ -0,0 +1,97 @@
package com.ruoyi.project.benyi.controller;
import java.util.List;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.ruoyi.framework.aspectj.lang.annotation.Log;
import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
import com.ruoyi.project.benyi.domain.ByThemeTermplanitem;
import com.ruoyi.project.benyi.service.IByThemeTermplanitemService;
import com.ruoyi.framework.web.controller.BaseController;
import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.framework.web.page.TableDataInfo;
/**
* 主题整合学期计划明细Controller
*
* @author tsbz
* @date 2020-08-24
*/
@RestController
@RequestMapping("/benyi/termplanitem")
public class ByThemeTermplanitemController extends BaseController {
@Autowired
private IByThemeTermplanitemService byThemeTermplanitemService;
/**
* 查询主题整合学期计划明细列表
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:list')")
@GetMapping("/list")
public TableDataInfo list(ByThemeTermplanitem byThemeTermplanitem) {
startPage();
List<ByThemeTermplanitem> list = byThemeTermplanitemService.selectByThemeTermplanitemList(byThemeTermplanitem);
return getDataTable(list);
}
/**
* 导出主题整合学期计划明细列表
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:export')")
@Log(title = "主题整合学期计划明细", businessType = BusinessType.EXPORT)
@GetMapping("/export")
public AjaxResult export(ByThemeTermplanitem byThemeTermplanitem) {
List<ByThemeTermplanitem> list = byThemeTermplanitemService.selectByThemeTermplanitemList(byThemeTermplanitem);
ExcelUtil<ByThemeTermplanitem> util = new ExcelUtil<ByThemeTermplanitem>(ByThemeTermplanitem.class);
return util.exportExcel(list, "termplanitem");
}
/**
* 获取主题整合学期计划明细详细信息
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) {
return AjaxResult.success(byThemeTermplanitemService.selectByThemeTermplanitemById(id));
}
/**
* 新增主题整合学期计划明细
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:add')")
@Log(title = "主题整合学期计划明细", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody ByThemeTermplanitem byThemeTermplanitem) {
return toAjax(byThemeTermplanitemService.insertByThemeTermplanitem(byThemeTermplanitem));
}
/**
* 修改主题整合学期计划明细
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:edit')")
@Log(title = "主题整合学期计划明细", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody ByThemeTermplanitem byThemeTermplanitem) {
return toAjax(byThemeTermplanitemService.updateByThemeTermplanitem(byThemeTermplanitem));
}
/**
* 删除主题整合学期计划明细
*/
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:remove')")
@Log(title = "主题整合学期计划明细", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids) {
return toAjax(byThemeTermplanitemService.deleteByThemeTermplanitemByIds(ids));
}
}

View File

@ -0,0 +1,194 @@
package com.ruoyi.project.benyi.domain;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.BaseEntity;
/**
* 主题整合学期计划对象 by_theme_termplan
*
* @author tsbz
* @date 2020-08-24
*/
public class ByThemeTermplan extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 编号
*/
private String id;
/**
* 学校id
*/
@Excel(name = "学校id")
private Long schoolid;
/**
* 班级id
*/
@Excel(name = "班级id")
private String classid;
/**
* 名称
*/
@Excel(name = "名称")
private String name;
/**
* 月份
*/
@JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "月份", width = 30, dateFormat = "yyyy-MM-dd")
private Date startmonth;
/**
* 结束月份
*/
@JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "结束月份", width = 30, dateFormat = "yyyy-MM-dd")
private Date endmonth;
/**
* 学年学期
*/
@Excel(name = "学年学期")
private String xnxq;
/**
* 创建人
*/
@Excel(name = "创建人")
private Long createuserid;
/**
* 状态
*/
@Excel(name = "状态")
private String status;
/**
* 审批人
*/
@Excel(name = "审批人")
private Long spr;
/**
* 审批时间
*/
@JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "审批时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date sptime;
public void setId(String id) {
this.id = id;
}
public String getId() {
return id;
}
public void setSchoolid(Long schoolid) {
this.schoolid = schoolid;
}
public Long getSchoolid() {
return schoolid;
}
public void setClassid(String classid) {
this.classid = classid;
}
public String getClassid() {
return classid;
}
public void setName(String name) {
this.name = name;
}
public String getName() {
return name;
}
public void setStartmonth(Date startmonth) {
this.startmonth = startmonth;
}
public Date getStartmonth() {
return startmonth;
}
public void setEndmonth(Date endmonth) {
this.endmonth = endmonth;
}
public Date getEndmonth() {
return endmonth;
}
public void setXnxq(String xnxq) {
this.xnxq = xnxq;
}
public String getXnxq() {
return xnxq;
}
public void setCreateuserid(Long createuserid) {
this.createuserid = createuserid;
}
public Long getCreateuserid() {
return createuserid;
}
public void setStatus(String status) {
this.status = status;
}
public String getStatus() {
return status;
}
public void setSpr(Long spr) {
this.spr = spr;
}
public Long getSpr() {
return spr;
}
public void setSptime(Date sptime) {
this.sptime = sptime;
}
public Date getSptime() {
return sptime;
}
@Override
public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("schoolid", getSchoolid())
.append("classid", getClassid())
.append("name", getName())
.append("startmonth", getStartmonth())
.append("endmonth", getEndmonth())
.append("xnxq", getXnxq())
.append("remark", getRemark())
.append("createuserid", getCreateuserid())
.append("createTime", getCreateTime())
.append("status", getStatus())
.append("spr", getSpr())
.append("sptime", getSptime())
.toString();
}
}

View File

@ -0,0 +1,117 @@
package com.ruoyi.project.benyi.domain;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.BaseEntity;
/**
* 主题整合学期计划明细对象 by_theme_termplanitem
*
* @author tsbz
* @date 2020-08-24
*/
public class ByThemeTermplanitem extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 编号
*/
private Long id;
/**
* 所属计划
*/
@Excel(name = "所属计划")
private String tpid;
/**
* 主题内容
*/
@Excel(name = "主题内容")
private String themeconent;
/**
* 创建人
*/
@Excel(name = "创建人")
private Long createuserid;
/**
* $column.columnComment
*/
@JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "创建人", width = 30, dateFormat = "yyyy-MM-dd")
private Date 创建时间;
/**
* 修改人
*/
@Excel(name = "修改人")
private Long updateuserid;
public void setId(Long id) {
this.id = id;
}
public Long getId() {
return id;
}
public void setTpid(String tpid) {
this.tpid = tpid;
}
public String getTpid() {
return tpid;
}
public void setThemeconent(String themeconent) {
this.themeconent = themeconent;
}
public String getThemeconent() {
return themeconent;
}
public void setCreateuserid(Long createuserid) {
this.createuserid = createuserid;
}
public Long getCreateuserid() {
return createuserid;
}
public void set创建时间(Date 创建时间) {
this.创建时间 = 创建时间;
}
public Date get创建时间() {
return 创建时间;
}
public void setUpdateuserid(Long updateuserid) {
this.updateuserid = updateuserid;
}
public Long getUpdateuserid() {
return updateuserid;
}
@Override
public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("tpid", getTpid())
.append("themeconent", getThemeconent())
.append("remark", getRemark())
.append("createuserid", getCreateuserid())
.append("创建时间", get创建时间())
.append("updateuserid", getUpdateuserid())
.append("updateTime", getUpdateTime())
.toString();
}
}

View File

@ -0,0 +1,61 @@
package com.ruoyi.project.benyi.mapper;
import java.util.List;
import com.ruoyi.project.benyi.domain.ByThemeTermplan;
/**
* 主题整合学期计划Mapper接口
*
* @author tsbz
* @date 2020-08-24
*/
public interface ByThemeTermplanMapper {
/**
* 查询主题整合学期计划
*
* @param id 主题整合学期计划ID
* @return 主题整合学期计划
*/
public ByThemeTermplan selectByThemeTermplanById(Long id);
/**
* 查询主题整合学期计划列表
*
* @param byThemeTermplan 主题整合学期计划
* @return 主题整合学期计划集合
*/
public List<ByThemeTermplan> selectByThemeTermplanList(ByThemeTermplan byThemeTermplan);
/**
* 新增主题整合学期计划
*
* @param byThemeTermplan 主题整合学期计划
* @return 结果
*/
public int insertByThemeTermplan(ByThemeTermplan byThemeTermplan);
/**
* 修改主题整合学期计划
*
* @param byThemeTermplan 主题整合学期计划
* @return 结果
*/
public int updateByThemeTermplan(ByThemeTermplan byThemeTermplan);
/**
* 删除主题整合学期计划
*
* @param id 主题整合学期计划ID
* @return 结果
*/
public int deleteByThemeTermplanById(Long id);
/**
* 批量删除主题整合学期计划
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public int deleteByThemeTermplanByIds(Long[] ids);
}

View File

@ -0,0 +1,61 @@
package com.ruoyi.project.benyi.mapper;
import java.util.List;
import com.ruoyi.project.benyi.domain.ByThemeTermplanitem;
/**
* 主题整合学期计划明细Mapper接口
*
* @author tsbz
* @date 2020-08-24
*/
public interface ByThemeTermplanitemMapper {
/**
* 查询主题整合学期计划明细
*
* @param id 主题整合学期计划明细ID
* @return 主题整合学期计划明细
*/
public ByThemeTermplanitem selectByThemeTermplanitemById(Long id);
/**
* 查询主题整合学期计划明细列表
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 主题整合学期计划明细集合
*/
public List<ByThemeTermplanitem> selectByThemeTermplanitemList(ByThemeTermplanitem byThemeTermplanitem);
/**
* 新增主题整合学期计划明细
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 结果
*/
public int insertByThemeTermplanitem(ByThemeTermplanitem byThemeTermplanitem);
/**
* 修改主题整合学期计划明细
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 结果
*/
public int updateByThemeTermplanitem(ByThemeTermplanitem byThemeTermplanitem);
/**
* 删除主题整合学期计划明细
*
* @param id 主题整合学期计划明细ID
* @return 结果
*/
public int deleteByThemeTermplanitemById(Long id);
/**
* 批量删除主题整合学期计划明细
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public int deleteByThemeTermplanitemByIds(Long[] ids);
}

View File

@ -0,0 +1,61 @@
package com.ruoyi.project.benyi.service;
import java.util.List;
import com.ruoyi.project.benyi.domain.ByThemeTermplan;
/**
* 主题整合学期计划Service接口
*
* @author tsbz
* @date 2020-08-24
*/
public interface IByThemeTermplanService {
/**
* 查询主题整合学期计划
*
* @param id 主题整合学期计划ID
* @return 主题整合学期计划
*/
public ByThemeTermplan selectByThemeTermplanById(Long id);
/**
* 查询主题整合学期计划列表
*
* @param byThemeTermplan 主题整合学期计划
* @return 主题整合学期计划集合
*/
public List<ByThemeTermplan> selectByThemeTermplanList(ByThemeTermplan byThemeTermplan);
/**
* 新增主题整合学期计划
*
* @param byThemeTermplan 主题整合学期计划
* @return 结果
*/
public int insertByThemeTermplan(ByThemeTermplan byThemeTermplan);
/**
* 修改主题整合学期计划
*
* @param byThemeTermplan 主题整合学期计划
* @return 结果
*/
public int updateByThemeTermplan(ByThemeTermplan byThemeTermplan);
/**
* 批量删除主题整合学期计划
*
* @param ids 需要删除的主题整合学期计划ID
* @return 结果
*/
public int deleteByThemeTermplanByIds(Long[] ids);
/**
* 删除主题整合学期计划信息
*
* @param id 主题整合学期计划ID
* @return 结果
*/
public int deleteByThemeTermplanById(Long id);
}

View File

@ -0,0 +1,61 @@
package com.ruoyi.project.benyi.service;
import java.util.List;
import com.ruoyi.project.benyi.domain.ByThemeTermplanitem;
/**
* 主题整合学期计划明细Service接口
*
* @author tsbz
* @date 2020-08-24
*/
public interface IByThemeTermplanitemService {
/**
* 查询主题整合学期计划明细
*
* @param id 主题整合学期计划明细ID
* @return 主题整合学期计划明细
*/
public ByThemeTermplanitem selectByThemeTermplanitemById(Long id);
/**
* 查询主题整合学期计划明细列表
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 主题整合学期计划明细集合
*/
public List<ByThemeTermplanitem> selectByThemeTermplanitemList(ByThemeTermplanitem byThemeTermplanitem);
/**
* 新增主题整合学期计划明细
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 结果
*/
public int insertByThemeTermplanitem(ByThemeTermplanitem byThemeTermplanitem);
/**
* 修改主题整合学期计划明细
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 结果
*/
public int updateByThemeTermplanitem(ByThemeTermplanitem byThemeTermplanitem);
/**
* 批量删除主题整合学期计划明细
*
* @param ids 需要删除的主题整合学期计划明细ID
* @return 结果
*/
public int deleteByThemeTermplanitemByIds(Long[] ids);
/**
* 删除主题整合学期计划明细信息
*
* @param id 主题整合学期计划明细ID
* @return 结果
*/
public int deleteByThemeTermplanitemById(Long id);
}

View File

@ -0,0 +1,89 @@
package com.ruoyi.project.benyi.service.impl;
import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.benyi.mapper.ByThemeTermplanMapper;
import com.ruoyi.project.benyi.domain.ByThemeTermplan;
import com.ruoyi.project.benyi.service.IByThemeTermplanService;
/**
* 主题整合学期计划Service业务层处理
*
* @author tsbz
* @date 2020-08-24
*/
@Service
public class ByThemeTermplanServiceImpl implements IByThemeTermplanService {
@Autowired
private ByThemeTermplanMapper byThemeTermplanMapper;
/**
* 查询主题整合学期计划
*
* @param id 主题整合学期计划ID
* @return 主题整合学期计划
*/
@Override
public ByThemeTermplan selectByThemeTermplanById(Long id) {
return byThemeTermplanMapper.selectByThemeTermplanById(id);
}
/**
* 查询主题整合学期计划列表
*
* @param byThemeTermplan 主题整合学期计划
* @return 主题整合学期计划
*/
@Override
public List<ByThemeTermplan> selectByThemeTermplanList(ByThemeTermplan byThemeTermplan) {
return byThemeTermplanMapper.selectByThemeTermplanList(byThemeTermplan);
}
/**
* 新增主题整合学期计划
*
* @param byThemeTermplan 主题整合学期计划
* @return 结果
*/
@Override
public int insertByThemeTermplan(ByThemeTermplan byThemeTermplan) {
byThemeTermplan.setCreateTime(DateUtils.getNowDate());
return byThemeTermplanMapper.insertByThemeTermplan(byThemeTermplan);
}
/**
* 修改主题整合学期计划
*
* @param byThemeTermplan 主题整合学期计划
* @return 结果
*/
@Override
public int updateByThemeTermplan(ByThemeTermplan byThemeTermplan) {
return byThemeTermplanMapper.updateByThemeTermplan(byThemeTermplan);
}
/**
* 批量删除主题整合学期计划
*
* @param ids 需要删除的主题整合学期计划ID
* @return 结果
*/
@Override
public int deleteByThemeTermplanByIds(Long[] ids) {
return byThemeTermplanMapper.deleteByThemeTermplanByIds(ids);
}
/**
* 删除主题整合学期计划信息
*
* @param id 主题整合学期计划ID
* @return 结果
*/
@Override
public int deleteByThemeTermplanById(Long id) {
return byThemeTermplanMapper.deleteByThemeTermplanById(id);
}
}

View File

@ -0,0 +1,89 @@
package com.ruoyi.project.benyi.service.impl;
import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.benyi.mapper.ByThemeTermplanitemMapper;
import com.ruoyi.project.benyi.domain.ByThemeTermplanitem;
import com.ruoyi.project.benyi.service.IByThemeTermplanitemService;
/**
* 主题整合学期计划明细Service业务层处理
*
* @author tsbz
* @date 2020-08-24
*/
@Service
public class ByThemeTermplanitemServiceImpl implements IByThemeTermplanitemService {
@Autowired
private ByThemeTermplanitemMapper byThemeTermplanitemMapper;
/**
* 查询主题整合学期计划明细
*
* @param id 主题整合学期计划明细ID
* @return 主题整合学期计划明细
*/
@Override
public ByThemeTermplanitem selectByThemeTermplanitemById(Long id) {
return byThemeTermplanitemMapper.selectByThemeTermplanitemById(id);
}
/**
* 查询主题整合学期计划明细列表
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 主题整合学期计划明细
*/
@Override
public List<ByThemeTermplanitem> selectByThemeTermplanitemList(ByThemeTermplanitem byThemeTermplanitem) {
return byThemeTermplanitemMapper.selectByThemeTermplanitemList(byThemeTermplanitem);
}
/**
* 新增主题整合学期计划明细
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 结果
*/
@Override
public int insertByThemeTermplanitem(ByThemeTermplanitem byThemeTermplanitem) {
return byThemeTermplanitemMapper.insertByThemeTermplanitem(byThemeTermplanitem);
}
/**
* 修改主题整合学期计划明细
*
* @param byThemeTermplanitem 主题整合学期计划明细
* @return 结果
*/
@Override
public int updateByThemeTermplanitem(ByThemeTermplanitem byThemeTermplanitem) {
byThemeTermplanitem.setUpdateTime(DateUtils.getNowDate());
return byThemeTermplanitemMapper.updateByThemeTermplanitem(byThemeTermplanitem);
}
/**
* 批量删除主题整合学期计划明细
*
* @param ids 需要删除的主题整合学期计划明细ID
* @return 结果
*/
@Override
public int deleteByThemeTermplanitemByIds(Long[] ids) {
return byThemeTermplanitemMapper.deleteByThemeTermplanitemByIds(ids);
}
/**
* 删除主题整合学期计划明细信息
*
* @param id 主题整合学期计划明细ID
* @return 结果
*/
@Override
public int deleteByThemeTermplanitemById(Long id) {
return byThemeTermplanitemMapper.deleteByThemeTermplanitemById(id);
}
}

View File

@ -0,0 +1,112 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.project.benyi.mapper.ByThemeTermplanMapper">
<resultMap type="ByThemeTermplan" id="ByThemeTermplanResult">
<result property="id" column="id"/>
<result property="schoolid" column="schoolid"/>
<result property="classid" column="classid"/>
<result property="name" column="name"/>
<result property="startmonth" column="startmonth"/>
<result property="endmonth" column="endmonth"/>
<result property="xnxq" column="xnxq"/>
<result property="remark" column="remark"/>
<result property="createuserid" column="createuserid"/>
<result property="createTime" column="create_time"/>
<result property="status" column="status"/>
<result property="spr" column="spr"/>
<result property="sptime" column="sptime"/>
</resultMap>
<sql id="selectByThemeTermplanVo">
select id, schoolid, classid, name, startmonth, endmonth, xnxq, remark, createuserid, create_time, status, spr, sptime from by_theme_termplan
</sql>
<select id="selectByThemeTermplanList" parameterType="ByThemeTermplan" resultMap="ByThemeTermplanResult">
<include refid="selectByThemeTermplanVo"/>
<where>
<if test="schoolid != null ">and schoolid = #{schoolid}</if>
<if test="classid != null and classid != ''">and classid = #{classid}</if>
<if test="name != null and name != ''">and name like concat('%', #{name}, '%')</if>
<if test="startmonth != null ">and startmonth = #{startmonth}</if>
<if test="endmonth != null ">and endmonth = #{endmonth}</if>
<if test="xnxq != null and xnxq != ''">and xnxq = #{xnxq}</if>
<if test="createuserid != null ">and createuserid = #{createuserid}</if>
<if test="status != null and status != ''">and status = #{status}</if>
<if test="spr != null ">and spr = #{spr}</if>
<if test="sptime != null ">and sptime = #{sptime}</if>
</where>
</select>
<select id="selectByThemeTermplanById" parameterType="String" resultMap="ByThemeTermplanResult">
<include refid="selectByThemeTermplanVo"/>
where id = #{id}
</select>
<insert id="insertByThemeTermplan" parameterType="ByThemeTermplan">
insert into by_theme_termplan
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null and id != ''">id,</if>
<if test="schoolid != null ">schoolid,</if>
<if test="classid != null and classid != ''">classid,</if>
<if test="name != null and name != ''">name,</if>
<if test="startmonth != null ">startmonth,</if>
<if test="endmonth != null ">endmonth,</if>
<if test="xnxq != null and xnxq != ''">xnxq,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="createuserid != null ">createuserid,</if>
<if test="createTime != null ">create_time,</if>
<if test="status != null and status != ''">status,</if>
<if test="spr != null ">spr,</if>
<if test="sptime != null ">sptime,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null and id != ''">#{id},</if>
<if test="schoolid != null ">#{schoolid},</if>
<if test="classid != null and classid != ''">#{classid},</if>
<if test="name != null and name != ''">#{name},</if>
<if test="startmonth != null ">#{startmonth},</if>
<if test="endmonth != null ">#{endmonth},</if>
<if test="xnxq != null and xnxq != ''">#{xnxq},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="createuserid != null ">#{createuserid},</if>
<if test="createTime != null ">#{createTime},</if>
<if test="status != null and status != ''">#{status},</if>
<if test="spr != null ">#{spr},</if>
<if test="sptime != null ">#{sptime},</if>
</trim>
</insert>
<update id="updateByThemeTermplan" parameterType="ByThemeTermplan">
update by_theme_termplan
<trim prefix="SET" suffixOverrides=",">
<if test="schoolid != null ">schoolid = #{schoolid},</if>
<if test="classid != null and classid != ''">classid = #{classid},</if>
<if test="name != null and name != ''">name = #{name},</if>
<if test="startmonth != null ">startmonth = #{startmonth},</if>
<if test="endmonth != null ">endmonth = #{endmonth},</if>
<if test="xnxq != null and xnxq != ''">xnxq = #{xnxq},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="createuserid != null ">createuserid = #{createuserid},</if>
<if test="createTime != null ">create_time = #{createTime},</if>
<if test="status != null and status != ''">status = #{status},</if>
<if test="spr != null ">spr = #{spr},</if>
<if test="sptime != null ">sptime = #{sptime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteByThemeTermplanById" parameterType="String">
delete from by_theme_termplan where id = #{id}
</delete>
<delete id="deleteByThemeTermplanByIds" parameterType="String">
delete from by_theme_termplan where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>

View File

@ -0,0 +1,86 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.project.benyi.mapper.ByThemeTermplanitemMapper">
<resultMap type="ByThemeTermplanitem" id="ByThemeTermplanitemResult">
<result property="id" column="id"/>
<result property="tpid" column="tpid"/>
<result property="themeconent" column="themeconent"/>
<result property="remark" column="remark"/>
<result property="createuserid" column="createuserid"/>
<result property="创建时间" column="创建时间"/>
<result property="updateuserid" column="updateuserid"/>
<result property="updateTime" column="update_time"/>
</resultMap>
<sql id="selectByThemeTermplanitemVo">
select id, tpid, themeconent, remark, createuserid, 创建时间, updateuserid, update_time from by_theme_termplanitem
</sql>
<select id="selectByThemeTermplanitemList" parameterType="ByThemeTermplanitem"
resultMap="ByThemeTermplanitemResult">
<include refid="selectByThemeTermplanitemVo"/>
<where>
<if test="tpid != null and tpid != ''">and tpid = #{tpid}</if>
<if test="themeconent != null and themeconent != ''">and themeconent = #{themeconent}</if>
<if test="createuserid != null ">and createuserid = #{createuserid}</if>
<if test="创建时间 != null ">and 创建时间 = #{创建时间}</if>
<if test="updateuserid != null ">and updateuserid = #{updateuserid}</if>
</where>
</select>
<select id="selectByThemeTermplanitemById" parameterType="Long" resultMap="ByThemeTermplanitemResult">
<include refid="selectByThemeTermplanitemVo"/>
where id = #{id}
</select>
<insert id="insertByThemeTermplanitem" parameterType="ByThemeTermplanitem" useGeneratedKeys="true" keyProperty="id">
insert into by_theme_termplanitem
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="tpid != null and tpid != ''">tpid,</if>
<if test="themeconent != null and themeconent != ''">themeconent,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="createuserid != null ">createuserid,</if>
<if test="创建时间 != null ">创建时间,</if>
<if test="updateuserid != null ">updateuserid,</if>
<if test="updateTime != null ">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="tpid != null and tpid != ''">#{tpid},</if>
<if test="themeconent != null and themeconent != ''">#{themeconent},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="createuserid != null ">#{createuserid},</if>
<if test="创建时间 != null ">#{创建时间},</if>
<if test="updateuserid != null ">#{updateuserid},</if>
<if test="updateTime != null ">#{updateTime},</if>
</trim>
</insert>
<update id="updateByThemeTermplanitem" parameterType="ByThemeTermplanitem">
update by_theme_termplanitem
<trim prefix="SET" suffixOverrides=",">
<if test="tpid != null and tpid != ''">tpid = #{tpid},</if>
<if test="themeconent != null and themeconent != ''">themeconent = #{themeconent},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="createuserid != null ">createuserid = #{createuserid},</if>
<if test="创建时间 != null ">创建时间 = #{创建时间},</if>
<if test="updateuserid != null ">updateuserid = #{updateuserid},</if>
<if test="updateTime != null ">update_time = #{updateTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteByThemeTermplanitemById" parameterType="Long">
delete from by_theme_termplanitem where id = #{id}
</delete>
<delete id="deleteByThemeTermplanitemByIds" parameterType="String">
delete from by_theme_termplanitem where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>