|
@@ -37,11 +37,11 @@
|
|
|
<el-input v-model="modifyNode.nodeName" placeholder="请输入节点名称" style="width:217px;"></el-input>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="节点链接" prop="nodeLink">
|
|
|
- <el-select v-model="modifyNode.nodeLink" value-key="classifyId" placeholder="请选择节点链接" style="width:217px;">
|
|
|
+ <el-select v-model="modifyNode.nodeLink" value-key="MyChartClassifyId" placeholder="请选择节点链接" style="width:217px;">
|
|
|
<el-option v-for="item in myList"
|
|
|
:key="item.MyChartClassifyId"
|
|
|
:label="item.MyChartClassifyName"
|
|
|
- :value="{id:item.MyChartClassifyId,userId:item.AdminId}">
|
|
|
+ :value="item">
|
|
|
<span style="float:left;">{{item.MyChartClassifyName}}</span>
|
|
|
<span style="float:right;color: #8492a6; font-size: 13px"
|
|
|
@click="goToList(item)"><img src="~@/assets/img/chart_m/check.png"></span>
|
|
@@ -51,7 +51,7 @@
|
|
|
</el-form>
|
|
|
</div>
|
|
|
<div class="dialog-footer">
|
|
|
- <el-button>取消</el-button>
|
|
|
+ <el-button @click="isModifyNodeDialogShow=false">取消</el-button>
|
|
|
<el-button type="primary" @click="editNode">确定</el-button>
|
|
|
</div>
|
|
|
|
|
@@ -91,11 +91,11 @@ export default {
|
|
|
await this.$refs.refForm.validate();
|
|
|
if(!this.$refs.container) return
|
|
|
this.$refs.container.editNode(this.modifyNode)
|
|
|
- this.$message.success(`${this.modifyNode.nodeId ? '编辑' : '添加'}成功`);
|
|
|
+ this.$message.success(`${this.modifyNode.nodeId ? '编辑' : '添加'}节点成功`);
|
|
|
this.isModifyNodeDialogShow = false;
|
|
|
},
|
|
|
goToList(item) {
|
|
|
- window.open(`/mychart?frameId=${item.classifyId}`);
|
|
|
+ window.open(`/mychart?frameId=${item.MyChartClassifyId}`);
|
|
|
},
|
|
|
async saveFrame(){
|
|
|
if(!this.frameDetail.FrameworkName.length){
|
|
@@ -108,7 +108,7 @@ export default {
|
|
|
this.lockLoding = this.$loading({
|
|
|
lock: true,
|
|
|
text: '保存中...',
|
|
|
- target: '.frame-container-wrap',
|
|
|
+ target: '.frame-editor-wrap',
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(255, 255, 255, 0.8)'
|
|
|
});
|
|
@@ -130,9 +130,10 @@ export default {
|
|
|
this.frameDetail.FrameworkContent = JSON.stringify(this.$refs.container.graph.toJSON())
|
|
|
if(this.frameId){
|
|
|
//edit
|
|
|
- chartFrameInterface.editFrame({...this.frameDetail,...{ChartFrameworkId:this.frameId}}).then(res=>{
|
|
|
+ chartFrameInterface.editFrame({...this.frameDetail,...{ChartFrameworkId:Number(this.frameId)}}).then(res=>{
|
|
|
if(res.Ret!==200) return
|
|
|
this.$message.success("编辑成功")
|
|
|
+ this.lockLoding.close();
|
|
|
})
|
|
|
}else{
|
|
|
//add
|
|
@@ -141,9 +142,10 @@ export default {
|
|
|
this.frameId = res.Data?res.Data.ChartFrameworkId:0
|
|
|
this.frameDetail = res.Data||{FrameworkName:'',FrameworkContent:''}
|
|
|
this.$message.success("新增成功")
|
|
|
+ this.lockLoding.close();
|
|
|
+ this.$router.replace({path:'/editframe',query:{frameId:this.frameId}})
|
|
|
})
|
|
|
}
|
|
|
- this.lockLoding.close();
|
|
|
},
|
|
|
getMyList(){
|
|
|
mychartInterface.classifyList().then((res)=>{
|