提交 f77601f8 编写于 作者: guofeng.chen's avatar guofeng.chen

修改小圈选择

上级 d6d15d5e
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
<el-step title="选择学员范围">3</el-step> <el-step title="选择学员范围">3</el-step>
</el-steps> </el-steps>
</el-col> </el-col>
<div> <div style="white-space: nowrap">
<div v-if="!canNext" class="dis-btn">下一步</div> <div v-if="!canNext" class="dis-btn">下一步</div>
<el-button class="dis-btn-b" v-if="active != 0 && projectStatus == 1 && isPreview != 1" size="small" @click="save">暂存</el-button> <el-button class="dis-btn-b" v-if="active != 0 && projectStatus == 1 && isPreview != 1" size="small" @click="save">暂存</el-button>
<el-button class="dis-btn-b" v-if="active !== 2 && canNext" size="small" type="primary" @click="nextStep">下一步</el-button> <el-button class="dis-btn-b" v-if="active !== 2 && canNext" size="small" type="primary" @click="nextStep">下一步</el-button>
...@@ -463,6 +463,8 @@ export default { ...@@ -463,6 +463,8 @@ export default {
// 查看时,点击下一步直接跳 // 查看时,点击下一步直接跳
if (vm.isPreview == 1) { if (vm.isPreview == 1) {
vm.active = 2; vm.active = 2;
this.getCircleList();
this.getCircleData();
return; return;
} }
// 调用项目信息中的下一步操作 // 调用项目信息中的下一步操作
......
...@@ -1962,19 +1962,20 @@ export default { ...@@ -1962,19 +1962,20 @@ export default {
//暂存步骤2 //暂存步骤2
if (this.formData.scopeType == 1) { if (this.formData.scopeType == 1) {
//小生态暂存 //小生态暂存
if (this.formEcology.ecology == "") { // if (this.formEcology.ecology == "") {
vm.$message.info("完成"); // vm.$message.info("完成");
} else { // } else {
let req = {}; // let req = {};
req.ecology = []; // req.ecology = [];
req.ecology[0] = this.formEcology.ecology; // req.ecology[0] = this.formEcology.ecology;
vm // vm
.POST("portal/scope/v1/" + this.projectId + "/organization", req) // .POST("portal/scope/v1/" + this.projectId + "/organization", req)
.then(res => { // .then(res => {
//console.log('设定小生态范围',res); // //console.log('设定小生态范围',res);
vm.$message.info(res.message); // vm.$message.info(res.message);
}); // });
} // }
this.sendCircleData('storage');
return; return;
} }
if (this.tagsRegion.length == 0) { if (this.tagsRegion.length == 0) {
...@@ -2124,7 +2125,7 @@ export default { ...@@ -2124,7 +2125,7 @@ export default {
// } // }
// }); // });
// 设定小圈范围 // 设定小圈范围
this.sendCircleData(); this.sendCircleData('next');
return; return;
} }
if (this.idType == 1) { if (this.idType == 1) {
...@@ -3345,13 +3346,15 @@ export default { ...@@ -3345,13 +3346,15 @@ export default {
}); });
}, },
// 提交、修改圈子数据 // 提交、修改圈子数据
sendCircleData() { sendCircleData(type = 'next') {
const { microecologyId, groupType, groupIds } = this.formCircle; const { microecologyId, groupType, groupIds } = this.formCircle;
if (!microecologyId) { if (!microecologyId) {
if (type == 'next') {
vm.$message({ vm.$message({
type: "info", type: "info",
message: "请选择关联小圈" message: "请选择关联小圈"
}); });
}
return; return;
} }
const postData = { const postData = {
...@@ -3364,9 +3367,16 @@ export default { ...@@ -3364,9 +3367,16 @@ export default {
vm.POST("portal/portalMicroEcology/relation/saveOrUpdate", postData).then(res => { vm.POST("portal/portalMicroEcology/relation/saveOrUpdate", postData).then(res => {
closeLoading(vm); closeLoading(vm);
if (res.code == "000000") { if (res.code == "000000") {
if (type == 'next') {
this.active++; this.active++;
this.stepData = [false, false, true]; this.stepData = [false, false, true];
this.tagDrop(); this.tagDrop();
} else if (type == 'storage') {
vm.$message({
type: "success",
message: "暂存成功"
});
}
} }
}); });
}, },
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册