待报价
This commit is contained in:
parent
13caeb8cd1
commit
e65c24c01a
@ -75,3 +75,13 @@ export const UserWithdrawListsdate_listsApi = (data) => {
|
||||
export const UserBlancelistsApi = (data) => {
|
||||
return request.get('financial/FinancialRecord/supplier_list', data);
|
||||
}
|
||||
|
||||
// 发货
|
||||
export const OpurchaseclassExpressApi = (data) => {
|
||||
return request.post('operation/Opurchaseclass/express', data);
|
||||
}
|
||||
|
||||
// 物流公司列表
|
||||
export const ExpressListApi = (data) => {
|
||||
return request.get('index/express_list', data);
|
||||
}
|
@ -30,7 +30,7 @@ switch (env) {
|
||||
httpApi = 'https://test.shop.lihaink.cn' //预发布环境
|
||||
httpSix = 'https://ceshi-new-wokr.lihaink.cn'
|
||||
// httpTwo = 'https://erp.lihaink.cn'
|
||||
httpTwo = 'http://192.168.1.13:8546'
|
||||
httpTwo = 'http://192.168.1.22:8546'
|
||||
wsApi = 'wss://test.shop.lihaink.cn'
|
||||
break;
|
||||
default:
|
||||
|
@ -2,8 +2,8 @@
|
||||
"name" : "惠农生活",
|
||||
"appid" : "__UNI__3A527D1",
|
||||
"description" : "",
|
||||
"versionName": "2.0.57",
|
||||
"versionCode": 2057,
|
||||
"versionName" : "2.0.58",
|
||||
"versionCode" : 2058,
|
||||
"transformPx" : false,
|
||||
/* 5+App特有相关 */
|
||||
"app-plus" : {
|
||||
|
@ -40,21 +40,22 @@
|
||||
<view style="width: 10rpx;">
|
||||
|
||||
</view>
|
||||
<u--input style="background-color: #F6F6F6;border: none;" placeholder="输入产品报价"
|
||||
@blur="priceBlur(index)" :readonly="tabIndex==2" v-model="item.price"></u--input>
|
||||
<u--input style="background-color: #F6F6F6;border: none;" placeholder="输入产品报价" @blur="priceBlur(index)"
|
||||
:readonly="tabIndex==2" v-model="item.price"></u--input>
|
||||
</view>
|
||||
</view>
|
||||
<view class="status-png" v-if="tabIndex==2">
|
||||
<image v-if="item.is_adopt==0" src="/static/images/dbj.png"
|
||||
style="width: 108rpx; height: 84rpx;">
|
||||
<image v-if="item.is_adopt==0" src="https://lihai001.oss-cn-chengdu.aliyuncs.com/def/491f6202405281828272606.png" style="width: 108rpx; height: 84rpx;">
|
||||
</image>
|
||||
<image v-else-if="item.is_adopt==1" src="/static/images/ybj.png"
|
||||
style="width: 108rpx; height: 84rpx;">
|
||||
<image v-else-if="item.is_adopt==1" src="https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/274ad202405111523222891.png" style="width: 108rpx; height: 84rpx;">
|
||||
</image>
|
||||
<image v-else-if="item.is_adopt==2" src="/static/images/ycn.png" style=" width: 108rpx;
|
||||
<image v-else-if="item.is_adopt==2 && item.delivery_name" src="https://lihai001.oss-cn-chengdu.aliyuncs.com/def/fde75202405281450531427.png" style=" width: 108rpx;
|
||||
height: 84rpx;">
|
||||
</image>
|
||||
<image v-else src="/static/images/wcn.png" style="width: 108rpx; height: 84rpx;">
|
||||
<image v-else-if="item.is_adopt==2 && !item.delivery_name" src="https://lihai001.oss-cn-chengdu.aliyuncs.com/def/dbe43202405281449446456.png" style=" width: 108rpx;
|
||||
height: 84rpx;">
|
||||
</image>
|
||||
<image v-else src="https://lihai001.oss-cn-chengdu.aliyuncs.com/def/22059202405281826183468.png" style="width: 108rpx; height: 84rpx;">
|
||||
</image>
|
||||
</view>
|
||||
</view>
|
||||
@ -71,13 +72,58 @@
|
||||
<view class="submit-btn" v-if="tabIndex==1">
|
||||
<u-button shape='circle' color='#20B128' @click="submit" text="提交"></u-button>
|
||||
</view>
|
||||
<view class="submit-btn" v-if="tabIndex==2">
|
||||
<u-button shape='circle' color='#20B128' @click="showDeliver" text="立即发货"></u-button>
|
||||
</view>
|
||||
<uni-popup ref="deliver" type="center" @click.stop="">
|
||||
<view class="deliver">
|
||||
<view style="font-size: 32rpx;font-weight: bold;text-align: center;">发货</view>
|
||||
<u--form labelPosition="left" style="width: 100%;" labelWidth="auto" :model="model1" :rules="rules"
|
||||
ref="uForm">
|
||||
<u-form-item label="配送方式" borderBottom>
|
||||
<u-radio-group v-model="model_type" placement="row" @change="model1.delivery_name='';model1.delivery_id=''">
|
||||
<u-radio label="自己配送" :name="2" style="margin-right: 20rpx;"></u-radio>
|
||||
<u-radio label="快递配送" :name="1"></u-radio>
|
||||
</u-radio-group>
|
||||
</u-form-item>
|
||||
<block v-if="model_type==1">
|
||||
<u-form-item label="快递公司" prop="delivery_name" @tap="deliveryNameShow=true" borderBottom>
|
||||
<u--input v-model="model1.delivery_name" readonly border="none" placeholder="请选择快递公司" suffixIcon="arrow-right"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="物流单号" prop="delivery_id" borderBottom>
|
||||
<u--input v-model="model1.delivery_id" border="none" placeholder="请输入物流单号"></u--input>
|
||||
</u-form-item>
|
||||
</block>
|
||||
<block v-if="model_type==2">
|
||||
<u-form-item label="送货人姓名" prop="delivery_name" borderBottom>
|
||||
<u--input v-model="model1.delivery_name" border="none" placeholder="请输入送货人姓名"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="送货人电话" prop="delivery_id" borderBottom>
|
||||
<u--input v-model="model1.delivery_id" border="none" placeholder="请输入送货人电话"></u--input>
|
||||
</u-form-item>
|
||||
</block>
|
||||
</u--form>
|
||||
<u-button shape='circle' style="margin-top: 80rpx;" color='#20B128' @click="onExpress" text="确认发货"></u-button>
|
||||
<u-picker
|
||||
:show="deliveryNameShow"
|
||||
:columns="[columns]"
|
||||
title="请选择快递公司"
|
||||
@cancel="deliveryNameShow = false"
|
||||
@confirm="changeName"
|
||||
>
|
||||
</u-picker>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
import { Toast } from "../../libs/uniApi";
|
||||
import {
|
||||
OpurchaseGoodsOfferApi,
|
||||
OpurchaseGoodsOfferListApi
|
||||
OpurchaseGoodsOfferListApi,
|
||||
OpurchaseclassExpressApi,
|
||||
ExpressListApi
|
||||
} from "@/api/supplier.js"
|
||||
|
||||
export default {
|
||||
@ -92,6 +138,27 @@
|
||||
ycn: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/739c3202405071458553459.png',
|
||||
wcj: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/04c2c202405071501462462.png',
|
||||
ybj: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/274ad202405111523222891.png',
|
||||
model_type: 2,
|
||||
deliveryNameShow: false,
|
||||
model1: {
|
||||
delivery_name: "",
|
||||
delivery_id: "",
|
||||
},
|
||||
rules: {
|
||||
delivery_name: {
|
||||
type: 'string',
|
||||
required: true,
|
||||
message: '不可为空',
|
||||
trigger: ['change', 'blur']
|
||||
},
|
||||
delivery_id: {
|
||||
type: 'string',
|
||||
required: true,
|
||||
message: '不可为空',
|
||||
trigger: ['change', 'blur']
|
||||
}
|
||||
},
|
||||
columns: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@ -147,13 +214,41 @@
|
||||
price: item.price
|
||||
}
|
||||
})
|
||||
if (!data.length) return
|
||||
console.log(data)
|
||||
if (!data.length) return ;
|
||||
let res = await OpurchaseGoodsOfferApi({
|
||||
data: data
|
||||
})
|
||||
this.getLists(1)
|
||||
}
|
||||
},
|
||||
showDeliver() {
|
||||
this.getAction();
|
||||
this.$refs.deliver.open()
|
||||
},
|
||||
// 发货
|
||||
onExpress() {
|
||||
this.$refs.uForm.validate().then(res=>{
|
||||
OpurchaseclassExpressApi({
|
||||
...this.model1,
|
||||
date: this.date
|
||||
}).then(res => {
|
||||
this.getLists(2);
|
||||
this.$refs.deliver.close();
|
||||
Toast('发货成功')
|
||||
})
|
||||
})
|
||||
},
|
||||
// 物流公司列表
|
||||
getAction(){
|
||||
ExpressListApi({
|
||||
page_size: 100
|
||||
}).then(res=>{
|
||||
this.columns = res.data.lists.map(item=>item.name);
|
||||
})
|
||||
},
|
||||
changeName(e){
|
||||
this.model1.delivery_name = e.value[0];
|
||||
this.deliveryNameShow = false;
|
||||
},
|
||||
},
|
||||
onLoad(option) {
|
||||
this.date = option.date
|
||||
@ -274,4 +369,16 @@
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.deliver {
|
||||
width: 600rpx;
|
||||
height: 500rpx;
|
||||
background-color: #fff;
|
||||
border-radius: 14rpx;
|
||||
padding: 20rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
</style>
|
Binary file not shown.
Before Width: | Height: | Size: 3.6 KiB |
Binary file not shown.
Before Width: | Height: | Size: 3.3 KiB |
Binary file not shown.
Before Width: | Height: | Size: 3.3 KiB |
Binary file not shown.
Before Width: | Height: | Size: 3.8 KiB |
Loading…
x
Reference in New Issue
Block a user