Tang 2 vuotta sitten
vanhempi
commit
98759a2354
57 muutettua tiedostoa jossa 3160 lisäystä ja 293 poistoa
  1. 6 2
      package.json
  2. 7 0
      public/index.html
  3. BIN
      src/assets/images/合同金额@2x.png
  4. BIN
      src/assets/images/实际款@2x.png
  5. BIN
      src/assets/images/已收款@2x.png
  6. BIN
      src/assets/images/已退款@2x.png
  7. BIN
      src/assets/images/成本金额@2x.png
  8. BIN
      src/assets/images/未收款@2x.png
  9. BIN
      src/assets/images/盈亏@2x.png
  10. BIN
      src/assets/images/订单人数@2x.png
  11. BIN
      src/assets/images/订单数@2x.png
  12. 9 1
      src/components/BaseDialog.vue
  13. 87 0
      src/components/Comon/pictureList.vue
  14. 1 0
      src/components/searchBoxNew.vue
  15. 2 211
      src/components/tableList.vue
  16. 7 0
      src/directive/filter/index.js
  17. 2 0
      src/directive/index.js
  18. 23 0
      src/newApi/examapply.js
  19. 24 0
      src/newApi/goods.js
  20. 8 0
      src/newApi/paperquestion.js
  21. 1 1
      src/permission.js
  22. 8 8
      src/store/modules/permission.js
  23. 4 0
      src/utils/methodsTool.js
  24. 1 1
      src/utils/request.js
  25. 8 1
      src/views/2Cport/pageSettings/header.vue
  26. 285 0
      src/views/Marketing/activitySystem/components/goodsCheck.vue
  27. 21 0
      src/views/Marketing/activitySystem/coupon/index.vue
  28. 215 0
      src/views/Marketing/activitySystem/instantDeath/addEdit/index.vue
  29. 368 0
      src/views/Marketing/activitySystem/instantDeath/dialogInstan.vue
  30. 341 0
      src/views/Marketing/activitySystem/instantDeath/index.vue
  31. 57 0
      src/views/Marketing/activitySystem/instantDeath/ruleSpecification.vue
  32. 312 0
      src/views/Marketing/goods/commodityManageMent/add/handoutContent/handoutsCheck.vue
  33. 51 0
      src/views/Marketing/goods/commodityManageMent/add/handoutContent/index.vue
  34. 56 8
      src/views/Marketing/goods/commodityManageMent/add/index.vue
  35. 38 1
      src/views/Marketing/goods/commodityManageMent/add/productInformation.vue
  36. 69 9
      src/views/Marketing/goods/commodityManageMent/edit/courseContent/index.vue
  37. 12 6
      src/views/Marketing/goods/commodityManageMent/edit/courseContent/share.vue
  38. 312 0
      src/views/Marketing/goods/commodityManageMent/edit/handoutContent/handoutsCheck.vue
  39. 51 0
      src/views/Marketing/goods/commodityManageMent/edit/handoutContent/index.vue
  40. 58 2
      src/views/Marketing/goods/commodityManageMent/edit/index.vue
  41. 57 9
      src/views/Marketing/goods/commodityManageMent/edit/productInformation.vue
  42. 2 2
      src/views/Marketing/goods/goodTopic/index.vue
  43. 48 3
      src/views/Marketing/order/offlineOrder/goodsMatch/goodsMatchToBusin.vue
  44. 1 5
      src/views/Marketing/order/orderList/details/costPriceManages.vue
  45. 4 0
      src/views/Marketing/order/orderList/details/goodsManage.vue
  46. 14 0
      src/views/YjConsult/Q&A/index.vue
  47. 82 0
      src/views/YjConsult/newsMessage/dialogMessage.vue
  48. 217 0
      src/views/YjConsult/newsMessage/index.vue
  49. 2 2
      src/views/education/classManageMent/learningHoursRecordListMonth/index.vue
  50. 133 4
      src/views/education/examManagement/applicationData/asPlanned.vue
  51. 83 0
      src/views/education/examManagement/listOfTestRooms/applyBeforeKnow.vue
  52. 13 2
      src/views/education/examManagement/listOfTestRooms/index.vue
  53. 3 3
      src/views/monitor/cache/index.vue
  54. 15 4
      src/views/resource/bankManagement/testPaperManagement/BatchImportPop.vue
  55. 5 0
      src/views/resource/bankManagement/testPaperManagement/addPaper/topicAddPaper/index.vue
  56. 6 0
      src/views/resource/bankManagement/testPaperManagement/editPaper/topicEditPaper/index.vue
  57. 31 8
      vue.config.js

+ 6 - 2
package.json

@@ -4,9 +4,10 @@
   "description": "中正高校端管理系统",
   "author": "中正高校端",
   "license": "MIT",
