|
@@ -17,10 +17,10 @@
|
|
|
</el-select>
|
|
|
</div>
|
|
|
<div class='input-right' ref='graph' v-show='ruleForm.Type=="Zone" || ruleForm.Type=="Image" || ruleForm.Type =="Line"'>
|
|
|
- <div v-if=' ruleForm.Type=="Image" && ruleForm.Url' class='input-right'>
|
|
|
+ <div v-show=' ruleForm.Type=="Image" && ruleForm.Url' class='input-right'>
|
|
|
<img :src='`/serve/topology-wanda/Picture/query/${ruleForm.Url}`' alt />
|
|
|
</div>
|
|
|
- <canvas id='canvas' :width='canvasWidth' :height='canvasHeight' v-else></canvas>
|
|
|
+ <canvas id='canvas' :width='canvasWidth' :height='canvasHeight' v-show='!(ruleForm.Type=="Image" && ruleForm.Url)'></canvas>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div v-if='ruleForm.Type=="Zone" || ruleForm.Type=="Line"' class='form3'>
|
|
@@ -251,8 +251,9 @@ export default {
|
|
|
this.view.lineWidth = this.ruleForm.LineWidth
|
|
|
},
|
|
|
initGraph() {
|
|
|
- if (this.ruleForm.Type == 'Zone' || this.ruleForm.Type == 'Line') {
|
|
|
- this.clearGraphy(this.ruleForm.Type == 'Zone' ? 1 : 0)
|
|
|
+ if (this.ruleForm.Type == 'Zone' || this.ruleForm.Type == 'Line' || this.ruleForm.Type == 'Image') {
|
|
|
+ //1是区域 0是线条
|
|
|
+ this.clearGraphy(this.ruleForm.Type == 'Zone' ? 1 : this.ruleForm.Type == 'Line' ? 0 : 2)
|
|
|
}
|
|
|
},
|
|
|
//rgba转成16进制
|