|
@@ -0,0 +1,391 @@
|
|
|
+<template>
|
|
|
+ <div id="studentPushData">
|
|
|
+ <div style="margin-bottom: 14px">
|
|
|
+ <el-select
|
|
|
+ v-model="formData['educationId']"
|
|
|
+ placeholder="请选择教育类型"
|
|
|
+ size="medium"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="(items, indexs) in educationType"
|
|
|
+ :key="indexs"
|
|
|
+ :label="items.educationName"
|
|
|
+ :value="items.id"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ <el-select
|
|
|
+ v-if="formData.educationId"
|
|
|
+ style="margin-left: 10px"
|
|
|
+ v-model="formData['businessId']"
|
|
|
+ placeholder="请选择业务层次"
|
|
|
+ size="medium"
|
|
|
+ @change="search"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="(items, indexs) in businessList"
|
|
|
+ :key="indexs"
|
|
|
+ :label="`${items.projectName} - ${items.businessName}`"
|
|
|
+ :value="items.id"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ </div>
|
|
|
+ <table-list
|
|
|
+ :tableSets="tableSet"
|
|
|
+ :tableData="tableData"
|
|
|
+ :navText="navText"
|
|
|
+ :loading="loading"
|
|
|
+ >
|
|
|
+ <template slot="btn" slot-scope="props">
|
|
|
+ <el-button type="text" @click="jumpClass(props.scope.row)"
|
|
|
+ >详情</el-button
|
|
|
+ >
|
|
|
+ </template>
|
|
|
+ </table-list>
|
|
|
+ <pagination
|
|
|
+ :total="total"
|
|
|
+ :pageSize="formData.pageSize"
|
|
|
+ :currentPage="formData.pageNum"
|
|
|
+ @handleSizeChange="handleSizeChange"
|
|
|
+ @handleCurrentChange="handleCurrentChange"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import { mapGetters } from "vuex";
|
|
|
+import searchBoxNew from "@/components/searchBoxNew";
|
|
|
+import tableList from "@/components/tableList";
|
|
|
+import pagination from "@/components/pagination";
|
|
|
+export default {
|
|
|
+ name: "StudentPushData",
|
|
|
+ components: { searchBoxNew, tableList, pagination },
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ disabledBtn: false,
|
|
|
+ changeHeight: true,
|
|
|
+ loading: false, //当前表单加载是否加载动画
|
|
|
+ navText: {
|
|
|
+ title: "学员推送数据",
|
|
|
+ index: 0,
|
|
|
+ ch: "条",
|
|
|
+ num: true,
|
|
|
+ border: true,
|
|
|
+ choice: true,
|
|
|
+ addHide: true,
|
|
|
+ backFatherBtn: {
|
|
|
+ status: false,
|
|
|
+ title: "未定义",
|
|
|
+ },
|
|
|
+ },
|
|
|
+ formData: {
|
|
|
+ educationId: "",
|
|
|
+ businessId: "",
|
|
|
+ status: "0,1",
|
|
|
+ pageSize: 10,
|
|
|
+ pageNum: 1,
|
|
|
+ },
|
|
|
+ // 表单
|
|
|
+ tableSet: [
|
|
|
+ {
|
|
|
+ label: "商品名称",
|
|
|
+ prop: "goodsName",
|
|
|
+ objProp: "goodsList",
|
|
|
+ hidden: true,
|
|
|
+ scope: "objType",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "班级名称",
|
|
|
+ prop: "className",
|
|
|
+ hidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "班级号",
|
|
|
+ prop: "classStatus",
|
|
|
+ prop1: "officialName",
|
|
|
+ hidden: true,
|
|
|
+ scope: "classTypes",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "班级有效期",
|
|
|
+ prop1: "classStartTime",
|
|
|
+ prop2: "classEndTime",
|
|
|
+ hidden: true,
|
|
|
+ Diszing: false,
|
|
|
+ scope: "TimeLists",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "班级人数",
|
|
|
+ prop: "studentNum",
|
|
|
+ hidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "是否配置报名接口",
|
|
|
+ prop: "officialStatus",
|
|
|
+ hidden: true,
|
|
|
+ scope: "isOptions",
|
|
|
+ options: [
|
|
|
+ {
|
|
|
+ label: "是",
|
|
|
+ value: 1,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "否",
|
|
|
+ value: 0,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "否",
|
|
|
+ value: null,
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "报名已推送人数",
|
|
|
+ prop: "officialStatusNum",
|
|
|
+ hidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "是否配置学时接口",
|
|
|
+ prop: "periodPlush",
|
|
|
+ hidden: true,
|
|
|
+ scope: "isOptions",
|
|
|
+ options: [
|
|
|
+ {
|
|
|
+ label: "是",
|
|
|
+ value: 1,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "否",
|
|
|
+ value: 0,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "否",
|
|
|
+ value: null,
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "学时审核通过人数",
|
|
|
+ prop: "periodStatusNum",
|
|
|
+ hidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "学时已推送人数",
|
|
|
+ prop: "periodPlushNum",
|
|
|
+ hidden: true,
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ tableData: [], //表单数据
|
|
|
+ total: 0, //一共多少条
|
|
|
+ businessList: [],
|
|
|
+ firstComeIn: true,
|
|
|
+ };
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ educationType(val) {
|
|
|
+ if (val.length > 0) {
|
|
|
+ this.formData.educationId = val[0].id;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ "formData.educationId"(val) {
|
|
|
+ this.formData.businessId = "";
|
|
|
+ this.getBusinessList(val);
|
|
|
+ },
|
|
|
+ },
|
|
|
+ computed: { ...mapGetters(["educationType"]) },
|
|
|
+ mounted() {
|
|
|
+ if (
|
|
|
+ !this.formData.educationId &&
|
|
|
+ this.educationType &&
|
|
|
+ this.educationType.length
|
|
|
+ ) {
|
|
|
+ this.formData.educationId = this.educationType[0].id;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ getBusinessList(v) {
|
|
|
+ this.$api
|
|
|
+ .inquirebusinessList({ status: 1, educationId: v })
|
|
|
+ .then((res) => {
|
|
|
+ this.businessList = res.rows;
|
|
|
+ if (this.firstComeIn) {
|
|
|
+ this.firstComeIn = false;
|
|
|
+ this.formData.businessId = res.rows[0].id;
|
|
|
+ this.search();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ jumpClass(row) {
|
|
|
+ const jump = () => {
|
|
|
+ this.$router.push({
|
|
|
+ name: "ClassList",
|
|
|
+ params: {
|
|
|
+ educationId: this.formData.educationId,
|
|
|
+ businessId: this.formData.businessId,
|
|
|
+ },
|
|
|
+ });
|
|
|
+ };
|
|
|
+ const statusPage = this.$store.state.tagsView.visitedViews.some(
|
|
|
+ (item) => {
|
|
|
+ return item.name == "ClassList";
|
|
|
+ }
|
|
|
+ );
|
|
|
+ if (statusPage) {
|
|
|
+ this.$store
|
|
|
+ .dispatch("tagsView/delCachedView", {
|
|
|
+ name: "ClassList",
|
|
|
+ })
|
|
|
+ .then((res) => {
|
|
|
+ jump();
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ jump();
|
|
|
+ }
|
|
|
+ },
|
|
|
+ search() {
|
|
|
+ this.loading = true;
|
|
|
+ var data = JSON.parse(JSON.stringify(this.formData));
|
|
|
+ this.$api
|
|
|
+ .inquireGradegradeList(data)
|
|
|
+ .then((res) => {
|
|
|
+ this.tableData = res.rows;
|
|
|
+ this.total = res.total;
|
|
|
+ this.navText.index = res.total;
|
|
|
+ })
|
|
|
+ .finally(() => {
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
+ },
|
|
|
+ handleSizeChange(v) {
|
|
|
+ this.formData.pageSize = v;
|
|
|
+ this.formData.pageNum = 1;
|
|
|
+ this.search();
|
|
|
+ },
|
|
|
+ handleCurrentChange(v) {
|
|
|
+ this.formData.pageNum = v;
|
|
|
+ this.search();
|
|
|
+ },
|
|
|
+ },
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="less" scoped>
|
|
|
+/deep/.el-button {
|
|
|
+ border-radius: 8px;
|
|
|
+}
|
|
|
+/deep/.el-dialog {
|
|
|
+ border-radius: 8px;
|
|
|
+ .el-dialog__header {
|
|
|
+ padding: 0;
|
|
|
+ .hearders {
|
|
|
+ height: 40px;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: space-between;
|
|
|
+ padding: 0px 18px 0px 20px;
|
|
|
+ border-bottom: 1px solid #e2e2e2;
|
|
|
+ .leftTitle {
|
|
|
+ font-size: 14px;
|
|
|
+ font-weight: bold;
|
|
|
+ color: #2f4378;
|
|
|
+ }
|
|
|
+ .rightBoxs {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ img {
|
|
|
+ width: 14px;
|
|
|
+ height: 14px;
|
|
|
+ margin-left: 13px;
|
|
|
+ cursor: pointer;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .el-dialog__footer {
|
|
|
+ padding: 0;
|
|
|
+ .dialog-footer {
|
|
|
+ padding: 0px 40px;
|
|
|
+ height: 70px;
|
|
|
+ border-top: 1px solid #e2e2e2;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: flex-end;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+.imgBox {
|
|
|
+ width: 100%;
|
|
|
+ // height: 210px;
|
|
|
+ border: 1px solid #e2e2e2;
|
|
|
+ border-radius: 8px;
|
|
|
+ padding: 8px 8px 3px;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
+ .imgLabel {
|
|
|
+ flex: 1;
|
|
|
+ width: 100%;
|
|
|
+ border: 1px dotted #e2e2e2;
|
|
|
+ color: #999;
|
|
|
+ font-size: 14px;
|
|
|
+ cursor: pointer;
|
|
|
+ border-radius: 8px;
|
|
|
+ .msPhoto {
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ align-items: center;
|
|
|
+ max-width: 100%;
|
|
|
+ max-height: 270px;
|
|
|
+ img {
|
|
|
+ max-width: 100%;
|
|
|
+ max-height: 270px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .imgbbx {
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: center;
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ i {
|
|
|
+ font-weight: bold;
|
|
|
+ margin: 14px 0;
|
|
|
+ font-size: 24px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ p {
|
|
|
+ margin: 5px 0px;
|
|
|
+ }
|
|
|
+}
|
|
|
+.checkboxSty {
|
|
|
+ max-height: 210px;
|
|
|
+ overflow: auto;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+}
|
|
|
+.listBoxStys {
|
|
|
+ flex-shrink: 0;
|
|
|
+ padding: 0px 10px;
|
|
|
+ border-radius: 8px;
|
|
|
+ border: 1px solid #eee;
|
|
|
+ margin-right: 10px;
|
|
|
+ margin-bottom: 6px;
|
|
|
+}
|
|
|
+.closeIcons {
|
|
|
+ color: red;
|
|
|
+ cursor: pointer;
|
|
|
+ margin-left: 6px;
|
|
|
+}
|
|
|
+.ach {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ overflow: hidden;
|
|
|
+}
|
|
|
+.clh {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ flex-wrap: wrap;
|
|
|
+}
|
|
|
+</style>
|
|
|
+
|