Merge branch 'uat-safe' of http://192.168.34.160:8023/admin/zhgdyun into uat-safe
This commit is contained in:
commit
54a0f258a1
@ -995,6 +995,28 @@
|
||||
<i v-else class="el-icon-plus avatar-uploader-icon"></i>
|
||||
</el-upload>
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
label="项目图标"
|
||||
prop="projectIcon"
|
||||
>
|
||||
<el-upload
|
||||
class="avatar-uploader"
|
||||
:action="$store.state.UPLOADURL"
|
||||
:show-file-list="false"
|
||||
:before-upload="beforeAvatarUpload"
|
||||
:on-success="handleUploadSuccess1"
|
||||
name="files"
|
||||
>
|
||||
<div v-if="addProjectForm.projectIcon" class="imgBox">
|
||||
<img :src="addProjectForm.projectIcon" class="avatar" />
|
||||
<i
|
||||
class="el-icon-error redText"
|
||||
@click.stop="addProjectForm.projectIcon = ''"
|
||||
></i>
|
||||
</div>
|
||||
<i v-else class="el-icon-plus avatar-uploader-icon"></i>
|
||||
</el-upload>
|
||||
</el-form-item>
|
||||
<div class="dialog-footer">
|
||||
<el-button
|
||||
class="cancleBtn"
|
||||
@ -1570,6 +1592,7 @@ export default {
|
||||
households: "",
|
||||
latitude: "",
|
||||
layoutImage: "",
|
||||
projectIcon: "",
|
||||
longitude: "",
|
||||
projectAcreage: "",
|
||||
projectAddress: "",
|
||||
@ -3571,19 +3594,24 @@ export default {
|
||||
console.log("编辑页有值吗", item);
|
||||
this.projectDialogTitle = this.$t("message.companyDiagram.editProject"); //编辑项目
|
||||
this.isAdd = false;
|
||||
this.addProjectForm = JSON.parse(JSON.stringify(item));
|
||||
this.addProjectForm = JSON.parse(JSON.stringify({
|
||||
...item,
|
||||
projectIcon: item.projectIcon ? item.projectIcon : "",
|
||||
}));
|
||||
this.addProjectDialog = true;
|
||||
this.$nextTick(() => {
|
||||
setTimeout(() => {
|
||||
this.$refs["addProjectForm"].clearValidate();
|
||||
this.$refs.cascader.$refs.panel.activePath = [];
|
||||
if (item.areaCode) {
|
||||
this.provincesCityArr = [
|
||||
item.provincesCode,
|
||||
item.cityCode,
|
||||
item.areaCode,
|
||||
].filter((item) => item);
|
||||
|
||||
console.log(this.provincesCityArr);
|
||||
];
|
||||
} else {
|
||||
this.provincesCityArr = [item.provincesCode, item.cityCode];
|
||||
}
|
||||
}, 200);
|
||||
});
|
||||
},
|
||||
@ -3597,8 +3625,8 @@ export default {
|
||||
}
|
||||
this.$refs["addProjectForm"].validate((valid) => {
|
||||
if (valid) {
|
||||
console.log(this.addProjectForm);
|
||||
if (this.isAdd) {
|
||||
console.log(this.addProjectForm);
|
||||
addProjectApi(this.addProjectForm).then((res) => {
|
||||
console.log("添加成功", res);
|
||||
this.addProjectDialog = false;
|
||||
@ -3608,12 +3636,7 @@ export default {
|
||||
); //添加成功!
|
||||
});
|
||||
} else {
|
||||
editProjectApi({
|
||||
...this.addProjectForm,
|
||||
areaCode: this.addProjectForm.areaCode
|
||||
? this.addProjectForm.areaCode
|
||||
: "",
|
||||
}).then((res) => {
|
||||
editProjectApi(this.addProjectForm).then((res) => {
|
||||
console.log("信息编辑", res);
|
||||
this.addProjectDialog = false;
|
||||
this.initData();
|
||||
@ -3655,7 +3678,7 @@ export default {
|
||||
console.log(val);
|
||||
this.addProjectForm.provincesCode = val[0];
|
||||
this.addProjectForm.cityCode = val[1];
|
||||
this.addProjectForm.areaCode = val[2];
|
||||
this.addProjectForm.areaCode = val[2] || "";
|
||||
},
|
||||
// handleRemove(){
|
||||
// this.addProjectForm.layoutImage=''
|
||||
@ -3682,6 +3705,12 @@ export default {
|
||||
this.addProjectForm.layoutImage =
|
||||
this.$store.state.FILEURL + res.data[0].imageUrl;
|
||||
},
|
||||
handleUploadSuccess1(res) {
|
||||
// console.log(res);
|
||||
this.addProjectForm.projectIcon =
|
||||
this.$store.state.FILEURL + res.data[0].imageUrl;
|
||||
console.log(this.addProjectForm.projectIcon);
|
||||
},
|
||||
openAuthorizedConfig(type) {
|
||||
this.authorizedConfig = {
|
||||
type: type,
|
||||
|
||||
@ -4,14 +4,14 @@
|
||||
<vue-scroll style="width: 100%">
|
||||
<div class="btn_wrap">
|
||||
<!-- <el-button
|
||||
v-if="projectAuditStatus != 2"
|
||||
type="primary"
|
||||
size="medium"
|
||||
@click="uploadThirdParty"
|
||||
>
|
||||
{{$t('message.projectInfo.updateToThirdParty')}}
|
||||
</el-button
|
||||
> -->
|
||||
v-if="projectAuditStatus != 2"
|
||||
type="primary"
|
||||
size="medium"
|
||||
@click="uploadThirdParty"
|
||||
>
|
||||
{{$t('message.projectInfo.updateToThirdParty')}}
|
||||
</el-button
|
||||
> -->
|
||||
<el-button
|
||||
v-if="company == 'zhengwu'"
|
||||
type="primary"
|
||||
@ -22,22 +22,25 @@
|
||||
</el-button>
|
||||
<!-- 编辑 -->
|
||||
<el-button
|
||||
v-permission="{key: 'xmjbxx_edit', menuPath: '/project/summary/baseInfo'}"
|
||||
v-permission="{
|
||||
key: 'xmjbxx_edit',
|
||||
menuPath: '/project/summary/baseInfo',
|
||||
}"
|
||||
type="primary"
|
||||
size="medium"
|
||||
@click="addProjectDialog = true"
|
||||
>{{ $t('message.companyDiagram.Table.edit') }}</el-button
|
||||
>{{ $t("message.companyDiagram.Table.edit") }}</el-button
|
||||
>
|
||||
<!-- <el-button type="primary" size="medium">{{$t('message.companyDiagram.projectSchedule')}}</el-button> -->
|
||||
</div>
|
||||
<div>
|
||||
<div class="custom_tab">
|
||||
<div class="title">{{ $t('message.companyDiagram.sheet') }}</div>
|
||||
<div class="title">{{ $t("message.companyDiagram.sheet") }}</div>
|
||||
<div class="flex4">
|
||||
<div class="type_content" style="z-index: 2">
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t('message.companyDiagram.entryName1')
|
||||
$t("message.companyDiagram.entryName1")
|
||||
}}</span>
|
||||
<span class="width_65" style="white-space: nowrap">{{
|
||||
projectDetail.projectName
|
||||
@ -45,7 +48,7 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t('message.companyDiagram.Table.projectAddress')
|
||||
$t("message.companyDiagram.Table.projectAddress")
|
||||
}}</span>
|
||||
<span class="width_65 bg_color" style="white-space: nowrap">{{
|
||||
projectDetail.projectAddress
|
||||
@ -54,18 +57,18 @@
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.provincesCode'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.provincesCode"
|
||||
)
|
||||
}}</span>
|
||||
<span class="width_65"
|
||||
>{{ projectDetail.provinceName
|
||||
}}{{projectDetail.cityName}}{{ projectDetail.areaName }}</span
|
||||
>{{ projectDetail.provinceName }}{{ projectDetail.cityName
|
||||
}}{{ projectDetail.areaName }}</span
|
||||
>
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.projectManage'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.projectManage"
|
||||
)
|
||||
}}</span>
|
||||
<span class="width_65 bg_color">{{
|
||||
@ -74,34 +77,24 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.longitude')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.longitude")
|
||||
}}</span>
|
||||
<span class="width_65">{{ projectDetail.longitude }}</span>
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.projectNumber'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.projectNumber"
|
||||
)
|
||||
}}</span>
|
||||
<span class="width_65 bg_color">{{
|
||||
projectDetail.projectNumber
|
||||
}}</span>
|
||||
</div>
|
||||
<div class="flex3" v-if="company == 'gsgs'">
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.bridgeLength'
|
||||
)
|
||||
}}</span>
|
||||
<span class="width_65"
|
||||
>{{ projectDetail.bridgeLength }}(m)</span
|
||||
>
|
||||
</div>
|
||||
<div class="flex3" v-else>
|
||||
<span class="width_35">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.projectAcreage'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.projectAcreage"
|
||||
)
|
||||
}}</span>
|
||||
<span class="width_65"
|
||||
@ -111,7 +104,7 @@
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.startWorkDate'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.startWorkDate"
|
||||
)
|
||||
}}</span>
|
||||
<span class="width_65 bg_color">{{
|
||||
@ -120,13 +113,13 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.saleAcreage')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.saleAcreage")
|
||||
}}</span>
|
||||
<span class="width_65">{{ projectDetail.saleAcreage }}</span>
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.buildingNum')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.buildingNum")
|
||||
}}</span>
|
||||
<span class="width_65 bg_color">{{
|
||||
projectDetail.buildingNum
|
||||
@ -134,14 +127,14 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.projectTel')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.projectTel")
|
||||
}}</span>
|
||||
<span class="width_65">{{ projectDetail.projectTel }}</span>
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35">
|
||||
<!-- 项目唯一标识(SN) -->
|
||||
{{ $t('message.projectInfo.projectOnlyMark') }}
|
||||
{{ $t("message.projectInfo.projectOnlyMark") }}
|
||||
</span>
|
||||
<span class="width_65 bg_color" style="white-space: nowrap">{{
|
||||
projectDetail.projectSn
|
||||
@ -166,7 +159,7 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.latitude')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.latitude")
|
||||
}}</span>
|
||||
<span class="width_65 bg_color">{{
|
||||
projectDetail.latitude
|
||||
@ -174,7 +167,7 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.projectType')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.projectType")
|
||||
}}</span>
|
||||
<span
|
||||
class="width_65"
|
||||
@ -187,7 +180,7 @@
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.structureType'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.structureType"
|
||||
)
|
||||
}}</span>
|
||||
<span
|
||||
@ -200,7 +193,7 @@
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.bulidStatus')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.bulidStatus")
|
||||
}}</span>
|
||||
<span
|
||||
class="width_65"
|
||||
@ -215,7 +208,7 @@
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.constructionStage'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.constructionStage"
|
||||
)
|
||||
}}</span>
|
||||
<span
|
||||
@ -226,24 +219,24 @@
|
||||
>{{ item.name }}</span
|
||||
>
|
||||
<!-- <span
|
||||
class="width_65 bg_color"
|
||||
v-for="(item, index) in $t(
|
||||
'message.companyDiagram.CONSTRUCTIONSTAGE'
|
||||
)"
|
||||
:key="index"
|
||||
v-if="projectDetail.constructionStage == item.id"
|
||||
>{{ item.name }}</span
|
||||
> -->
|
||||
class="width_65 bg_color"
|
||||
v-for="(item, index) in $t(
|
||||
'message.companyDiagram.CONSTRUCTIONSTAGE'
|
||||
)"
|
||||
:key="index"
|
||||
v-if="projectDetail.constructionStage == item.id"
|
||||
>{{ item.name }}</span
|
||||
> -->
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.households')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.households")
|
||||
}}</span>
|
||||
<span class="width_65">{{ projectDetail.households }}</span>
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.layoutImage')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.layoutImage")
|
||||
}}</span>
|
||||
<span class="width_65 bg_color">
|
||||
<img
|
||||
@ -255,15 +248,15 @@
|
||||
cursor: pointer;
|
||||
"
|
||||
@click="
|
||||
bigImageDialog = true
|
||||
bigImageUrl = projectDetail.layoutImage
|
||||
bigImageDialog = true;
|
||||
bigImageUrl = projectDetail.layoutImage;
|
||||
"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div class="flex3">
|
||||
<span class="width_35 border_l" style="height: 44px">{{
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.shopDrawing')
|
||||
$t("message.companyDiagram.dialog_ProjectPop_up.shopDrawing")
|
||||
}}</span>
|
||||
<span class="width_65">
|
||||
<img
|
||||
@ -275,8 +268,8 @@
|
||||
cursor: pointer;
|
||||
"
|
||||
@click="
|
||||
bigImageDialog = true
|
||||
bigImageUrl = projectDetail.constructionMapUrl
|
||||
bigImageDialog = true;
|
||||
bigImageUrl = projectDetail.constructionMapUrl;
|
||||
"
|
||||
/>
|
||||
</span>
|
||||
@ -382,7 +375,7 @@
|
||||
<template slot="append">
|
||||
<el-link type="primary" @click="toGetLocalFn">{{
|
||||
$t(
|
||||
'message.companyDiagram.dialog_ProjectPop_up.coordinatePicking'
|
||||
"message.companyDiagram.dialog_ProjectPop_up.coordinatePicking"
|
||||
)
|
||||
}}</el-link>
|
||||
</template>
|
||||
@ -466,20 +459,6 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
v-if="company == 'gsgs'"
|
||||
:label="
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.bridgeLength')
|
||||
"
|
||||
prop="bridgeLength"
|
||||
>
|
||||
<el-input
|
||||
v-model="addProjectForm.bridgeLength"
|
||||
:placeholder="$t('message.companyDiagram.PleaseEnter')"
|
||||
type="number"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
v-else
|
||||
:label="
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.projectAcreage')
|
||||
"
|
||||
@ -491,7 +470,6 @@
|
||||
type="number"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item
|
||||
:label="
|
||||
$t('message.companyDiagram.dialog_ProjectPop_up.bulidStatus')
|
||||
@ -546,11 +524,11 @@
|
||||
:value="Number(item.data)"
|
||||
></el-option>
|
||||
<!-- <el-option
|
||||
v-for="item in $t('message.companyDiagram.CONSTRUCTIONSTAGE')"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option> -->
|
||||
v-for="item in $t('message.companyDiagram.CONSTRUCTIONSTAGE')"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option> -->
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
@ -600,10 +578,10 @@
|
||||
<div style="width: 280px">
|
||||
<el-radio v-model="addProjectForm.majorProjectType" :label="1">
|
||||
<!-- 是 -->
|
||||
{{ $t('message.projectInfo.is') }}
|
||||
{{ $t("message.projectInfo.is") }}
|
||||
</el-radio>
|
||||
<el-radio v-model="addProjectForm.majorProjectType" :label="0">
|
||||
{{ $t('message.projectInfo.isNot') }}
|
||||
{{ $t("message.projectInfo.isNot") }}
|
||||
<!-- 否 -->
|
||||
</el-radio>
|
||||
</div>
|
||||
@ -665,14 +643,14 @@
|
||||
@click="addProjectDialog = false"
|
||||
icon="el-icon-circle-close"
|
||||
size="medium"
|
||||
>{{ $t('message.companyDiagram.cancel') }}</el-button
|
||||
>{{ $t("message.companyDiagram.cancel") }}</el-button
|
||||
>
|
||||
<el-button
|
||||
type="primary"
|
||||
icon="el-icon-circle-check"
|
||||
@click="saveProjectFn"
|
||||
size="medium"
|
||||
>{{ $t('message.companyDiagram.determine') }}</el-button
|
||||
>{{ $t("message.companyDiagram.determine") }}</el-button
|
||||
>
|
||||
</div>
|
||||
</el-form>
|
||||
@ -695,15 +673,18 @@
|
||||
></gd-map>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
checkPhone
|
||||
} from '@/assets/js/util.js'
|
||||
<script>
|
||||
import { checkPhone } from "@/assets/js/util.js";
|
||||
import {
|
||||
sendSafetyHatProjectDataApi,
|
||||
getDictionaryItemApi
|
||||
getDictionaryItemApi,
|
||||
} from "@/assets/js/api/companyDiagram.js";
|
||||
import { getProjectDetail, editProjectInfo, sendProjectInfo, getProjectConfigListApi } from "@/assets/js/api/baseInfo.js";
|
||||
import {
|
||||
getProjectDetail,
|
||||
editProjectInfo,
|
||||
sendProjectInfo,
|
||||
getProjectConfigListApi,
|
||||
} from "@/assets/js/api/baseInfo.js";
|
||||
import { selectProvincesCityListApi } from "@/assets/js/api/project.js";
|
||||
import scroll from "vue-seamless-scroll";
|
||||
import gdMap from "../../../components/map/gd-map";
|
||||
@ -726,7 +707,9 @@ export default {
|
||||
}
|
||||
};
|
||||
return {
|
||||
projectDialogTitle: /* "编辑项目", */ this.$t('message.projectInfo.editProject'),
|
||||
projectDialogTitle: /* "编辑项目", */ this.$t(
|
||||
"message.projectInfo.editProject"
|
||||
),
|
||||
addProjectDialog: false,
|
||||
addProjectForm: {
|
||||
areaCode: "",
|
||||
@ -739,10 +722,9 @@ export default {
|
||||
households: "",
|
||||
latitude: "",
|
||||
layoutImage: "",
|
||||
constructionMapUrl: '',
|
||||
constructionMapUrl: "",
|
||||
longitude: "",
|
||||
projectAcreage: "",
|
||||
bridgeLength: "",
|
||||
projectAddress: "",
|
||||
projectName: "",
|
||||
projectNumber: "",
|
||||
@ -753,7 +735,7 @@ export default {
|
||||
structureType: "",
|
||||
projectManage: "",
|
||||
projectTel: "",
|
||||
majorProjectType: 0
|
||||
majorProjectType: 0,
|
||||
},
|
||||
projectDetail: {
|
||||
areaCode: "",
|
||||
@ -766,10 +748,9 @@ export default {
|
||||
households: "",
|
||||
latitude: "",
|
||||
layoutImage: "",
|
||||
constructionMapUrl: '',
|
||||
constructionMapUrl: "",
|
||||
longitude: "",
|
||||
projectAcreage: "",
|
||||
bridgeLength: "",
|
||||
projectAddress: "",
|
||||
projectName: "",
|
||||
projectNumber: "",
|
||||
@ -894,8 +875,8 @@ export default {
|
||||
value: "code",
|
||||
},
|
||||
showMap: false,
|
||||
projectAuditStatus: '',//审核状态
|
||||
company: '',
|
||||
projectAuditStatus: "", //审核状态
|
||||
company: "",
|
||||
constructionStageList: [],
|
||||
structureTypeList: [],
|
||||
projectTypeList: [],
|
||||
@ -904,78 +885,77 @@ export default {
|
||||
},
|
||||
created() {
|
||||
this.projectSn = this.$store.state.projectSn;
|
||||
this.company = COMPANY
|
||||
this.company = COMPANY;
|
||||
this.getDataDateils();
|
||||
this.loadProvincesCityList();
|
||||
this.getProjectConfigList();
|
||||
this.getDictionaryList();
|
||||
this.getDictionaryByStructure();
|
||||
this.getDicProjectTypeList();
|
||||
|
||||
},
|
||||
mounted() {
|
||||
console.log('编辑表示:',this.$store.state.userInfo);
|
||||
console.log("编辑表示:", this.$store.state.userInfo);
|
||||
},
|
||||
|
||||
methods: {
|
||||
// 获取字典工程类别列表
|
||||
// 获取字典工程类别列表
|
||||
getDicProjectTypeList(){
|
||||
// 获取字典工程类别列表
|
||||
getDicProjectTypeList() {
|
||||
getDictionaryItemApi({
|
||||
dictionaryEncoding: 'project_type',
|
||||
projectSn: this.projectSn
|
||||
}).then(res => {
|
||||
dictionaryEncoding: "project_type",
|
||||
projectSn: this.projectSn,
|
||||
}).then((res) => {
|
||||
if (res.result.length > 0) {
|
||||
this.projectTypeList = res.result
|
||||
this.projectTypeList = res.result;
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
//获取字典施工阶段
|
||||
getDictionaryList() {
|
||||
getDictionaryItemApi({
|
||||
dictionaryEncoding: 'project_construction_stage',
|
||||
projectSn: this.projectSn
|
||||
}).then(res => {
|
||||
dictionaryEncoding: "project_construction_stage",
|
||||
projectSn: this.projectSn,
|
||||
}).then((res) => {
|
||||
if (res.result.length > 0) {
|
||||
this.constructionStageList = res.result
|
||||
this.constructionStageList = res.result;
|
||||
}
|
||||
|
||||
})
|
||||
});
|
||||
},
|
||||
//获取字典 结构类型
|
||||
getDictionaryByStructure() {
|
||||
getDictionaryItemApi({
|
||||
dictionaryEncoding: 'project_structure_type',
|
||||
projectSn: this.projectSn
|
||||
}).then(res => {
|
||||
dictionaryEncoding: "project_structure_type",
|
||||
projectSn: this.projectSn,
|
||||
}).then((res) => {
|
||||
if (res.result.length > 0) {
|
||||
this.structureTypeList = res.result
|
||||
this.structureTypeList = res.result;
|
||||
}
|
||||
|
||||
})
|
||||
});
|
||||
},
|
||||
sendSafetyHatProject() {
|
||||
sendSafetyHatProjectDataApi({ projectSn: this.projectSn }).then(res => {
|
||||
sendSafetyHatProjectDataApi({ projectSn: this.projectSn }).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message.success('上传成功!')
|
||||
this.$message.success("上传成功!");
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
getProjectConfigList() {
|
||||
getProjectConfigListApi({ projectSn: this.projectSn }).then(res => {
|
||||
getProjectConfigListApi({ projectSn: this.projectSn }).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.projectAuditStatus = res.result[0].projectAuditStatus
|
||||
this.projectAuditStatus = res.result[0].projectAuditStatus;
|
||||
console.log(res.result[0].projectAuditStatus);
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
uploadThirdParty() {
|
||||
sendProjectInfo({ projectSn: this.projectSn }).then(res => {
|
||||
sendProjectInfo({ projectSn: this.projectSn }).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message.success(this.$t('message.projectInfo.updateSuccess') + '!')
|
||||
this.getProjectConfigList()
|
||||
this.$message.success(
|
||||
this.$t("message.projectInfo.updateSuccess") + "!"
|
||||
);
|
||||
this.getProjectConfigList();
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
closeMap(val) {
|
||||
this.showMap = val;
|
||||
@ -992,14 +972,22 @@ export default {
|
||||
};
|
||||
getProjectDetail(data).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.projectDetail = res.result != null ? res.result : this.projectDetail;
|
||||
this.provincesCityArr = [
|
||||
res.result.provincesCode,
|
||||
res.result.cityCode,
|
||||
res.result.areaCode,
|
||||
];
|
||||
this.projectDetail =
|
||||
res.result != null ? res.result : this.projectDetail;
|
||||
if (res.result.areaCode) {
|
||||
this.provincesCityArr = [
|
||||
res.result.provincesCode,
|
||||
res.result.cityCode,
|
||||
res.result.areaCode,
|
||||
];
|
||||
} else {
|
||||
this.provincesCityArr = [
|
||||
res.result.provincesCode,
|
||||
res.result.cityCode,
|
||||
];
|
||||
}
|
||||
this.addProjectForm = JSON.parse(JSON.stringify(res.result));
|
||||
this.$store.commit('setProDetail', res.result)
|
||||
this.$store.commit("setProDetail", res.result);
|
||||
}
|
||||
});
|
||||
},
|
||||
@ -1020,12 +1008,13 @@ export default {
|
||||
},
|
||||
//文件上传成功
|
||||
handleUploadSuccess(res, type) {
|
||||
console.log(res)
|
||||
console.log(res);
|
||||
if (type == 1) {
|
||||
this.addProjectForm.layoutImage =
|
||||
this.$store.state.FILEURL + res.data[0].imageUrl;
|
||||
} else {
|
||||
this.addProjectForm.constructionMapUrl = this.$store.state.FILEURL + res.data[0].imageUrl;
|
||||
this.addProjectForm.constructionMapUrl =
|
||||
this.$store.state.FILEURL + res.data[0].imageUrl;
|
||||
}
|
||||
},
|
||||
|
||||
@ -1039,9 +1028,12 @@ export default {
|
||||
saveProjectFn() {
|
||||
if (this.addProjectForm.projectTel) {
|
||||
if (!checkPhone(this.addProjectForm.projectTel)) {
|
||||
console.log('this.addProjectForm.projectTel', this.addProjectForm.projectTel);
|
||||
this.$message.error('请输入正确的联系电话')
|
||||
return
|
||||
console.log(
|
||||
"this.addProjectForm.projectTel",
|
||||
this.addProjectForm.projectTel
|
||||
);
|
||||
this.$message.error("请输入正确的联系电话");
|
||||
return;
|
||||
}
|
||||
}
|
||||
this.$refs["addProjectForm"].validate((valid) => {
|
||||
@ -1069,12 +1061,12 @@ export default {
|
||||
changeProvincesCity(val) {
|
||||
this.addProjectForm.provincesCode = val[0];
|
||||
this.addProjectForm.cityCode = val[1];
|
||||
this.addProjectForm.areaCode = val[2];
|
||||
this.addProjectForm.areaCode = val[2] || "";
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.flex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@ -1211,4 +1203,4 @@ export default {
|
||||
line-height: 1px !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user