Commit 18f2ad79 authored by xiaoyan's avatar xiaoyan

feature: 入仓取消空白关闭&弹窗点取消二次确认

parent 517e74c8
...@@ -146,7 +146,7 @@ ...@@ -146,7 +146,7 @@
<button style="color: #007aff" @tap="next">{{$t('下一步')}}</button> <button style="color: #007aff" @tap="next">{{$t('下一步')}}</button>
</view> </view>
<view class="add-popup"> <view class="add-popup">
<uni-popup ref="popup" background-color="#fff" @maskClick="maskClick"> <uni-popup ref="popup" background-color="#fff" :maskClick="false">
<view class="popup-content"> <view class="popup-content">
<view class="popup-title">{{title}}</view> <view class="popup-title">{{title}}</view>
<view class="add-form"> <view class="add-form">
...@@ -293,7 +293,7 @@ ...@@ -293,7 +293,7 @@
<!-- 添加新商品--> <!-- 添加新商品-->
<view class="add-popup"> <view class="add-popup">
<uni-popup ref="product" background-color="#fff" @maskClick="maskClickAddProduct"> <uni-popup ref="product" background-color="#fff" :maskClick="false">
<view class="popup-content"> <view class="popup-content">
<view class="popup-title">{{$t('添加新商品')}}</view> <view class="popup-title">{{$t('添加新商品')}}</view>
...@@ -908,25 +908,45 @@ export default { ...@@ -908,25 +908,45 @@ export default {
}) })
}, },
maskClick() { maskClick() {
this.$refs.popup.close() const _this = this
this.addForm = { uni.showModal({
unit: '1', title: '提示',
orderWarehouseInItemDoList: [{cartonsNum:undefined}], content: '确认取消吗?',
pictureUrls: [], success: function (res) {
usageIds: [], if (res.confirm) {
} console.log('用户点击确定');
_this.$refs.popup.close()
_this.addForm = {
unit: '1',
orderWarehouseInItemDoList: [{cartonsNum:undefined}],
pictureUrls: [],
usageIds: [],
}
}
}
});
}, },
addProduct() { addProduct() {
this.$refs.product.open('center') this.$refs.product.open('center')
}, },
maskClickAddProduct() { maskClickAddProduct() {
this.$refs.product.close() const _this = this
this.productForm = { uni.showModal({
typeId: undefined, title: '提示',
attrArray: [], content: '确认取消吗?',
titleZh: undefined, success: function (res) {
titleEn: undefined if (res.confirm) {
} console.log('用户点击确定');
_this.$refs.product.close()
_this.productForm = {
typeId: undefined,
attrArray: [],
titleZh: undefined,
titleEn: undefined
}
}
}
});
}, },
saveProductForm() { saveProductForm() {
if(!this.productForm.typeId){ if(!this.productForm.typeId){
......
...@@ -145,7 +145,7 @@ ...@@ -145,7 +145,7 @@
<button style="color: #007aff" @tap="next">{{$t('下一步')}}</button> <button style="color: #007aff" @tap="next">{{$t('下一步')}}</button>
</view> </view>
<view class="add-popup"> <view class="add-popup">
<uni-popup ref="popup" background-color="#fff" @maskClick="maskClick"> <uni-popup ref="popup" background-color="#fff" :maskClick="false">
<view class="popup-content"> <view class="popup-content">
<view class="popup-title">{{title}}</view> <view class="popup-title">{{title}}</view>
<view class="add-form"> <view class="add-form">
...@@ -292,7 +292,7 @@ ...@@ -292,7 +292,7 @@
<!-- 添加新商品--> <!-- 添加新商品-->
<view class="add-popup"> <view class="add-popup">
<uni-popup ref="product" background-color="#fff" @maskClick="maskClickAddProduct"> <uni-popup ref="product" background-color="#fff" :maskClick="false">
<view class="popup-content"> <view class="popup-content">
<view class="popup-title">{{$t('添加新商品')}}</view> <view class="popup-title">{{$t('添加新商品')}}</view>
...@@ -906,25 +906,44 @@ export default { ...@@ -906,25 +906,44 @@ export default {
}) })
}, },
maskClick() { maskClick() {
this.$refs.popup.close() const _this = this
this.addForm = { uni.showModal({
unit: '1', title: '提示',
orderWarehouseInItemDoList: [{cartonsNum:undefined}], content: '确认取消吗?',
pictureUrls: [], success: function (res) {
usageIds: [], if (res.confirm) {
} console.log('用户点击确定');
_this.$refs.popup.close()
_this.addForm = {
unit: '1',
orderWarehouseInItemDoList: [{cartonsNum:undefined}],
pictureUrls: [],
usageIds: [],
}
}
}
});
}, },
addProduct() { addProduct() {
this.$refs.product.open('center') this.$refs.product.open('center')
}, },
maskClickAddProduct() { maskClickAddProduct() {
this.$refs.product.close() const _this = this
this.productForm = { uni.showModal({
typeId: undefined, title: '提示',
attrArray: [], content: '确认取消吗?',
titleZh: undefined, success: function (res) {
titleEn: undefined if (res.confirm) {
} _this.$refs.product.close()
_this.productForm = {
typeId: undefined,
attrArray: [],
titleZh: undefined,
titleEn: undefined
}
}
}
});
}, },
saveProductForm() { saveProductForm() {
if(!this.productForm.typeId){ if(!this.productForm.typeId){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment