| @@ -180,7 +180,7 @@ | |||||
| created() { | created() { | ||||
| let query = { | let query = { | ||||
| parentId : null, | parentId : null, | ||||
| tree:true | |||||
| tree:false | |||||
| } | } | ||||
| productTypes(query).then(response => { | productTypes(query).then(response => { | ||||
| this.productList = response.data; | this.productList = response.data; | ||||
| @@ -137,7 +137,7 @@ | |||||
| productList:[], | productList:[], | ||||
| main_content_right_header_tit:'全套服务', | main_content_right_header_tit:'全套服务', | ||||
| query:{ | query:{ | ||||
| entityId:Cookies.get('ACCESS-SESSION-ID'), | |||||
| entityId:'', | |||||
| productType:'', | productType:'', | ||||
| supplyDemandName:'' | supplyDemandName:'' | ||||
| }, | }, | ||||
| @@ -96,7 +96,7 @@ | |||||
| created() { | created() { | ||||
| let query = { | let query = { | ||||
| parentId : null, | parentId : null, | ||||
| tree:true | |||||
| tree:false | |||||
| } | } | ||||
| productTypes(query).then(response => { | productTypes(query).then(response => { | ||||
| this.productList = response.data; | this.productList = response.data; | ||||
| @@ -120,6 +120,7 @@ | |||||
| }, | }, | ||||
| created() { | created() { | ||||
| this.query.financialType = this.$route.query.type; | this.query.financialType = this.$route.query.type; | ||||
| this.query2.financialType = this.$route.query.type; | |||||
| if (this.$route.query.type == 3){this.tt = '农担'} | if (this.$route.query.type == 3){this.tt = '农担'} | ||||
| if (this.$route.query.type == 2){this.tt = '保险'} | if (this.$route.query.type == 2){this.tt = '保险'} | ||||
| if (this.$route.query.type == 1){this.tt = '贷款'} | if (this.$route.query.type == 1){this.tt = '贷款'} | ||||
| @@ -76,10 +76,7 @@ | |||||
| if(res.sysYesNo == 'Y'){ | if(res.sysYesNo == 'Y'){ | ||||
| if (res.mainImg){ | if (res.mainImg){ | ||||
| let supplyMasterMap = res.mainImg.split( "," ) | let supplyMasterMap = res.mainImg.split( "," ) | ||||
| res.mainImg2 = [] | |||||
| supplyMasterMap.map(rr=>{ | |||||
| res.mainImg2.push('/api'+rr) | |||||
| }) | |||||
| res.mainImg = '/api'+supplyMasterMap[0] | |||||
| } | } | ||||
| this.productListYes.push(res); | this.productListYes.push(res); | ||||
| } | } | ||||
| @@ -56,7 +56,8 @@ | |||||
| <van-cell title="下单时间" :border="false" :value="supplyDemand.orderAt" /> | <van-cell title="下单时间" :border="false" :value="supplyDemand.orderAt" /> | ||||
| <van-cell title="服务时间" :border="false" :value="supplyDemand.serviceAt" /> | <van-cell title="服务时间" :border="false" :value="supplyDemand.serviceAt" /> | ||||
| <van-cell title="服务数量" :border="false" :value="supplyDemand.serviceNum" /> | <van-cell title="服务数量" :border="false" :value="supplyDemand.serviceNum" /> | ||||
| <van-cell title="成交金额" :border="false" :value="supplyDemand.realityServiceMoney" /> | |||||
| <van-cell title="成交金额" :border="false" :value="supplyDemand.realityServiceMoney == null ? supplyDemand.countMoney:supplyDemand.realityServiceMoney" /> | |||||
| <van-cell title="备注" :border="false" :value="supplyDemand.serviceRemark" /> | <van-cell title="备注" :border="false" :value="supplyDemand.serviceRemark" /> | ||||
| </div> | </div> | ||||
| @@ -92,7 +93,7 @@ | |||||
| created() { | created() { | ||||
| let query = { | let query = { | ||||
| parentId : null, | parentId : null, | ||||
| tree:true | |||||
| tree:false | |||||
| } | } | ||||
| productTypes(query).then(response => { | productTypes(query).then(response => { | ||||
| this.productList = response.data; | this.productList = response.data; | ||||
| @@ -111,6 +112,7 @@ | |||||
| response.data.cropType = this.selectDictLabel(this.cropTypeOptions, response.data.cropType); | response.data.cropType = this.selectDictLabel(this.cropTypeOptions, response.data.cropType); | ||||
| response.data.orderStatus = this.selectDictLabel(this.orderStatusOptions, response.data.orderStatus); | response.data.orderStatus = this.selectDictLabel(this.orderStatusOptions, response.data.orderStatus); | ||||
| response.data.productType = this.productList.filter(function (e) { return e.id == response.data.productType; })[0].dictName; | response.data.productType = this.productList.filter(function (e) { return e.id == response.data.productType; })[0].dictName; | ||||
| response.data.countMoney = response.data.unitPrice*response.data.serviceNum; | |||||
| if (response.data.supplyDemand.supplyMasterMap){ | if (response.data.supplyDemand.supplyMasterMap){ | ||||
| var attachement = response.data.supplyDemand.supplyMasterMap.split( "," ); | var attachement = response.data.supplyDemand.supplyMasterMap.split( "," ); | ||||
| response.data.supplyDemand.supplyMasterMap = '/api' + attachement[0]; | response.data.supplyDemand.supplyMasterMap = '/api' + attachement[0]; | ||||
| @@ -25,7 +25,10 @@ | |||||
| </div> | </div> | ||||
| <div class="main_content_right_list_center"> | <div class="main_content_right_list_center"> | ||||
| <img v-if="item.supplyDemand.supplyMasterMap" :src="item.supplyDemand.supplyMasterMap" style="width: 25vw;height: 25vw;"> | |||||
| <template v-if="item.supplyDemand"> | |||||
| <img v-if="item.supplyDemand.supplyMasterMap" :src="item.supplyDemand.supplyMasterMap" style="width: 25vw;height: 25vw;"> | |||||
| <img v-else src="../../../../static/images/agriculturalTrusteeship/zwtp.png" style="width: 25vw;height: 25vw;"> | |||||
| </template> | |||||
| <img v-else src="../../../../static/images/agriculturalTrusteeship/zwtp.png" style="width: 25vw;height: 25vw;"> | <img v-else src="../../../../static/images/agriculturalTrusteeship/zwtp.png" style="width: 25vw;height: 25vw;"> | ||||
| <div class="main_content_right_list_content"> | <div class="main_content_right_list_content"> | ||||
| <p class="tt">{{item.contractionName}}</p> | <p class="tt">{{item.contractionName}}</p> | ||||
| @@ -116,9 +119,11 @@ | |||||
| supplyorderList(this.query).then(response => { | supplyorderList(this.query).then(response => { | ||||
| response.rows.map(res=>{ | response.rows.map(res=>{ | ||||
| if ( res.orderStatus == '1'){ | if ( res.orderStatus == '1'){ | ||||
| if (res.supplyDemand.supplyMasterMap){ | |||||
| let supplyMasterMap = res.supplyDemand.supplyMasterMap.split( "," ) | |||||
| res.supplyDemand.supplyMasterMap = '/api'+supplyMasterMap[0] | |||||
| if (res.supplyDemand){ | |||||
| if (res.supplyDemand.supplyMasterMap){ | |||||
| let supplyMasterMap = res.supplyDemand.supplyMasterMap.split( "," ) | |||||
| res.supplyDemand.supplyMasterMap = '/api'+supplyMasterMap[0] | |||||
| } | |||||
| } | } | ||||
| res.cropType = this.selectDictLabel(this.cropTypeOptions, res.cropType); | res.cropType = this.selectDictLabel(this.cropTypeOptions, res.cropType); | ||||
| res.orderStatus = this.selectDictLabel(this.orderStatusOptions, res.orderStatus); | res.orderStatus = this.selectDictLabel(this.orderStatusOptions, res.orderStatus); | ||||
| @@ -23,7 +23,7 @@ | |||||
| <p><span>销 {{supplyDemand.orderNum}}</span><span>分 {{supplyDemand.orderScore}}</span></p> | <p><span>销 {{supplyDemand.orderNum}}</span><span>分 {{supplyDemand.orderScore}}</span></p> | ||||
| </div> | </div> | ||||
| <p class="tt">{{supplyDemand.supplyDemandName}}</p> | <p class="tt">{{supplyDemand.supplyDemandName}}</p> | ||||
| <p class="name" @click="$router.push({name:'agriculturalTrusteeshipSocietyProjectList',query:{id:supplyDemand.id,entityName:supplyDemand.entityName}})">{{supplyDemand.entityName}}<span>{{supplyDemand.createTime}}</span></p> | |||||
| <p class="name" @click="$router.push({name:'agriculturalTrusteeshipSocietyProjectList',query:{id:supplyDemand.entityId,entityName:supplyDemand.entityName}})">{{supplyDemand.entityName}}<span>{{supplyDemand.createTime}}</span></p> | |||||
| </div> | </div> | ||||
| <div class="main_box"> | <div class="main_box"> | ||||
| @@ -108,6 +108,7 @@ | |||||
| supplyDemandGet(this.$route.query.id).then(response => { | supplyDemandGet(this.$route.query.id).then(response => { | ||||
| response.data.bodyType = this.selectDictLabel(this.bodyTypeOptions, response.data.bodyType); | response.data.bodyType = this.selectDictLabel(this.bodyTypeOptions, response.data.bodyType); | ||||
| response.data.productType = this.productList1.filter(function (e) { return e.id == response.data.productType; })[0].dictName; | response.data.productType = this.productList1.filter(function (e) { return e.id == response.data.productType; })[0].dictName; | ||||
| response.data.createTime = response.data.createTime.substr(0,10) | |||||
| if (response.data.supplyMasterMap){ | if (response.data.supplyMasterMap){ | ||||
| response.data.supplyMasterMapList = []; | response.data.supplyMasterMapList = []; | ||||
| var attachement = response.data.supplyMasterMap.split( "," ); | var attachement = response.data.supplyMasterMap.split( "," ); | ||||
| @@ -12,6 +12,7 @@ | |||||
| <!-- 内容开始 --> | <!-- 内容开始 --> | ||||
| <van-form @submit="submitForm" ref="formData" show-error :show-error-message="false"> | |||||
| <div class="main"> | <div class="main"> | ||||
| <van-field label="产品名称" v-model="supplyDemand.supplyDemandName" input-align="right" placeholder="请输入产品名称" /> | <van-field label="产品名称" v-model="supplyDemand.supplyDemandName" input-align="right" placeholder="请输入产品名称" /> | ||||
| <!-- <van-field label="产品类型" v-model="supplyDemand.productType" input-align="right" placeholder="请输入产品类型" />--> | <!-- <van-field label="产品类型" v-model="supplyDemand.productType" input-align="right" placeholder="请输入产品类型" />--> | ||||
| @@ -43,28 +44,29 @@ | |||||
| <!-- <van-field label="二级分类" v-model="supplyDemand.supplyDemandType" input-align="right" placeholder="请输入二级分类" />--> | <!-- <van-field label="二级分类" v-model="supplyDemand.supplyDemandType" input-align="right" placeholder="请输入二级分类" />--> | ||||
| <van-field label="产品规格" v-model="supplyDemand.specification" input-align="right" placeholder="请输入产品规格" /> | <van-field label="产品规格" v-model="supplyDemand.specification" input-align="right" placeholder="请输入产品规格" /> | ||||
| <!-- <van-field label="所属主体" v-model="supplyDemand.bodyType" input-align="right" placeholder="请输入所属主体" />--> | <!-- <van-field label="所属主体" v-model="supplyDemand.bodyType" input-align="right" placeholder="请输入所属主体" />--> | ||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| required | |||||
| :rules="[{ required: true , message:'请选择所属主体'}]" | |||||
| v-model="bodyType" | |||||
| label="所属主体" | |||||
| placeholder="请选择所属主体" | |||||
| @click="showBodyType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| /> | |||||
| <van-popup v-model="showBodyType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="projectTypeOptions" | |||||
| @confirm="onConfirmProjectType" | |||||
| @cancel="showBodyType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <!-- <van-field--> | |||||
| <!-- readonly--> | |||||
| <!-- clickable--> | |||||
| <!-- required--> | |||||
| <!-- :rules="[{ required: true , message:'请选择所属主体'}]"--> | |||||
| <!-- v-model="bodyType"--> | |||||
| <!-- label="所属主体"--> | |||||
| <!-- placeholder="请选择所属主体"--> | |||||
| <!-- @click="showBodyType = true"--> | |||||
| <!-- input-align="right"--> | |||||
| <!-- right-icon="arrow-down"--> | |||||
| <!-- label-width="auto"--> | |||||
| <!-- />--> | |||||
| <!-- <van-popup v-model="showBodyType" position="bottom">--> | |||||
| <!-- <van-picker--> | |||||
| <!-- show-toolbar--> | |||||
| <!-- :columns="projectTypeOptions"--> | |||||
| <!-- @confirm="onConfirmProjectType"--> | |||||
| <!-- @cancel="showBodyType = false"--> | |||||
| <!-- />--> | |||||
| <!-- </van-popup>--> | |||||
| <van-field label="所属主体" v-model="supplyDemand.entityName" input-align="right" placeholder="请输入所属主体" /> | |||||
| <van-field label="单价" v-model="supplyDemand.unitPrice" input-align="right" placeholder="请输入单价" /> | <van-field label="单价" v-model="supplyDemand.unitPrice" input-align="right" placeholder="请输入单价" /> | ||||
| <van-field label="数量" v-model="supplyDemand.number" input-align="right" placeholder="请输入数量" /> | <van-field label="数量" v-model="supplyDemand.number" input-align="right" placeholder="请输入数量" /> | ||||
| <van-field label="单位" v-model="supplyDemand.unit" input-align="right" placeholder="请输入单位" /> | <van-field label="单位" v-model="supplyDemand.unit" input-align="right" placeholder="请输入单位" /> | ||||
| @@ -87,9 +89,10 @@ | |||||
| </div> | </div> | ||||
| <div class="main_btn"> | <div class="main_btn"> | ||||
| <p @click="submitForm('3')">发布</p> | |||||
| <p @click="submitForm('2')">存稿</p> | |||||
| <p @click="publishStatus = '3',$refs.formData.submit()">发布</p> | |||||
| <p @click="publishStatus = '2',$refs.formData.submit()">存稿</p> | |||||
| </div> | </div> | ||||
| </van-form> | |||||
| <!-- 内容结束 --> | <!-- 内容结束 --> | ||||
| </div> | </div> | ||||
| </template> | </template> | ||||
| @@ -130,7 +133,7 @@ | |||||
| value: 'id', | value: 'id', | ||||
| children: 'children', | children: 'children', | ||||
| }, | }, | ||||
| publishStatus:'' | |||||
| }; | }; | ||||
| }, | }, | ||||
| created() { | created() { | ||||
| @@ -200,7 +203,7 @@ | |||||
| submitForm(publishStatus){ | submitForm(publishStatus){ | ||||
| this.supplyDemand.supplyMasterMap = this.supplyMasterMapArr.join(',') | this.supplyDemand.supplyMasterMap = this.supplyMasterMapArr.join(',') | ||||
| this.supplyDemand.supplyDemandType = '1'; | this.supplyDemand.supplyDemandType = '1'; | ||||
| this.supplyDemand.publishStatus = publishStatus; | |||||
| this.supplyDemand.publishStatus = this.publishStatus; | |||||
| supplyDemandEdit(this.supplyDemand).then((res) => { | supplyDemandEdit(this.supplyDemand).then((res) => { | ||||
| if(res.code=="200"){ | if(res.code=="200"){ | ||||
| if (publishStatus == '3'){ | if (publishStatus == '3'){ | ||||
| @@ -12,85 +12,89 @@ | |||||
| <!-- 内容开始 --> | <!-- 内容开始 --> | ||||
| <div class="main"> | |||||
| <van-field label="产品名称" v-model="supplyDemand.supplyDemandName" input-align="right" placeholder="请输入产品名称" /> | |||||
| <!-- <van-field label="产品类型" v-model="supplyDemand.productType" input-align="right" placeholder="请输入产品类型" />--> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| required | |||||
| :rules="[{ required: true , message:'请选择产品类型'}]" | |||||
| v-model="productType" | |||||
| label="产品类型" | |||||
| placeholder="请选择产品类型" | |||||
| @click="showProductType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| /> | |||||
| <van-popup v-model="showProductType" round position="bottom"> | |||||
| <!-- v-model="cascaderValue"--> | |||||
| <van-cascader | |||||
| title="请选择产品类型" | |||||
| :options="productList" | |||||
| @close="showProductType = false" | |||||
| @finish="onConfirmProductType" | |||||
| :field-names="fieldNames" | |||||
| <van-form @submit="submitForm" ref="formData" show-error :show-error-message="false"> | |||||
| <div class="main"> | |||||
| <van-field label="产品名称" required :rules="[{ required: true }]" v-model="supplyDemand.supplyDemandName" input-align="right" placeholder="请输入产品名称" /> | |||||
| <!-- <van-field label="产品类型" v-model="supplyDemand.productType" input-align="right" placeholder="请输入产品类型" />--> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| required | |||||
| :rules="[{ required: true , message:'请选择产品类型'}]" | |||||
| v-model="productType" | |||||
| label="产品类型" | |||||
| placeholder="请选择产品类型" | |||||
| @click="showProductType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| /> | /> | ||||
| </van-popup> | |||||
| <!-- <van-field label="二级分类" v-model="supplyDemand.supplyDemandType" input-align="right" placeholder="请输入二级分类" />--> | |||||
| <van-field label="产品规格" v-model="supplyDemand.specification" input-align="right" placeholder="请输入产品规格" /> | |||||
| <!-- <van-field label="所属主体" v-model="supplyDemand.bodyType" input-align="right" placeholder="请输入所属主体" />--> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| required | |||||
| :rules="[{ required: true , message:'请选择所属主体'}]" | |||||
| v-model="bodyType" | |||||
| label="所属主体" | |||||
| placeholder="请选择所属主体" | |||||
| @click="showBodyType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| /> | |||||
| <van-popup v-model="showBodyType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="projectTypeOptions" | |||||
| @confirm="onConfirmProjectType" | |||||
| @cancel="showBodyType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-popup v-model="showProductType" round position="bottom"> | |||||
| <!-- v-model="cascaderValue"--> | |||||
| <van-cascader | |||||
| title="请选择产品类型" | |||||
| :options="productList" | |||||
| @close="showProductType = false" | |||||
| @finish="onConfirmProductType" | |||||
| :field-names="fieldNames" | |||||
| /> | |||||
| </van-popup> | |||||
| <!-- <van-field label="二级分类" v-model="supplyDemand.supplyDemandType" input-align="right" placeholder="请输入二级分类" />--> | |||||
| <van-field label="产品规格" required :rules="[{ required: true }]" v-model="supplyDemand.specification" input-align="right" placeholder="请输入产品规格" /> | |||||
| <!-- <van-field label="所属主体" v-model="supplyDemand.bodyType" input-align="right" placeholder="请输入所属主体" />--> | |||||
| <!-- <van-field--> | |||||
| <!-- readonly--> | |||||
| <!-- clickable--> | |||||
| <!-- required--> | |||||
| <!-- :rules="[{ required: true , message:'请选择所属主体'}]"--> | |||||
| <!-- v-model="bodyType"--> | |||||
| <!-- label="所属主体"--> | |||||
| <!-- placeholder="请选择所属主体"--> | |||||
| <!-- @click="showBodyType = true"--> | |||||
| <!-- input-align="right"--> | |||||
| <!-- right-icon="arrow-down"--> | |||||
| <!-- label-width="auto"--> | |||||
| <!-- />--> | |||||
| <!-- <van-popup v-model="showBodyType" position="bottom">--> | |||||
| <!-- <van-picker--> | |||||
| <!-- show-toolbar--> | |||||
| <!-- :columns="projectTypeOptions"--> | |||||
| <!-- @confirm="onConfirmProjectType"--> | |||||
| <!-- @cancel="showBodyType = false"--> | |||||
| <!-- />--> | |||||
| <!-- </van-popup>--> | |||||
| <van-field label="单价" v-model="supplyDemand.unitPrice" type="number" input-align="right" placeholder="请输入单价" /> | |||||
| <van-field label="数量" v-model="supplyDemand.number" type="digit" input-align="right" placeholder="请输入数量" /> | |||||
| <van-field label="单位" v-model="supplyDemand.unit" input-align="right" placeholder="请输入单位" /> | |||||
| <van-field label="联系电话" v-model="supplyDemand.supplyDemandTal" type="digit" input-align="right" placeholder="请输入联系电话" /> | |||||
| <van-field label="联系人" v-model="supplyDemand.linker" input-align="right" placeholder="请输入联系人" /> | |||||
| <van-field label="服务区域" v-model="supplyDemand.serviceDeptName" input-align="right" placeholder="请输入服务区域" /> | |||||
| <van-field label="地址" v-model="supplyDemand.address" input-align="right" placeholder="请输入地址" /> | |||||
| <van-field label="简介" v-model="supplyDemand.introduction" type="textarea" autosize input-align="right" placeholder="请输入简介" /> | |||||
| <van-field label="详情" v-model="supplyDemand.particulars" type="textarea" autosize input-align="right" placeholder="请输入详情" /> | |||||
| <van-field label="图片" :border="false" input-align="right" readonly /> | |||||
| <div style="padding: 0 4% 2vh;"> | |||||
| <van-uploader v-model="supplyDemand.supplyMasterMapList" :after-read="afterReadEvidenceForm" :before-delete="deleteFileEvidenceForm" /> | |||||
| <van-field label="所属主体" required :rules="[{ required: true }]" v-model="supplyDemand.entityName" input-align="right" placeholder="请输入所属主体" /> | |||||
| <van-field label="单价" required :rules="[{ required: true }]" v-model="supplyDemand.unitPrice" type="number" input-align="right" placeholder="请输入单价" /> | |||||
| <van-field label="数量" required :rules="[{ required: true }]" v-model="supplyDemand.number" type="digit" input-align="right" placeholder="请输入数量" /> | |||||
| <van-field label="单位" required :rules="[{ required: true }]" v-model="supplyDemand.unit" input-align="right" placeholder="请输入单位" /> | |||||
| <van-field label="联系电话" required :rules="[{ required: true }]" v-model="supplyDemand.supplyDemandTal" type="digit" input-align="right" placeholder="请输入联系电话" /> | |||||
| <van-field label="联系人" required :rules="[{ required: true }]" v-model="supplyDemand.linker" input-align="right" placeholder="请输入联系人" /> | |||||
| <van-field label="服务区域" required :rules="[{ required: true }]" v-model="supplyDemand.serviceDeptName" input-align="right" placeholder="请输入服务区域" /> | |||||
| <van-field label="地址" required :rules="[{ required: true }]" v-model="supplyDemand.address" input-align="right" placeholder="请输入地址" /> | |||||
| <van-field label="简介" required :rules="[{ required: true }]" v-model="supplyDemand.introduction" type="textarea" autosize input-align="right" placeholder="请输入简介" /> | |||||
| <van-field label="详情" required :rules="[{ required: true }]" v-model="supplyDemand.particulars" type="textarea" autosize input-align="right" placeholder="请输入详情" /> | |||||
| <van-field label="图片" :border="false" input-align="right" readonly /> | |||||
| <div style="padding: 0 4% 2vh;"> | |||||
| <van-uploader v-model="supplyDemand.supplyMasterMapList" :after-read="afterReadEvidenceForm" :before-delete="deleteFileEvidenceForm" /> | |||||
| </div> | |||||
| </div> | </div> | ||||
| </div> | |||||
| <div class="main"> | |||||
| <baidu-map :center="center" panBy="[50,50]" :zoom="zoom" :scroll-wheel-zoom="true" :pinch-to-zoom="true" map-type="BMAP_NORMAL_MAP" style="height:25vh" > | |||||
| <!-- 必须给容器指高度,不然地图将显示在一个高度为0的容器中,看不到 --> | |||||
| <bm-marker :position="center" :dragging="true" animation="BMAP_ANIMATION_BOUNCE" :icon="{url: '../../../../static/images/lawEnforcement/new/address.gif', size: {width: 50, height: 50}}"></bm-marker> | |||||
| </baidu-map> | |||||
| </div> | |||||
| <div class="main"> | |||||
| <baidu-map :center="center" panBy="[50,50]" :zoom="zoom" :scroll-wheel-zoom="true" :pinch-to-zoom="true" map-type="BMAP_NORMAL_MAP" style="height:25vh" > | |||||
| <!-- 必须给容器指高度,不然地图将显示在一个高度为0的容器中,看不到 --> | |||||
| <bm-marker :position="center" :dragging="true" animation="BMAP_ANIMATION_BOUNCE" :icon="{url: '../../../../static/images/lawEnforcement/new/address.gif', size: {width: 50, height: 50}}"></bm-marker> | |||||
| </baidu-map> | |||||
| </div> | |||||
| <div class="main_btn"> | |||||
| <p @click="submitForm('3')">发布</p> | |||||
| <p @click="submitForm('2')">存稿</p> | |||||
| </div> | |||||
| <div class="main_btn"> | |||||
| <p @click="publishStatus = '3',$refs.formData.submit()">发布</p> | |||||
| <p @click="publishStatus = '2',$refs.formData.submit()">存稿</p> | |||||
| </div> | |||||
| </van-form> | |||||
| <!-- 内容结束 --> | <!-- 内容结束 --> | ||||
| </div> | </div> | ||||
| </template> | </template> | ||||
| @@ -125,6 +129,7 @@ | |||||
| value: 'id', | value: 'id', | ||||
| children: 'children', | children: 'children', | ||||
| }, | }, | ||||
| publishStatus:'' | |||||
| }; | }; | ||||
| }, | }, | ||||
| created() { | created() { | ||||
| @@ -181,7 +186,7 @@ | |||||
| submitForm(publishStatus){ | submitForm(publishStatus){ | ||||
| this.supplyDemand.supplyMasterMap = this.supplyMasterMapArr.join(',') | this.supplyDemand.supplyMasterMap = this.supplyMasterMapArr.join(',') | ||||
| this.supplyDemand.supplyDemandType = '1'; | this.supplyDemand.supplyDemandType = '1'; | ||||
| this.supplyDemand.publishStatus = publishStatus; | |||||
| this.supplyDemand.publishStatus = this.publishStatus; | |||||
| supplyDemandAdd(this.supplyDemand).then((res) => { | supplyDemandAdd(this.supplyDemand).then((res) => { | ||||
| if(res.code=="200"){ | if(res.code=="200"){ | ||||
| if (publishStatus == '3'){ | if (publishStatus == '3'){ | ||||
| @@ -2,7 +2,7 @@ | |||||
| <div class="home_wrapper"> | <div class="home_wrapper"> | ||||
| <!-- 头部开始 --> | <!-- 头部开始 --> | ||||
| <div class="header"> | <div class="header"> | ||||
| <div class="header_left" @click="onClickLeft"> | |||||
| <div class="header_left" @click="$router.push({name:'agriculturalTrusteeshipLogin'})"> | |||||
| <img src="../../../../static/images/agriculturalTrusteeship/return.png"> | <img src="../../../../static/images/agriculturalTrusteeship/return.png"> | ||||
| <p>退出登录</p> | <p>退出登录</p> | ||||
| </div> | </div> | ||||
| @@ -23,7 +23,7 @@ | |||||
| <p><span>销 {{supplyDemand.orderNum}}</span><span>分 {{supplyDemand.orderScore}}</span></p> | <p><span>销 {{supplyDemand.orderNum}}</span><span>分 {{supplyDemand.orderScore}}</span></p> | ||||
| </div> | </div> | ||||
| <p class="tt">{{supplyDemand.supplyDemandName}}</p> | <p class="tt">{{supplyDemand.supplyDemandName}}</p> | ||||
| <p class="name">{{supplyDemand.entityName}}<span>{{supplyDemand.createTime.substr(0,10)}}</span></p> | |||||
| <p class="name" @click="$router.push({name:'agriculturalTrusteeshipSocietyProjectList',query:{id:supplyDemand.entityId,entityName:supplyDemand.entityName}})">{{supplyDemand.entityName}}<span>{{supplyDemand.createTime}}</span></p> | |||||
| </div> | </div> | ||||
| <div class="main_box"> | <div class="main_box"> | ||||
| @@ -41,9 +41,15 @@ | |||||
| </div> | </div> | ||||
| <div class="main_box" style="padding: 0;"> | <div class="main_box" style="padding: 0;"> | ||||
| <baidu-map :center="center" panBy="[50,50]" :zoom="zoom" :scroll-wheel-zoom="true" :pinch-to-zoom="true" map-type="BMAP_NORMAL_MAP" style="height:25vh" > | |||||
| <baidu-map | |||||
| :center="center" | |||||
| panBy="[50,50]" | |||||
| :zoom="zoom" | |||||
| :scroll-wheel-zoom="true" | |||||
| :pinch-to-zoom="true" | |||||
| map-type="BMAP_NORMAL_MAP" | |||||
| style="height:25vh" > | |||||
| <!-- 必须给容器指高度,不然地图将显示在一个高度为0的容器中,看不到 --> | <!-- 必须给容器指高度,不然地图将显示在一个高度为0的容器中,看不到 --> | ||||
| <bm-geolocation anchor="BMAP_ANCHOR_BOTTOM_RIGHT" :showAddressBar="true" :autoLocation="true"></bm-geolocation> | |||||
| <bm-marker :position="center" :dragging="true" animation="BMAP_ANIMATION_BOUNCE" :icon="{url: '../../../../static/images/lawEnforcement/new/address.gif', size: {width: 50, height: 50}}"></bm-marker> | <bm-marker :position="center" :dragging="true" animation="BMAP_ANIMATION_BOUNCE" :icon="{url: '../../../../static/images/lawEnforcement/new/address.gif', size: {width: 50, height: 50}}"></bm-marker> | ||||
| </baidu-map> | </baidu-map> | ||||
| </div> | </div> | ||||
| @@ -68,8 +74,11 @@ | |||||
| active: 0, | active: 0, | ||||
| loading: false, | loading: false, | ||||
| finished: false, | finished: false, | ||||
| center: { lng: 122.089726, lat: 37.540728 }, //经纬度 | |||||
| zoom: 15, //地图展示级别 | |||||
| center: { | |||||
| lng :'', | |||||
| lat :'', | |||||
| }, //经纬度 | |||||
| zoom: 1, //地图展示级别 | |||||
| showDialog:false, | showDialog:false, | ||||
| supplyDemand:{}, | supplyDemand:{}, | ||||
| productType:'', | productType:'', | ||||
| @@ -90,17 +99,12 @@ | |||||
| }, | }, | ||||
| created() { | created() { | ||||
| let query = { | let query = { | ||||
| parentId : '' | |||||
| } | |||||
| let query1 = { | |||||
| tree : true | |||||
| parentId : '', | |||||
| tree : false | |||||
| } | } | ||||
| productTypes(query).then(response => { | productTypes(query).then(response => { | ||||
| this.productList = response.data; | this.productList = response.data; | ||||
| }); | }); | ||||
| productTypes(query1).then(response => { | |||||
| this.productList1 = response.data; | |||||
| }); | |||||
| this.getDicts("newBusinessEntity_statistics_project").then(response => { | this.getDicts("newBusinessEntity_statistics_project").then(response => { | ||||
| for (var i = 0; i < response.data.length; i++) { | for (var i = 0; i < response.data.length; i++) { | ||||
| this.projectTypeOptions.push({text: response.data[i].dictLabel, value: response.data[i].dictValue}); | this.projectTypeOptions.push({text: response.data[i].dictLabel, value: response.data[i].dictValue}); | ||||
| @@ -113,14 +117,23 @@ | |||||
| getDetail(){ | getDetail(){ | ||||
| supplyDemandGet(this.$route.query.id).then(response => { | supplyDemandGet(this.$route.query.id).then(response => { | ||||
| response.data.bodyType = this.selectDictLabel(this.bodyTypeOptions, response.data.bodyType); | response.data.bodyType = this.selectDictLabel(this.bodyTypeOptions, response.data.bodyType); | ||||
| response.data.productType = this.productList1.filter(function (e) { return e.id == response.data.productType; })[0].dictName; | |||||
| response.data.productType = this.productList.filter(function (e) { return e.id == response.data.productType; })[0].dictName; | |||||
| response.data.createTime = response.data.createTime.substr(0,10); | |||||
| response.data.supplyMasterMapList = []; | |||||
| if (response.data.theGeom){ | |||||
| console.log(JSON.parse(response.data.theGeom).coordinates[0]) | |||||
| console.log(JSON.parse(response.data.theGeom).coordinates[1]) | |||||
| this.center.lng = JSON.parse(response.data.theGeom).coordinates[0]; | |||||
| this.center.lat = JSON.parse(response.data.theGeom).coordinates[1]; | |||||
| } | |||||
| if (response.data.supplyMasterMap){ | if (response.data.supplyMasterMap){ | ||||
| response.data.supplyMasterMapList = []; | |||||
| var attachement = response.data.supplyMasterMap.split( "," ); | var attachement = response.data.supplyMasterMap.split( "," ); | ||||
| this.supplyMasterMapArr = response.data.supplyMasterMap.split( "," ); | this.supplyMasterMapArr = response.data.supplyMasterMap.split( "," ); | ||||
| attachement.forEach(responseAttach=>{ | attachement.forEach(responseAttach=>{ | ||||
| response.data.supplyMasterMapList.push('/api' + responseAttach); | response.data.supplyMasterMapList.push('/api' + responseAttach); | ||||
| }) | }) | ||||
| }else{ | |||||
| response.data.supplyMasterMapList.push('../../../../static/images/agriculturalTrusteeship/zwtp.png') | |||||
| } | } | ||||
| this.supplyDemand = response.data; | this.supplyDemand = response.data; | ||||
| }); | }); | ||||
| @@ -131,6 +144,7 @@ | |||||
| <style scoped lang="scss"> | <style scoped lang="scss"> | ||||
| .home_wrapper{ | .home_wrapper{ | ||||
| padding-bottom: 15vh; | padding-bottom: 15vh; | ||||
| background-color: #F9F9F9; | |||||
| } | } | ||||
| /*头部*/ | /*头部*/ | ||||
| .header{ | .header{ | ||||