学期计划预览
This commit is contained in:
parent
13e47aff77
commit
20f1d72420
@ -337,6 +337,21 @@ export const constantRoutes = [{
|
|||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/benyi_course/themetermplanprint',
|
||||||
|
component: Layout,
|
||||||
|
hidden: true,
|
||||||
|
children: [{
|
||||||
|
path: 'table/:id',
|
||||||
|
component: () =>
|
||||||
|
import('@/views/benyi/themetermplan/table'),
|
||||||
|
name: 'Themetermplan2',
|
||||||
|
meta: {
|
||||||
|
title: '主题整合学期计划(表格)',
|
||||||
|
icon: ''
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
path: '/benyi_course/math',
|
path: '/benyi_course/math',
|
||||||
component: Layout,
|
component: Layout,
|
||||||
|
@ -118,6 +118,13 @@
|
|||||||
v-hasPermi="['benyi:themetermplan:edit']"
|
v-hasPermi="['benyi:themetermplan:edit']"
|
||||||
v-show="isShow(scope.row)"
|
v-show="isShow(scope.row)"
|
||||||
>提交</el-button>
|
>提交</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-view"
|
||||||
|
@click="handleView(scope.row)"
|
||||||
|
v-hasPermi="['benyi:themetermplan:query']"
|
||||||
|
>预览</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
@ -375,15 +382,11 @@ export default {
|
|||||||
/** 删除按钮操作 */
|
/** 删除按钮操作 */
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
const ids = row.id || this.ids;
|
const ids = row.id || this.ids;
|
||||||
this.$confirm(
|
this.$confirm("是否确认删除主题整合学期计划数据项?", "警告", {
|
||||||
'是否确认删除主题整合学期计划数据项?',
|
|
||||||
"警告",
|
|
||||||
{
|
|
||||||
confirmButtonText: "确定",
|
confirmButtonText: "确定",
|
||||||
cancelButtonText: "取消",
|
cancelButtonText: "取消",
|
||||||
type: "warning",
|
type: "warning",
|
||||||
}
|
})
|
||||||
)
|
|
||||||
.then(function () {
|
.then(function () {
|
||||||
return delTermplan(ids);
|
return delTermplan(ids);
|
||||||
})
|
})
|
||||||
@ -414,6 +417,13 @@ export default {
|
|||||||
})
|
})
|
||||||
.catch(function () {});
|
.catch(function () {});
|
||||||
},
|
},
|
||||||
|
/** 预览按钮操作 */
|
||||||
|
handleView(row) {
|
||||||
|
const id = row.id;
|
||||||
|
this.$router.push({
|
||||||
|
path: "/benyi_course/themetermplanprint/table/"+id,
|
||||||
|
});
|
||||||
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
@ -17,7 +17,7 @@
|
|||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<b class="table-title">学期:</b>
|
<b class="table-title">学期:</b>
|
||||||
{{month}}
|
{{xnxqFormat(xnxq)}}
|
||||||
</td>
|
</td>
|
||||||
<td class="w200">
|
<td class="w200">
|
||||||
<b class="table-title">制定人:</b>
|
<b class="table-title">制定人:</b>
|
||||||
@ -29,51 +29,16 @@
|
|||||||
<b>{{h.label}}</b>
|
<b>{{h.label}}</b>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr v-for="item in bodyData.weekplanitemList" :key="item.daytime">
|
<tr v-for="item in bodyData.termplanitemList" :key="item.id">
|
||||||
<td class="align-center">
|
<td class="align-center">
|
||||||
<span>{{item.month}}</span>
|
<span>{{item.month}}</span>
|
||||||
</td>
|
</td>
|
||||||
<td>{{item.theme}}</td>
|
<td class="align-center">{{themeFormat(item.themeconent)}}</td>
|
||||||
<td>{{item.info}}</td>
|
<td>{{item.remark}}</td>
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td colspan="3">
|
|
||||||
<h2 class="title title2">下学期课程计划(2018年3月-2019年3月)</h2>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr class="align-center">
|
|
||||||
<!-- <td v-for="h in headerData" :key="h.title">
|
|
||||||
<b class="table-title">{{h.title}}</b>
|
|
||||||
{{h.name}}
|
|
||||||
</td>-->
|
|
||||||
<td>
|
|
||||||
<b class="table-title">班级:</b>
|
|
||||||
{{classname}}
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<b class="table-title">学期:</b>
|
|
||||||
{{month}}
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<b class="table-title">制定人:</b>
|
|
||||||
{{tbr}}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr class="align-center table-bg">
|
|
||||||
<td v-for="h in bodyData.title" :key="h.prop">
|
|
||||||
<b>{{h.label}}</b>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr v-for="item in bodyData.weekplanitemList" :key="item.daytime">
|
|
||||||
<td class="align-center">
|
|
||||||
<span>{{item.month}}</span>
|
|
||||||
</td>
|
|
||||||
<td>{{item.theme}}</td>
|
|
||||||
<td>{{item.info}}</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="align-center">教学主管审批</td>
|
<td class="align-center">教学主管审批</td>
|
||||||
<td colspan="2">{{bz}}</td>
|
<td colspan="2">{{spyj}}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<!-- <p
|
<!-- <p
|
||||||
@ -84,40 +49,30 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import { listTermplan, getTermplan } from "@/api/benyi/themetermplan";
|
||||||
import {
|
import {
|
||||||
listWeekplanitem,
|
listTermplanitem,
|
||||||
getWeekplanitem,
|
getTermplanitem,
|
||||||
} from "@/api/benyi/themeweekplanitem";
|
} from "@/api/benyi/themetermplanitem";
|
||||||
|
import { listTheme } from "@/api/benyi/theme";
|
||||||
import { listWeekplan, getWeekplan } from "@/api/benyi/themeweekplan";
|
|
||||||
import { listActivityByThemeId } from "@/api/benyi/activity";
|
|
||||||
import { listMonthplan } from "@/api/benyi/thememonthplan";
|
|
||||||
import { listMonthplanitem } from "@/api/benyi/thememonthplanitem";
|
|
||||||
import { listThemeByIds, listThemeByActivityIds } from "@/api/benyi/theme";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "TermTable",
|
name: "TermTable",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
tableData: [],
|
//学年学期
|
||||||
title: "主题整合课程学期教学计划表",
|
xnxqOptions: [],
|
||||||
zc: "",
|
//主题
|
||||||
month: "",
|
themeOptions: [],
|
||||||
classname: "中二班",
|
title: "",
|
||||||
|
xnxq: "",
|
||||||
|
classname: "",
|
||||||
tbr: "",
|
tbr: "",
|
||||||
monththeme: "",
|
|
||||||
bz: "",
|
|
||||||
spyj: "",
|
spyj: "",
|
||||||
//根据活动id获取的theme名称
|
|
||||||
themenamebyactivityids: "",
|
|
||||||
//分组性质
|
|
||||||
fzxzOptions: [],
|
|
||||||
//主题活动
|
|
||||||
themeactivityOptions: [],
|
|
||||||
bodyData: {
|
bodyData: {
|
||||||
title: [
|
title: [
|
||||||
{
|
{
|
||||||
label: "月时间",
|
label: "月份",
|
||||||
prop: "theme",
|
prop: "theme",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -129,197 +84,71 @@ export default {
|
|||||||
prop: "help",
|
prop: "help",
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
weekplanitemList: [
|
termplanitemList: [],
|
||||||
{
|
|
||||||
month: '1月',
|
|
||||||
theme: "春天的颜色",
|
|
||||||
info: '时代峰峻的斯洛伐克'
|
|
||||||
},
|
|
||||||
// {
|
|
||||||
// day: "周二",
|
|
||||||
// name: "活动",
|
|
||||||
// term: "同质",
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// day: "周三",
|
|
||||||
// name: "活动",
|
|
||||||
// term: "同质",
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// day: "周四",
|
|
||||||
// name: "活动",
|
|
||||||
// term: "同质",
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// day: "周五",
|
|
||||||
// name: "活动",
|
|
||||||
// term: "同质",
|
|
||||||
// },
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
// 查询参数
|
// 查询参数
|
||||||
queryParams: {
|
queryParams: {
|
||||||
wpid: undefined,
|
tpid: undefined,
|
||||||
},
|
|
||||||
// 查询参数
|
|
||||||
queryParams_MonPlan: {
|
|
||||||
xnxq: undefined,
|
|
||||||
month: undefined,
|
|
||||||
status: "2",
|
|
||||||
},
|
|
||||||
queryParams_MonPlanItem: {
|
|
||||||
mpid: undefined,
|
|
||||||
zc: undefined,
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
const themeweekplanid = this.$route.params && this.$route.params.id;
|
const themetermplanid = this.$route.params && this.$route.params.id;
|
||||||
this.getThemeWeekPlan(themeweekplanid);
|
this.queryParams.tpid = themetermplanid;
|
||||||
this.getDicts("sys_dm_fzxz").then((response) => {
|
this.getThemeTermPlan(themetermplanid);
|
||||||
this.fzxzOptions = response.data;
|
this.getThemeList();
|
||||||
|
this.getDicts("sys_xnxq").then((response) => {
|
||||||
|
this.xnxqOptions = response.data;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
//主题翻译
|
// 学年学期类型--字典状态字典翻译
|
||||||
async themeFormat(themeids) {
|
xnxqFormat(xnxq) {
|
||||||
var themename = "";
|
return this.selectDictLabel(this.xnxqOptions, xnxq);
|
||||||
var ids = themeids.split(";");
|
|
||||||
var array = [];
|
|
||||||
//console.log(ids);
|
|
||||||
ids.forEach(function (value, key, arr) {
|
|
||||||
//console.log(value); // 结果依次为1,2,3
|
|
||||||
if (value != "") {
|
|
||||||
array.push(parseInt(value));
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
if (array.length > 0) {
|
|
||||||
await listThemeByIds(array).then((response) => {
|
|
||||||
response.rows.forEach(function (value1, key1, arr1) {
|
|
||||||
themename = themename + value1.name + ";";
|
|
||||||
});
|
|
||||||
});
|
|
||||||
//(themename);
|
|
||||||
this.monththeme = themename;
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
// 主题--字典状态字典翻译
|
// 主题--字典状态字典翻译
|
||||||
themeactivityFormat(activityid) {
|
themeFormat(themeids) {
|
||||||
if (activityid != null) {
|
if (themeids != "") {
|
||||||
var ilength = activityid.split(";").length - 1;
|
var ilength = themeids.split(";").length - 1;
|
||||||
var names = "";
|
var names = "";
|
||||||
for (var i = 1; i < ilength; i++) {
|
for (var i = 1; i < ilength; i++) {
|
||||||
names =
|
names =
|
||||||
names +
|
names +
|
||||||
this.selectMoeDictLabel(
|
this.selectMoeDictLabel(this.themeOptions, themeids.split(";")[i]) +
|
||||||
this.themeactivityOptions,
|
" ";
|
||||||
activityid.split(";")[i]
|
|
||||||
) +
|
|
||||||
";";
|
|
||||||
}
|
}
|
||||||
//this.selectDictLabel(this.scopeOptions, row.xnxq);
|
//this.selectDictLabel(this.scopeOptions, row.xnxq);
|
||||||
return names;
|
return names;
|
||||||
}
|
}
|
||||||
return "";
|
return "";
|
||||||
},
|
},
|
||||||
// 分组性质类型--字典状态字典翻译
|
//主题
|
||||||
fzxzFormat(fzxz) {
|
getThemeList() {
|
||||||
return this.selectDictLabel(this.fzxzOptions, fzxz);
|
listTheme(null).then((response) => {
|
||||||
},
|
|
||||||
//主题活动
|
|
||||||
getThemeActivityList(themeid) {
|
|
||||||
listActivityByThemeId(themeid).then((response) => {
|
|
||||||
//console.log(response.rows);
|
//console.log(response.rows);
|
||||||
this.themeactivityOptions = response.rows;
|
this.themeOptions = response.rows;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
//获取周教学计划详情
|
//获取教学学期计划
|
||||||
getThemeWeekPlan(themeweekplanid) {
|
getThemeTermPlan(themetermplanid) {
|
||||||
getWeekplan(themeweekplanid).then((response) => {
|
getTermplan(themetermplanid).then((response) => {
|
||||||
//(response);
|
console.log(response.data);
|
||||||
this.queryParams.wpid = response.data.id;
|
|
||||||
this.title = response.data.name;
|
this.title = response.data.name;
|
||||||
this.zc = response.data.zc;
|
|
||||||
this.month = response.data.month;
|
|
||||||
this.classname = response.classname;
|
|
||||||
this.tbr = response.createusername;
|
this.tbr = response.createusername;
|
||||||
this.bz = response.data.remark;
|
this.classname = response.classname;
|
||||||
|
this.xnxq = response.data.xnxq;
|
||||||
this.spyj = response.data.shyj;
|
this.spyj = response.data.shyj;
|
||||||
|
|
||||||
//查找活动id
|
|
||||||
this.queryParams_MonPlan.month = response.data.month;
|
|
||||||
this.queryParams_MonPlan.xnxq = response.data.xnxq;
|
|
||||||
listMonthplan(this.queryParams_MonPlan).then((resMonPlan) => {
|
|
||||||
//console.log(resMonPlan.rows);
|
|
||||||
//获取的月主题
|
|
||||||
var monththemeids = resMonPlan.rows[0].themes;
|
|
||||||
|
|
||||||
this.themeFormat(monththemeids);
|
|
||||||
|
|
||||||
this.queryParams_MonPlanItem.mpid = resMonPlan.rows[0].id;
|
|
||||||
this.queryParams_MonPlanItem.zc = response.data.zc;
|
|
||||||
listMonthplanitem(this.queryParams_MonPlanItem).then(
|
|
||||||
(resMonPlanItem) => {
|
|
||||||
//console.log(resMonPlanItem.rows);
|
|
||||||
var activityids = resMonPlanItem.rows[0].activityid.split(";");
|
|
||||||
var array = [];
|
|
||||||
//console.log(arr);
|
|
||||||
activityids.forEach(function (value, key, arr) {
|
|
||||||
//console.log(value); // 结果依次为1,2,3
|
|
||||||
if (value != "") {
|
|
||||||
array.push(parseInt(value));
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
this.getThemeActivityList(array);
|
this.getThemeTermItemPlan();
|
||||||
}
|
},
|
||||||
);
|
//获取学期月份详细计划
|
||||||
});
|
getThemeTermItemPlan() {
|
||||||
|
listTermplanitem(this.queryParams).then((response) => {
|
||||||
this.getList();
|
console.log(response.rows);
|
||||||
|
this.bodyData.termplanitemList = response.rows;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
/** 查询主题整合周计划明细列表 */
|
//打印
|
||||||
async getList() {
|
|
||||||
//console.log(this.queryParams.wpid);
|
|
||||||
await listWeekplanitem(this.queryParams).then((response) => {
|
|
||||||
this.bodyData.weekplanitemList = response.rows;
|
|
||||||
|
|
||||||
//获取所有的活动id
|
|
||||||
var activityIds = "";
|
|
||||||
response.rows.forEach(function (value, key, arr) {
|
|
||||||
if (value.activityid != null) {
|
|
||||||
activityIds = activityIds + value.activityid + ";";
|
|
||||||
}
|
|
||||||
});
|
|
||||||
var array = [];
|
|
||||||
activityIds.split(";").forEach(function (value, key, arr) {
|
|
||||||
if (value != "") {
|
|
||||||
array.push(parseInt(value));
|
|
||||||
}
|
|
||||||
});
|
|
||||||
//获取所有的活动id截止
|
|
||||||
this.getThemeByActivityIds(array);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
//根据活动id获取theme列表
|
|
||||||
async getThemeByActivityIds(array) {
|
|
||||||
if (array.length > 0) {
|
|
||||||
var themename = "";
|
|
||||||
await listThemeByActivityIds(array).then((response) => {
|
|
||||||
response.rows.forEach(function (value, key, arr) {
|
|
||||||
themename = themename + value.name + ";";
|
|
||||||
});
|
|
||||||
});
|
|
||||||
//console.log(themename);
|
|
||||||
this.themenamebyactivityids = themename;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.bodyData.weekplanitemList[0].theme =
|
|
||||||
this.themenamebyactivityids == ""
|
|
||||||
? "未设置"
|
|
||||||
: this.themenamebyactivityids;
|
|
||||||
},
|
|
||||||
prints() {
|
prints() {
|
||||||
//console.log(this.$refs.printMe);
|
//console.log(this.$refs.printMe);
|
||||||
this.$print(this.$refs.printMe);
|
this.$print(this.$refs.printMe);
|
||||||
|
@ -11,6 +11,7 @@ import com.ruoyi.project.benyi.domain.ByThemeTermplanitem;
|
|||||||
import com.ruoyi.project.benyi.service.IByThemeTermplanitemService;
|
import com.ruoyi.project.benyi.service.IByThemeTermplanitemService;
|
||||||
import com.ruoyi.project.common.SchoolCommon;
|
import com.ruoyi.project.common.SchoolCommon;
|
||||||
import com.ruoyi.project.system.service.IByClassService;
|
import com.ruoyi.project.system.service.IByClassService;
|
||||||
|
import com.ruoyi.project.system.service.ISysUserService;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
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;
|
||||||
@ -47,6 +48,8 @@ public class ByThemeTermplanController extends BaseController {
|
|||||||
private IByClassService byClassService;
|
private IByClassService byClassService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private IByThemeTermplanitemService byThemeTermplanitemService;
|
private IByThemeTermplanitemService byThemeTermplanitemService;
|
||||||
|
@Autowired
|
||||||
|
private ISysUserService userService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询主题整合学期计划列表
|
* 查询主题整合学期计划列表
|
||||||
@ -84,7 +87,12 @@ public class ByThemeTermplanController extends BaseController {
|
|||||||
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:query')")
|
@PreAuthorize("@ss.hasPermi('benyi:themetermplan:query')")
|
||||||
@GetMapping(value = "/{id}")
|
@GetMapping(value = "/{id}")
|
||||||
public AjaxResult getInfo(@PathVariable("id") String id) {
|
public AjaxResult getInfo(@PathVariable("id") String id) {
|
||||||
return AjaxResult.success(byThemeTermplanService.selectByThemeTermplanById(id));
|
AjaxResult ajax = AjaxResult.success();
|
||||||
|
ByThemeTermplan byThemeTermplan = byThemeTermplanService.selectByThemeTermplanById(id);
|
||||||
|
ajax.put(AjaxResult.DATA_TAG, byThemeTermplan);
|
||||||
|
ajax.put("classname", byClassService.selectByClassById(byThemeTermplan.getClassid()).getBjmc());
|
||||||
|
ajax.put("createusername", userService.selectUserById(byThemeTermplan.getCreateuserid()).getNickName());
|
||||||
|
return ajax;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user