ソースを参照

产权交易

rongxin_prod
庞东旭 2年前
コミット
888ba23d49
1個のファイルの変更39行の追加20行の削除
  1. +39
    -20
      src/views/biddingHall/index.vue

+ 39
- 20
src/views/biddingHall/index.vue ファイルの表示

@@ -16,7 +16,7 @@
/> />
<van-row> <van-row>
<van-dropdown-menu> <van-dropdown-menu>
<van-dropdown-item v-model="value1" :options="projectTypeOption" @change="getList"/>
<van-dropdown-item v-model="value1" :options="projectTypeOption" @change="tabChange"/>
<van-dropdown-item :value="value2" :title="value2"> <van-dropdown-item :value="value2" :title="value2">
<van-tree-select <van-tree-select
:active-id.sync="activeId" :active-id.sync="activeId"
@@ -27,7 +27,7 @@
@click-nav="clickNav" @click-nav="clickNav"
/> />
</van-dropdown-item> </van-dropdown-item>
<van-dropdown-item v-model="value3" :options="option3" @change="getList"/>
<van-dropdown-item v-model="value3" :options="option3" @change="tabChange"/>
</van-dropdown-menu> </van-dropdown-menu>
</van-row> </van-row>
<van-row type="flex" justify="center" class="biddingProcessTitle"> <van-row type="flex" justify="center" class="biddingProcessTitle">
@@ -108,12 +108,12 @@
</van-col> </van-col>
<van-col span="1"></van-col> <van-col span="1"></van-col>
</van-row> </van-row>
<van-pull-refresh v-model="refreshing" @refresh="onRefresh">
<!-- <van-pull-refresh v-model="refreshing" @refresh="onRefresh">-->
<van-list <van-list
v-model="loading" v-model="loading"
:finished="finished" :finished="finished"
finished-text="没有更多了" finished-text="没有更多了"
@load="onL"
@load="getList"
> >
<van-row v-for="(item,index) in infoList" :key="index" :title="item" @click="goDetail(item.id)"> <van-row v-for="(item,index) in infoList" :key="index" :title="item" @click="goDetail(item.id)">
<van-col span="13" class="biddingProcessListLeftCol"> <van-col span="13" class="biddingProcessListLeftCol">
@@ -129,7 +129,7 @@
</van-col> </van-col>
</van-row> </van-row>
</van-list> </van-list>
</van-pull-refresh>
<!-- </van-pull-refresh>-->
</div> </div>
</template> </template>


@@ -165,13 +165,19 @@ export default {
deptListOption: [], deptListOption: [],
option3: [ option3: [
{ text: '竞价状态', value: '' }, { text: '竞价状态', value: '' },
{ text: '全部', value: '全部' },
{ text: '竞价中', value: '竞价中' },
{ text: '竞价结束', value: '竞价结束' },
{ text: '正在报名', value: '正在报名' },
{ text: '等待竞价', value: '等待竞价' },
{ text: '正在竞价', value: '正在竞价' },
{ text: '等待成交', value: '等待成交' },
{ text: '已经成交', value: '已经成交' },
], ],
loading: false, loading: false,
finished: false, finished: false,
refreshing: false, refreshing: false,
queryParams : {
pageNum:1,
pageSize:10
}
} }
}, },
created(){ created(){
@@ -203,26 +209,31 @@ export default {
this.$router.push({path:'project/projectDetail',query:{id:id}}) this.$router.push({path:'project/projectDetail',query:{id:id}})
}, },
getList(){ getList(){
let queryDatas = {
deptId: this.activeId,
projectNumber:this.value1,
projectShowStatus:this.value3
}
getBiddingList(queryDatas).then(response =>{
this.infoList = response.rows.map(item => {
this.queryParams.deptId = this.activeId;
this.queryParams.projectNumber = this.value1;
this.queryParams.projectShowStatus = this.value3;
getBiddingList(this.queryParams).then(response =>{
response.rows.map(item => {
if (item.biddingStopTime!=""){ if (item.biddingStopTime!=""){
let time = 0 let time = 0
let endDate = Date.parse(item.biddingStopTime);
let endDate = Date.parse(item.biddingStopTime);
let nowDate = Date.parse(new Date()); let nowDate = Date.parse(new Date());
if(endDate>nowDate){ if(endDate>nowDate){
time = endDate-nowDate>0?endDate-nowDate:0 time = endDate-nowDate>0?endDate-nowDate:0
} }
return{content:item.projectName,deadline:time,currentPrice:item.price,priceUnit:item.unit,id:item.id}
}else {
return{content:item.projectName,deadline:0,currentPrice:item.price,priceUnit:item.unit,id:item.id}
console.log(time)
this.infoList.push({content:item.projectName,deadline:time,currentPrice:item.price,priceUnit:item.unit,id:item.id})
}else{
this.infoList.push({content:item.projectName,deadline:0,currentPrice:item.price,priceUnit:item.unit,id:item.id})
} }

}) })
if(this.infoList.length >= response.total){
this.finished = true;
return;
}else{
this.loading = false;
this.queryParams.pageNum += 1 ;
}
}); });
}, },
clickNav(index){ clickNav(index){
@@ -230,6 +241,8 @@ export default {
}, },
clickItem(data){ clickItem(data){
console.log(data) console.log(data)
this.infoList = [];
this.queryParams.pageNum = 1;
if(data.text==this.value2){ if(data.text==this.value2){
this.activeId=1 this.activeId=1
this.value2='标的物位置' this.value2='标的物位置'
@@ -238,6 +251,12 @@ export default {
} }
this.getList() this.getList()
}, },
tabChange(){
this.infoList = [];
this.queryParams.pageNum = 1;
this.finished = false;
this.getList()
},
onSearch(val) { onSearch(val) {
this.loading = true; this.loading = true;
if(this.infoList.length>0){ if(this.infoList.length>0){


読み込み中…
キャンセル
保存