'优化2'
This commit is contained in:
parent
f371c2c9e0
commit
a993e98d19
@ -65,7 +65,7 @@
|
||||
</view>
|
||||
<view class="flex-between goodsWrap">
|
||||
<view class="goodsBox1 flex-center" style="width: 40%;">
|
||||
<image :src="item.type_image" class="goodsImg"></image>
|
||||
<image :src="path+item.type_image" class="goodsImg"></image>
|
||||
<view>
|
||||
<view class="goodsText1">回收品类</view>
|
||||
<view class="goodsText2">{{item.type_name}}</view>
|
||||
@ -86,7 +86,7 @@
|
||||
<view class="remarkBox">备注:{{item.remark}}</view>
|
||||
<view class="flex-between userBox">
|
||||
<view class="flex-center">
|
||||
<image src="/static/img/39.png" class="userImg"></image>
|
||||
<!-- <image src="/static/img/39.png" class="userImg"></image> -->
|
||||
<view>{{item.accept_name}}</view>
|
||||
</view>
|
||||
<view class="userBtn flex-center" @click.stop="setorder(item.id)">
|
||||
@ -115,7 +115,7 @@
|
||||
<!-- <view class="timeLabel">36分钟内</view> -->
|
||||
<view class="timeLabel2">{{item.order_time_text}}</view>
|
||||
</view>
|
||||
<view class="distant">1.5公里</view>
|
||||
<view class="distant">{{item.distance}}公里</view>
|
||||
</view>
|
||||
<view class="flex-between addressBox">
|
||||
<view class="addressText">{{item.accept_address}}</view>
|
||||
@ -144,7 +144,7 @@
|
||||
<view class="remarkBox">备注:{{item.remark}}</view>
|
||||
<view class="flex-between userBox">
|
||||
<view class="flex-center">
|
||||
<image src="/static/img/39.png" class="userImg"></image>
|
||||
<!-- <image src="/static/img/39.png" class="userImg"></image> -->
|
||||
<view>{{item.person_name}}</view>
|
||||
</view>
|
||||
<view class="flex-center contactText" @click.stop="callPhone(item.person_mobile)">
|
||||
@ -159,8 +159,9 @@
|
||||
</view>
|
||||
<view v-if="item.status!=7 && item.status!=2"></view>
|
||||
<view class="flex-center statusText1" v-show="item.status==2">
|
||||
<view @click.stop="moreShow=!moreShow">更多操作</view>
|
||||
<view class="floatBtnBox" v-show="moreShow">
|
||||
<!-- <view @click.stop="moreShow[item.id]=!moreShow[item.id]">更多操作</view> -->
|
||||
<view @click.stop="moreClick(item.id)">更多操作</view>
|
||||
<view class="floatBtnBox" v-show="moreShow[item.id]">
|
||||
<view class="floatBtnEle" @click.stop="cancleClickOrder(item.id)">取消订单</view>
|
||||
<view class="btnLine"></view>
|
||||
<view class="floatBtnEle" @click.stop="changeClickOrder(item.id)">改派订单</view>
|
||||
@ -359,6 +360,7 @@
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
path: this.path,
|
||||
userinfo: {},
|
||||
personInfo: {},
|
||||
jscode:'',
|
||||
@ -425,7 +427,7 @@
|
||||
pop3Show: false,
|
||||
pop4Show: false,
|
||||
notesText: '',
|
||||
moreShow: false,
|
||||
moreShow: {},
|
||||
orderId: '',
|
||||
statusToast: '',
|
||||
showCity: false,
|
||||
@ -479,6 +481,11 @@
|
||||
},
|
||||
onLoad() {
|
||||
this.getauth()
|
||||
|
||||
/* #ifdef H5 */
|
||||
this.latitude = 32.199974
|
||||
this.longitude = 118.715805
|
||||
/* #endif */
|
||||
// let _this = this;
|
||||
// util.getAddress(function(res){
|
||||
// _this.cityText = res.city;
|
||||
@ -532,6 +539,9 @@
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
moreClick(id){
|
||||
this.$set(this.moreShow, id, this.moreShow[id]?false:true)
|
||||
},
|
||||
callPhone(phoneNumber) {
|
||||
uni.makePhoneCall({
|
||||
phoneNumber: phoneNumber, // 必需,电话号码字符串
|
||||
@ -545,6 +555,8 @@
|
||||
},
|
||||
initFun(){
|
||||
let _this = this;
|
||||
this.recycleList = []
|
||||
this.qiangdanArr = []
|
||||
if(this.longitude){
|
||||
util.getAddress(function(res){
|
||||
_this.cityText = res.city;
|
||||
@ -556,7 +568,7 @@
|
||||
})
|
||||
this.recycleOrderList()
|
||||
}else{
|
||||
_this.qiangdanlist()
|
||||
this.qiangdanlist()
|
||||
this.recycleOrderList()
|
||||
}
|
||||
},
|
||||
@ -622,7 +634,8 @@
|
||||
this.$api.cancelorder(data,res=>{
|
||||
if(res.code == '1'){
|
||||
uni.showToast({ title: this.statusToast , icon: 'success' })
|
||||
this.recycleOrderList()
|
||||
// this.recycleOrderList()
|
||||
this.initFun();
|
||||
this.cancleShow = false
|
||||
setTimeout(()=>{
|
||||
this.menuNum = 2
|
||||
@ -653,7 +666,8 @@
|
||||
if(res.code == '1'){
|
||||
_this.tabCur = 3;
|
||||
uni.showToast({ title: '签到成功' , icon: 'success' })
|
||||
_this.recycleOrderList()
|
||||
// _this.recycleOrderList()
|
||||
this.initFun();
|
||||
setTimeout(()=>{
|
||||
_this.menuNum = 2
|
||||
},2000)
|
||||
@ -670,7 +684,8 @@
|
||||
if(res.code == '1'){
|
||||
_this.tabCur = 3;
|
||||
uni.showToast({ title: '签到成功' , icon: 'success' })
|
||||
_this.recycleOrderList()
|
||||
// _this.recycleOrderList()
|
||||
this.initFun();
|
||||
setTimeout(()=>{
|
||||
_this.menuNum = 2
|
||||
},2000)
|
||||
@ -727,7 +742,8 @@
|
||||
if(res.code == '1'){
|
||||
this.tabCur = 2;
|
||||
uni.showToast({ title: this.statusToast , icon: 'success' })
|
||||
this.recycleOrderList()
|
||||
// this.recycleOrderList()
|
||||
this.initFun();
|
||||
setTimeout(()=>{
|
||||
this.menuNum = 2
|
||||
},2000)
|
||||
@ -745,7 +761,11 @@
|
||||
if(res.code == '1'){
|
||||
this.tabCur = 7;
|
||||
uni.showToast({ title: '抢单成功' , icon: 'success' })
|
||||
this.recycleOrderList()
|
||||
// this.recycleList = []
|
||||
// this.qiangdanArr = []
|
||||
// this.recycleOrderList()
|
||||
// this.qiangdanlist()
|
||||
this.initFun();
|
||||
setTimeout(()=>{
|
||||
this.menuNum = 2
|
||||
},2000)
|
||||
@ -762,17 +782,20 @@
|
||||
cancleClickOrder(id){
|
||||
this.orderId = id
|
||||
this.cancleShow = true
|
||||
this.moreShow = false
|
||||
// this.moreShow = false
|
||||
this.$set(this.moreShow, id, false)
|
||||
},
|
||||
changeClickOrder(id){
|
||||
this.pop4Show = true
|
||||
this.moreShow = false
|
||||
// this.moreShow = false
|
||||
this.orderId = id
|
||||
this.$set(this.moreShow, id, false)
|
||||
},
|
||||
selectTab(id){
|
||||
this.page=1
|
||||
this.page2=1
|
||||
this.tabCur = id
|
||||
// this.recycleList = []
|
||||
this.recycleList = []
|
||||
this.recycleOrderList(id)
|
||||
},
|
||||
qiangdanlist(){
|
||||
console.log('fffffffff')
|
||||
@ -793,12 +816,14 @@
|
||||
}
|
||||
})
|
||||
},
|
||||
recycleOrderList(){
|
||||
recycleOrderList(status){
|
||||
console.log('fffffffff')
|
||||
let data = {
|
||||
status: '',
|
||||
status: status,
|
||||
page: this.page2,
|
||||
limit: this.limit
|
||||
// longitude: this.longitude,
|
||||
// latitude: this.latitude
|
||||
}
|
||||
this.$api.recycleOrderList(data,res=>{
|
||||
if(res.code == '1'){
|
||||
|
||||
183
pages/index/person.vue
Normal file
183
pages/index/person.vue
Normal file
@ -0,0 +1,183 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<view class="problem " v-if="list.length > 0">
|
||||
<view class="problem_main">
|
||||
<view class="li" v-for="(item,index) in list" :key="index" @click="show(index)">
|
||||
<view class="left frex-start">
|
||||
<view class="zmLable">Q</view>
|
||||
<view class="left_2 rightContent">{{item.name}}</view>
|
||||
<!-- <view class="left_1" >
|
||||
<image v-if="item.is_show==1" class="icon" src="/static/img/up.png" mode=""></image>
|
||||
<image v-if="item.is_show==0" class="icon" src="/static/img/down.png" mode=""></image>
|
||||
</view> -->
|
||||
</view>
|
||||
<view class="frex-start">
|
||||
<view class="zmLable">A</view>
|
||||
<view class="rightContent">
|
||||
<lookMore :content="item.content"></lookMore>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view class="textBox" @click="getH">
|
||||
{{item.content}}
|
||||
</view> -->
|
||||
<!-- <u-read-more>
|
||||
<rich-text :nodes="content" :showHeight="30"></rich-text>
|
||||
</u-read-more> -->
|
||||
<!-- <u-read-more ref="uReadMore">
|
||||
<u-parse :content="item.content" @load="load"></u-parse>
|
||||
</u-read-more> -->
|
||||
<!-- <view class="left " v-if="item.is_show==1">
|
||||
<view class="left_3"><text style="white-space: pre-wrap;line-height: 20px;">{{item.content}}</text></view>
|
||||
</view> -->
|
||||
</view>
|
||||
<!-- <uni-load-more :status="loadmore" :content-text="contentText" /> -->
|
||||
</view>
|
||||
</view>
|
||||
<uni-load-more :status="loadmore" :content-text="contentText" />
|
||||
<view class="zanwuimg" v-if="list.length == 0">
|
||||
<image src="../../static/img/null.png" mode="widthFix"></image>
|
||||
<view>暂无相关数据</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default{
|
||||
data(){
|
||||
return{
|
||||
list:[],
|
||||
ifBottomRefresh:false,
|
||||
loadmore: 'more',
|
||||
contentText: {
|
||||
contentdown: '查看更多',
|
||||
contentrefresh: '加载中',
|
||||
contentnomore: ''
|
||||
}
|
||||
}
|
||||
},
|
||||
onLoad(e) {
|
||||
this.getdata()
|
||||
},
|
||||
onShow() {
|
||||
},
|
||||
onReachBottom() {
|
||||
this.page += 1
|
||||
if (this.loadmore == 'noMore') return
|
||||
this.ifBottomRefresh = true
|
||||
this.getData()
|
||||
},
|
||||
methods:{
|
||||
getH(){
|
||||
const query = uni.createSelectorQuery().in(this);
|
||||
query.select('.textBox').boundingClientRect(({ height }) => {
|
||||
console.log('square_giant的高度是:' + height + 'px');
|
||||
}).exec();
|
||||
},
|
||||
load() {
|
||||
this.$refs.uReadMore.init();
|
||||
},
|
||||
show(index){
|
||||
var list = this.list;
|
||||
list.forEach((item,index2) => {
|
||||
if(index == index2){
|
||||
list[index2].is_show = item.is_show==1 ? 0: 1;
|
||||
}
|
||||
})
|
||||
this.list = list;
|
||||
},
|
||||
getdata(){
|
||||
let data={page:this.page}
|
||||
this.$api.question_list(data,res=>{
|
||||
if(res.code == '1'){
|
||||
this.list= this.list.concat(res.data.list.data)
|
||||
this.loadmore = this.list.length < res.data.list.total ? 'more' : 'noMore'
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
page{
|
||||
// background: #fff;
|
||||
background: rgb(245,245,250);
|
||||
}
|
||||
.content{
|
||||
padding: 20rpx 35rpx;
|
||||
}
|
||||
.problem{
|
||||
background-color: #fff;
|
||||
border-radius: 30rpx;
|
||||
padding-top: 15rpx;
|
||||
padding-bottom: 17rpx;
|
||||
.problem_main{
|
||||
width: 92%;
|
||||
margin: 0 auto;padding-bottom: 10px;
|
||||
|
||||
.li{
|
||||
padding-top: 20rpx;
|
||||
border-bottom: 1px solid #eee;
|
||||
.left{
|
||||
overflow: hidden;
|
||||
margin-bottom: 20rpx;
|
||||
.left_1{
|
||||
float: left;
|
||||
height: 4vh;
|
||||
width: 4vh;
|
||||
}
|
||||
.left_2{
|
||||
font-size: 30rpx;
|
||||
float:left;
|
||||
width: 90%;
|
||||
}
|
||||
.left_3{
|
||||
font-size: 24rpx;
|
||||
float:left;
|
||||
width: 92%;color: #676767;padding-left: 12px;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
.li:last-child{
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
.articleBox{
|
||||
padding: 29rpx 24rpx 38rpx 35rpx;
|
||||
.articleInfo{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: flex-start;
|
||||
.articleTitle{
|
||||
margin-top: 10rpx;
|
||||
font-weight: bold;
|
||||
font-size: 30rpx;
|
||||
color: #282F38;
|
||||
width: 350rpx;
|
||||
}
|
||||
img{
|
||||
margin-left: 20rpx;
|
||||
}
|
||||
}
|
||||
.articleData{
|
||||
font-size: 24rpx;
|
||||
color: #999999;
|
||||
margin-top: 36rpx;
|
||||
}
|
||||
}
|
||||
.zmLable{
|
||||
color: #FB8F0C;
|
||||
font-weight: 800;
|
||||
// margin-right: 15rpx;
|
||||
width: 38rpx;
|
||||
}
|
||||
.frex-start{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.rightContent{
|
||||
width: calc(100% - 38rpx)
|
||||
}
|
||||
</style>
|
||||
@ -118,6 +118,7 @@
|
||||
<view style="margin-left: 28rpx;">{{order_person_time}}</view>
|
||||
</view>
|
||||
<view class="flex-center">
|
||||
<text v-show="!order_person_time" class="recordLable">选择预约时间</text>
|
||||
<u-icon name="arrow-right" color="#333333" size="13"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user