fix:修复模板保存
This commit is contained in:
parent
85f614f414
commit
ea0d68036b
@ -24,8 +24,12 @@
|
|||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="primary" size="small" @click="move('bottom')">
|
<el-button type="primary" size="small" @click="move('bottom')">
|
||||||
<el-tooltip effect="dark" content="下移规则" placement="top"
|
<el-tooltip effect="dark" content="下移规则" placement="top"
|
||||||
><el-icon> <bottom /> </el-icon
|
>
|
||||||
></el-tooltip>
|
<el-icon>
|
||||||
|
<bottom/>
|
||||||
|
</el-icon
|
||||||
|
>
|
||||||
|
</el-tooltip>
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</div>
|
</div>
|
||||||
@ -38,7 +42,8 @@
|
|||||||
<el-button type="primary" size="small" text @click="addRuleDialogShow = true">+ 新增规则</el-button>
|
<el-button type="primary" size="small" text @click="addRuleDialogShow = true">+ 新增规则</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<el-dialog :title="editRule ? '编辑规则' : '新增规则'" v-model="addRuleDialogShow" width="70%" @close="ruleDialogClose">
|
<el-dialog :title="editRule ? '编辑规则' : '新增规则'" v-model="addRuleDialogShow" width="70%"
|
||||||
|
@close="ruleDialogClose">
|
||||||
<rule :editRule="editRule" @ruleAdd="ruleAdd" v-if="addRuleDialogShow" :isAutoPlan="rules != undefined"/>
|
<rule :editRule="editRule" @ruleAdd="ruleAdd" v-if="addRuleDialogShow" :isAutoPlan="rules != undefined"/>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
<el-dialog title="模板管理" v-model="ruleTemplateShow" width="70%">
|
<el-dialog title="模板管理" v-model="ruleTemplateShow" width="70%">
|
||||||
@ -52,6 +57,7 @@ import Rule from "@/components/Rule";
|
|||||||
import ApplicationRuleList from "./ApplicationRuleList";
|
import ApplicationRuleList from "./ApplicationRuleList";
|
||||||
import HttpUtil from "@/utils/HttpUtil";
|
import HttpUtil from "@/utils/HttpUtil";
|
||||||
import {Top, Bottom, Edit} from "@element-plus/icons-vue";
|
import {Top, Bottom, Edit} from "@element-plus/icons-vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "RuleBlock",
|
name: "RuleBlock",
|
||||||
props: ["rules"],
|
props: ["rules"],
|
||||||
@ -107,7 +113,9 @@ export default {
|
|||||||
},
|
},
|
||||||
//切换模板
|
//切换模板
|
||||||
async templateUpdate(newVal) {
|
async templateUpdate(newVal) {
|
||||||
|
console.debug("新的模板:", newVal);
|
||||||
this.ruleList = JSON.parse(newVal.content);
|
this.ruleList = JSON.parse(newVal.content);
|
||||||
|
this.chosedTemplate = newVal;
|
||||||
this.ruleUpdate();
|
this.ruleUpdate();
|
||||||
this.ruleTemplateShow = false;
|
this.ruleTemplateShow = false;
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user