Przeglądaj źródła

班级管理需求

En route 1 rok temu
rodzic
commit
4ce09cb560
20 zmienionych plików z 3548 dodań i 509 usunięć
  1. 21 1
      src/newApi/classTab.js
  2. 9 0
      src/newApi/visit.js
  3. 1 0
      src/views/education/archives/archivesDetails/courseRecords/ClassHour.vue
  4. 15 2
      src/views/education/classManageMent/classHoursReview/component/LessonTable.vue
  5. 788 0
      src/views/education/classManageMent/classList/classList/addClass.vue
  6. 391 0
      src/views/education/classManageMent/classList/classList/index.vue
  7. 54 0
      src/views/education/classManageMent/classList/classList/remark.vue
  8. 18 0
      src/views/education/classManageMent/classList/classStudent/index.vue
  9. 554 0
      src/views/education/classManageMent/classList/index copy 2.vue
  10. 554 0
      src/views/education/classManageMent/classList/index copy.vue
  11. 14 445
      src/views/education/classManageMent/classList/index.vue
  12. 50 25
      src/views/education/classManageMent/classList/manageClass/baseInfo.vue
  13. 7 12
      src/views/education/classManageMent/classList/manageClass/studentRecords.vue
  14. 19 10
      src/views/education/classManageMent/classList/manageClass/teacherRecords.vue
  15. 218 0
      src/views/education/classManageMent/classList/trainee/changeClassDialog.vue
  16. 667 0
      src/views/education/classManageMent/classList/trainee/index.vue
  17. 159 0
      src/views/education/classManageMent/classList/trainee/tabClassDialog.vue
  18. 0 5
      src/views/education/classManageMent/studentMenu/index.vue
  19. 3 3
      src/views/education/studentManageMent/studentXQ/index.vue
  20. 6 6
      src/views/education/studentManageMent/studentXQ/studentBaseManage.vue

+ 21 - 1
src/newApi/classTab.js

@@ -96,6 +96,16 @@ export default {
             params: data
         })
     },
+    //导出所有班级用户列表
+    inquireGradegradelistGradeAllExport(data) {
+        return request({
+            url: '/grade/grade/listGradeAllExport',
+            isProce: true,
+            method: 'get',
+            params: data
+        })
+    },
+
     //查询学员学时列表
     inquireGradegradelistUserPeriod(data) {
         return request({
@@ -122,6 +132,16 @@ export default {
             method: 'get',
         })
     },
+
+    //查询所有班级用户列表
+    gradelistGradeAll(data) {
+        return request({
+            url: '/grade/grade/listGradeAll',
+            method: 'get',
+            isProce: true,
+            params: data
+        })
+    },
     //查询官方接口
     inquirelistInterfaceVo(data) {
         return request({
@@ -364,5 +384,5 @@ export default {
             data
         })
     },
-    
+
 }

+ 9 - 0
src/newApi/visit.js

@@ -31,4 +31,13 @@ export default {
             method: 'get',
         })
     },
+    //修改图片
+    imgChange(data) {
+        return request({
+            url: '/common/student/image/spin',
+            method: 'post',
+            data
+        })
+    },
+    
 }

+ 1 - 0
src/views/education/archives/archivesDetails/courseRecords/ClassHour.vue

