| | |
| | | VUE_APP_DEBUG = 'off' |
| | | |
| | | # VUE_APP_API_URL = 'https://test.doumee.cn/jinkuai_admin' |
| | | VUE_APP_API_URL = 'http://192.168.0.212/jinkuai_admin' |
| | | VUE_APP_API_URL = 'https://jinkuai.832smartfarm.com/jinkuai_admin' |
| | |
| | | uni.getLocation({ |
| | | type: 'wgs84', |
| | | success: (addr) => { |
| | | const locParam = { latitude: addr.latitude, longitude: addr.longitude ,address:'获取地址失败'}; |
| | | const locParam = { latitude: addr.latitude, longitude: addr.longitude }; |
| | | uni.setStorageSync('address', locParam); |
| | | var address =null |
| | | const qqmapsdk = new QQMapWX({ |
| | | key: '4PXBZ-JLBC7-LCLXG-P2SZX-C4HYE-LDBLQ' //腾讯地图申请的key(后续需要公司提供,个人开发者额度有限) |
| | |
| | | Vue.prototype.$isResolve = resolve; |
| | | }) |
| | | |
| | | Vue.prototype.$baseUrl = 'http://192.168.1.54:10011/' |
| | | // Vue.prototype.$baseUrl = 'http://192.168.1.54:10011/' |
| | | // Vue.prototype.$baseUrl = 'https://test.doumee.cn/jinkuai_web/' |
| | | Vue.prototype.$baseUrl = 'https://jinkuai.832smartfarm.com/jinkuai_web/' |
| | | |
| | | const app = new Vue({ |
| | | store, |
| | |
| | | <view class="eidt-phone" v-if="[2].includes(item.status)">联系师傅</view> |
| | | <view class="eidt-phone" v-if="item.status === 4 && item.commentStatus === 0">评价订单</view> |
| | | <view class="eidt-btn" v-if="[0,1,2].includes(item.status) && item.type !== 2" @click.stop="jumpEdit(item)">修改订单</view> |
| | | <view class="eidt-btn" v-if="(item.type === 2 && item.status === 0) || (item.type === 2 && item.status === 3)" @click.stop="jumpEdit(item)">继续支付</view> |
| | | <view class="eidt-btn" v-if="(item.type !== 2 && item.status === 0) || (item.type !== 2 && item.status === 3)" @click.stop="jumpEdit(item)">继续支付</view> |
| | | <!-- <view class="eidt-btn" v-if="item.status === 2" @click.stop="startJobs(item.id)">开始作业</view> --> |
| | | <view class="eidt-btn" v-if="item.status === 3" @click.stop="jumpDesc(item)">完成并支付</view> |
| | | <view class="eidt-btn" v-if="item.type != 2 && item.status === 3" @click.stop="jumpDesc(item)">完成并支付</view> |
| | | <view class="eidt-btn" v-if="item.type == 2 && item.status === 3" @click.stop="jumpDesc(item)">完成作业</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <!-- 接单方 --> |
| | | <view class="index-list" v-if="typeViewId === 1"> |
| | | <view class="index-list-item" v-for="(item, index) in orderList" :key="index" @click="jumpDesc(item)"> |
| | | <view class="index-list-wu" v-if="orderList.length === 0"> |
| | | <text>已加载全部数据</text> |
| | | </view> |
| | | <view class="index-list-item" v-for="(item, index) in orderList" :key="index" @click="jumpDesc(item)" v-else> |
| | | <view class="index-list-item-head"> |
| | | <view class="index-list-item-head-l"> |
| | | <view class="xoam"></view> |
| | |
| | | { name: '已接单', id: 2 }, |
| | | { name: '进行中', id: 3 }, |
| | | { name: '已完成', id: 4 }, |
| | | { name: '已取消', id: 99 }, |
| | | // { name: '已取消', id: 99 }, |
| | | ], |
| | | list1: [ |
| | | { name: '全部', id: '' }, |
| | |
| | | { name: '进行中', id: 3 }, |
| | | { name: '已完成', id: 4 }, |
| | | { name: '已取消', id: 99 }, |
| | | { name: '待评价', id: [4, 0] } |
| | | { name: '待评价', id: 5 } |
| | | ], |
| | | orderId: null, |
| | | status: '', |
| | |
| | | page: this.page, |
| | | model: { |
| | | queryMyOrderType: this.userInfo.useIdentity, |
| | | status: this.status, |
| | | status: this.status === 5 ? 4 : this.status, |
| | | commentStatus: this.status === 5 ? 0 : '', |
| | | queryLat: this.latitude, |
| | | queryLgt: this.longitude |
| | | } |
| | |
| | | }) |
| | | }, |
| | | clickOrderType(id) { |
| | | if (typeof id === 'object') { |
| | | this.status = id[0] |
| | | this.commentStatus = id[1] |
| | | } else { |
| | | // if (typeof id === 5) { |
| | | // this.status = 5 |
| | | // // this.commentStatus = 0 |
| | | // } else { |
| | | this.commentStatus = '' |
| | | this.status = id |
| | | } |
| | | // } |
| | | this.orderList = [] |
| | | this.next = true |
| | | this.page = 1 |
| | |
| | | <template> |
| | | <view class="box"> |
| | | <view class="box-head" :style="{ backgroundImage: 'url(' + bgImg + ')' }"> |
| | | <view class="box-head"> |
| | | <!-- 用工 --> |
| | | <image class="box-head-bg" src="@/static/image/bg_renzheng_yonggong@2x.png" mode="widthFix" v-if="title === '用工认证'"></image> |
| | | <!-- 货运 --> |
| | | <image class="box-head-bg" src="@/static/image/bg_renzheng_huoyun@2x.png" mode="widthFix" v-if="title === '货运认证'"></image> |
| | | <!-- 用餐 --> |
| | | <image class="box-head-bg" src="@/static/image/bg_renzheng_gongcan@2x.png" mode="widthFix" v-if="title === '供餐认证'"></image> |
| | | <view class="box-head-info"> |
| | | <text>{{title}}</text> |
| | | <text>请按要求填写认证信息</text> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | bgImg: require('@/static/image/bg_renzheng_yonggong@2x.png'), |
| | | bgImg: null, |
| | | title: '用户认证', |
| | | flag: null, |
| | | |
| | |
| | | return false |
| | | }, |
| | | applySubmit() { |
| | | console.log(this.loading) |
| | | if (this.loading) { |
| | | return |
| | | } |
| | |
| | | this.inNullParam(this.form.lgt) || |
| | | this.inNullParam(this.form.location) || |
| | | this.inNullParam(this.form.telephone)) { |
| | | |
| | | uni.showToast({ |
| | | title: '对不起,请按要求填写申请信息1!', |
| | | icon: "none", |
| | |
| | | param.img2 = this.form.img21 |
| | | } |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['4H9ztG4E9BxJLwMuYSZ6oiM7yb4KX7u7bYhkhYJP0-Y'], |
| | | tmplIds: ['VJho7-lf-4_WZFfOzenDndgwNDIA0EvCiE6vqBnExpQ'], |
| | | success(res) { |
| | | console.log('提交参数:', param) |
| | | that.$u.api.applyForIdentity(param).then(res => { |
| | |
| | | }).finally(() => { |
| | | that.loading = false |
| | | }) |
| | | }, |
| | | fail(err) { |
| | | console.log(err) |
| | | } |
| | | }) |
| | | }, |
| | |
| | | height: 300rpx; |
| | | padding: 34rpx 40rpx 0 40rpx; |
| | | box-sizing: border-box; |
| | | background-repeat: no-repeat; |
| | | background-size: 100% 100%; |
| | | // background-repeat: no-repeat; |
| | | // background-size: 100% 100%; |
| | | position: relative; |
| | | |
| | | .box-head-bg { |
| | | width: 100%; |
| | | height: 300rpx; |
| | | position: absolute; |
| | | top: 0; |
| | | left: 0; |
| | | z-index: -1; |
| | | } |
| | | |
| | | .box-head-botton { |
| | | width: 100%; |
| | |
| | | <view class="list-item-row"> |
| | | <view class="list-item-row-label">运输重量/数量<b>*</b></view> |
| | | <view class="list-item-row-val"> |
| | | <input type="text" v-model="form.transportNum" placeholder="请输入" /> |
| | | <view @click="show4 = true" style="width: 100%; flex-shrink: 0; display: flex; align-items: center; justify-content: flex-end;"> |
| | | <input type="text" style="flex: 1;" v-model="form.transportNum" placeholder="请输入" /> |
| | | <view @click="show4 = true" style="width: 100rpx; flex-shrink: 0; display: flex; align-items: center; justify-content: flex-end;"> |
| | | <text>{{form.transportUnit}}</text> |
| | | <u-icon name="arrow-down" color="#111111" size="16"></u-icon> |
| | | </view> |
| | |
| | | <u-calendar |
| | | :show="show2" |
| | | color="#00BC12" |
| | | :allowSameDay="true" |
| | | mode="range" |
| | | @close="show2 = false" |
| | | @confirm="confirmDate" /> |
| | |
| | | }) |
| | | } else { |
| | | const res = uni.getStorageSync('carData'); |
| | | console.log(res) |
| | | this.form.linkPhone = this.userInfo.telephone |
| | | this.form.linkName = this.userInfo.name |
| | | this.form.startDate = res.startDate |
| | | this.form.endDate = res.endDate |
| | | this.form.lat = res.lat |
| | |
| | | }, |
| | | // 提交订单 |
| | | submit() { |
| | | var that = this; |
| | | if (!this.form.carUnit) { |
| | | return uni.showToast({ title: '请选择货车型号', icon: 'none' }) |
| | | } |
| | |
| | | if (!this.form.linkPhone) { |
| | | return uni.showToast({ title: '请输入联系电话', icon: 'none' }) |
| | | } |
| | | if (!this.form.id) { |
| | | this.$u.api.release({ |
| | | ...this.form, |
| | | price: Number(this.form.price) * 100, |
| | | if (!that.form.id) { |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['oVjOBLcHxIlGzOMJsdInmgI5CHGXh-UTvMzQqfFOnIg'], |
| | | success(res) { |
| | | that.$u.api.release({ |
| | | ...that.form, |
| | | price: Number(that.form.price) * 100, |
| | | wayInfoDTOList: [ |
| | | { |
| | | lat: this.form.lat, |
| | | lgt: this.form.lgt, |
| | | location: this.form.location |
| | | lat: that.form.lat, |
| | | lgt: that.form.lgt, |
| | | location: that.form.location |
| | | }, |
| | | ...this.form.wayInfoDTOList, |
| | | ...that.form.wayInfoDTOList, |
| | | { |
| | | lat: this.form.latEnd, |
| | | lgt: this.form.lgtEnd, |
| | | location: this.form.locationEnd |
| | | lat: that.form.latEnd, |
| | | lgt: that.form.lgtEnd, |
| | | location: that.form.locationEnd |
| | | } |
| | | ] |
| | | }).then(res => { |
| | |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } else { |
| | | this.$u.api.updateOrder({ |
| | | ...this.form, |
| | | price: Number(this.form.price) * 100, |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['3YSC7gouRlSjHXz4CrWOGFzPmGwEBtFj4snwdfMvKHk'], |
| | | success(res) { |
| | | that.$u.api.updateOrder({ |
| | | ...that.form, |
| | | price: Number(that.form.price) * 100, |
| | | wayInfoDTOList: [ |
| | | { |
| | | lat: this.form.lat, |
| | | lgt: this.form.lgt, |
| | | location: this.form.location |
| | | lat: that.form.lat, |
| | | lgt: that.form.lgt, |
| | | location: that.form.location |
| | | }, |
| | | ...this.form.wayInfoDTOList, |
| | | ...that.form.wayInfoDTOList, |
| | | { |
| | | lat: this.form.latEnd, |
| | | lgt: this.form.lgtEnd, |
| | | location: this.form.locationEnd |
| | | lat: that.form.latEnd, |
| | | lgt: that.form.lgtEnd, |
| | | location: that.form.locationEnd |
| | | } |
| | | ] |
| | | }).then(res => { |
| | |
| | | uni.navigateBack({ delta: 1 }); |
| | | // uni.$emit('refresh') |
| | | }, 1500) |
| | | |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | |
| | | confirmDate(e) { |
| | | this.form.startDate = e[0] |
| | | this.form.endDate = e[e.length - 1] |
| | | this.form.priceNum1 = e.length; |
| | | let time = this.form.startDate == this.form.endDate ? 1 : 0 |
| | | this.form.priceNum1 = e.length - time; |
| | | this.show2 = false |
| | | }, |
| | | addAddr() { |
| | |
| | | <template> |
| | | <view class="index"> |
| | | <!-- 接单方 --> |
| | | <view class="index-j" v-if="typeViewId === 1"> |
| | | <view class="index-j" v-if="userInfo && userInfo.useIdentity === 1"> |
| | | <view class="index-j-head"> |
| | | <view :style="{ width: '100%', height: statusbarHeight + 'px' }"></view> |
| | | <view class="index-c-title" :style="{ height: navHeight + 'px' }"> |
| | |
| | | <text>¥{{item.estimatedAccount / 100}}</text> |
| | | </view> |
| | | <view class="eidt"> |
| | | <sunui-mverify @change="getaccept($event, item.id, index)"></sunui-mverify> |
| | | <!-- <sunui-mverify @change="getaccept($event, item.id, index)"></sunui-mverify> --> |
| | | <view class="eidt-btn" @click="show1 = true, orderId = item.id">抢单</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | |
| | | <!-- 发单方 --> |
| | | <view class="index-c" v-if="typeViewId === 0"> |
| | | <view class="index-c" v-if="!userInfo || userInfo.useIdentity === 0"> |
| | | <view :style="{ width: '100%', height: statusbarHeight + 'px' }"></view> |
| | | <view class="index-c-title" :style="{ height: navHeight + 'px' }" @click="selectAddress(-1)"> |
| | | <text class="index-c-title-logo">近快</text> |
| | |
| | | <view :class="child.active ? 'radio-item-list-item active' : 'radio-item-list-item'" v-for="(child, childIndex) in item.list" :key="childIndex" @click="selectMenu(index, childIndex)">{{child.price}}元</view> |
| | | </view> |
| | | <view class="radio-item-list-data"> |
| | | <text>份数:</text> |
| | | <text style="flex-shrink: 0;">份数:</text> |
| | | <input type="number" v-model="item.num" placeholder="请输入"> |
| | | <text style="color: #999999;">份</text> |
| | | <view class="radio-item-list-data-btn" @click="clear(index)">取消</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | </view> |
| | | |
| | | <!-- 选择日期范围 --> |
| | | <u-calendar :show="show" color="#00BC12" mode="range" @close="show = false" @confirm="confirmDate"></u-calendar> |
| | | <u-popup :show="showPhone" round="15" mode="bottom" @close="contactPhone()" :closeable="true" :closeOnClickOverlay="true"> |
| | | <u-calendar :show="show" color="#00BC12" :allowSameDay="true" mode="range" @close="show = false" @confirm="confirmDate"></u-calendar> |
| | | |
| | | <u-popup :show="showPhone" round="15" mode="bottom" :safeAreaInsetBottom="true" @close="contactPhone()" :closeable="true" :closeOnClickOverlay="true"> |
| | | <view class="phone"> |
| | | <view class="phone-head"> |
| | | <view></view> |
| | |
| | | <view></view> |
| | | <text>{{item}}</text> |
| | | </view> |
| | | <view style="width: 100%; height: 30rpx;"></view> |
| | | <!-- <view class="phone-botton" @click="contactPhone()" >关闭</view> --> |
| | | </view> |
| | | </u-popup> |
| | | |
| | | <u-modal |
| | | title="温馨提示" |
| | | :show="show1" |
| | | closeOnClickOverlay |
| | | showCancelButton |
| | | > |
| | | <view class="slot-content"> |
| | | 是否确认抢单? |
| | | </view> |
| | | <view slot="confirmButton" style="display: flex; justify-content: space-between; align-items: center; width: 100%;"> |
| | | <view class="btn1" @click="show1 = false">取消</view> |
| | | <view class="btn2" @click="getaccept1">确认</view> |
| | | </view> |
| | | </u-modal> |
| | | </view> |
| | | </template> |
| | | |
| | |
| | | linkName: '', |
| | | linkPhone: '', |
| | | estimatedAccount: '', |
| | | price: '' |
| | | price: '', |
| | | address: '' |
| | | }, |
| | | sortType: 0, |
| | | orderList: [], |
| | |
| | | page: 1, |
| | | next: true, |
| | | |
| | | isOnce: true |
| | | isOnce: true, |
| | | show1: false, |
| | | orderId: null |
| | | } |
| | | }, |
| | | async onLoad() { |
| | | await this.$onLaunched; |
| | | |
| | | if (this.token && this.token != '' && this.userInfo && JSON.stringify(this.userInfo) != '{}' && this.userInfo.useIdentity === 1) { |
| | | this.getOrderList() |
| | | } |
| | | console.log('2') |
| | | // if (this.token && this.token != '' && this.userInfo && JSON.stringify(this.userInfo) != '{}' && this.userInfo.useIdentity === 1) { |
| | | // this.getOrderList() |
| | | // } |
| | | |
| | | this.getCategoryLists() |
| | | this.getDictInfo() |
| | | |
| | | if (this.token && this.token != '' && this.userInfo && JSON.stringify(this.userInfo) != '{}') { |
| | | this.form.linkPhone = this.userInfo.telephone |
| | | this.form.linkPhone = this.userInfo.telephone || '' |
| | | this.form.linkName = this.userInfo.name || '' |
| | | } |
| | | |
| | | this.qqmapsdk = new QQMapWX({ |
| | |
| | | this.form.locationRemark = '' |
| | | this.form.supplement = '' |
| | | this.form.multifileList = [] |
| | | this.form.linkName = '' |
| | | this.form.estimatedAccount = '' |
| | | this.form.price = '' |
| | | this.form.address = '' |
| | | this.orderFood = [] |
| | | }) |
| | | // 刷新首页数据 |
| | | uni.$on('refresh', () => { |
| | |
| | | } |
| | | }) |
| | | }, |
| | | onShow(options) { |
| | | this.typeViewId = 0 |
| | | async onShow(options) { |
| | | await this.$onLaunched; |
| | | console.log('2') |
| | | |
| | | if(this.token && this.token != '' && this.userInfo && JSON.stringify(this.userInfo) != '{}') { |
| | | console.log('已登陆') |
| | | this.isLogin = true |
| | | |
| | | if (!this.isOnce && this.userInfo.useIdentity == 1) { |
| | | // this.typeViewId = this.userInfo.useIdentity |
| | | // !this.isOnce && |
| | | if (this.userInfo.useIdentity === 1) { |
| | | console.log('已登陆111') |
| | | this.page = 1 |
| | | this.next = true |
| | | this.orderList = [] |
| | |
| | | this.isLogin = false |
| | | console.log('未登陆') |
| | | } |
| | | |
| | | if (this.userInfo && this.userInfo.useIdentity == 1) { |
| | | this.typeViewId = 1 |
| | | } |
| | | }, |
| | | watch: { |
| | | typeId: { |
| | | handler(news, old) { |
| | | console.log('typeId') |
| | | this.form.startDate = '' |
| | | |
| | | this.form.address = '' |
| | | this.form.endDate = '' |
| | | this.form.latitude = '' |
| | | this.form.longitude = '' |
| | |
| | | this.form.locationRemark = '' |
| | | this.form.supplement = '' |
| | | this.form.multifileList = [] |
| | | this.form.linkName = '' |
| | | this.form.estimatedAccount = '' |
| | | this.form.price = '' |
| | | this.viewStatus = false |
| | |
| | | } |
| | | }, |
| | | methods: { |
| | | clear(index) { |
| | | this.orderFood[index].num = '' |
| | | this.orderFood[index].list.forEach(item => { |
| | | item.active = false |
| | | }) |
| | | }, |
| | | getDictInfo(){ |
| | | var that = this; |
| | | this.$u.api.getPlatformAboutUs({}).then(res =>{ |
| | |
| | | } |
| | | }, |
| | | // 手动接单 |
| | | getaccept(e, orderId, index) { |
| | | if (!e.msg) return; |
| | | this.$u.api.accept({ orderId }) |
| | | .then(res => { |
| | | if (res.code === 200) { |
| | | getaccept() { |
| | | var that = this; |
| | | that.$u.api.accept({ orderId: this.orderId }) |
| | | .then(res1 => { |
| | | if (res1.code === 200) { |
| | | uni.showToast({ title: '抢单成功!', icon: 'success', duration: 2000 }) |
| | | setTimeout(() => { |
| | | this.page = 1 |
| | | this.next = true |
| | | this.orderList = [] |
| | | this.getOrderList() |
| | | that.page = 1 |
| | | that.next = true |
| | | that.orderList = [] |
| | | that.getOrderList() |
| | | }, 2000) |
| | | } |
| | | }) |
| | | }, |
| | | getaccept1() { |
| | | var that = this; |
| | | this.show1 = false |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['tDpYImlrdv-0d3euTrHbYZ1cEZvjVHTNlqHvV0tpLHg'], |
| | | success(res) { |
| | | that.getaccept() |
| | | }, |
| | | fail(err) { |
| | | that.getaccept() |
| | | } |
| | | }) |
| | | }, |
| | |
| | | queryMyOrderType: 2, |
| | | type: this.typeVal, |
| | | sortType: this.sortType, |
| | | queryLat: this.latitude, |
| | | queryLgt: this.longitude |
| | | queryLat: uni.getStorageSync('address').latitude, |
| | | queryLgt: uni.getStorageSync('address').longitude |
| | | } |
| | | }).then(res => { |
| | | if (res.code !== 200) return; |
| | |
| | | }, |
| | | // 提交订单 |
| | | submit() { |
| | | var that = this |
| | | if (!this.form.startDate) { |
| | | return uni.showToast({ title: '请选择用餐时间', icon: 'none' }) |
| | | } |
| | |
| | | if (!this.form.linkPhone) { |
| | | return uni.showToast({ title: '请输入联系电话', icon: 'none' }) |
| | | } |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['oVjOBLcHxIlGzOMJsdInmgI5CHGXh-UTvMzQqfFOnIg'], |
| | | success(res) { |
| | | let cateringDTOList = [] |
| | | this.orderFood.forEach(item => { |
| | | that.orderFood.forEach(item => { |
| | | item.list.forEach(child => { |
| | | if (child.active) { |
| | | // (Number(child.price) * Number(item.num)) |
| | | cateringDTOList.push({ |
| | | name: item.name, |
| | | num: item.num, |
| | | price: (Number(child.price) * Number(item.num)) * 100 |
| | | price: child.price * 100 |
| | | }) |
| | | } |
| | | }) |
| | | }) |
| | | this.$u.api.release({ |
| | | ...this.form, |
| | | that.$u.api.release({ |
| | | ...that.form, |
| | | type: 2, |
| | | price: Number(this.form.price) * 100, |
| | | priceNum1: this.form.days, |
| | | location: this.form.address, |
| | | lat: this.form.latitude, |
| | | lgt: this.form.longitude, |
| | | price: Number(that.form.price) * 100, |
| | | priceNum1: that.form.days, |
| | | location: that.form.address, |
| | | lat: that.form.latitude, |
| | | lgt: that.form.longitude, |
| | | cateringDTOList |
| | | }).then(res => { |
| | | if (res.code == 200) { |
| | |
| | | } |
| | | }) |
| | | console.log(cateringDTOList) |
| | | }, |
| | | fail(err) { |
| | | console.log(err) |
| | | } |
| | | }) |
| | | }, |
| | | uploadImg() { |
| | | uni.chooseImage({ |
| | |
| | | confirmDate(e) { |
| | | this.form.startDate = e[0] |
| | | this.form.endDate = e[e.length - 1] |
| | | this.form.days = e.length; |
| | | |
| | | let time = this.form.startDate == this.form.endDate ? 1 : 0 |
| | | |
| | | this.form.days = e.length - time; |
| | | this.show = false |
| | | if (this.typeId === 2) { |
| | | this.getPrice() |
| | |
| | | }); |
| | | }, |
| | | clickType(e) { |
| | | if (!this.token) { |
| | | uni.navigateTo({ |
| | | url: '/pages/login/login' |
| | | }) |
| | | return |
| | | } |
| | | this.typeId = e |
| | | if (e === 2) { |
| | | this.form.categoryId = this.car[0].id |
| | |
| | | <style lang="scss" scoped> |
| | | .index { |
| | | width: 100%; |
| | | .slot-content { |
| | | width: 100%; |
| | | text-align: center; |
| | | font-weight: 400; |
| | | font-size: 30rpx; |
| | | color: #333333; |
| | | margin: 30rpx 0; |
| | | } |
| | | .btn1 { |
| | | width: 264rpx; |
| | | height: 88rpx; |
| | | line-height: 88rpx; |
| | | text-align: center; |
| | | font-weight: 400; |
| | | font-size: 32rpx; |
| | | color: #666666; |
| | | border-radius: 44rpx; |
| | | border: 1rpx solid #B2B2B2; |
| | | } |
| | | .btn2 { |
| | | width: 264rpx; |
| | | height: 88rpx; |
| | | line-height: 88rpx; |
| | | text-align: center; |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | color: #FFFFFF; |
| | | background: #00BC12; |
| | | border-radius: 44rpx; |
| | | } |
| | | .index-j { |
| | | width: 100%; |
| | | .index-j-head { |
| | |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | .eidt-btn { |
| | | width: 100%; |
| | | height: 88rpx; |
| | | line-height: 88rpx; |
| | | text-align: center; |
| | | background: #00BC12; |
| | | border-radius: 44rpx; |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | color: #FFFFFF; |
| | | } |
| | | // background: #00BC12; |
| | | // border-radius: 50rpx; |
| | | // text { |
| | |
| | | .radio-item { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: self-end; |
| | | align-items: flex-start; |
| | | margin-bottom: 30rpx; |
| | | border-bottom: 1rpx solid #E5E5E5; |
| | | &:last-child { |
| | |
| | | justify-content: flex-end; |
| | | margin-top: 42rpx; |
| | | margin-bottom: 34rpx; |
| | | .radio-item-list-data-btn { |
| | | width: 110rpx; |
| | | height: 64rpx; |
| | | line-height: 64rpx; |
| | | margin-left: 20rpx; |
| | | font-weight: 400; |
| | | font-size: 24rpx; |
| | | color: #666666; |
| | | text-align: center; |
| | | border: 1rpx solid #B2B2B2; |
| | | border-radius: 34rpx; |
| | | } |
| | | text { |
| | | font-weight: 400; |
| | | font-size: 30rpx; |
| | |
| | | <view class="info-box-head" > |
| | | <view class="info-box-head-image" @click="jump(isLogin?1:5)"> |
| | | <image v-if="userInfo.fullCoverImage&&userInfo.fullCoverImage !=''" :src="userInfo.fullCoverImage" mode="widthFix"></image> |
| | | <image v-else src="/static/logo.png" mode="widthFix"></image> |
| | | <image v-else src="/static/icon/img@2x.png" mode="widthFix"></image> |
| | | </view> |
| | | <view class="info-box-head-info" v-if="isLogin"> |
| | | <view class="info-box-head-info-name" @click="jump(1)">{{userInfo.nickName||'匿名'}}</view> |
| | |
| | | console.log(222,res) |
| | | if(res.code ===200){ |
| | | that.userInfo.useIdentity = param.useIdentity |
| | | that.$store.commit('setUserInfo', that.userInfo) |
| | | uni.$emit('refresh') |
| | | } |
| | | }).finally(() => { |
| | |
| | | <view class="order-head-status">{{info.statusName || ''}}</view> |
| | | <view class="order-head-info">{{getStatusInfo()}}</view> |
| | | </view> |
| | | <view class="order-quxiao" v-if="userInfo.useIdentity != 0"> |
| | | <view class="order-quxiao"> |
| | | <view class="order-quxiao-btn" @click="show = true" v-if="userInfo.id === info.acceptMemberId && info.status ===2">取消订单</view> |
| | | <view class="order-quxiao-btn" @click="show = true" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)">取消订单</view> |
| | | <view class="order-quxiao-btn1" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)" @click="jumpEdit()">修改订单</view> |
| | | </view> |
| | | <view class="order-user" v-if="userInfo.id === info.releaseMemberId && userInfo.useIdentity != 0"> |
| | | <view class="order-user" v-if="userInfo.id === info.releaseMemberId && info.acceptMemberId"> |
| | | <view class="order-user-info"> |
| | | <view class="user-info-l"> |
| | | <view class="user-info-l-image"> |
| | |
| | | </view> |
| | | <view class="user-info-l-i-bottom-item"> |
| | | <text>单数:</text> |
| | | <text>{{info.publishNum || 0}}</text> |
| | | <text>{{info.receiveNum ? info.receiveNum : 0}}</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | </view> |
| | | <view class="price-row"> |
| | | <view class="price-row-label">预估总费用(元)</view> |
| | | <view class="price-row-val" style="color: #FF0000;"> |
| | | <view class="price-row-val" :style="{color: userInfo.id !== info.acceptMemberId ? '#FF0000' : ''}"> |
| | | ¥{{((info.estimatedAccount||0)/100).toFixed(2) }} |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="price-row" v-if="userInfo.id === info.acceptMemberId"> |
| | | <view class="price-row-label">实际到账(元)</view> |
| | | <view class="price-row-val" style="color: #FF0000;"> |
| | | ¥{{((info.estimatedAccount * (1 - (info.platformRata || 0))) / 100).toFixed(2) }} |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | <view class="order-info-title"> |
| | | <text>评价</text> |
| | | </view> |
| | | <u-rate :count="count" activeColor="#FFC331" size="26" v-model="info.commentLevel"></u-rate> |
| | | <u-rate :count="count" readonly activeColor="#FFC331" size="26" v-model="info.commentLevel"></u-rate> |
| | | <view class="order-info-remark"> |
| | | {{ info.commentInfo || '-'}} |
| | | </view> |
| | |
| | | <view class="order-footer-btn-a" @click="show = true" v-if="userInfo.id === info.acceptMemberId && info.status ===2">取消订单</view> |
| | | <view class="order-footer-btn-a" @click="show = true" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)">取消订单</view> |
| | | <view class="order-footer-btn-b" @click="show2=true" v-if="userInfo.id === info.releaseMemberId && (info.status ===4 && info.commentStatus!=1)">去评价</view> |
| | | <view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId &&((info.status ===3 && info.type !==2)|| (info.status ===0 && info.type===2))" @click="show1 = true">完成并支付</view> |
| | | <view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId &&((info.status ===3 && info.type !==2)|| (info.status ===0 && info.type===2))" @click="show1 = true">{{info.type === 2 ? '继续支付' : '完成并支付'}}</view> |
| | | |
| | | <view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId && ((info.status ===3 && info.type===2))" @click="payment1">完成作业</view> |
| | | |
| | | <view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)" @click="jumpEdit()">修改订单</view> |
| | | <view class="order-footer-btn-b" @click="show5 =true" v-if="userInfo.id === info.acceptMemberId && (info.isUpdate==1 && info.status ===2)">修改确认</view> |
| | | <view class="order-footer-btn-b" @click="startJobs()" v-if="userInfo.id === info.releaseMemberId && (info.status ===2)">开始作业</view> |
| | |
| | | }) |
| | | } |
| | | }, |
| | | payment1() { |
| | | var that = this |
| | | this.$u.api.doneOrder({ |
| | | orderId: this.info.id |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | that.getOrderData() |
| | | } |
| | | }) |
| | | }, |
| | | payment() { |
| | | var that = this |
| | | // 订餐 |
| | |
| | | }, |
| | | cancelDo(){ |
| | | var that = this |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['AA97cHjvlPiNO4viMkVe4JifCf9TD5b5Eb7s6El3VS8'], |
| | | success(res) { |
| | | var param ={ orderId:that.id} |
| | | this.$u.api.cancelOrder(param).then(res =>{ |
| | | that.$u.api.cancelOrder(param).then(res =>{ |
| | | if(res.code ===200){ |
| | | that.show=false |
| | | uni.showToast({ title: '订单取消成功', icon: 'error', duration: 2000 }); |
| | |
| | | } |
| | | }) |
| | | }, |
| | | fail(err) { |
| | | console.log(err) |
| | | } |
| | | }) |
| | | |
| | | }, |
| | | previemImg(src){ |
| | | uni.previewImage({ |
| | | current: src, |
| | |
| | | <view :class="form.carType === item.id ? 'list-item-cate-item active' : 'list-item-cate-item'" v-for="(item, index) in settlementType" :key="index" @click="clickType(item.id)">{{item.name}}</view> |
| | | </view> |
| | | <view class="list-item-row"> |
| | | <view class="list-item-row-label">天数</view> |
| | | <view class="list-item-row-label" v-if="form.carType === 0">天数</view> |
| | | <view class="list-item-row-label" v-if="form.carType === 1">小时数</view> |
| | | <view class="list-item-row-label" v-if="form.carType === 2">重量</view> |
| | | <view class="list-item-row-val"> |
| | | <input v-model="form.priceNum1" disabled @blur="getPrice" type="number" placeholder="请输入" /> |
| | | <text>天</text> |
| | | <input v-model="form.priceNum1" :disabled="form.carType === 0" @blur="getPrice" type="number" placeholder="请输入" /> |
| | | <text v-if="form.carType === 0">天</text> |
| | | <text v-if="form.carType === 1">小时</text> |
| | | <text v-if="form.carType === 2">斤</text> |
| | | </view> |
| | | </view> |
| | | <view class="list-item-row"> |
| | |
| | | :show="show" |
| | | color="#00BC12" |
| | | mode="range" |
| | | :allowSameDay="true" |
| | | @close="show = false" |
| | | @confirm="confirmDate" /> |
| | | |
| | |
| | | }, |
| | | settlementType: [ |
| | | { name: '按天付费', id: 0 }, |
| | | { name: '按次付费', id: 1 }, |
| | | { name: '按小时付费', id: 1 }, |
| | | { name: '按重量付费', id: 2 } |
| | | ], |
| | | cateList: [], |
| | | viewStatus: false |
| | | viewStatus: false, |
| | | workDays: 0 |
| | | }; |
| | | }, |
| | | onLoad(option) { |
| | |
| | | confirmDate(e) { |
| | | this.form.startDate = e[0] |
| | | this.form.endDate = e[e.length - 1] |
| | | this.form.priceNum1 = e.length; |
| | | let time = this.form.startDate == this.form.endDate ? 1 : 0 |
| | | this.workDays = e.length - time; |
| | | if (this.form.carType === 0) { |
| | | this.form.priceNum1 = e.length - time; |
| | | } |
| | | this.show = false |
| | | this.getPrice() |
| | | }, |
| | |
| | | this.form.carType = id |
| | | if (id === 0) { |
| | | this.form.priceUnit = '元/人/天' |
| | | this.form.priceNum1 = this.workDays |
| | | } else if (id === 1) { |
| | | this.form.priceUnit = '元/人/小时' |
| | | this.form.priceNum1 = '' |
| | | } else { |
| | | this.form.priceUnit = '元/斤' |
| | | this.form.priceNum1 = '' |
| | | } |
| | | }, |
| | | confirmCategary(e) { |
| | |
| | | :show="show" |
| | | color="#00BC12" |
| | | mode="range" |
| | | :allowSameDay="true" |
| | | @close="show = false" |
| | | @confirm="confirmDate" /> |
| | | |
| | |
| | | :show="show" |
| | | color="#00BC12" |
| | | mode="range" |
| | | :allowSameDay="true" |
| | | @close="show = false" |
| | | @confirm="confirmDate" /> |
| | | |
| | |
| | | methods: { |
| | | // 提交订单 |
| | | submit() { |
| | | var that = this; |
| | | if (!this.form.categoryId) { |
| | | return uni.showToast({ title: '请选择采摘品种', icon: 'none' }) |
| | | } |
| | |
| | | if (!this.form.linkPhone) { |
| | | return uni.showToast({ title: '请输入联系电话', icon: 'none' }) |
| | | } |
| | | if (!this.form.id) { |
| | | this.$u.api.release({ ...this.form, price: Number(this.form.price) * 100 }) |
| | | if (!that.form.id) { |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['oVjOBLcHxIlGzOMJsdInmgI5CHGXh-UTvMzQqfFOnIg'], |
| | | success(res) { |
| | | that.$u.api.release({ ...that.form, price: Number(that.form.price) * 100 }) |
| | | .then(res => { |
| | | if (res.code == 200) { |
| | | uni.navigateTo({ |
| | |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } else { |
| | | this.$u.api.updateOrder({ ...this.form, price: Number(this.form.price) * 100 }) |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['3YSC7gouRlSjHXz4CrWOGFzPmGwEBtFj4snwdfMvKHk'], |
| | | success(res) { |
| | | that.$u.api.updateOrder({ ...that.form, price: Number(that.form.price) * 100 }) |
| | | .then(res => { |
| | | if (res.code == 200) { |
| | | uni.showToast({ |
| | |
| | | uni.navigateBack({ delta: 1 }); |
| | | // uni.$emit('refresh') |
| | | }, 1500) |
| | | |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | |
| | | fail: (res) => { |
| | | console.log("22222222222222",res) |
| | | uni.showToast({ |
| | | title:'对不起,提现失败。'+res.err_msg |
| | | title:'对不起,提现失败。', |
| | | icon: 'none' |
| | | }) |
| | | }, |
| | | }); |
| | |
| | | ); */ |
| | | }, |
| | | submit() { |
| | | var that = this; |
| | | if(!this.canTransfer){ |
| | | uni.showToast({ |
| | | title:'您的微信版本过低,请更新至最新版本使用该功能。' |
| | |
| | | this.changing1 = false |
| | | return |
| | | } |
| | | uni.requestSubscribeMessage({ |
| | | tmplIds: ['fNJy4545hcrH83bP3a1vszs7XEKWjXMsrfr2XCNsql0'], |
| | | success(res) { |
| | | this.changing1 = true |
| | | var that = this |
| | | var param ={amount:this.amount,name:this.name } |
| | | var param ={amount:that.amount,name:that.name } |
| | | that.$u.api.applyWithdrawal(param) |
| | | .then(res =>{ |
| | | if(res.code ===200){ |
| | |
| | | that.tips='' |
| | | that.amount =null |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | } |
| | |
| | | }, |
| | | // 设置经纬度 |
| | | setPosition(state, obj) { |
| | | console.log(obj) |
| | | state.latitude = obj.latitude |
| | | state.longitude = obj.longitude |
| | | state.address = obj.address |
| | | console.log("=====================",obj) |
| | | console.log("地址设置完成") |
| | | }, |
| | | // 清除缓存数据 |
| | | empty(state) { |