|
|
@ -86,7 +86,7 @@ |
|
|
|
<view class="address" style="width: 70%"> |
|
|
|
<image mode="" src="/static/image/address/selectIcon.png"></image> |
|
|
|
<view class=""> |
|
|
|
{{ address.name + '' + address.phone }} |
|
|
|
{{ address.name + address.phone + address.address + address.addressDetail }} |
|
|
|
</view> |
|
|
|
<view class="icon"> |
|
|
|
<uv-icon name="arrow-right" size="30rpx"></uv-icon> |
|
|
@ -168,6 +168,7 @@ |
|
|
|
:previewFullImage="true"></uv-upload> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
|
|
|
|
<view class="item"> |
|
|
|
<view>检测视频</view> |
|
|
|
<view class=""> |
|
|
@ -238,7 +239,45 @@ |
|
|
|
topbar |
|
|
|
}, |
|
|
|
onLoad(options) { |
|
|
|
this.titleIndex = options.titleIndex; |
|
|
|
this.titleIndex = options.titleIndex || 0;//默认供应商报价 |
|
|
|
this.type = options.type |
|
|
|
|
|
|
|
if(options.type = 'edit'){ |
|
|
|
|
|
|
|
|
|
|
|
this.form = this.$store.state.orderDetail |
|
|
|
|
|
|
|
// 商品主图 |
|
|
|
this.fileList = this.form.pic ? this.form.pic.split(',').map(url => { |
|
|
|
return { |
|
|
|
url |
|
|
|
} |
|
|
|
}) : [] |
|
|
|
// 检测报告 |
|
|
|
this.reportFileList = this.form.report ? this.form.report.split(',').map(url => { |
|
|
|
return { |
|
|
|
url |
|
|
|
} |
|
|
|
}) : [] |
|
|
|
// 检测视频 |
|
|
|
this.reportFileVideoList = this.form.reportVideo ? this.form.reportVideo.split(',').map(url => { |
|
|
|
return { |
|
|
|
url |
|
|
|
} |
|
|
|
}) : [] |
|
|
|
// 商品内容-详情图片 |
|
|
|
this.contentFileList = this.form.picDetail ? this.form.picDetail.split(',').map(url => { |
|
|
|
return { |
|
|
|
url |
|
|
|
} |
|
|
|
}) : [] |
|
|
|
// 商品内容-详情视频 |
|
|
|
this.contentFileVideoList = this.form.video ? this.form.video.split(',').map(url => { |
|
|
|
return { |
|
|
|
url |
|
|
|
} |
|
|
|
}) : [] |
|
|
|
} |
|
|
|
}, |
|
|
|
data() { |
|
|
|
return { |
|
|
@ -268,14 +307,13 @@ |
|
|
|
unit : {//选中的规格 |
|
|
|
specsName : '请选择规格' |
|
|
|
}, |
|
|
|
type : '', |
|
|
|
} |
|
|
|
}, |
|
|
|
onShow() { |
|
|
|
this.getUnitList() |
|
|
|
this.getAddressDefault() |
|
|
|
}, |
|
|
|
onLoad() { |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
//获取默认地址 |
|
|
|
getAddressDefault() { |
|
|
@ -299,6 +337,14 @@ |
|
|
|
}, res => { |
|
|
|
if(res.code == 200){ |
|
|
|
this.unitList = [res.result.records] |
|
|
|
|
|
|
|
if(this.type == 'edit'){ |
|
|
|
res.result.records.forEach(n => { |
|
|
|
if(n.id == this.form.specsId){ |
|
|
|
this.unit = n |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
@ -350,8 +396,14 @@ |
|
|
|
})) { |
|
|
|
return |
|
|
|
} |
|
|
|
|
|
|
|
let api = 'addProduct' |
|
|
|
|
|
|
|
if(this.type == 'edit'){ |
|
|
|
api = 'updateProduct' |
|
|
|
} |
|
|
|
|
|
|
|
this.$api('addProduct', this.form, res => { |
|
|
|
this.$api(api, this.form, res => { |
|
|
|
if (res.code == 200) { |
|
|
|
uni.showToast({ |
|
|
|
title: '提交成功', |
|
|
@ -470,7 +522,7 @@ |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
background-color: #FFF; |
|
|
|
height: 80rpx; |
|
|
|
// height: 80rpx; |
|
|
|
|
|
|
|
.title { |
|
|
|
display: flex; |
|
|
@ -490,14 +542,15 @@ |
|
|
|
width: 30rpx; |
|
|
|
height: 30rpx; |
|
|
|
margin: 10rpx; |
|
|
|
flex-shrink: 0; |
|
|
|
} |
|
|
|
|
|
|
|
view { |
|
|
|
|
|
|
|
//margin: 20rpx; |
|
|
|
overflow: hidden; //超出的文本隐藏 |
|
|
|
text-overflow: ellipsis; //溢出用省略号显示 |
|
|
|
white-space: nowrap; //溢出不换行 |
|
|
|
// overflow: hidden; //超出的文本隐藏 |
|
|
|
// text-overflow: ellipsis; //溢出用省略号显示 |
|
|
|
// white-space: nowrap; //溢出不换行 |
|
|
|
} |
|
|
|
|
|
|
|
.icon { |
|
|
|