Browse Source

延长 showToast 时间为 2秒

master
zhengshuiqi 3 years ago
parent
commit
0825dc152a
  1. 0
      common/base.js
  2. 8
      common/common.scss
  3. 13
      pages.json
  4. 30
      pages/account/addAddress.vue
  5. 3
      pages/account/address.vue
  6. 3
      pages/account/changeImg.vue
  7. 3
      pages/account/deleteCount.vue
  8. 9
      pages/account/favorites.vue
  9. 3
      pages/account/message.vue
  10. 3
      pages/account/myOrders.vue
  11. 15
      pages/account/wishlist.vue
  12. 16
      pages/category/productList.vue
  13. 6
      pages/index/flashSale.vue
  14. 8
      pages/index/index.vue
  15. 3
      pages/index/pickUpCentre.vue
  16. 4
      pages/index/search.vue
  17. 6
      pages/login/changePwd.vue
  18. 9
      pages/login/index.vue
  19. 6
      pages/login/verifyEmail.vue
  20. 21
      pages/order/confirmation.vue
  21. 6
      pages/order/details.vue
  22. 3
      pages/order/logisticsDetails.vue
  23. 3
      pages/order/paySuccess.vue
  24. 2086
      pages/productDetails/index.vue
  25. 6
      pages/productDetails/review.vue
  26. 27
      pages/shippingCart/index.vue
  27. 3
      uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue
  28. 6
      uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue

0
common/base.js

8
common/common.scss

@ -1169,4 +1169,12 @@
}
.uni-page-refresh {
background: #000 !important;
color: #630102 !important;
}
.uni-page-refresh__spinner {
color: #630102 !important;
}
.uni-page-refresh__path {
color: #630102 !important;
stroke: rgb(99, 1, 2);
}

13
pages.json

@ -9,12 +9,8 @@
"app-plus":{
"titleNView":false,
"bounce": "none",
"pullToRefresh": {
"style": "circle",
"backgroundColor": "#000000",
"color": "#aa0000"
}
"bounce": "none"
// "renderer": "native"
},
"navigationBarTextStyle":"white"
@ -385,10 +381,7 @@
"optimization": {
"subPackages": true
},
"pullToRefresh": {
"style": "circle",
"color": "#aa0000"
},
"runmode" : "liberate" //
}
},

30
pages/account/addAddress.vue

