Ver a proveniência

前端修改

wulanhaote
庞东旭 há 3 anos
ascendente
cometimento
9b7eee173f
4 ficheiros alterados com 69 adições e 39 eliminações
  1. +11
    -2
      src/api/notice/index.js
  2. +4
    -4
      src/main.js
  3. +1
    -1
      src/views/index.vue
  4. +53
    -32
      src/views/notice/index.vue

+ 11
- 2
src/api/notice/index.js Ver ficheiro

@@ -1,10 +1,19 @@
import request from '@/utils/request'

//通讯录查询
export function newList(query) {
//成交公告
export function noticeList(query) {
return request({
url: '/transaction/website/outproject/publicity',
method: 'get',
params: query
})
}

//鉴证公告
export function Attestation(query) {
return request({
url: '/transaction/website/jzlist',
method: 'get',
params: query
})
}

+ 4
- 4
src/main.js Ver ficheiro

@@ -11,10 +11,10 @@ import './config/flexible'
import store from './store/'
import './permission' // permission control

// import { getDicts } from "utils/data";
//
// //全局方法挂载
// Vue.prototype.getDicts = () => new getDicts();
import { getDicts } from "@/utils/data";
//全局方法挂载
Vue.prototype.getDicts = getDicts;

// Vant 引用
import Vant from 'vant';


+ 1
- 1
src/views/index.vue Ver ficheiro

@@ -7,7 +7,7 @@
<van-col span="22" style="line-height: 29px;font-size: 20px;">农村产权交易平台</van-col>
</van-row>
<van-swipe class="my-swipe" :autoplay="3000" height="180" indicator-color="white">
<van-swipe-item v-for="item in bannerList" v-key="item.id">
<van-swipe-item v-for="item in bannerList" :key="item.id">
<van-image :src="item.img" height="180" />
<p class="bannerTit">{{item.title}}</p>
</van-swipe-item>


+ 53
- 32
src/views/notice/index.vue Ver ficheiro

@@ -14,20 +14,11 @@
:finished="finished"
finished-text="没有更多了"
style="margin-top: 10px;"
@load="getList"
>
<van-cell icon="play" title="海勃湾区森林草原防火区划定:哪些地方是重点防火区严禁做什么?">
<van-cell v-for="item in noticeList" icon="play" :key="item.id" :title="item.projectName">
<template #label>
项目编号:TD-ZC-21213685 <p style="float: right;">2021-06-30</p>
</template>
</van-cell>
<van-cell icon="play" title="海勃湾区森林草原防火区划定:哪些地方是重点防火区严禁做什么?">
<template #label>
项目编号:TD-ZC-21213685 <p style="float: right;">2021-06-30</p>
</template>
</van-cell>
<van-cell icon="play" title="海勃湾区森林草原防火区划定:哪些地方是重点防火区严禁做什么?">
<template #label>
项目编号:TD-ZC-21213685 <p style="float: right;">2021-06-30</p>
项目编号:{{item.projectCode}} <p style="float: right;">{{item.contractDate}}</p>
</template>
</van-cell>
</van-list>
@@ -35,22 +26,13 @@
<van-tab title="选项">
<template #title><van-icon name="records" size="18" style="top: 4px"/>鉴证公告</template>
<van-list
v-model="loading"
:finished="finished"
v-model="loading1"
:finished="finished1"
finished-text="没有更多了"
style="margin-top: 10px;"
@load="getAttestationList"
>
<van-cell icon="play" title="海勃湾区森林草原防火区划定:哪些地方是重点防火区严禁做什么?">
<template #label>
鉴证书编号:[202113184] <p style="float: right;">2021-06-30</p>
</template>
</van-cell>
<van-cell icon="play" title="海勃湾区森林草原防火区划定:哪些地方是重点防火区严禁做什么?">
<template #label>
鉴证书编号:[202113184] <p style="float: right;">2021-06-30</p>
</template>
</van-cell>
<van-cell icon="play" title="海勃湾区森林草原防火区划定:哪些地方是重点防火区严禁做什么?">
<van-cell v-for="item in attestationList" :key="item.id" icon="play" :title="item.projectName">
<template #label>
鉴证书编号:[202113184] <p style="float: right;">2021-06-30</p>
</template>
@@ -62,7 +44,7 @@
</template>

<script>
import { newList } from "@/api/notice/index";
import { noticeList , Attestation } from "@/api/notice/index";
export default {
name: "notice",
data() {
@@ -70,16 +52,55 @@ export default {
//是否显示加载
loading: false,
//是否滚动到底部
finished: true,
finished: false,
//是否显示加载
loading1: false,
//是否滚动到底部
finished1: false,
//成交公告集合
noticeList:[],
//鉴证公告集合
attestationList:[],
//查询参数
queryParams: {
deptId:100,
},
};
},
mounted() {
getDicts("project_type").then(response => {
console.log(response)
})
created() {

},
methods: {

//成交公告集合
getList(){
this.loading = true;
noticeList(this.queryParams).then(response => {
console.log(response);
this.noticeList = response.rows;
console.log(this.noticeList)
if(this.noticeList.length >= response.total){
this.finished = true;
return;
}
this.queryParams.pageNum += 1 ;
this.loading = false;
});
},
//鉴证公告集合
getAttestationList(){
this.loading = true;
Attestation(this.queryParams).then(response => {
console.log(response);
this.attestationList = response.rows;
console.log(this.attestationList)
if(this.attestationList.length >= response.total){
this.finished = true;
return;
}
this.queryParams.pageNum += 1 ;
this.loading = false;
});
},
},
};
</script>


Carregando…
Cancelar
Guardar