@@ -212,6 +212,7 @@ export default {
   methods: {
     openBoxs(item) {
       this.userData = {};
+      console.log(item,'item')
       this.setData = item;
       this.isShow = true;
       this.getUserInfo();

+ 15 - 2
src/views/education/classManageMent/classHoursReview/component/LessonTable.vue

@@ -32,7 +32,7 @@
                   :preview-src-list="[$methodsTools.splitImgHost(its.photo)]"
                 >
                 </el-image>
-                <div class="abos">
+                <div class="abos" @click="imgChange(scope.row.userStudyRecordPhotoList[inds],'photo',its.photo)">
                   {{ $methodsTools.onlyForma(its.createTime) }}
                 </div>
               </li>
@@ -369,6 +369,19 @@ export default {
     };
   },
   methods: {
+    imgChange(list,name,url) {
+      return
+      this.$api
+        .imgChange({
+          imageUrl: url,
+        })
+        .then((res) => {
+          if (res.code == 200) {
+            this.$set(list,name,url + `?v=${Math.random()}`)
+            this.$message.success("操作成功");
+          }
+        });
+    },
     submit(text) {
       this.formData.auditReason = text;
       this.$api
@@ -392,7 +405,7 @@ export default {
     },
     comput(item) {
       var ast = item.studyEndTime - item.studyStartTime;
-      let status = item.durationTime - ast
+      let status = item.durationTime - ast;
       if (status > 25) {
         return "color:red;";
       } else {

+ 788 - 0
src/views/education/classManageMent/classList/classList/addClass.vue

@@ -0,0 +1,788 @@
+<template>
+  <div id="">
+    <BaseDialog
+      width="1400px"
+      :isShow.sync="isShow"
+      title="新增"
+      @close="close"
+      @submit="submitForm"
+      @open="init"
+    >
+      <el-row :gutter="20">
+        <el-form
+          label-position="right"
+          label-width="120px"
+          :model="listData"
+          :rules="rules"
+          ref="listData"
+        >
+          <el-col :span="12">
+            <el-form-item label="所属商品" prop="payer">
+              <span
+                style="margin-right: 20px"
+                v-if="listData.classGradeGoodsAddBos.length"
+                >{{ listData.goodsName }}</span
+              >
+              <el-button type="primary" size="small" @click="openGoodsBox">{{
+                listData.classGradeGoodsAddBos.length ? "更换商品" : "添加商品"
+              }}</el-button>
+            </el-form-item>
+            <el-form-item label="班级名称" prop="className">
+              <el-input
+                style="width: 400px"
+                v-model="listData.className"
+                placeholder="请填写班级名称"
+              ></el-input>
+            </el-form-item>
+            <el-form-item label="学员上限" prop="studentUpper">
+              <el-input-number
+                :controls="false"
+                v-model="listData.studentUpper"
+                placeholder="请填写学员上限"
+              ></el-input-number>
+            </el-form-item>
+            <el-form-item
+              label="开放学习"
+              :prop="
+                listData.learningStatus == 3
+                  ? 'learningTimeStart'
+                  : 'learningStatus'
+              "
+            >
+              <!-- <el-button
+              style="margin-right: 14px"
+              size="mini"
+              v-if="listData.learningStatus"
+              @click="listData.learningStatus = ''"
+              >清除选择</el-button
+            > -->
+              <el-radio-group
+                v-model="listData.learningStatus"
+                @change="changeLearning"
+              >
+                <el-radio :label="1">即刻</el-radio>
+                <el-radio :label="2">待定</el-radio>
+                <el-radio :label="3">日期</el-radio>
+              </el-radio-group>
+              <el-date-picker
+                v-if="listData.learningStatus === 3"
+                v-model="listData.learningTimeStart"
+                type="datetime"
+                value-format="timestamp"
+                placeholder="请选择开放学习时间"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item label="班级状态" prop="status">
+              <el-radio-group v-model="listData.status">
+                <el-radio :label="1">开启</el-radio>
+                <el-radio :label="0">关闭</el-radio>
+              </el-radio-group>
+            </el-form-item>
+            <el-form-item label="官方班级号">
+              <el-button
+                style="margin-right: 14px"
+                size="mini"
+                v-if="listData.classStatus || listData.classStatus === 0"
+                @click="clearClassNumber"
+                >清除选择</el-button
+              >
+              <el-radio-group
+                v-model="listData.classStatus"
+                @change="changeClassStatus"
+              >
+                <el-radio :label="0">预报(未开班)</el-radio>
+                <el-radio :label="1">已开班</el-radio>
+              </el-radio-group>
+            </el-form-item>
+            <el-form-item
+              label=""
+              prop="officialName"
+              v-if="listData.classStatus === 1"
+            >
+              <el-input
+                placeholder="输入班级号"
+                v-model="listData.officialName"
+              ></el-input>
+            </el-form-item>
+            <el-form-item
+              label="班级有效期"
+              prop="timeList"
+              v-if="listData.classStatus"
+            >
+              <el-date-picker
+                style="width: 90%"
+                v-model="listData.timeList"
+                type="datetimerange"
+                range-separator="至"
+                start-placeholder="开始日期"
+                end-placeholder="结束日期"
+                value-format="timestamp"
+                @change="changeDataTimeStudy(listData.timeList)"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item label="考期" prop="examineId">
+              <el-select
+                v-model="listData.examineId"
+                placeholder="请选择考期"
+                clearable
+              >
+                <el-option
+                  v-for="(item, index) in courseExamine"
+                  :key="index"
+                  :label="item.examineName"
+                  :value="item.id"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item label="报考地区" prop="areasId">
+              <el-select
+                v-model="listData.areasId"
+                placeholder="请选择报考地区(省)"
+                @change="getNewCityList"
+                clearable
+              >
+                <el-option
+                  v-for="(item, index) in areas"
+                  :key="index"
+                  :label="item.areaName"
+                  :value="item.areaId"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item
+              label="报考地区(地市)"
+              :prop="listData.areasId ? 'cityId' : ''"
+              v-if="listData.areasId"
+            >
+              <el-select
+                v-model="listData.cityId"
+                placeholder="请选择报考地区(市)"
+                clearable
+              >
+                <el-option
+                  v-for="(item, index) in newCityList"
+                  :key="index"
+                  :label="item.areaName"
+                  :value="item.areaId"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item label="指派班主任">
+              <el-select
+                v-model="listData.sysUserId"
+                placeholder="请选择"
+                clearable
+              >
+                <el-option
+                  v-for="(item, index) in teacherList"
+                  :key="index"
+                  :label="item.nickName"
+                  :value="item.userId"
+                >
+                </el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <div v-if="statusShow === 1">
+              <el-form-item label="官方信息推送" prop="interfacePushId">
+                <el-select
+                  v-model="listData.interfacePushId"
+                  placeholder="请选择"
+                  clearable
+                >
+                  <el-option
+                    v-for="(item, index) in type1List"
+                    :key="index"
+                    :label="item.name"
+                    :value="item.id"
+                  >
+                  </el-option>
+                </el-select>
+              </el-form-item>
+              <el-form-item label="官方学时推送" prop="interfacePeriodId">
+                <el-select
+                  v-model="listData.interfacePeriodId"
+                  placeholder="请选择"
+                  clearable
+                >
+                  <el-option
+                    v-for="(item, index) in type3List"
+                    :key="index"
+                    :label="item.name"
+                    :value="item.id"
+                  >
+                  </el-option>
+                </el-select>
+              </el-form-item>
+              <el-form-item label="官方账号标记(有接口+标记功能)">
+                <el-select
+                  v-model="listData.interfaceAccountId"
+                  placeholder="请选择"
+                  clearable
+                  :disabled="listData.noInterfaceAccountId ? true : false"
+                >
+                  <el-option
+                    v-for="(item, index) in type2List"
+                    :key="index"
+                    :label="item.name"
+                    :value="item.id"
+                  >
+                  </el-option>
+                </el-select>
+              </el-form-item>
+              <el-form-item label="官方账号标记(无接口+标记功能)">
+                <el-select
+                  v-model="listData.noInterfaceAccountId"
+                  placeholder="请选择"
+                  clearable
+                  :disabled="listData.interfaceAccountId ? true : false"
+                >
+                  <el-option
+                    v-for="(item, index) in type4List"
+                    :key="index"
+                    :label="item.name"
+                    :value="item.id"
+                  >
+                  </el-option>
+                </el-select>
+              </el-form-item>
+            </div>
+            <el-form-item label="备注" prop="remark">
+              <el-input
+                type="textarea"
+                :rows="5"
+                v-model="listData.remark"
+              ></el-input>
+            </el-form-item>
+          </el-col>
+        </el-form>
+      </el-row>
+      <el-dialog
+        :visible.sync="dialogVisiblePZDown"
+        appendToBody
+        width="900px"
+        :show-close="false"
+        :close-on-click-modal="false"
+      >
+        <div slot="title" class="hearders">
+          <div class="leftTitle">添加商品</div>
+          <div class="rightBoxs">
+            <img src="@/assets/images/Close@2x.png" alt="" @click="closePZ" />
+          </div>
+        </div>
+        <div>
+          <search-box-new
+            ref="searchBox"
+            :formData="formData"
+            :formList="formList"
+            @search="getGoodsList"
+            @init="init"
+          />
+          <el-table
+            ref="multipleTable"
+            :data="tableData"
+            border
+            :header-cell-style="{
+              'background-color': '#eee',
+              padding: '8px',
+              color: '#333',
+            }"
+          >
+            <el-table-column label="" width="45" align="center">
+              <template scope="scope">
+                <el-radio
+                  class="radioTables"
+                  :label="scope.row.goodsId"
+                  v-model="templateRadio"
+                  @change.native="getTemplateRow(scope.$index, scope.row)"
+                  >{{ "" }}</el-radio
+                >
+              </template>
+            </el-table-column>
+            <template v-for="(item, index) in tableList">
+              <el-table-column
+                v-if="item.scope !== 'inputs'"
+                :width="item.width"
+                :key="index"
+                :label="item.label"
+                align="center"
+                :show-overflow-tooltip="true"
+                header-align="center"
+              >
+                <template slot-scope="scope">
+                  <span v-if="item.scope === 'status'">
+                    {{
+                      scope.row[item.prop] === 1
+                        ? "有效"
+                        : scope.row[item.prop] === 0
+                        ? "无效"
+                        : "未知"
+                    }}
+                  </span>
+                  <span v-else-if="item.scope === 'moreList'">
+                    {{
+                      scope.row[item.prop1] +
+                      "-" +
+                      scope.row[item.prop2] +
+                      "-" +
+                      scope.row[item.prop3]
+                    }}
+                  </span>
+                  <span v-else-if="item.scope === 'goodsType'">{{
+                    getGoodsTypes(scope.row[item.prop])
+                  }}</span>
+                  <span v-else>{{ scope.row[item.prop] }}</span></template
+                >
+              </el-table-column></template
+            >
+          </el-table>
+          <pagination
+            :total="total"
+            :pageSize="formData.pageSize"
+            :currentPage="formData.pageNum"
+            @handleSizeChange="handleSizeChange"
+            @handleCurrentChange="handleCurrentChange"
+          />
+        </div>
+        <span slot="footer" class="dialog-footer">
+          <el-button @click="closePZ">取 消</el-button>
+          <el-button type="primary" @click="submitPZ">确 定</el-button>
+        </span>
+      </el-dialog>
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+import searchBoxNew from "@/components/searchBoxNew";
+import pagination from "@/components/pagination";
+import { mapGetters } from "vuex";
+export default {
+  components: { searchBoxNew, pagination },
+  data() {
+    return {
+      isShow: false,
+      total: 0,
+      formList: [
+        {
+          prop: "educationId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationId",
+        },
+        {
+          prop: "goodsName",
+          placeholder: "请输入商品名称",
+        },
+      ],
+      formData: {
+        goodsType: 1,
+        status: 1,
+        pageSize: 10,
+        pageNum: 1,
+      },
+      dialogVisiblePZDown: false,
+      listData: {
+        classStatus: "",
+        status: 1,
+        timeList: [],
+        learningStatus: 1,
+        learningTimeStart: "",
+        officialName: "",
+        cityId: "",
+        classGradeGoodsAddBos: [],
+        studentUpper: 1000000,
+        // officialLearningUrl: "",
+      },
+      rules: {
+        className: [
+          { required: true, message: "请填写班级名称", trigger: "blur" },
+        ],
+        officialLearningUrl: [
+          { required: true, message: "请输入学习的网址", trigger: "blur" },
+        ],
+        officialName: [
+          { required: true, message: "请填写官方班级", trigger: "blur" },
+        ],
+        studentUpper: [
+          { required: true, message: "请填写学员上限", trigger: "blur" },
+          {
+            validator(rule, value, callback) {
+              var reg = /^[1-9]\d*$/;
+              if (reg.test(value)) {
+                callback();
+              } else {
+                callback(new Error("请规范输入学员上限数量"));
+              }
+            },
+            trigger: "blur",
+          },
+        ],
+        status: [{ required: true, message: "请选择状态", trigger: "change" }],
+        timeList: [
+          {
+            type: "array",
+            required: true,
+            message: "请选择班级有效期",
+            trigger: "change",
+          },
+        ],
+        learningTimeStart: [
+          {
+            type: "date",
+            required: true,
+            message: "请选择开放学习时间",
+            trigger: "change",
+          },
+        ],
+        cityId: [
+          {
+            required: true,
+            message: "请选择报考地市",
+            trigger: ["blur", "change"],
+          },
+        ],
+      },
+      cityList: [],
+      newCityList: [],
+      tableData: [],
+      tableList: [
+        {
+          label: "商品编码",
+          prop: "code",
+          width: "130px",
+        },
+        {
+          label: "年份",
+          prop: "year",
+        },
+        {
+          label: "商品名称",
+          prop: "goodsName",
+          width: "280px",
+        },
+        {
+          label: "业务层级",
+          prop1: "educationName",
+          prop2: "projectName",
+          prop3: "businessName",
+          scope: "moreList",
+          width: "340px",
+        },
+        {
+          label: "商品类型",
+          prop: "goodsType",
+          scope: "goodsType",
+          width: "100px",
+        },
+        {
+          label: "有效状态",
+          prop: "status",
+          scope: "status",
+          width: "100px",
+        },
+        {
+          label: "商品标价",
+          prop: "standPrice",
+          width: "100px",
+        },
+      ],
+      templateRadio: "",
+      goodsName: "",
+      //	1官方推送 2官方学习账号开通 3官方学时推送
+      type1List: [],
+      type2List: [],
+      type3List: [],
+      type4List: [],
+      teacherList: [],
+      statusShow: 1, //0隐藏1显示
+      timeArrays: [], //限制班级有效期时间
+    };
+  },
+  computed: { ...mapGetters(["courseExamine", "areas"]) },
+  methods: {
+    inits() {
+      this.isShow = true;
+      this.listData = {
+        classStatus: "",
+        status: 1,
+        timeList: [],
+        learningStatus: 1,
+        learningTimeStart: "",
+        officialName: "",
+        cityId: "",
+        classGradeGoodsAddBos: [],
+        studentUpper: 1000000,
+      };
+      this.$nextTick(()=>{
+        this.$refs.listData.clearValidate()
+      })
+      this.getInfoCityDict();
+      this.getGoodsList();
+      this.getGFList();
+    },
+    clearClassNumber() {
+      this.listData.classStatus = "";
+      this.changeClassStatus();
+    },
+    changeDataTimeStudy(arr) {
+      if (arr) {
+        if (arr[0] === arr[1]) {
+          this.$message.warning("开始时间与结束时间不允许相同");
+          this.listData.timeList = [];
+        }
+      }
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.getGoodsList();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.getGoodsList();
+    },
+    //官方接口是否出现
+    getVoselect() {
+      this.$api.inquirelistInterfaceVoselect().then((res) => {
+        if (res.data === 1) {
+          // this.getVoselect();
+        }
+        this.statusShow = res.data;
+      });
+    },
+    //获取官方接口
+    getGFList() {
+      this.$api.inquirelistInterfaceVo().then((res) => {
+        res.rows.forEach((item) => {
+          if (item.type === 1) {
+            this.type1List.push(item);
+          }
+          if (item.type === 2) {
+            this.type2List.push(item);
+          }
+          if (item.type === 3) {
+            this.type3List.push(item);
+          }
+          if (item.type === 4) {
+            this.type4List.push(item);
+          }
+        });
+      });
+      this.$api
+        .obtainUserList({ status: 1, roleName: "班主任" })
+        .then((res) => {
+          this.teacherList = res.rows;
+        });
+    },
+    //动态获取商品类型
+    getGoodsTypes(int) {
+      var ast = "";
+      switch (int) {
+        case 1:
+          ast = "视频";
+          break;
+        case 2:
+          ast = "题库";
+          break;
+        case 3:
+          ast = "补考";
+          break;
+        case 4:
+          ast = "前培";
+          break;
+        default:
+          break;
+      }
+      return ast;
+    },
+    //单选触发
+    getTemplateRow(index, row) {
+      this.templateRadio = row.goodsId;
+      this.goodsName = row.goodsName;
+    },
+    /**
+     * 确定选择商品列表
+     */
+    submitPZ() {
+      this.$api.obtainGoods(this.templateRadio).then((res) => {
+        this.timeArrays = [res.data.studyStartTime, res.data.studyEndTime];
+        this.listData.timeList = [];
+      });
+      this.listData.classGradeGoodsAddBos[0] = this.templateRadio;
+      this.listData.goodsName = this.goodsName;
+      this.dialogVisiblePZDown = false;
+    },
+    //获取商品列表
+    getGoodsList(int) {
+      this.loading = true;
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      if (int === 2) {
+        this.formData = {
+          goodsType: 1,
+          status: 1,
+          pageSize: 10,
+          pageNum: 1,
+        };
+      }
+      this.$api
+        .inquireGoods(this.formData)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.getGoodsList(2);
+    },
+    //获取地市列表
+    getInfoCityDict() {
+      this.$api.inquireapplyCityList({ status: 1, areaType: 2 }).then((res) => {
+        this.cityList = res.rows;
+      });
+    },
+    //获取最新地市列表
+    getNewCityList(n) {
+      this.newCityList = this.cityList.filter((item) => {
+        return item.parentId == n;
+      });
+      this.listData.cityId = "";
+    },
+    //改变开放学习状态-清空选择框
+    changeLearning() {
+      this.listData.learningTimeStart = "";
+    },
+    //改变班级号状态-清空输入框
+    changeClassStatus() {
+      this.listData.officialName = "";
+      this.listData.timeList = [];
+    },
+    //返回
+    backPage() {
+      this.$store.dispatch("tagsView/delView", this.$route).then((res) => {
+        this.$router.push({
+          path: "classList",
+        });
+      });
+    },
+    //表单验证
+    submitForm() {
+      this.$refs["listData"].validate((valid) => {
+        if (valid) {
+          if (!this.listData.classGradeGoodsAddBos.length) {
+            this.$message.error("请选择商品课程");
+            return;
+          }
+          this.submit(); //提交
+        } else {
+          console.log("error submit!!");
+          return false;
+        }
+      });
+    },
+    //提交
+    submit() {
+      var data = JSON.parse(JSON.stringify(this.listData));
+      // if(!data.interfaceAccountId){
+      //   delete data.officialLearningUrl
+      // }
+      if (data.timeList.length) {
+        data.classStartTime = this.listData.timeList[0] / 1000;
+        data.classEndTime = this.listData.timeList[1] / 1000;
+      }
+      if (!data.timeList) {
+        data.classStartTime = null;
+        data.classEndTime = null;
+      }
+      if (data.learningStatus === 3) {
+        data.learningTimeStart = this.listData.learningTimeStart / 1000;
+      }
+      this.$api.appGradegrade(data).then((res) => {
+        this.$message.success("添加成功");
+        this.$emit("backFunc")
+        this.isShow = false
+      });
+    },
+    //商品列表
+    openGoodsBox() {
+      if (this.listData.classGradeGoodsAddBos.length) {
+        this.templateRadio = this.listData.classGradeGoodsAddBos[0];
+        this.goodsName = this.listData.goodsName;
+      } else {
+        this.templateRadio = "";
+        this.goodsName = "";
+      }
+      this.dialogVisiblePZDown = true;
+    },
+    closePZ() {
+      this.dialogVisiblePZDown = false;
+    },
+    close() {},
+  },
+};
+</script>
+
+<style lang="scss" 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;
+    }
+  }
+}
+/deep/.radioTables > .el-radio__label {
+  display: none;
+}
+</style>

+ 391 - 0
src/views/education/classManageMent/classList/classList/index.vue

@@ -0,0 +1,391 @@
+<template>
+  <div id="">
+    <search-box-new
+      ref="searchBox"
+      :formData="formData"
+      :formList="formList"
+      @search="search"
+      @init="init"
+    />
+    <table-list
+      :tableSets="tableSet"
+      :tableData="tableData"
+      :navText="navText"
+      @addClick="addClick"
+      :loading="loading"
+      @editInfo="editInfo"
+    >
+      <template slot="customize">
+        <el-button type="warning" @click="addClick()">新增</el-button>
+      </template>
+      <template slot="goodsInfo" slot-scope="props">
+        <div style="text-align: left">
+          <p>商品名称:{{ props.scope.row["goodsList"][0].goodsName }}</p>
+          <p>教育类型:{{ props.scope.row["goodsList"][0].educationName }}</p>
+          <p>
+            业务层次:{{
+              props.scope.row["goodsList"][0].projectName +
+              " - " +
+              props.scope.row["goodsList"][0].businessName
+            }}
+          </p>
+          <p>专业:{{ props.scope.row["goodsList"][0].categoryName }}</p>
+          <p>年份:{{ props.scope.row["goodsList"][0].year }}</p>
+        </div>
+      </template>
+      <template slot="TimeLists" slot-scope="props">
+        <div style="text-align: left">
+          <p>
+            时间:<span>{{
+              $methodsTools.onlyForma(props.scope.row["classStartTime"])
+                ? $methodsTools.onlyForma(props.scope.row["classStartTime"])
+                : "--"
+            }}</span>
+            至
+            <span>{{
+              $methodsTools.onlyForma(props.scope.row["classEndTime"])
+                ? $methodsTools.onlyForma(props.scope.row["classEndTime"])
+                : "--"
+            }}</span>
+          </p>
+          <p>状态:{{ getClassStatus(props.scope.row) }}</p>
+        </div>
+      </template>
+
+      <template slot="btn" slot-scope="props">
+        <el-button type="text" @click="addClick(props.scope.row, 2)"
+          >班级详情</el-button
+        ><el-button type="text" @click="remark(props.scope.row)"
+          >备注</el-button
+        >
+        <el-button type="text" @click="addClick(props.scope.row, 3)"
+          >班级学员</el-button
+        >
+        <el-button
+          type="text"
+          :disabled="
+            (props.scope.row.learningStatus == 3 &&
+              props.scope.row.officialName) ||
+            props.scope.row.studentNum > 0
+          "
+          @click="del(props.scope.row)"
+          >删除</el-button
+        >
+      </template>
+    </table-list>
+    <pagination
+      :total="total"
+      :pageSize="formData.pageSize"
+      :currentPage="formData.pageNum"
+      @handleSizeChange="handleSizeChange"
+      @handleCurrentChange="handleCurrentChange"
+    />
+    <addClass ref="addClass" @backFunc="search(2)"></addClass>
+    <remark ref="remark" @backFunc="search()"></remark>
+  </div>
+</template>
+
+<script>
+import remark from "./remark.vue";
+import searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+import addClass from "./addClass.vue";
+export default {
+  components: { remark, searchBoxNew, tableList, pagination, addClass },
+  // name: "ClassList",
+  data() {
+    return {
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        border: true,
+        title: "班级列表",
+        index: 0,
+        ch: "条",
+        num: false,
+        choice: true,
+        addHide: true,
+        backFatherBtn: {
+          status: false,
+          title: "未定义",
+        },
+      },
+      //搜索
+      formList: [
+        {
+          prop: "educationTypeId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationTypeId",
+        },
+        { 
+          prop: "majorId",
+          placeholder: "专业",
+          scope: "Professional",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "status",
+          placeholder: "班级状态",
+          scope: "select",
+          noClear: false,
+          options: [
+            {
+              label: "全部状态",
+              value: '0,1',
+            },
+            { label: "开启", value: 1 },
+            { label: "关闭", value: 0 },
+          ],
+        },
+        {
+          prop: "classStatus",
+          placeholder: "开班状态",
+          scope: "select",
+          options: [
+            { label: "已过期", value: 2 },
+            { label: "未过期", value: 1 },
+            { label: "未开班", value: 0 },
+          ],
+        },
+        {
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          placeholder1: "班级有效期开始时间",
+          placeholder2: "班级有效期结束时间",
+          scope: "moreDataPicker",
+        },
+        {
+          prop: "searchKey",
+          placeholder: "请输入班级名称/商品名称",
+        },
+      ],
+      formData: {
+        status: "0,1",
+        pageSize: 10,
+        pageNum: 1,
+        classStatus: "",
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "所属商品",
+          hidden: true,
+          scope: "slot",
+          slotName: "goodsInfo",
+        },
+        {
+          label: "班级名称",
+          prop: "className",
+          hidden: true,
+        },
+        {
+          label: "班级人数",
+          prop1: "studentNum",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+        },
+        {
+          label: "班级总人数",
+          prop1: "studentNumAll",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+        },
+        {
+          label: "班级状态",
+          prop: "status",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "开启",
+              value: 1,
+            },
+            {
+              label: "关闭",
+              value: 0,
+            },
+          ],
+        },
+        {
+          label: "开放学习",
+          prop: "learningStatus",
+          prop1: "learningTimeStart",
+          hidden: true,
+          scope: "classTimeTypes",
+        },
+        {
+          label: "官方班级号",
+          prop: "classStatus",
+          prop1: "officialName",
+          hidden: true,
+          scope: "classTypes",
+        },
+        {
+          label: "开班状态",
+          hidden: true,
+          scope: "slot",
+          slotName: "TimeLists",
+        },
+        {
+          label: "备注",
+          prop: "remark",
+          hidden: true,
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+    };
+  },
+  mounted() {
+    this.init();
+  },
+  methods: {
+    remark(item) {
+      this.$refs.remark.openBoxs(item);
+    },
+    getClassStatus(item) {
+      let nowTime = parseInt(new Date().getTime() / 1000);
+      if (
+        item.classStartTime &&
+        item.classEndTime &&
+        item.classEndTime > nowTime &&
+        item.classStartTime < nowTime
+      ) {
+        return "未过期";
+      } else if (item.classStartTime && item.classStartTime > nowTime) {
+        return "未开始";
+      } else if (item.classEndTime && item.classEndTime < nowTime) {
+        return "已过期";
+      } else {
+        return "未开班";
+      }
+    },
+    editInfo(v) {
+      this.addClick(v, 2);
+    },
+    search(int) {
+      this.loading = true;
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      if (int === 2) {
+        this.formData = {
+          status: "0,1",
+          pageSize: 10,
+          pageNum: 1,
+          classStatus: "",
+        };
+      }
+      var data = JSON.parse(JSON.stringify(this.formData));
+      if (this.formData.classStartTime) {
+        data.classStartTime = parseInt(data.classStartTime / 1000);
+      }
+      if (this.formData.classEndTime) {
+        data.classEndTime = parseInt(data.classEndTime / 1000);
+      }
+      this.$api
+        .inquireGradegradesearchList(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    del(v) {
+      this.$alert(
+        "确定删除此内容?<br />内容删除后将无法恢复,请慎重考虑",
+        "提示",
+        {
+          dangerouslyUseHTMLString: true,
+        }
+      )
+        .then(() => {
+          var data = {
+            gradeId: v.gradeId,
+            status: -1,
+          };
+          this.$api.editGradegrade(data).then((res) => {
+            this.$message.success("删除成功");
+            this.search();
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    addClick(v, int) {
+      // int = 2详情 3学员管理
+      if (v === undefined) {
+        // 添加班级
+        this.$refs.addClass.inits();
+      } else {
+        if (int === 2) {
+          const jump = () => {
+            //班级详情
+            this.$router.push({
+              path: "manageClass",
+              query: {
+                id: v.gradeId,
+              },
+            });
+          };
+          const statusPage = this.$store.state.tagsView.visitedViews.some(
+            (item) => {
+              return item.name == "ManageClass";
+            }
+          );
+          if (statusPage) {
+            this.$store
+              .dispatch("tagsView/delCachedView", {
+                name: "ManageClass",
+              })
+              .then((res) => {
+                jump();
+              });
+          } else {
+            jump();
+          }
+        }
+        if (int === 3) {
+          // 学员管理
+          this.$router.push({
+            path: "classStudent",
+            query: {
+              id: v.gradeId,
+              goodsId: v.goodsList[0].goodsId,
+            },
+          });
+        }
+      }
+    },
+    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></style>

+ 54 - 0
src/views/education/classManageMent/classList/classList/remark.vue

@@ -0,0 +1,54 @@
+<template>
+  <div id="">
+    <BaseDialog
+      width="800px"
+      :isShow.sync="isShow"
+      title="备注"
+      @close="close"
+      @submit="submitForm"
+      @open="init"
+    >
+      <el-input
+        type="textarea"
+        :rows="6"
+        placeholder="请输入备注"
+        v-model="remark"
+      >
+      </el-input>
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      isShow: false,
+      remark: "",
+      gradeId: "",
+    };
+  },
+  methods: {
+    openBoxs(item) {
+      this.gradeId = item.gradeId;
+      this.remark = item.remark;
+      this.isShow = true;
+    },
+    init() {},
+    submitForm() {
+      this.$api
+        .editGradegrade({
+          gradeId: this.gradeId,
+          remark: this.remark,
+        })
+        .then((res) => {
+          this.isShow = false;
+          this.$emit("backFunc");
+        });
+    },
+    close() {},
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 18 - 0
src/views/education/classManageMent/classList/classStudent/index.vue

@@ -0,0 +1,18 @@
+<template>
+  <div id="">
+    <trainee :showStatus="false"></trainee>
+  </div>
+</template>
+
+<script>
+import trainee from "../trainee/index.vue";
+export default {
+  components: { trainee },
+  data() {
+    return {};
+  },
+  methods: {},
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 554 - 0
src/views/education/classManageMent/classList/index copy 2.vue

@@ -0,0 +1,554 @@
+<template>
+  <div id="classList">
+    <search-box-new
+      ref="searchBox"
+      :formData="formData"
+      :formList="formList"
+      @search="search"
+      @init="init"
+    />
+    <table-list
+      :tableSets="tableSet"
+      :tableData="tableData"
+      :navText="navText"
+      @addClick="addClick"
+      :loading="loading"
+      @editInfo="editInfo"
+    >
+      <template slot="btn" slot-scope="props">
+        <el-button type="text" @click="addClick(props.scope.row, 2)"
+          >详情</el-button
+        >
+        <el-button type="text" @click="addClick(props.scope.row, 3)"
+          >学员管理</el-button
+        >
+        <el-button type="text" @click="del(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 searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+export default {
+  components: { searchBoxNew, tableList, pagination },
+  name: "ClassList",
+  data() {
+    return {
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        border: true,
+        title: "班级管理",
+        index: 0,
+        ch: "条",
+        num: false,
+        choice: true,
+        addHide: false,
+        backFatherBtn: {
+          status: false,
+          title: "未定义",
+        },
+      },
+      //搜索
+      formList: [
+        {
+          prop: "educationTypeId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "schoolId",
+          placeholder: "院校",
+          scope: "schoolList",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "majorId",
+          placeholder: "专业",
+          scope: "Professional",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "subjectId",
+          placeholder: "科目",
+          scope: "sujectType",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "classStatus",
+          placeholder: "开班状态",
+          scope: "select",
+          options: [
+            { label: "已开班", value: 1 },
+            { label: "预报名(未开班)", value: 0 },
+          ],
+        },
+        {
+          prop: "status",
+          placeholder: "班级状态",
+          scope: "select",
+          noClear: false,
+          options: [
+            { label: "全部状态", value: "0,1" },
+            { label: "无效", value: 0 },
+            { label: "有效", value: 1 },
+          ],
+        },
+        {
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          placeholder1: "班级有效期开始时间",
+          placeholder2: "班级有效期结束时间",
+          scope: "moreDataPicker",
+        },
+        {
+          prop: "searchKey",
+          placeholder: "请输入班级名称/商品名称",
+        },
+        {
+          prop: "userName",
+          placeholder: "请输入学员姓名",
+        },
+      ],
+      formData: {
+        status: "0,1",
+        pageSize: 10,
+        pageNum: 1,
+        classStatus: "",
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "商品编码",
+          prop: "code",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objType",
+        },
+        {
+          label: "年份",
+          prop: "year",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objType",
+        },
+        {
+          label: "商品业务层级",
+          prop1: "educationName",
+          prop2: "projectName",
+          prop3: "businessName",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objTypeYW",
+        },
+        {
+          label: "商品名称",
+          prop: "goodsName",
+          objProp: "goodsList",
+          hidden: true,
+          scope: "objType",
+        },
+        {
+          label: "科目",
+          prop: "subjectNames",
+          hidden: true,
+        },
+        {
+          label: "班级编码",
+          prop: "gradeCode",
+          hidden: false,
+        },
+        {
+          label: "班级号",
+          prop: "classStatus",
+          prop1: "officialName",
+          hidden: true,
+          scope: "classTypes",
+        },
+        {
+          label: "班级名称",
+          prop: "className",
+          hidden: true,
+          scope: "editInfo",
+        },
+        {
+          label: "学时",
+          prop: "classHours",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objType",
+        },
+        {
+          label: "班主任",
+          prop: "nickName",
+          hidden: false,
+        },
+        {
+          label: "班级人数",
+          prop1: "studentNum",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+        },
+        {
+          label: "班级总人数",
+          prop1: "studentNumAll",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+        },
+        {
+          label: "开放学习时间",
+          prop: "learningStatus",
+          prop1: "learningTimeStart",
+          hidden: true,
+          scope: "classTimeTypes",
+        },
+        {
+          label: "班级状态",
+          prop: "status",
+          hidden: false,
+          scope: "isOptions",
+          options: [
+            {
+              label: "有效",
+              value: 1,
+            },
+            {
+              label: "无效",
+              value: 0,
+            },
+          ],
+        },
+        {
+          label: "班级有效期",
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          hidden: true,
+          Diszing: false,
+          scope: "TimeLists",
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+    };
+  },
+  async mounted() {
+    if (Object.keys(this.$route.params).length) {
+      if (this.$route.params.educationId) {
+        this.$set(
+          this.formData,
+          "educationTypeId",
+          this.$route.params.educationId
+        );
+        this.$refs.searchBox.changeEducationType(
+          this.$route.params.educationId,
+          true
+        );
+      }
+      if (this.$route.params.businessId) {
+        this.$set(this.formData, "businessId", this.$route.params.businessId);
+        this.$refs.searchBox.changeBusinessLevel(this.$route.params.businessId);
+      }
+      if (this.$route.params.userId) {
+        this.$set(this.formData, "userId", this.$route.params.userId);
+      }
+      if (this.$route.params.classStatus >= 0) {
+        this.$set(this.formData, "classStatus", this.$route.params.classStatus);
+      }
+      if (this.$route.params.hasInterface >= 0) {
+        this.formData.hasInterface = this.$route.params.hasInterface;
+      }
+    } else {
+      // await this.moRenBus();
+    }
+    if (this.$route.params.timeType >= 0) {
+      this.$set(
+        this.formData,
+        "classStartTime",
+        this.$methodsTools.timestampConvert(this.$route.params.timeType)[0]
+      );
+      this.$set(
+        this.formData,
+        "classEndTime",
+        this.$methodsTools.timestampConvert(this.$route.params.timeType)[1]
+      );
+    }
+    this.search();
+  },
+  activated() {
+    this.search();
+  },
+  methods: {
+    /**
+     * 默认选择继教二建业务层次
+     */
+    moRenBus() {
+      return new Promise((resolve, reject) => {
+        this.$api.inquireCourseEducationType({ status: 1 }).then((res) => {
+          console.log(res);
+          for (let i = 0; i < res.rows.length; i++) {
+            if (res.rows[i].educationName === "继续教育") {
+              this.$api
+                .inquirebusinessList({ status: 1, educationId: res.rows[i].id })
+                .then((result) => {
+                  for (let j = 0; j < result.rows.length; j++) {
+                    if (
+                      result.rows[j].projectName === "建造师" &&
+                      result.rows[j].businessName === "二级"
+                    ) {
+                      this.$set(
+                        this.formData,
+                        "educationTypeId",
+                        res.rows[i].id
+                      );
+                      this.$refs.searchBox.changeEducationType(
+                        res.rows[i].id,
+                        true
+                      );
+                      this.$set(this.formData, "businessId", result.rows[j].id);
+                      this.$refs.searchBox.changeBusinessLevel(
+                        result.rows[j].id
+                      );
+                      resolve();
+                      break;
+                    }
+                  }
+                });
+              break;
+            }
+          }
+        });
+      });
+    },
+    editInfo(v) {
+      this.addClick(v, 2);
+    },
+    search(int) {
+      this.loading = true;
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      if (int === 2) {
+        this.formData = {
+          status: "0,1",
+          pageSize: 10,
+          pageNum: 1,
+          classStatus: "",
+        };
+      }
+      if (int === 4) {
+        this.formData.pageNum = 1;
+      }
+      var data = JSON.parse(JSON.stringify(this.formData));
+      if (this.formData.classStartTime) {
+        data.classStartTime = parseInt(data.classStartTime / 1000);
+      }
+      if (this.formData.classEndTime) {
+        data.classEndTime = parseInt(data.classEndTime / 1000);
+      }
+      this.$api
+        .inquireGradegradesearchList(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    del(v) {
+      this.$alert(
+        "确定删除此内容?<br />内容删除后将无法恢复,请慎重考虑",
+        "提示",
+        {
+          dangerouslyUseHTMLString: true,
+        }
+      )
+        .then(() => {
+          var data = {
+            gradeId: v.gradeId,
+            status: -1,
+          };
+          this.$api.editGradegrade(data).then((res) => {
+            this.$message.success("删除成功");
+            this.search();
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    addClick(v, int) {
+      // int = 2详情 3学员管理
+      if (v === undefined) {
+        // 添加班级
+        this.$router.push({
+          path: "addClass",
+        });
+      } else {
+        if (int === 2) {
+          const jump = () => {
+            //班级详情
+            this.$router.push({
+              path: "manageClass",
+              query: {
+                id: v.gradeId,
+              },
+            });
+          };
+          const statusPage = this.$store.state.tagsView.visitedViews.some(
+            (item) => {
+              return item.name == "ManageClass";
+            }
+          );
+          if (statusPage) {
+            this.$store
+              .dispatch("tagsView/delCachedView", {
+                name: "ManageClass",
+              })
+              .then((res) => {
+                jump();
+              });
+          } else {
+            jump();
+          }
+        }
+        if (int === 3) {
+          // 学员管理
+          this.$router.push({
+            path: "studentMenu",
+            query: {
+              id: v.gradeId,
+              goodsId: v.goodsList[0].goodsId,
+            },
+          });
+        }
+      }
+    },
+    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;
+  }
+}
+</style>

+ 554 - 0
src/views/education/classManageMent/classList/index copy.vue

@@ -0,0 +1,554 @@
+<template>
+  <div id="classList">
+    <search-box-new
+      ref="searchBox"
+      :formData="formData"
+      :formList="formList"
+      @search="search"
+      @init="init"
+    />
+    <table-list
+      :tableSets="tableSet"
+      :tableData="tableData"
+      :navText="navText"
+      @addClick="addClick"
+      :loading="loading"
+      @editInfo="editInfo"
+    >
+      <template slot="btn" slot-scope="props">
+        <el-button type="text" @click="addClick(props.scope.row, 2)"
+          >详情</el-button
+        >
+        <el-button type="text" @click="addClick(props.scope.row, 3)"
+          >学员管理</el-button
+        >
+        <el-button type="text" @click="del(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 searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+export default {
+  components: { searchBoxNew, tableList, pagination },
+  name: "ClassList",
+  data() {
+    return {
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        border: true,
+        title: "班级管理",
+        index: 0,
+        ch: "条",
+        num: false,
+        choice: true,
+        addHide: false,
+        backFatherBtn: {
+          status: false,
+          title: "未定义",
+        },
+      },
+      //搜索
+      formList: [
+        {
+          prop: "educationTypeId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "schoolId",
+          placeholder: "院校",
+          scope: "schoolList",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "majorId",
+          placeholder: "专业",
+          scope: "Professional",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "subjectId",
+          placeholder: "科目",
+          scope: "sujectType",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "classStatus",
+          placeholder: "开班状态",
+          scope: "select",
+          options: [
+            { label: "已开班", value: 1 },
+            { label: "预报名(未开班)", value: 0 },
+          ],
+        },
+        {
+          prop: "status",
+          placeholder: "班级状态",
+          scope: "select",
+          noClear: false,
+          options: [
+            { label: "全部状态", value: "0,1" },
+            { label: "无效", value: 0 },
+            { label: "有效", value: 1 },
+          ],
+        },
+        {
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          placeholder1: "班级有效期开始时间",
+          placeholder2: "班级有效期结束时间",
+          scope: "moreDataPicker",
+        },
+        {
+          prop: "searchKey",
+          placeholder: "请输入班级名称/商品名称",
+        },
+        {
+          prop: "userName",
+          placeholder: "请输入学员姓名",
+        },
+      ],
+      formData: {
+        status: "0,1",
+        pageSize: 10,
+        pageNum: 1,
+        classStatus: "",
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "商品编码",
+          prop: "code",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objType",
+        },
+        {
+          label: "年份",
+          prop: "year",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objType",
+        },
+        {
+          label: "商品业务层级",
+          prop1: "educationName",
+          prop2: "projectName",
+          prop3: "businessName",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objTypeYW",
+        },
+        {
+          label: "商品名称",
+          prop: "goodsName",
+          objProp: "goodsList",
+          hidden: true,
+          scope: "objType",
+        },
+        {
+          label: "科目",
+          prop: "subjectNames",
+          hidden: true,
+        },
+        {
+          label: "班级编码",
+          prop: "gradeCode",
+          hidden: false,
+        },
+        {
+          label: "班级号",
+          prop: "classStatus",
+          prop1: "officialName",
+          hidden: true,
+          scope: "classTypes",
+        },
+        {
+          label: "班级名称",
+          prop: "className",
+          hidden: true,
+          scope: "editInfo",
+        },
+        {
+          label: "学时",
+          prop: "classHours",
+          objProp: "goodsList",
+          hidden: false,
+          scope: "objType",
+        },
+        {
+          label: "班主任",
+          prop: "nickName",
+          hidden: false,
+        },
+        {
+          label: "班级人数",
+          prop1: "studentNum",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+        },
+        {
+          label: "班级总人数",
+          prop1: "studentNumAll",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+        },
+        {
+          label: "开放学习时间",
+          prop: "learningStatus",
+          prop1: "learningTimeStart",
+          hidden: true,
+          scope: "classTimeTypes",
+        },
+        {
+          label: "班级状态",
+          prop: "status",
+          hidden: false,
+          scope: "isOptions",
+          options: [
+            {
+              label: "有效",
+              value: 1,
+            },
+            {
+              label: "无效",
+              value: 0,
+            },
+          ],
+        },
+        {
+          label: "班级有效期",
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          hidden: true,
+          Diszing: false,
+          scope: "TimeLists",
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+    };
+  },
+  async mounted() {
+    if (Object.keys(this.$route.params).length) {
+      if (this.$route.params.educationId) {
+        this.$set(
+          this.formData,
+          "educationTypeId",
+          this.$route.params.educationId
+        );
+        this.$refs.searchBox.changeEducationType(
+          this.$route.params.educationId,
+          true
+        );
+      }
+      if (this.$route.params.businessId) {
+        this.$set(this.formData, "businessId", this.$route.params.businessId);
+        this.$refs.searchBox.changeBusinessLevel(this.$route.params.businessId);
+      }
+      if (this.$route.params.userId) {
+        this.$set(this.formData, "userId", this.$route.params.userId);
+      }
+      if (this.$route.params.classStatus >= 0) {
+        this.$set(this.formData, "classStatus", this.$route.params.classStatus);
+      }
+      if (this.$route.params.hasInterface >= 0) {
+        this.formData.hasInterface = this.$route.params.hasInterface;
+      }
+    } else {
+      // await this.moRenBus();
+    }
+    if (this.$route.params.timeType >= 0) {
+      this.$set(
+        this.formData,
+        "classStartTime",
+        this.$methodsTools.timestampConvert(this.$route.params.timeType)[0]
+      );
+      this.$set(
+        this.formData,
+        "classEndTime",
+        this.$methodsTools.timestampConvert(this.$route.params.timeType)[1]
+      );
+    }
+    this.search();
+  },
+  activated() {
+    this.search();
+  },
+  methods: {
+    /**
+     * 默认选择继教二建业务层次
+     */
+    moRenBus() {
+      return new Promise((resolve, reject) => {
+        this.$api.inquireCourseEducationType({ status: 1 }).then((res) => {
+          console.log(res);
+          for (let i = 0; i < res.rows.length; i++) {
+            if (res.rows[i].educationName === "继续教育") {
+              this.$api
+                .inquirebusinessList({ status: 1, educationId: res.rows[i].id })
+                .then((result) => {
+                  for (let j = 0; j < result.rows.length; j++) {
+                    if (
+                      result.rows[j].projectName === "建造师" &&
+                      result.rows[j].businessName === "二级"
+                    ) {
+                      this.$set(
+                        this.formData,
+                        "educationTypeId",
+                        res.rows[i].id
+                      );
+                      this.$refs.searchBox.changeEducationType(
+                        res.rows[i].id,
+                        true
+                      );
+                      this.$set(this.formData, "businessId", result.rows[j].id);
+                      this.$refs.searchBox.changeBusinessLevel(
+                        result.rows[j].id
+                      );
+                      resolve();
+                      break;
+                    }
+                  }
+                });
+              break;
+            }
+          }
+        });
+      });
+    },
+    editInfo(v) {
+      this.addClick(v, 2);
+    },
+    search(int) {
+      this.loading = true;
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      if (int === 2) {
+        this.formData = {
+          status: "0,1",
+          pageSize: 10,
+          pageNum: 1,
+          classStatus: "",
+        };
+      }
+      if (int === 4) {
+        this.formData.pageNum = 1;
+      }
+      var data = JSON.parse(JSON.stringify(this.formData));
+      if (this.formData.classStartTime) {
+        data.classStartTime = parseInt(data.classStartTime / 1000);
+      }
+      if (this.formData.classEndTime) {
+        data.classEndTime = parseInt(data.classEndTime / 1000);
+      }
+      this.$api
+        .inquireGradegradesearchList(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    del(v) {
+      this.$alert(
+        "确定删除此内容?<br />内容删除后将无法恢复,请慎重考虑",
+        "提示",
+        {
+          dangerouslyUseHTMLString: true,
+        }
+      )
+        .then(() => {
+          var data = {
+            gradeId: v.gradeId,
+            status: -1,
+          };
+          this.$api.editGradegrade(data).then((res) => {
+            this.$message.success("删除成功");
+            this.search();
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    addClick(v, int) {
+      // int = 2详情 3学员管理
+      if (v === undefined) {
+        // 添加班级
+        this.$router.push({
+          path: "addClass",
+        });
+      } else {
+        if (int === 2) {
+          const jump = () => {
+            //班级详情
+            this.$router.push({
+              path: "manageClass",
+              query: {
+                id: v.gradeId,
+              },
+            });
+          };
+          const statusPage = this.$store.state.tagsView.visitedViews.some(
+            (item) => {
+              return item.name == "ManageClass";
+            }
+          );
+          if (statusPage) {
+            this.$store
+              .dispatch("tagsView/delCachedView", {
+                name: "ManageClass",
+              })
+              .then((res) => {
+                jump();
+              });
+          } else {
+            jump();
+          }
+        }
+        if (int === 3) {
+          // 学员管理
+          this.$router.push({
+            path: "studentMenu",
+            query: {
+              id: v.gradeId,
+              goodsId: v.goodsList[0].goodsId,
+            },
+          });
+        }
+      }
+    },
+    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;
+  }
+}
+</style>

+ 14 - 445
src/views/education/classManageMent/classList/index.vue

@@ -1,461 +1,30 @@
 <template>
   <div id="classList">
-    <search-box-new
-      ref="searchBox"
-      :formData="formData"
-      :formList="formList"
-      @search="search"
-      @init="init"
-    />
-    <table-list
-      :tableSets="tableSet"
-      :tableData="tableData"
-      :navText="navText"
-      @addClick="addClick"
-      :loading="loading"
-      @editInfo="editInfo"
-    >
-      <template slot="btn" slot-scope="props">
-        <el-button type="text" @click="addClick(props.scope.row, 2)"
-          >详情</el-button
-        >
-        <el-button type="text" @click="addClick(props.scope.row, 3)"
-          >学员管理</el-button
-        >
-        <el-button type="text" @click="del(props.scope.row)">删除</el-button>
-      </template>
-    </table-list>
-    <pagination
-      :total="total"
-      :pageSize="formData.pageSize"
-      :currentPage="formData.pageNum"
-      @handleSizeChange="handleSizeChange"
-      @handleCurrentChange="handleCurrentChange"
-    />
+    <el-tabs v-model="activeName" @tab-click="handleClick">
+      <el-tab-pane label="班级列表" name="first">
+        <class-list v-if="activeName == 'first'"></class-list>
+      </el-tab-pane>
+      <el-tab-pane label="报班学员" name="second">
+        <trainee v-if="activeName == 'second'"></trainee>
+      </el-tab-pane>
+    </el-tabs>
   </div>
 </template>
 
 <script>
-import searchBoxNew from "@/components/searchBoxNew";
-import tableList from "@/components/tableList";
-import pagination from "@/components/pagination";
+import classList from "./classList";
+import trainee from "./trainee";
 export default {
-  components: { searchBoxNew, tableList, pagination },
+  components: { classList, trainee },
   name: "ClassList",
   data() {
     return {
-      loading: false, //当前表单加载是否加载动画
-      navText: {
-        border: true,
-        title: "班级管理",
-        index: 0,
-        ch: "条",
-        num: false,
-        choice: true,
-        addHide: false,
-        backFatherBtn: {
-          status: false,
-          title: "未定义",
-        },
-      },
-      //搜索
-      formList: [
-        {
-          prop: "educationTypeId",
-          placeholder: "教育类型",
-          scope: "educationType",
-        },
-        {
-          prop: "businessId",
-          placeholder: "业务层次",
-          scope: "businessLevel",
-          edu: "educationTypeId",
-        },
-        {
-          prop: "schoolId",
-          placeholder: "院校",
-          scope: "schoolList",
-          edu: "educationTypeId",
-        },
-        {
-          prop: "majorId",
-          placeholder: "专业",
-          scope: "Professional",
-          edu: "educationTypeId",
-        },
-        {
-          prop: "subjectId",
-          placeholder: "科目",
-          scope: "sujectType",
-          edu: "educationTypeId",
-        },
-        {
-          prop: "classStatus",
-          placeholder: "开班状态",
-          scope: "select",
-          options: [
-            { label: "已开班", value: 1 },
-            { label: "预报名(未开班)", value: 0 },
-          ],
-        },
-        {
-          prop: "status",
-          placeholder: "班级状态",
-          scope: "select",
-          noClear: false,
-          options: [
-            { label: "全部状态", value: "0,1" },
-            { label: "无效", value: 0 },
-            { label: "有效", value: 1 },
-          ],
-        },
-        {
-          prop1: "classStartTime",
-          prop2: "classEndTime",
-          placeholder1: "班级有效期开始时间",
-          placeholder2: "班级有效期结束时间",
-          scope: "moreDataPicker",
-        },
-        {
-          prop: "searchKey",
-          placeholder: "请输入班级名称/商品名称",
-        },
-        {
-          prop: "userName",
-          placeholder: "请输入学员姓名",
-        },
-      ],
-      formData: {
-        status: "0,1",
-        pageSize: 10,
-        pageNum: 1,
-        classStatus: "",
-      },
-      // 表单
-      tableSet: [
-        {
-          label: "商品编码",
-          prop: "code",
-          objProp: "goodsList",
-          hidden: false,
-          scope: "objType",
-        },
-        {
-          label: "年份",
-          prop: "year",
-          objProp: "goodsList",
-          hidden: false,
-          scope: "objType",
-        },
-        {
-          label: "商品业务层级",
-          prop1: "educationName",
-          prop2: "projectName",
-          prop3: "businessName",
-          objProp: "goodsList",
-          hidden: false,
-          scope: "objTypeYW",
-        },
-        {
-          label: "商品名称",
-          prop: "goodsName",
-          objProp: "goodsList",
-          hidden: true,
-          scope: "objType",
-        },
-        {
-          label: "科目",
-          prop: "subjectNames",
-          hidden: true,
-        },
-        {
-          label: "班级编码",
-          prop: "gradeCode",
-          hidden: false,
-        },
-        {
-          label: "班级号",
-          prop: "classStatus",
-          prop1: "officialName",
-          hidden: true,
-          scope: "classTypes",
-        },
-        {
-          label: "班级名称",
-          prop: "className",
-          hidden: true,
-          scope: "editInfo",
-        },
-        {
-          label: "学时",
-          prop: "classHours",
-          objProp: "goodsList",
-          hidden: false,
-          scope: "objType",
-        },
-        {
-          label: "班主任",
-          prop: "nickName",
-          hidden: false,
-        },
-        {
-          label: "班级人数",
-          prop1: "studentNum",
-          prop2: "studentUpper",
-          hidden: true,
-          scope: "peopleNums",
-        },
-        {
-          label: "班级总人数",
-          prop1: "studentNumAll",
-          prop2: "studentUpper",
-          hidden: true,
-          scope: "peopleNums",
-        },
-        {
-          label: "开放学习时间",
-          prop: "learningStatus",
-          prop1: "learningTimeStart",
-          hidden: true,
-          scope: "classTimeTypes",
-        },
-        {
-          label: "班级状态",
-          prop: "status",
-          hidden: false,
-          scope: "isOptions",
-          options: [
-            {
-              label: "有效",
-              value: 1,
-            },
-            {
-              label: "无效",
-              value: 0,
-            },
-          ],
-        },
-        {
-          label: "班级有效期",
-          prop1: "classStartTime",
-          prop2: "classEndTime",
-          hidden: true,
-          Diszing: false,
-          scope: "TimeLists",
-        },
-      ],
-      tableData: [], //表单数据
-      total: 0, //一共多少条
+      activeName: "first",
     };
   },
-  async mounted() {
-    if (Object.keys(this.$route.params).length) {
-      if (this.$route.params.educationId) {
-        this.$set(
-          this.formData,
-          "educationTypeId",
-          this.$route.params.educationId
-        );
-        this.$refs.searchBox.changeEducationType(
-          this.$route.params.educationId,
-          true
-        );
-      }
-      if (this.$route.params.businessId) {
-        this.$set(this.formData, "businessId", this.$route.params.businessId);
-        this.$refs.searchBox.changeBusinessLevel(this.$route.params.businessId);
-      }
-      if (this.$route.params.userId) {
-        this.$set(this.formData, "userId", this.$route.params.userId);
-      }
-      if (this.$route.params.classStatus >= 0) {
-        this.$set(this.formData, "classStatus", this.$route.params.classStatus);
-      }
-      if (this.$route.params.hasInterface >= 0) {
-        this.formData.hasInterface = this.$route.params.hasInterface;
-      }
-    } else {
-      // await this.moRenBus();
-    }
-    if (this.$route.params.timeType >= 0) {
-      this.$set(
-        this.formData,
-        "classStartTime",
-        this.$methodsTools.timestampConvert(this.$route.params.timeType)[0]
-      );
-      this.$set(
-        this.formData,
-        "classEndTime",
-        this.$methodsTools.timestampConvert(this.$route.params.timeType)[1]
-      );
-    }
-    this.search();
-  },
-  activated() {
-    this.search();
-  },
   methods: {
-    /**
-     * 默认选择继教二建业务层次
-     */
-    moRenBus() {
-      return new Promise((resolve, reject) => {
-        this.$api.inquireCourseEducationType({ status: 1 }).then((res) => {
-          console.log(res);
-          for (let i = 0; i < res.rows.length; i++) {
-            if (res.rows[i].educationName === "继续教育") {
-              this.$api
-                .inquirebusinessList({ status: 1, educationId: res.rows[i].id })
-                .then((result) => {
-                  for (let j = 0; j < result.rows.length; j++) {
-                    if (
-                      result.rows[j].projectName === "建造师" &&
-                      result.rows[j].businessName === "二级"
-                    ) {
-                      this.$set(
-                        this.formData,
-                        "educationTypeId",
-                        res.rows[i].id
-                      );
-                      this.$refs.searchBox.changeEducationType(
-                        res.rows[i].id,
-                        true
-                      );
-                      this.$set(this.formData, "businessId", result.rows[j].id);
-                      this.$refs.searchBox.changeBusinessLevel(
-                        result.rows[j].id
-                      );
-                      resolve();
-                      break;
-                    }
-                  }
-                });
-              break;
-            }
-          }
-        });
-      });
-    },
-    editInfo(v) {
-      this.addClick(v, 2);
-    },
-    search(int) {
-      this.loading = true;
-      if (int === 1) {
-        this.formData.pageNum = 1;
-      }
-      if (int === 2) {
-        this.formData = {
-          status: "0,1",
-          pageSize: 10,
-          pageNum: 1,
-          classStatus: "",
-        };
-      }
-      if (int === 4) {
-        this.formData.pageNum = 1;
-      }
-      var data = JSON.parse(JSON.stringify(this.formData));
-      if (this.formData.classStartTime) {
-        data.classStartTime = parseInt(data.classStartTime / 1000);
-      }
-      if (this.formData.classEndTime) {
-        data.classEndTime = parseInt(data.classEndTime / 1000);
-      }
-      this.$api
-        .inquireGradegradesearchList(data)
-        .then((res) => {
-          this.tableData = res.rows;
-          this.total = res.total;
-          this.navText.index = res.total;
-        })
-        .finally(() => {
-          this.loading = false;
-        });
-    },
-    init() {
-      this.search(2);
-    },
-    del(v) {
-      this.$alert(
-        "确定删除此内容?<br />内容删除后将无法恢复,请慎重考虑",
-        "提示",
-        {
-          dangerouslyUseHTMLString: true,
-        }
-      )
-        .then(() => {
-          var data = {
-            gradeId: v.gradeId,
-            status: -1,
-          };
-          this.$api.editGradegrade(data).then((res) => {
-            this.$message.success("删除成功");
-            this.search();
-          });
-        })
-        .catch(() => {
-          this.$message({
-            type: "info",
-            message: "已取消删除",
-          });
-        });
-    },
-    addClick(v, int) {
-      // int = 2详情 3学员管理
-      if (v === undefined) {
-        // 添加班级
-        this.$router.push({
-          path: "addClass",
-        });
-      } else {
-        if (int === 2) {
-          const jump = () => {
-            //班级详情
-            this.$router.push({
-              path: "manageClass",
-              query: {
-                id: v.gradeId,
-              },
-            });
-          };
-          const statusPage = this.$store.state.tagsView.visitedViews.some(
-            (item) => {
-              return item.name == "ManageClass";
-            }
-          );
-          if (statusPage) {
-            this.$store
-              .dispatch("tagsView/delCachedView", {
-                name: "ManageClass",
-              })
-              .then((res) => {
-                jump();
-              });
-          } else {
-            jump();
-          }
-        }
-        if (int === 3) {
-          // 学员管理
-          this.$router.push({
-            path: "studentMenu",
-            query: {
-              id: v.gradeId,
-              goodsId: v.goodsList[0].goodsId,
-            },
-          });
-        }
-      }
-    },
-    handleSizeChange(v) {
-      this.formData.pageSize = v;
-      this.formData.pageNum = 1;
-      this.search();
-    },
-    handleCurrentChange(v) {
-      this.formData.pageNum = v;
-      this.search();
+    handleClick(tab, event) {
+      console.log(tab, event);
     },
   },
 };

+ 50 - 25
src/views/education/classManageMent/classList/manageClass/baseInfo.vue

@@ -1,7 +1,43 @@
 <template>
   <div id="baseInfo">
     <div class="YZsty">
-      <el-row :gutter="20">
+      <div class="top_style">所属商品</div>
+      <el-descriptions
+        class="margin-top"
+        title=""
+        :column="3"
+        :size="size"
+        border
+      >
+        <el-descriptions-item label="教育类型">
+          {{ listData.goodsList[0].educationName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="业务层次">
+          {{listData.goodsList[0].projectName + ' - ' + listData.goodsList[0].businessName }}
+          
+        </el-descriptions-item>
+        <el-descriptions-item label="专业">
+          {{ listData.goodsList[0].categoryName }}
+          
+        </el-descriptions-item>
+        <el-descriptions-item label="商品名称">
+          {{ listData.goodsList[0].goodsName }}
+          
+        </el-descriptions-item>
+        <el-descriptions-item label="学时">
+          {{ listData.goodsList[0].classHours }}
+          
+        </el-descriptions-item>
+        <el-descriptions-item label="年份">
+          {{ listData.sevenYear || listData.goodsList[0].year }}
+          
+        </el-descriptions-item>
+      </el-descriptions>
+      <div class="top_style">班级信息</div>
+      <el-row
+        :gutter="20"
+        style="background: rgb(242, 242, 242); border-radius: 8px;padding: 20px;"
+      >
         <el-form
           label-position="right"
           label-width="130px"
@@ -9,26 +45,6 @@
           :rules="rules"
           ref="listData"
         >
-          <el-col :span="24">
-            <el-form-item label="所属商品课程">
-              <div class="flex_s">
-                <div style="display: flex">
-                  <div>商品业务层级:</div>
-                  <div style="flex: 1">
-                    {{
-                      `${listData.goodsList[0].educationName}-${listData.goodsList[0].projectName}-${listData.goodsList[0].businessName}`
-                    }}
-                  </div>
-                </div>
-                <div>学时:{{ listData.goodsList[0].classHours }}</div>
-                <div>年份:{{ listData.sevenYear || listData.goodsList[0].year }}</div>
-                <div>商品名称:{{ listData.goodsList[0].goodsName }}</div>
-              </div>
-            </el-form-item>
-          </el-col>
-          <el-col :span="24">
-            <div class="fgx"></div>
-          </el-col>
           <el-col :span="12">
             <el-form-item label="班级编码" prop="gradeCode">
               <el-input
@@ -278,7 +294,9 @@
                   placeholder="请选择官方学习账号开通"
                   :disabled="
                     copyData.noInterfaceAccountId || copyData.interfaceAccountId
-                      ? true : listData.noInterfaceAccountId ? true
+                      ? true
+                      : listData.noInterfaceAccountId
+                      ? true
                       : false
                   "
                   clearable
@@ -298,7 +316,9 @@
                   placeholder="请选择官方账号标记(无接口+标记功能)"
                   :disabled="
                     copyData.noInterfaceAccountId || copyData.interfaceAccountId
-                      ? true : listData.interfaceAccountId ? true
+                      ? true
+                      : listData.interfaceAccountId
+                      ? true
                       : false
                   "
                   clearable
@@ -626,9 +646,14 @@ export default {
 </script>
 
 <style lang="less" scoped>
+.top_style {
+  font-size: 16px;
+  padding: 10px;
+  font-weight: bold;
+  border-bottom: 2px solid #000;
+  margin-bottom: 10px;
+}
 .YZsty {
-  background-color: #eee;
-  padding: 30px;
   margin-top: 16px;
 }
 /deep/.el-button {

+ 7 - 12
src/views/education/classManageMent/classList/manageClass/studentRecords.vue

@@ -1,6 +1,7 @@
 <template>
   <div id="studentRecords">
     <div class="studentSty">
+      <div style="margin-bottom: 14px;">学员记录{{ total }}条</div>
       <el-table
         ref="multipleTable"
         :data="tableData"
@@ -11,6 +12,7 @@
           color: '#333',
         }"
       >
+      <el-table-column type="index" label="序号" align="center" width="80px"></el-table-column>
         <template v-for="(item, index) in tableList">
           <el-table-column
             v-if="item.scope !== 'inputs'"
@@ -22,18 +24,12 @@
             header-align="center"
           >
             <template slot-scope="scope">
-              <span v-if="item.scope === 'status'" style="color:#F56C6C;">
-                {{
-                  scope.row[item.prop] === 1
-                    ? "进入"
-                    : scope.row[item.prop] === 0
-                    ? "移除"
-                    : "未知"
-                }}
-              </span>
-              <span v-else-if="item.scope ==='aTime'">
+              <span v-if="item.scope ==='aTime'">
                 {{$methodsTools.onlyForma(scope.row[item.prop])}}
               </span>
+              <span v-else-if="item.scope ==='status'">
+                {{scope.row[item.prop] === 1 ? '进入':scope.row[item.prop] === 0?'移除':''}}
+              </span>
               <span v-else>{{ scope.row[item.prop] }}</span></template
             >
           </el-table-column></template
@@ -136,8 +132,7 @@ export default {
 
 <style lang="less" scoped>
 .studentSty {
-  background-color: #eee;
-  padding: 20px 10px;
+  padding: 0px 10px;
   margin-top: 16px;
 }
 .align_center {

+ 19 - 10
src/views/education/classManageMent/classList/manageClass/teacherRecords.vue

@@ -1,6 +1,7 @@
 <template>
   <div id="teacherRecords">
     <div class="teacherSty">
+      <div style="margin-bottom: 14px">班主任记录{{ total }}条</div>
       <el-table
         ref="multipleTable"
         :data="tableData"
@@ -11,6 +12,12 @@
           color: '#333',
         }"
       >
+        <el-table-column
+          type="index"
+          label="序号"
+          align="center"
+          width="80px"
+        ></el-table-column>
         <template v-for="(item, index) in tableList">
           <el-table-column
             v-if="item.scope !== 'inputs'"
@@ -93,7 +100,7 @@ export default {
           prop2: "endTime",
           prop: "status",
           scope: "teshu",
-          width:"330px"
+          width: "330px",
         },
         {
           label: "指派时间",
@@ -107,7 +114,7 @@ export default {
       ],
       total: 0,
       formData: {
-        gradeId:this.$route.query.id,
+        gradeId: this.$route.query.id,
         pageSize: 10,
         pageNum: 1,
       },
@@ -119,12 +126,15 @@ export default {
   methods: {
     search() {
       this.loading = true;
-      this.$api.inquireGradegradelistSysList(this.formData).then((res) => {
-        this.tableData = res.rows;
-        this.total = res.total;
-      }).finally(()=>{
-        this.loading = false;
-      })
+      this.$api
+        .inquireGradegradelistSysList(this.formData)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
     },
     handleSizeChange(v) {
       this.formData.pageSize = v;
@@ -149,8 +159,7 @@ export default {
 
 <style lang="less" scoped>
 .teacherSty {
-  background-color: #eee;
-  padding: 20px 10px;
+  padding: 0px 10px;
   margin-top: 16px;
 }
 .align_center {

+ 218 - 0
src/views/education/classManageMent/classList/trainee/changeClassDialog.vue

@@ -0,0 +1,218 @@
+<template>
+  <Base-dialog
+    title="更换班级"
+    width="1000px"
+    :isShow.sync="isShow"
+    @submit="submit"
+    @close="close"
+  >
+    <div>
+      <el-table
+      v-loading="loading"
+        ref="multipleTable"
+        :data="tableData"
+        border
+        :row-key="getRowKeys"
+        :header-cell-style="{
+          'background-color': '#eee',
+          padding: '8px',
+          color: '#333',
+        }"
+      >
+        <el-table-column label="" width="45" align="center">
+          <template scope="scope">
+            <el-radio
+              class="radioTables"
+              :label="scope.row.gradeId"
+              v-model="tableRadio"
+              :reserve-selection="true"
+              @change.native="getTemplateRow(scope.$index, scope.row)"
+              :disabled="
+                parseInt(scope.row.studentUpper) -
+                  parseInt(scope.row.studentNum) <
+                studentList.length
+                  ? true
+                  : false
+              "
+              >{{ "" }}</el-radio
+            >
+          </template>
+        </el-table-column>
+        <template v-for="(item, index) in tableSet">
+          <el-table-column
+            v-if="item.scope !== 'inputs'"
+            :width="item.width"
+            :key="index"
+            :label="item.label"
+            align="center"
+            :show-overflow-tooltip="true"
+            header-align="center"
+          >
+            <template slot-scope="scope">
+              <span v-if="item.scope === 'status'">
+                {{
+                  scope.row[item.prop] === 1
+                    ? "有效"
+                    : scope.row[item.prop] === 0
+                    ? "无效"
+                    : "未知"
+                }}
+              </span>
+              <span v-else-if="item.scope === 'openStatus'">
+                {{ scope.row[item.prop] === 0 ? "未开班" : "已开班" }}
+                {{
+                  scope.row[item.prop] === 1 ? scope.row["officialName"] : ""
+                }}
+              </span>
+              <span v-else-if="item.scope === 'moreList'">
+                {{
+                  scope.row[item.prop1] +
+                  "-" +
+                  scope.row[item.prop2] +
+                  "-" +
+                  scope.row[item.prop3]
+                }}
+              </span>
+              <span v-else-if="item.scope === 'classNums'">
+                {{ scope.row[item.prop1] + "/" + scope.row[item.prop2] }}
+              </span>
+              <span v-else-if="item.scope === 'timeTwo'">
+                {{ $methodsTools.onlyForma(scope.row[item.prop1], false) }}-{{
+                  $methodsTools.onlyForma(scope.row[item.prop2], false)
+                }}
+              </span>
+              <span v-else>{{ scope.row[item.prop] }}</span></template
+            >
+          </el-table-column></template
+        >
+      </el-table>
+      <pagination
+        :total="total"
+        :pageSize="formData.pageSize"
+        :currentPage="formData.pageNum"
+        @handleSizeChange="handleSizeChange"
+        @handleCurrentChange="handleCurrentChange"
+      />
+    </div>
+  </Base-dialog>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      studentList: [],
+      tableSet: [
+        {
+          label: "班级编码",
+          prop: "gradeCode",
+        },
+        {
+          label: "班级号",
+          prop: "classStatus",
+          prop1: "officialName",
+          scope: "openStatus",
+        },
+        {
+          label: "班级名称",
+          prop: "className",
+        },
+        {
+          label: "班级人数",
+          prop1: "studentNum",
+          prop2: "studentUpper",
+          scope: "classNums",
+        },
+        {
+          label: "班级状态",
+          prop: "status",
+          scope: "status",
+        },
+        {
+          label: "班级有效期",
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          scope: "timeTwo",
+        },
+      ],
+      tableData: [],
+      loading: false,
+      total: 0,
+      tableRadio: "",
+      formData: {},
+      isShow: false,
+    };
+  },
+  methods: {
+    getRowKeys(row) {
+      return row.gradeId;
+    },
+    //单选触发
+    getTemplateRow(index, row) {
+      this.tableRadio = row.gradeId;
+    },
+    openBoxs(item) {
+      this.isShow = true;
+      this.studentList = item;
+      this.search(2);
+    },
+    search(int) {
+      if (int === 2) {
+        this.tableRadio = ""
+        this.formData = {
+          pastDue: 1,
+          atFull: 1,
+          goodsId: this.$route.query.goodsId,
+          status: 1,
+          pageSize: 10,
+          pageNum: 1,
+        };
+      }
+      this.loading = true;
+      this.$api
+        .inquireGradegradeList(this.formData)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    submit() {
+      if (!this.tableRadio) {
+        return this.$message.error("请选择班级");
+      }
+      if (this.tableRadio == this.$route.query.id) {
+        return this.$message.error("不可更换相同班级");
+      }
+      var lets = this.studentList.map((item) => {
+        return {
+          oldGradeId: this.$route.query.id,
+          goodsId: item.goodsId,
+          gradeId: this.tableRadio,
+          orderGoodsId: item.orderGoodsId,
+          userId: item.userId,
+        };
+      });
+      this.$api.gradegradechangeGrade({ userList: lets }).then((res) => {
+        this.$message.success("更换成功");
+        this.$emit("search", 2);
+        this.isShow = false;
+      });
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.search();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.search();
+    },
+    close() {},
+  },
+};
+</script>
+
+<style></style>

+ 667 - 0
src/views/education/classManageMent/classList/trainee/index.vue

@@ -0,0 +1,667 @@
+<template>
+  <div id="trainee">
+    <search-box-new
+      ref="searchBox"
+      :formData="formData"
+      :formList="formList"
+      @search="search"
+      @init="init"
+    />
+    <table-list
+      ref="tableList"
+      :tableSets="tableSet"
+      :tableData="tableData"
+      :navText="navText"
+      :loading="loading"
+      rowKey="id"
+    >
+      <template slot="customize">
+        <el-button
+          type="success"
+          @click="moreActive"
+          v-if="studyCountMoreStatus && !showStatus"
+          >换班</el-button
+        >
+        <el-button type="primary" @click="exportStudent">导出学员</el-button>
+        <el-button type="primary" @click="uploadGF(1)">信息推送</el-button>
+        <el-button type="primary" @click="uploadGF(2)">信息强制推送</el-button>
+        <el-button type="primary" @click="uploadXS">学时推送</el-button>
+      </template>
+      <template slot="userInfo" slot-scope="props">
+        <div style="text-align: left">
+          <p>姓名:{{ props.scope.row["realname"] }}</p>
+          <p>身份证号:{{ props.scope.row["idCard"] }}</p>
+          <p>绑定手机:{{ props.scope.row["telPhone"] }}</p>
+          <p>所属公司:{{ props.scope.row["companyName"] }}</p>
+        </div>
+      </template>
+      <template slot="goodsInfo" slot-scope="props">
+        <div style="text-align: left">
+          <p>商品名称:{{ props.scope.row.goodsName }}</p>
+          <p>教育类型:{{ props.scope.row.educationName }}</p>
+          <p>
+            业务层次:{{
+              props.scope.row.projectName + " - " + props.scope.row.businessName
+            }}
+          </p>
+          <p>专业:{{ props.scope.row.categoryName }}</p>
+          <p>年份:{{ props.scope.row.year }}</p>
+        </div>
+      </template>
+      <template slot="classInfo" slot-scope="props">
+        <div style="text-align: left">
+          <p>所属班级:{{ props.scope.row["gradeName"] }}</p>
+          <p>
+            时间:<span>{{
+              $methodsTools.onlyForma(props.scope.row["classStartTime"])
+                ? $methodsTools.onlyForma(props.scope.row["classStartTime"])
+                : "--"
+            }}</span>
+            至
+            <span>{{
+              $methodsTools.onlyForma(props.scope.row["classEndTime"])
+                ? $methodsTools.onlyForma(props.scope.row["classEndTime"])
+                : "--"
+            }}</span>
+          </p>
+          <p>
+            状态:{{
+              props.scope.row["classStatus"] === 0
+                ? "未开班"
+                : props.scope.row["classStatus"] === 1
+                ? "已开班"
+                : "预开班"
+            }}
+          </p>
+        </div>
+      </template>
+      <template slot="studentQk" slot-scope="props">
+        <div style="text-align: left">
+          <p>
+            学时进度:{{
+              Number(props.scope.row["stuAllNum"]) +
+              Number(props.scope.row["recordNum"]) +
+              "/" +
+              (Number(props.scope.row["examNum"]) +
+                Number(props.scope.row["secAllNum"]))
+            }}
+          </p>
+          <p>
+            视频学习(节):{{
+              props.scope.row["stuAllNum"] +
+              " / " +
+              props.scope.row["secAllNum"]
+            }}
+          </p>
+          <p>
+            做题进度(章卷):{{
+              props.scope.row["recordNum"] + " / " + props.scope.row["examNum"]
+            }}
+          </p>
+        </div>
+      </template>
+
+      <template slot="official" slot-scope="props">
+        <el-popover width="300" trigger="hover">
+          <p>信息推送结果:{{ props.scope.row.officialStatusMsg || "无" }}</p>
+          <el-button type="text" slot="reference">{{
+            props.scope.row.officialStatus ? "是" : "否"
+          }}</el-button>
+        </el-popover>
+      </template>
+      <template slot="btn" slot-scope="props">
+        <el-button type="text" @click="studentJump(props.scope.row)"
+          >学员详情</el-button
+        ><el-button type="text" @click="ClassHour(props.scope.row)"
+          >学时</el-button
+        >
+        <el-button
+          v-if="showStatus"
+          type="text"
+          @click="addClick(props.scope.row)"
+          >所属班级</el-button
+        >
+        <el-button
+          type="text"
+          :disabled="
+            !(props.scope.row.stuAllNum == 0 && props.scope.row.recordNum == 0)
+          "
+          @click="changeClass(props.scope.row)"
+          >换班</el-button
+        >
+      </template>
+    </table-list>
+    <pagination
+      :total="total"
+      :pageSize="formData.pageSize"
+      :currentPage="formData.pageNum"
+      @handleSizeChange="handleSizeChange"
+      @handleCurrentChange="handleCurrentChange"
+    />
+    <tab-class-dialog ref="tabClassDialog" @search="search"></tab-class-dialog>
+    <change-class-dialog
+      ref="changeClassDialog"
+      @search="search"
+    ></change-class-dialog>
+    <class-hour ref="ClassHour" />
+  </div>
+</template>
+
+<script>
+import * as baseUrls from "@/utils/request.js";
+import ClassHour from "@/views/education/archives/archivesDetails/courseRecords/ClassHour";
+import searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+import tabClassDialog from "./tabClassDialog.vue";
+import changeClassDialog from "./changeClassDialog.vue";
+export default {
+  components: {
+    ClassHour,
+    searchBoxNew,
+    tableList,
+    pagination,
+    tabClassDialog,
+    changeClassDialog,
+  },
+  props: {
+    showStatus: {
+      type: Boolean,
+      default: true,
+    },
+  },
+  // name: "ClassList",
+  data() {
+    return {
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        border: true,
+        title: "报班学员",
+        index: 0,
+        ch: "条",
+        num: false,
+        choice: true,
+        addHide: true,
+        openCheckMore: true,
+        backFatherBtn: {
+          status: false,
+          title: "未定义",
+        },
+      },
+      formData: {
+        // status: "0,1",
+        pageSize: 10,
+        pageNum: 1,
+        // classStatus: "",
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "学员编码",
+          hidden: true,
+          scope: "slot",
+          slotName: "userInfo",
+        },
+        {
+          label: "所属商品",
+          scope: "slot",
+          slotName: "goodsInfo",
+        },
+        {
+          label: "所属班级",
+          scope: "slot",
+          slotName: "classInfo",
+          hidden: this.showStatus,
+        },
+        {
+          label: "学习情况",
+          hidden: true,
+          scope: "slot",
+          slotName: "studentQk",
+        },
+        {
+          label: "学习机会",
+          prop1: "useStudyCount",
+          prop2: "studyCount",
+          hidden: true,
+          scope: "studyCount",
+        },
+        {
+          label: "考试机会",
+          prop1: "examNumber",
+          prop2: "expendNumber",
+          hidden: true,
+          scope: "chance",
+        },
+        {
+          label: "资料审核",
+          prop: "profileStatus",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "通过",
+              value: 1,
+            },
+            {
+              label: "待审",
+              value: 2,
+            },
+            {
+              label: "不通过",
+              value: 3,
+            },
+            {
+              label: "删除",
+              value: -1,
+            },
+          ],
+        },
+        {
+          label: "信息推送",
+          hidden: true,
+          scope: "slot",
+          slotName: "official",
+        },
+        {
+          label: "学时审核",
+          prop: "periodStatus",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "不通过",
+              value: 0,
+            },
+            {
+              label: "已通过",
+              value: 1,
+            },
+            {
+              label: "待审核",
+              value: 2,
+            },
+            {
+              label: "审核中",
+              value: 3,
+            },
+            {
+              label: "不可审核",
+              value: -1,
+            },
+          ],
+        },
+        {
+          label: "学时推送",
+          prop: "periodPlush",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "是",
+              value: 1,
+            },
+            {
+              label: "否",
+              value: 0,
+            },
+            {
+              label: "否",
+              value: null,
+            },
+          ],
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+      studyCountMoreStatus: false,
+    };
+  },
+  computed: {
+    formList() {
+      let arr = [
+        {
+          prop: "educationTypeId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationTypeId",
+        },
+        { 
+          prop: "majorId",
+          placeholder: "专业",
+          scope: "Professional",
+          edu: "educationTypeId",
+        },
+      ];
+      let arr1 = [
+        {
+          prop: "studyCountMore",
+          placeholder: "过期换班",
+          scope: "select",
+          options: [{ label: "可换班学员", value: 2 }],
+        },
+      ];
+      //搜索
+      let formList = [
+        {
+          prop: "periodStatus",
+          placeholder: "学时状态",
+          scope: "select",
+          options: [
+            { label: "待审核", value: 2 },
+            { label: "审核中", value: 3 },
+            { label: "不通过", value: 0 },
+            { label: "已通过", value: 1 },
+            { label: "不可审核", value: -1 },
+          ],
+        },
+        {
+          prop: "officialStatus",
+          placeholder: "信息推送",
+          scope: "select",
+          options: [
+            { label: "是", value: 1 },
+            { label: "否", value: 0 },
+          ],
+        },
+        {
+          prop: "periodPlush",
+          placeholder: "学时推送",
+          scope: "select",
+          options: [
+            { label: "是", value: 1 },
+            { label: "否", value: 0 },
+          ],
+        },
+        {
+          prop: "searchKey",
+          placeholder: this.showStatus ? '请输入班级名称/所属公司/学员姓名': '请输入所属公司/学员姓名',
+        },
+        {
+          prop: "telphone",
+          placeholder: "绑定手机",
+        },
+        {
+          prop: "idCard",
+          placeholder: "身份证号",
+        },
+      ];
+      if (this.showStatus) {
+        return arr.concat(formList);
+      } else {
+        return arr1.concat(formList);
+      }
+    },
+  },
+  mounted() {
+    this.search();
+  },
+  methods: {
+    exportStudent() {
+      let data = JSON.parse(JSON.stringify(this.formData));
+      data.gradeId = this.$route.query.id || "";
+      data.goodsId = this.$route.query.goodsId || "";
+      delete data.pageNum;
+      delete data.pageSize;
+      this.$api.inquireGradegradelistGradeAllExport(data).then((res) => {
+        if (res.msg) {
+          let url = baseUrls.baseURL + "common/download?fileName=" + res.msg;
+          let link = document.createElement("a");
+          let fileName = "班级学员数据" + ".xlsx";
+          document.body.appendChild(link);
+          link.href = url;
+          link.dowmload = fileName;
+          link.click();
+          link.remove();
+          this.$message.success("导出成功");
+        } else {
+          this.$message.error("导出失败");
+        }
+      });
+    },
+    moreActive() {
+      if (!this.$refs.tableList.allCheckData.length) {
+        this.$message.warning("请勾选需要操作的学员");
+        return;
+      }
+
+      var newTime = Date.parse(new Date()) / 1000;
+      var itemsq = JSON.parse(
+        JSON.stringify(this.$refs.tableList.allCheckData)
+      );
+      var ast = itemsq.every((items) => {
+        return items.periodStatus !== 1 && items.classEndTime
+          ? items.classEndTime < newTime
+          : false;
+      });
+      if (!ast) {
+        this.$message.warning(
+          "选择的学员中存在学时审批状态已通过或班级有效期未过期"
+        );
+        return;
+      }
+      var ast1 = itemsq.every((items) => {
+        return items.periodStatus === -1 || items.periodStatus === 0;
+      });
+      if (!ast1) {
+        this.$message.warning("只允许选择未通过或不可审核的学员");
+        return;
+      }
+      this.$refs.changeClassDialog.openBoxs(itemsq);
+    },
+    ClassHour(item) {
+      this.$refs.ClassHour.openBoxs(item);
+    },
+    uploadGF(type) {
+      if (!this.$refs.tableList.allCheckData.length) {
+        this.$message.warning("请勾选需要官方信息推送的学员");
+        return;
+      }
+      let arr = this.$refs.tableList.allCheckData.map((item) => {
+        return {
+          orderGoodsId: item.orderGoodsId,
+          userId: item.userId,
+          gradeId: item.gradeId,
+        };
+      });
+      this.$api[
+        type == 1 ? "editGradeUsereditpushInfo" : "gradestudentpushForceInfo"
+      ](arr).then((res) => {
+        if (res.code === 200) {
+          if (!res.msg) {
+            this.$message.success("推送成功");
+          } else {
+            this.$message.error(res.msg);
+          }
+          this.search();
+          this.$refs.tableList.clearMoreActive();
+        }
+      });
+    },
+    uploadXS() {
+      if (!this.$refs.tableList.allCheckData.length) {
+        this.$message.warning("请勾选需要学时信息推送的学员");
+        return;
+      }
+      let stu = this.$refs.tableList.allCheckData.some((item) => {
+        return item.periodStatus === -1;
+      });
+      if (stu) {
+        this.$message.warning("所勾选学员不符合学时推送条件,请重新选择");
+        return;
+      }
+      let arr = this.$refs.tableList.allCheckData.map((item) => {
+        return {
+          userId: item.userId,
+          gradeId: item.gradeId,
+        };
+      });
+      this.$api.editGradeUsereditpushPeriod(arr).then((res) => {
+        if (res.code === 200) {
+          if (!res.msg) {
+            this.$message.success("推送成功");
+          } else {
+            this.$message.error(res.msg);
+          }
+          this.search();
+          this.$refs.tableList.clearMoreActive();
+        }
+      });
+    },
+    changeClass(row) {
+      this.$refs.tabClassDialog.openBoxs(row);
+    },
+    getClassStatus(item) {
+      let nowTime = parseInt(new Date().getTime() / 1000);
+      if (
+        item.classStartTime &&
+        item.classEndTime &&
+        item.classEndTime > nowTime &&
+        item.classStartTime < nowTime
+      ) {
+        return "未过期";
+      } else if (item.classStartTime && item.classStartTime > nowTime) {
+        return "未开始";
+      } else if (item.classEndTime && item.classEndTime < nowTime) {
+        return "已过期";
+      } else {
+        return "未开班";
+      }
+    },
+    search(int) {
+      this.loading = true;
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      if (int === 2) {
+        this.formData = {
+          // status: "0,1",
+          pageSize: 10,
+          pageNum: 1,
+          // classStatus: "",
+        };
+        this.$refs.tableList.clearMoreActive();
+      }
+      if (int === 4) {
+        this.formData.pageNum = 1;
+      }
+      var data = JSON.parse(JSON.stringify(this.formData));
+      data.gradeId = this.$route.query.id || "";
+      data.goodsId = this.$route.query.goodsId || "";
+      this.studyCountMoreStatus = false;
+      this.$api[
+        this.showStatus ? "gradelistGradeAll" : "inquireGradegradelistGrade"
+      ](data)
+        .then((res) => {
+          if (data.studyCountMore == 2) {
+            this.studyCountMoreStatus = true;
+          }
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    del(v) {
+      this.$alert(
+        "确定删除此内容?<br />内容删除后将无法恢复,请慎重考虑",
+        "提示",
+        {
+          dangerouslyUseHTMLString: true,
+        }
+      )
+        .then(() => {
+          var data = {
+            gradeId: v.gradeId,
+            status: -1,
+          };
+          this.$api.editGradegrade(data).then((res) => {
+            this.$message.success("删除成功");
+            this.search();
+          });
+        })
+        .catch(() => {
+          this.$message({
+            type: "info",
+            message: "已取消删除",
+          });
+        });
+    },
+    addClick(v) {
+      const jump = () => {
+        //班级详情
+        this.$router.push({
+          path: "manageClass",
+          query: {
+            id: v.gradeId,
+          },
+        });
+      };
+      const statusPage = this.$store.state.tagsView.visitedViews.some(
+        (item) => {
+          return item.name == "ManageClass";
+        }
+      );
+      if (statusPage) {
+        this.$store
+          .dispatch("tagsView/delCachedView", {
+            name: "ManageClass",
+          })
+          .then((res) => {
+            jump();
+          });
+      } else {
+        jump();
+      }
+    },
+    studentJump(v) {
+      const jump = () => {
+        //学员详情
+        this.$router.push({
+          name: "StudentXQ",
+          query: {
+            id: v.userId,
+          },
+        });
+      };
+      const statusPage = this.$store.state.tagsView.visitedViews.some(
+        (item) => {
+          return item.name == "StudentXQ";
+        }
+      );
+      if (statusPage) {
+        this.$store
+          .dispatch("tagsView/delCachedView", {
+            name: "StudentXQ",
+          })
+          .then((res) => {
+            jump();
+          });
+      } else {
+        jump();
+      }
+    },
+    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></style>

+ 159 - 0
src/views/education/classManageMent/classList/trainee/tabClassDialog.vue

@@ -0,0 +1,159 @@
+<template>
+  <Base-dialog
+    title="更换班级"
+    width="1000px"
+    :isShow.sync="isShow"
+    @submit="submit"
+    @close="close"
+  >
+    <div>
+      <table-list
+        :tableSets="tableSet"
+        :tableData="tableData"
+        :navText="navText"
+        :loading="loading"
+        :radio.sync="tableRadio"
+      >
+      </table-list>
+      <pagination
+        :total="total"
+        :pageSize="formData.pageSize"
+        :currentPage="formData.pageNum"
+        @handleSizeChange="handleSizeChange"
+        @handleCurrentChange="handleCurrentChange"
+      />
+    </div>
+  </Base-dialog>
+</template>
+
+<script>
+import tableList from "@/components/tableList";
+import { getListGoods, changeGradeFree } from "@/api/education/classManageMent";
+export default {
+  components: {
+    tableList,
+  },
+  data() {
+    return {
+      navText: {
+        title: "营销活动",
+        index: 0,
+        ch: "条",
+        num: false,
+        border: true,
+        dontNum: true,
+        choice: false,
+        choiceRadio: true,
+        radioKey: "gradeId",
+        tableHide: true,
+        addHide: true,
+        headShow: false,
+        backFatherBtn: {
+          status: false,
+          title: "未定义",
+        },
+      },
+      studentInfo: {},
+      tableSet: [
+        {
+          label: "班级名称",
+          prop: "className",
+          hidden: true,
+          scope: "editInfo",
+        },
+        {
+          label: "班级人数",
+          prop1: "studentNum",
+          prop2: "studentUpper",
+          hidden: true,
+          scope: "peopleNums",
+          width: "150px",
+        },
+        {
+          label: "开放学习时间",
+          prop: "learningStatus",
+          prop1: "learningTimeStart",
+          hidden: true,
+          scope: "classTimeTypes",
+          width: "150px",
+        },
+        {
+          label: "班级有效期",
+          prop1: "classStartTime",
+          prop2: "classEndTime",
+          hidden: true,
+          Diszing: false,
+          scope: "TimeLists",
+          width: "200px",
+        },
+      ],
+      tableData: [],
+      loading: false,
+      total: 0,
+      tableRadio: "",
+      formData: {},
+      isShow: false,
+    };
+  },
+  methods: {
+    openBoxs(item) {
+      this.isShow = true;
+      this.studentInfo = item;
+      this.search(2);
+    },
+    search(int) {
+      if (int === 2) {
+        this.tableRadio = "";
+        this.formData = {
+          pageSize: 10,
+          pageNum: 1,
+          goodsId: this.studentInfo.goodsId,
+        };
+      }
+      this.loading = true;
+      getListGoods(this.formData)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    submit() {
+      if (!this.tableRadio) {
+        return this.$message.error("请选择班级");
+      }
+
+      let { goodsId, gradeId, orderGoodsId, userId } = this.studentInfo;
+      if (this.tableRadio == gradeId) {
+        return this.$message.error("不可更换相同班级");
+      }
+      changeGradeFree({
+        goodsId,
+        oldGradeId: gradeId,
+        gradeId: this.tableRadio,
+        orderGoodsId,
+        userId,
+      }).then((res) => {
+        this.$message.success("更换成功");
+        this.$emit("search", 2);
+        this.isShow = false;
+      });
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.search();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.search();
+    },
+    close() {},
+  },
+};
+</script>
+
+<style></style>

+ 0 - 5
src/views/education/classManageMent/studentMenu/index.vue

@@ -842,11 +842,6 @@ export default {
           hidden: true,
           scope: "chance",
         },
-        {
-          label: "学员身份证",
-          prop: "idCard",
-          hidden: true,
-        },
       ],
       listData: {},
       finishStatusOS: "",

+ 3 - 3
src/views/education/studentManageMent/studentXQ/index.vue

@@ -4,16 +4,16 @@
       <el-tab-pane label="基本信息" name="commodInfo"
         ><student-base-manage
       /></el-tab-pane>
-      <el-tab-pane label="网课-学习记录" name="studentInfo"
+      <el-tab-pane label="网课记录" name="studentInfo"
         ><study-record
       /></el-tab-pane>
-      <el-tab-pane label="题库通-做题记录" name="chargeInfo"
+      <el-tab-pane label="题库记录" name="chargeInfo"
         ><bank-question-pass-record
       /></el-tab-pane>
       <el-tab-pane label="班级记录" name="classRecode"
         ><class-record
       /></el-tab-pane>
-      <el-tab-pane label="直播-学习记录" name="liveRecode"
+      <el-tab-pane label="直播记录" name="liveRecode"
         ><live-list
       /></el-tab-pane>
       <el-tab-pane label="访问日志" name="accesslog"

+ 6 - 6
src/views/education/studentManageMent/studentXQ/studentBaseManage.vue

@@ -9,7 +9,7 @@
         :rules="rules"
       >
         <el-row :gutter="20">
-          <el-col :span="6">
+          <el-col :span="8">
             <div class="dis_fs">
               <div class="photoSty1">
                 <img
@@ -113,17 +113,17 @@
               </div>
             </div>
           </el-col>
-          <el-col :span="9">
+          <el-col :span="8">
             <el-form-item label="学员编码" prop="studentCode">
               <el-input disabled v-model="listData.studentCode"></el-input>
             </el-form-item>
-            <el-form-item label="绑定手机" prop="telphone">
+            <el-form-item label="绑定手机" prop="telphone">
               <el-input v-model="listData.telphone"></el-input>
             </el-form-item>
             <el-form-item label="姓名" prop="realname">
               <el-input v-model="listData.realname"></el-input>
             </el-form-item>
-            <el-form-item label="身份证号" prop="idCard">
+            <el-form-item label="身份证号" prop="idCard">
               <el-input v-model="listData.idCard"></el-input>
             </el-form-item>
             <el-form-item label="性别" prop="sex">
@@ -173,14 +173,14 @@
                 </el-option>
               </el-select>
             </el-form-item>
-            <el-form-item label="在职状" prop="jobStatus">
+            <el-form-item label="在职状" prop="jobStatus">
               <el-radio-group v-model="listData.jobStatus">
                 <el-radio :label="1">在职</el-radio>
                 <el-radio :label="2">离职</el-radio>
               </el-radio-group>
             </el-form-item>
           </el-col>
-          <el-col :span="9">
+          <el-col :span="8">
             <el-form-item label="民族" prop="nation">
               <el-input v-model="listData.nation"></el-input>
             </el-form-item>