Browse Source

Merge branch 'master' into xqc_16

jwyu 1 year ago
parent
commit
1e8fb4dd14
31 changed files with 2853 additions and 121 deletions
  1. 5 1
      src/api/api.js
  2. 135 1
      src/api/modules/dataApi.js
  3. 77 20
      src/api/modules/thirdBaseApi.js
  4. 8 41
      src/components/lzTable.vue
  5. 8 2
      src/main.js
  6. 12 0
      src/routes/modules/dataRoutes.js
  7. 6 0
      src/routes/modules/oldRoutes.js
  8. 9 2
      src/utils/buttonConfig.js
  9. 96 0
      src/views/dataEntry_manage/css/coalCommon.scss
  10. 2 1
      src/views/dataEntry_manage/databaseComponents/edbDetailData.vue
  11. 14 0
      src/views/dataEntry_manage/databaseList.vue
  12. 388 0
      src/views/dataEntry_manage/thirdBase/coalWord.vue
  13. 292 0
      src/views/dataEntry_manage/thirdBase/icpiConsumption.vue
  14. 37 32
      src/views/datasheet_manage/components/MixedTable.vue
  15. 14 2
      src/views/datasheet_manage/components/SheetExcel.vue
  16. 9 3
      src/views/edbHistoryPage.vue
  17. 1 1
      src/views/mychart_manage/index.vue
  18. 4 1
      src/views/ppt_manage/mixins/pptMixins.js
  19. 11 4
      src/views/ppt_manage/newVersion/components/editor/AddFormat.vue
  20. 7 1
      src/views/ppt_manage/newVersion/components/editor/ChangeFormatDialog.vue
  21. 111 0
      src/views/ppt_manage/newVersion/components/formatPage/FormatEle.vue
  22. 121 0
      src/views/ppt_manage/newVersion/components/formatPage/FormatTen.vue
  23. 115 0
      src/views/ppt_manage/newVersion/components/formatPage/FormatTwelve.vue
  24. 40 0
      src/views/ppt_manage/newVersion/components/formatPreview/FormatPreEle.vue
  25. 44 0
      src/views/ppt_manage/newVersion/components/formatPreview/FormatPreTen.vue
  26. 41 0
      src/views/ppt_manage/newVersion/components/formatPreview/FormatPreTwelve.vue
  27. 16 2
      src/views/ppt_manage/newVersion/pptPublish.vue
  28. 192 3
      src/views/ppt_manage/newVersion/utils/config.js
  29. 47 4
      src/views/ppt_manage/newVersion/utils/untils.js
  30. 259 0
      src/views/system_manage/components/refreshConfig.vue
  31. 732 0
      src/views/system_manage/dataRefreshSetting.vue

+ 5 - 1
src/api/api.js

@@ -13,7 +13,9 @@ import {
   databankInterface,
   yongyiInterface,
   fwmtInterface,
-  guangqiInterface
+  guangqiInterface,
+  icpiInterface,
+  coalWordInterface
 } from './modules/thirdBaseApi';
 
 //手工指标 手工数据 手工数据权限
@@ -119,6 +121,8 @@ export {
   yongyiInterface,
   fwmtInterface,
   guangqiInterface,
+  icpiInterface,
+  coalWordInterface
 };
 
 //老接口 研报 ppt等

+ 135 - 1
src/api/modules/dataApi.js

@@ -385,8 +385,142 @@ const dataAuthInterface = {
 		return http.get('/datamanage/manual/classify/all_list',params)
 	}
 }
+/* 数据刷新设置 */
+const dataRefreshInterface = {
+    /**
+     * 获取数据源列表,Child不为空则显示第二个筛选框
+     * @param {*} params 
+     * @returns 
+     */
+    getDataSourceList:params=>{
+        return http.get("/datamanage/edb_info/refresh/source_list",params)
+    },
+    /**
+     * 获取数据源刷新的默认设置
+     * @param {Object} params 
+     * @param {Number} params.Source
+     * @param {Number} params.SubSource
+     * @param {String} params.Frequency
+     * @returns 
+     */
+    getDefaultConfig:params=>{
+        return http.get("/datamanage/edb_info/refresh/default_config",params)
+    },
+    /**
+     * 获取终端列表
+     * @param {Object} params 
+     * @param {Number} params.Source
+     * @returns 
+     */
+    getTerminalList:params=>{
+        return http.get("/data_stat/terminal/code",params)
+    },
+    /**
+     * 获取分类列表
+     * @param {Object} params 
+     * @param {Number} params.Source 
+     * @returns 
+     */
+    getClassifyList:params=>{
+        return http.get("/datamanage/edb_info/refresh/classify_list",params)
+    },
+    /**
+     * 获取筛选后的指标列表
+     * @param {Object} params 
+     * @param {Number} params.Source 
+     * @param {Number} params.SubSource
+     * @param {Number} params.ClassifyId
+     * @param {String} params.TerminalCode
+     * @param {Number} params.SysUserId
+     * @param {String} params.Frequency
+     * @param {String} params.Keyword
+     * @param {String} params.Status
+     * @param {String} params.SortParam 排序字段:end_date(最新日期)
+     * @param {String} params.SortType 排序类型,正序:asc;逆序:desc
+     * @param {Number} params.PageSize
+     * @param {Number} params.CurrentIndex
+     * @returns 
+     */
+    getEdbTableList:params=>{
+        return http.get("/datamanage/edb_info/refresh/edb_list",params)
+    },
+    /**
+     * 单独设置指标刷新时间
+     * @param {Object} params 
+     * @param {Number} params.Source
+     * @param {Number} params.SubSource
+     * @param {String} params.ClassifyId 筛选项 多选
+     * @param {String} params.TerminalCode 筛选项
+     * @param {String} params.SysUserId 筛选项 多选
+     * @param {String} params.Frequency 筛选项 多选
+     * @param {String} params.Keyword 筛选项
+     * @param {String} params.Status 筛选项
+     * @param {Boolean} params.IsSelectAll
+     * @param {Object[]} params.EdbSelectIdList
+     * @param {Object[]} params.List
+     * @param {String} params.List[].RefreshFrequency
+     * @param {Number} params.List[].RefreshFrequencyDay
+     * @param {String} params.List[].RefreshTime
+     * @param {Number} params.List[].RefreshAllData
+     * @param {Number} params.List[].RefreshDataNum
+     * @returns 
+     */
+    setRefreshTime(params){
+        return http.post("/datamanage/edb_info/refresh/config/save",params)
+    },
+    /**
+     * 设置默认的指标刷新时间
+     * @param {Object} params 
+     * @param {Number} params.Source
+     * @param {Number} params.SubSource
+     * @param {String} params.Frequency 
+     * @param {Object[]} params.List
+     * @param {String} params.List[].RefreshFrequency
+     * @param {Number} params.List[].RefreshFrequencyDay
+     * @param {String} params.List[].RefreshTime
+     * @param {Number} params.List[].RefreshAllData
+     * @param {Number} params.List[].RefreshDataNum
+     * @returns 
+     */
+    setDefaultTime(params){
+        return http.post("/datamanage/edb_info/refresh/default_config/save",params)
+    },
+    /**
+     * 设置指标刷新状态
+     * @param {Object} params 
+     * @param {Number} params.Source
+     * @param {Number} params.SubSource
+     * @param {String} params.ClassifyId 筛选项 多选
+     * @param {String} params.TerminalCode 筛选项
+     * @param {String} params.SysUserId 筛选项 多选
+     * @param {String} params.Frequency 筛选项 多选
+     * @param {String} params.Keyword 筛选项
+     * @param {String} params.Status 筛选项
+     * @param {Boolean} params.IsSelectAll
+     * @param {Object[]} params.EdbSelectIdList
+     * @param {String} params.ModifyStatus 需要更改的状态,枚举值:启用、暂停
+     * @returns 
+     */
+    setRefreshStatus(params){
+        return http.post("/datamanage/edb_info/refresh/status/save",params)
+    },
+    /**
+     * 获取单个指标的刷新配置
+     * @param {Object} params 
+     * @param {Number} params.EdbInfoId
+     * @param {Number} params.Source
+     * @param {Number} params.SubSource
+     * @returns 
+     */
+    getSimgleEdbRefreshTime(params){
+        return http.get("/datamanage/edb_info/refresh/edb_config",params)
+    },
+
+
+}
 
 export {
 	dataInterence,
-	dataAuthInterface
+	dataAuthInterface,
+    dataRefreshInterface
 }

+ 77 - 20
src/api/modules/thirdBaseApi.js