@ -180,28 +180,32 @@
if(this.query.consignee.consignee==''){
uni.showToast({
icon:'none',
title:'Please fill Fall name'
title:'Please fill Fall name',
duration: 2000
})
return
}
if(this.query.consignee.mobile==''){
uni.showToast({
icon:'none',
title:'Please fill Phone Number'
title:'Please fill Phone Number',
duration: 2000
})
return
}
if(this.address==''){
uni.showToast({
icon:'none',
title:'Please fill Stree adderss or P.O.Box'
title:'Please fill Stree adderss or P.O.Box',
duration: 2000
})
return
}
if(this.query.consignee.sign_building==''){
uni.showToast({
icon:'none',
title:'Please fill Appartment,suite,unit,etc.'
title:'Please fill Appartment,suite,unit,etc.',
duration: 2000
})
return
}
@ -209,7 +213,8 @@
if(this.city==''){
uni.showToast({
icon:'none',
title:'Please fill in City/Town'
title:'Please fill in City/Town',
duration: 2000
})
return
}
@ -222,7 +227,8 @@
if(this.query.consignee.city==0){
uni.showToast({
icon:'none',
title:'Please Select City/Town'
title:'Please Select City/Town',
duration: 2000
})
return
@ -232,7 +238,8 @@
if(this.province==''){
uni.showToast({
icon:'none',
title:'Please fill in State/Province'
title:'Please fill in State/Province',
duration: 2000
})
return
}
@ -242,7 +249,8 @@
if(this.query.consignee.province==0){
uni.showToast({
icon:'none',
title:'Please Select State/Province'
title:'Please Select State/Province',
duration: 2000
})
return
}
@ -250,7 +258,8 @@
if(this.query.consignee.zipcode==''){
uni.showToast({
icon:'none',
title:'Please fill Zip code/Postcode/PLZ/Eircode'
title:'Please fill Zip code/Postcode/PLZ/Eircode',
duration: 2000
})
return
}
@ -262,7 +271,8 @@
if(res.error==0){
uni.showToast({
icon:'none',
title:res.message
title:res.message,
duration: 2000
})
uni.navigateBack()
}

3
pages/account/address.vue

@ -82,7 +82,8 @@
if(res.error==0){
uni.showToast({
icon:'none',
title:res.message
title:res.message,
duration: 2000
})
this.getList()
}

3
pages/account/changeImg.vue

@ -90,7 +90,8 @@
setTimeout(() =>{
uni.showToast({
title:'ok!',
icon:'none'
icon:'none',
duration: 2000
})
},500)

3
pages/account/deleteCount.vue

@ -60,7 +60,8 @@
setTimeout(() =>{
uni.showToast({
icon:'none',
title:'ok to delete!'
title:'ok to delete!',
duration: 2000
})
},500)
uni.navigateTo({

9
pages/account/favorites.vue

@ -81,7 +81,8 @@
if(res.error==0){
uni.showToast({
title:'ok',
icon:'none'
icon:'none',
duration: 2000
})
this.getList()
}
@ -97,7 +98,8 @@
if(res.error==0){
uni.showToast({
title:res.message,
icon:'none'
icon:'none',
duration: 2000
})
this.changeImage(id,0)
}
@ -111,7 +113,8 @@
if(res.error==0){
uni.showToast({
title:res.message,
icon:'none'
icon:'none',
duration: 2000
})
this.changeImage(id,1)
}

3
pages/account/message.vue

@ -177,7 +177,8 @@
if (res.error == 0) {
uni.showToast({
title: 'Read',
icon: 'none'
icon: 'none',
duration: 2000
})
console.log(res)
this.getMes()

3
pages/account/myOrders.vue

@ -716,7 +716,8 @@
console.log('fail:' + JSON.stringify(err));
uni.showToast({
title: 'Payment failed',
icon: 'none'
icon: 'none',
duration: 2000
})
}
});

15
pages/account/wishlist.vue

@ -269,7 +269,8 @@
if(res.error==0){
uni.showToast({
title:'ok!',
icon:'none'
icon:'none',
duration: 2000
})
this.getList()
@ -306,7 +307,8 @@
if(res.error==0){
uni.showToast({
title:res.message,
icon:'none'
icon:'none',
duration: 2000
})
}
})
@ -341,7 +343,8 @@
uni.showToast({
title:'ok!',
icon:'none'
icon:'none',
duration: 2000
})
},1000)
this.getList()
@ -522,7 +525,8 @@
if(isall == 0){
uni.showToast({
title:'Please select the product specification',
icon:'none'
icon:'none',
duration: 2000
})
return
}
@ -540,7 +544,8 @@
setTimeout( ()=>{
uni.showToast({
title:'Successfully added',
icon:'none'
icon:'none',
duration: 2000
})
},500)

16
pages/category/productList.vue

@ -221,7 +221,8 @@
if (res.error == 0) {
uni.showToast({
title: res.message,
icon: 'none'
icon: 'none',
duration: 2000
})
this.changeImage(id, 0)
}
@ -244,7 +245,8 @@
if (res.error == 0) {
uni.showToast({
title: 'ok',
icon: 'none'
icon: 'none',
duration: 2000
})
this.changeImage(id, 1)
}
@ -282,7 +284,8 @@
if (isall == 0) {
uni.showToast({
title: 'Please select the product specification',
icon: 'none'
icon: 'none',
duration: 2000
})
return
}
@ -299,9 +302,10 @@
setTimeout(() => {
uni.showToast({
title: 'Successfully added',
icon: 'none'
icon: 'none',
duration: 2000
})
}, 500)
}, 2000)
this.isCart = false
} else {
@ -500,7 +504,7 @@
icon: 'none',
duration: 3000
})
}, 1000)
}, 2000)
this.query.page_index--
}
}

6
pages/index/flashSale.vue