+  "sideEffects": true,
   "scripts": {
     "dev": "vue-cli-service serve",
-    "build:prod": "vue-cli-service build",
+    "build:prod": "vue-cli-service build --mode production",
     "build:stage": "vue-cli-service build --mode staging",
     "preview": "node build/index.js --preview",
     "lint": "eslint --ext .js,.vue src"
@@ -41,6 +42,7 @@
     "af-table-column": "^1.0.3",
     "axios": "0.21.0",
     "clipboard": "2.0.6",
+    "compression-webpack-plugin": "^6.1.1",
     "core-js": "3.8.1",
     "echarts": "4.9.0",
     "element-ui": "^2.15.13",
@@ -78,6 +80,7 @@
     "@vue/cli-plugin-eslint": "4.4.6",
     "@vue/cli-service": "4.4.6",
     "babel-eslint": "10.1.0",
+    "babel-plugin-dynamic-import-node": "2.3.3",
     "chalk": "4.1.0",
     "connect": "3.6.6",
     "eslint": "7.15.0",
@@ -90,7 +93,8 @@
     "sass-loader": "10.1.1",
     "script-ext-html-webpack-plugin": "2.1.5",
     "svg-sprite-loader": "5.1.1",
-    "vue-template-compiler": "2.6.12"
+    "vue-template-compiler": "2.6.12",
+    "webpack-bundle-analyzer": "^4.9.0"
   },
   "engines": {
     "node": ">=8.9",

+ 7 - 0
public/index.html

@@ -12,6 +12,8 @@
   </title>
   <!--[if lt IE 11]><script>window.location.href='/html/ie.html';</script><![endif]-->
   <!-- <script src="https://manage.xyyxt.net/static/js/gsap.min.js"></script> -->
+  <!-- 使用CDN的CSS文件 -->
+  <link rel="stylesheet" href="https://cdn.staticfile.org/element-ui/2.15.13/theme-chalk/index.min.css">
   <style>
     html,
     body,
@@ -212,6 +214,11 @@
       <div class="load_title">正在加载系统资源,请耐心等待</div>
     </div>
   </div>
+  <!-- 使用CDN的JS文件 -->
+  <script src="https://cdn.staticfile.org/vue/2.6.12/vue.min.js"></script>
+  <script src="https://cdn.staticfile.org/element-ui/2.15.13/index.min.js"></script>
+  <script src="https://cdn.staticfile.org/axios/0.21.0/axios.min.js"></script>
+  <script src="https://cdn.staticfile.org/vue-router/3.5.1/vue-router.min.js"></script>
 </body>
 
 </html>

BIN
src/assets/images/合同金额@2x.png


BIN
src/assets/images/实际款@2x.png


BIN
src/assets/images/已收款@2x.png


BIN
src/assets/images/已退款@2x.png


BIN
src/assets/images/成本金额@2x.png


BIN
src/assets/images/未收款@2x.png


BIN
src/assets/images/盈亏@2x.png


BIN
src/assets/images/订单人数@2x.png


BIN
src/assets/images/订单数@2x.png


+ 9 - 1
src/components/BaseDialog.vue

@@ -6,10 +6,15 @@
     :close-on-click-modal="false"
     :append-to-body="appendToBody"
     @closed="close"
+    :fullscreen="fullscreen"
   >
     <div slot="title" class="hearders">
       <div class="leftTitle">{{ title }}</div>
       <div class="rightBoxs">
+        <i
+          class="el-icon-full-screen full_style"
+          @click="fullscreen = !fullscreen"
+        ></i>
         <img
           src="@/assets/images/Close@2x.png"
           alt=""
@@ -67,7 +72,9 @@ export default {
     },
   },
   data() {
-    return {};
+    return {
+      fullscreen: false,
+    };
   },
   methods: {
     confirmBtn() {
@@ -92,6 +99,7 @@ export default {
     visible(val) {
       // 在此做显示与隐藏的交互
       if (val === false) {
+        this.fullscreen = false;
         // 重置操作
       } else {
         // 展示时操作

+ 87 - 0
src/components/Comon/pictureList.vue

@@ -0,0 +1,87 @@
+<template>
+  <div class="dis_flex_order_li">
+    <div class="list" v-for="(item, index) in list" :key="index">
+      <img :src="backFullSrc(item.img)" alt="" />
+      <div class="right">
+        <h4>{{ item.label }}:</h4>
+        <p>
+          {{ item.value || info[item.prop] | formatPrice }}{{ item.ch || "元" }}
+        </p>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  name: "SaasMasterPlatformPictureList",
+  props: {
+    list: {
+      type: Array,
+      default: () => {
+        return [];
+      },
+    },
+    info: {
+      type: Object,
+      default: () => {
+        return {};
+      },
+    },
+  },
+  data() {
+    return {
+    };
+  },
+
+  methods: {
+    backFullSrc(name) {
+      return require(`@/assets/images/${name}@2x.png`);
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.dis_flex_order_li {
+  display: flex;
+  align-items: center;
+  flex-wrap: wrap;
+  & > .list {
+    user-select: none;
+    cursor: pointer;
+    transition: all 0.3s;
+    box-shadow: 0px 0px 4px 1px rgba(0, 0, 0, 0.2);
+    &:hover {
+      transform: scale(1.04);
+    }
+    width: 136px;
+    height: 44px;
+    border-radius: 6px;
+    display: flex;
+    align-items: center;
+    flex-shrink: 0;
+    margin-right: 10px;
+    margin-bottom: 10px;
+    & > img {
+      margin-left: 2px;
+      width: 40px;
+      height: 40px;
+    }
+    & > .right {
+      flex: 1;
+      padding-left: 4px;
+      & > h4 {
+        color: #000;
+        margin: 0;
+        font-size: 12px;
+      }
+      & > p {
+        font-size: 12px;
+        color: red;
+        margin: 0;
+      }
+    }
+  }
+}
+</style>

+ 1 - 0
src/components/searchBoxNew.vue

@@ -496,6 +496,7 @@
             >
             </el-date-picker>
           </div>
+          <slot v-else-if="item.scope === 'slot'" :name="item.slotName"></slot>
           <el-input
             :style="item.prop === 'searchKey' ? 'width:260px;' : ''"
             v-else-if="!item.scope"

+ 2 - 211
src/components/tableList.vue

@@ -208,27 +208,9 @@
               ? "无效"
               : "未知"
           }}</span>
-          <span v-else-if="item.scope === 'statusZpFB'">{{
-            Number(scope.row[item.prop]) === 1
-              ? "未发布"
-              : Number(scope.row[item.prop]) === 2
-              ? "已发布"
-              : Number(scope.row[item.prop]) === 0
-              ? "停用"
-              : Number(scope.row[item.prop]) === -1
-              ? "已删除"
-              : "未知"
-          }}</span>
-          <div v-else-if="item.scope === 'solt'">
-            <slot :name="item.soltName" :scope="scope"></slot>
+          <div v-else-if="item.scope === 'slot'">
+            <slot :name="item.slotName" :scope="scope"></slot>
           </div>
-          <span v-else-if="item.scope === 'reStatus'">{{
-            Number(scope.row[item.prop]) === 1
-              ? "定时发布"
-              : Number(scope.row[item.prop]) === 0
-              ? "手动发布"
-              : "未知"
-          }}</span>
           <span v-else-if="item.scope === 'fabStatus'">{{
             Number(scope.row[item.prop]) === 1
               ? "发布"
@@ -347,13 +329,6 @@
               ? scope.row[item.prop2]
               : scope.row[item.prop1]
           }}</span>
-          <span v-else-if="item.scope === 'ggType'">{{
-            Number(scope.row[item.prop]) === 1
-              ? "学习中心"
-              : Number(scope.row[item.prop]) === 2
-              ? "求职中心"
-              : "未知"
-          }}</span>
           <ul v-else-if="item.scope === 'mapTypesTeacher'" class="ulAuto">
             <template v-for="(itm, inds) in scope.row[item.prop]">
               <li :key="inds" v-if="inds < 2">
@@ -634,39 +609,9 @@
               >
             </el-popover>
           </ul>
-          <span v-else-if="item.scope === 'statusRe'">{{
-            Number(scope.row[item.prop]) === 0
-              ? "已删除"
-              : Number(scope.row[item.prop]) === 1 &&
-                Number(scope.row["reStatus"]) === 1
-              ? "待发布"
-              : Number(scope.row[item.prop]) === 1 &&
-                Number(scope.row["reStatus"]) === 0
-              ? "未发布"
-              : Number(scope.row[item.prop]) === 2
-              ? "已撤回"
-              : Number(scope.row[item.prop]) === 3
-              ? "已发布"
-              : Number(scope.row[item.prop]) === 4
-              ? "已到期"
-              : "未知"
-          }}</span>
           <div v-else-if="item.scope === 'htmlInfo'">
             <bankMsg ref="bankMsg" :bankMsg="scope.row" />
           </div>
-          <span v-else-if="item.scope === 'TimeVoBtn'">
-            <el-popover :key="Math.random()" placement="left" trigger="click">
-              <div
-                v-for="(items, indexs) in scope.row[item.prop]"
-                :key="indexs"
-                style="margin-bottom: 6px"
-              >
-                {{ $methodsTools.onlyForma(items.startTime) }} ~
-                {{ $methodsTools.onlyForma(items.endTime) }}
-              </div>
-              <el-button slot="reference" size="mini">查看</el-button>
-            </el-popover>
-          </span>
           <div v-else-if="item.scope === 'subTime'">
             <span style="margin-right: 6px">{{
               $methodsTools.onlyForma(scope.row[item.prop1], false)
@@ -716,14 +661,6 @@
             </a>
             <div>{{ scope.row[item.prop][item.prop2] }}</div>
           </div>
-          <span v-else-if="item.scope === 'Salary'">
-            {{ scope.row[item.prop1] === 1 ? "月薪" : "年薪" }}
-            {{
-              scope.row[item.prop2] === scope.row[item.prop3]
-                ? scope.row[item.prop2]
-                : scope.row[item.prop2] + "~" + scope.row[item.prop3]
-            }}
-          </span>
           <template v-else-if="item.scope === 'courseAbout'">
             <div v-for="(item, index) in scope.row[item.prop]" :key="index">
               {{ item.courseName }} ({{ item.aliasName }})
@@ -765,47 +702,6 @@
               >
             </div>
           </div>
-          <span v-else-if="item.scope === 'activityType'">{{
-            Number(scope.row[item.prop]) === 0
-              ? "优惠券"
-              : Number(scope.row[item.prop]) === 1
-              ? "折扣券"
-              : Number(scope.row[item.prop]) === 2
-              ? "线上直播"
-              : Number(scope.row[item.prop]) === 3
-              ? "定价"
-              : Number(scope.row[item.prop]) === 4
-              ? "优惠"
-              : Number(scope.row[item.prop]) === 5
-              ? "折扣"
-              : Number(scope.row[item.prop]) === 6
-              ? "线下活动"
-              : "未知"
-          }}</span>
-          <span v-else-if="item.scope === 'activityRemarks'">{{
-            Number(scope.row[item.prop]) === 0
-              ? "金额:¥" + scope.row["price"]
-              : Number(scope.row[item.prop]) === 1
-              ? "折扣:" + scope.row["price"] + "折"
-              : Number(scope.row[item.prop]) === 2
-              ? "直播内容:" + scope.row["liveContent"]
-              : Number(scope.row[item.prop]) === 3
-              ? "商品金额:¥" + scope.row["price"]
-              : Number(scope.row[item.prop]) === 4
-              ? "优惠金额:¥" + scope.row["price"]
-              : Number(scope.row[item.prop]) === 5
-              ? "商品折扣:" + scope.row["price"] + "折"
-              : Number(scope.row[item.prop]) === 6
-              ? "活动地点:" + scope.row["liveAdress"]
-              : "未知"
-          }}</span>
-          <span v-else-if="item.scope === 'isUrgent'">{{
-            scope.row[item.prop] === 0
-              ? "不是"
-              : scope.row[item.prop] === 1
-              ? "是"
-              : "未知"
-          }}</span>
           <span v-else-if="item.scope === 'convert'">{{
             $methodsTools.secondToDate(scope.row[item.prop], false)
           }}</span>
@@ -851,9 +747,6 @@
                 : "待审核"
             }}
           </div>
-          <span v-else-if="item.scope === 'peopleNum'">{{
-            scope.row[item.prop] === 0 ? "不限制" : scope.row[item.prop]
-          }}</span>
           <span v-else-if="item.scope === 'address'"
             >{{
               scope.row[item.prop1] +
@@ -861,19 +754,6 @@
               scope.row[item.prop3]
             }}{{ scope.row[item.prop4] ? scope.row[item.prop4] : "" }}</span
           >
-          <span v-else-if="item.scope === 'statusActivity'">{{
-            Number(scope.row[item.prop]) === 0
-              ? "已删除"
-              : Number(scope.row[item.prop]) === 1
-              ? "已结束"
-              : Number(scope.row[item.prop]) === 2
-              ? "已撤回"
-              : Number(scope.row[item.prop]) === 3
-              ? "已开始"
-              : Number(scope.row[item.prop]) === 4
-              ? "未开始"
-              : "未知"
-          }}</span>
           <span v-else-if="item.scope === 'sex'">
             {{
               scope.row[item.prop] == 1
@@ -883,17 +763,6 @@
                 : "未知"
             }}
           </span>
-          <span v-else-if="item.scope === 'statusFB'">{{
-            scope.row[item.prop] === 0
-              ? "删除"
-              : scope.row[item.prop] === 1
-              ? "发布"
-              : scope.row[item.prop] === 2
-              ? "撤回"
-              : scope.row[item.prop] === 3
-              ? "未发布"
-              : "未知"
-          }}</span>
           <span v-else-if="item.scope === 'typeStatus'">{{
             scope.row[item.prop] === 0
               ? "报名指引"
@@ -912,43 +781,6 @@
               ? "真题试卷"
               : "未知"
           }}</span>
-          <span v-else-if="item.scope === 'taskType'">{{
-            scope.row[item.prop] === 0
-              ? "每日签到"
-              : scope.row[item.prop] === 1
-              ? "完善信息"
-              : scope.row[item.prop] === 2
-              ? "邀请好友"
-              : scope.row[item.prop] === 3
-              ? "每日分享"
-              : scope.row[item.prop] === 4
-              ? "视频学习"
-              : scope.row[item.prop] === 5
-              ? "模拟考试"
-              : "未知"
-          }}</span>
-          <span v-else-if="item.scope === 'releaseType'">{{
-            scope.row[item.prop] === 0
-              ? "手动发布"
-              : scope.row[item.prop] === 1
-              ? "定时发布"
-              : "未知"
-          }}</span>
-          <span v-else-if="item.scope === 'releaseStatus'">{{
-            scope.row[item.prop] === 0
-              ? "删除"
-              : scope.row[item.prop] === 1
-              ? "待发布"
-              : scope.row[item.prop] === 2
-              ? "撤回"
-              : scope.row[item.prop] === 3
-              ? "发布成功"
-              : scope.row[item.prop] === 4
-              ? "未发布"
-              : scope.row[item.prop] === 5
-              ? "已结束"
-              : "未知"
-          }}</span>
           <div v-else-if="item.scope === 'knowledge'" class="overSty">
             <el-button
               type="success"
@@ -962,9 +794,6 @@
           <span v-else-if="item.scope === 'numberAll'">{{
             scope.row[item.prop1] + scope.row[item.prop2]
           }}</span>
-          <span v-else-if="item.scope === 'moreLists'">{{
-            scope.row[item.prop1] + " ~ " + scope.row[item.prop2]
-          }}</span>
           <span v-else-if="item.scope === 'resultType'">
             {{ scope.row[item.prop1] }}
             <span
@@ -1274,19 +1103,6 @@
           >
             {{ scope.row[item.prop1] }} / {{ scope.row[item.prop2] }}
           </div>
-          <span v-else-if="item.scope === 'statusOrder'">{{
-            scope.row[item.prop] === -2
-              ? "超时关闭"
-              : scope.row[item.prop] === -1
-              ? "手动关闭"
-              : scope.row[item.prop] === 0
-              ? "待付款"
-              : scope.row[item.prop] === 1
-              ? "已付款"
-              : scope.row[item.prop] === 3
-              ? "成功"
-              : "未知"
-          }}</span>
           <span v-else-if="item.scope === 'cType'">
             <el-tag
               type="success"
@@ -1324,10 +1140,6 @@
           <span v-else-if="item.scope === 'time'">{{
             numTime(scope.row[item.prop])
           }}</span>
-          <span v-else-if="item.scope === 'timeBtn'"
-            >{{ numTime(scope.row[item.prop]) }}
-            <el-button type="text" @click="getxq(scope.row)">详情</el-button>
-          </span>
           <span
             class="editInfoSty"
             v-else-if="item.scope === 'editInfo'"
@@ -1343,12 +1155,6 @@
               >修改</el-button
             >
           </div>
-          <span
-            class="editInfoSty"
-            v-else-if="item.scope === 'editInfoMore'"
-            @click="editInfo(scope.row)"
-            >{{ scope.row[item.prop1] }} - {{ scope.row[item.prop2] }}
-          </span>
           <span v-else-if="item.scope === 'InfoMore'"
             >{{ scope.row[item.prop1] }} - {{ scope.row[item.prop2] }}
           </span>
@@ -1371,9 +1177,6 @@
           <div v-else-if="item.scope === 'editInfoHTMLs'">
             {{ getSimpleText(scope.row[item.prop]) }}
           </div>
-          <span v-else-if="item.scope === 'minute'">{{
-            numTimeminute(scope.row[item.prop])
-          }}</span>
           <span
             v-else-if="item.scope === 'jumpPage'"
             @click="jumpPage(scope.row)"
@@ -1514,13 +1317,6 @@
           <span v-else-if="item.scope === 'ptai'">{{
             scope.row[item.prop] == 1 ? "微信小程序" : "未知"
           }}</span>
-          <span v-else-if="item.scope === 'diffTime'"
-            >{{
-              scope.row["sectionType"] === 2
-                ? scope.row[item.prop1]
-                : scope.row[item.prop2]
-            }}分钟</span
-          >
           <div v-else-if="item.scope === 'isOptions'">
             <template v-for="(itemt, indext) in item.options">
               <span
@@ -2026,11 +1822,6 @@ export default {
         return Number(res / 3600).toFixed(2);
       };
     },
-    numTimeminute: function () {
-      return function (res) {
-        return Number(res / 60).toFixed(2);
-      };
-    },
     compType: function () {
       return function (res, data) {
         if (data === "POST") {

+ 7 - 0
src/directive/filter/index.js

@@ -0,0 +1,7 @@
+// 金额格式化
+export function formatPrice(price) {
+  return price?.toLocaleString(
+    "zh-CN",
+    (undefined, { minimumFractionDigits: 2, maximumFractionDigits: 2 })
+  );
+}

+ 2 - 0
src/directive/index.js

@@ -4,6 +4,7 @@ import dialogDrag from './dialog/drag'
 import dialogDragWidth from './dialog/dragWidth'
 import dialogDragHeight from './dialog/dragHeight'
 import throttle from "./common/throttle"
+import { formatPrice } from "./filter";
 
 const install = function (Vue) {
   Vue.directive('hasRole', hasRole)
@@ -12,6 +13,7 @@ const install = function (Vue) {
   Vue.directive('dialogDragWidth', dialogDragWidth)
   Vue.directive('dialogDragHeight', dialogDragHeight)
   Vue.directive('throttle', throttle)
+  Vue.filter("formatPrice", formatPrice);
 }
 
 if (window.Vue) {

+ 23 - 0
src/newApi/examapply.js

@@ -110,6 +110,29 @@ export default {
             params: data
         })
     },
+    //考前须知
+    examapplybeforeknow(data) {
+        return request({
+            url: '/system/apply/before/know',
+            method: 'get',
+            params: data
+        })
+    },
+    //根据月份获取当月考试场次
+    obtainsystemsubscribesessiondata(data) {
+        return request({
+            url: `/system/subscribe/session/` + data,
+            method: 'get',
+        })
+    },
+    //考前须知修改
+    systemapplysaveorupbeforeknow(data) {
+        return request({
+            url: '/system/apply/saveorup/before/know',
+            method: 'post',
+            data
+        })
+    },
     //考场邮件地址
     examapplysendmail(data) {
         return request({

+ 24 - 0
src/newApi/goods.js

@@ -115,6 +115,22 @@ export default {
             data
         })
     },
+    //新增讲义商品
+    addGoodshandouts(data) {
+        return request({
+            url: '/goods/handouts',
+            method: 'post',
+            data
+        })
+    },
+    //修改讲义商品
+    editGoodshandouts(data) {
+        return request({
+            url: '/goods/handouts/edit',
+            method: 'post',
+            data
+        })
+    },
     //查询编辑数据是否有用户通过学时
     gradecheckGoodsChange(data) {
         return request({
@@ -155,4 +171,12 @@ export default {
             params: data
         })
     },
+    //商品修改-复制
+    goodsnodecopyadd(data) {
+        return request({
+            url: '/goods/node/copy/add',
+            method: 'post',
+            data
+        })
+    },
 }

+ 8 - 0
src/newApi/paperquestion.js

@@ -71,6 +71,14 @@ export default {
             data
         })
     },
+    //导入学监题目Word模板列表
+    bankquestionimportXueJianWordQuestionList(data) {
+        return request({
+            url: '/bank/question/importXueJianWordQuestionList',
+            method: 'post',
+            data
+        })
+    },
     //导入题目模板EXCEL
     importDatabankimportDataBackList(data) {
         return request({

+ 1 - 1
src/permission.js

@@ -34,10 +34,10 @@ router.beforeEach(async (to, from, next) => {
     let array = to.path.split('/').filter(i => !!i)
     sessionStorage.TenantId = array[1]
     if (to.query.data) {
+      to.query.data = to.query.data.replace(/\s/g, '+')
       store.dispatch('FedLogOut')
       await new Promise((resolve) => {
         $api.commonfreedecryptOfficialInfo({ data: to.query.data }).then(res => {
-          console.log(res, 'res')
           let data = {
             type: res.data.gradeType,
             userId: res.data.userId,

+ 8 - 8
src/store/modules/permission.js

@@ -12,17 +12,17 @@ const permission = {
     defaultRoutes: [],
     topbarRouters: [],
     sidebarRouters: [],
-    dictManages:{}//字典数据
+    dictManages: {}//字典数据
   },
-  getters:{
-  dictManages: state => state.dictManages
+  getters: {
+    dictManages: state => state.dictManages
   },
   mutations: {
     SET_ROUTES: (state, routes) => {
       state.addRoutes = routes
       state.routes = constantRoutes.concat(routes)
     },
-    GET_DICT_INFO(state){
+    GET_DICT_INFO(state) {
       api.obtaindictdata().then(res => {
         let newList = {}
         let list = res.rows
@@ -44,10 +44,10 @@ const permission = {
       // 顶部导航菜单默认添加统计报表栏指向首页
       const index = [{
         path: 'index',
-        meta: { title: '工作台', icon: 'dashboard'}
+        meta: { title: '工作台', icon: 'dashboard' }
       }]
       let ary = []
-      state.topbarRouters = ary.concat(index,routes)
+      state.topbarRouters = ary.concat(index, routes)
     },
     SET_SIDEBAR_ROUTERS: (state, routes) => {
       state.sidebarRouters = routes
@@ -129,12 +129,12 @@ function filterChildren(childrenMap, lastRouter = false) {
 }
 
 export const loadView = (view) => {
-  console.log(view,"view")
   if (process.env.NODE_ENV === 'development') {
     return (resolve) => require([`@/views/${view}`], resolve)
   } else {
     // 使用 import 实现生产环境的路由懒加载
-    return (resolve) => require([`@/views/${view}`],resolve)
+    return r => require.ensure([], () => r(require(`@/views/${view}`)), 'demo')
+    // return (resolve) => require([`@/views/${view}`],resolve)
   }
 }
 

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 4 - 0
src/utils/methodsTool.js


+ 1 - 1
src/utils/request.js

@@ -8,7 +8,7 @@ import methods from '@/utils/methodsTool';
 axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
 // 创建axios实例
 export const baseURL = process.env.VUE_APP_BASE_API
-// export const baseURL = 'http://192.168.1.24:5030/'
+// export const baseURL = 'http://192.168.1.7:5030/'
 export const BASE_IMG_URL = process.env.VUE_APP_IMG_API
 const service = axios.create({
   // axios中请求配置有baseURL选项,表示请求URL公共部分

+ 8 - 1
src/views/2Cport/pageSettings/header.vue

@@ -265,10 +265,17 @@ export default {
         if (res.rows.length) {
           this.initData = res.rows[0];
           this.listData = JSON.parse(res.rows[0].configValue);
+          if(!this.listData.Nav.some(i => i.name === '讲义资料')){
+            this.listData.Nav.push({
+              name:"讲义资料",
+              sort:6,
+              status:0
+            })
+          }
           if(!this.listData.Nav.some(i => i.name === '积分商城')){
             this.listData.Nav.push({
               name:"积分商城",
-              sort:6,
+              sort:7,
               status:0
             })
           }

+ 285 - 0
src/views/Marketing/activitySystem/components/goodsCheck.vue

@@ -0,0 +1,285 @@
+<template>
+  <div class="">
+    <BaseDialog
+      width="1100px"
+      :isShow.sync="isShow"
+      title="秒杀数据"
+      @close="close"
+      @submit="submit"
+    >
+      <search-box-new
+        ref="searchBox"
+        :formData="formData"
+        :formList="formList"
+        @search="search"
+        @init="init"
+        :topType="topType"
+      />
+      <table-list
+        rowKey="goodsId"
+        ref="tableList"
+        :tableSets="tableSet"
+        :tableData="tableData"
+        :navText="navText"
+        :loading="loading"
+      >
+      </table-list>
+      <pagination
+        :total="total"
+        :pageSize="formData.pageSize"
+        :currentPage="formData.pageNum"
+        @handleSizeChange="handleSizeChange"
+        @handleCurrentChange="handleCurrentChange"
+      />
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+import searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+export default {
+  components: {
+    searchBoxNew,
+    tableList,
+    pagination,
+  },
+  props: {
+    dialogVisible: {
+      type: Boolean,
+      default: false,
+    },
+  },
+  data() {
+    return {
+      info: {},
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        title: "商品管理",
+        index: 0,
+        ch: "条",
+        num: true,
+        choice: true,
+        addHide: true,
+        openCheckMore: true,
+        tableHide: true,
+        backFatherBtn: {
+          status: false,
+          title: "规则说明",
+        },
+      },
+      topType: true,
+      //搜索
+      formList: [
+        {
+          prop: "goodsName",
+          placeholder: "请输入商品名称",
+        },
+        {
+          prop: "educationTypeId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "subjectId",
+          placeholder: "科目",
+          scope: "sujectType",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "status",
+          placeholder: "商品状态",
+          scope: "select",
+          noClear: false,
+          options: [
+            {
+              label: "全部状态",
+              value: "0,1",
+            },
+            {
+              label: "有效",
+              value: 1,
+            },
+            {
+              label: "无效",
+              value: 0,
+            },
+          ],
+        },
+        {
+          prop: "goodsStatus",
+          placeholder: "前台可售状态",
+          scope: "select",
+          options: [
+            {
+              label: "已上架",
+              value: 1,
+            },
+            {
+              label: "未上架",
+              value: 0,
+            },
+          ],
+        },
+        {
+          prop1: "validityStartTime",
+          prop2: "validityEndTime",
+          placeholder1: "商品有效期开始时间",
+          placeholder2: "商品有效期结束时间",
+          scope: "moreDataPicker",
+        },
+      ],
+      formData: {
+        goodsType: "",
+        status: "0,1",
+        pageSize: 10,
+        pageNum: 1,
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "商品名称",
+          prop: "goodsName",
+          hidden: true,
+        },
+        {
+          label: "商品编码",
+          prop: "code",
+          hidden: true,
+        },
+        {
+          label: "商品类型",
+          prop: "goodsType",
+          hidden: true,
+        },
+        {
+          label: "教育类型",
+          prop: "educationName",
+          hidden: true,
+        },
+        {
+          label: "业务层次",
+          prop1: "projectName",
+          prop2: "businessName",
+          hidden: true,
+          scope: "InfoMore",
+        },
+        {
+          label: "科目",
+          prop: "subjectNames",
+          hidden: true,
+        },
+        {
+          label: "学时",
+          prop: "classHours",
+          hidden: true,
+        },
+        {
+          label: "商品价格",
+          prop: "standPrice",
+          hidden: true,
+          scope: "leftCh",
+          ch: "¥",
+        },
+        {
+          label: "商品划线价",
+          prop: "linePrice",
+          hidden: true,
+          scope: "leftCh",
+          ch: "¥",
+        },
+        {
+          label: "商品状态",
+          prop: "status",
+          hidden: true,
+          scope: "hasTime",
+        },
+        {
+          label: "可售状态",
+          prop: "goodsStatus",
+          hidden: true,
+          scope: "status",
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+      num: 0,
+    };
+  },
+  mounted() {},
+
+  methods: {
+    init() {
+      this.search(2);
+    },
+    search(int) {
+      this.loading = true;
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      if (int === 2) {
+        this.formData = {
+          goodsType: "",
+          status: "0,1",
+          pageSize: 10,
+          pageNum: 1,
+        };
+      }
+      if (int === 3) {
+        this.formData.pageNum = 1;
+      }
+      var data = JSON.parse(JSON.stringify(this.formData));
+      if (this.formData.validityStartTime) {
+        data.validityStartTime = data.validityStartTime / 1000;
+      }
+      if (this.formData.validityEndTime) {
+        data.validityEndTime = data.validityEndTime / 1000;
+      }
+      this.$api
+        .inquireGoods(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.search();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.search();
+    },
+    close() {},
+    submit() {},
+    initData() {},
+  },
+  computed: {
+    isShow: {
+      get() {
+        if (this.dialogVisible) {
+          this.initData();
+        }
+        return this.dialogVisible;
+      },
+      set(val) {
+        this.$emit("update:dialogVisible", false);
+      },
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 21 - 0
src/views/Marketing/activitySystem/coupon/index.vue

@@ -0,0 +1,21 @@
+<template>
+  <div id="coupon">
+优惠券coupon
+  </div>
+</template>
+
+<script>
+export default {
+  data () {
+    return {
+    }
+  },
+  methods: {
+
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+
+</style>

+ 215 - 0
src/views/Marketing/activitySystem/instantDeath/addEdit/index.vue

@@ -0,0 +1,215 @@
+<template>
+  <div class="addEdit">
+    <BaseDialog
+      width="700px"
+      :isShow.sync="isShow"
+      :title="info.id ? '修改活动' : '新增活动'"
+      @close="close"
+      @submit="submit"
+    >
+      <el-form
+        :model="formData"
+        :rules="rules"
+        ref="formData"
+        label-width="100px"
+        class="demo-ruleForm"
+        size="small"
+      >
+        <el-form-item label="活动名称:" prop="name">
+          <el-input v-model="formData.name"></el-input> </el-form-item
+        ><el-form-item label="活动产品:">
+          <div>
+            <el-button type="primary" @click="addGoods">添加</el-button>
+          </div>
+          <div class="goods">
+            <div v-for="(item, index) in formData.goodsList" class="goodsBox">
+              <div class="goodsData">
+                <img src="" alt="" />
+                <div class="title">
+                  <h3>考前培训一级建造师</h3>
+                  <p>课程分类:考前培训/一级建造师/市政</p>
+                  <p>商品原价:<span>¥22.00</span></p>
+                </div>
+              </div>
+              <div class="content">
+                <el-form-item
+                  label="秒杀价格:"
+                  :prop="'goodsList.' + index + '.price'"
+                  :rules="rules['price']"
+                >
+                  <el-input v-model="item.price"></el-input> </el-form-item
+                ><el-form-item
+                  label="秒杀库存:"
+                  :prop="'goodsList.' + index + '.num'"
+                  :rules="rules['num']"
+                >
+                  <el-input v-model="item.name"></el-input>
+                </el-form-item>
+              </div>
+              <div class="foolter">
+                <el-button @click="formData.goodsList.splice(index, 1)"
+                  >删除</el-button
+                >
+              </div>
+            </div>
+          </div> </el-form-item
+        ><el-form-item label="活动时间:" prop="time">
+          <el-date-picker
+            v-model="formData.time"
+            type="datetimerange"
+            range-separator="至"
+            start-placeholder="开始日期"
+            end-placeholder="结束日期"
+            value-format="timestamp"
+          >
+          </el-date-picker> </el-form-item
+        ><el-form-item label="订单取消:">
+          买家
+          <el-input-number
+            style="width: 140px; margin: 0px 10px"
+            v-model="formData.num"
+            :min="0"
+            :precision="0"
+            :controls="false"
+            placeholder="0则为不限时间"
+          ></el-input-number
+          >分钟内未付款,自动取消订单。</el-form-item
+        ><el-form-item label="展示:">
+          <el-switch
+            :active-value="1"
+            :inactive-value="0"
+            v-model="formData.switch"
+            active-color="#13ce66"
+            inactive-color="#ff4949"
+          >
+          </el-switch> </el-form-item
+      ></el-form>
+    </BaseDialog>
+    <goodsCheck ref="goodsCheck" :dialogVisible.sync="dialogVisibleGoods" />
+  </div>
+</template>
+
+<script>
+import goodsCheck from "../../components/goodsCheck.vue";
+export default {
+  components: { goodsCheck },
+  props: {
+    dialogVisible: {
+      type: Boolean,
+      default: false,
+    },
+    info: {
+      type: Object,
+      default: () => {
+        return {};
+      },
+    },
+  },
+  data() {
+    return {
+      formData: {
+        goodsList: [
+          {
+            price: 100,
+            num: 2,
+          },
+          {
+            price: 100,
+            num: 2,
+          },
+        ],
+      },
+      rules: {
+        name: [{ required: true, message: "请输入活动名称", trigger: "blur" }],
+        time: [
+          { required: true, message: "请选择活动时间", trigger: "change" },
+        ],
+        price: [
+          {
+            required: true,
+            message: "请输入秒杀价格(元)",
+            trigger: "blur",
+          },
+        ],
+        num: [
+          {
+            required: true,
+            message: "请输入可秒杀库存数量",
+            trigger: "change",
+          },
+        ],
+      },
+      dialogVisibleGoods: false,
+    };
+  },
+
+  mounted() {},
+
+  methods: {
+    //添加商品
+    addGoods() {
+      this.dialogVisibleGoods = true;
+      this.$refs.goodsCheck.init();
+    },
+    init() {},
+    close() {},
+    submit() {},
+  },
+  computed: {
+    isShow: {
+      get() {
+        if (this.dialogVisible) {
+          this.init();
+        }
+        return this.dialogVisible;
+      },
+      set(val) {
+        this.$emit("update:dialogVisible", false);
+      },
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+.goods {
+  padding: 14px;
+  max-height: 470px;
+  overflow: auto;
+  .goodsBox {
+    padding: 10px;
+    margin-bottom: 18px;
+    box-shadow: 0px 0px 8px 2px rgba(0, 0, 0, 0.1);
+    border-radius: 8px;
+    .goodsData {
+      display: flex;
+      margin-bottom: 20px;
+      & > img {
+        width: 130px;
+        height: 90px;
+        margin-right: 14px;
+      }
+      & > .title {
+        flex: 1;
+        display: flex;
+        flex-direction: column;
+        justify-content: space-between;
+        h3 {
+          margin: 0;
+        }
+        p {
+          margin: 0;
+        }
+      }
+    }
+    .content {
+      padding: 14px;
+      background-color: #eee;
+    }
+    .foolter {
+      margin-top: 10px;
+      text-align: end;
+    }
+  }
+}
+</style>

+ 368 - 0
src/views/Marketing/activitySystem/instantDeath/dialogInstan.vue

@@ -0,0 +1,368 @@
+<template>
+  <div class="dialogInstan">
+    <BaseDialog
+      width="900px"
+      :isShow.sync="isShow"
+      title="秒杀数据"
+      @close="close"
+      @submit="submit"
+      ><search-box-new
+        ref="searchBox"
+        :formData="formData"
+        :formList="formList"
+        @search="search"
+        @init="init"
+      />
+
+      <picture-list
+        ref="pictureList"
+        :info="info"
+        :list="showTabList"
+      ></picture-list>
+      <table-list
+        rowKey="id"
+        ref="tableList"
+        :tableSets="tableSet"
+        :tableData="tableData"
+        :navText="navText"
+        :loading="loading"
+        @addClick="addClick"
+        @emitData="emitData"
+      >
+        <template slot="switch" slot-scope="props">
+          <el-switch
+            v-model="props.scope.row.switch"
+            active-color="#13ce66"
+            inactive-color="#ff4949"
+            @change="changeSwitch($event, props.scope.row)"
+          >
+          </el-switch>
+        </template>
+        <template slot="btn" slot-scope="props">
+          <el-button type="text" @click="dataFunc(props.scope.row)"
+            >数据</el-button
+          >
+          <el-button type="text">编辑</el-button>
+          <el-button type="text">删除</el-button>
+        </template>
+      </table-list>
+      <pagination
+        :total="total"
+        :pageSize="formData.pageSize"
+        :currentPage="formData.pageNum"
+        @handleSizeChange="handleSizeChange"
+        @handleCurrentChange="handleCurrentChange"
+      />
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+import pictureList from "@/components/Comon/pictureList.vue";
+import searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+export default {
+  components: {
+    searchBoxNew,
+    tableList,
+    pagination,
+    pictureList,
+  },
+  props: {
+    dialogVisible: {
+      type: Boolean,
+      default: false,
+    },
+    orderInfo: {
+      type: Object,
+      default: () => {
+        return {};
+      },
+    },
+  },
+  data() {
+    return {
+      showTabList: [
+        {
+          label: "总订单",
+          prop: "unPayMoneyTotal",
+          img: "盈亏",
+          ch: " ",
+        },
+        {
+          label: "总金额",
+          prop: "unPayMoneyTotal",
+          img: "合同金额",
+        },
+        {
+          label: "待支付订单",
+          prop: "unPayMoneyTotal",
+          img: "盈亏",
+          ch: " ",
+        },
+        {
+          label: "待支付金额",
+          prop: "unPayMoneyTotal",
+          img: "合同金额",
+        },
+        {
+          label: "已支付订单",
+          prop: "unPayMoneyTotal",
+          img: "盈亏",
+          ch: " ",
+        },
+        {
+          label: "已支付金额",
+          prop: "unDeductMoneyTotal",
+          img: "合同金额",
+        },
+        {
+          label: "秒杀人数",
+          prop: "deductMoneyTotal",
+          img: "合同金额",
+          ch: " ",
+        },
+        {
+          label: "支付人数",
+          prop: "payMoneyTotal",
+          img: "合同金额",
+          ch: " ",
+        },
+      ],
+      info: {},
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        title: "秒杀管理",
+        index: 0,
+        ch: "条",
+        num: true,
+        choice: false,
+        addHide: true,
+        openCheckMore: false,
+        tableHide: true,
+        backFatherBtn: {
+          status: false,
+          title: "规则说明",
+        },
+      },
+      //搜索
+      formList: [
+        {
+          lable: "商品名称",
+          prop: "name",
+          placeholder: "请输入商品名称",
+        },
+        {
+          prop: "educationTypeId",
+          placeholder: "教育类型",
+          scope: "educationType",
+        },
+        {
+          prop: "businessId",
+          placeholder: "业务层次",
+          scope: "businessLevel",
+          edu: "educationTypeId",
+        },
+        {
+          prop: "subjectId",
+          placeholder: "科目",
+          scope: "sujectType",
+          edu: "educationTypeId",
+        },
+        {
+          lable: "支付状态",
+          prop: "status",
+          placeholder: "请选择支付状态",
+          scope: "select",
+          options: [
+            { label: "待支付", value: 0 },
+            { label: "已支付", value: 1 },
+          ],
+        },
+        {
+          prop1: "validityStartTime",
+          prop2: "validityEndTime",
+          placeholder1: "秒杀开始时间",
+          placeholder2: "秒杀结束时间",
+          scope: "moreDataPicker",
+        },
+      ],
+      formData: {
+        pageSize: 10,
+        pageNum: 1,
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "秒杀时间",
+          prop: "createTime",
+          hidden: true,
+          scope: "aTimeList",
+        },
+        {
+          label: "订单来源",
+          prop: "name",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "小程序",
+              value: 0,
+            },
+            {
+              label: "电脑端",
+              value: 1,
+            },
+            {
+              label: "H5",
+              value: 2,
+            },
+          ],
+        },
+        {
+          label: "用户手机",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "用户姓名",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "用户身份号",
+          prop: "standPrice",
+          hidden: true,
+        },
+        {
+          label: "秒杀价格",
+          prop: "standPrice",
+          hidden: true,
+          scope: "leftCh",
+          ch: "¥",
+        },
+        {
+          label: "支付状态",
+          prop: "status",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "待支付",
+              value: 0,
+            },
+            {
+              label: "已支付",
+              value: 1,
+            },
+          ],
+        },
+        {
+          label: "商品名称",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "商品编码",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "教育类型",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "培训项目",
+          prop1: "projectName",
+          prop2: "businessName",
+          scope: "InfoMore",
+          hidden: true,
+        },
+        {
+          label: "科目",
+          prop: "posterTempName",
+          hidden: true,
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+    };
+  },
+
+  mounted() {},
+
+  methods: {
+    init() {
+      this.search();
+    },
+
+    //switch触发
+    changeSwitch(e, item) {
+      if (true) {
+        item.switch = !e;
+      }
+    },
+    addClick() {},
+    editClick() {},
+    //规则说明
+    emitData() {},
+    search(v) {
+      this.loading = true;
+      if (v === 2) {
+        this.formData = {
+          pageSize: 10,
+          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
+        .distributiontemplist(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.search();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.search();
+    },
+    close() {},
+    submit() {},
+  },
+  computed: {
+    isShow: {
+      get() {
+        if (this.dialogVisible) {
+          this.init();
+        }
+        return this.dialogVisible;
+      },
+      set(val) {
+        this.$emit("update:dialogVisible", false);
+      },
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 341 - 0
src/views/Marketing/activitySystem/instantDeath/index.vue

@@ -0,0 +1,341 @@
+<template>
+  <div id="instantDeath">
+    <search-box-new
+      ref="searchBox"
+      :formData="formData"
+      :formList="formList"
+      @search="search"
+      @init="init"
+    />
+
+    <picture-list
+      ref="pictureList"
+      :info="info"
+      :list="showTabList"
+    ></picture-list>
+    <table-list
+      rowKey="id"
+      ref="tableList"
+      :tableSets="tableSet"
+      :tableData="tableData"
+      :navText="navText"
+      :loading="loading"
+      @addClick="addClick"
+      @emitData="emitData"
+    >
+      <template slot="switch" slot-scope="props">
+        <el-switch
+          v-model="props.scope.row.switch"
+          active-color="#13ce66"
+          inactive-color="#ff4949"
+          @change="changeSwitch($event, props.scope.row)"
+        >
+        </el-switch>
+      </template>
+      <template slot="btn" slot-scope="props">
+        <el-button type="text" @click="dataFunc(props.scope.row)"
+          >数据</el-button
+        >
+        <el-button type="text">编辑</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"
+    />
+    <dialogInstan
+      :dialogVisible.sync="dialogVisibleData"
+      :orderInfo="activeOrderInfo"
+    />
+    <ruleSpecification :dialogVisible.sync="dialogVisibleRule" />
+    <addEdit  :dialogVisible.sync="dialogVisibleAddEdit" />
+  </div>
+</template>
+
+<script>
+import pictureList from "@/components/Comon/pictureList.vue";
+import searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+import dialogInstan from "./dialogInstan.vue";
+import ruleSpecification from "./ruleSpecification.vue";
+import addEdit from "./addEdit/index.vue";
+
+export default {
+  // name: "InstantDeath",
+  components: {
+    searchBoxNew,
+    tableList,
+    pagination,
+    pictureList,
+    dialogInstan,
+    ruleSpecification,
+    addEdit
+  },
+  data() {
+    return {
+      showTabList: [
+        {
+          label: "总订单",
+          prop: "unPayMoneyTotal",
+          img: "盈亏",
+          ch: " ",
+        },
+        {
+          label: "总金额",
+          prop: "unPayMoneyTotal",
+          img: "合同金额",
+        },
+        {
+          label: "待支付订单",
+          prop: "unPayMoneyTotal",
+          img: "盈亏",
+          ch: " ",
+        },
+        {
+          label: "待支付金额",
+          prop: "unPayMoneyTotal",
+          img: "合同金额",
+        },
+        {
+          label: "已支付订单",
+          prop: "unPayMoneyTotal",
+          img: "盈亏",
+          ch: " ",
+        },
+        {
+          label: "已支付金额",
+          prop: "unDeductMoneyTotal",
+          img: "合同金额",
+        },
+        {
+          label: "秒杀人数",
+          prop: "deductMoneyTotal",
+          img: "合同金额",
+          ch: " ",
+        },
+        {
+          label: "支付人数",
+          prop: "payMoneyTotal",
+          img: "合同金额",
+          ch: " ",
+        },
+      ],
+      info: {},
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        title: "秒杀列表",
+        index: 0,
+        ch: "条",
+        num: true,
+        choice: false,
+        addHide: false,
+        openCheckMore: true,
+        changeWidth: "160px",
+        backFatherBtn: {
+          status: true,
+          title: "规则说明",
+        },
+      },
+      //搜索
+      formList: [
+        {
+          lable: "活动名称",
+          prop: "name",
+          placeholder: "请输入活动名称",
+        },
+        {
+          lable: "活动状态",
+          prop: "status",
+          placeholder: "请选择活动状态",
+          scope: "select",
+          options: [
+            { label: "未开始", value: 0 },
+            { label: "进行中", value: 1 },
+            { label: "已结束", value: 2 },
+          ],
+        },
+        {
+          lable: "展现",
+          prop: "status1",
+          placeholder: "请选择展现状态",
+          scope: "select",
+          options: [
+            { label: "启动", value: 1 },
+            { label: "暂停", value: 0 },
+          ],
+        },
+      ],
+      formData: {
+        pageSize: 10,
+        pageNum: 1,
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "活动名称",
+          prop: "name",
+          hidden: true,
+        },
+        {
+          label: "有效时间",
+          prop1: "validityStartTime",
+          prop2: "validityEndTime",
+          scope: "TimeLists",
+          Diszing: false,
+          hidden: true,
+        },
+        {
+          label: "秒杀总订单",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "秒杀总金额",
+          prop: "standPrice",
+          hidden: true,
+          scope: "leftCh",
+          ch: "¥",
+        },
+        {
+          label: "待支付订单",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "待支付金额",
+          prop: "standPrice",
+          hidden: true,
+          scope: "leftCh",
+          ch: "¥",
+        },
+        {
+          label: "已支付订单",
+          prop: "posterTempName",
+          hidden: true,
+        },
+        {
+          label: "已支付金额",
+          prop: "standPrice",
+          hidden: true,
+          scope: "leftCh",
+          ch: "¥",
+        },
+        {
+          label: "展示",
+          prop: "posterTempName",
+          hidden: true,
+          scope: "slot",
+          slotName: "switch",
+        },
+        {
+          label: "状态",
+          prop: "status",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "未开始",
+              value: 0,
+            },
+            {
+              label: "进行中",
+              value: 1,
+            },
+            {
+              label: "已结束",
+              value: 2,
+            },
+          ],
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+      dialogVisibleData: false,
+      dialogVisibleRule: false,
+      dialogVisibleAddEdit:false,
+      activeOrderInfo: {},
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    //switch触发
+    changeSwitch(e, item) {
+      if (true) {
+        item.switch = !e;
+      }
+    },
+    addClick() {
+        this.dialogVisibleAddEdit = true
+    },
+    editClick() {},
+    //规则说明
+    emitData() {
+      this.dialogVisibleRule = true;
+    },
+    dataFunc() {
+      this.dialogVisibleData = true;
+    },
+    del(item) {
+      this.$confirm("是否删除该数据?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          this.$message({
+            type: "success",
+            message: "删除成功!",
+          });
+        })
+        .catch(() => {});
+    },
+    search(v) {
+      this.loading = true;
+      if (v === 2) {
+        this.formData = {
+          pageSize: 10,
+          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
+        .distributiontemplist(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.search();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.search();
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 57 - 0
src/views/Marketing/activitySystem/instantDeath/ruleSpecification.vue

@@ -0,0 +1,57 @@
+<template>
+  <div class="dialogInstan">
+    <BaseDialog
+      width="500px"
+      :isShow.sync="isShow"
+      title="规则说明"
+      @close="close"
+      @submit="submit"
+    >
+      <el-input
+        v-model="value"
+        type="textarea"
+        :rows="6"
+        placeholder="输入秒杀规则说明"
+      ></el-input>
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+export default {
+  props: {
+    dialogVisible: {
+      type: Boolean,
+      default: false,
+    },
+  },
+  data() {
+    return {
+      value: "",
+    };
+  },
+
+  mounted() {},
+
+  methods: {
+    init() {},
+    close() {},
+    submit() {},
+  },
+  computed: {
+    isShow: {
+      get() {
+        if (this.dialogVisible) {
+          this.init();
+        }
+        return this.dialogVisible;
+      },
+      set(val) {
+        this.$emit("update:dialogVisible", false);
+      },
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 312 - 0
src/views/Marketing/goods/commodityManageMent/add/handoutContent/handoutsCheck.vue

@@ -0,0 +1,312 @@
+<template>
+  <div id="">
+    <!-- 关联讲义列表 -->
+    <el-dialog
+      :visible.sync="jYactiveBoxs"
+      width="1080px"
+      append-to-body
+      :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="jYactiveBoxs = false"
+          />
+        </div>
+      </div>
+      <div style="margin-bottom: 10px">
+        <!-- 搜索框 -->
+        <el-input
+          style="width: 230px; margin-right: 10px"
+          :size="size"
+          v-model="formData['key']"
+          placeholder="请输入讲义标题/讲义编码"
+        ></el-input>
+        <el-button :size="size" type="primary" @click="getJyData(1)"
+          >查询</el-button
+        >
+        <el-button :size="size" @click="getJyData(0)">重置</el-button>
+      </div>
+      <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
+              :label="scope.row.handoutsId"
+              v-model="handoutsId"
+              @change.native="getTemplateRow(scope.$index, scope.row)"
+              >{{ "" }}</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>
+              <ul v-else-if="item.scope === 'eduType'" class="ulAuto">
+                <template v-for="(itm, inds) in scope.row[item.prop]">
+                  <li :key="inds" v-if="inds === 0">
+                    {{
+                      itm.educationName +
+                      "-" +
+                      itm.projectName +
+                      "-" +
+                      itm.businessName
+                    }}
+                  </li>
+                </template>
+                <el-popover
+                  :key="Math.random()"
+                  placement="right"
+                  trigger="click"
+                >
+                  <ul>
+                    <li v-for="(itm, inds) in scope.row[item.prop]" :key="inds">
+                      {{ inds + 1 }}、
+                      {{
+                        itm.educationName +
+                        "-" +
+                        itm.projectName +
+                        "-" +
+                        itm.businessName
+                      }}
+                    </li>
+                  </ul>
+                  <el-button
+                    slot="reference"
+                    style="margin-left: 6px"
+                    type="text"
+                    v-if="scope.row[item.prop].length > 1"
+                    size="mini"
+                    >更多</el-button
+                  >
+                </el-popover>
+              </ul>
+              <span v-else-if="item.scope === 'canDownload'">{{
+                scope.row[item.prop] === 1 ? "是" : "否"
+              }}</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"
+      />
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="jYactiveBoxs = false">取 消</el-button>
+        <el-button type="primary" @click="submitBox">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import pagination from "@/components/pagination";
+export default {
+  components: { pagination },
+  data() {
+    return {
+      size: "small",
+      total: 0,
+      tableSet: [
+        { label: "讲义编码", prop: "encoder", width: "150px" },
+        { label: "讲义标题", prop: "handoutsName" },
+        {
+          label: "是否可下载",
+          prop: "canDownload",
+          scope: "canDownload",
+          width: "140px",
+        },
+        { label: "发布状态", prop: "status", scope: "Status", width: "140px" },
+      ],
+      tableData: [],
+      formData: {},
+      handoutsId: "",
+      handoutsName: "",
+      handoutsCode: "",
+      jYactiveBoxs: false,
+    };
+  },
+  methods: {
+    openBox(id) {
+      this.getJyData(0);
+      this.handoutsId = id || "";
+      this.jYactiveBoxs = true;
+    },
+    /**
+     * 临时选中
+     */
+    getTemplateRow(index, row) {
+      this.handoutsId = row.handoutsId;
+      this.handoutsName = row.handoutsName;
+      this.handoutsCode = row.encoder;
+    },
+    /**
+     * 确定选中
+     */
+    submitBox() {
+      this.jYactiveBoxs = false;
+      this.$emit("backData", {
+        handoutsId: this.handoutsId,
+        handoutsName: this.handoutsName,
+        handoutsCode: this.handoutsCode,
+      });
+    },
+    /**
+     * 搜索
+     */
+    getJyData(int) {
+      if (int === 0) {
+        this.formData = {
+          businessId: this.$parent.listData.businessId,
+          status: 1,
+          pageSize: 10,
+          pageNum: 1,
+          key: "",
+        };
+      }
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      this.$api.inquireCourseHandoutsList(this.formData).then((res) => {
+        this.total = res.total;
+        this.tableData = res.rows;
+      });
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.getJyData();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.getJyData();
+    },
+  },
+};
+</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;
+    }
+  }
+}
+.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>

+ 51 - 0
src/views/Marketing/goods/commodityManageMent/add/handoutContent/index.vue

@@ -0,0 +1,51 @@
+<template>
+  <div id="handoutContent">
+    <el-form-item label="关联讲义" prop="handoutsId">
+      <div>
+        <el-button @click="goToActivehandouts">选择讲义</el-button>
+        <span v-if="listData.handoutsId" style="margin-left: 12px"
+          >{{ listData.handoutsCode }} - {{ listData.handoutsName }}</span
+        >
+        <el-button
+          style="margin-left: 12px"
+          v-if="listData.handoutsId"
+          type="text"
+          @click="clearGoods"
+          >删除</el-button
+        >
+      </div>
+    </el-form-item>
+    <handouts-check ref="handoutsCheck" @backData="backData" />
+  </div>
+</template>
+
+<script>
+import handoutsCheck from "./handoutsCheck.vue";
+export default {
+  components: { handoutsCheck },
+  props: ["listData"],
+  data() {
+    return {};
+  },
+  methods: {
+    goToActivehandouts() {
+      //打开讲义资料组件
+      this.$refs.handoutsCheck.openBox(this.listData.handoutsId);
+    },
+    backData(activeObj) {
+      this.$set(this.listData, "handoutsId", activeObj.handoutsId);
+      this.$set(this.listData, "handoutsName", activeObj.handoutsName);
+      this.$set(this.listData, "handoutsCode", activeObj.handoutsCode);
+      this.$bus.$emit("validateHandoutsId");
+    },
+    clearGoods() {
+      this.$set(this.listData, "handoutsId", "");
+      this.$set(this.listData, "handoutsName", "");
+      this.$set(this.listData, "handoutsCode", "");
+      this.$bus.$emit("validateHandoutsId");
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 56 - 8
src/views/Marketing/goods/commodityManageMent/add/index.vue

@@ -10,7 +10,11 @@
       <h5>商品信息</h5>
       <div class="boxBorderStyle">
         <h5 class="segmentationStyle">基本信息</h5>
-        <product-information ref="productInformation" :listData="listData" @activeExternalLinkStatus="activeExternalLinkStatus" />
+        <product-information
+          ref="productInformation"
+          :listData="listData"
+          @activeExternalLinkStatus="activeExternalLinkStatus"
+        />
         <h5 class="segmentationStyle">商品价格和有效期</h5>
         <price-period ref="pricePeriod" :listData="listData" />
         <div
@@ -43,6 +47,10 @@
           </h5>
           <make-up-exam ref="makeUpExam" :listData="listData" />
         </div>
+        <div v-if="listData.goodsType === 8 && listData.businessId">
+          <h5 class="segmentationStyle">关联讲义资料</h5>
+          <handout-content ref="handoutContent" :listData="listData" />
+        </div>
         <!-- 学习次数及服务时间 -->
         <configure-content-parameters
           v-if="listData.businessId && listData.goodsType"
@@ -92,6 +100,7 @@ import pricePeriod from "./pricePeriod.vue";
 import courseContent from "./courseContent/index.vue";
 import bankContent from "./bankContent/index.vue";
 import makeUpExam from "./makeUpExam/index.vue";
+import handoutContent from "./handoutContent/index.vue";
 import configureContentParameters from "./configureContentParameters.vue";
 import issueAcertificate from "./issueAcertificate.vue";
 import introduction from "./introduction.vue";
@@ -106,6 +115,7 @@ export default {
     issueAcertificate,
     introduction,
     makeUpExam,
+    handoutContent,
   },
   data() {
     var validatorClassHours = (rule, value, callback) => {
@@ -203,8 +213,8 @@ export default {
         status: 1,
         certificateTypeId: "",
         showStatus: 1,
-        externalLinkStatus:0,
-        commitPeriodStatus:0
+        externalLinkStatus: 0,
+        commitPeriodStatus: 0,
       },
       rules: {
         year: [
@@ -230,6 +240,14 @@ export default {
             trigger: "change",
           },
         ],
+        gradeType: [
+          {
+            type: "number",
+            required: true,
+            message: "请选择班级类型",
+            trigger: "change",
+          },
+        ],
         goodsName: [
           {
             required: true,
@@ -345,6 +363,13 @@ export default {
             trigger: "blur",
           },
         ],
+        handoutsId: [
+          {
+            required: true,
+            message: "请选择关联讲义资料",
+            trigger: "blur",
+          },
+        ],
         examNumber: [
           {
             required: false,
@@ -472,6 +497,9 @@ export default {
     this.$bus.$on("validateMakeId", () => {
       this.$refs["listData"].validateField("makeGoodsId");
     });
+    this.$bus.$on("validateHandoutsId", () => {
+      this.$refs["listData"].validateField("handoutsId");
+    });
     this.$bus.$on("validateCoverUrl", () => {
       this.$refs["listData"].validateField("coverUrl");
     });
@@ -495,11 +523,11 @@ export default {
   activated() {},
   methods: {
     //判断是否必填外链
-    activeExternalLinkStatus(e){
-      if(e){
-        this.rules.externalLink[0].required = true
-      }else{
-        this.rules.externalLink[0].required = false
+    activeExternalLinkStatus(e) {
+      if (e) {
+        this.rules.externalLink[0].required = true;
+      } else {
+        this.rules.externalLink[0].required = false;
       }
       this.$refs["listData"].validateField("externalLink");
     },
@@ -725,6 +753,25 @@ export default {
             this.disabledBtn = false;
           });
       }
+      if (this.listData.goodsType === 8) {
+        this.$api
+          .addGoodshandouts(data)
+          .then((res) => {
+            this.$message.success("新增成功");
+            setTimeout(() => {
+              this.$store
+                .dispatch("tagsView/exitView", this.$route)
+                .then((res) => {
+                  this.$router.push({
+                    path: "commodityManageMent",
+                  });
+                });
+            }, 300);
+          })
+          .catch(() => {
+            this.disabledBtn = false;
+          });
+      }
     },
     /**
      * 视频商品参数转换
@@ -880,6 +927,7 @@ export default {
   beforeDestroy() {
     this.$bus.$off("clearValidateFuncAdd");
     this.$bus.$off("validateMakeId");
+    this.$bus.$off("validateHandoutsId");
     this.$bus.$off("validateCoverUrl");
     this.$bus.$off("initTimeVal");
     this.$bus.$off("againValidate");

+ 38 - 1
src/views/Marketing/goods/commodityManageMent/add/productInformation.vue

@@ -69,6 +69,21 @@
             </el-option>
           </el-select>
         </el-form-item>
+        <el-form-item
+          label="班级类型"
+          prop="gradeType"
+          v-if="listData.goodsType === 1"
+        >
+          <el-select v-model="listData.gradeType" placeholder="请选择班级类型">
+            <el-option
+              v-for="(item, index) in gradeType"
+              :key="index"
+              :label="item.label"
+              :value="item.value"
+            >
+            </el-option>
+          </el-select>
+        </el-form-item>
         <el-form-item
           label="院校"
           prop="schoolId"
@@ -201,6 +216,20 @@ export default {
   props: ["listData"],
   data() {
     return {
+      gradeType: [
+        {
+          label: "基础班",
+          value: 1,
+        },
+        {
+          label: "强化班",
+          value: 2,
+        },
+        {
+          label: "私塾班",
+          value: 3,
+        },
+      ],
       goodsTypeOptions: [
         {
           label: "视频",
@@ -222,6 +251,10 @@ export default {
           label: "直播",
           value: 6,
         },
+        {
+          label: "讲义资料",
+          value: 8,
+        },
       ], //商品类型
       newCourTypeOptions: [], //业务层次
       newSchoolOption: [], //院校
@@ -248,6 +281,8 @@ export default {
       this.$set(this.listData, "majorId", "");
       this.$set(this.listData, "subjectIds", "");
       this.$set(this.listData, "handoutsId", "");
+      this.$set(this.listData, "handoutsName", "");
+      this.$set(this.listData, "handoutsCode", "");
       this.$bus.$emit("sendBybus");
       this.$bus.$emit("sendBybusBank");
       if (val) {
@@ -326,10 +361,13 @@ export default {
      * 商品类型切换
      */
     changeTypes(val) {
+      this.$set(this.listData, "gradeType", ""); //班级类型
       this.$set(this.listData, "examNumber", "0"); //考试次数
       this.$set(this.listData, "doNumber", "0"); //刷题次数
       this.$set(this.listData, "studyCount", "1"); //学习次数
       this.$set(this.listData, "handoutsId", ""); //讲义ID
+      this.$set(this.listData, "handoutsName", "");
+      this.$set(this.listData, "handoutsCode", "");
       this.$set(this.listData, "serviceTimeType", ""); //学习服务期类型
       this.$set(this.listData, "serviceTimeNum", ""); //学习服务期年月日
       this.$set(this.listData, "studyTimeArrays", []); //学习服务期具体时间
@@ -357,7 +395,6 @@ export default {
         );
       } //封面
       if (val === 1 || val === 6) {
-        console.log("封面", val);
         this.$bus.$emit("sendBybus");
       }
       if (val === 2) {

+ 69 - 9
src/views/Marketing/goods/commodityManageMent/edit/courseContent/index.vue

@@ -4,7 +4,10 @@
       <el-button
         @click="addCourse"
         size="small"
-        :disabled="tableData.length > 0 && tableData[0].type > 0 || tableData.length > 0 "
+        :disabled="
+          (tableData.length > 0 && tableData[0].type > 0) ||
+          tableData.length > 0
+        "
         >添加课程</el-button
       >
       <el-button
@@ -123,12 +126,7 @@
           <span v-else>{{ scope.row[item.prop] }}</span></template
         >
       </el-table-column>
-      <el-table-column
-        label="操作"
-        align="center"
-        fixed="right"
-        width="100px"
-      >
+      <el-table-column label="操作" align="center" fixed="right" width="100px">
         <template slot-scope="scope">
           <el-button
             type="text"
@@ -141,6 +139,11 @@
             v-if="scope.row.type === 3 && scope.row.sectionType !== 1"
             @click="openShare(scope.row)"
             >分享</el-button
+          ><el-button
+            type="text"
+            @click="handelCopy(scope.row)"
+            v-if="copyShowStatus"
+            >复制</el-button
           >
         </template>
       </el-table-column>
@@ -160,6 +163,22 @@
     <share ref="share" />
     <every-day-study-num ref="everyDayStudyNum" @backData="backEveryDaySet" />
     <handout-view ref="handoutView" @backData="backHandoutView" />
+    <Base-dialog
+      title="商品复制机构选择"
+      :isShow.sync="dialogCopyVisible"
+      @submit="goodsCopy"
+      :disabledBtn="copyLoading"
+    >
+      <el-radio-group v-model="tenantId">
+        <el-radio
+          style="display: block; margin-bottom: 10px"
+          :label="item.tenantId"
+          v-for="item in tenantList"
+          :key="item.tenantId"
+          >{{ item.tenantName }}</el-radio
+        >
+      </el-radio-group>
+    </Base-dialog>
   </div>
 </template>
 
@@ -171,6 +190,7 @@ import playPhoto from "./playPhoto.vue";
 import share from "./share.vue";
 import everyDayStudyNum from "./everyDayStudyNum.vue";
 import handoutView from "./handoutView.vue";
+import { getTenantList } from "@/api/resource/good";
 
 export default {
   components: {
@@ -185,6 +205,12 @@ export default {
   props: ["listData", "submitStatusInfo"],
   data() {
     return {
+      dialogCopyVisible: false,
+      copyLoading: false,
+      activeKeyId: [],
+      activeKeyType: "",
+      tenantId: "",
+      tenantList: [],
       tableSetVideo: [
         { label: "排序", prop: "sort", scope: "inputs", width: "100" },
         { label: "编码", prop: "code", width: "140" },
@@ -229,6 +255,9 @@ export default {
     },
   },
   computed: {
+    copyShowStatus(){
+      return this.listData.goodsType === 1 && sessionStorage.getItem('TenantId') == '867735392558919680'
+    },
     compayTypes: function () {
       return function (array) {
         let ary = [];
@@ -251,8 +280,40 @@ export default {
     this.$bus.$on("sendBybus", () => {
       this.tableData = [];
     });
+    getTenantList().then((res) => {
+      this.tenantList = res.data;
+      console.log(res.data);
+    });
   },
   methods: {
+    handelCopy(item) {
+      this.activeKeyId = item.keyId.split("-").map(Number);
+      this.activeKeyType = item.type;
+      this.tenantId = "";
+      this.copyLoading = false;
+      this.dialogCopyVisible = true;
+    },
+    goodsCopy() {
+      var data = {
+        tenantId: [this.tenantId],
+        goodsId: this.$route.query.id,
+        courseId: this.activeKeyId[0] || undefined,
+        modelId: this.activeKeyId[1] || undefined,
+        chapterId: this.activeKeyId[2] || undefined,
+        sectionId: this.activeKeyId[3] || undefined,
+        type: this.activeKeyType + 1,
+      };
+      this.copyLoading = true;
+      this.$api
+        .goodsnodecopyadd(JSON.parse(JSON.stringify(data)))
+        .then((res) => {
+          this.$message.success("复制成功");
+          this.dialogCopyVisible = false;
+        })
+        .finally(() => {
+          this.copyLoading = false;
+        });
+    },
     /**
      * 打开分享窗口
      */
@@ -572,5 +633,4 @@ export default {
 };
 </script>
 
-<style lang="less" scoped>
-</style>
+<style lang="less" scoped></style>

+ 12 - 6
src/views/Marketing/goods/commodityManageMent/edit/courseContent/share.vue

@@ -19,12 +19,15 @@
       </div>
       <el-form label-width="180px" :model="formLabelAlign">
         <el-form-item label="观看权限:">
-          <el-radio-group v-model="formLabelAlign.watchPer" @change="submitTable">
+          <el-radio-group
+            v-model="formLabelAlign.watchPer"
+            @change="submitTable"
+          >
             <el-radio :label="1">已开通课程的学员</el-radio>
             <el-radio :label="2">所有学员</el-radio>
           </el-radio-group>
         </el-form-item>
-        <el-form-item label="观看链接(PC端):">
+        <el-form-item label="观看链接:">
           <span id="copycode">{{ formLabelAlign.enCodePC }}</span
           ><el-button
             v-if="formLabelAlign.enCodePC"
@@ -34,7 +37,7 @@
             >复制</el-button
           >
         </el-form-item>
-        <el-form-item label="观看二维码:">
+        <el-form-item label="观看二维码:" v-if="false">
           <img
             style="width: 100px; height: 100px"
             :src="formLabelAlign.enCode"
@@ -74,7 +77,7 @@ export default {
      * 复制地址
      */
     copyUrl() {
-      const range = document.createRange();//创建range对象;
+      const range = document.createRange(); //创建range对象;
       range.selectNode(document.getElementById("copycode")); //获取复制内容的 id 选择器
       const selection = window.getSelection(); //创建 selection对象
       if (selection.rangeCount > 0) selection.removeAllRanges(); //如果页面已经有选取了的话,会自动删除这个选区,没有选区的话,会把这个选取加入选区
@@ -122,6 +125,9 @@ export default {
       this.keyIdArray = rows.keyId.split("-").map(Number);
       this.goodsId = goodsId;
       this.sectionType = rows.sectionType;
+      this.getWatchper();
+    },
+    getWatchper() {
       this.$api
         .coursesectionwatchper({
           goodsId: this.goodsId,
@@ -171,11 +177,11 @@ export default {
       }
       this.$api.coursesectionaddwatchper(data).then((res) => {
         this.$message.success("保存成功");
+        this.getWatchper();
       });
     },
   },
 };
 </script>
 
-<style lang="less" scoped>
-</style>
+<style lang="less" scoped></style>

+ 312 - 0
src/views/Marketing/goods/commodityManageMent/edit/handoutContent/handoutsCheck.vue

@@ -0,0 +1,312 @@
+<template>
+  <div id="">
+    <!-- 关联讲义列表 -->
+    <el-dialog
+      :visible.sync="jYactiveBoxs"
+      width="1080px"
+      append-to-body
+      :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="jYactiveBoxs = false"
+          />
+        </div>
+      </div>
+      <div style="margin-bottom: 10px">
+        <!-- 搜索框 -->
+        <el-input
+          style="width: 230px; margin-right: 10px"
+          :size="size"
+          v-model="formData['key']"
+          placeholder="请输入讲义标题/讲义编码"
+        ></el-input>
+        <el-button :size="size" type="primary" @click="getJyData(1)"
+          >查询</el-button
+        >
+        <el-button :size="size" @click="getJyData(0)">重置</el-button>
+      </div>
+      <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
+              :label="scope.row.handoutsId"
+              v-model="handoutsId"
+              @change.native="getTemplateRow(scope.$index, scope.row)"
+              >{{ "" }}</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>
+              <ul v-else-if="item.scope === 'eduType'" class="ulAuto">
+                <template v-for="(itm, inds) in scope.row[item.prop]">
+                  <li :key="inds" v-if="inds === 0">
+                    {{
+                      itm.educationName +
+                      "-" +
+                      itm.projectName +
+                      "-" +
+                      itm.businessName
+                    }}
+                  </li>
+                </template>
+                <el-popover
+                  :key="Math.random()"
+                  placement="right"
+                  trigger="click"
+                >
+                  <ul>
+                    <li v-for="(itm, inds) in scope.row[item.prop]" :key="inds">
+                      {{ inds + 1 }}、
+                      {{
+                        itm.educationName +
+                        "-" +
+                        itm.projectName +
+                        "-" +
+                        itm.businessName
+                      }}
+                    </li>
+                  </ul>
+                  <el-button
+                    slot="reference"
+                    style="margin-left: 6px"
+                    type="text"
+                    v-if="scope.row[item.prop].length > 1"
+                    size="mini"
+                    >更多</el-button
+                  >
+                </el-popover>
+              </ul>
+              <span v-else-if="item.scope === 'canDownload'">{{
+                scope.row[item.prop] === 1 ? "是" : "否"
+              }}</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"
+      />
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="jYactiveBoxs = false">取 消</el-button>
+        <el-button type="primary" @click="submitBox">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import pagination from "@/components/pagination";
+export default {
+  components: { pagination },
+  data() {
+    return {
+      size: "small",
+      total: 0,
+      tableSet: [
+        { label: "讲义编码", prop: "encoder", width: "150px" },
+        { label: "讲义标题", prop: "handoutsName" },
+        {
+          label: "是否可下载",
+          prop: "canDownload",
+          scope: "canDownload",
+          width: "140px",
+        },
+        { label: "发布状态", prop: "status", scope: "Status", width: "140px" },
+      ],
+      tableData: [],
+      formData: {},
+      handoutsId: "",
+      handoutsName: "",
+      handoutsCode: "",
+      jYactiveBoxs: false,
+    };
+  },
+  methods: {
+    openBox(id) {
+      this.getJyData(0);
+      this.handoutsId = id || "";
+      this.jYactiveBoxs = true;
+    },
+    /**
+     * 临时选中
+     */
+    getTemplateRow(index, row) {
+      this.handoutsId = row.handoutsId;
+      this.handoutsName = row.handoutsName;
+      this.handoutsCode = row.encoder;
+    },
+    /**
+     * 确定选中
+     */
+    submitBox() {
+      this.jYactiveBoxs = false;
+      this.$emit("backData", {
+        handoutsId: this.handoutsId,
+        handoutsName: this.handoutsName,
+        handoutsCode: this.handoutsCode,
+      });
+    },
+    /**
+     * 搜索
+     */
+    getJyData(int) {
+      if (int === 0) {
+        this.formData = {
+          businessId: this.$parent.listData.businessId,
+          status: 1,
+          pageSize: 10,
+          pageNum: 1,
+          key: "",
+        };
+      }
+      if (int === 1) {
+        this.formData.pageNum = 1;
+      }
+      this.$api.inquireCourseHandoutsList(this.formData).then((res) => {
+        this.total = res.total;
+        this.tableData = res.rows;
+      });
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.getJyData();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.getJyData();
+    },
+  },
+};
+</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;
+    }
+  }
+}
+.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>

+ 51 - 0
src/views/Marketing/goods/commodityManageMent/edit/handoutContent/index.vue

@@ -0,0 +1,51 @@
+<template>
+  <div id="handoutContent">
+    <el-form-item label="关联讲义" prop="handoutsId">
+      <div>
+        <el-button @click="goToActivehandouts">选择讲义</el-button>
+        <span v-if="listData.handoutsId" style="margin-left: 12px"
+          >{{ listData.handoutsCode }} - {{ listData.handoutsName }}</span
+        >
+        <el-button
+          style="margin-left: 12px"
+          v-if="listData.handoutsId"
+          type="text"
+          @click="clearGoods"
+          >删除</el-button
+        >
+      </div>
+    </el-form-item>
+    <handouts-check ref="handoutsCheck" @backData="backData" />
+  </div>
+</template>
+
+<script>
+import handoutsCheck from "./handoutsCheck.vue";
+export default {
+  components: { handoutsCheck },
+  props: ["listData"],
+  data() {
+    return {};
+  },
+  methods: {
+    goToActivehandouts() {
+      //打开讲义资料组件
+      this.$refs.handoutsCheck.openBox(this.listData.handoutsId);
+    },
+    backData(activeObj) {
+      this.$set(this.listData, "handoutsId", activeObj.handoutsId);
+      this.$set(this.listData, "handoutsName", activeObj.handoutsName);
+      this.$set(this.listData, "handoutsCode", activeObj.handoutsCode);
+      this.$bus.$emit("validateHandoutsId");
+    },
+    clearGoods() {
+      this.$set(this.listData, "handoutsId", "");
+      this.$set(this.listData, "handoutsName", "");
+      this.$set(this.listData, "handoutsCode", "");
+      this.$bus.$emit("validateHandoutsId");
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 58 - 2
src/views/Marketing/goods/commodityManageMent/edit/index.vue

@@ -52,6 +52,10 @@
           </h5>
           <make-up-exam ref="makeUpExam" :listData="listData" />
         </div>
+        <div v-if="listData.goodsType === 8 && listData.businessId">
+          <h5 class="segmentationStyle">关联讲义资料</h5>
+          <handout-content ref="handoutContent" :listData="listData" />
+        </div>
         <!-- 学习次数及服务时间 -->
         <configure-content-parameters
           v-if="listData.businessId && listData.goodsType"
@@ -111,6 +115,7 @@ import pricePeriod from "./pricePeriod.vue";
 import courseContent from "./courseContent/index.vue";
 import bankContent from "./bankContent/index.vue";
 import makeUpExam from "./makeUpExam/index.vue";
+import handoutContent from "./handoutContent/index.vue";
 import configureContentParameters from "./configureContentParameters.vue";
 import issueAcertificate from "./issueAcertificate.vue";
 import introduction from "./introduction.vue";
@@ -125,6 +130,7 @@ export default {
     issueAcertificate,
     introduction,
     makeUpExam,
+    handoutContent,
   },
   data() {
     var validatorClassHours = (rule, value, callback) => {
@@ -237,7 +243,7 @@ export default {
         coverUrl: "oss/images/avatar/20211013/1634097664410_1397766697",
         goodsType: "",
         certificateTypeId: "",
-        commitPeriodStatus:0
+        commitPeriodStatus: 0,
       },
       rules: {
         year: [
@@ -263,6 +269,14 @@ export default {
             trigger: "change",
           },
         ],
+        gradeType: [
+          {
+            type: "number",
+            required: true,
+            message: "请选择班级类型",
+            trigger: "change",
+          },
+        ],
         goodsName: [
           {
             required: true,
@@ -388,6 +402,13 @@ export default {
             trigger: "blur",
           },
         ],
+        handoutsId: [
+          {
+            required: true,
+            message: "请选择关联讲义资料",
+            trigger: "blur",
+          },
+        ],
         examNumber: [
           {
             type: "number",
@@ -530,6 +551,13 @@ export default {
         }
       });
     });
+    this.$bus.$on("validateHandoutsId", () => {
+      this.$nextTick(() => {
+        if (this.$refs["listData"]) {
+          this.$refs["listData"].validateField("handoutsId");
+        }
+      });
+    });
     this.$bus.$on("validateCoverUrl", () => {
       this.$nextTick(() => {
         if (this.$refs["listData"]) {
@@ -679,7 +707,7 @@ export default {
      * 商品详细数据
      */
     search() {
-      this.$api.obtainGoods(this.goodsId).then((res) => {
+      this.$api.obtainGoods(this.goodsId).then(async (res) => {
         var auditionList;
         var examConfigList;
         this.activeExternalLinkStatus(res.data.externalLinkStatus);
@@ -789,6 +817,14 @@ export default {
             );
           }
         }
+        //讲义资料商品查询讲义Code及名称
+        if (res.data.goodsType == 8 && res.data.handoutsId) {
+          const result = await this.$api.inquireCourseHandoutsfiledetail({
+            handoutsId: res.data.handoutsId,
+          });
+          res.data.handoutsName = result.data.handoutsName;
+          res.data.handoutsCode = result.data.encoder;
+        }
         this.listData = res.data;
         //课程内容转换
         if (res.data.goodsType === 1 || res.data.goodsType === 6) {
@@ -945,6 +981,25 @@ export default {
             this.disabledBtn = false;
           });
       }
+      if (this.listData.goodsType === 8) {
+        this.$api
+          .editGoodshandouts(data)
+          .then((res) => {
+            this.$message.success("修改成功");
+            setTimeout(() => {
+              this.$store
+                .dispatch("tagsView/exitView", this.$route)
+                .then((res) => {
+                  this.$router.push({
+                    path: "commodityManageMent",
+                  });
+                });
+            }, 300);
+          })
+          .catch(() => {
+            this.disabledBtn = false;
+          });
+      }
     },
     /**
      * 视频商品参数转换
@@ -1112,6 +1167,7 @@ export default {
     console.log(2);
     this.$bus.$off("clearValidateFuncAdd");
     this.$bus.$off("validateMakeId");
+    this.$bus.$off("validateHandoutsId");
     this.$bus.$off("validateCoverUrl");
     this.$bus.$off("initTimeVal");
     this.$bus.$off("againValidate");

+ 57 - 9
src/views/Marketing/goods/commodityManageMent/edit/productInformation.vue

@@ -75,7 +75,27 @@
             </el-option>
           </el-select>
         </el-form-item>
-        <el-form-item label="院校" prop="schoolId" v-if="listData.businessId" :key="14">
+        <el-form-item
+          label="班级类型"
+          prop="gradeType"
+          v-if="listData.goodsType === 1"
+        >
+          <el-select v-model="listData.gradeType" placeholder="请选择班级类型">
+            <el-option
+              v-for="(item, index) in gradeType"
+              :key="index"
+              :label="item.label"
+              :value="item.value"
+            >
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item
+          label="院校"
+          prop="schoolId"
+          v-if="listData.businessId"
+          :key="14"
+        >
           <el-select v-model="listData.schoolId" placeholder="请选择院校">
             <el-option
               v-for="(item, index) in newSchoolOption"
@@ -86,7 +106,12 @@
             </el-option>
           </el-select>
         </el-form-item>
-        <el-form-item label="专业" prop="majorId" v-if="listData.businessId" :key="15">
+        <el-form-item
+          label="专业"
+          prop="majorId"
+          v-if="listData.businessId"
+          :key="15"
+        >
           <el-select v-model="listData.majorId" placeholder="请选择专业">
             <el-option
               v-for="(item, index) in newMajorOption"
@@ -120,9 +145,12 @@
             v-model="listData.goodsName"
           ></el-input>
         </el-form-item>
-        
+
         <el-form-item label="是否外链商品" prop="externalLinkStatus">
-          <el-radio-group v-model="listData.externalLinkStatus" @change="activeExternalLinkStatus">
+          <el-radio-group
+            v-model="listData.externalLinkStatus"
+            @change="activeExternalLinkStatus"
+          >
             <el-radio :label="1">是</el-radio>
             <el-radio :label="0">否</el-radio>
           </el-radio-group>
@@ -139,7 +167,7 @@
           label="学时"
           prop="classHours"
         >
-         <el-input-number
+          <el-input-number
             :controls="false"
             :style="`max-width: ${inputWidth}px`"
             v-model="listData.classHours"
@@ -195,6 +223,20 @@ export default {
   props: ["listData", "submitStatusInfo"],
   data() {
     return {
+      gradeType: [
+        {
+          label: "基础班",
+          value: 1,
+        },
+        {
+          label: "强化班",
+          value: 2,
+        },
+        {
+          label: "私塾班",
+          value: 3,
+        },
+      ],
       goodsTypeOptions: [
         {
           label: "视频",
@@ -216,6 +258,10 @@ export default {
           label: "直播",
           value: 6,
         },
+        {
+          label: "讲义资料",
+          value: 8,
+        },
       ], //商品类型
       newCourTypeOptions: [], //业务层次
       newSchoolOption: [], //院校
@@ -246,7 +292,7 @@ export default {
       if (val) {
         // this.$bus.$emit("clearValidateFunc");
         this.getInitBabelList(val);
-         if (this.listData.goodsType === 1) {
+        if (this.listData.goodsType === 1) {
           this.$bus.$emit("getCheckRequired", val);
         } else {
           this.$bus.$emit("getCheckQuitRequired", val);
@@ -258,7 +304,8 @@ export default {
   methods: {
     //校验外链格式
     judgeUrl() {
-      var regUrl = /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/)(([A-Za-z0-9-~]+)\.)+([A-Za-z0-9-~\/])+$/;
+      var regUrl =
+        /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/)(([A-Za-z0-9-~]+)\.)+([A-Za-z0-9-~\/])+$/;
       let flag = new RegExp(regUrl).test(val);
       if (!flag) {
         this.$message({
@@ -271,8 +318,8 @@ export default {
       }
       return 1;
     },
-    activeExternalLinkStatus(e){
-      this.$emit('activeExternalLinkStatus',e)
+    activeExternalLinkStatus(e) {
+      this.$emit("activeExternalLinkStatus", e);
     },
     /**
      *科目切换清楚列表
@@ -285,6 +332,7 @@ export default {
      * 商品类型切换
      */
     changeTypes(val) {
+      // this.$set(this.listData, "gradeType", ""); //班级类型
       // this.$set(this.listData, "examNumber", 0); //考试次数
       // this.$set(this.listData, "doNumber", 0); //刷题次数
       // this.$set(this.listData, "studyCount", 1); //学习次数

+ 2 - 2
src/views/Marketing/goods/goodTopic/index.vue

@@ -43,7 +43,7 @@
         </div>
       </div>
       <el-form label-width="180px" :model="formLabelAlign">
-        <el-form-item label="观看链接(PC端):">
+        <el-form-item label="观看链接:">
           <span id="copycode">{{ formLabelAlign.enCodePC }}</span
           ><el-button
             v-if="formLabelAlign.enCodePC"
@@ -53,7 +53,7 @@
             >复制</el-button
           >
         </el-form-item>
-        <el-form-item label="观看二维码:">
+        <el-form-item label="观看二维码:" v-if="false">
           <img
             style="width: 100px; height: 100px"
             :src="formLabelAlign.enCode"

+ 48 - 3
src/views/Marketing/order/offlineOrder/goodsMatch/goodsMatchToBusin.vue

@@ -66,6 +66,9 @@
                     : ""
                 }}
               </span>
+              <span v-else-if="item.scope === 'select'">
+                {{ computerNames(scope.row[item.prop]) }}
+              </span>
               <span v-else>{{ scope.row[item.prop] }}</span>
             </template>
           </el-table-column>
@@ -127,6 +130,20 @@
               placeholder="请输入配置标题"
             ></el-input>
           </el-form-item>
+          <el-form-item label="班级类型" prop="gradeType">
+            <el-select
+              v-model="listData.gradeType"
+              placeholder="请选择班级类型"
+            >
+              <el-option
+                v-for="(item, index) in gradeType"
+                :key="index"
+                :label="item.label"
+                :value="item.value"
+              >
+              </el-option>
+            </el-select>
+          </el-form-item>
           <el-form-item label="状态" prop="status">
             <el-radio-group v-model="listData.status">
               <el-radio :label="1">启用</el-radio>
@@ -156,6 +173,20 @@ export default {
   components: { pagination },
   data() {
     return {
+      gradeType: [
+        {
+          label: "基础班",
+          value: 1,
+        },
+        {
+          label: "强化班",
+          value: 2,
+        },
+        {
+          label: "私塾班",
+          value: 3,
+        },
+      ],
       disabledBtn: false,
       size: "small",
       educationId: "", //教育类型ID
@@ -169,6 +200,11 @@ export default {
           label: "配置标题",
           prop: "configName",
         },
+        {
+          label: "班级类型",
+          prop: "gradeType",
+          scope: "select",
+        },
         {
           label: "状态",
           prop: "status",
@@ -185,6 +221,9 @@ export default {
           { required: true, message: "请输入配置标题", trigger: "blur" },
         ],
         status: [{ required: true, message: "请选择状态", trigger: "change" }],
+        gradeType: [
+          { required: true, message: "请选择班级类型", trigger: "change" },
+        ],
       },
       tabSearchData: {
         pageNum: 1,
@@ -218,6 +257,12 @@ export default {
   },
   computed: {
     ...mapGetters(["educationType"]),
+    computerNames: function () {
+      return function (int) {
+        let a = this.gradeType.find((i) => i.value == int);
+        return a.label;
+      };
+    },
   },
   mounted() {
     if (this.educationType && this.educationType.length) {
@@ -273,9 +318,9 @@ export default {
         this.listData.businessId = this.active;
       }
       this.dialogVisible = true;
-      this.$nextTick(()=>{
-          this.$refs.listData.clearValidate()
-      })
+      this.$nextTick(() => {
+        this.$refs.listData.clearValidate();
+      });
     },
     loadingClose() {
       this.disabledBtn = false;

+ 1 - 5
src/views/Marketing/order/orderList/details/costPriceManages.vue

@@ -238,11 +238,7 @@ export default {
       });
     },
     getCostInfos(v) {
-      this.orderList.map((item) => {
-        if (item.sheetSn === v) {
-          this.costList = item;
-        }
-      });
+      this.costList = this.orderList.find((item) => item.sheetSn === v);
       this.$api.obtainOrdersheetSn(v).then((res) => {
         this.listData = res.data;
       });

+ 4 - 0
src/views/Marketing/order/orderList/details/goodsManage.vue

@@ -260,6 +260,10 @@ export default {
           label: "直播",
           value: 6,
         },
+        {
+          label: "讲义资料",
+          value: 8,
+        },
       ],
       payType: [
         {

+ 14 - 0
src/views/YjConsult/Q&A/index.vue

@@ -0,0 +1,14 @@
+<template>
+  <div id="">常见问题</div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {};
+  },
+  methods: {},
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 82 - 0
src/views/YjConsult/newsMessage/dialogMessage.vue

@@ -0,0 +1,82 @@
+<template>
+  <div class="dialogInstan">
+    <BaseDialog
+      width="900px"
+      :isShow.sync="isShow"
+      :title="info.id ? '编辑' : '新增'"
+      @close="close"
+      @submit="submit"
+    >
+      <el-form
+        :model="formData"
+        :rules="rules"
+        ref="formData"
+        label-width="100px"
+        class="demo-ruleForm"
+      >
+        <el-form-item label="新闻标题" prop="name">
+          <el-input v-model="formData.name"></el-input> </el-form-item
+        ><el-form-item label="新闻内容" prop="name">
+          <el-input v-model="formData.name"></el-input> </el-form-item
+        ><el-form-item label="发布时间" prop="name">
+          <el-date-picker
+            v-model="formData.value1"
+            type="datetime"
+            placeholder="选择日期时间"
+            value-format="timestamp"
+          >
+          </el-date-picker> </el-form-item
+        ><el-form-item label="问题类型" prop="name">
+          <el-input v-model="formData.name"></el-input> </el-form-item
+        ><el-form-item label="上传附件" prop="name">
+          <el-input v-model="formData.name"></el-input> </el-form-item
+      ></el-form>
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+export default {
+  props: {
+    dialogVisible: {
+      type: Boolean,
+      default: false,
+    },
+    info: {
+      type: Object,
+      default: () => {
+        return {};
+      },
+    },
+  },
+  data() {
+    return {
+      formData: {},
+    };
+  },
+
+  mounted() {},
+
+  methods: {
+    init() {},
+
+    close() {},
+    submit() {},
+  },
+  computed: {
+    isShow: {
+      get() {
+        if (this.dialogVisible) {
+          this.init();
+        }
+        return this.dialogVisible;
+      },
+      set(val) {
+        this.$emit("update:dialogVisible", false);
+      },
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 217 - 0
src/views/YjConsult/newsMessage/index.vue

@@ -0,0 +1,217 @@
+<template>
+  <div id="instantDeath">
+    <search-box-new
+      ref="searchBox"
+      :formData="formData"
+      :formList="formList"
+      @search="search"
+      @init="init"
+    />
+    <table-list
+      rowKey="id"
+      ref="tableList"
+      :tableSets="tableSet"
+      :tableData="tableData"
+      :navText="navText"
+      :loading="loading"
+      @addClick="addClick"
+    >
+      <template slot="btn" slot-scope="props">
+        <el-button type="text">编辑</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"
+    />
+    <dialog-message :dialogVisible.sync="dialogVisible" />
+  </div>
+</template>
+
+<script>
+import searchBoxNew from "@/components/searchBoxNew";
+import tableList from "@/components/tableList";
+import pagination from "@/components/pagination";
+import dialogMessage from "./dialogMessage.vue";
+export default {
+  // name: "InstantDeath",
+  components: {
+    searchBoxNew,
+    tableList,
+    pagination,
+    dialogMessage,
+  },
+  data() {
+    return {
+      info: {},
+      loading: false, //当前表单加载是否加载动画
+      navText: {
+        title: "新闻资讯",
+        index: 0,
+        ch: "条",
+        num: true,
+        choice: true,
+        addHide: false,
+        openCheckMore: true,
+        changeWidth: "160px",
+        backFatherBtn: {
+          status: false,
+          title: "",
+        },
+      },
+      //搜索
+      formList: [
+        {
+          lable: "新闻标题",
+          prop: "name",
+          placeholder: "请输入新闻标题",
+        },
+        {
+          prop1: "validityStartTime",
+          prop2: "validityEndTime",
+          placeholder1: "发布开始时间",
+          placeholder2: "发布结束时间",
+          scope: "moreDataPicker",
+        },
+        {
+          lable: "新闻类型",
+          prop: "status",
+          placeholder: "请选择新闻类型",
+          scope: "select",
+          options: [
+            { label: "行业资讯", value: 1 },
+            { label: "政策法规", value: 2 },
+            { label: "文件通知", value: 3 },
+          ],
+        },
+        {
+          lable: "显示状态",
+          prop: "status1",
+          placeholder: "请选择显示状态",
+          scope: "select",
+          options: [
+            { label: "启动", value: 1 },
+            { label: "暂停", value: 0 },
+          ],
+        },
+      ],
+      formData: {
+        pageSize: 10,
+        pageNum: 1,
+      },
+      // 表单
+      tableSet: [
+        {
+          label: "新闻类型",
+          prop: "name",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            { label: "行业资讯", value: 1 },
+            { label: "政策法规", value: 2 },
+            { label: "文件通知", value: 3 },
+          ],
+        },
+        {
+          label: "新闻标题",
+          prop: "name",
+          hidden: true,
+        },
+        {
+          label: "发布时间",
+          prop: "createTime",
+          hidden: true,
+          scope: "aTimeList",
+          width: "180px",
+        },
+        {
+          label: "显示状态",
+          prop: "status",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "关闭",
+              value: 0,
+            },
+            {
+              label: "显示",
+              value: 1,
+            },
+          ],
+        },
+      ],
+      tableData: [], //表单数据
+      total: 0, //一共多少条
+      dialogVisible: false,
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    addClick() {
+      this.dialogVisible = true;
+    },
+    editClick() {},
+    del(item) {
+      this.$confirm("是否删除该数据?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          this.$message({
+            type: "success",
+            message: "删除成功!",
+          });
+        })
+        .catch(() => {});
+    },
+    search(v) {
+      this.loading = true;
+      if (v === 2) {
+        this.formData = {
+          pageSize: 10,
+          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
+        .distributiontemplist(data)
+        .then((res) => {
+          this.tableData = res.rows;
+          this.total = res.total;
+          this.navText.index = res.total;
+        })
+        .finally(() => {
+          this.loading = false;
+        });
+    },
+    init() {
+      this.search(2);
+    },
+    handleSizeChange(v) {
+      this.formData.pageSize = v;
+      this.formData.pageNum = 1;
+      this.search();
+    },
+    handleCurrentChange(v) {
+      this.formData.pageNum = v;
+      this.search();
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 2 - 2
src/views/education/classManageMent/learningHoursRecordListMonth/index.vue

@@ -274,8 +274,8 @@ export default {
           label: "学习学时",
           prop: "studyTime",
           hidden: true,
-          scope: "solt",
-          soltName: "studyTime",
+          scope: "slot",
+          slotName: "studyTime",
         },
         {
           label: "所在班级",

+ 133 - 4
src/views/education/examManagement/applicationData/asPlanned.vue

@@ -6,7 +6,56 @@
       :formList="formList"
       @search="search"
       @init="init"
-    />
+    >
+      <template slot="month">
+        <el-select
+          size="small"
+          v-model="month"
+          placeholder="月份"
+          @change="getCanActiveApplyMonth"
+        >
+          <el-option
+            v-for="item in monthList"
+            :key="item.value"
+            :label="item.label"
+            :value="item.value"
+          >
+          </el-option>
+        </el-select>
+        <el-select
+          style="margin-left: 10px"
+          size="small"
+          v-model="day"
+          v-if="month"
+          placeholder="日期"
+          @change="getCanActiveApply"
+        >
+          <el-option
+            v-for="item in dayList"
+            :key="item.value"
+            :label="item.label"
+            :value="item.value"
+          >
+          </el-option>
+        </el-select>
+
+        <el-select
+          style="margin-left: 10px"
+          v-if="month || day"
+          size="small"
+          v-model="monthApplyIndex"
+          placeholder="考试场次"
+        >
+          <el-option
+            v-for="(item, index) in monthApplyList"
+            :key="index"
+            :label="item.examSession"
+            :value="index"
+          >
+          </el-option>
+        </el-select>
+      </template>
+    </search-box-new>
     <table-list
       :tableSets="tableSet"
       :tableData="tableData"
@@ -347,6 +396,25 @@ export default {
   components: { searchBoxNew, tableList, pagination },
   data() {
     return {
+      month: "",
+      monthList: [
+        { label: "一月", value: "01" },
+        { label: "二月", value: "02" },
+        { label: "三月", value: "03" },
+        { label: "四月", value: "04" },
+        { label: "五月", value: "05" },
+        { label: "六月", value: "06" },
+        { label: "七月", value: "07" },
+        { label: "八月", value: "08" },
+        { label: "九月", value: "09" },
+        { label: "十月", value: "10" },
+        { label: "十一月", value: "11" },
+        { label: "十二月", value: "12" },
+      ],
+      day: "",
+      dayList: [],
+      monthApplyIndex: "",
+      monthApplyList: [],
       size: "small",
       plan: "",
       loading: false, //当前表单加载是否加载动画
@@ -426,6 +494,12 @@ export default {
           prop: "realname",
           placeholder: "请输入用户名",
         },
+        {
+          prop: "month",
+          placeholder: "月份",
+          scope: "slot",
+          slotName: "month",
+        },
       ],
       formData: {
         pageSize: 10,
@@ -645,7 +719,7 @@ export default {
     }
     if (this.$route.params.type == 3) {
       this.formData.applyId = Number(this.$route.params.id);
-      this.formData.syncStatus = 2
+      this.formData.syncStatus = 2;
     }
     this.search();
     this.getQP();
@@ -655,6 +729,43 @@ export default {
     this.getQP();
   },
   methods: {
+    getMonthDays(target) {
+      let date = new Date(target + "-01"); // 移动端使用格式要转成: "2018/10/01"
+      date.setMonth(date.getMonth() + 1); // 先设置为下个月
+      date.setDate(0); // 再置0,变成当前月最后一天
+      return date.getDate(); // 当前月最后一天即当前月拥有的天数
+    },
+    getCanActiveApplyMonth() {
+      this.day = "";
+      var year = new Date().getFullYear();
+      var num = this.getMonthDays(year + "-" + this.month);
+      var list = [];
+      for (let i = 0; i < num; i++) {
+        list.push({
+          label: i + 1 + "号",
+          value: i < 10 ? "0" + (i + 1) : i + 1,
+        });
+      }
+      this.dayList = list || [];
+      var a = year + this.month + this.day;
+      this.getSearchApply(a);
+    },
+    getCanActiveApply() {
+      var year = new Date().getFullYear();
+      var a = year + "" + this.month + "" + this.day;
+      this.getSearchApply(a);
+    },
+    getSearchApply(i) {
+      this.monthApplyIndex = "";
+      this.$api
+        .obtainsystemsubscribesessiondata(i)
+        .then((res) => {
+          this.monthApplyList = res.data;
+        })
+        .catch(() => {
+          this.monthApplyList = [];
+        });
+    },
     getDowm() {
       let url =
         baseUrls.BASE_IMG_URL +
@@ -1003,8 +1114,25 @@ export default {
           pageNum: 1,
         };
       }
+      var data = JSON.parse(JSON.stringify(this.formData));
+      if (this.month) {
+        var year = new Date().getFullYear();
+        var a = year + "" + this.month;
+        if (this.day) {
+          a = year + "" + this.month + "" + this.day;
+        }
+        data.ApplyDateTime = a;
+      }
+      if (this.monthApplyIndex) {
+        data.applySiteExamTime =
+          this.monthApplyList[this.monthApplyIndex].examTime;
+        data.applySiteStartTime =
+          this.monthApplyList[this.monthApplyIndex].examStartTime;
+        data.applySiteEndTime =
+          this.monthApplyList[this.monthApplyIndex].examEndTime;
+      }
       this.$api
-        .inquiresystemsubscribelist(this.formData)
+        .inquiresystemsubscribelist(data)
         .then((res) => {
           this.$refs.tableList.allCheckData = [];
           this.tableData = res.rows;
@@ -1016,6 +1144,8 @@ export default {
         });
     },
     init() {
+      this.month = "";
+      this.monthApplyIndex = "";
       this.search(2);
     },
     del(v) {
@@ -1209,4 +1339,3 @@ export default {
   cursor: pointer;
 }
 </style>
-

+ 83 - 0
src/views/education/examManagement/listOfTestRooms/applyBeforeKnow.vue

@@ -0,0 +1,83 @@
+<template>
+  <div>
+    <BaseDialog
+      width="900px"
+      :isShow.sync="emailDialog"
+      title="考前须知"
+      @close="close"
+      @submit="submitForm"
+      :appendToBody="true"
+      :confirmStatus="false"
+    >
+      <el-form
+        :model="ruleForm"
+        :rules="rules"
+        ref="ruleForm"
+        label-width="140px"
+        class="demo-ruleForm"
+        ><el-form-item label="提示内容:" prop="value">
+          <editor
+            v-model="ruleForm.value"
+            :min-height="300"
+            :max-height="500"
+            :uploadStatus="2"
+          /> </el-form-item
+        ><el-form-item label="是否提示" prop="type">
+          <el-radio-group v-model="ruleForm.type">
+            <el-radio label="Y">开启</el-radio>
+            <el-radio label="N">关闭</el-radio>
+          </el-radio-group>
+        </el-form-item></el-form
+      >
+    </BaseDialog>
+  </div>
+</template>
+
+<script>
+import Editor from "@/components/Editor";
+export default {
+  components: { Editor },
+  data() {
+    return {
+      rules: {
+        value: [{ required: true, message: "请输入邮件内容", trigger: "blur" }],
+        type: [
+          { required: true, message: "请选择是否提示", trigger: "change" },
+        ],
+      },
+      ruleForm: {},
+      emailDialog: false,
+    };
+  },
+
+  mounted() {},
+
+  methods: {
+    openBoxs() {
+      this.$api.examapplybeforeknow().then((res) => {
+        this.ruleForm = res.data;
+        this.emailDialog = true;
+        this.$nextTick(() => {
+          this.$refs["ruleForm"].clearValidate();
+        });
+      });
+    },
+    close() {},
+    submitForm() {
+      this.$refs["ruleForm"].validate((valid) => {
+        if (valid) {
+          this.$api.systemapplysaveorupbeforeknow(this.ruleForm).then((res) => {
+            this.$message.success("操作成功");
+            this.emailDialog = false;
+          });
+        } else {
+          console.log("error submit!!");
+          return false;
+        }
+      });
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped></style>

+ 13 - 2
src/views/education/examManagement/listOfTestRooms/index.vue

@@ -20,6 +20,11 @@
       :navText="navText"
       :loading="loading"
     >
+      <template slot="customize">
+        <el-button type="warning" @click="applyBeforeKnow"
+          >考前须知</el-button
+        >
+      </template>
       <template slot="num" slot-scope="props">
         <div>
           <span style="color: rgb(78, 175, 255)">{{
@@ -37,10 +42,12 @@
       @handleCurrentChange="handleCurrentChange"
     />
     <sendEmail ref="sendEmail" />
+    <applyBeforeKnow ref="applyBeforeKnow" />
   </div>
 </template>
 
 <script>
+import applyBeforeKnow from "./applyBeforeKnow.vue"
 import sendEmail from "./sendEmail.vue";
 import searchBoxNew from "@/components/searchBoxNew";
 import tableList from "@/components/tableList";
@@ -52,6 +59,7 @@ export default {
     tableList,
     pagination,
     sendEmail,
+    applyBeforeKnow
   },
   data() {
     return {
@@ -118,8 +126,8 @@ export default {
         {
           label: "已报考人数/可报考人数",
           hidden: true,
-          soltName: "num",
-          scope: "solt",
+          slotName: "num",
+          scope: "slot",
         },
         {
           label: "考试性质",
@@ -185,6 +193,9 @@ export default {
     this.search();
   },
   methods: {
+    applyBeforeKnow(){
+      this.$refs.applyBeforeKnow.openBoxs()
+    },
     moreActive() {
       if (this.$refs.tableList.allCheckData.length === 0) {
         this.$message.error("请勾选数据");

+ 3 - 3
src/views/monitor/cache/index.vue

@@ -68,7 +68,7 @@
 
 <script>
 import { getCache } from "@/api/monitor/cache";
-import echarts from "echarts";
+// import echarts from "echarts";
 
 export default {
   name: "Server",
@@ -83,8 +83,8 @@ export default {
     };
   },
   created() {
-    this.getList();
-    this.openLoading();
+    // this.getList();
+    // this.openLoading();
   },
   methods: {
     /** 查缓存询信息 */

+ 15 - 4
src/views/resource/bankManagement/testPaperManagement/BatchImportPop.vue

@@ -18,7 +18,7 @@
     @success="ExcelSuccess"
   ></batch-import-dialoga>
   <batch-import-dialoga
-  v-else-if="type == 4"
+    v-else-if="type == 4"
     :dialogVisible.sync="dialogVisible"
     temUrl="/oss/images/file/20220324/1648102107588.docx"
     apiKey="bankquestionimportJJWordQuestionList"
@@ -29,6 +29,18 @@
     type="Word"
     :param="formData"
   ></batch-import-dialoga>
+  <batch-import-dialoga
+    v-else-if="type == 5"
+    :dialogVisible.sync="dialogVisible"
+    temUrl="/oss/images/file/20230705/1688551198807.docx"
+    apiKey="bankquestionimportXueJianWordQuestionList"
+    :isCheck="false"
+    :isShowTip="false"
+    :isSuccessBack="true"
+    @success="wordSuccess"
+    type="Word"
+    :param="formData"
+  ></batch-import-dialoga>
   <batch-import-dialoga
     v-else
     :dialogVisible.sync="dialogVisible"
@@ -58,7 +70,7 @@ export default {
         subjectId: "",
         projectId: "",
       },
-      type: 1, //1是execl 2 word 4建匠题目Word
+      type: 1, //1是execl 2 word 4建匠题目Word 5学监题目Word
     };
   },
   methods: {
@@ -106,7 +118,7 @@ export default {
       this.$emit("backData", list);
     },
     ExcelSuccess(data) {
-      console.log(data,"data")
+      console.log(data, "data");
       if (data.fullStatus == "全部成功") {
         this.backDataX(data.questionList);
         this.$message.success("全部导入成功");
@@ -181,4 +193,3 @@ export default {
   },
 };
 </script>
-

+ 5 - 0
src/views/resource/bankManagement/testPaperManagement/addPaper/topicAddPaper/index.vue

@@ -26,6 +26,11 @@
             @click="$refs.batchPop.openBoxs(tableData, businObj, 3)"
             type="success"
             >(旧系统)Excel批量导入</el-button
+          ><el-button
+            size="medium"
+            @click="$refs.batchPop.openBoxs(tableData, businObj, 5)"
+            type="success"
+            >学监题目Word批量导入</el-button
           ><el-button
             size="medium"
             @click="$refs.batchPop.openBoxs(tableData, businObj, 4)"

+ 6 - 0
src/views/resource/bankManagement/testPaperManagement/editPaper/topicEditPaper/index.vue

@@ -22,6 +22,12 @@
             type="success"
             :disabled="!noStudent"
             >(旧系统)Excel批量导入</el-button
+          ><el-button
+            size="medium"
+            @click="$refs.batchPop.openBoxs(tableData, businObj, 5)"
+            type="success"
+            :disabled="!noStudent"
+            >学监题目Word批量导入</el-button
           ><el-button
             size="medium"
             @click="$refs.batchPop.openBoxs(tableData, businObj, 4)"

+ 31 - 8
vue.config.js

@@ -4,11 +4,9 @@ const webpack = require('webpack')
 function resolve(dir) {
   return path.join(__dirname, dir)
 }
-
 const name = process.env.VUE_APP_TITLE || '中正云教育管理后台' // 网页标题
-
 const port = process.env.port || process.env.npm_config_port || 80 // 端口
-
+const CompressionWebpackPlugin = require("compression-webpack-plugin");
 // vue.config.js 配置说明
 //官方vue.config.js 参考文档 https://cli.vuejs.org/zh/config/#css-loaderoptions
 // 这里只列一部分,具体配置参考文档
@@ -44,6 +42,13 @@ module.exports = {
   },
   configureWebpack: {
     name: name,
+    // 生产环境,则添加不参与打包的包名和依赖包的名称
+    externals: {
+      'vue': 'Vue',
+      'axios': 'axios',
+      'element-ui': 'ELEMENT',
+      'vue-router': 'VueRouter',
+    },
     resolve: {
       alias: {
         '@': resolve('src')
@@ -51,11 +56,23 @@ module.exports = {
     }
   },
   chainWebpack(config) {
+    // 生产环境,开启js\css压缩
+    if (process.env.NODE_ENV !== 'development') {
+      config.plugin('compressionPlugin').use(new CompressionWebpackPlugin({
+        test: /\.(js|css|less|map)$/, // 匹配文件名
+        threshold: 1024, // 对超过10k的数据压缩
+        minRatio: 0.8,
+      }))
+    }
     config.plugin('provide').use(webpack.ProvidePlugin, [{
       'window.Quill': 'quill'
     }])
-    config.plugins.delete('preload') // TODO: need test
-    config.plugins.delete('prefetch') // TODO: need test
+    // 查看打包文件体积大小
+    // config
+    //   .plugin('webpack-bundle-analyzer')
+    //   .use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin)
+    // config.plugins.delete('preload') // TODO: need test
+    // config.plugins.delete('prefetch') // TODO: need test
 
     // set svg-sprite-loader
     config.module
@@ -81,13 +98,15 @@ module.exports = {
             .plugin('ScriptExtHtmlWebpackPlugin')
             .after('html')
             .use('script-ext-html-webpack-plugin', [{
-            // `runtime` must same as runtimeChunk name. default is `runtime`
+              // `runtime` must same as runtimeChunk name. default is `runtime`
               inline: /runtime\..*\.js$/
             }])
             .end()
           config
             .optimization.splitChunks({
               chunks: 'all',
+              minSize: 1000000,
+              maxSize: 3000000,
               cacheGroups: {
                 libs: {
                   name: 'chunk-libs',
@@ -110,9 +129,13 @@ module.exports = {
               }
             })
           config.optimization.runtimeChunk('single'),
+            config.optimization.providedExports = true,
+            config.optimization.usedExports = true,
+            config.optimization.innerGraph = true,
+            config.optimization.sideEffects = true,
           {
-             from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件
-             to: './' //到根目录下
+            from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件
+            to: './' //到根目录下
           }
         }
       )

Kaikkia tiedostoja ei voida näyttää, sillä liian monta tiedostoa muuttui tässä diffissä