|
@@ -2,30 +2,32 @@
|
|
|
<view>
|
|
|
<view style='background:#fff;border-bottom:1px solid #EEE;padding-bottom:10px;'>
|
|
|
<view class="cu-bar search">
|
|
|
- <view style='position:absolute;left:30px;top:50%;transform: translateY(-50%);'>
|
|
|
- <picker style='display:inline-block;' @change="locationChange" :value="location" :range="locationType">
|
|
|
- <view class="picker">
|
|
|
- {{location>-1?locationType[location]:'请选择'}}
|
|
|
+ <view style='position:absolute;left:30px;top:50%;transform: translateY(-50%);'>
|
|
|
+ <picker style='display:inline-block;' @change="locationChange" :value="location"
|
|
|
+ :range="locationType">
|
|
|
+ <view class="picker">
|
|
|
+ {{location>-1?locationType[location]:'请选择'}}
|
|
|
+ </view>
|
|
|
+ </picker>
|
|
|
+ <image style='width:10px;height:6px;margin-left:4px;position:relative;top:-2px;'
|
|
|
+ src='../../static/img/jiaoyi/down.png'></image>
|
|
|
+ </view>
|
|
|
+ <view class="search-form round" @click="naviageToPage('/pageA/product/lookup?TabCur=')">
|
|
|
+ <text style='color: #ccc;text-indent:56px;' class="cuIcon-search"></text>
|
|
|
+ <input type="text" placeholder="请输入货名或标题" confirm-type="search"></input>
|
|
|
</view>
|
|
|
- </picker>
|
|
|
- <image style='width:10px;height:6px;margin-left:4px;position:relative;top:-2px;' src='../../static/img/jiaoyi/down.png'></image>
|
|
|
- </view>
|
|
|
- <view class="search-form round" @click="naviageToPage('/pageA/product/lookup?TabCur=')">
|
|
|
- <text style='color: #ccc;text-indent:56px;' class="cuIcon-search"></text>
|
|
|
- <input type="text" placeholder="请输入货名或标题" confirm-type="search"></input>
|
|
|
</view>
|
|
|
- </view>
|
|
|
- <view style='margin:0 15px;'>
|
|
|
- <view class='tag radius line-pink' @click="sousuo('玉米')">玉米</view>
|
|
|
- <view class='tag radius line-pink' @click="sousuo('大豆')">大豆</view>
|
|
|
- <view class='tag radius line-pink' @click="sousuo('小麦')">小麦</view>
|
|
|
- <view class='tag radius line-pink' @click="sousuo('水稻')">水稻</view>
|
|
|
- <view class='tag radius line-pink' @click="sousuo('高粱')">高粱</view>
|
|
|
- </view>
|
|
|
+ <view style='margin:0 15px;'>
|
|
|
+ <view class='tag radius line-pink' @click="sousuo('玉米')">玉米</view>
|
|
|
+ <view class='tag radius line-pink' @click="sousuo('大豆')">大豆</view>
|
|
|
+ <view class='tag radius line-pink' @click="sousuo('小麦')">小麦</view>
|
|
|
+ <view class='tag radius line-pink' @click="sousuo('水稻')">水稻</view>
|
|
|
+ <view class='tag radius line-pink' @click="sousuo('高粱')">高粱</view>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
<view style='background:#fff;padding:0 15px;'>
|
|
|
<view @click='tabcarchange(0)' class='line' :class='TabCur==0?"active":""'>采购</view>
|
|
|
- <view @click='tabcarchange(1)' class='line' :class='TabCur==1?"active":""'>销售</view>
|
|
|
+ <view @click='tabcarchange(1)' class='line' :class='TabCur==1?"active":""'>销售</view>
|
|
|
</view>
|
|
|
<view v-if='buyInfo.length>0' class="introduce-section">
|
|
|
<view v-for="(item, index) in buyInfo" :key="index" class="guess-item" @click="navToDetailPage(item)">
|
|
@@ -36,8 +38,10 @@
|
|
|
<view class='address'>
|
|
|
{{item.receivePrivate}}{{item.receiveCity}}{{item.receiveArea}}{{item.receiveWarehouse}}
|
|
|
</view>
|
|
|
- <view class='price' v-if='item.procurementPlanType=="期货"'>{{item.basisPrice}}<text style='font-size:13px;color:#333333;'>元/吨</text></view>
|
|
|
- <view class='price' v-if='item.procurementPlanType=="现货"'>{{item.unitPrice}}<text style='font-size:13px;color:#333;'>元/吨</text></view>
|
|
|
+ <view class='price' v-if='item.procurementPlanType=="期货"'>{{item.basisPrice}}<text
|
|
|
+ style='font-size:13px;color:#333333;'>元/吨</text></view>
|
|
|
+ <view class='price' v-if='item.procurementPlanType=="现货"'>{{item.unitPrice}}<text
|
|
|
+ style='font-size:13px;color:#333;'>元/吨</text></view>
|
|
|
</view>
|
|
|
<view class='flex justify-between'>
|
|
|
<view>
|
|
@@ -54,24 +58,17 @@
|
|
|
<uni-load-more :status="loadStatus"></uni-load-more>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view style='height:65vh;background:#F5F6FA;line-height:65vh;text-align:center;' v-if='buyInfo.length==0'>
|
|
|
+ <view style='height:65vh;background:#F5F6FA;line-height:65vh;text-align:center;' v-if='buyInfo.length==0'>
|
|
|
当前暂无结果
|
|
|
</view>
|
|
|
<u-back-top :scroll-top="scrollTop" tips="顶部" :custom-style="{backgroundColor: '#a0cfff',color: '#2979ff'}"
|
|
|
:iconStyle="{color: '#2979ff',fontSize: '34rpx'}" mode="square" icon="arrow-up"></u-back-top>
|
|
|
- <view>
|
|
|
- <view
|
|
|
- id="_drag_button"
|
|
|
- class="drag"
|
|
|
- style="right:0;bottom:60px;"
|
|
|
- @touchstart="touchstart"
|
|
|
- @touchmove.stop.prevent="touchmove"
|
|
|
- @touchend="touchend"
|
|
|
- @click.stop.prevent="fabu"
|
|
|
- >
|
|
|
+ <view>
|
|
|
+ <view id="_drag_button" class="drag" style="right:0;bottom:60px;" @touchstart="touchstart"
|
|
|
+ @touchmove.stop.prevent="touchmove" @touchend="touchend" @click.stop.prevent="fabu">
|
|
|
<image class='side-bg' src='../../static/img/jiaoyi/ic_fabu@3x.png'></image>
|
|
|
- </view>
|
|
|
</view>
|
|
|
+ </view>
|
|
|
<!-- <drag-button :isDock="true" :existTabBar="true" :isIcon="true" text="发布" location="20" @btnClick="fabu" /> -->
|
|
|
</view>
|
|
|
</template>
|
|
@@ -88,10 +85,10 @@
|
|
|
isLoadMore: false, //是否加载中
|
|
|
showTran: true,
|
|
|
scrollTop: 0,
|
|
|
- pageSize:10,
|
|
|
- searchKeyWord:'',
|
|
|
- receivePrivate:'',
|
|
|
- currentPage:1,
|
|
|
+ pageSize: 10,
|
|
|
+ searchKeyWord: '',
|
|
|
+ receivePrivate: '',
|
|
|
+ currentPage: 1,
|
|
|
categoryList: [{
|
|
|
title: '我要买粮',
|
|
|
id: '0'
|
|
@@ -102,7 +99,7 @@
|
|
|
TabCur: 0,
|
|
|
current: 1,
|
|
|
location: 0,
|
|
|
- locationType: ['全国','黑龙江', '河南', '山东', '安徽', '吉林', '河北', '江苏', '内蒙古', '四川', '湖南', '湖北', '辽宁',
|
|
|
+ locationType: ['全国', '黑龙江', '河南', '山东', '安徽', '吉林', '河北', '江苏', '内蒙古', '四川', '湖南', '湖北', '辽宁',
|
|
|
'江西', '云南', '新疆', '山西', '广西', '陕西', '广东', '甘肃', '重庆', '贵州', '浙江', '福建',
|
|
|
'宁夏', '天津', '海南', '青海', '西藏', '上海', '北京'
|
|
|
]
|
|
@@ -138,8 +135,8 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
- sousuo(name){
|
|
|
- var page = '/pageA/product/lookup?TabCur=' + this.TabCur+'&searchKeyWord='+name
|
|
|
+ sousuo(name) {
|
|
|
+ var page = '/pageA/product/lookup?TabCur=' + this.TabCur + '&searchKeyWord=' + name
|
|
|
uni.navigateTo({
|
|
|
url: page,
|
|
|
fail() {
|
|
@@ -149,8 +146,8 @@
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
- tabcarchange(status){
|
|
|
- this.TabCur=status
|
|
|
+ tabcarchange(status) {
|
|
|
+ this.TabCur = status
|
|
|
this.pageSize = 1
|
|
|
this.loadData()
|
|
|
},
|
|
@@ -166,7 +163,7 @@
|
|
|
})
|
|
|
},
|
|
|
locationChange(e) {
|
|
|
-
|
|
|
+
|
|
|
this.receivePrivate = e.detail.value
|
|
|
this.pageSize = 1
|
|
|
this.loadData()
|
|
@@ -180,10 +177,10 @@
|
|
|
fabu() {
|
|
|
uni.showActionSheet({
|
|
|
itemList: ['我要买粮', '我要卖粮'],
|
|
|
- success (res) {
|
|
|
+ success(res) {
|
|
|
console.log(res.tapIndex)
|
|
|
},
|
|
|
- fail (res) {
|
|
|
+ fail(res) {
|
|
|
console.log(res.errMsg)
|
|
|
}
|
|
|
})
|
|
@@ -202,21 +199,25 @@
|
|
|
if (that.TabCur == 0) {
|
|
|
param1 = '/procurementPlanInfo/selectProcurementPlanInfo'
|
|
|
} else {
|
|
|
- param1 = 'buy'
|
|
|
+ param1 = '/salePlanInfo/selectSalePlanInfo'
|
|
|
}
|
|
|
- this.$api.doRequest('get', param1,{pageSize:this.pageSize,
|
|
|
- showFlag:1,
|
|
|
-currentPage:this.currentPage,searchKeyWord:this.searchKeyWord,receivePrivate:this.receivePrivate}).then(res => {
|
|
|
- uni.hideLoading()
|
|
|
- this.buyInfo=res.data.data.records
|
|
|
- })
|
|
|
- .catch(res => {
|
|
|
- uni.showToast({
|
|
|
- title: res.errmsg,
|
|
|
- icon:'none',
|
|
|
- duration: 2000
|
|
|
+ this.$api.doRequest('get', param1, {
|
|
|
+ pageSize: this.pageSize,
|
|
|
+ showFlag: 1,
|
|
|
+ currentPage: this.currentPage,
|
|
|
+ searchKeyWord: this.searchKeyWord,
|
|
|
+ receivePrivate: this.receivePrivate
|
|
|
+ }).then(res => {
|
|
|
+ uni.hideLoading()
|
|
|
+ this.buyInfo = res.data.data.records
|
|
|
})
|
|
|
- });
|
|
|
+ .catch(res => {
|
|
|
+ uni.showToast({
|
|
|
+ title: res.errmsg,
|
|
|
+ icon: 'none',
|
|
|
+ duration: 2000
|
|
|
+ })
|
|
|
+ });
|
|
|
// that.$api.request(param1, param2, {
|
|
|
// page: 1,
|
|
|
// limit: 10
|
|
@@ -330,79 +331,93 @@ currentPage:this.currentPage,searchKeyWord:this.searchKeyWord,receivePrivate:thi
|
|
|
.content {
|
|
|
background: #F5F6FA;
|
|
|
}
|
|
|
- .line{
|
|
|
- display:inline-block;
|
|
|
- padding:5px;
|
|
|
- position:relative;
|
|
|
- font-size:17px;
|
|
|
+
|
|
|
+ .line {
|
|
|
+ display: inline-block;
|
|
|
+ padding: 5px;
|
|
|
+ position: relative;
|
|
|
+ font-size: 17px;
|
|
|
}
|
|
|
- .line.active{
|
|
|
- font-size:19px;
|
|
|
+
|
|
|
+ .line.active {
|
|
|
+ font-size: 19px;
|
|
|
font-weight: 900;
|
|
|
}
|
|
|
- .line.active:after{
|
|
|
- content:'';
|
|
|
- display:block;
|
|
|
- position:absolute;
|
|
|
- width:18px;
|
|
|
- left:50%;
|
|
|
+
|
|
|
+ .line.active:after {
|
|
|
+ content: '';
|
|
|
+ display: block;
|
|
|
+ position: absolute;
|
|
|
+ width: 18px;
|
|
|
+ left: 50%;
|
|
|
transform: translateX(-50%);
|
|
|
- bottom:0;
|
|
|
- border-bottom:1px solid #22C572;
|
|
|
+ bottom: 0;
|
|
|
+ border-bottom: 1px solid #22C572;
|
|
|
}
|
|
|
+
|
|
|
.cu-tag.badge {
|
|
|
right: 26rpx;
|
|
|
}
|
|
|
+
|
|
|
.cu-item {
|
|
|
height: 80rpx;
|
|
|
display: inline-block;
|
|
|
line-height: 80rpx;
|
|
|
}
|
|
|
+
|
|
|
.search-form {
|
|
|
background: #F5F6F9;
|
|
|
}
|
|
|
+
|
|
|
.title-tip {
|
|
|
color: #E63113;
|
|
|
text-align: right;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
.tag1 {
|
|
|
- background:#F5F6F9;
|
|
|
+ background: #F5F6F9;
|
|
|
padding: 5px;
|
|
|
- color:#333333;
|
|
|
+ color: #333333;
|
|
|
display: inline-flex;
|
|
|
font-size: 22rpx;
|
|
|
border-radius: 3px;
|
|
|
margin: 3px;
|
|
|
}
|
|
|
+
|
|
|
.tag {
|
|
|
- background:#F5F6F9;
|
|
|
+ background: #F5F6F9;
|
|
|
padding: 7px 12px;
|
|
|
- color:#333333;
|
|
|
+ color: #333333;
|
|
|
display: inline-flex;
|
|
|
font-size: 22rpx;
|
|
|
border-radius: 15px;
|
|
|
margin: 3px;
|
|
|
}
|
|
|
+
|
|
|
.tag-bule {
|
|
|
background: #EBEEFA;
|
|
|
color: #5C76DF;
|
|
|
}
|
|
|
+
|
|
|
.tag-green {
|
|
|
background: #C6F7BC;
|
|
|
color: #065112;
|
|
|
}
|
|
|
+
|
|
|
.tag-yellow {
|
|
|
background: #F9F2EA;
|
|
|
color: #BE9C69;
|
|
|
}
|
|
|
+
|
|
|
.tag-red {
|
|
|
background: #FEECE6;
|
|
|
color: #FE6430;
|
|
|
}
|
|
|
+
|
|
|
.text-white {
|
|
|
color: #fff;
|
|
|
}
|
|
|
+
|
|
|
.text-white text {
|
|
|
position: relative;
|
|
|
z-index: 2;
|
|
@@ -645,35 +660,39 @@ currentPage:this.currentPage,searchKeyWord:this.searchKeyWord,receivePrivate:thi
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-.introduce-section .title{
|
|
|
- font-size: 17px;
|
|
|
- font-weight: bold;
|
|
|
- height:40px;
|
|
|
- line-height: 40px;
|
|
|
- flex: 2.5;
|
|
|
- border-bottom:1px solid #EEEEEE;
|
|
|
-}
|
|
|
-.introduce-section .address{
|
|
|
- color:#878C9C;
|
|
|
- font-size:12px;
|
|
|
- padding:15px 0 10px;
|
|
|
-}
|
|
|
-.introduce-section .price{
|
|
|
- padding:10px 0 10px;
|
|
|
- color:#FD714F;
|
|
|
- font-size:19px;
|
|
|
- font-weight:700;
|
|
|
-}
|
|
|
-.introduce-section .guess-item{
|
|
|
- border-radius:4px;
|
|
|
- background: #fff;
|
|
|
- padding: 0upx 30upx 20upx;
|
|
|
- margin:10px;
|
|
|
- padding-bottom: 20upx;
|
|
|
- border-bottom: 1px solid #ccc;
|
|
|
- }
|
|
|
+ .introduce-section .title {
|
|
|
+ font-size: 17px;
|
|
|
+ font-weight: bold;
|
|
|
+ height: 40px;
|
|
|
+ line-height: 40px;
|
|
|
+ flex: 2.5;
|
|
|
+ border-bottom: 1px solid #EEEEEE;
|
|
|
+ }
|
|
|
+
|
|
|
+ .introduce-section .address {
|
|
|
+ color: #878C9C;
|
|
|
+ font-size: 12px;
|
|
|
+ padding: 15px 0 10px;
|
|
|
+ }
|
|
|
+
|
|
|
+ .introduce-section .price {
|
|
|
+ padding: 10px 0 10px;
|
|
|
+ color: #FD714F;
|
|
|
+ font-size: 19px;
|
|
|
+ font-weight: 700;
|
|
|
+ }
|
|
|
+
|
|
|
+ .introduce-section .guess-item {
|
|
|
+ border-radius: 4px;
|
|
|
+ background: #fff;
|
|
|
+ padding: 0upx 30upx 20upx;
|
|
|
+ margin: 10px;
|
|
|
+ padding-bottom: 20upx;
|
|
|
+ border-bottom: 1px solid #ccc;
|
|
|
+ }
|
|
|
+
|
|
|
/* 销售信息 */
|
|
|
- .introduce-section{
|
|
|
+ .introduce-section {
|
|
|
.title-tip {
|
|
|
flex: 1;
|
|
|
}
|
|
@@ -718,27 +737,29 @@ currentPage:this.currentPage,searchKeyWord:this.searchKeyWord,receivePrivate:thi
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- .side-bg{
|
|
|
- position:absolute;
|
|
|
+
|
|
|
+ .side-bg {
|
|
|
+ position: absolute;
|
|
|
width: 64px;
|
|
|
height: 64px;
|
|
|
z-index: 1;
|
|
|
}
|
|
|
+
|
|
|
.drag {
|
|
|
- position:relative;
|
|
|
+ position: relative;
|
|
|
display: flex;
|
|
|
justify-content: center;
|
|
|
align-items: center;
|
|
|
color: $uni-text-color-inverse;
|
|
|
width: 64px;
|
|
|
height: 64px;
|
|
|
- background:transparent;
|
|
|
+ background: transparent;
|
|
|
font-size: $uni-font-size-sm;
|
|
|
position: fixed;
|
|
|
z-index: 9;
|
|
|
-
|
|
|
+
|
|
|
&.transition {
|
|
|
- transition: left .3s ease,top .3s ease;
|
|
|
+ transition: left .3s ease, top .3s ease;
|
|
|
}
|
|
|
}
|
|
|
</style>
|