| @@ -0,0 +1,72 @@ | |||||
| import request from '@/utils/request' | |||||
| // 查询产业信息列表 | |||||
| export function listIndustry(query) { | |||||
| return request({ | |||||
| url: '/asset/industry/list', | |||||
| method: 'get', | |||||
| params: query | |||||
| }) | |||||
| } | |||||
| // 统计查询产业信息列表 | |||||
| export function statisticIndustry(query) { | |||||
| return request({ | |||||
| url: '/asset/industry/statistic', | |||||
| method: 'get', | |||||
| params: query | |||||
| }) | |||||
| } | |||||
| // 导出产业信息 | |||||
| export function exportIndustry(query) { | |||||
| return request({ | |||||
| url: '/asset/industry/export', | |||||
| method: 'get', | |||||
| params: query | |||||
| }) | |||||
| } | |||||
| // 查询产业信息详细 | |||||
| export function getIndustry(id) { | |||||
| return request({ | |||||
| url: '/asset/industry/get/' + id, | |||||
| method: 'get', | |||||
| params: arguments[1] || {} | |||||
| }) | |||||
| } | |||||
| // 新增产业信息 | |||||
| export function addIndustry(data) { | |||||
| return request({ | |||||
| url: '/asset/industry/add', | |||||
| method: 'post', | |||||
| data: data | |||||
| }) | |||||
| } | |||||
| // 修改产业信息 | |||||
| export function updateIndustry(data) { | |||||
| return request({ | |||||
| url: '/asset/industry/edit', | |||||
| method: 'post', | |||||
| data: data | |||||
| }) | |||||
| } | |||||
| // 删除产业信息 | |||||
| export function delIndustry(id) { | |||||
| return request({ | |||||
| url: '/asset/industry/remove/' + id, | |||||
| method: 'get' | |||||
| }) | |||||
| } | |||||
| // 清空空间字段 | |||||
| export function clearTheGeom(id) { | |||||
| return request({ | |||||
| url: '/asset/industry/clear/' + id, | |||||
| method: 'get', | |||||
| }) | |||||
| } | |||||
| @@ -4786,6 +4786,42 @@ export const constantRoutes = [ | |||||
| }, | }, | ||||
| component: (resolve) => require(['@/views/sunVillage_info/threeDetail'], resolve) | component: (resolve) => require(['@/views/sunVillage_info/threeDetail'], resolve) | ||||
| }, | }, | ||||
| { ////阳光村务(新)-- 产业信息管理 | |||||
| path: '/sunVillage_info/industry', | |||||
| name: 'sunVillageInfoListIndustry', | |||||
| meta: { | |||||
| title: '产业信息管理', | |||||
| hidden: true, | |||||
| }, | |||||
| component: (resolve) => require(['@/views/sunVillage_info/industry'], resolve) | |||||
| }, | |||||
| { ////阳光村务(新)-- 新增产业信息 | |||||
| path: '/sunVillage_info/industryAdd', | |||||
| name: 'sunVillageInfoListIndustryAdd', | |||||
| meta: { | |||||
| title: '新增产业信息', | |||||
| hidden: true, | |||||
| }, | |||||
| component: (resolve) => require(['@/views/sunVillage_info/industryAdd'], resolve) | |||||
| }, | |||||
| { ////阳光村务(新)-- 修改产业信息 | |||||
| path: '/sunVillage_info/industryEdit', | |||||
| name: 'sunVillageInfoListIndustryEdit', | |||||
| meta: { | |||||
| title: '修改产业信息', | |||||
| hidden: true, | |||||
| }, | |||||
| component: (resolve) => require(['@/views/sunVillage_info/industryEdit'], resolve) | |||||
| }, | |||||
| { ////阳光村务(新)-- 产业信息详情 | |||||
| path: '/sunVillage_info/industryDetail', | |||||
| name: 'sunVillageInfoListIndustryDetail', | |||||
| meta: { | |||||
| title: '产业信息详情', | |||||
| hidden: true, | |||||
| }, | |||||
| component: (resolve) => require(['@/views/sunVillage_info/industryDetail'], resolve) | |||||
| }, | |||||
| { ////阳光村务(新)-- 修改资源 | { ////阳光村务(新)-- 修改资源 | ||||
| path: '/sunVillage_info/detailed_liabilities', | path: '/sunVillage_info/detailed_liabilities', | ||||
| name: 'sunVillageInfoDetailedLiabilities', | name: 'sunVillageInfoDetailedLiabilities', | ||||
| @@ -0,0 +1,549 @@ | |||||
| <template> | |||||
| <div class="home_wrapper"> | |||||
| <div class="header_main"> | |||||
| 产业信息管理 | |||||
| <div class="return_btn" @click="onClickLeft"></div> | |||||
| <div class="add_btn" @click="goAdd"></div> | |||||
| </div> | |||||
| <div class="search_info"> | |||||
| <div class="search_block"> | |||||
| <van-search class="search_block searchHeight" v-model="queryParams.industryName" @input="getSearchList" :placeholder="searchPlaceholder" /> | |||||
| <van-icon name="filter-o" color="#1989fa" class="filter-icon" @click="openIndustryRights" /> | |||||
| </div> | |||||
| <div class="total">共{{listLength}}个产业</div> | |||||
| </div> | |||||
| <div class="list_main"> | |||||
| <van-list | |||||
| v-model="loading" | |||||
| :finished="finished" | |||||
| finished-text="没有更多了" | |||||
| @load="getList" | |||||
| > | |||||
| <!--1--> | |||||
| <van-swipe-cell right-width="200" class="item" v-for="(item,index) in applicationList" :key="index"> | |||||
| <div class="item_box" @click="$router.push({name:'sunVillageInfoListIndustryDetail',query:{id:item.id}})"> | |||||
| <div class="head_block"> | |||||
| <i class="icon"></i> | |||||
| <div class="title">{{item.industryName}}</div> | |||||
| <div class="describe">{{item.industryRights}}</div> | |||||
| </div> | |||||
| <div class="order_block"> | |||||
| <div class="order">{{item.industryCode}}</div> | |||||
| <div class="describe">{{item.industryType}}</div> | |||||
| </div> | |||||
| </div> | |||||
| <template #right> | |||||
| <div @click="handleDelete(item,index)" style="background-color: #ee0a24;height: 100%">删除</div> | |||||
| <router-link :to="{name:'sunVillageInfoListIndustryEdit',query:{id:item.id}}" style="background-color: #07c160">修改</router-link> | |||||
| <div @click="openLoader(item.id,0)" style="background-color: rgb(98,173,102,0.2);color: #62AD66;">附件</div> | |||||
| <div @click="openMap(item.id, item.theGeom,index)" style="background-color: #62AD66;color: #ffffff;">地图</div> | |||||
| </template> | |||||
| </van-swipe-cell> | |||||
| </van-list> | |||||
| </div> | |||||
| <!-- <div class="bottom_tips">--> | |||||
| <!-- <span class="xs">已经到底啦</span>--> | |||||
| <!-- </div>--> | |||||
| <van-popup v-model="showMap" lock-scroll position="top" :style="{ height: '80%' }" > | |||||
| <div style="padding: 0;text-align: center"> | |||||
| <MapGisLine ref="clickLoading" :message="theGeom" v-on:formSubmit="MapTag" :resourceId="resourceId" :resourceList="resourceList"></MapGisLine> | |||||
| <!-- <div>地图信息:绿色地块表示该地块,蓝色表示本账套已标记的其他地块</div>--> | |||||
| <div style="margin-top: 1.5vh"> | |||||
| <van-button type="info" size="small" @click="saveGeom">保存</van-button> | |||||
| <van-button type="danger" size="small" @click="clearLayer">清除图层</van-button> | |||||
| <van-button plain type="info" size="small" @click="showMap = false">取消</van-button> | |||||
| </div> | |||||
| </div> | |||||
| </van-popup> | |||||
| <van-popup v-model="show" lock-scroll closeable position="top" :style="{ height: '30%' }" > | |||||
| <div style="padding: 0 13% 0 5%;"> | |||||
| <van-divider>附件</van-divider> | |||||
| <van-uploader v-model="fileList" :after-read="afterRead" @delete="deleteFile1" multiple /> | |||||
| </div> | |||||
| </van-popup> | |||||
| <van-popup v-model="typeVisible" lock-scroll closeable position="top" > | |||||
| <div style="padding: 0.2rem 0.3rem 0.3rem;"> | |||||
| <van-cell-group> | |||||
| <van-cell> | |||||
| <div style="text-align: center; font-size: 18px;">筛选</div> | |||||
| </van-cell> | |||||
| <van-cell> | |||||
| <van-checkbox v-model="queryParams.params.noMap" :border="false">未上图</van-checkbox> | |||||
| </van-cell> | |||||
| <van-cell> | |||||
| <van-checkbox v-model="queryParams.params.noAttachment" :border="false">无附件</van-checkbox> | |||||
| </van-cell> | |||||
| <field-select | |||||
| v-model="queryParams.industryRights" | |||||
| label="产业权属" | |||||
| value-key="dictLabel" | |||||
| data-key="dictValue" | |||||
| placeholder="选择产业权属" | |||||
| :columns="industryRightsOptions" | |||||
| :clearable="true" | |||||
| /> | |||||
| </van-cell-group> | |||||
| <div style="padding: 0.2rem 0.5rem 0;"> | |||||
| <van-button round type="primary" block @click="refresh">搜索</van-button> | |||||
| </div> | |||||
| </div> | |||||
| </van-popup> | |||||
| </div> | |||||
| </template> | |||||
| <script> | |||||
| import { | |||||
| commonAttach, | |||||
| attachmentList, | |||||
| systemAttachment, | |||||
| } from "@/api/sunVillage_info/three"; | |||||
| import { listIndustry, statisticIndustry, getIndustry, delIndustry, addIndustry, updateIndustry, exportIndustry,clearTheGeom } from "@/api/sunVillage_info/industry"; | |||||
| import request from '@/utils/request' | |||||
| import MapGisLine from "@/components/Map/MapGisLine"; | |||||
| import Selector from "@/components/common/Selector.vue"; | |||||
| import FieldSelect from "@/components/form/FieldSelect.vue"; | |||||
| export default { | |||||
| name: "certificateList", | |||||
| components: {FieldSelect, Selector, MapGisLine,}, | |||||
| data() { | |||||
| return { | |||||
| theGeom:'', | |||||
| applicationList:[], | |||||
| applicationListSecond:[], | |||||
| assetStatusOptions:[], | |||||
| auditStatus:[], | |||||
| loading: false, | |||||
| finished: false, | |||||
| show: false, | |||||
| showMap: false, | |||||
| fileList:[], | |||||
| listLength:'0', | |||||
| searchInput:'', | |||||
| queryParams:{ | |||||
| pageNum:1, | |||||
| pageSize:10, | |||||
| orderByColumn:'createTime', | |||||
| isAsc:'desc', | |||||
| translate_dict:1, | |||||
| industryName:'', | |||||
| industryRights: null, | |||||
| params: { | |||||
| noMap: false, | |||||
| noAttachment: false, | |||||
| }, | |||||
| }, | |||||
| uploadFiles1:[], | |||||
| projectId:'', | |||||
| projectIndex:'', | |||||
| showBtn:true, | |||||
| listMap: 0, | |||||
| resourceId: null, // 资产ID,记录当前资产的ID | |||||
| resourceList: [], // 资产列表,存储本账套下所有的资产信息 | |||||
| typeVisible: false, | |||||
| industryRightsOptions: [], | |||||
| }; | |||||
| }, | |||||
| created() { | |||||
| this.houseGetDicts("industry_rights_type").then((response) => { | |||||
| this.industryRightsOptions = response.data; | |||||
| }); | |||||
| }, | |||||
| methods: { | |||||
| saveGeom(){ | |||||
| var that = this; | |||||
| updateIndustry({id: this.resourceId, theGeom: this.theGeom}).then((response) => { | |||||
| if (response.code == 200){ | |||||
| this.$notify({ type: 'success', message: '修改成功' }); | |||||
| setTimeout(function(){ | |||||
| that.showMap = false; | |||||
| getIndustry(that.resourceId).then(response => { | |||||
| that.applicationList[that.listMap].theGeom = response.data.theGeom; | |||||
| }); | |||||
| },500) | |||||
| } | |||||
| }); | |||||
| }, | |||||
| clearLayer() { | |||||
| this.$dialog.confirm({ | |||||
| message: '是否清除图层?', | |||||
| }).then(() => { | |||||
| // on confirm | |||||
| clearTheGeom(this.resourceId).then(res => { | |||||
| if (res.code === 200) { | |||||
| this.$notify({ type: 'success', message: '清除成功' }); | |||||
| this.showMap = false; | |||||
| this.applicationList[this.listMap].theGeom = null; | |||||
| } | |||||
| }); | |||||
| }).catch(() => { | |||||
| // on cancel | |||||
| }); | |||||
| }, | |||||
| openMap(id, theGeom,index){ | |||||
| listIndustry().then(response => { | |||||
| this.showMap = true; | |||||
| this.resourceId = id; | |||||
| this.theGeom = theGeom; | |||||
| this.listMap = index; | |||||
| this.resourceList = response.rows; | |||||
| this.mapClickLoading(); | |||||
| }); | |||||
| }, | |||||
| //每个查看修改,新增 方法下引用下面方法 | |||||
| mapClickLoading(){ | |||||
| setTimeout(() => { | |||||
| this.$refs.clickLoading.drawingPaceCountryLine(); | |||||
| }, 1000); | |||||
| }, | |||||
| /** 查找地图中定位点 */ | |||||
| MapTag: function (data) { | |||||
| // this.applicationList[this.listMap].theGeom = data; | |||||
| this.theGeom = data; | |||||
| }, | |||||
| guidProduct(){ | |||||
| return 'xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx'.replace(/[xy]/g, function (c) { | |||||
| var r = Math.random() * 16 | 0, | |||||
| v = c == 'x' ? r : (r & 0x3 | 0x8); | |||||
| return v.toString(16); | |||||
| }); | |||||
| }, | |||||
| getList(){ | |||||
| this.loading = true; | |||||
| listIndustry(this.queryParams).then(response => { | |||||
| this.listLength = response.total; | |||||
| response.rows.forEach(item => { | |||||
| this.applicationList.push(item); | |||||
| }); | |||||
| if(this.applicationList.length >= response.total){ | |||||
| this.finished = true; | |||||
| return; | |||||
| }else{ | |||||
| this.loading = false; | |||||
| this.queryParams.pageNum += 1 ; | |||||
| } | |||||
| }); | |||||
| }, | |||||
| afterRead(file) { | |||||
| // 此时可以自行将文件上传至服务器 | |||||
| console.log(file) | |||||
| this.uploadFiles1.push(file.file); | |||||
| let params1 = new FormData(); | |||||
| params1.append("tableId", this.projectId); | |||||
| params1.append("tableName", "t_asset_industry"); | |||||
| params1.append("bizPath", "asset"); | |||||
| params1.append("fileType", this.projectIndex); | |||||
| params1.append("file", file.file); | |||||
| commonAttach(params1).then((r1) => { | |||||
| this.$notify({ type: 'success', message: '上传成功' }); | |||||
| }) | |||||
| }, | |||||
| openLoader(id,index){ | |||||
| this.show = true; | |||||
| this.projectId = id; | |||||
| this.projectIndex = index; | |||||
| this.fileList = []; | |||||
| let oData1= { | |||||
| tableId: id, | |||||
| tableName: "t_asset_industry", | |||||
| bizPath: "asset", | |||||
| fileType: '', | |||||
| } | |||||
| attachmentList(oData1).then(res => { | |||||
| res.rows.map(r => { | |||||
| let baseUrl = location.protocol+"//"+location.host+request.defaults.baseURL | |||||
| this.fileList.push({"url":baseUrl + r.fileUrl,"file":new File([],r.fileName,{}),"id":r.id}) | |||||
| }) | |||||
| }) | |||||
| }, | |||||
| /** 删除按钮操作 */ | |||||
| handleDelete(row,index) { | |||||
| const ids = row.id || this.ids; | |||||
| this.$dialog.alert( | |||||
| { | |||||
| message:'是否确认删除资产?', | |||||
| title:"警告", | |||||
| showCancelButton:true, | |||||
| confirmButtonText: "确定", | |||||
| cancelButtonText: "取消", | |||||
| } | |||||
| ) | |||||
| .then(function () { | |||||
| return delIndustry(ids); | |||||
| }) | |||||
| .then(() => { | |||||
| this.applicationList.splice(index, 1); | |||||
| this.$notify({ type: 'success', message: '删除成功' }); | |||||
| }); | |||||
| }, | |||||
| getSearchList(){ | |||||
| this.queryParams.pageNum = 1; | |||||
| this.finished = false; | |||||
| this.applicationList = []; | |||||
| this.getList(); | |||||
| }, | |||||
| deleteFile1(file){ | |||||
| console.log(file) | |||||
| systemAttachment(file.id).then(res => { | |||||
| this.$notify({ type: 'success', message: '删除成功' }); | |||||
| }) | |||||
| }, | |||||
| goAdd(){ | |||||
| this.$router.push('/sunVillage_info/industryAdd') | |||||
| }, | |||||
| openIndustryRights() { | |||||
| this.typeVisible = true; | |||||
| }, | |||||
| refresh() { | |||||
| this.typeVisible = false; | |||||
| this.queryParams.pageNum = 1; | |||||
| this.listLength = 0; | |||||
| this.applicationList = []; | |||||
| this.finished = false; | |||||
| this.getList(); | |||||
| }, | |||||
| }, | |||||
| computed: { | |||||
| searchPlaceholder() { | |||||
| let typeName = this.industryRightsOptions.find((x) => x.dictValue == this.queryParams.industryRights); | |||||
| return '搜索' + (typeName ? typeName.dictLabel : ''); | |||||
| }, | |||||
| } | |||||
| } | |||||
| </script> | |||||
| <style scoped lang="scss"> | |||||
| /deep/ .van-search__content{ | |||||
| background-color: transparent; | |||||
| } | |||||
| .home_wrapper{ | |||||
| background: #e9e9e9; | |||||
| min-height: 100vh; | |||||
| width: 100vw; | |||||
| .header_main { | |||||
| height: 116px; | |||||
| background: url('../../assets/images/sunVillage_info/list_head.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| position: fixed; | |||||
| top: 0; | |||||
| left: 0; | |||||
| width: 100%; | |||||
| font-size: 36px; | |||||
| line-height: 116px; | |||||
| text-align: center; | |||||
| color: #fff; | |||||
| position: relative; | |||||
| .return_btn { | |||||
| width: 24px; | |||||
| height: 43.2px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_5.png') center center no-repeat; | |||||
| background-size: 20px 36px; | |||||
| position: absolute; | |||||
| left: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| .add_btn { | |||||
| width: 56.4px; | |||||
| height: 40.8px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_9.png') center center no-repeat; | |||||
| background-size: 47px 34px; | |||||
| position: absolute; | |||||
| right: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| } | |||||
| .search_info{ | |||||
| padding:20px 23px; | |||||
| display: flex; | |||||
| .search_block{ | |||||
| width: 535px; | |||||
| border-radius: 59px; | |||||
| background: #fff; | |||||
| display: flex; | |||||
| border:2px solid #3494ff; | |||||
| padding-right: 20px; | |||||
| align-items: center; | |||||
| &.searchHeight{ | |||||
| border: none; | |||||
| height: 57px; | |||||
| padding-left: 0; | |||||
| } | |||||
| .icon{ | |||||
| width: 30px; | |||||
| height: 30px; | |||||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_1.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| display: block; | |||||
| margin:0 8px 0 26px; | |||||
| } | |||||
| .filter-icon { | |||||
| font-weight: bold; | |||||
| font-size: .4rem; | |||||
| width: .6rem; | |||||
| text-align: center; | |||||
| } | |||||
| .ipt{ | |||||
| flex: 1; | |||||
| font-size: 26px; | |||||
| background: none; | |||||
| border:0 none; | |||||
| line-height: 59px; | |||||
| } | |||||
| } | |||||
| .total{ | |||||
| flex: 1; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| justify-content: center; | |||||
| font-size: 26px; | |||||
| color: #858585; | |||||
| } | |||||
| } | |||||
| .list_main{ | |||||
| padding:0 22px; | |||||
| .item{ | |||||
| /*height: 198px;*/ | |||||
| border-radius: 30px; | |||||
| background: #fff; | |||||
| box-shadow: 4px 6px 5px rgba(63, 68, 75, 0.1); | |||||
| margin-bottom: 20px; | |||||
| .item_box{ | |||||
| padding:25px 32px; | |||||
| } | |||||
| .head_block{ | |||||
| height: 56px; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| width: 100%; | |||||
| .icon{ | |||||
| width: 34px; | |||||
| height: 30px; | |||||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_2.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| display: block; | |||||
| margin-right: 12px; | |||||
| } | |||||
| .title{ | |||||
| flex:1; | |||||
| font-size: 32px; | |||||
| color: #252525; | |||||
| overflow: hidden; | |||||
| text-overflow: ellipsis; | |||||
| white-space: nowrap; | |||||
| padding-right: 20px; | |||||
| } | |||||
| .describe{ | |||||
| height: 34px; | |||||
| padding: 0 15px; | |||||
| font-size: 24px; | |||||
| color: #3494ff; | |||||
| background: #e6f2ff; | |||||
| border-radius: 8px; | |||||
| } | |||||
| } | |||||
| .order_block{ | |||||
| height: 50px; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| width: 100%; | |||||
| .order{ | |||||
| flex: 1; | |||||
| font-size: 26px; | |||||
| color: #252525; | |||||
| } | |||||
| .describe{ | |||||
| font-size: 26px; | |||||
| color: #3494ff; | |||||
| } | |||||
| } | |||||
| .function_block{ | |||||
| height: 46px; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| .time{ | |||||
| display: flex; | |||||
| flex: 1; | |||||
| align-items: center; | |||||
| font-size: 24px; | |||||
| color: #858585; | |||||
| .icon{ | |||||
| width: 25px; | |||||
| height: 25px; | |||||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_3.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| display: block; | |||||
| margin-right: 8px; | |||||
| } | |||||
| } | |||||
| .state{ | |||||
| /*flex: 1;*/ | |||||
| display: flex; | |||||
| justify-content: center; | |||||
| align-items: center; | |||||
| &.sell{ | |||||
| color: #f69600; | |||||
| } | |||||
| &.scrap{ | |||||
| color: #858585; | |||||
| } | |||||
| &.normal{ | |||||
| color: #68c000; | |||||
| } | |||||
| } | |||||
| .value{ | |||||
| flex:1; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| justify-content:flex-end; | |||||
| font-size: 24px; | |||||
| color: #858585; | |||||
| .amount{ | |||||
| color: #eb1616; | |||||
| } | |||||
| } | |||||
| } | |||||
| } | |||||
| } | |||||
| .bottom_tips{ | |||||
| font-size: 24px; | |||||
| color: #a7a6a6; | |||||
| text-align: center; | |||||
| margin-top: 32px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_8.png') center center no-repeat; | |||||
| background-size: 260px 2px; | |||||
| .xs{ | |||||
| padding:0 8px; | |||||
| background: #e9e9e9; | |||||
| } | |||||
| } | |||||
| /deep/ .van-swipe-cell__right{ | |||||
| display: flex; | |||||
| align-items: center; | |||||
| width: 200PX; | |||||
| margin-left: 5PX; | |||||
| a,div{ | |||||
| margin: 0; | |||||
| display: flex; | |||||
| align-items: center; | |||||
| justify-content: center; | |||||
| color: #ffffff; | |||||
| font-size: 14PX; | |||||
| height: 100%; | |||||
| flex: 1; | |||||
| } | |||||
| } | |||||
| } | |||||
| </style> | |||||
| @@ -0,0 +1,379 @@ | |||||
| <template> | |||||
| <div class="home_wrapper"> | |||||
| <div class="header_main"> | |||||
| 产业信息新增 | |||||
| <div class="return_btn" @click="onClickLeft"></div> | |||||
| </div> | |||||
| <van-form @submit="onSubmit"> | |||||
| <div class="list_main"> | |||||
| <div class="titBox"> | |||||
| <img src="../../assets/images/sunVillage_info/add_icon_1.png" style="width:22PX;height:22PX;margin-right: 10px;"/> | |||||
| <p class="tit">基本信息</p> | |||||
| </div> | |||||
| <van-field required :rules="[{ required: true }]" v-model="form.industryCode" label="产业编码" placeholder="产业编码" input-align="right" :border="false" :maxlength="20"/> | |||||
| <van-field required :rules="[{ required: true }]" v-model="form.industryName" label="产业名称" placeholder="产业名称" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="产业权属" | |||||
| placeholder="请选择" | |||||
| v-model="industryRights" | |||||
| @click="showIndustryRights = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| required | |||||
| :border="false" | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showIndustryRights" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="industryRightsOptions" | |||||
| @confirm="onConfirmIndustryRights" | |||||
| @cancel="showIndustryRights = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.industryRightsOther" label="其他权属" placeholder="其他权属" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="产业类型" | |||||
| placeholder="请选择" | |||||
| v-model="industryType" | |||||
| @click="showIndustryType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| required | |||||
| :border="false" | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showIndustryType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="industryTypeOptions" | |||||
| @confirm="onConfirmIndustryType" | |||||
| @cancel="showIndustryType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.industryTypeOther" label="其他产业" placeholder="其他产业" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field v-model="form.productName" label="主要产品" placeholder="主要产品" required :rules="[{ required: true }]" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="占用土地" | |||||
| placeholder="请选择" | |||||
| v-model="occupyLand" | |||||
| @click="showOccupyLand = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| required | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showOccupyLand" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="sysYesNoOptions" | |||||
| @confirm="onConfirmOccupyLand" | |||||
| @cancel="showOccupyLand = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.occupyLandArea" label="占地面积" placeholder="占地面积" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="占用类型" | |||||
| placeholder="请选择" | |||||
| v-model="occupyLandType" | |||||
| @click="showOccupyLandType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showOccupyLandType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="occupyLandTypeOptions" | |||||
| @confirm="onConfirmOccupyLandType" | |||||
| @cancel="showOccupyLandType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.occupyLandTypeOther" label="其他占用" placeholder="其他占用" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="土地来源" | |||||
| placeholder="请选择" | |||||
| v-model="landSource" | |||||
| @click="showLandSource = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showLandSource" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="landSourceOptions" | |||||
| @confirm="onConfirmLandSource" | |||||
| @cancel="showLandSource = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.landSourceOther" label="其他来源" placeholder="其他来源" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field v-model="form.investmentAmount" label="产业投资金额" placeholder="产业投资金额" required :rules="[{ required: true }]" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.industryValuation" label="产业估值" placeholder="产业估值" required :rules="[{ required: true }]" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.yearSaleAmount" label="年销售额" placeholder="年销售额" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.yearProfitAmount" label="年利润" placeholder="年利润" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="有贷款需求" | |||||
| placeholder="请选择" | |||||
| v-model="isLoan" | |||||
| @click="showIsLoan = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showIsLoan" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="sysYesNoOptions" | |||||
| @confirm="onConfirmIsLoan" | |||||
| @cancel="showIsLoan = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.loanAmount" label="计划贷款金额" placeholder="计划贷款金额" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.industryBz" label="备注" placeholder="备注" input-align="right" :border="false" :maxlength="500"/> | |||||
| </div> | |||||
| <div style="margin: 16px auto;width: 50%;"> | |||||
| <van-button round block type="primary" native-type="submit"> | |||||
| 保存 | |||||
| </van-button> | |||||
| </div> | |||||
| </van-form> | |||||
| </div> | |||||
| </template> | |||||
| <script> | |||||
| import {addIndustry} from "@/api/sunVillage_info/industry"; | |||||
| export default { | |||||
| name: "certificateList", | |||||
| data() { | |||||
| return { | |||||
| // 资产分类字典 | |||||
| industryRightsOptions: [], | |||||
| industryTypeOptions: [], | |||||
| showIndustryRights:false, | |||||
| industryRights:'村集体产业', | |||||
| showIndustryType:false, | |||||
| industryType:'种植业', | |||||
| form:{ | |||||
| id: null, | |||||
| bookId: null, | |||||
| deptId: null, | |||||
| industryCode: null, | |||||
| industryName: null, | |||||
| industryRights: "1", | |||||
| industryRightsOther: null, | |||||
| industryType: "1", | |||||
| industryTypeOther: null, | |||||
| productName: null, | |||||
| occupyLand: "Y", | |||||
| occupyLandArea: null, | |||||
| occupyLandType: "1", | |||||
| occupyLandTypeOther: null, | |||||
| landSource: "1", | |||||
| landSourceOther: null, | |||||
| investmentAmount: null, | |||||
| industryValuation: null, | |||||
| yearSaleAmount: null, | |||||
| yearProfitAmount: null, | |||||
| isLoan: "Y", | |||||
| loanAmount: null, | |||||
| industryBz: null, | |||||
| theGeom: null, | |||||
| createBy: null, | |||||
| createTime: null, | |||||
| updateBy: null, | |||||
| updateTime: null | |||||
| }, | |||||
| showOccupyLand:false, | |||||
| occupyLand:'是', | |||||
| sysYesNoOptions:[], | |||||
| showOccupyLandType:false, | |||||
| occupyLandTypeOptions:[], | |||||
| occupyLandType:'耕地', | |||||
| showLandSource:false, | |||||
| landSourceOptions:[], | |||||
| landSource:'集体', | |||||
| landSourceTypeOptions:[], | |||||
| showIsLoan:false, | |||||
| isLoan:'是', | |||||
| loading: false, | |||||
| finished: false, | |||||
| listLength:'0', | |||||
| searchInput:'', | |||||
| queryParams:{ | |||||
| pageNum:1, | |||||
| pageSize:10, | |||||
| orderByColumn:'createTime', | |||||
| isAsc:'desc', | |||||
| industryName:'', | |||||
| }, | |||||
| buildTime:new Date() | |||||
| }; | |||||
| }, | |||||
| created() { | |||||
| this.houseGetDicts("sys_yes_no").then((response) => { | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.sysYesNoOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("industry_rights_type").then((response) => { | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.industryRightsOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("occupy_land_type").then((response) => { | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.occupyLandTypeOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("land_source").then((response) => { | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.landSourceOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("purpose_type").then((response) => { | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.industryTypeOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| }, | |||||
| methods: { | |||||
| onConfirmIndustryRights(data){ | |||||
| this.industryRights = data.text; | |||||
| this.form.industryRights = data.value; | |||||
| this.showIndustryRights = false; | |||||
| }, | |||||
| onConfirmIndustryType(data){ | |||||
| this.industryType = data.text; | |||||
| this.form.industryType = data.value; | |||||
| this.showIndustryType = false; | |||||
| }, | |||||
| onConfirmOccupyLandType(data){ | |||||
| this.occupyLandType = data.text; | |||||
| this.form.occupyLandType = data.value; | |||||
| this.showOccupyLandType = false; | |||||
| }, | |||||
| onConfirmOccupyLand(data){ | |||||
| this.occupyLand = data.text; | |||||
| this.form.occupyLand = data.value; | |||||
| this.showOccupyLand = false; | |||||
| }, | |||||
| onConfirmLandSource(data){ | |||||
| this.landSource = data.text; | |||||
| this.form.landSource = data.value; | |||||
| this.showLandSource = false; | |||||
| }, | |||||
| onConfirmIsLoan(data){ | |||||
| this.isLoan = data.text; | |||||
| this.form.isLoan = data.value; | |||||
| this.showIsLoan = false; | |||||
| }, | |||||
| onSubmit(){ | |||||
| addIndustry(this.form).then(response => { | |||||
| if (response.code == 200){ | |||||
| this.$notify({ type: 'success', message: '新增成功' }); | |||||
| setTimeout(function(){ | |||||
| history.back(-1); | |||||
| },2000) | |||||
| } | |||||
| }); | |||||
| } | |||||
| }, | |||||
| } | |||||
| </script> | |||||
| <style scoped lang="scss"> | |||||
| /deep/ .van-button--primary{ | |||||
| background: url("../../assets/images/sunVillage_info/btn_bg.png") no-repeat; | |||||
| background-size: 100% 100%; | |||||
| border: none; | |||||
| } | |||||
| .home_wrapper{ | |||||
| background: #e9e9e9; | |||||
| min-height: 100vh; | |||||
| width: 100vw; | |||||
| .header_main { | |||||
| height: 116px; | |||||
| background: url('../../assets/images/sunVillage_info/list_head.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| position: fixed; | |||||
| top: 0; | |||||
| left: 0; | |||||
| width: 100%; | |||||
| font-size: 36px; | |||||
| line-height: 116px; | |||||
| text-align: center; | |||||
| color: #fff; | |||||
| position: relative; | |||||
| .return_btn { | |||||
| width: 24px; | |||||
| height: 43.2px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_5.png') center center no-repeat; | |||||
| background-size: 20px 36px; | |||||
| position: absolute; | |||||
| left: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| .add_btn { | |||||
| width: 56.4px; | |||||
| height: 40.8px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_9.png') center center no-repeat; | |||||
| background-size: 47px 34px; | |||||
| position: absolute; | |||||
| right: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| } | |||||
| .list_main{ | |||||
| padding:25px; | |||||
| background: #ffffff; | |||||
| width: 94%; | |||||
| margin: 25px auto 0; | |||||
| border-radius: 15PX; | |||||
| box-shadow: 4px 6px 5px rgba(63, 68, 75, 0.1); | |||||
| } | |||||
| .titBox{ | |||||
| display: flex; | |||||
| align-items: center; | |||||
| } | |||||
| .tit{ | |||||
| font-size: 36px; | |||||
| font-weight: bold; | |||||
| } | |||||
| /deep/ .van-cell{ | |||||
| padding-left: 0!important; | |||||
| padding-right: 0!important; | |||||
| padding-bottom: 0!important; | |||||
| } | |||||
| /deep/ .van-field__label{ | |||||
| padding-left: 10PX; | |||||
| width: 8.2em; | |||||
| } | |||||
| /deep/ .van-cell--required::before{ | |||||
| left: 0; | |||||
| } | |||||
| } | |||||
| </style> | |||||
| @@ -0,0 +1,397 @@ | |||||
| <template> | |||||
| <div class="home_wrapper"> | |||||
| <div class="header_main"> | |||||
| 产业信息详情 | |||||
| <div class="return_btn" @click="onClickLeft"></div> | |||||
| </div> | |||||
| <van-form @submit="onSubmit"> | |||||
| <div class="list_main"> | |||||
| <div class="titBox"> | |||||
| <img src="../../assets/images/sunVillage_info/add_icon_1.png" style="width:22PX;height:22PX;margin-right: 10px;"/> | |||||
| <p class="tit">基本信息</p> | |||||
| </div> | |||||
| <van-field required :rules="[{ required: true }]" v-model="form.industryCode" label="产业编码" placeholder="产业编码" input-align="right" :border="false" :maxlength="20"/> | |||||
| <van-field required :rules="[{ required: true }]" v-model="form.industryName" label="产业名称" placeholder="产业名称" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="产业权属" | |||||
| placeholder="请选择" | |||||
| v-model="industryRights" | |||||
| @click="showIndustryRights = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| required | |||||
| :border="false" | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showIndustryRights" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="industryRightsOptions" | |||||
| @confirm="onConfirmIndustryRights" | |||||
| @cancel="showIndustryRights = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.industryRightsOther" label="其他权属" placeholder="其他权属" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="产业类型" | |||||
| placeholder="请选择" | |||||
| v-model="industryType" | |||||
| @click="showIndustryType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| required | |||||
| :border="false" | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showIndustryType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="industryTypeOptions" | |||||
| @confirm="onConfirmIndustryType" | |||||
| @cancel="showIndustryType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.industryTypeOther" label="其他产业" placeholder="其他产业" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field v-model="form.productName" label="主要产品" placeholder="主要产品" required :rules="[{ required: true }]" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="占用土地" | |||||
| placeholder="请选择" | |||||
| v-model="occupyLand" | |||||
| @click="showOccupyLand = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| required | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showOccupyLand" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="sysYesNoOptions" | |||||
| @confirm="onConfirmOccupyLand" | |||||
| @cancel="showOccupyLand = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.occupyLandArea" label="占地面积" placeholder="占地面积" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="占用类型" | |||||
| placeholder="请选择" | |||||
| v-model="occupyLandType" | |||||
| @click="showOccupyLandType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showOccupyLandType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="occupyLandTypeOptions" | |||||
| @confirm="onConfirmOccupyLandType" | |||||
| @cancel="showOccupyLandType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.occupyLandTypeOther" label="其他占用" placeholder="其他占用" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="土地来源" | |||||
| placeholder="请选择" | |||||
| v-model="landSource" | |||||
| @click="showLandSource = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showLandSource" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="landSourceOptions" | |||||
| @confirm="onConfirmLandSource" | |||||
| @cancel="showLandSource = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.landSourceOther" label="其他来源" placeholder="其他来源" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field v-model="form.investmentAmount" label="产业投资金额" placeholder="产业投资金额" required :rules="[{ required: true }]" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.industryValuation" label="产业估值" placeholder="产业估值" required :rules="[{ required: true }]" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.yearSaleAmount" label="年销售额" placeholder="年销售额" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.yearProfitAmount" label="年利润" placeholder="年利润" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="有贷款需求" | |||||
| placeholder="请选择" | |||||
| v-model="isLoan" | |||||
| @click="showIsLoan = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showIsLoan" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="sysYesNoOptions" | |||||
| @confirm="onConfirmIsLoan" | |||||
| @cancel="showIsLoan = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.loanAmount" label="计划贷款金额" placeholder="计划贷款金额" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.industryBz" label="备注" placeholder="备注" input-align="right" :border="false" :maxlength="500"/> | |||||
| </div> | |||||
| </van-form> | |||||
| </div> | |||||
| </template> | |||||
| <script> | |||||
| import {getIndustry,updateIndustry} from "@/api/sunVillage_info/industry"; | |||||
| export default { | |||||
| name: "certificateList", | |||||
| data() { | |||||
| return { | |||||
| // 资产分类字典 | |||||
| industryRightsOptions: [], | |||||
| industryTypeOptions: [], | |||||
| industryRightsSelect: [], | |||||
| industryTypeSelect: [], | |||||
| showIndustryRights:false, | |||||
| industryRights:'村集体产业', | |||||
| showIndustryType:false, | |||||
| industryType:'种植业', | |||||
| form:{ | |||||
| id: null, | |||||
| bookId: null, | |||||
| deptId: null, | |||||
| industryCode: null, | |||||
| industryName: null, | |||||
| industryRights: "1", | |||||
| industryRightsOther: null, | |||||
| industryType: "1", | |||||
| industryTypeOther: null, | |||||
| productName: null, | |||||
| occupyLand: "Y", | |||||
| occupyLandArea: null, | |||||
| occupyLandType: "1", | |||||
| occupyLandTypeOther: null, | |||||
| landSource: "1", | |||||
| landSourceOther: null, | |||||
| investmentAmount: null, | |||||
| industryValuation: null, | |||||
| yearSaleAmount: null, | |||||
| yearProfitAmount: null, | |||||
| isLoan: "Y", | |||||
| loanAmount: null, | |||||
| industryBz: null, | |||||
| theGeom: null, | |||||
| createBy: null, | |||||
| createTime: null, | |||||
| updateBy: null, | |||||
| updateTime: null | |||||
| }, | |||||
| showOccupyLand:false, | |||||
| occupyLand:'是', | |||||
| sysYesNoOptions:[], | |||||
| sysYesNoSelect:[], | |||||
| showOccupyLandType:false, | |||||
| occupyLandTypeOptions:[], | |||||
| occupyLandTypeSelect:[], | |||||
| occupyLandType:'耕地', | |||||
| showLandSource:false, | |||||
| landSourceOptions:[], | |||||
| landSourceSelect:[], | |||||
| landSource:'集体', | |||||
| landSourceTypeOptions:[], | |||||
| landSourceTypeSelect:[], | |||||
| showIsLoan:false, | |||||
| isLoan:'是', | |||||
| loading: false, | |||||
| finished: false, | |||||
| listLength:'0', | |||||
| searchInput:'', | |||||
| queryParams:{ | |||||
| pageNum:1, | |||||
| pageSize:10, | |||||
| orderByColumn:'createTime', | |||||
| isAsc:'desc', | |||||
| industryName:'', | |||||
| }, | |||||
| buildTime:new Date() | |||||
| }; | |||||
| }, | |||||
| created() { | |||||
| this.houseGetDicts("sys_yes_no").then((response) => { | |||||
| this.sysYesNoSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.sysYesNoOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("industry_rights_type").then((response) => { | |||||
| this.industryRightsSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.industryRightsOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("occupy_land_type").then((response) => { | |||||
| this.occupyLandTypeSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.occupyLandTypeOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("land_source").then((response) => { | |||||
| this.landSourceSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.landSourceOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("purpose_type").then((response) => { | |||||
| this.industryTypeSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.industryTypeOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.getDetail(); | |||||
| }, | |||||
| methods: { | |||||
| getDetail(){ | |||||
| getIndustry(this.$route.query.id).then(response => { | |||||
| this.form = response.data; | |||||
| this.industryRights = this.selectDictLabel(this.industryRightsSelect, response.data.industryRights); | |||||
| this.industryType = this.selectDictLabel(this.industryTypeSelect, response.data.industryType); | |||||
| this.occupyLand = this.selectDictLabel(this.sysYesNoSelect, response.data.occupyLand); | |||||
| this.occupyLandType = this.selectDictLabel(this.occupyLandTypeSelect, response.data.occupyLandType); | |||||
| this.landSource = this.selectDictLabel(this.landSourceSelect, response.data.landSource); | |||||
| this.isLoan = this.selectDictLabel(this.sysYesNoSelect, response.data.isLoan); | |||||
| }); | |||||
| }, | |||||
| onConfirmIndustryRights(data){ | |||||
| this.industryRights = data.text; | |||||
| this.form.industryRights = data.value; | |||||
| this.showIndustryRights = false; | |||||
| }, | |||||
| onConfirmIndustryType(data){ | |||||
| this.industryType = data.text; | |||||
| this.form.industryType = data.value; | |||||
| this.showIndustryType = false; | |||||
| }, | |||||
| onConfirmOccupyLandType(data){ | |||||
| this.occupyLandType = data.text; | |||||
| this.form.occupyLandType = data.value; | |||||
| this.showOccupyLandType = false; | |||||
| }, | |||||
| onConfirmOccupyLand(data){ | |||||
| this.occupyLand = data.text; | |||||
| this.form.occupyLand = data.value; | |||||
| this.showOccupyLand = false; | |||||
| }, | |||||
| onConfirmLandSource(data){ | |||||
| this.landSource = data.text; | |||||
| this.form.landSource = data.value; | |||||
| this.showLandSource = false; | |||||
| }, | |||||
| onConfirmIsLoan(data){ | |||||
| this.isLoan = data.text; | |||||
| this.form.isLoan = data.value; | |||||
| this.showIsLoan = false; | |||||
| }, | |||||
| onSubmit(){ | |||||
| updateIndustry(this.form).then(response => { | |||||
| if (response.code == 200){ | |||||
| this.$notify({ type: 'success', message: '新增成功' }); | |||||
| setTimeout(function(){ | |||||
| history.back(-1); | |||||
| },2000) | |||||
| } | |||||
| }); | |||||
| } | |||||
| }, | |||||
| } | |||||
| </script> | |||||
| <style scoped lang="scss"> | |||||
| /deep/ .van-button--primary{ | |||||
| background: url("../../assets/images/sunVillage_info/btn_bg.png") no-repeat; | |||||
| background-size: 100% 100%; | |||||
| border: none; | |||||
| } | |||||
| .home_wrapper{ | |||||
| background: #e9e9e9; | |||||
| min-height: 100vh; | |||||
| width: 100vw; | |||||
| .header_main { | |||||
| height: 116px; | |||||
| background: url('../../assets/images/sunVillage_info/list_head.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| position: fixed; | |||||
| top: 0; | |||||
| left: 0; | |||||
| width: 100%; | |||||
| font-size: 36px; | |||||
| line-height: 116px; | |||||
| text-align: center; | |||||
| color: #fff; | |||||
| position: relative; | |||||
| .return_btn { | |||||
| width: 24px; | |||||
| height: 43.2px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_5.png') center center no-repeat; | |||||
| background-size: 20px 36px; | |||||
| position: absolute; | |||||
| left: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| .add_btn { | |||||
| width: 56.4px; | |||||
| height: 40.8px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_9.png') center center no-repeat; | |||||
| background-size: 47px 34px; | |||||
| position: absolute; | |||||
| right: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| } | |||||
| .list_main{ | |||||
| padding:25px; | |||||
| background: #ffffff; | |||||
| width: 94%; | |||||
| margin: 25px auto 0; | |||||
| border-radius: 15PX; | |||||
| box-shadow: 4px 6px 5px rgba(63, 68, 75, 0.1); | |||||
| } | |||||
| .titBox{ | |||||
| display: flex; | |||||
| align-items: center; | |||||
| } | |||||
| .tit{ | |||||
| font-size: 36px; | |||||
| font-weight: bold; | |||||
| } | |||||
| /deep/ .van-cell{ | |||||
| padding-left: 0!important; | |||||
| padding-right: 0!important; | |||||
| padding-bottom: 0!important; | |||||
| } | |||||
| /deep/ .van-field__label{ | |||||
| padding-left: 10PX; | |||||
| width: 8.2em; | |||||
| } | |||||
| /deep/ .van-cell--required::before{ | |||||
| left: 0; | |||||
| } | |||||
| } | |||||
| </style> | |||||
| @@ -0,0 +1,402 @@ | |||||
| <template> | |||||
| <div class="home_wrapper"> | |||||
| <div class="header_main"> | |||||
| 产业信息修改 | |||||
| <div class="return_btn" @click="onClickLeft"></div> | |||||
| </div> | |||||
| <van-form @submit="onSubmit"> | |||||
| <div class="list_main"> | |||||
| <div class="titBox"> | |||||
| <img src="../../assets/images/sunVillage_info/add_icon_1.png" style="width:22PX;height:22PX;margin-right: 10px;"/> | |||||
| <p class="tit">基本信息</p> | |||||
| </div> | |||||
| <van-field required :rules="[{ required: true }]" v-model="form.industryCode" label="产业编码" placeholder="产业编码" input-align="right" :border="false" :maxlength="20"/> | |||||
| <van-field required :rules="[{ required: true }]" v-model="form.industryName" label="产业名称" placeholder="产业名称" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="产业权属" | |||||
| placeholder="请选择" | |||||
| v-model="industryRights" | |||||
| @click="showIndustryRights = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| required | |||||
| :border="false" | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showIndustryRights" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="industryRightsOptions" | |||||
| @confirm="onConfirmIndustryRights" | |||||
| @cancel="showIndustryRights = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.industryRightsOther" label="其他权属" placeholder="其他权属" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="产业类型" | |||||
| placeholder="请选择" | |||||
| v-model="industryType" | |||||
| @click="showIndustryType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| required | |||||
| :border="false" | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showIndustryType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="industryTypeOptions" | |||||
| @confirm="onConfirmIndustryType" | |||||
| @cancel="showIndustryType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.industryTypeOther" label="其他产业" placeholder="其他产业" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field v-model="form.productName" label="主要产品" placeholder="主要产品" required :rules="[{ required: true }]" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="占用土地" | |||||
| placeholder="请选择" | |||||
| v-model="occupyLand" | |||||
| @click="showOccupyLand = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| required | |||||
| :rules="[{ required: true }]" | |||||
| /> | |||||
| <van-popup v-model="showOccupyLand" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="sysYesNoOptions" | |||||
| @confirm="onConfirmOccupyLand" | |||||
| @cancel="showOccupyLand = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.occupyLandArea" label="占地面积" placeholder="占地面积" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="占用类型" | |||||
| placeholder="请选择" | |||||
| v-model="occupyLandType" | |||||
| @click="showOccupyLandType = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showOccupyLandType" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="occupyLandTypeOptions" | |||||
| @confirm="onConfirmOccupyLandType" | |||||
| @cancel="showOccupyLandType = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.occupyLandTypeOther" label="其他占用" placeholder="其他占用" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="土地来源" | |||||
| placeholder="请选择" | |||||
| v-model="landSource" | |||||
| @click="showLandSource = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showLandSource" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="landSourceOptions" | |||||
| @confirm="onConfirmLandSource" | |||||
| @cancel="showLandSource = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.landSourceOther" label="其他来源" placeholder="其他来源" input-align="right" :border="false" :maxlength="100"/> | |||||
| <van-field v-model="form.investmentAmount" label="产业投资金额" placeholder="产业投资金额" required :rules="[{ required: true }]" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.industryValuation" label="产业估值" placeholder="产业估值" required :rules="[{ required: true }]" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.yearSaleAmount" label="年销售额" placeholder="年销售额" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.yearProfitAmount" label="年利润" placeholder="年利润" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field | |||||
| readonly | |||||
| clickable | |||||
| label="有贷款需求" | |||||
| placeholder="请选择" | |||||
| v-model="isLoan" | |||||
| @click="showIsLoan = true" | |||||
| input-align="right" | |||||
| right-icon="arrow-down" | |||||
| label-width="auto" | |||||
| :border="false" | |||||
| /> | |||||
| <van-popup v-model="showIsLoan" position="bottom"> | |||||
| <van-picker | |||||
| show-toolbar | |||||
| :columns="sysYesNoOptions" | |||||
| @confirm="onConfirmIsLoan" | |||||
| @cancel="showIsLoan = false" | |||||
| /> | |||||
| </van-popup> | |||||
| <van-field v-model="form.loanAmount" label="计划贷款金额" placeholder="计划贷款金额" type="number" input-align="right" :border="false" :maxlength="15"/> | |||||
| <van-field v-model="form.industryBz" label="备注" placeholder="备注" input-align="right" :border="false" :maxlength="500"/> | |||||
| </div> | |||||
| <div style="margin: 16px auto;width: 50%;"> | |||||
| <van-button round block type="primary" native-type="submit"> | |||||
| 保存 | |||||
| </van-button> | |||||
| </div> | |||||
| </van-form> | |||||
| </div> | |||||
| </template> | |||||
| <script> | |||||
| import {getIndustry,updateIndustry} from "@/api/sunVillage_info/industry"; | |||||
| export default { | |||||
| name: "certificateList", | |||||
| data() { | |||||
| return { | |||||
| // 资产分类字典 | |||||
| industryRightsOptions: [], | |||||
| industryTypeOptions: [], | |||||
| industryRightsSelect: [], | |||||
| industryTypeSelect: [], | |||||
| showIndustryRights:false, | |||||
| industryRights:'村集体产业', | |||||
| showIndustryType:false, | |||||
| industryType:'种植业', | |||||
| form:{ | |||||
| id: null, | |||||
| bookId: null, | |||||
| deptId: null, | |||||
| industryCode: null, | |||||
| industryName: null, | |||||
| industryRights: "1", | |||||
| industryRightsOther: null, | |||||
| industryType: "1", | |||||
| industryTypeOther: null, | |||||
| productName: null, | |||||
| occupyLand: "Y", | |||||
| occupyLandArea: null, | |||||
| occupyLandType: "1", | |||||
| occupyLandTypeOther: null, | |||||
| landSource: "1", | |||||
| landSourceOther: null, | |||||
| investmentAmount: null, | |||||
| industryValuation: null, | |||||
| yearSaleAmount: null, | |||||
| yearProfitAmount: null, | |||||
| isLoan: "Y", | |||||
| loanAmount: null, | |||||
| industryBz: null, | |||||
| theGeom: null, | |||||
| createBy: null, | |||||
| createTime: null, | |||||
| updateBy: null, | |||||
| updateTime: null | |||||
| }, | |||||
| showOccupyLand:false, | |||||
| occupyLand:'是', | |||||
| sysYesNoOptions:[], | |||||
| sysYesNoSelect:[], | |||||
| showOccupyLandType:false, | |||||
| occupyLandTypeOptions:[], | |||||
| occupyLandTypeSelect:[], | |||||
| occupyLandType:'耕地', | |||||
| showLandSource:false, | |||||
| landSourceOptions:[], | |||||
| landSourceSelect:[], | |||||
| landSource:'集体', | |||||
| landSourceTypeOptions:[], | |||||
| landSourceTypeSelect:[], | |||||
| showIsLoan:false, | |||||
| isLoan:'是', | |||||
| loading: false, | |||||
| finished: false, | |||||
| listLength:'0', | |||||
| searchInput:'', | |||||
| queryParams:{ | |||||
| pageNum:1, | |||||
| pageSize:10, | |||||
| orderByColumn:'createTime', | |||||
| isAsc:'desc', | |||||
| industryName:'', | |||||
| }, | |||||
| buildTime:new Date() | |||||
| }; | |||||
| }, | |||||
| created() { | |||||
| this.houseGetDicts("sys_yes_no").then((response) => { | |||||
| this.sysYesNoSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.sysYesNoOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("industry_rights_type").then((response) => { | |||||
| this.industryRightsSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.industryRightsOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("occupy_land_type").then((response) => { | |||||
| this.occupyLandTypeSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.occupyLandTypeOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("land_source").then((response) => { | |||||
| this.landSourceSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.landSourceOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.houseGetDicts("purpose_type").then((response) => { | |||||
| this.industryTypeSelect = response.data; | |||||
| for(var i = 0 ; i < response.data.length ; i++){ | |||||
| this.industryTypeOptions.push({text:response.data[i].dictLabel,value:response.data[i].dictValue}); | |||||
| } | |||||
| }); | |||||
| this.getDetail(); | |||||
| }, | |||||
| methods: { | |||||
| getDetail(){ | |||||
| getIndustry(this.$route.query.id).then(response => { | |||||
| this.form = response.data; | |||||
| this.industryRights = this.selectDictLabel(this.industryRightsSelect, response.data.industryRights); | |||||
| this.industryType = this.selectDictLabel(this.industryTypeSelect, response.data.industryType); | |||||
| this.occupyLand = this.selectDictLabel(this.sysYesNoSelect, response.data.occupyLand); | |||||
| this.occupyLandType = this.selectDictLabel(this.occupyLandTypeSelect, response.data.occupyLandType); | |||||
| this.landSource = this.selectDictLabel(this.landSourceSelect, response.data.landSource); | |||||
| this.isLoan = this.selectDictLabel(this.sysYesNoSelect, response.data.isLoan); | |||||
| }); | |||||
| }, | |||||
| onConfirmIndustryRights(data){ | |||||
| this.industryRights = data.text; | |||||
| this.form.industryRights = data.value; | |||||
| this.showIndustryRights = false; | |||||
| }, | |||||
| onConfirmIndustryType(data){ | |||||
| this.industryType = data.text; | |||||
| this.form.industryType = data.value; | |||||
| this.showIndustryType = false; | |||||
| }, | |||||
| onConfirmOccupyLandType(data){ | |||||
| this.occupyLandType = data.text; | |||||
| this.form.occupyLandType = data.value; | |||||
| this.showOccupyLandType = false; | |||||
| }, | |||||
| onConfirmOccupyLand(data){ | |||||
| this.occupyLand = data.text; | |||||
| this.form.occupyLand = data.value; | |||||
| this.showOccupyLand = false; | |||||
| }, | |||||
| onConfirmLandSource(data){ | |||||
| this.landSource = data.text; | |||||
| this.form.landSource = data.value; | |||||
| this.showLandSource = false; | |||||
| }, | |||||
| onConfirmIsLoan(data){ | |||||
| this.isLoan = data.text; | |||||
| this.form.isLoan = data.value; | |||||
| this.showIsLoan = false; | |||||
| }, | |||||
| onSubmit(){ | |||||
| updateIndustry(this.form).then(response => { | |||||
| if (response.code == 200){ | |||||
| this.$notify({ type: 'success', message: '新增成功' }); | |||||
| setTimeout(function(){ | |||||
| history.back(-1); | |||||
| },2000) | |||||
| } | |||||
| }); | |||||
| } | |||||
| }, | |||||
| } | |||||
| </script> | |||||
| <style scoped lang="scss"> | |||||
| /deep/ .van-button--primary{ | |||||
| background: url("../../assets/images/sunVillage_info/btn_bg.png") no-repeat; | |||||
| background-size: 100% 100%; | |||||
| border: none; | |||||
| } | |||||
| .home_wrapper{ | |||||
| background: #e9e9e9; | |||||
| min-height: 100vh; | |||||
| width: 100vw; | |||||
| .header_main { | |||||
| height: 116px; | |||||
| background: url('../../assets/images/sunVillage_info/list_head.png') no-repeat; | |||||
| background-size: 100% 100%; | |||||
| position: fixed; | |||||
| top: 0; | |||||
| left: 0; | |||||
| width: 100%; | |||||
| font-size: 36px; | |||||
| line-height: 116px; | |||||
| text-align: center; | |||||
| color: #fff; | |||||
| position: relative; | |||||
| .return_btn { | |||||
| width: 24px; | |||||
| height: 43.2px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_5.png') center center no-repeat; | |||||
| background-size: 20px 36px; | |||||
| position: absolute; | |||||
| left: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| .add_btn { | |||||
| width: 56.4px; | |||||
| height: 40.8px; | |||||
| background: url('../../assets/images/sunVillage_info/list_icon_9.png') center center no-repeat; | |||||
| background-size: 47px 34px; | |||||
| position: absolute; | |||||
| right: 38px; | |||||
| top: 36px; | |||||
| } | |||||
| } | |||||
| .list_main{ | |||||
| padding:25px; | |||||
| background: #ffffff; | |||||
| width: 94%; | |||||
| margin: 25px auto 0; | |||||
| border-radius: 15PX; | |||||
| box-shadow: 4px 6px 5px rgba(63, 68, 75, 0.1); | |||||
| } | |||||
| .titBox{ | |||||
| display: flex; | |||||
| align-items: center; | |||||
| } | |||||
| .tit{ | |||||
| font-size: 36px; | |||||
| font-weight: bold; | |||||
| } | |||||
| /deep/ .van-cell{ | |||||
| padding-left: 0!important; | |||||
| padding-right: 0!important; | |||||
| padding-bottom: 0!important; | |||||
| } | |||||
| /deep/ .van-field__label{ | |||||
| padding-left: 10PX; | |||||
| width: 8.2em; | |||||
| } | |||||
| /deep/ .van-cell--required::before{ | |||||
| left: 0; | |||||
| } | |||||
| } | |||||
| </style> | |||||