| this.pageLoading = true; | this.pageLoading = true; | ||||
| getCompanyNewsList(this.queryParams) | getCompanyNewsList(this.queryParams) | ||||
| .then(res => { | .then(res => { | ||||
| console.log(res.data); | |||||
| if (res.data.status == 0) { | if (res.data.status == 0) { | ||||
| this.dataList = res.data.data.list; | this.dataList = res.data.data.list; | ||||
| this.total = res.data.data.total; | this.total = res.data.data.total; |
| } | } | ||||
| .is-active button::after, | .is-active button::after, | ||||
| .el-carousel__indicator:hover button::after { | .el-carousel__indicator:hover button::after { | ||||
| opacity: 0.72; | |||||
| background: #0086e7; | |||||
| opacity: 0.72; | |||||
| background: #0086e7; | |||||
| } | } | ||||
| } | } | ||||
| </style> | </style> | ||||
| <Banner></Banner> | <Banner></Banner> | ||||
| <div> | <div> | ||||
| <park-introduce :navLists="indexTab" :parkInfo="parkInfo"></park-introduce> | <park-introduce :navLists="indexTab" :parkInfo="parkInfo"></park-introduce> | ||||
| <!-- 产业导向和发展方向 --> | |||||
| <ParkCard :name="'industrialOrientation'" :data="industrialOrientation" /> | |||||
| <product :leadingIndustryArr="leadingIndustryArr"></product> | <product :leadingIndustryArr="leadingIndustryArr"></product> | ||||
| <service></service> | <service></service> | ||||
| <advantage></advantage> | <advantage></advantage> | ||||
| <park-map :address="address"></park-map> | <park-map :address="address"></park-map> | ||||
| <ParkCard :name="'surroundingFacilities'" :data="surroundingFacilities" /> | |||||
| <Footer></Footer> | <Footer></Footer> | ||||
| <slide-nav :navLists="indexTab"></slide-nav> | <slide-nav :navLists="indexTab"></slide-nav> | ||||
| </div> | </div> | ||||
| import Footer from "@components/Footer.vue"; | import Footer from "@components/Footer.vue"; | ||||
| import SlideNav from "./SlideNav.vue"; | import SlideNav from "./SlideNav.vue"; | ||||
| import { getRegisterArea } from "@api/index"; | import { getRegisterArea } from "@api/index"; | ||||
| import ParkCard from "./ParkCard.vue"; | |||||
| export default { | export default { | ||||
| metaInfo: { | metaInfo: { | ||||
| ParkMap, | ParkMap, | ||||
| Footer, | Footer, | ||||
| SlideNav, | SlideNav, | ||||
| ParkCard, | |||||
| }, | }, | ||||
| data() { | data() { | ||||
| return { | return { | ||||
| parkInfo: null, | parkInfo: null, | ||||
| leadingIndustryArr: [], | leadingIndustryArr: [], | ||||
| address: null, | address: null, | ||||
| // 产业导向和发展方向 | |||||
| industrialOrientation: null, | |||||
| // 周边配套 | |||||
| surroundingFacilities: null, | |||||
| }; | }; | ||||
| }, | }, | ||||
| computed: {}, | computed: {}, | ||||
| methods: { | methods: { | ||||
| getRegisterArea() { | getRegisterArea() { | ||||
| getRegisterArea() | getRegisterArea() | ||||
| .then(res => { | |||||
| console.log(res.data,'获取地图数据'); | |||||
| .then((res) => { | |||||
| // console.log(res.data, "获取地图数据"); | |||||
| if (res.data.status == 0) { | if (res.data.status == 0) { | ||||
| this.parkInfo = res.data.data[0]; | this.parkInfo = res.data.data[0]; | ||||
| this.address = { | this.address = { | ||||
| lng: this.parkInfo.map.lng, | lng: this.parkInfo.map.lng, | ||||
| lat: this.parkInfo.map.lat, | lat: this.parkInfo.map.lat, | ||||
| }; | }; | ||||
| this.leadingIndustryArr = this.parkInfo.leadingIndustryList; | |||||
| this.leadingIndustryArr = | |||||
| this.parkInfo.leadingIndustryList; | |||||
| this.industrialOrientation = | |||||
| this.parkInfo.industrialOrientation; | |||||
| this.surroundingFacilities = | |||||
| this.parkInfo.surroundingFacilities; | |||||
| } else { | } else { | ||||
| this.$message.error(`获取数据失败,请刷新重试!`); | this.$message.error(`获取数据失败,请刷新重试!`); | ||||
| } | } | ||||
| }) | }) | ||||
| .catch(err => { | |||||
| this.$message.error(`获取数据失败,失败原因${err},请刷新重试!`); | |||||
| .catch((err) => { | |||||
| this.$message.error( | |||||
| `获取数据失败,失败原因${err},请刷新重试!` | |||||
| ); | |||||
| }); | }); | ||||
| }, | }, | ||||
| }, | }, |
| <template> | |||||
| <div class="park_card" :class="[name]" v-if="data"> | |||||
| <div class="card_title">{{ cardData[name] }}</div> | |||||
| <div class="card_content"> | |||||
| <div class="html_box"> | |||||
| <span v-html="floamtStr(data)"></span> | |||||
| </div> | |||||
| </div> | |||||
| </div> | |||||
| </template> | |||||
| <script> | |||||
| export default { | |||||
| props: { | |||||
| // 类型名称 | |||||
| name: { | |||||
| type: String, | |||||
| default: "", | |||||
| }, | |||||
| // 数据 | |||||
| data: { | |||||
| type: String, | |||||
| default: "", | |||||
| }, | |||||
| }, | |||||
| data() { | |||||
| return { | |||||
| cardData: { | |||||
| // 产业导向和发展方向 | |||||
| industrialOrientation: "产业导向和发展方向", | |||||
| // 周边配套 | |||||
| surroundingFacilities: "周边配套", | |||||
| }, | |||||
| }; | |||||
| }, | |||||
| methods: { | |||||
| floamtStr(str) { | |||||
| return str.replace(/\n/g, "<br/>"); | |||||
| }, | |||||
| }, | |||||
| }; | |||||
| </script> | |||||
| <style lang="scss" scoped> | |||||
| .park_card { | |||||
| @include size(100%, auto); | |||||
| @include flex(column, space-between, center, null); | |||||
| // | |||||
| padding-bottom: 100px; | |||||
| @include border-box; | |||||
| .card_title { | |||||
| @include font(36px, $color-white); | |||||
| padding: 60px 0 100px; | |||||
| @include border-box; | |||||
| } | |||||
| .card_content { | |||||
| width: 1200px; | |||||
| color: #fff; | |||||
| font-size: 36px; | |||||
| line-height: 50px; | |||||
| margin-top: 30px; | |||||
| } | |||||
| &.industrialOrientation { | |||||
| background: url("~@assets/image/index/bg_industrialOrientation.png") | |||||
| no-repeat; | |||||
| background-size: 100% 100%; | |||||
| } | |||||
| &.surroundingFacilities { | |||||
| background: url("~@assets/image/index/bg_surroundingFacilities.png") | |||||
| no-repeat; | |||||
| background-size: 100% 100%; | |||||
| .html_box { | |||||
| background: linear-gradient( | |||||
| 90deg, | |||||
| rgba(60, 220, 234, 0.2) 0%, | |||||
| rgba(60, 220, 234, 0) 100% | |||||
| ); | |||||
| border-radius: 8px; | |||||
| box-sizing: border-box; | |||||
| padding: 20px; | |||||
| } | |||||
| .card_title { | |||||
| padding-bottom: 40px; | |||||
| } | |||||
| .card_content { | |||||
| font-size: 16px; | |||||
| line-height: 30px; | |||||
| } | |||||
| } | |||||
| // &.surroundingFacilities .html_box { | |||||
| // background: linear-gradient(90deg, rgba(60, 220, 234, 0.2) 0%, rgba(60, 220, 234, 0) 100%); | |||||
| // border-radius: 8px; | |||||
| // } | |||||
| } | |||||
| </style> |
| this.serviceLoading = true; | this.serviceLoading = true; | ||||
| getParkServiceProduct(this.queryParams) | getParkServiceProduct(this.queryParams) | ||||
| .then(res => { | .then(res => { | ||||
| console.log(res.data); | |||||
| if (res.data.status == 0) { | if (res.data.status == 0) { | ||||
| this.tempList1 = res.data.data.list; | this.tempList1 = res.data.data.list; | ||||
| this.lists = this.tempList1; | this.lists = this.tempList1; | ||||
| this.serviceLoading = true; | this.serviceLoading = true; | ||||
| getPropertyManage(this.queryParams) | getPropertyManage(this.queryParams) | ||||
| .then(res => { | .then(res => { | ||||
| console.log(res.data); | |||||
| if (res.data.status == 0) { | if (res.data.status == 0) { | ||||
| this.tempList2 = res.data.data.list; | this.tempList2 = res.data.data.list; | ||||
| } else { | } else { |
| <!-- 资讯列表页 --> | <!-- 资讯列表页 --> | ||||
| <template> | <template> | ||||
| <div class=""> | |||||
| <div class> | |||||
| <div class="tab_box"> | <div class="tab_box"> | ||||
| <span | <span | ||||
| v-for="(item, index) in tabs" | v-for="(item, index) in tabs" | ||||
| :class="['pointer', activeTab === index ? 'active' : '']" | :class="['pointer', activeTab === index ? 'active' : '']" | ||||
| :key="item.itemId" | :key="item.itemId" | ||||
| @click="changeTab(index)" | @click="changeTab(index)" | ||||
| > | |||||
| {{ item.text }} | |||||
| </span> | |||||
| >{{ item.text }}</span> | |||||
| </div> | </div> | ||||
| <div v-loading="pageLoading" element-loading-text="数据加载中"> | <div v-loading="pageLoading" element-loading-text="数据加载中"> | ||||
| <search-box @search-data="searchData"></search-box> | |||||
| <search-box @search-data="searchData" :dropdownList="dropdownList"></search-box> | |||||
| <div class="detail_box" v-if="dataList && dataList.length > 0"> | <div class="detail_box" v-if="dataList && dataList.length > 0"> | ||||
| <question-list :list="dataList"></question-list> | <question-list :list="dataList"></question-list> | ||||
| <div class="pagination_box"> | <div class="pagination_box"> | ||||
| pageSize: 10, | pageSize: 10, | ||||
| search: "", | search: "", | ||||
| type: "", | type: "", | ||||
| policyCategory: "", | |||||
| }, | }, | ||||
| tempPolicyCategory: "", | |||||
| total: 0, | total: 0, | ||||
| dataList: null, | dataList: null, | ||||
| // 下拉选项 | |||||
| tabDropdown: [], | |||||
| dropdownList: [], | |||||
| }; | }; | ||||
| }, | }, | ||||
| //监听属性 类似于data概念 | //监听属性 类似于data概念 | ||||
| changeTab(index) { | changeTab(index) { | ||||
| this.activeTab = index; | this.activeTab = index; | ||||
| this.queryParams.type = this.tabs[index].itemId; | this.queryParams.type = this.tabs[index].itemId; | ||||
| this.getData(); | this.getData(); | ||||
| if (this.tabs[index].itemId == "012-0182fd1fe3aa2aaf") { | |||||
| this.dropdownList = this.$cloneDeep(this.tabDropdown); | |||||
| this.queryParams.policyCategory = this.tempPolicyCategory; | |||||
| } else { | |||||
| this.dropdownList = []; | |||||
| this.queryParams.policyCategory = ""; | |||||
| } | |||||
| }, | }, | ||||
| // getData() { | // getData() { | ||||
| // this.pageLoading = true; | // this.pageLoading = true; | ||||
| // }, | // }, | ||||
| //搜索 | //搜索 | ||||
| searchData(val) { | searchData(val) { | ||||
| this.queryParams.search = val; | |||||
| this.queryParams.search = val.searchInput; | |||||
| this.tempPolicyCategory = | |||||
| val.cutCommand == "all" ? "" : val.cutCommand; | |||||
| this.queryParams.policyCategory = this.tempPolicyCategory; | |||||
| this.queryParams.page = 1; | this.queryParams.page = 1; | ||||
| this.getData(); | this.getData(); | ||||
| }, | }, | ||||
| //生命周期 - 创建完成(可以访问当前this实例) | //生命周期 - 创建完成(可以访问当前this实例) | ||||
| created() { | created() { | ||||
| this.tabs = this.tabList.yuanquzixun_zixunleixing8; | this.tabs = this.tabList.yuanquzixun_zixunleixing8; | ||||
| this.tabDropdown = this.tabList.yuanquzixun_chanyezhengcexiaolei; | |||||
| this.queryParams.type = this.tabs[0].itemId; | this.queryParams.type = this.tabs[0].itemId; | ||||
| this.getData(); | this.getData(); | ||||
| }, | }, |
| <div class="search_box"> | <div class="search_box"> | ||||
| <img class="info_img" src="@assets/image/company/icon_info.png" alt="园区知识库" /> | <img class="info_img" src="@assets/image/company/icon_info.png" alt="园区知识库" /> | ||||
| <span class="search_title">园区知识库</span> | <span class="search_title">园区知识库</span> | ||||
| <search-input @search-data="searchData"></search-input> | |||||
| <search-input @search-data="searchData" :tagName="'question'" :dropdownList="dropdownList"></search-input> | |||||
| </div> | </div> | ||||
| </template> | </template> | ||||
| //例如:import 《组件名称》 from '《组件路径》'; | //例如:import 《组件名称》 from '《组件路径》'; | ||||
| export default { | export default { | ||||
| props: { | |||||
| dropdownList: { | |||||
| type: Array, | |||||
| }, | |||||
| }, | |||||
| //import引入的组件需要注入到对象中才能使用 | //import引入的组件需要注入到对象中才能使用 | ||||
| components: { SearchInput }, | components: { SearchInput }, | ||||
| data() { | data() { | ||||
| //方法集合 | //方法集合 | ||||
| methods: { | methods: { | ||||
| searchData(val) { | searchData(val) { | ||||
| this.$router.push({ | |||||
| path: "/park-information/question-search", | |||||
| query: { | |||||
| searchWord: val, | |||||
| }, | |||||
| }); | |||||
| if (val.cutCommand) { | |||||
| this.$emit("search-data", { | |||||
| searchInput: val.searchInput, | |||||
| cutCommand: val.cutCommand, | |||||
| }); | |||||
| } else { | |||||
| this.$router.push({ | |||||
| path: "/park-information/question-search", | |||||
| query: { | |||||
| searchWord: val.searchInput, | |||||
| }, | |||||
| }); | |||||
| } | |||||
| }, | }, | ||||
| }, | }, | ||||
| //生命周期 - 创建完成(可以访问当前this实例) | //生命周期 - 创建完成(可以访问当前this实例) |
| <!-- --> | <!-- --> | ||||
| <template> | <template> | ||||
| <div class="input_box"> | |||||
| <div class="input_box" :class="[tagName]"> | |||||
| <el-input | <el-input | ||||
| placeholder="请输入搜索内容" | placeholder="请输入搜索内容" | ||||
| v-model.trim="searchInput" | v-model.trim="searchInput" | ||||
| @clear="clearKeyWord" | @clear="clearKeyWord" | ||||
| > | > | ||||
| <div slot="prefix" class="icon_box"> | <div slot="prefix" class="icon_box"> | ||||
| <el-dropdown v-if="tagName=='question'" @command="handleCommand" trigger="click"> | |||||
| <span class="el-dropdown-link"> | |||||
| {{ getDropdownTitle() }} | |||||
| <i class="el-icon-arrow-down el-icon--right"></i> | |||||
| </span> | |||||
| <el-dropdown-menu slot="dropdown"> | |||||
| <el-dropdown-item command="all" :disabled="cutCommand == 'all'">全部</el-dropdown-item> | |||||
| <el-dropdown-item | |||||
| v-for="(item,inx) of dropdownList" | |||||
| :key="inx" | |||||
| :command="item.itemId" | |||||
| :disabled="cutCommand == item.itemId" | |||||
| >{{ item.text }}</el-dropdown-item> | |||||
| </el-dropdown-menu> | |||||
| </el-dropdown> | |||||
| <span class="shu" v-if="tagName=='question'">|</span> | |||||
| <img src="@assets/image/company/icon_search.png" alt="搜索" /> | <img src="@assets/image/company/icon_search.png" alt="搜索" /> | ||||
| </div> | </div> | ||||
| <div slot="append" class="pointer" @click="searchByKeyword">搜索</div> | <div slot="append" class="pointer" @click="searchByKeyword">搜索</div> | ||||
| //例如:import 《组件名称》 from '《组件路径》'; | //例如:import 《组件名称》 from '《组件路径》'; | ||||
| export default { | export default { | ||||
| props: { | |||||
| // 标签名字,用来切换样式 | |||||
| tagName: { | |||||
| type: String, | |||||
| default: "", | |||||
| }, | |||||
| dropdownList: { | |||||
| type: Array, | |||||
| default:()=>[], | |||||
| }, | |||||
| }, | |||||
| //import引入的组件需要注入到对象中才能使用 | //import引入的组件需要注入到对象中才能使用 | ||||
| components: {}, | components: {}, | ||||
| data() { | data() { | ||||
| //这里存放数据 | //这里存放数据 | ||||
| return { | return { | ||||
| searchInput: "", | searchInput: "", | ||||
| cutCommand: "all", | |||||
| }; | }; | ||||
| }, | }, | ||||
| //监听属性 类似于data概念 | //监听属性 类似于data概念 | ||||
| watch: {}, | watch: {}, | ||||
| //方法集合 | //方法集合 | ||||
| methods: { | methods: { | ||||
| getDropdownTitle(){ | |||||
| let title = "全部"; | |||||
| this.dropdownList.forEach(el=>{ | |||||
| if(el.itemId == this.cutCommand){ | |||||
| title = el.text; | |||||
| } | |||||
| }) | |||||
| return title; | |||||
| }, | |||||
| handleCommand(command) { | |||||
| this.cutCommand = command; | |||||
| this.getDropdownTitle(); | |||||
| this.searchByKeyword(); | |||||
| }, | |||||
| searchByKeyword() { | searchByKeyword() { | ||||
| this.$emit("search-data", this.searchInput); | |||||
| if (this.tagName == "question") { | |||||
| this.$emit("search-data", { | |||||
| searchInput: this.searchInput, | |||||
| cutCommand: this.cutCommand, | |||||
| }); | |||||
| } else { | |||||
| this.$emit("search-data", this.searchInput); | |||||
| } | |||||
| }, | }, | ||||
| clearKeyWord() { | clearKeyWord() { | ||||
| this.searchInput = ""; | this.searchInput = ""; | ||||
| this.$emit("search-data", this.searchInput); | |||||
| this.cutCommand = "all"; | |||||
| if (this.tagName == "question") { | |||||
| this.$emit("search-data", { | |||||
| searchInput: this.searchInput, | |||||
| cutCommand: "all", | |||||
| }); | |||||
| } else { | |||||
| this.$emit("search-data", this.searchInput); | |||||
| } | |||||
| }, | }, | ||||
| }, | }, | ||||
| //生命周期 - 创建完成(可以访问当前this实例) | //生命周期 - 创建完成(可以访问当前this实例) | ||||
| height: 100%; | height: 100%; | ||||
| line-height: 60px; | line-height: 60px; | ||||
| } | } | ||||
| &.question { | |||||
| .shu { | |||||
| margin: 0 20px; | |||||
| } | |||||
| ::v-deep .el-input__prefix{ | |||||
| width: 176px; | |||||
| } | |||||
| ::v-deep .el-input__inner { | |||||
| padding-left: 182px; | |||||
| } | |||||
| } | |||||
| .el-dropdown-link { | |||||
| cursor: pointer; | |||||
| } | |||||
| } | } | ||||
| </style> | </style> |
| // target: "http://localhost:8089", | // target: "http://localhost:8089", | ||||
| // 测试环境 | // 测试环境 | ||||
| // target: "http://192.168.18.236:18888/", | // target: "http://192.168.18.236:18888/", | ||||
| // 临时测试环境 | |||||
| // 线上测试环境 | |||||
| target: "http://park.test.hhrchina.com/", | target: "http://park.test.hhrchina.com/", | ||||
| // 谢老师 | // 谢老师 | ||||
| // target: "http://192.168.18.138:18888/", | // target: "http://192.168.18.138:18888/", | ||||
| // 阚老师 | // 阚老师 | ||||
| // target: "http://192.168.18.121:18888/", | |||||
| // target: "http://192.168.18.7:18888/", | |||||
| // 何老师 | // 何老师 | ||||
| // target: "http://192.168.30.48:18888/", | // target: "http://192.168.30.48:18888/", | ||||
| changeOrigin: true, | changeOrigin: true, |