@@ -779,30 +779,30 @@ const yongyiInterface={
 
 /* 汾渭煤炭树 */
 const fwmtInterface={
-	/**
+		/**
 	 * 分类列表
 	 * @param {} params 
 	 * @returns 
 	 */
-	classifyList: params => {
-		return http.get('/datamanage/fenwei/classify',params);
-	},
-	/**
-	 * 获取指标列表详情
-	 */
-	dataList: params => {
-		return http.get('/datamanage/fenwei/index/data',params);
-	},
-	//单个指标数据
-	getTargetDataList:params=>{
-		return http.get('/datamanage/fenwei/single_data',params);
-	},
-	// 搜索
-	getTargetListByName:params=>{
-		return http.get('/datamanage/fenwei/search_list',params);
-	}
+		classifyList: params => {
+			return http.get('/datamanage/fenwei/classify',params);
+		},
+		/**
+		 * 获取指标列表详情
+		 */
+		dataList: params => {
+			return http.get('/datamanage/fenwei/index/data',params);
+		},
+		//单个指标数据
+		getTargetDataList:params=>{
+			return http.get('/datamanage/fenwei/single_data',params);
+		},
+		// 搜索
+		getTargetListByName:params=>{
+			return http.get('/datamanage/fenwei/search_list',params);
+		}
 }
-
+/* 广期所 */
 const guangqiInterface={
 		/**
 		 * 分类列表
@@ -856,6 +856,61 @@ const guangqiInterface={
 	},
 }
 
+/* ICPI消费价格指数 */
+const icpiInterface={
+	/**
+	 * 分类列表
+	 * @param {} params 
+	 * @returns 
+	 */
+	classifyList: params => {
+		return http.get('/data_source/icpi/classify/list',params);
+	},
+	/**
+	 * 获取指标列表详情
+	 * BaseFromIcpiClassifyId PageSize CurrentIndex
+	 */
+	dataList: params => {
+		return http.get('/data_source/icpi/index/data',params);
+	}
+}
+
+/* 煤炭江湖 */
+const coalWordInterface={
+	/**
+	 * 分类列表
+	 * @param {} params 
+	 * @returns 
+	 */
+	classifyList: params => {
+		return http.get('/entry/data/mtjh/classify',params);
+	},
+	/**
+	 * 获取指标列表详情 Area PageSize CurrentIndex
+	 */
+	dataList: params => {
+		return http.get('/entry/data/mtjh/data',params);
+	},
+	/**
+	 * 单个指标数据 IndexCode PageSize CurrentIndex
+	*/
+	getTargetDataList:params=>{
+		return http.get('/entry/data/mtjh/single_data',params);
+	},
+	/**
+	 * 搜索 Keyword
+	*/
+	targetListSearch:params=>{
+		return http.get('/entry/data/mtjh/search',params);
+	},
+	/**
+	 * 获取频度列表 Area
+	*/
+	getFrequencyList:params=>{
+		return http.get('/entry/data/mtjh/frequency',params)
+	},
+}
+
 export { 
 	lzDataInterface,
 	glDataInterface,
@@ -869,5 +924,7 @@ export {
   databankInterface,
   yongyiInterface,
   fwmtInterface,
-	guangqiInterface
+	guangqiInterface,
+	icpiInterface,
+	coalWordInterface
 }

+ 8 - 41
src/components/lzTable.vue

@@ -69,19 +69,11 @@ export default {
 		headerArr(){
 			let arr=['QuotaName','LzCode','Frequency','UnitName','ModifyTime']
 
+			let sourceTypeOne = ['smm','coal','baiinfo','yyzx','icpi','coalWord']
+
 			if(this.source==='gl'){
 				arr=['IndexName','IndexCode','FrequencyName','UnitName','UpdateTime']
-			}
-			if(this.source==='smm'){
-				arr=['IndexName','IndexCode','Frequency','Unit','ModifyTime']
-			}
-			if(this.source==='coal'){
-				arr=['IndexName','IndexCode','Frequency','Unit','ModifyTime']
-			}
-			if(this.source==='baiinfo'){
-				arr=['IndexName','IndexCode','Frequency','Unit','ModifyTime']
-			}
-			if(this.source==='yyzx'){
+			}else if(sourceTypeOne.includes(this.source)){
 				arr=['IndexName','IndexCode','Frequency','Unit','ModifyTime']
 			}
 
@@ -95,6 +87,7 @@ export default {
 				['UnitName', '单位'],
 				['ModifyTime', '更新时间'],
 			])
+			let sourceTypeOne = ['smm','coal','baiinfo','yyzx','icpi','coalWord']
 
 			if(this.source==='gl'){
 				temMap=new Map([
@@ -104,35 +97,7 @@ export default {
 					['UnitName', '单位'],
 					['UpdateTime', '更新时间'],
 				])
-			}
-			if(this.source==='smm'){
-				temMap=new Map([
-					['IndexName', '指标名称'],
-					['IndexCode', '指标ID'],
-					['Frequency', '频度'],
-					['Unit', '单位'],
-					['ModifyTime', '更新时间'],
-				])
-			}
-			if(this.source==='coal'){
-				temMap=new Map([
-					['IndexName', '指标名称'],
-					['IndexCode', '指标ID'],
-					['Frequency', '频度'],
-					['Unit', '单位'],
-					['ModifyTime', '更新时间'],
-				])
-			}
-			if(this.source==='baiinfo'){
-				temMap=new Map([
-					['IndexName', '指标名称'],
-					['IndexCode', '指标ID'],
-					['Frequency', '频度'],
-					['Unit', '单位'],
-					['ModifyTime', '更新时间'],
-				])
-			}
-			if(this.source==='yyzx'){
+			}else if(sourceTypeOne.includes(this.source)){
 				temMap=new Map([
 					['IndexName', '指标名称'],
 					['IndexCode', '指标ID'],
@@ -146,8 +111,10 @@ export default {
 		},
 		dynamic_key(){
 			let key='InputValue'
-			if(['smm','baiinfo','coal','yyzx'].includes(this.source)){
+			if(['smm','baiinfo','coal','yyzx','icpi'].includes(this.source)){
 				key='Value'
+			}else if(this.source=='coalWord'){
+				key='DealValue'
 			}
 
 			return key

+ 8 - 2
src/main.js

@@ -11,6 +11,7 @@ import "font-awesome/css/font-awesome.min.css";
 import "@/utils/dialog.js";
 import "@/utils/option-scroll.js";
 import "@/utils/buttonPermission.js";
+import { dataBaseInterface } from '@/api/api.js';
 import { mixins } from "@/mixins";
 Vue.mixin(mixins);
 
@@ -24,7 +25,7 @@ import{endCalc,optionTimeCalc,init}from'@/utils/TimeOnPage.js';
 import setting from '@/mixins/theme.js'
 Vue.prototype.$setting = setting;
 
-Vue.prototype.toHistoryPage = (EdbInfoId,from=[])=>{
+Vue.prototype.toHistoryPage =  async(EdbInfoId,from=[])=>{
     console.log('from',from)
     let pathArr = from.map(p=>{
         return {
@@ -37,10 +38,15 @@ Vue.prototype.toHistoryPage = (EdbInfoId,from=[])=>{
         path:'/edbHistory'
     })
     sessionStorage.setItem('edbHistoryPath',JSON.stringify(pathArr))
+
+    //改为传code获取溯源 改的地方太多了在这里直接获取code算了
+    const {Ret,Data} = await dataBaseInterface.targetDetail({EdbInfoId})
+    if(Ret!==200) return
+
     const href = router.resolve({
         path:'/edbHistory',
         query:{
-            edbId:EdbInfoId,
+            code:Data.UniqueCode,
         }
     }).href
     window.open(href,"_blank")

+ 12 - 0
src/routes/modules/dataRoutes.js

@@ -80,6 +80,12 @@ export default [
         name: "天然气历史数据",
         hidden: true,
       },
+      {
+        path: "ICPIconsumption",
+        component: () => import("@/views/dataEntry_manage/thirdBase/icpiConsumption.vue"),
+        name: "ICPI消费价格指数",
+        hidden: false,
+      },
       {
         path: "zhengzhoushop",
         component: () =>
@@ -233,6 +239,12 @@ export default [
           keepAlive: false,
         },
       },
+      {
+        path: "coalWord",
+        component: () => import("@/views/dataEntry_manage/thirdBase/coalWord.vue"),
+        name: "煤炭江湖",
+        hidden: false
+      },
     ],
   },
 ];

+ 6 - 0
src/routes/modules/oldRoutes.js

@@ -366,6 +366,12 @@ export default [
         name: "数据源终端管理",
         hidden: true,
       },
+      {
+        path: "dataRefreshSetting",
+        component: () => import("@/views/system_manage/dataRefreshSetting.vue"),
+        name: "数据刷新设置",
+        hidden: true,
+      },
     ],
   },
   // 外部链接

+ 9 - 2
src/utils/buttonConfig.js

@@ -241,7 +241,10 @@ export const dataSourcePermission = {
     dataSource_account_edit:'dataSourceAccount:edit',//编辑
     dataSource_account_enable:'dataSourceAccount:enable',//禁用/启用
     /*--------涌益咨询---- */
-    yyzxData_export:'yyzx:exportData'
+    yyzxData_export:'yyzx:exportData',
+    /*--------煤炭江湖---- */
+    coalWordData_view:'coalWord:view', // 查看
+    coalWordData_export:'coalWord:export', // 导出
 }
 
 /*
@@ -595,7 +598,11 @@ export const sysDepartPermission = {
     sysRole_addRole:'sysRole:addRole',//添加角色
     /*-----------英文权限配置-------- */
     enAuthManage_del:'enAuthManage:del',
-    enAuthManage_settingAuth:'enAuthManage:settingAuth'
+    enAuthManage_settingAuth:'enAuthManage:settingAuth',
+    /*-----------数据刷新设置-------- */
+    refresh_default:'refresh:default', //默认刷新时间 
+    refresh_time:'refresh:time', //设置刷新时间
+    refresh_state:'refresh:state', //设置刷新状态
 }
 /*-----------数据操作权限-------- */
 export const operateAuthPermission = {

+ 96 - 0
src/views/dataEntry_manage/css/coalCommon.scss

@@ -0,0 +1,96 @@
+// 煤炭江湖页面的同款样式
+
+.coal-similarity-container {
+  display: flex;
+  position: relative;
+  box-sizing: border-box;
+  .slide-btn-icon{
+        &.slide-left{
+            left:225px;
+        }
+        &.slide-right{
+            left: 0;
+        }
+    }
+  .minHeight {
+    height: calc(100vh - 120px);
+    background-color: #fff;
+    box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.05);
+    border-radius: 4px;
+    box-sizing: border-box;
+  }
+  div::-webkit-scrollbar {
+    width: 5px !important;
+  }
+  .left-cont {
+    min-width: 240px;
+    width:240px;
+    margin-right: 20px;
+    padding: 30px 0;
+    overflow: hidden;
+    .left-top {
+      padding: 0 20px;
+    }
+    .classify-list {
+      padding: 0 20px;
+      margin-top: 20px;
+      height: calc(100vh - 280px);
+      overflow-y: auto;
+      .classify-item {
+        font-size: 14px;
+        color: #666;
+        margin-bottom: 20px;
+        &:hover {
+          cursor: pointer;
+          color: #409eff;
+        }
+        &.act {
+          color: #409eff;
+        }
+      }
+    }
+  }
+  .right-cont {
+    flex:1;
+    padding: 30px;
+    overflow-x: auto;
+    box-sizing: border-box;
+    display: flex;
+    flex-direction: column;
+    .right-box {
+      max-width: 100%;
+      flex-grow: 1;
+      min-height: 600px;
+      // border-right: 1px solid #dcdfe6;
+      box-sizing: border-box;
+      overflow: auto;
+      .data-header {
+        width: 100%;
+        position: sticky;
+        top: 0;
+        z-index: 2;
+      }
+      .data-cont {
+        height: calc(100vh - 444px);
+      }
+      .nodata {
+        width: 100%;
+        font-size: 16px;
+        color: #999;
+        padding-top: 100px;
+      }
+    }
+    .frequency-list {
+      margin-top: 20px;
+      display: flex;
+      flex-wrap: wrap;
+      gap:20px;
+      .el-button{
+            margin-left: 0 !important;
+        }
+      .frequency-btn {
+        width: 112px;
+      }
+    }
+  }
+}

+ 2 - 1
src/views/dataEntry_manage/databaseComponents/edbDetailData.vue

@@ -35,7 +35,8 @@
 					<span>{{ item.label }}</span>
 				</template>
 				<template slot-scope="scope">
-					<span>{{ scope.row[item.key] }}</span>
+					<span v-if="item.key==='NoUpdate'">{{scope.row[item.key]?'暂停':'启用'}}</span>
+					<span v-else>{{ scope.row[item.key] }}</span>
 				</template>
 			</el-table-column>
 			<div slot="empty" style="padding: 50px 0 320px;">

+ 14 - 0
src/views/dataEntry_manage/databaseList.vue

@@ -644,6 +644,11 @@ export default {
 					key: 'ModifyTime',
 					minwidthsty: '120px',
 				},
+				{
+					label:'刷新状态',
+					key:'NoUpdate',
+					widthsty:'100px'
+				},
 				{
 					label: '添加人',
 					key: 'SysUserRealName',
@@ -1324,6 +1329,11 @@ export default {
 		},
 		/* 刷新获取指标最新数据 */
 		refreshTargetHandle: _.debounce(function() {
+			//如果该指标为暂停刷新,则提示
+			if(this.EdbData.NoUpdate){
+				this.$message.warning("该指标已暂停刷新")
+				return
+			}
 			if(this.selected_edbid) {
 				this.loading = this.$loading({
 					lock: true,
@@ -1765,6 +1775,10 @@ export default {
 
 		/* 基础指标刷新 */
 		refreshBaseHandler() {
+			if(this.EdbData.NoUpdate){
+				this.$message.warning("该指标已暂停刷新")
+				return 
+			}
 			this.refreshLoading = true;
 			this.loading = this.$loading({
 					lock: true,

+ 388 - 0
src/views/dataEntry_manage/thirdBase/coalWord.vue

@@ -0,0 +1,388 @@
+<template>
+  <div class="coal-word-container coal-similarity-container" >
+    <span
+        class="slide-btn-icon"
+        :class="{'slide-left':isLeftWrapShow,'slide-right':!isLeftWrapShow}"
+        @click="isLeftWrapShow = !isLeftWrapShow"
+    >
+        <i :class="{'el-icon-d-arrow-left':isLeftWrapShow,'el-icon-d-arrow-right':!isLeftWrapShow}"></i>
+    </span>
+    <div class="left-cont minHeight" v-show="isLeftWrapShow">
+      <div class="left-top">
+        <el-button
+          style="width: 100%;margin-bottom: 10px;"
+          type="primary"
+          plain
+          size="medium"
+          @click="exportClick"
+          :loading="btnload"
+          v-permission="permissionBtn.dataSourcePermission.coalWordData_export" 
+          >导出Excel</el-button
+        >
+        <el-autocomplete
+          style="margintop: 20px; width: 100%"
+          prefix-icon="el-icon-search"
+          v-model="leftSearchVal"
+          :fetch-suggestions="handleLeftSearch"
+          :trigger-on-focus="false"
+          placeholder="指标名称/指标ID"
+          @select="handleSelectLeftSearchval"
+          @blur="searchvalBlur"
+          @clear="searchvalClear"
+          popper-class="el-autocomplete-suggestion-data-entry"
+          clearable
+        >
+          <template slot-scope="scope">
+            <div v-if="scope.item.nodata" style="text-align: center">
+              暂无数据
+            </div>
+            <div v-else>
+              {{ scope.item.IndexName }}
+            </div>
+          </template>
+        </el-autocomplete>
+      </div>
+      <ul class="classify-list">
+        <li
+          :class="['classify-item', { act: select_classify == item.Area }]"
+          v-for="item in classifyList"
+          :key="item.Area"
+          @click="changeClassify(item)"
+        >
+          {{ item.Area }}
+        </li>
+      </ul>
+    </div>
+    <div
+      class="right-cont minHeight"
+      v-loading="dataloading"
+      element-loading-text="获取数据中..."
+    >
+      <div class="right-box" v-if="rightShow"
+        v-infinite-scroll="loadNext"
+        :infinite-scroll-disabled="!haveMore"
+        :infinite-scroll-immediate="false">
+        <template v-if="dateArr.length">
+          <div class="data-header">
+            <lz-table
+              :tableOption="tableOption"
+              tableType="header"
+              ref="table"
+              source="coalWord"
+            />
+          </div>
+          <div class="data-cont" >
+            <lz-table
+              :tableOption="tableOption"
+              tableType="data"
+              :dateArr="dateArr"
+              source="coalWord"
+            />
+          </div>
+        </template>
+        <tableNoData v-else text="暂无数据" class="nodata"></tableNoData>
+      </div>
+      <div class="frequency-list" v-if="rightShow">
+        <el-button
+          type="primary"
+          class="frequency-btn"
+          :plain="select_frequency !== item"
+          v-for="item in frequencyList"
+          :key="item"
+          @click="changeFrequency(item)"
+          >{{ item }}</el-button
+        >
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import lzTable from "@/components/lzTable.vue";
+import { coalWordInterface } from "@/api/api.js";
+export default {
+  name: "coalWord",
+  components: { lzTable },
+  watch: {
+    select_classify(newval) {
+      if (!this.isAuto) return;
+      this.select_frequency = "";
+      newval && this.getFrequency();
+    },
+    select_frequency(newval) {
+      if (!this.isAuto) return;
+      newval && this.getDataList();
+    },
+  },
+  computed: {
+    exportApi() {
+      // 数据导出接口
+      let urlStr = this.exportBase;
+      // token
+      urlStr += `?${localStorage.getItem("auth") || ""}`;
+      // 分类名称
+      urlStr += `&Area=${this.select_classify}`;
+      // 指标Id
+      urlStr += `&IndexCode=${this.leftSearchTradeCode}`;
+      return this.escapeStr(urlStr);
+    },
+  },
+  created() {
+    if(this.permissionBtn.isShowBtn('dataSourcePermission','coalWordData_view')){
+      this.getClassify();
+    }else{
+      this.rightShow=true
+    }
+  },
+  data() {
+    return {
+      isLeftWrapShow:true,
+      dataloading: false,
+      rightShow: false,
+      exportBase: process.env.VUE_APP_API_ROOT + "/entry/export/mtjh", //数据导出接口
+      select_classify: "",
+      classifyList: [],
+      select_frequency: "",
+      PageSize:20,
+      CurrentIndex:1,
+      haveMore:true,
+      frequencyType: new Map([
+        [1, "日度"],
+        [2, "周度"],
+        [3, "月度"],
+        [4, "季度"],
+        [5, "年度"],
+        [99, "无固定频率"],
+      ]),
+      frequencyList: [],
+      tableOption: [],
+      dateArr: [], //最长的日期数组
+      btnload: false,
+      leftSearchVal: "", //左侧搜索值
+      leftSearchTradeCode: "", //如果是搜索选择的 则有此code
+      isAuto: true, // 改变分类时是否自动获取数据
+    };
+  },
+  methods: {
+    /* 获取分类 */
+    getClassify() {
+      coalWordInterface.classifyList().then((res) => {
+        if (res.Ret !== 200) return;
+        this.classifyList = res.Data || [];
+        this.select_classify =
+          this.select_classify || this.classifyList[0].Area;
+      });
+    },
+    /* 获取频度 */
+    getFrequency(defaultSelect) {
+      coalWordInterface.getFrequencyList({
+        Area: this.select_classify,
+      }).then((res) => {
+        if (res.Ret !== 200) return;
+        this.frequencyList = res.Data || []
+        //设置当前选中的频度,若传入有默认选项则选中默认频度,否则选中列表第一个
+        this.select_frequency = defaultSelect || this.frequencyList[0];
+        //如果有默认频度,结束后恢复watcher
+        this.$nextTick(() => {
+          if (defaultSelect) this.isAuto = true;
+        });
+      });
+    },
+    /* 获取数据 */
+    getDataList() {
+      this.dataloading = true;
+      coalWordInterface.dataList({
+        Area: this.select_classify,
+        PageSize: this.PageSize,
+        CurrentIndex:this.CurrentIndex,
+        Frequency: this.select_frequency,
+      }).then((res) => {
+        this.rightShow = true;
+        if (res.Ret !== 200) return;
+
+        // 找出最多的页码 判断是否还有数据
+        let page_arrs = res.Data.map((item) => item.Paging?item.Paging.Pages:0);
+        let totalPage = Math.max.apply(Math, page_arrs);
+        this.haveMore = this.CurrentIndex < totalPage ? true : false;
+        // 设置表格数据
+        this.setDataList(res.Data || []);
+
+        this.CurrentIndex == 1 &&
+          this.$nextTick(() => {
+            this.initWidth();
+          });
+      }).finally(()=>{
+        this.dataloading = false;
+      })
+    },
+    /* 滚动加载 */
+    loadNext() {
+      this.CurrentIndex++;
+      if(this.leftSearchTradeCode){
+        this.getTargetDataList()
+      }else{
+        this.getDataList();
+      }
+    },
+    /* 改变分类 */
+    changeClassify(item) {
+      if(this.dataloading) return 
+      this.select_classify = item.Area;
+      this.leftSearchVal = "";
+      this.leftSearchTradeCode = ""
+      this.CurrentIndex=1
+    },
+    /* 改变频度 */
+    changeFrequency(item) {
+      if(this.select_frequency == item) return 
+      this.select_frequency = item;
+      this.leftSearchVal = "";
+      this.CurrentIndex=1
+    },
+    initWidth() {
+      $(".right-box")[0].style.width =
+      this.$refs.table ? this.$refs.table.$el.clientWidth + 2 + "px":0
+      $(".right-box")[0].scrollTop = 0;
+      $(".right-box")[0].scrollLeft = 0;
+    },
+    /* 数据导出 */
+    exportClick() {
+      this.btnload = true;
+      console.log({
+        Area:this.select_classify,
+        IndexCode:this.leftSearchTradeCode
+      },this.exportApi);
+      const link = document.createElement("a");
+      link.href = this.exportApi;
+      link.download = "";
+      link.click();
+      setTimeout(() => {
+        this.btnload = false;
+      }, 2000);
+    },
+
+    //左侧搜索
+    async handleLeftSearch(query, cb) {
+      cb([]);
+      if (!query) return;
+      const res = await coalWordInterface.targetListSearch({
+        Keyword: query,
+      });
+      if (res.Ret === 200) {
+        let arr = res.Data || [];
+        if (!arr.length) {
+          cb([{ nodata: true }]);
+        } else {
+          cb(arr);
+        }
+      }
+    },
+    // 选中左侧搜索值
+    handleSelectLeftSearchval(e) {
+      if (!e.IndexCode || this.dataloading) return;
+      this.leftSearchTradeCode = e.IndexCode;
+      this.leftSearchVal = e.IndexName;
+      this.select_classify = e.Area
+      // 关闭watcher
+      this.isAuto = false;
+      this.getFrequency(e.Frequency);
+      this.CurrentIndex=1
+      this.getTargetDataList()
+      this.$nextTick(() => {
+        this.handleScrollLeftWrap();
+      });
+    },
+    searchvalBlur(){
+      if((!this.leftSearchVal) && this.leftSearchTradeCode){
+        this.searchvalClear()
+      }   
+    },
+    searchvalClear(){
+      this.CurrentIndex=1
+      this.leftSearchTradeCode=''
+      this.getDataList();
+    },
+    // 左侧滚动
+    handleScrollLeftWrap() {
+      let top = $(".act")[0].offsetTop;
+      $(".classify-list").animate({
+        scrollTop: top - 200,
+      });
+    },
+    // 获取单个指标数据
+    getTargetDataList() {
+      if (!this.leftSearchTradeCode) return;
+      this.dataloading = true;
+
+      try {
+        coalWordInterface.getTargetDataList({
+          IndexCode: this.leftSearchTradeCode,
+          Pagesize: this.PageSize,
+          CurrentIndex: this.CurrentIndex
+        }).then(res=>{
+          if (res.Ret !== 200) return;
+
+          this.haveMore = this.CurrentIndex < res.Data.Paging.Pages ? true : false;
+          this.setDataList([res.Data])
+
+          this.CurrentIndex == 1 &&
+            this.$nextTick(() => {
+              this.initWidth();
+            });
+        }).finally(()=>{
+          this.dataloading = false;
+        })
+      } catch (err) {
+        console.error(err);
+        this.dataloading = false;
+      }
+    },
+    // 设置表格数据
+    setDataList(data) {
+      if(this.CurrentIndex ==1){
+        this.tableOption = data;
+        /* 不满6个追加6个空的显示一排 别问 问就是为了美观  */
+        if (data.length < 6){
+          for (let i = 0; i < 6; i++) {
+            this.tableOption.push({
+              DataList: [],
+            });
+            if (this.tableOption.length >= 6) break;
+          }
+        }
+      }else{
+        this.tableOption.forEach((item) => {
+          data.forEach((_item) => {
+            if (item.IndexCode === _item.IndexCode) {
+              item.DataList = item.DataList.concat(_item.DataList);
+            }
+          });
+        });
+      }   
+      // 合并所有日期
+      let arr = this.tableOption.map((item) => item.DataList);
+      let obj = [];
+      arr.forEach((dataList) => {
+        obj.push(...dataList.map((item) => item.DataTime));
+      });
+      // 日期去重倒序排序
+      this.dateArr = [...new Set(obj)].sort().reverse();
+      //数据最大长度小于12个 追加数据满12个 别问 问就是为了美观
+      if (this.dateArr.length < 12){
+        for (let i = 0; i < 12; i++) {
+          this.dateArr.push("");
+          if (this.dateArr.length >= 12) break;
+        }
+      }
+
+    },
+    // 对[#,;]转义
+    escapeStr(str) {
+      return str.replace(/#/g, escape("#")).replace(/;/g, escape(";"));
+    },
+  },
+};
+</script>
+<style lang="scss" scoped>
+@import "../css/coalCommon.scss";
+</style>

+ 292 - 0
src/views/dataEntry_manage/thirdBase/icpiConsumption.vue

@@ -0,0 +1,292 @@
+<template>
+  <div class="icpc-container coal-similarity-container">
+    <span
+        class="slide-btn-icon"
+        :class="{'slide-left':isLeftWrapShow,'slide-right':!isLeftWrapShow}"
+        @click="isLeftWrapShow = !isLeftWrapShow"
+    >
+        <i :class="{'el-icon-d-arrow-left':isLeftWrapShow,'el-icon-d-arrow-right':!isLeftWrapShow}"></i>
+    </span>
+    <div class="left-cont minHeight" v-show="isLeftWrapShow">
+      <div class="left-top">
+        <el-button
+          style="width: 100%;"
+          type="primary"
+          plain
+          size="medium"
+          @click="exportClick"
+          :loading="btnload"
+          >导出Excel</el-button
+        >
+        <el-autocomplete
+          style="margin-top: 20px; width: 100%"
+          prefix-icon="el-icon-search"
+          v-model="leftSearchVal"
+          :fetch-suggestions="handleLeftSearch"
+          :trigger-on-focus="false"
+          placeholder="指标名称/指标ID"
+          @select="handleSelectLeftSearchval"
+          popper-class="el-autocomplete-suggestion-data-entry"
+          @clear="clearSearchVal"
+          clearable
+        >
+          <template slot-scope="scope">
+            <div v-if="scope.item.nodata" style="text-align: center">
+              暂无数据
+            </div>
+            <div v-else>
+              {{ scope.item.IndexName }}
+            </div>
+          </template>
+        </el-autocomplete>
+      </div>
+      <ul class="classify-list">
+        <li
+          :class="['classify-item', { act: select_classify === item.BaseFromIcpiClassifyId }]"
+          v-for="item in classifyList"
+          :key="item.BaseFromIcpiClassifyId"
+          @click="changeClassify(item)"
+        >
+          {{ item.ClassifyName }}
+        </li>
+      </ul>
+    </div>
+    <div
+      class="right-cont minHeight"
+      v-loading="dataloading"
+      element-loading-text="获取数据中..."
+    >
+      <div class="right-box" v-if="rightShow" @scroll="scrollHandle">
+        <template v-if="dateArr.length">
+          <div class="data-header">
+            <lz-table
+              :tableOption="tableOption"
+              tableType="header"
+              ref="table"
+              source="icpi"
+            />
+          </div>
+          <div class="data-cont">
+            <lz-table
+              :tableOption="tableOption"
+              tableType="data"
+              :dateArr="dateArr"
+              source="icpi"
+            />
+          </div>
+        </template>
+        <tableNoData v-else text="暂无数据" class="nodata"></tableNoData>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import lzTable from "@/components/lzTable.vue";
+import { lzDataInterface } from "@/api/api.js";
+import { icpiInterface } from "@/api/api.js";
+
+export default {
+  name: "icpiConsumption",
+  components: { lzTable },
+  data() {
+    return {
+      isLeftWrapShow:true,
+      dataloading: false,
+      rightShow: false,
+      exportBase: process.env.VUE_APP_API_ROOT + "/data_source/icpi/export/icpiDataList", //数据导出接口
+      select_classify: "",
+      classifyList: [],
+      tableOption: [],
+      dateArr: [], //最长的日期数组
+      btnload: false,
+
+      leftSearchVal: "", //左侧搜索值
+      pageParams:{
+        PageSize:20,
+        CurrentIndex:1,
+        KeyWord:''
+      },
+      havemore:true
+    };
+  },
+  computed: {
+    exportIcpiApi() {
+      // 数据导出接口
+      let urlStr = this.exportBase;
+      // token
+      urlStr += `?${localStorage.getItem("auth") || ""}`;
+      // 分类Id参数
+      urlStr += `&BaseFromIcpiClassifyId=${this.select_classify}`;
+      urlStr += `&KeyWord=${this.pageParams.KeyWord}`;
+      return this.escapeStr(urlStr);
+    },
+  },
+  created() {
+    this.getClassify();
+  },
+  methods: {
+    /* 获取分类 */
+    getClassify() {
+      icpiInterface.classifyList().then((res) => {
+        if (res.Ret !== 200) return;
+        this.classifyList = res.Data || [];
+        this.select_classify =
+          this.select_classify || this.classifyList[0].BaseFromIcpiClassifyId;
+        
+        this.getDataList()
+      });
+    },
+
+    /* 获取数据 */
+    getDataList() {
+      this.dataloading = true;
+      icpiInterface.dataList({
+        BaseFromIcpiClassifyId: Number(this.select_classify),
+        PageSize:this.pageParams.PageSize,
+        CurrentIndex:this.pageParams.CurrentIndex,
+        KeyWord:this.pageParams.KeyWord
+      }).then((res) => {
+        this.rightShow = true;
+        if (res.Ret !== 200) return;
+
+        // 找出最多的页码 判断是否还有数据
+        let page_arrs = res.Data.map((item) => item.Paging?item.Paging.Pages:0);
+        let totalPage = Math.max.apply(Math, page_arrs);
+        this.havemore = this.pageParams.CurrentIndex < totalPage ? true : false;
+        
+        // 设置表格数据
+        this.setDataList(res.Data);
+        this.$nextTick(() => {
+          this.initWidth();
+        });
+      }).finally(()=>{
+        this.dataloading = false;
+      })
+    },
+    /* 改变品种 */
+    changeClassify(item) {
+      this.select_classify = item.BaseFromIcpiClassifyId;
+      this.leftSearchVal = ""
+      this.pageParams.KeyWord=''
+      this.getDataList()
+    },
+
+    initWidth() {
+      $(".right-box")[0].style.width =
+      this.$refs.table ? this.$refs.table.$el.clientWidth + 2 + "px":'0';
+      $(".right-box")[0].scrollTop = 0;
+      $(".right-box")[0].scrollLeft = 0;
+    },
+    // 对[#,;]转义
+    escapeStr(str) {
+      return str.replace(/#/g, escape("#")).replace(/;/g, escape(";")); 
+    },
+    /* 导出 */
+    exportClick() {
+      this.btnload = true;
+      const link = document.createElement("a");
+      link.href = this.exportIcpiApi;
+      link.download = "";
+      link.click();
+      setTimeout(() => {
+        this.btnload = false;
+      }, 2000);
+    },
+
+    //左侧搜索
+    async handleLeftSearch(query, cb) {
+      cb([]);
+      if (!query) return;
+      const res = await icpiInterface.dataList({
+        KeyWord: query
+      });
+      if (res.Ret === 200) {
+        let arr = res.Data || [];
+        if (!arr.length) {
+          cb([{ nodata: true }]);
+        } else {
+          cb(arr);
+        }
+      }
+    },
+    // 选中左侧搜索值
+    handleSelectLeftSearchval(e) {
+      if (!e.BaseFromIcpiIndexId) return;
+      this.rightShow = false;
+      this.leftSearchVal = e.IndexName;
+      this.pageParams.KeyWord=e.IndexName
+      this.select_classify = e.BaseFromIcpiClassifyId;
+      this.pageParams.CurrentIndex=1
+      this.getDataList()
+      this.$nextTick(() => {
+        this.rightShow = true;
+        this.handleScrollLeftWrap();
+      });
+    },
+    clearSearchVal(){
+      this.pageParams.KeyWord=''
+      this.getDataList()
+    },
+    // 左侧滚动
+    handleScrollLeftWrap() {
+      let top = $(".act")[0].offsetTop;
+      $(".classify-list").animate({
+        scrollTop: top - 200,
+      });
+    },
+    /* 滚动加载 */
+    scrollHandle(e) {
+      const dom = e.target;
+      let total = dom.scrollTop + dom.clientHeight;
+      if (total >= dom.scrollHeight && this.havemore) {
+        this.pageParams.CurrentIndex++;
+        // console.log("load下一页");
+        this.getDataList();
+      }
+    },
+    // 设置表格数据
+    setDataList(data) {
+      if(this.pageParams.CurrentIndex==1){
+        this.tableOption = data;
+        /* 不满7个追加7个空的显示一排 别问 问就是为了美观  */
+        if (this.tableOption.length < 7){
+          for (let i = 0; i < 7; i++) {
+            this.tableOption.push({
+              DataList: [],
+            });
+            if (this.tableOption.length >= 7) break;
+          }
+        }
+      }else{
+        this.tableOption.forEach((item) => {
+          data.forEach((_item) => {
+            if (item.IndexCode === _item.IndexCode) {
+              item.DataList = item.DataList.concat(_item.DataList);
+            }
+          });
+        });
+      }
+
+      // 合并所有日期
+      let arr = this.tableOption.map((item) => item.DataList);
+      let obj = [];
+      arr.forEach((dataList) => {
+        obj.push(...dataList.map((item) => item.DataTime));
+      });
+      // 日期去重倒序排序
+      this.dateArr = [...new Set(obj)].sort().reverse();
+      //数据最大长度小于13个 追加数据满13个 别问 问就是为了美观
+      if (this.dateArr.length < 13){
+        for (let i = 0; i < 13; i++) {
+          this.dateArr.push("");
+          if (this.dateArr.length >= 13) break;
+        }
+      }
+    },
+  },
+};
+</script>
+<style lang="scss" scoped>
+@import "../css/coalCommon.scss";
+</style>

+ 37 - 32
src/views/datasheet_manage/components/MixedTable.vue

@@ -563,44 +563,49 @@ export default {
 
       //去处理每一组关联的情况
       haveRelationArr.forEach( async(relation) => {
-        const { relation_date,relation_edb } = relation;
+        const { relation_date,relation_edb,type } = relation;
   
         if((relation_date.key === key && cell.DataType === 1) || (relation_edb.key === key && cell.DataType === 2)) { //单元格类型不变只变值仍有关联关系 更新值
-  
-          //刷新插入值结果
-          let params = null;
-          if(relation_date.key === key && cell.DataType === 1) { //修改的是依赖日期格
-            let { EdbInfoId } = findCellByKey(this.config.data,relation.key)
-            params = {
-              EdbInfoId,
-              Date: cell.ShowValue
+
+          //类型4的表格插值才调接口刷数据 之后关联的有其他类型插值 区分一下
+          if(type === 4) {
+
+            //刷新插入值结果
+            let params = null;
+            if(relation_date.key === key && cell.DataType === 1) { //修改的是依赖日期格
+              let { EdbInfoId } = findCellByKey(this.config.data,relation.key)
+              params = {
+                EdbInfoId,
+                Date: cell.ShowValue
+              }
+    
+            } else if( relation_edb.key === key && cell.DataType === 2) { //修改的依赖指标格
+              let {ShowValue} = findCellByKey(this.config.data,relation_date.key)
+              params = {
+                EdbInfoId: cell.EdbInfoId,
+                Date: ShowValue
+              }
             }
+    
+            const res = await sheetInterface.insertData(params)
+            if(res.Ret !==200) return
   
-          } else if( relation_edb.key === key && cell.DataType === 2) { //修改的依赖指标格
-            let {ShowValue} = findCellByKey(this.config.data,relation_date.key)
-            params = {
-              EdbInfoId: cell.EdbInfoId,
-              Date: ShowValue
-            }
+            //现在日期无值也不清除关系了
+            // !res.Data && this.updateInsertCell(relation.key);
+            
+            this.config.data.forEach(row => {
+              row.forEach(cell => {
+                if(cell.Uid === relation.key) {
+                    cell.DataType = relation.type;
+                    cell.ShowValue = res.Data;
+                    cell.Value = res.Data;
+                    cell.EdbInfoId = params.EdbInfoId;
+                    cell.DataTime = params.Date;
+                }
+              })
+            })
           }
   
-          const res = await sheetInterface.insertData(params)
-          if(res.Ret !==200) return
-
-          //现在日期无值也不清除关系了
-          // !res.Data && this.updateInsertCell(relation.key);
-          
-          this.config.data.forEach(row => {
-            row.forEach(cell => {
-              if(cell.Uid === relation.key) {
-                  cell.DataType = relation.type;
-                  cell.ShowValue = res.Data;
-                  cell.Value = res.Data;
-                  cell.EdbInfoId = params.EdbInfoId;
-                  cell.DataTime = params.Date;
-              }
-            })
-          })
   
         }else {
           // 清除插入值单元格式和关联关系

+ 14 - 2
src/views/datasheet_manage/components/SheetExcel.vue

@@ -54,12 +54,13 @@ export default {
     },
 
     copyData() {
-      let rangeArr = luckysheet.getRangeArray('twoDimensional');
+      let rangeArr = luckysheet.getRangeValue();
+      console.log(rangeArr)
       let str = ''
       rangeArr.forEach((item,r_index) => {
         let row = ''
         item.forEach((cell,index) => {
-          row+= `${index!==0?'\t':''}${cell||''}`
+          row+= `${index!==0?'\t':''}${cell?(cell.m||this.getCellContent(cell.ct.s)):''}`
         })
         str+= r_index===rangeArr.length-1 ? row : `${row}\n`
       });
@@ -67,6 +68,17 @@ export default {
       copyFit(str)
     },
 
+    // 单元格内的文字分段
+    getCellContent(arr) {
+      if(!arr||!arr.length) return ''
+      let cellStr = ''
+      arr.forEach(_ => {
+        cellStr+=_.v.replace(/\r/,'').replace(/\n/,'')
+      })
+
+      return cellStr;
+    },
+
     updateEmit(){
       this.$emit("updated")
     }

+ 9 - 3
src/views/edbHistoryPage.vue

@@ -29,7 +29,10 @@ export default {
         renderContent(h, data) {
             return (
                 <el-tooltip content={data.RuleTitle} placement='top' popper-class='node-tooltip'>
-                    <span class='node'>{data.EdbName}</span>
+                    {
+                        data.IsStop?<span class='node stop'>{data.EdbName+'(暂停更新)'}</span>
+                        :<span class='node'>{data.EdbName}</span>
+                    }
                 </el-tooltip>
             )
         },
@@ -42,13 +45,13 @@ export default {
             window.open(href, '_blank');
         },
         async getData() {
-            const res = await dataBaseInterface.getEdbCreateHistory({ EdbInfoId: Number(this.$route.query.edbId) })
+            const res = await dataBaseInterface.getEdbCreateHistory({ UniqueCode: this.$route.query.code})
             if (res.Ret !== 200) return
             this.treeData = res.Data;
         }
     },
     mounted(){
-        if(this.$route.query.edbId){
+        if(this.$route.query.code){
             this.getData()
         }
     }
@@ -110,6 +113,9 @@ export default {
                 }
             }
         }
+        .stop{
+            color:red;
+        }
     }
     .org-tree-node-children {
         .org-tree-node ~ .org-tree-node{

+ 1 - 1
src/views/mychart_manage/index.vue

@@ -623,7 +623,7 @@ export default {
     /* 切换分类 */
     chooseClassify({MyChartClassifyId,fromPublic,AdminId}) {
       if(fromPublic!==1){
-        this.$refs.catalogTree.setCurrentKey(null)
+        this.$refs.catalogTree&&this.$refs.catalogTree.setCurrentKey(null)
       }
       this.select_classify = MyChartClassifyId;
       this.ispublic = fromPublic;

+ 4 - 1
src/views/ppt_manage/mixins/pptMixins.js

@@ -22,9 +22,12 @@ import FormatSix from '../newVersion/components/formatPage/FormatSix.vue';
 import FormatSeven from '../newVersion/components/formatPage/FormatSeven.vue';
 import FormatEight from '../newVersion/components/formatPage/FormatEight.vue';
 import FormatNine from '../newVersion/components/formatPage/FormatNine.vue';
+import FormatTen from '../newVersion/components/formatPage/FormatTen.vue';
+import FormatEle from '../newVersion/components/formatPage/FormatEle.vue';
+import FormatTwelve from '../newVersion/components/formatPage/FormatTwelve.vue';
 export default {
   components:{ FormatOne,FormatTwo,FormatThree,
-    FormatFour,FormatFive,FormatSix,FormatSeven,FormatEight,FormatNine},
+    FormatFour,FormatFive,FormatSix,FormatSeven,FormatEight,FormatNine,FormatTen,FormatEle,FormatTwelve},
   data(){
     return{
       chartInfo:null,

+ 11 - 4
src/views/ppt_manage/newVersion/components/editor/AddFormat.vue

@@ -29,6 +29,9 @@ import FormatPreSix from "@/views/ppt_manage/newVersion/components/formatPreview
 import FormatPreSeven from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreSeven";
 import FormatPreEight from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreEight";
 import FormatPreNine from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreNine";
+import FormatPreTen from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreTen";
+import FormatPreEle from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreEle";
+import FormatPreTwelve from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreTwelve";
 import {countComponentName} from '@/views/ppt_manage/newVersion/utils/untils';
 export default {
   name: "AddFormat",
@@ -47,7 +50,10 @@ export default {
     FormatPreSix,
     FormatPreSeven,
     FormatPreEight,
-    FormatPreNine
+    FormatPreNine,
+    FormatPreTen,
+    FormatPreEle,
+    FormatPreTwelve
   },
   data() {
     return {
@@ -91,11 +97,12 @@ export default {
     width: calc(100% - 40px);
     /* height: 120px; */
     display: flex;
+    /* flex-wrap: wrap; */
     justify-content: space-between;
     .format-item {
-      width: 95px;
-      height: 70px;
-      padding: 10px 10px 20px 10px;
+      width: 80px;
+      height: 56px;
+      padding: 5px;
       border: 1px solid transparent;
       cursor: pointer;
       &:hover {

+ 7 - 1
src/views/ppt_manage/newVersion/components/editor/ChangeFormatDialog.vue

@@ -45,6 +45,9 @@ import FormatPreSix from "@/views/ppt_manage/newVersion/components/formatPreview
 import FormatPreSeven from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreSeven";
 import FormatPreEight from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreEight";
 import FormatPreNine from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreNine";
+import FormatPreTen from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreTen";
+import FormatPreEle from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreEle";
+import FormatPreTwelve from "@/views/ppt_manage/newVersion/components/formatPreview/FormatPreTwelve";
 import {countComponentName} from '@/views/ppt_manage/newVersion/utils/untils';
 export default {
   props:{
@@ -65,7 +68,10 @@ export default {
     FormatPreSix,
     FormatPreSeven,
     FormatPreEight,
-    FormatPreNine
+    FormatPreNine,
+    FormatPreTen,
+    FormatPreEle,
+    FormatPreTwelve
   },
   data() {
     return {

+ 111 - 0
src/views/ppt_manage/newVersion/components/formatPage/FormatEle.vue

@@ -0,0 +1,111 @@
+<template>
+    <div class="total-wrap flex-column" :style="{'pointer-events' :isPreview?'none':'auto'}">
+        <div class="line flex-center">
+            <div class="line-item flex-center" 
+                :style="pageItem.layers&&!isLayerShow()?TypeName(1)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="1" :is="TypeName(1)" :ref="RefName(1)" :index="pageIndex" :position="1"
+                    :item="Item(1)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,1)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(2)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="2" :is="TypeName(2)" :ref="RefName(2)" :index="pageIndex" :position="2"
+                    :item="Item(2)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,2)" />
+            </div>
+        </div>
+        <div class="line flex-center">
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(3)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="3" :is="TypeName(3)" :ref="RefName(3)" :index="pageIndex" :position="3"
+                    :item="Item(3)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,3)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(4)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="4" :is="TypeName(4)" :ref="RefName(4)" :index="pageIndex" :position="4"
+                    :item="Item(4)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,4)" />
+            </div>
+        </div>
+        <div class="wrap-full-bottom bottom-15 flex-center"
+            :style="pageItem.layers&&!isLayerShow()?TypeName(5)==='ChartEl'?'z-index:5':'z-index:3':''">
+            <component :data-position="5" :is="TypeName(5)" :ref="RefName(5)" :index="pageIndex" :position="5"
+                :item="Item(5)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                @getText="getText($event,5)"></component>
+        </div>
+        <!-- 图层编辑模式 -->
+        <div class="layers" :id="`layers_${pageItem.id}`" v-if="isLayerShow()" @click.stop="clickLayer"
+            @contextmenu.stop="showLayerContentMenu">
+            <template v-for="item in pageItem.layers">
+                <component :is="getLayerElName(item)" :key="item.id" :elementInfo="item"
+                    :isActive="item.id===activeLayerEl.id&&!isClickLayer" :isLayerEdit="true"
+                    @click.stop.native="changeActEl(item)" @chooseThis="changeActEl(item)" v-on="$listeners">
+                </component>
+            </template>
+        </div>
+        <!-- 非图层编辑模式 -->
+        <template v-else>
+            <template v-for="item in pageItem.layers">
+                <component :is="getLayerElName(item)" :key="item.id" :elementInfo="item" :isActive="false"
+                    :isLayerEdit="false"></component>
+            </template>
+        </template>
+    </div>
+</template>
+
+<script>
+    import mixin from "./mixins";
+    import {
+        defaultPosition
+    } from "../../utils/config";
+    export default {
+        name: "formatEle",
+        mixins: [mixin],
+        data() {
+            return {
+                modelId: 11,
+                positionInfo: defaultPosition[11]
+            }
+        },
+    };
+</script>
+<style lang="scss">
+.line{
+    justify-content: space-around !important;
+    .line-item{
+        .el-wrap .chart-wrap{
+            width:90%;
+            height:90%;
+        }
+        .editor-wrap{
+            width:90%;
+            height:90%
+        }
+    }
+}
+</style>
+<style scoped lang="scss">
+    .total-wrap {
+        .line{
+            height:40%;
+            .line-item{
+                width:45%;
+                height:100%;
+                .el-wrap .chart-wrap{
+                    width:90%;
+                    height:90%;
+                }
+            }
+        }
+
+        .wrap-full-bottom {
+            position: absolute;
+            bottom: 0;
+            justify-content: space-around;
+        }
+        .bottom-15{
+            height: 18%;
+        }
+    }
+</style>

+ 121 - 0
src/views/ppt_manage/newVersion/components/formatPage/FormatTen.vue

@@ -0,0 +1,121 @@
+<template>
+    <div class="total-wrap flex-column" :style="{'pointer-events' :isPreview?'none':'auto'}">
+        <div class="line flex-center">
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(1)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="1" :is="TypeName(1)" :ref="RefName(1)" :index="pageIndex" :position="1"
+                    :item="Item(1)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,1)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(2)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="2" :is="TypeName(2)" :ref="RefName(2)" :index="pageIndex" :position="2"
+                    :item="Item(2)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,2)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(3)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="3" :is="TypeName(3)" :ref="RefName(3)" :index="pageIndex" :position="3"
+                    :item="Item(3)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,3)" />
+            </div>
+        </div>
+        <div class="line flex-center">
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(4)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="4" :is="TypeName(4)" :ref="RefName(4)" :index="pageIndex" :position="4"
+                    :item="Item(4)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,4)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(5)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="5" :is="TypeName(5)" :ref="RefName(5)" :index="pageIndex" :position="5"
+                    :item="Item(5)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,5)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(6)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="6" :is="TypeName(6)" :ref="RefName(6)" :index="pageIndex" :position="6"
+                    :item="Item(6)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,6)" />
+            </div>
+        </div>
+        <div class="wrap-full-bottom bottom-15 flex-center"
+            :style="pageItem.layers&&!isLayerShow()?TypeName(7)==='ChartEl'?'z-index:5':'z-index:3':''">
+            <component :data-position="7" :is="TypeName(7)" :ref="RefName(7)" :index="pageIndex" :position="7"
+                :item="Item(7)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                @getText="getText($event,7)"></component>
+        </div>
+        <!-- 图层编辑模式 -->
+        <div class="layers" :id="`layers_${pageItem.id}`" v-if="isLayerShow()" @click.stop="clickLayer"
+            @contextmenu.stop="showLayerContentMenu">
+            <template v-for="item in pageItem.layers">
+                <component :is="getLayerElName(item)" :key="item.id" :elementInfo="item"
+                    :isActive="item.id===activeLayerEl.id&&!isClickLayer" :isLayerEdit="true"
+                    @click.stop.native="changeActEl(item)" @chooseThis="changeActEl(item)" v-on="$listeners">
+                </component>
+            </template>
+        </div>
+        <!-- 非图层编辑模式 -->
+        <template v-else>
+            <template v-for="item in pageItem.layers">
+                <component :is="getLayerElName(item)" :key="item.id" :elementInfo="item" :isActive="false"
+                    :isLayerEdit="false"></component>
+            </template>
+        </template>
+    </div>
+</template>
+
+<script>
+    import mixin from "./mixins";
+    import {
+        defaultPosition
+    } from "../../utils/config";
+    export default {
+        name: "formatTen",
+        mixins: [mixin],
+        data() {
+            return {
+                modelId: 10,
+                positionInfo: defaultPosition[10]
+            }
+        },
+    };
+</script>
+<style lang="scss">
+.line{
+    .line-item{
+        .el-wrap .chart-wrap{
+            width:90%;
+            height:90%;
+        }
+        .editor-wrap{
+            width:90%;
+            height:90%
+        }
+    }
+}
+</style>
+<style scoped lang="scss">
+    .total-wrap {
+        .line{
+            height:40%;
+            .line-item{
+                width:33%;
+                height:100%;
+                .el-wrap .chart-wrap{
+                    width:90%;
+                    height:90%;
+                }
+            }
+        }
+
+        .wrap-full-bottom {
+            position: absolute;
+            bottom: 0;
+        }
+        .bottom-15{
+            height: 18%;
+        }
+    }
+</style>

+ 115 - 0
src/views/ppt_manage/newVersion/components/formatPage/FormatTwelve.vue

@@ -0,0 +1,115 @@
+<template>
+    <div class="total-wrap flex-column" :style="{'pointer-events' :isPreview?'none':'auto'}">
+        <div class="line flex-center">
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(1)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="1" :is="TypeName(1)" :ref="RefName(1)" :index="pageIndex" :position="1"
+                    :item="Item(1)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,1)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(2)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="2" :is="TypeName(2)" :ref="RefName(2)" :index="pageIndex" :position="2"
+                    :item="Item(2)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,2)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(3)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="3" :is="TypeName(3)" :ref="RefName(3)" :index="pageIndex" :position="3"
+                    :item="Item(3)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,3)" />
+            </div>
+        </div>
+        <div class="line flex-center">
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(4)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="4" :is="TypeName(4)" :ref="RefName(4)" :index="pageIndex" :position="4"
+                    :item="Item(4)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,4)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(5)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="5" :is="TypeName(5)" :ref="RefName(5)" :index="pageIndex" :position="5"
+                    :item="Item(5)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,5)" />
+            </div>
+            <div class="line-item flex-center"
+                :style="pageItem.layers&&!isLayerShow()?TypeName(6)==='ChartEl'?'z-index:5':'z-index:3':''">
+                <component :data-position="6" :is="TypeName(6)" :ref="RefName(6)" :index="pageIndex" :position="6"
+                    :item="Item(6)" @dragstart.native="onDragStart" @dragover.native="onDragOver" @drop.native="onDrop"
+                    @getText="getText($event,6)" />
+            </div>
+        </div>
+        <!-- 图层编辑模式 -->
+        <div class="layers" :id="`layers_${pageItem.id}`" v-if="isLayerShow()" @click.stop="clickLayer"
+            @contextmenu.stop="showLayerContentMenu">
+            <template v-for="item in pageItem.layers">
+                <component :is="getLayerElName(item)" :key="item.id" :elementInfo="item"
+                    :isActive="item.id===activeLayerEl.id&&!isClickLayer" :isLayerEdit="true"
+                    @click.stop.native="changeActEl(item)" @chooseThis="changeActEl(item)" v-on="$listeners">
+                </component>
+            </template>
+        </div>
+        <!-- 非图层编辑模式 -->
+        <template v-else>
+            <template v-for="item in pageItem.layers">
+                <component :is="getLayerElName(item)" :key="item.id" :elementInfo="item" :isActive="false"
+                    :isLayerEdit="false"></component>
+            </template>
+        </template>
+    </div>
+</template>
+
+<script>
+    import mixin from "./mixins";
+    import {
+        defaultPosition
+    } from "../../utils/config";
+    export default {
+        name: "formatTen",
+        mixins: [mixin],
+        data() {
+            return {
+                modelId: 10,
+                positionInfo: defaultPosition[10]
+            }
+        },
+    };
+</script>
+<style lang="scss">
+.line{
+    .line-item{
+        .el-wrap .chart-wrap{
+            width:90%;
+            height:90%;
+        }
+        .editor-wrap{
+            width:90%;
+            height:90%
+        }
+    }
+}
+</style>
+<style scoped lang="scss">
+    .total-wrap {
+        .line{
+            height:48%;
+            .line-item{
+                width:33%;
+                height:100%;
+                .el-wrap .chart-wrap{
+                    width:90%;
+                    height:90%;
+                }
+            }
+        }
+
+        .wrap-full-bottom {
+            position: absolute;
+            bottom: 0;
+        }
+        .bottom-15{
+            height: 18%;
+        }
+    }
+</style>

+ 40 - 0
src/views/ppt_manage/newVersion/components/formatPreview/FormatPreEle.vue

@@ -0,0 +1,40 @@
+<template>
+    <div class="format-pre-wrap flex-center" style="flex-direction: column;">
+      <div class="line flex-center" style="justify-content: space-between;">
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+      </div>
+      <div class="line flex-center" style="justify-content: space-between;">
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+      </div>
+      <div class="line flex-center" style="width:100%;height:30%;">
+        <div class="full text" style="width:97%;height:90%;"></div>
+      </div>
+    </div>
+  </template>
+  
+  <script>
+  export default {
+    name: "formatPreEle",
+    data() {
+      return {};
+    },
+    methods: {},
+  };
+  </script>
+  
+  <style scoped lang="scss">
+  .format-pre-wrap{
+    .line{
+        img{
+            width:40%;
+        }
+    }
+  }
+  </style>
+  

+ 44 - 0
src/views/ppt_manage/newVersion/components/formatPreview/FormatPreTen.vue

@@ -0,0 +1,44 @@
+<template>
+    <div class="format-pre-wrap flex-center" style="flex-direction: column;">
+      <div class="line flex-center" style="justify-content: space-between;">
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+      </div>
+      <div class="line flex-center" style="justify-content: space-between;">
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+      </div>
+      <div class="line flex-center" style="width:100%;height:30%;">
+        <div class="full text" style="width:97%;height:90%;"></div>
+      </div>
+    </div>
+  </template>
+  
+  <script>
+  export default {
+    name: "formatPreTen",
+    data() {
+      return {};
+    },
+    methods: {},
+  };
+  </script>
+  
+  <style scoped lang="scss">
+  .format-pre-wrap{
+    .line{
+        img{
+            width:30%;
+        }
+    }
+  }
+  </style>
+  

+ 41 - 0
src/views/ppt_manage/newVersion/components/formatPreview/FormatPreTwelve.vue

@@ -0,0 +1,41 @@
+<template>
+    <div class="format-pre-wrap flex-center" style="flex-direction: column;">
+      <div class="line flex-center" style="justify-content: space-between;">
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+      </div>
+      <div class="line flex-center" style="justify-content: space-between;">
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+        <img style="object-fit:fill !important;"
+          src="~@/assets/img/ppt_m/format-pic.png" />
+      </div>
+    </div>
+  </template>
+  
+  <script>
+  export default {
+    name: "formatPreTwelve",
+    data() {
+      return {};
+    },
+    methods: {},
+  };
+  </script>
+  
+  <style scoped lang="scss">
+  .format-pre-wrap{
+    .line{
+        img{
+            width:33%;
+        }
+    }
+  }
+  </style>
+  

+ 16 - 2
src/views/ppt_manage/newVersion/pptPublish.vue

@@ -26,7 +26,12 @@
           </div>
           <!-- 内容 -->
           <div class="ppt-item" v-for="(item,index) in pageList" :key="item.id">
-            <div class="title-wrap">
+            <div class="title-wrap"
+            :style="`
+                top:${lineClamp===2?'2%':getStrCount(item.title)<58?'5.5%':'0'};
+                height:${lineClamp===2?'12%':getStrCount(item.title)<58?'7%':'14%'};
+                -webkit-line-clamp:${lineClamp===2?2:3};`" 
+            :class="{'title-ellipsis':getStrCount(item.title)>lineClamp*57}">
               {{item.title}} 
             </div>
             <component
@@ -59,7 +64,7 @@ import Cover from './components/Cover.vue';
 import CustomCover from './components/CustomCover.vue';
 import TransReport from './components/catalog/transReport.vue';
 //import {pageList} from './utils/mock';
-import {countComponentName,pptConfigInit,toTextProps,toJson,svg2Base64,getImgRealSize,calcScale,getShapeOptions,createRandomCode,getTableData,getChartInfo,pptInit,rgbaToHex } from './utils/untils';
+import {countComponentName,pptConfigInit,toTextProps,toJson,svg2Base64,getImgRealSize,calcScale,countStrSize,getShapeOptions,createRandomCode,getTableData,getChartInfo,pptInit,rgbaToHex } from './utils/untils';
 import {marginTop,modelConfig,pptSlideMaster} from './utils/config';
 import pptmixin from '../mixins/pptMixins';
 import mixins from '../mixins/mixins';
@@ -120,7 +125,16 @@ export default {
       this.coefficient = coefficient
     }
   },
+  computed:{
+    lineClamp(){
+        return this.LayoutType===2?2:3
+    },
+  },
   methods: {
+    //计算title的字节数
+    getStrCount(title){
+        return countStrSize(title)
+    },
     async transHandle(){
       //需要校验PPT
       const {result,hintText} = this.checkPPT()

+ 192 - 3
src/views/ppt_manage/newVersion/utils/config.js

@@ -83,6 +83,16 @@ export const formatPre = [{
     },{
       modelId:9,
       text:'上2图+文字'
+    },{
+        modelId:10,
+        text:'上6图+文字'
+    },
+    {
+        modelId:11,
+        text:'上4图+文字'
+    },{
+        modelId:12,
+        text:'上6图'
     }
 ]
 //版式id对应组件名
@@ -95,7 +105,10 @@ export const modelMap = {
     6: 'Six',
     7: 'Seven',
     8: 'Eight',
-    9: 'Nine'
+    9: 'Nine',
+    10:'Ten',
+    11:'Ele',
+    12:'Twelve'
 }
 //版式信息,用于判断图表/文字插入哪个位置
 export const modelInfo = {
@@ -167,7 +180,31 @@ export const modelInfo = {
       elChartNum:2,
       elTextNum:1,
       elTextPosition: 3
-    }
+    },
+    12:{
+        elNum:6,
+        elType:['chart','chart','chart','chart','chart','chart'],
+        positions:[1,2,3,4,5,6],
+        elChartNum:6,
+        elTextNum:0,
+        /* elTextPosition: 7 */
+    },
+    11:{
+        elNum:5,
+        elType:['chart','chart','chart','chart','text'],
+        positions:[1,2,3,4,5],
+        elChartNum:4,
+        elTextNum:1,
+        elTextPosition: 5
+      },
+    10:{
+        elNum:7,
+        elType:['chart','chart','chart','chart','chart','chart','text'],
+        positions:[1,2,3,4,5,6],
+        elChartNum:6,
+        elTextNum:1,
+        elTextPosition: 7
+    },
 }
 
 //给标题预留的位置,单位%
@@ -176,6 +213,7 @@ const titleHeight = 7
 const restHeight = 100 - marginTop
 //版式位置宽高设置,x,y,width,height都是基于整张ppt的百分比
 //百分比的值来自./css/format.scss ->.chart-wrap,.editor-wrap
+//用于发布页生成PPT
 export const modelConfig = [{
         modelId: 1,
         elements: [{
@@ -348,6 +386,132 @@ export const modelConfig = [{
         y:60
       }
     ]
+    },{
+        modelId:12,
+        elements:[{
+            position:1,
+            width:33*0.9,
+            height:(restHeight)*0.48*0.9,
+            x:(33*0.1)/2,
+            y:(restHeight*0.48*0.1)/2
+        },{
+            position:2,
+            width:33*0.9,
+            height:(restHeight)*0.48*0.9,
+            x:(33*0.1)/2+33,
+            y:(restHeight*0.48*0.1)/2
+        },
+        {
+            position:3,
+            width:33*0.9,
+            height:(restHeight)*0.48*0.9,
+            x:(33*0.1)/2+33*2,
+            y:(restHeight*0.48*0.1)/2
+        },
+        {
+            position:4,
+            width:33*0.9,
+            height:(restHeight)*0.48*0.9,
+            x:(33*0.1)/2,
+            y:(restHeight)*0.48
+        },
+        {
+            position:5,
+            width:33*0.9,
+            height:(restHeight)*0.48*0.9,
+            x:(33*0.1)/2+33,
+            y:(restHeight)*0.48
+        },
+        {
+            position:6,
+            width:33*0.9,
+            height:(restHeight)*0.48*0.9,
+            x:(33*0.1)/2+33*2,
+            y:(restHeight)*0.48
+        }]
+    },{
+        modelId:11,
+        elements:[{
+            position:1,
+            width:45*0.9,
+            height:(restHeight)*0.40*0.9,
+            x:(45*0.1)/2,
+            y:(restHeight*0.4*0.1)/2
+        },{
+            position:2,
+            width:45*0.9,
+            height:(restHeight)*0.40*0.9,
+            x:(45*0.1)/2+50,
+            y:(restHeight*0.4*0.1)/2
+        },{
+            position:3,
+            width:45*0.9,
+            height:(restHeight)*0.40*0.9,
+            x:(45*0.1)/2,
+            y:38
+        },{
+            position:4,
+            width:45*0.9,
+            height:(restHeight)*0.40*0.9,
+            x:(45*0.1)/2+50,
+            y:38
+        },{
+            position:5,
+            width:100*0.9,
+            height:(restHeight)*0.18*0.8,
+            x:(100-100*0.9)/2,
+            y:74
+        }]
+    },{
+        modelId:10,
+        elements:[{
+            position:1,
+            width:33*0.9,
+            height:(restHeight)*0.4*0.9,
+            x:(33*0.1)/2,
+            y:(restHeight*0.4*0.1)/2
+        },{
+            position:2,
+            width:33*0.9,
+            height:(restHeight)*0.4*0.9,
+            x:(33*0.1)/2+33,
+            y:(restHeight*0.4*0.1)/2
+        },
+        {
+            position:3,
+            width:33*0.9,
+            height:(restHeight)*0.4*0.9,
+            x:(33*0.1)/2+33*2,
+            y:(restHeight*0.4*0.1)/2
+        },
+        {
+            position:4,
+            width:33*0.9,
+            height:(restHeight)*0.4*0.9,
+            x:(33*0.1)/2,
+            y:38
+        },
+        {
+            position:5,
+            width:33*0.9,
+            height:(restHeight)*0.4*0.9,
+            x:(33*0.1)/2+33,
+            y:38
+        },
+        {
+            position:6,
+            width:33*0.9,
+            height:(restHeight)*0.4*0.9,
+            x:(33*0.1)/2+33*2,
+            y:38
+        },
+        {
+            position:7,
+            width:100*0.9,
+            height:(restHeight)*0.18*0.8,
+            x:(100-100*0.9)/2,
+            y:74
+        }]
     }
 ]
 //ppt母版
@@ -579,6 +743,7 @@ export const BaseTextShape = {
   richContent:''
 }
 //默认情况下,版式内部位置对应的组件元素
+//用于版式渲染,版式内切换元素位置
 export const defaultPosition = {
   1:{//modelId
     1:{type:'chart'},//position
@@ -619,7 +784,31 @@ export const defaultPosition = {
     1:{type:'chart'},
     2:{type:'chart'},
     3:{type:'text'}
-  }
+  },
+  12:{
+    1:{type:'chart'},
+    2:{type:'chart'},
+    3:{type:'chart'},
+    4:{type:'chart'},
+    5:{type:'chart'},
+    6:{type:'chart'},
+  },
+  11:{
+    1:{type:'chart'},
+    2:{type:'chart'},
+    3:{type:'chart'},
+    4:{type:'chart'},
+    5:{type:'text'},
+  },
+  10:{
+    1:{type:'chart'},
+    2:{type:'chart'},
+    3:{type:'chart'},
+    4:{type:'chart'},
+    5:{type:'chart'},
+    6:{type:'chart'},
+    7:{type:'text'}
+  },
 }
 //画笔工具栏
 export const boardTool = [

+ 47 - 4
src/views/ppt_manage/newVersion/utils/untils.js

@@ -140,7 +140,7 @@ export const toTextProps = (json) => {
       if ('tagName' in item && item.tagName === 'br') {
         slices.push({ text: '', options: { breakLine: true } })
       } else if ('content' in item) {
-            const transStr = /(&lt;|&gt;|&ldquo;|&rdquo;|&amp;|&lsquo;|&rsquo;|&mdash;|&ge;|&le;|&middot;)/g
+            const transStr = /(&lt;|&gt;|&ldquo;|&rdquo;|&amp;|&lsquo;|&rsquo;|&mdash;|&ge;|&le;|&middot;|&oslash;|&Oslash;|&empty;)/g
             const text = item.content.replace(/\n/g, '').replace(/&nbsp;/g, ' ').replace(transStr, replacer)
             const options = {}
 
@@ -205,6 +205,7 @@ export const toTextProps = (json) => {
   return slices
 }
 //将text中被转义的字符转义回来,如:a<b 在富文本内会被转义成 a&lt;b
+//https://www.cnblogs.com/tiancixiong/p/13581746.html
 const replacer = (_, p1) => {
     return {
         "&lt;": "<",
@@ -217,7 +218,10 @@ const replacer = (_, p1) => {
         "&mdash;":'——',
         "&ge;":'≥',
         "&le;":'≤',
-        "&middot;":'·'
+        "&middot;":'·',
+        "&oslash;":'ø',
+        "&Oslash;":'Ø',
+        "&empty;":'∅'
     } [p1]
 }
 //根据字符串的字节长,在指定位置换行
@@ -292,6 +296,7 @@ export const changeCatalogArr = (arr)=>{
 }
 //计算各个版式下,文本框占据的真实宽度
 //基准:编辑页ppt-item的最大宽高:w:900px;h:630
+//用于transform:scale 文本元素,如果该版式没有文本框,可以直接给一个空数组
 export const getTextContentSize = (model,position)=>{
     const modelMapWidth = {
         1:{
@@ -330,7 +335,26 @@ export const getTextContentSize = (model,position)=>{
           1:[1,1,0.5,0.9],
           2:[1,1,0.5,0.9],
           3:[1,1,0.9]
-        }
+        },
+        12:{
+            1:[],2:[],3:[],4:[],5:[],6:[],7:[],
+        },
+        11:{
+            1:[1,1,0.45,1,0.9],
+            2:[1,1,0.45,1,0.9],
+            3:[1,1,0.45,1,0.9],
+            4:[1,1,0.45,1,0.9],
+            5:[1,1,0.9],
+        },
+        10:{
+            1:[1,1,0.33,1,0.9],
+            2:[1,1,0.33,1,0.9],
+            3:[1,1,0.33,1,0.9],
+            4:[1,1,0.33,1,0.9],
+            5:[1,1,0.33,1,0.9],
+            6:[1,1,0.33,1,0.9],
+            7:[1,1,0.9],
+        },
     }
     const modelMapHeight = {
         1:{
@@ -365,7 +389,26 @@ export const getTextContentSize = (model,position)=>{
           1:[0.86,0.7,1,0.9],
           2:[0.86,0.7,1,0.9],
           3:[0.86,0.3,0.8]
-        }
+        },
+        12:{
+            1:[],2:[],3:[],4:[],5:[],6:[],
+        },
+        11:{
+            1:[0.86,0.4,1,0.9],
+            2:[0.86,0.4,1,0.9],
+            3:[0.86,0.4,1,0.9],
+            4:[0.86,0.4,1,0.9],
+            5:[0.86,0.18,0.8],
+        },
+        10:{
+            1:[0.86,0.4,1,0.9],
+            2:[0.86,0.4,1,0.9],
+            3:[0.86,0.4,1,0.9],
+            4:[0.86,0.4,1,0.9],
+            5:[0.86,0.4,1,0.9],
+            6:[0.86,0.4,1,0.9],
+            7:[0.86,0.18,0.8],
+        },
     }
     const baseWidth=900,baseHeight=630
     const width = modelMapWidth[model][position].reduce((pre,curr)=>{

+ 259 - 0
src/views/system_manage/components/refreshConfig.vue

@@ -0,0 +1,259 @@
+<template>
+    <!-- 刷新配置 + 添加删除-->
+    <div class="refresh-config-wrap">
+        <!-- form -->
+        <el-form :model="dynamicForm" ref="dynamicForm" label-width="110px" class="dynamic-form">
+            <div class="group" v-for="(item,index) in dynamicForm.configList" :key="item.key">
+                <div class="delete btn-box" @click="deleteSetting(index)"
+                    v-if="index!==0"><i class="el-icon-delete"></i>删除</div>
+                <el-form-item label="刷新频率" class="item">
+                    <el-form-item :prop="`configList[${index}].frequency`" :rules="{required:true,message:'请选择刷新频率',trigger: 'blur'}">
+                        <el-select v-model="item.frequency">
+                            <el-option v-for="i in frequencyType" :key="i.key" 
+                                :label="i.label" :value="i.key"/>
+                        </el-select>
+                    </el-form-item>
+                    
+                    <!-- 每周 -->
+                    <el-form-item :prop="`configList[${index}].frequency_week`" v-if="item.frequency.includes('周')" :rules="{required:true,message:'请选择刷新频率',trigger: 'blur'}">
+                        <el-select v-model="item.frequency_week" class="full-input" key="week">
+                            <el-option v-for="i in weekList" :key="i.key" 
+                                :label="i.label" :value="i.key"/>
+                        </el-select>
+                    </el-form-item>
+                    
+                    <!-- 每旬、月、季、半年、年 -->
+                    <el-form-item :prop="`configList[${index}].frequency_last`" v-if="!item.frequency.includes('日')&&!item.frequency.includes('周')"
+                        :rules="{required:true,message:'请选择刷新频率',trigger: 'blur'}">
+                        <el-select v-model="item.frequency_last" :key="item.key" key="option">
+                            <el-option v-for="i in timeOptionList" :key="i.key" 
+                                :label="i.label" :value="i.key"/>
+                        </el-select>
+                    </el-form-item>
+                    <el-form-item :prop="`configList[${index}].frequency_n`" v-if="item.frequency_last==='n'&&!item.frequency.includes('日')&&!item.frequency.includes('周')"
+                        :rules="{required:true,message:'请选择刷新频率',trigger: 'blur'}">
+                        <el-input v-model="item.frequency_n" type="number" :min="1" :max="n_limit_map[item.frequency]||10">
+                            <template slot="prefix">N=</template>
+                        </el-input>
+                    </el-form-item>
+                </el-form-item>
+                <el-form-item class="item" label="时间">
+                    <el-form-item :prop="`configList[${index}].time`" :rules="{required:true,message:'请选择刷新时间',trigger: 'blur'}">
+                        <el-select v-model="item.time" class="full-input" key="single">
+                            <el-option v-for="i in timeList" :key="i" 
+                                :label="i" :value="i"/>
+                        </el-select>
+                    </el-form-item>
+                </el-form-item>
+                <el-form-item v-if="Source!==11"
+                    :prop="`configList[${index}].num`" label="刷新单元格数" class="item" :rules="{required:true,message:'请输入刷新单元格数',trigger: 'blur'}">
+                    <el-input v-model="item.num" type="number"></el-input>
+                    <el-checkbox v-model="item.isAll">全部刷新</el-checkbox>
+                </el-form-item>
+                <div class="line"></div>
+                <div class="add btn-box" @click="addSetting"
+                    v-if="index===dynamicForm.configList.length-1&&index<maxSetting-1">
+                    <i class="el-icon-circle-plus-outline"></i>添加刷新时间</div>
+            </div>
+        </el-form>
+    </div>
+</template>
+
+<script>
+const config = {
+    frequency:'',//刷新频率:
+    frequency_week:'',//频率为每周时,选择
+    frequency_last:'',//第N天或最后一天
+    frequency_n:1,
+    time:'',//时间
+    num:7,//刷新单元格数
+    isAll:false,//全部刷新
+}
+export default {
+    props:{
+        Source:{
+            type:Number,
+        },
+        defaultForm:{
+            type:Object
+        }
+    },
+    data() {
+        return {
+            maxSetting:5,//可设置的刷新时间数量
+            dynamicForm:{
+                configList:[{
+                        ...config,
+                        key:0
+                    }
+                ]
+            },
+            frequencyType:[
+                {label:'每自然日',key:'每自然日'},
+                {label:'每交易日',key:'每交易日'},
+                {label:'每周',key:'每周'},
+                {label:'每旬',key:'每旬'},
+                {label:'每月',key:'每月'},
+                {label:'每季',key:'每季'},
+                {label:'每半年',key:'每半年'},
+                {label:'每年',key:'每年'},
+            ],
+            //每周,可多选
+            weekList:[
+                {key:1,label:'周一'},
+                {key:2,label:'周二'},
+                {key:3,label:'周三'},
+                {key:4,label:'周四'},
+                {key:5,label:'周五'},
+                {key:6,label:'周六'},
+                {key:7,label:'周日'}
+            ],
+            //每旬、月、季、半年、年
+            timeOptionList:[
+                {label:'第N天',key:'n'},
+                {label:'最后一天',key:'last'}
+            ],
+            //时间选项,仅整点
+            timeList:[
+                '00:00','00:30','01:00','01:30','02:00','02:30','03:00','03:30',
+                '04:00','04:30','05:00','05:30','06:00','06:30','07:00','07:30',
+                '08:00','08:30','09:00','09:30','10:00','10:30','11:00','11:30',
+                '12:00','12:30','13:00','13:30','14:00','14:30','15:00','15:30',
+                '16:00','16:30','17:00','17:30','18:00','18:30','19:00','19:30',
+                '20:00','20:30','21:00','21:30','22:00','22:30','23:00','23:30'
+            ],
+            //N 范围 1-~
+            n_limit_map:{
+                '每旬':11,
+                '每月':31,
+                '每季':92,
+                '每半年':184,
+                '每年':365
+            },
+        };
+    },
+    watch:{
+        defaultForm:{
+            handler(newVal){
+                this.dynamicForm = this.formatForm(newVal)
+            },
+            deep:true
+        }
+    },
+    methods: {
+        addSetting(){
+            this.dynamicForm.configList.push({
+                ...config,
+                key:Date.now()
+            })
+        },
+        deleteSetting(index){
+            this.dynamicForm.configList.splice(index,1)
+        },
+        //将接口数据转换成form支持的格式
+        formatForm(form){
+            const {configList=[]} = form
+            if(!configList.length){
+                return {
+                    configList:[{
+                        ...config,
+                        key:0
+                    }]
+                }
+            }
+            const formatList = configList.map((item)=>{
+                let isOther = false
+                if(!item.RefreshFrequency.includes("周")&&!item.RefreshFrequency.includes("日")){
+                    isOther = true
+                }
+                return {
+                    frequency:item.RefreshFrequency,
+                    frequency_week:item.RefreshFrequency.includes("周")?item.RefreshFrequencyDay:'',
+                    frequency_last:isOther?(item.RefreshFrequencyDay===0?'last':'n'):'',
+                    frequency_n:item.RefreshFrequencyDay,
+                    time:item.RefreshTime,
+                    num:item.RefreshDataNum,
+                    isAll:Boolean(item.RefreshAllData)
+                }
+            })
+            return {
+                configList:formatList
+            }
+        },
+        //将数据转换成接口形式
+        getFormList(){
+            const list = this.dynamicForm.configList.map((item)=>{
+                //RefreshFrequencyDay: 每自然日、每交易日传0;每周传1~7;其他传n,最后一天n=0
+                let FrequencyDay = 0
+                if(item.frequency.includes("日")){
+                    FrequencyDay = 0
+                }else if(item.frequency.includes("周")){
+                    FrequencyDay = item.frequency_week
+                }else{
+                    FrequencyDay = item.frequency_last==='last'?0:item.frequency_n
+                }
+                return {
+                    RefreshFrequency:item.frequency,
+                    RefreshFrequencyDay:Number(FrequencyDay),
+                    RefreshTime:item.time,
+                    RefreshAllData:Number(item.isAll),
+                    RefreshDataNum:Number(item.num),
+                }
+            })
+            return list
+        }
+    },
+};
+</script>
+
+<style lang="scss">
+.refresh-config-wrap{
+        .dynamic-form{
+            .group{
+                position:relative;
+                padding: 30px 0 8px 0;
+                /* border-bottom: 1px solid #EBEFF6; */
+                &:first-child{
+                    padding-top: 0;
+                }
+                .line{
+                    height:1px;
+                    background-color: #EBEFF6;
+                }
+                .btn-box{
+                    cursor: pointer;
+                    i{
+                        margin-right: 8px;
+                        font-size: 16px;
+                    }
+                    &.add{
+                        display:inline-block;
+                        margin-top: 20px;
+                        color:#0052D9;
+                    }
+                    &.delete{
+                        position: absolute;
+                        right:10px;
+                        top:10px;
+                        color:#AD352F;
+                    }
+                }
+                .item{
+                    .el-input{
+                        width:110px;
+                    }
+                    .full-input{
+                        width: 100%;
+                        .el-input{
+                            width:100%;
+                        }
+                    }
+                    >.el-form-item__content{
+                        display: flex;
+                        gap:10px;
+                    }
+                }
+            }
+        }
+}
+</style>

+ 732 - 0
src/views/system_manage/dataRefreshSetting.vue

@@ -0,0 +1,732 @@
+<template>
+    <!-- 数据源刷新设置 -->
+    <div class="data-refresh-setting-wrap">
+        <div class="top-box">
+            <div class="select-box">
+                <span>选择数据源</span>
+                <el-select placeholder="请选择数据源" v-model="Source" @change="handleSourceChange">
+                    <el-option v-for="item in SourceList" :key="item.Source" 
+                    :label="item.SourceName" :value="item.Source"/>
+                </el-select>
+                <el-select placeholder="请选择数据源" v-model="SubSource" v-if="SubSourceList.length" @change="handleSubSourceChange">
+                    <el-option v-for="item in SubSourceList" :key="item.Source" 
+                    :label="item.SubSourceName" :value="item.SubSource"/>
+                </el-select>
+                <el-button type="primary" @click="showDialog(true)"
+                    v-permission="permissionBtn.sysDepartPermission.refresh_default"
+                >默认刷新时间</el-button>
+            </div>
+            
+            <el-input placeholder="指标ID/指标名称" prefix-icon="el-icon-search" clearable
+                v-model="selectOption.keyWord" @input="selectOptionChange('keyWord')"
+                v-if="![34,11].includes(Source)&&Source"></el-input>
+            
+        </div>
+        <div class="table-box" v-if="hasSelectOption">
+            <div class="table-select" v-loading="selectOptionLoading">
+                <div class="select-list">
+                    <el-select placeholder="终端编码" no-match-text="请选择完整数据源" clearable
+                        v-model="selectOption.terminalCode" @change="selectOptionChange('terminalCode')">
+                        <el-option v-for="i in terminalCodeList" :key="i.TerminalCode"
+                            :label="i.Name" :value="i.TerminalCode"/>
+                    </el-select>
+                    <el-cascader placeholder="ETA指标库分类" no-match-text="请选择完整数据源" clearable
+                        v-model="selectOption.classify" @change="selectOptionChange('classify')"
+                        :options="edbClassifyList" 
+                        :show-all-levels="false"
+                        collapse-tags
+                        :props="{
+                            emitPath:true,
+                            value:'ClassifyId',
+                            label:'ClassifyName',
+                            children:'Children',
+                            multiple:true
+                        }" />
+                    <el-cascader
+                        placeholder="创建人" no-match-text="请选择完整数据源" style="height: 40px;"
+                        v-model="selectOption.user" @change="selectOptionChange('user')"
+                        :options="userList"
+                        :props="{
+                            value: 'ItemId',
+                            label: 'ItemName',
+                            children: 'Children',
+                            emitPath: false,
+                            multiple:true,
+                        }"
+                        collapse-tags
+                        :show-all-levels="false"
+                        clearable
+                        filterable 
+                    />
+                    <el-select placeholder="频度" v-model="selectOption.frequency" @change="selectOptionChange('frequency')" multiple collapse-tags clearable>
+                        <el-option v-for="i in frequencyList" :key="i"
+                            :label="i" :value="i"
+                        />
+                    </el-select>
+                    <el-select placeholder="刷新状态" v-model="selectOption.state" @change="selectOptionChange('state')" clearable>
+                        <el-option label="启用刷新" value="启用"/>
+                        <el-option label="暂停刷新" value="暂停"/>
+                    </el-select>
+                </div>
+                <div class="select-other">
+                    <el-checkbox :indeterminate="isIndeterminate" v-model="isCheckAll" @change="listCheckAllChange">列表全选</el-checkbox>
+                    <el-button type="primary" @click="showDialog(false)"
+                        v-permission="permissionBtn.sysDepartPermission.refresh_time"
+                        :disabled="!tableData.length"
+                    >设置刷新时间</el-button>
+                    <el-button type="primary" @click="isSetStateDialogShow=true"
+                        v-permission="permissionBtn.sysDepartPermission.refresh_state"
+                        :disabled="!tableData.length"
+                    >设置刷新状态</el-button>
+                </div>
+            </div>
+            <el-table :data="tableData" border
+                ref="edbDataRef"
+                @selection-change="selectionChange"
+                @select="selectHandle" 
+                @select-all="selectAllHandle"
+                @sort-change="handleSortChange"
+                >
+                <!-- 多选 -->
+                <el-table-column
+                    align="center"
+                    type="selection"
+                    width="55">
+                </el-table-column>
+                <el-table-column v-for="column in columns" :key="column.key"
+                    :prop="column.key"
+                    :label="column.label"
+                    :min-width="column.minWidth"
+                    :sortable="column.sortable?column.sortable:false"
+                    align="center"
+                    >
+                    <template slot-scope="{row}">
+                        <span v-if="column.key==='IsStop'">
+                            {{row.IsStop?'暂停刷新':'启用刷新'}}
+                        </span>
+                        <span v-else>
+                            {{row[column.key]}}
+                        </span>
+                    </template>
+                </el-table-column>
+            </el-table>
+            <el-pagination 
+                :current-page="currentPage"
+                :page-size="pageSize"
+                :total="total"
+                @current-change="handleCurrentChange"
+            />
+        </div>
+        <!-- 默认刷新时间,设置刷新时间 -->
+        <el-dialog custom-class="refresh-setting-dialog"
+            :title="(isDefault?'默认':'设置')+'刷新时间'"
+            :visible.sync="isSetTimeDialogShow"
+            :close-on-click-modal="false"
+            :modal-append-to-body="false"
+            @close="isSetTimeDialogShow=false"
+            width="578px"
+            top="5vh"
+            v-dialogDrag
+            center
+        >
+            <div class="dialog-container" v-loading="defaultDialogLoading">
+                <!-- 默认刷新时间设置数据频度 -->
+                <div class="default-box" v-if="isDefault&&Source!==11">
+                    <label style="display: block;width:88px;text-align:right;padding-right: 12px;">数据频度</label>
+                    <el-select style="margin-left: 10px;" v-model="defaultFrequency" @change="handleDefaultChange">
+                        <el-option v-for="i in frequencyList" :key="i"
+                            :label="i" :value="i"
+                        />
+                    </el-select>
+                </div>
+                <!-- 刷新配置 -->
+                <div class="refresh-box">
+                    <RefreshConfig
+                        ref="refreshconfig"
+                        :Source="Source"
+                        :defaultForm="defaultForm"
+                    ></RefreshConfig>
+                </div>
+                
+            </div>
+            <!-- 弹窗按钮 -->
+            <div class="dialog-btn">
+                <el-button type="primary" plain @click="isSetTimeDialogShow=false">取消</el-button>
+                <el-button type="primary" @click="handleSetRefreshTime">确定</el-button>
+            </div>
+        </el-dialog>
+        <!-- 设置刷新状态 -->
+        <el-dialog custom-class="refresh-setting-dialog"
+            title="设置刷新状态"
+            :visible.sync="isSetStateDialogShow"
+            :close-on-click-modal="false"
+            :modal-append-to-body="false"
+            @close="isSetStateDialogShow=false"
+            width="578px"
+            top="5vh"
+            v-dialogDrag
+            center
+        >
+            <div class="dialog-container" style="text-align: center;margin:60px 0;">
+                <el-radio label="暂停" v-model="isState">暂停刷新</el-radio>
+                <el-radio label="启用" v-model="isState">启用刷新</el-radio>
+            </div>
+            <!-- 弹窗按钮 -->
+            <div class="dialog-btn">
+                <el-button type="primary" plain @click="isSetStateDialogShow=false">取消</el-button>
+                <el-button type="primary" @click="setRefreshStatus">确定</el-button>
+            </div>
+        </el-dialog>
+    </div>
+</template>
+
+<script>
+import RefreshConfig from './components/refreshConfig.vue';
+import {dataRefreshInterface,dataAuthInterface} from '@/api/modules/dataApi.js';
+export default {
+    components: { RefreshConfig },
+    data() {
+        return {
+            Source:'',
+            SourceList:[],
+            SubSource:'',
+            SubSourceList:[],
+
+            frequencyList:['日度','周度','旬度','月度','季度','半年度','年度'],
+            terminalCodeList:[],
+            edbClassifyList:[],
+            userList:[],
+
+            selectOption:{
+                frequency:'',//频度
+                user:'',//创建人
+                classify:'',//分类
+                state:'',//状态
+                terminalCode:'',//终端编码
+                keyWord:'',//关键字
+                sortType:'',//升序降序
+                sortParam:'',//排序字段
+            },
+            hasSelectOption:false,
+            selectOptionLoading:false,
+
+            columns: [
+                {key: 'IndexCode',label: '指标编码'},
+                {key: 'IndexName',label: '指标全称',minWidth:150},
+                {key: 'EndDate',label: '最新日期',sortable:'custom'},
+                {key: 'EndValue',label: '最新值'},
+                {key: 'SysUserRealName',label: '创建人'}, 
+                {key: 'Frequency',label: '频度'},
+                {key: 'RefreshTime',label: '刷新时间',minWidth:150},
+                {key: 'IsStop',label: '刷新状态'}
+            ],
+            tableData: [],
+            tableDataIds:[],
+            pageSize:10,
+            currentPage:1,
+            total:0,
+
+            isSetTimeDialogShow: false,//设置刷新时间弹窗
+            defaultDialogLoading:false,//可能需要获取默认设置,增加loading
+            isDefault:false,//是否是默认刷新时间
+            defaultForm:{},//默认刷新时间的配置
+            defaultFrequency:'日度',//默认刷新时间的频率
+
+            isSetStateDialogShow:false,//设置刷新状态弹窗
+            isState:'启用',//启用刷新or暂停刷新
+            //全部全选
+            isIndeterminate:false,
+            isCheckAll:false,
+            isSelectAll:false,//为true时,selectList是剔除的指标,为false时selectList是已选择的指标
+            //已选择/已剔除的指标id
+            selectList:[],//监听table的select-all select
+            selectionReactCancel:false,
+        };
+    },
+    methods: {
+        //展示刷新时间弹窗
+        showDialog(isDefault){
+            this.isDefault = isDefault
+            this.isSetTimeDialogShow = true
+            if(isDefault){
+                //判断数据源是否选择
+                if(!this.Source){
+                    this.$message.warning("请选择数据源")
+                    return
+                }
+                /* if(this.SubSourceList.length&&!this.SubSource){
+                    this.$message.warning("请选择完整数据源")
+                    return
+                } */
+                //SMM不带频度
+                if(this.Source===11){
+                    this.defaultFrequency=''
+                }else{
+                    this.defaultFrequency = '日度'
+                }
+                this.handleDefaultChange()
+            }else{
+                //单独设置指标,需判断指标是否为单个
+                if((this.total===1&&!this.selectList.length)||(!this.isSelectAll&&this.selectList.length===1)){
+                    //单个则回显刷新时间
+                    this.getEdbRefreshDetail()
+                }else{
+                    this.defaultForm={}
+                }
+                
+            }
+        },
+        //获取对应频度下的默认刷新时间
+        handleDefaultChange(){
+            this.defaultDialogLoading = true
+            dataRefreshInterface.getDefaultConfig({
+                Frequency:this.defaultFrequency,
+                Source:Number(this.Source),
+                SubSource:Number(this.SubSource)
+            }).then(res=>{
+                this.defaultDialogLoading = false
+                if(res.Ret!==200) return 
+                let configList = res.Data||[]
+                configList = configList.map((item,index)=>{
+                    return {
+                        ...item,
+                        key:index
+                    }
+                })
+                this.defaultForm = {
+                    configList
+                }
+            })
+        },
+        //获取单个指标的刷新时间
+        getEdbRefreshDetail(){
+            this.defaultDialogLoading = true
+            let EdbInfoId = 0
+            if(this.total===1){
+                EdbInfoId = this.tableData[0].EdbInfoId
+            }else{
+                EdbInfoId = this.selectList[0]
+            }
+            dataRefreshInterface.getSimgleEdbRefreshTime({
+                EdbInfoId,
+                Source:Number(this.Source),
+                SubSource:Number(this.SubSource)
+            }).then(res=>{
+                this.defaultDialogLoading = false
+                if(res.Ret!==200) return 
+                let configList = res.Data||[]
+                configList = configList.map((item,index)=>{
+                    return {
+                        ...item,
+                        key:index
+                    }
+                })
+                this.defaultForm = {
+                    configList
+                }
+            })
+        },
+        //获取数据源列表
+        getSourceList(){
+            dataRefreshInterface.getDataSourceList().then(res=>{
+                if(res.Ret!==200) return 
+                this.SourceList = res.Data||[]
+            })
+        },
+        //一级数据源改变时,二级数据源和筛选项也重新赋值
+        handleSourceChange(){
+            const source = this.SourceList.find(i=>i.Source===this.Source)||{Child:[]}
+            this.SubSourceList = source.Child
+            this.SubSource=''
+            this.hasSelectOption = ![34,11].includes(this.Source)
+            if(this.hasSelectOption){
+                this.resetSelect()
+                this.tableData = []
+            }
+            //如果没有二级数据源,则请求表格筛选项数据;钢联化工,SMM没有筛选项数据
+            if(!this.SubSourceList.length&&this.hasSelectOption){
+                this.getSelectOption()
+                this.selectOptionChange()
+            }
+            //如果有二级数据源,默认选中第一个
+            if(this.SubSourceList.length){
+                this.SubSource = this.SubSourceList[0].SubSource
+                this.handleSubSourceChange()
+            }
+        },
+        handleSubSourceChange(){
+            this.getSelectOption()
+            this.selectOptionChange()
+        },
+        //获取终端编码列表
+        async getTerminalCodeList(){
+            if(!this.Source) return 
+            const res = await dataRefreshInterface.getTerminalList({
+                Source:Number(this.Source)
+            })
+            if(res.Ret!==200) return 
+            this.terminalCodeList = res.Data?res.Data.List||[]:[]
+        },
+        //获取分类列表
+        async getClassifyList(){
+            if(!this.Source) return 
+            const res = await dataRefreshInterface.getClassifyList({
+                Source:Number(this.Source)
+            })
+            if(res.Ret!==200) return 
+            this.edbClassifyList = res.Data||[]
+        },
+        //获取用户列表
+        getUserList() {
+            dataAuthInterface.userSearch({
+                KeyWord: ''
+            }).then(res => {
+                if(res.Ret !== 200) return 
+                this.userList = res.Data||[]
+            })
+        },
+        async getSelectOption(){
+            this.selectOptionLoading = true
+            //获取终端编码列表
+            await this.getClassifyList()
+            //获取分类列表
+            await this.getTerminalCodeList()
+            this.selectOptionLoading = false
+        },
+        //切换数据源时重置表格选项
+        resetSelect(){
+            this.terminalCodeList=[]
+            this.edbClassifyList = []
+            this.selectOption = {
+                frequency:'',
+                user:'',
+                classify:'',
+                state:'',
+                terminalCode:''
+            }
+            this.selectList=[]
+        },
+        //表格筛选项改变时触发
+        selectOptionChange(type){
+            this.currentPage = 1
+            this.getTableData('optionChange')
+        },
+        handleCurrentChange(page){
+            this.currentPage = page
+            this.getTableData()
+        },
+        async getTableData(type){
+            const {frequency,user,classify,state,terminalCode,keyWord,sortParam,sortType} = this.selectOption
+            const classifyArr = Array.isArray(classify)?classify:[]
+            const classifyId = [...new Set(classifyArr.join(',').split(','))]
+            const res = await dataRefreshInterface.getEdbTableList({
+                Source:Number(this.Source),
+                SubSource:Number(this.SubSource),
+                ClassifyId:classifyId.join(','),
+                TerminalCode:terminalCode,
+                SysUserId:Array.isArray(user)?user.join(','):user,
+                Frequency:Array.isArray(frequency)?frequency.join(','):frequency,
+                Keyword:keyWord,
+                Status:state,
+                SortParam:sortParam,
+                SortType:sortType,
+                PageSize:Number(this.pageSize),
+                CurrentIndex:Number(this.currentPage)
+            })
+            if(res.Ret!==200) return 
+            const {Paging,List} = res.Data||{}
+            this.tableData = List||[]
+            this.total = Paging.Totals||0
+            if(this.tableData.length>0){
+              this.tableDataIds = this.tableData.map(it => it.EdbInfoId)
+            }else{
+              this.tableDataIds = []
+            }
+            if(type==='optionChange'){
+                //如果是表格筛选项改变导致重新请求数据
+                //数据获取完成后,列表全选,表格全选
+                this.selectList = []
+                this.listCheckAllChange(true)
+            }else{
+                //若不是,数据获取完成后,查询列表全选的值
+                //若当页有数据在selectList内,则勾选/剔除
+                this.adjustSelection()
+            }
+        },
+        //勾选/取消勾选表格项
+        adjustSelection(){
+            this.selectionReactCancel=true
+            if(!this.isSelectAll){
+                this.selectList.map(it =>{
+                    let row = this.tableData.find(da => da.EdbInfoId==it)
+                    if(row){
+                        setTimeout(()=>{
+                            this.$refs.edbDataRef.toggleRowSelection(row,true)
+                        },10)
+                    }
+                })
+            }else{
+                this.$refs.edbDataRef && this.$refs.edbDataRef.clearSelection()
+                this.$refs.edbDataRef &&this.$refs.edbDataRef.toggleAllSelection()
+                this.selectList.map(it =>{
+                    let row = this.tableData.find(da => da.EdbInfoId==it)
+                    if(row){
+                        setTimeout(()=>{
+                            this.$refs.edbDataRef.toggleRowSelection(row,false)
+                        },50)
+                    }
+                })
+            }
+            setTimeout(()=>{
+                this.selectionReactCancel=false
+            },50)
+        },
+        //列表全选改变
+        listCheckAllChange(value){
+            this.selectList = []
+            this.isSelectAll = value
+            this.$refs.edbDataRef && this.$refs.edbDataRef.clearSelection()
+            if(value){
+                this.$refs.edbDataRef && this.$refs.edbDataRef.toggleAllSelection()
+            }
+        },
+        selectionChange(selection){
+            if(this.selectionReactCancel) return 
+            // selectAllHandle的触发在selectionChange后面,将selectionChange的逻辑延迟一下
+            setTimeout(()=>{
+                // 去重
+                let duplicateArr = Array.from(new Set(this.selectList))
+                //isSelectAll为true时,selectList表示需要剔除的项
+                //isSelectAll为false时,selectList表示需要勾选的项
+                //全选
+                if((duplicateArr.length == this.total && (!this.isSelectAll))|| (duplicateArr.length == 0 && this.isSelectAll)){
+                    this.isCheckAll = true
+                    this.isIndeterminate=false
+                //全不选
+                }else if((duplicateArr.length == 0 && (!this.isSelectAll))|| (duplicateArr.length == this.total && this.isSelectAll)){
+                    this.isCheckAll = false
+                    this.isIndeterminate=false
+                //半选
+                }else{
+                    this.isCheckAll = false
+                    this.isIndeterminate=true
+                }
+            },1)
+        },
+        selectHandle(selection,row){
+            if(this.selectionReactCancel) return 
+            let check = false; 
+            if(selection.some(it => it.EdbInfoId == row.EdbInfoId)){
+                // 勾选
+                if(this.isSelectAll){
+                    check=false
+                }else{
+                    check=true
+                }
+            }else{
+                // 取消勾选
+                if(this.isSelectAll){
+                    check=true
+                }else{
+                    check=false
+                }
+            }
+            if(check){
+                this.selectList.push(row.EdbInfoId)
+                }else{
+                this.selectList=this.selectList.filter(it => it!=row.EdbInfoId)
+            }
+        },
+        selectAllHandle(selection){
+            if(this.selectionReactCancel) return 
+            let check = false; 
+            if(selection && selection.length>0){
+                // 全选
+                if(this.isSelectAll){
+                    check=false
+                }else{
+                    check=true
+                }
+            }else{
+                // 全不选
+                if(this.isSelectAll){
+                    check=true
+                }else{
+                    check=false
+                }
+            }
+            if(check){
+                this.selectList =  [...this.selectList,...this.tableDataIds]
+            }else{
+                this.selectList = this.selectList.filter(it => !this.tableDataIds.includes(it))
+            }
+        },
+        //设置刷新时间
+        async handleSetRefreshTime(){
+            //校验表格
+            try{
+                await this.$refs.refreshconfig.$refs.dynamicForm.validate()
+            }catch(e){
+                console.log(e)
+                return
+            }
+            //转换数据格式
+            const list = this.$refs.refreshconfig.getFormList()
+            //判断是否是默认时间,走不同接口
+            if(this.isDefault){
+                this.setDefaultTime(list)
+            }else{
+                this.setRefreshTime(list)
+            }
+        },
+        setRefreshTime(list){
+            const {frequency,user,classify,state,terminalCode,keyWord} = this.selectOption
+            const classifyArr = Array.isArray(classify)?classify:[]
+            const classifyId = [...new Set(classifyArr.join(',').split(','))]
+            dataRefreshInterface.setRefreshTime({
+                Source:Number(this.Source),
+                SubSource:Number(this.SubSource),
+                ClassifyId:classifyId.join(','),
+                TerminalCode:terminalCode,
+                SysUserId:Array.isArray(user)?user.join(','):user,
+                Frequency:Array.isArray(frequency)?frequency.join(','):frequency,
+                Keyword:keyWord,
+                Status:state,
+                IsSelectAll:this.isSelectAll,
+                EdbSelectIdList:this.selectList,
+                List:list
+            }).then(res=>{
+                if(res.Ret!==200) return
+                this.$message.success("设置刷新时间成功")
+                this.selectOptionChange()
+                this.isSetTimeDialogShow = false
+            })
+        },
+        setDefaultTime(list){
+            dataRefreshInterface.setDefaultTime({
+                Source:Number(this.Source),
+                SubSource:Number(this.SubSource),
+                Frequency:this.defaultFrequency,
+                List:list
+            }).then(res=>{
+                if(res.Ret!==200) return 
+                this.$message.success("设置默认刷新时间成功")
+                this.isSetTimeDialogShow = false
+            })
+        },
+        setRefreshStatus(){
+            const {frequency,user,classify,state,terminalCode,keyWord} = this.selectOption
+            const classifyArr = Array.isArray(classify)?classify:[]
+            const classifyId = [...new Set(classifyArr.join(',').split(','))]
+            dataRefreshInterface.setRefreshStatus({
+                Source:Number(this.Source),
+                SubSource:Number(this.SubSource),
+                ClassifyId:classifyId.join(','),
+                TerminalCode:terminalCode,
+                SysUserId:Array.isArray(user)?user.join(','):user,
+                Frequency:Array.isArray(frequency)?frequency.join(','):frequency,
+                Keyword:keyWord,
+                Status:state,
+                IsSelectAll:this.isSelectAll,
+                EdbSelectIdList:this.selectList,
+                ModifyStatus:this.isState
+            }).then(res=>{
+                if(res.Ret!==200) return 
+                this.$message.success("设置刷新状态成功")
+                this.selectOptionChange()
+                this.isSetStateDialogShow = false
+            })
+        },
+        handleSortChange({prop,order}){
+            if(order){
+                this.selectOption.sortParam = 'end_date'
+                this.selectOption.sortType = order==='ascending'?'asc':'desc'
+            }else{
+                this.selectOption.sortParam = ''
+                this.selectOption.sortType = ''
+            }
+            this.selectOptionChange()
+        }
+    },
+    mounted(){
+        this.getSourceList()
+        this.getUserList()
+    }
+};
+</script>
+
+<style scoped lang="scss">
+.data-refresh-setting-wrap{
+    min-height: calc(100vh - 120px);
+    display: flex;
+    flex-direction: column;
+    .top-box,.table-box{
+        box-sizing: border-box;
+        padding:20px;
+        background-color: #fff;
+        border:1px solid #C8CDD9;
+        border-radius: 4px;
+    }
+    .top-box{
+        margin-bottom: 20px;
+        display: flex;
+        justify-content: space-between;
+        .el-input{
+            width:260px;
+        }
+        .select-box{
+            .el-select{
+                margin:0 20px;
+            }
+        }
+    }
+    .table-box{
+        flex:1;
+        .el-select{
+            min-width:180px;
+        }
+        .table-select{
+            display: flex;
+            justify-content: space-between;
+            .select-list{
+                flex:1;
+                display: flex;
+                flex-wrap: wrap;
+                gap:20px;
+            }
+            .select-other{
+                .el-button{
+                    margin-left:30px;
+                }
+            }
+        }
+        .el-table{
+            margin:20px 0;
+        }
+        .el-pagination{
+            text-align: right;
+        }
+    }
+    .refresh-setting-dialog{
+        margin-bottom: 0;
+        .dialog-container{
+            overflow: hidden;
+            .default-box{
+                display: flex;
+                align-items: center;
+                padding-bottom: 30px;
+                margin-bottom: 30px;
+                border-bottom: 1px solid #EBEFF6;
+            }
+            .refresh-box{
+                max-height: 65vh;
+                overflow-y: auto;
+            }
+        }
+        .dialog-btn{
+            text-align: center;
+            padding: 25px 0;
+        }
+    }
+}
+</style>