bug
This commit is contained in:
		| @@ -19,7 +19,7 @@ | |||||||
|       <ai-echart-v2 v-else-if="/Chart/.test(data.type)" |       <ai-echart-v2 v-else-if="/Chart/.test(data.type)" | ||||||
|         style="height: 100%; width: 100%;" |         style="height: 100%; width: 100%;" | ||||||
|         :ref="'chart' + index" |         :ref="'chart' + index" | ||||||
|         :key="`chart${index}`" |         :key="`chart-${index}`" | ||||||
|         :theme="theme" |         :theme="theme" | ||||||
|         :data="values" |         :data="values" | ||||||
|         :ops="chartList[data.config]"/> |         :ops="chartList[data.config]"/> | ||||||
|   | |||||||
| @@ -82,7 +82,7 @@ | |||||||
|             <div class="table-options"> |             <div class="table-options"> | ||||||
|               <el-button type="text" @click="toDetail(row.id)">详情</el-button> |               <el-button type="text" @click="toDetail(row.id)">详情</el-button> | ||||||
|               <el-button type="text" @click="remove(row.id)">删除</el-button> |               <el-button type="text" @click="remove(row.id)">删除</el-button> | ||||||
|               <el-button type="text" @click="push(row.id)" v-if="row.status === '1'">推送精选</el-button> |               <el-button type="text" @click="push(row.id)" v-if="row.status === '1' && row.pushStatus === '0'">推送精选</el-button> | ||||||
|             </div> |             </div> | ||||||
|           </template> |           </template> | ||||||
|         </el-table-column> |         </el-table-column> | ||||||
|   | |||||||
| @@ -1,7 +1,7 @@ | |||||||
| <template> | <template> | ||||||
|   <div class="AppHelp"> |   <div class="AppHelp"> | ||||||
|     <keep-alive :include="['List']"> |     <keep-alive :include="['List']"> | ||||||
|       <component ref="component" :is="component" @change="onChange" :params="params" :instance="instance" :dict="dict"></component> |       <component ref="component" :is="component" :params="params" :instance="instance" :dict="dict"></component> | ||||||
|     </keep-alive> |     </keep-alive> | ||||||
|   </div> |   </div> | ||||||
| </template> | </template> | ||||||
|   | |||||||
| @@ -46,7 +46,7 @@ | |||||||
|               <el-cascader v-model="form.systemRuleId" ref="cascaderArr" :props="etOps" clearable placeholder="请选择" @change="handleTypeForm" :options="rulesOps"/> |               <el-cascader v-model="form.systemRuleId" ref="cascaderArr" :props="etOps" clearable placeholder="请选择" @change="handleTypeForm" :options="rulesOps"/> | ||||||
|             </el-form-item> |             </el-form-item> | ||||||
|             <el-form-item label="自定义事件" prop="ruleName"> |             <el-form-item label="自定义事件" prop="ruleName"> | ||||||
|               <ai-select v-model="form.ruleName" placeholder="请选择自定义事件" :selectList="$dict.getDict('appIntegralApplyEventType')"> |               <ai-select v-model="form.ruleName" @change="change" placeholder="请选择自定义事件" :selectList="dict.getDict('appIntegralApplyEventType')"> | ||||||
|             </ai-select> |             </ai-select> | ||||||
|             </el-form-item> |             </el-form-item> | ||||||
|  |  | ||||||
| @@ -54,7 +54,7 @@ | |||||||
|               <div>常规</div> |               <div>常规</div> | ||||||
|             </el-form-item> |             </el-form-item> | ||||||
|             <el-form-item label="周期范围" prop="scoringCycle"> |             <el-form-item label="周期范围" prop="scoringCycle"> | ||||||
|               <ai-select v-model="form.scoringCycle" :selectList="$dict.getDict('integralRuleScoringCycle')" :disabled="isOneAndTen"/> |               <ai-select v-model="form.scoringCycle" :selectList="dict.getDict('integralRuleScoringCycle')" :disabled="isOneAndTen"/> | ||||||
|             </el-form-item> |             </el-form-item> | ||||||
|             <el-form-item label="奖励次数"> |             <el-form-item label="奖励次数"> | ||||||
|               <el-input type="number" placeholder="请输入,周期范围内,不填写表示不限制" v-model.number="form.numberLimit" clearable :disabled="isOneAndTen"/> |               <el-input type="number" placeholder="请输入,周期范围内,不填写表示不限制" v-model.number="form.numberLimit" clearable :disabled="isOneAndTen"/> | ||||||
| @@ -68,7 +68,7 @@ | |||||||
|               <ai-area-select |               <ai-area-select | ||||||
|                 clearable |                 clearable | ||||||
|                 @fullname="v => form.areaName = v" |                 @fullname="v => form.areaName = v" | ||||||
|                 :disabled-level="$store.state.user.info.areaList.length - 1" |                 :disabled-level="$store.state.user.info.areaList.length" | ||||||
|                 always-show |                 always-show | ||||||
|                 :instance="instance" |                 :instance="instance" | ||||||
|                 v-model="form.areaId"> |                 v-model="form.areaId"> | ||||||
| @@ -173,7 +173,7 @@ | |||||||
|             {required: true, message: "请选择事件/类型", trigger: "change"}, |             {required: true, message: "请选择事件/类型", trigger: "change"}, | ||||||
|           ], |           ], | ||||||
|           ruleName: [ |           ruleName: [ | ||||||
|             {required: true, message: "请输入自定义事件", trigger: "change"}, |             {required: true, message: "请选择自定义事件", trigger: "change"}, | ||||||
|           ], |           ], | ||||||
|           scoringCycle: [ |           scoringCycle: [ | ||||||
|             {required: true, message: "请选择周期范围", trigger: "change"}, |             {required: true, message: "请选择周期范围", trigger: "change"}, | ||||||
| @@ -231,6 +231,10 @@ | |||||||
|           } |           } | ||||||
|         }); |         }); | ||||||
|       }, |       }, | ||||||
|  |  | ||||||
|  |       change (e) { | ||||||
|  |         console.log(this.dict.getDict('appIntegralApplyEventType')) | ||||||
|  |       }, | ||||||
|       closed () { |       closed () { | ||||||
|         this.form.ruleType = '0' |         this.form.ruleType = '0' | ||||||
|         this.form.systemRuleId = '' |         this.form.systemRuleId = '' | ||||||
|   | |||||||
| @@ -13,7 +13,7 @@ | |||||||
|       <template v-else> |       <template v-else> | ||||||
|         <el-option v-for="(item, index) in ops" :key="index" |         <el-option v-for="(item, index) in ops" :key="index" | ||||||
|                    :label="item.dictName||item[actionProp.label]" |                    :label="item.dictName||item[actionProp.label]" | ||||||
|                    :value="item.dictValue>-1?item.dictValue:item[actionProp.value]" |                    :value="item.dictValue>-1 || item.dictValue ?item.dictValue:item[actionProp.value]" | ||||||
|                    :disabled="check(item[actionProp.value])"/> |                    :disabled="check(item[actionProp.value])"/> | ||||||
|       </template> |       </template> | ||||||
|     </el-select> |     </el-select> | ||||||
|   | |||||||
| @@ -1,6 +1,6 @@ | |||||||
| <template> | <template> | ||||||
|   <section class="AiEchart"> |   <section class="AiEchart"> | ||||||
|     <div ref="AiEchart" class="chart" :style="{minWidth:grid.width,minHeight:grid.height}"/> |     <div :ref="AiEchart" class="chart" :style="{minWidth:grid.width,minHeight:grid.height}"/> | ||||||
|     <slot v-if="$slots.default"/> |     <slot v-if="$slots.default"/> | ||||||
|     <render-component v-else-if="ops.render" :render="ops.render" :options="chartOptions" :data="data"/> |     <render-component v-else-if="ops.render" :render="ops.render" :options="chartOptions" :data="data"/> | ||||||
|   </section> |   </section> | ||||||
| @@ -39,7 +39,8 @@ export default { | |||||||
|   data() { |   data() { | ||||||
|     return { |     return { | ||||||
|       chart: null, |       chart: null, | ||||||
|       timer: null |       timer: null, | ||||||
|  |       AiEchart: `AiEchart-${new Date().getTime()}` | ||||||
|     } |     } | ||||||
|   }, |   }, | ||||||
|   computed: { |   computed: { | ||||||
| @@ -176,14 +177,14 @@ export default { | |||||||
|       } |       } | ||||||
|     }, |     }, | ||||||
|     initChart() { |     initChart() { | ||||||
|       this.chart = echarts.init(this.$refs.AiEchart) |       this.chart = echarts.init(this.$refs[this.AiEchart]) | ||||||
|       this.chart.setOption(this.chartOptions || {}) |       this.chart.setOption(this.chartOptions || {}) | ||||||
|     }, |     }, | ||||||
|     watchResize() { |     watchResize() { | ||||||
|       this.timer && clearInterval(this.timer) |       this.timer && clearInterval(this.timer) | ||||||
|       this.timer = setInterval(() => { |       this.timer = setInterval(() => { | ||||||
|         if (this.chart?.getHeight() != this.$refs.AiEchart?.clientHeight || |         if (this.chart?.getHeight() != this.$refs[this.AiEchart]?.clientHeight || | ||||||
|             this.chart?.getWidth() != this.$refs.AiEchart?.clientWidth) { |             this.chart?.getWidth() != this.$refs[this.AiEchart]?.clientWidth) { | ||||||
|           this.chart?.resize() |           this.chart?.resize() | ||||||
|         } |         } | ||||||
|       }, 1000) |       }, 1000) | ||||||
| @@ -196,6 +197,7 @@ export default { | |||||||
|   }, |   }, | ||||||
|   mounted() { |   mounted() { | ||||||
|     this.$nextTick(() => { |     this.$nextTick(() => { | ||||||
|  |     console.log(this.$refs[this.AiEchart]) | ||||||
|       this.watchResize() |       this.watchResize() | ||||||
|       this.initChart() |       this.initChart() | ||||||
|       this.getChartData() |       this.getChartData() | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user