@ -288,7 +288,8 @@
if(isall==0){
uni.showToast({
title:'Please select the product specification',
icon:'none'
icon:'none',
duration: 2000
})
return
}
@ -305,7 +306,8 @@
this.cartQuery.goods_attr_id = ''
uni.showToast({
title:'Successfully added',
icon:'none'
icon:'none',
duration: 2000
})
}
this.isCart = false

8
pages/index/index.vue

@ -817,7 +817,8 @@
if (isall == 0) {
uni.showToast({
title: 'Please select the product specification',
icon: 'none'
icon: 'none',
duration: 2000
})
return
}
@ -835,9 +836,10 @@
setTimeout(() => {
uni.showToast({
title: 'Successfully added',
icon: 'none'
icon: 'none',
duration: 2000
})
}, 500)
}, 2000)
}
//uni.showTabBar()

3
pages/index/pickUpCentre.vue

@ -51,7 +51,8 @@
if(res.error==0){
uni.showToast({
icon:'none',
title:'ok!'
title:'ok!',
duration: 2000
})
}
this.getList()

4
pages/index/search.vue

@ -143,8 +143,8 @@
//
empty() {
uni.showToast({
title: 'emptied'
title: 'emptied',
duration: 2000
});
uni.removeStorage({
key: 'searchList'

6
pages/login/changePwd.vue

@ -30,12 +30,14 @@
console.info(res)
uni.showToast({
title:res.message,
icon:'none'
icon:'none',
duration: 2000
})
if(res.error==0){
uni.showToast({
title:res.message,
icon:'none'
icon:'none',
duration: 2000
})
setTimeout(function() {
uni.navigateBack({

9
pages/login/index.vue

@ -137,6 +137,7 @@
uni.showToast({
title:'Please fill in the user email first',
icon:'none',
duration: 2000
})
return
}
@ -192,7 +193,8 @@
uni.hideLoading()
uni.showToast({
title:'Login successful',
icon:'none'
icon:'none',
duration: 2000
})
},1000)
let list ={
@ -227,6 +229,7 @@
uni.showToast({
title:res.message,
icon:'none',
duration: 2000
})
}
})
@ -238,6 +241,7 @@
uni.showToast({
title:'please agree to and tick the User Agreement first',
icon:'none',
duration: 2000
})
return
}
@ -258,7 +262,8 @@
// Successful registration, please verify your email address!
uni.showToast({
title:'logining in~',
icon:'none'
icon:'none',
duration: 2000
})
},1000)
}else{

6
pages/login/verifyEmail.vue

@ -47,7 +47,8 @@
if(!this.resetcode){
uni.showToast({
icon:'none',
title:'Please fill in the verification code'
title:'Please fill in the verification code',
duration: 2000
})
}
else{
@ -65,7 +66,8 @@
uni.showToast({
title:res.message,
icon:'none'
icon:'none',
duration: 2000
})

21
pages/order/confirmation.vue

@ -339,7 +339,8 @@
if (!this.address) {
uni.showToast({
icon: 'none',
title: 'please add address'
title: 'please add address',
duration: 2000
})
this.isShow = false
} else if (this.total.amount != 0 && this.address) {
@ -350,7 +351,8 @@
setTimeout(() => {
uni.showToast({
icon: 'none',
title: 'ok!'
title: 'ok!',
duration: 2000
})
}, 1000)
uni.navigateTo({
@ -703,7 +705,8 @@
if (!this.list) {
uni.showToast({
icon: 'none',
title: 'No coupon available'
title: 'No coupon available',
duration: 2000
})
return
} else {
@ -712,7 +715,8 @@
if (this.orderDate.allow_use_bonus == 0) {
uni.showToast({
icon: 'none',
title: 'Coupon cannot be used for this product'
title: 'Coupon cannot be used for this product',
duration: 2000
})
return
}
@ -723,7 +727,8 @@
} else {
uni.showToast({
icon: 'none',
title: 'Points cannot be used for this product'
title: 'Points cannot be used for this product',
duration: 2000
})
}
// if(this.orderDate.allow_use_integral==0){
@ -737,12 +742,14 @@
if (!this.address) {
uni.showToast({
icon: 'none',
title: 'please add address'
title: 'please add address',
duration: 2000
})
} else if (!this.orderId || this.tag == 0) {
uni.showToast({
icon: 'none',
title: 'please select shipping method'
title: 'please select shipping method',
duration: 2000
})
}
// else{

6
pages/order/details.vue

@ -399,7 +399,8 @@
console.log('fail:' + JSON.stringify(err));
uni.showToast({
title: 'Payment failed',
icon: 'none'
icon: 'none',
duration: 2000
})
}
});
@ -444,7 +445,8 @@
success: () => {
uni.showToast({
title: 'ok!',
icon: 'none'
icon: 'none',
duration: 2000
})
}

3
pages/order/logisticsDetails.vue

@ -54,7 +54,8 @@
success:()=>{//
uni.showToast({//
title:'succeeded',
icon:'none'
icon:'none',
duration: 2000
})
}
});

