提交 89c71834 编写于 作者: zhentian.jia's avatar zhentian.jia

添加外部用户情况

上级 d0b5bf0c
...@@ -7,4 +7,4 @@ dist/ ...@@ -7,4 +7,4 @@ dist/
node_modules/ node_modules/
.DS_Store .DS_Store
.vscode .vscode
envConfig.js src/utils/envConfig.js
\ No newline at end of file \ No newline at end of file
...@@ -154,7 +154,7 @@ ...@@ -154,7 +154,7 @@
</div> </div>
<div class="second-step" v-else-if="active === 1"> <div class="second-step" v-else-if="active === 1">
<el-tabs v-model="activeName" @tab-click="handleClickTabs"> <el-tabs v-model="activeName" @tab-click="handleClickTabs">
<el-tab-pane label="设定行政范围" name="first"> <el-tab-pane v-if="idTypeValue == 1" label="设定行政范围" name="first">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col class="rim" :span="12"> <el-col class="rim" :span="12">
<!-- <!--
...@@ -423,7 +423,7 @@ ...@@ -423,7 +423,7 @@
import BreadCrumb from "../../components/breadcrumb.vue"; import BreadCrumb from "../../components/breadcrumb.vue";
import { doUpload, getFilePath } from "../../utils/qiniuUtil"; import { doUpload, getFilePath } from "../../utils/qiniuUtil";
import { returnData } from "../mock"; import { returnData } from "../mock";
import { setTimeout } from "timers"; import { mapGetters } from "vuex";
import { openLoading, closeLoading } from "../../utils/utils"; import { openLoading, closeLoading } from "../../utils/utils";
let vm = null; let vm = null;
export default { export default {
...@@ -448,6 +448,7 @@ export default { ...@@ -448,6 +448,7 @@ export default {
district: "长宁区" district: "长宁区"
}; };
return { return {
idTypeValue: "",
itemOrganization: itemOrganization, itemOrganization: itemOrganization,
itemPerson: itemPerson, itemPerson: itemPerson,
projectId: null, projectId: null,
...@@ -637,6 +638,9 @@ export default { ...@@ -637,6 +638,9 @@ export default {
} }
}; };
}, },
computed: {
...mapGetters(["_token", "idType"])
},
created() { created() {
vm = this; vm = this;
(this.projectId = vm.getUrlSearch(window.location.href, "projectId")), (this.projectId = vm.getUrlSearch(window.location.href, "projectId")),
...@@ -645,8 +649,13 @@ export default { ...@@ -645,8 +649,13 @@ export default {
this.getComponentInfo(); this.getComponentInfo();
this.$nextTick(function() { this.$nextTick(function() {
//this.getComponentInfo();
//this.getDepartment(); //this.getDepartment();
this.idTypeValue = vm.idType;
//this.idTypeValue = 2;
if (this.idTypeValue == 2) {
console.log("idType:", vm.idType, " idTypeValue:", this.idTypeValue);
this.activeName = "second";
}
}); });
}, },
methods: { methods: {
...@@ -954,6 +963,8 @@ export default { ...@@ -954,6 +963,8 @@ export default {
} }
} }
} else if (this.active == 1) { } else if (this.active == 1) {
if (this.idTypeValue == 1) {
//内部管理员
if (this.tagsRegion.length > 0) { if (this.tagsRegion.length > 0) {
//选择了范围 //选择了范围
let req = { let req = {
...@@ -1006,6 +1017,7 @@ export default { ...@@ -1006,6 +1017,7 @@ export default {
}); });
} }
} }
}
}, },
//图片上传 //图片上传
handleAvatarSuccess(res, file) { handleAvatarSuccess(res, file) {
...@@ -1074,9 +1086,7 @@ export default { ...@@ -1074,9 +1086,7 @@ export default {
const isMP4 = file.type === "video/mp4"; const isMP4 = file.type === "video/mp4";
const isLt = file.size / 1024 / 1024 < 500; const isLt = file.size / 1024 / 1024 < 500;
if (!isLt) { if (!isLt) {
this.$message.error( this.$message.error("上传视频大小不能超过500M !");
"上传视频大小不能超过500M !"
);
} }
if (!isMP4) { if (!isMP4) {
this.$message.error("请上传MP4格式文件!"); this.$message.error("请上传MP4格式文件!");
...@@ -1170,8 +1180,10 @@ export default { ...@@ -1170,8 +1180,10 @@ export default {
//新建 //新建
} else { } else {
//编辑 //编辑
if(this.idTypeValue == 1) {
this.getAdministrative(); this.getAdministrative();
} }
}
}, },
//切换tabs //切换tabs
handleClickTabs(tab, event) { handleClickTabs(tab, event) {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册