3
pages/order/paySuccess.vue

@ -64,7 +64,8 @@
this.isReachBottom=false
uni.showToast({
title: 'No more data yet',
icon:'none'
icon:'none',
duration: 2000
})
this.catQuery.page_index--
}

2086
pages/productDetails/index.vue

File diff suppressed because it is too large

6
pages/productDetails/review.vue

@ -200,7 +200,8 @@
if(res.error==0){
uni.showToast({
icon:'none',
title:'Comment successful!'
title:'Comment successful!',
duration: 2000
})
setTimeout(function(){
uni.navigateBack()
@ -233,7 +234,8 @@
if(res.error==0){
uni.showToast({
icon:'none',
title:'Comment successful!'
title:'Comment successful!',
duration: 2000
})
setTimeout(function(){
uni.navigateBack()

27
pages/shippingCart/index.vue

@ -424,7 +424,8 @@
this.isReachBottom = false
uni.showToast({
title: 'No more data yet',
icon: 'none'
icon: 'none',
duration: 2000
})
this.catQuery.page_index--
}
@ -471,7 +472,8 @@
if (this.all_allno == 2) {
uni.showToast({
icon: 'none',
title: 'Please select the product'
title: 'Please select the product',
duration: 2000
})
return
}
@ -497,7 +499,8 @@
if (this.all_allno == 2) {
uni.showToast({
icon: 'none',
title: 'Please select the product to delete'
title: 'Please select the product to delete',
duration: 2000
})
return
}
@ -519,7 +522,8 @@
if (selectNum > 1) {
uni.showToast({
icon: 'none',
title: 'Only one or all items can be deleted'
title: 'Only one or all items can be deleted',
duration: 2000
})
return
} else if (selectNum == 1) {
@ -554,7 +558,8 @@
setTimeout(() => {
uni.showToast({
icon: 'none',
title: 'Successfully deleted!'
title: 'Successfully deleted!',
duration: 2000
})
}, 500)
}
@ -720,7 +725,8 @@
uni.startPullDownRefresh()
uni.showToast({
icon: 'none',
title: 'ok!'
title: 'ok!',
duration: 2000
})
@ -746,7 +752,8 @@
setTimeout( () =>{
uni.showToast({
icon: 'none',
title: 'ok!'
title: 'ok!',
duration: 2000
})
},1000)
@ -1031,7 +1038,8 @@
if(isall == 0){
uni.showToast({
title:'Please select the product specification',
icon:'none'
icon:'none',
duration: 2000
})
return
}
@ -1053,7 +1061,8 @@
setTimeout( ()=>{
uni.showToast({
title:'Successfully added',
icon:'none'
icon:'none',
duration: 2000
})
},500)

3
uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue

@ -328,7 +328,8 @@
'array') {
uni.showToast({
title: `您最多选择 ${this.limitLength} 个文件`,
icon: 'none'
icon: 'none',
duration: 2000
})
return
}

6
uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue

@ -320,13 +320,15 @@ export default {
if (this.form.errShowType === 'toast') {
uni.showToast({
title: result.errorMessage || '校验错误',
icon: 'none'
icon: 'none',
duration: 2000
});
}
if (this.form.errShowType === 'modal') {
uni.showModal({
title: '提示',
content: result.errorMessage || '校验错误'
content: result.errorMessage || '校验错误',
duration: 2000
});
}
} else {

Loading…
Cancel
Save