From 982bc23d3f293d789f335e832c56764d6ab7765f Mon Sep 17 00:00:00 2001 From: YeMingfei666 <1619116647@qq.com> Date: Tue, 15 Oct 2024 16:07:28 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=88=A0=E9=99=A4=E5=B8=A6?= =?UTF-8?q?=E6=9D=A5=E7=9A=84=E5=88=97=E8=A1=A8=E9=A1=B5=E9=9D=A2=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E4=B8=BA=E7=A9=BA=E6=9C=AA=E8=87=AA=E5=8A=A8=E5=87=8F?= =?UTF-8?q?=E5=B0=91=E9=A1=B5=E7=A0=81=E8=AF=B7=E6=B1=82=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/my-components/my-pagination.vue | 4 +++- manifest.json | 2 +- pageCategory/index/index.vue | 9 ++++++--- pageGoodsGroup/index/index.vue | 7 +++++-- pageProduct/add-Product/add-Product.vue | 5 +++-- pageProduct/index/index.vue | 10 +++++++++- pageUser/index/components/user.vue | 4 ++-- pages/index/index.vue | 6 +++++- pages/shopSetUp/index.vue | 9 +++++---- pagesOrder/index/compoents/filter.vue | 17 ++++++++++++----- pagesOrder/index/index.vue | 5 ++++- .../uni-forms/components/uni-forms/validate.js | 1 + 12 files changed, 56 insertions(+), 23 deletions(-) diff --git a/components/my-components/my-pagination.vue b/components/my-components/my-pagination.vue index 6faeae4..0dbf76c 100644 --- a/components/my-components/my-pagination.vue +++ b/components/my-components/my-pagination.vue @@ -90,7 +90,9 @@ } setCurrentPage(newPage) } - + watch(()=>props.page,(newval)=>{ + currentPage.value =newval + }) watch(() => currentPage.value, (newval) => { emits('change', newval) emits('update:page', newval) diff --git a/manifest.json b/manifest.json index f645895..a2393a0 100644 --- a/manifest.json +++ b/manifest.json @@ -130,7 +130,7 @@ "quickapp" : {}, /* 快应用特有相关 */ "mp-weixin" : { - "appid" : "wxcf0fe8cdba153fd6", + "appid" : "wxcbff1cfb27c1066c", "setting" : { "urlCheck" : false, "minified" : true, diff --git a/pageCategory/index/index.vue b/pageCategory/index/index.vue index 9f5d284..a04b091 100644 --- a/pageCategory/index/index.vue +++ b/pageCategory/index/index.vue @@ -12,8 +12,8 @@ :showChecked="showChecked" :showDetail="pageData.showGoodsDetail"> - - + + @@ -136,7 +136,7 @@ }, showGoodsDetail:false, query:{ - page: 1, + page: 0, size:10 }, totalElements:0, @@ -302,6 +302,9 @@ const islast=pageData.list.length===1 $productCategory.del([pageData.list[index].id]).then(res=>{ infoBox.showToast('删除成功') + if(islast&&pageData.query.page>=1){ + pageData.query.page-=1 + } // if(islast&&pageData.query.page>=1){ // pageData.query.page-- // } diff --git a/pageGoodsGroup/index/index.vue b/pageGoodsGroup/index/index.vue index 9761a09..f153379 100644 --- a/pageGoodsGroup/index/index.vue +++ b/pageGoodsGroup/index/index.vue @@ -9,8 +9,8 @@ @isShowChange="isSHowChange" :index="index" :data="item" :showChecked="showChecked" :showDetail="pageData.showGoodsDetail"> - - + @@ -327,6 +327,9 @@ const islast = pageData.list.length === 1 $productCategory.del([pageData.list[index].id]).then(res => { infoBox.showToast('删除成功') + if(islast&&pageData.query.page>=1){ + pageData.query.page-=1 + } // if(islast&&pageData.query.page>=1){ // pageData.query.page-- // } diff --git a/pageProduct/add-Product/add-Product.vue b/pageProduct/add-Product/add-Product.vue index c2bd2a6..dcac0f8 100644 --- a/pageProduct/add-Product/add-Product.vue +++ b/pageProduct/add-Product/add-Product.vue @@ -257,7 +257,7 @@ + placeholder="请输入分销金额" /> { + uni.$emit('del:productIndex',option.productId) go.back() - }, 1000) + }, 500) }) } diff --git a/pageProduct/index/index.vue b/pageProduct/index/index.vue index 28b97cf..a86e70d 100644 --- a/pageProduct/index/index.vue +++ b/pageProduct/index/index.vue @@ -52,7 +52,7 @@ @@ -401,9 +401,17 @@ function watchEmitInit() { uni.$off('update:productIndex') + uni.$off('del:productIndex') uni.$on('update:productIndex', (data) => { getGoodsList() }) + uni.$on('del:productIndex', (productId) => { + if(pageData.goodsList.length<=1){ + pageData.query.page-=1 + } + getGoodsList() + }) + } onShow(() => { // getGoodsList() diff --git a/pageUser/index/components/user.vue b/pageUser/index/components/user.vue index 4ee400e..9996581 100644 --- a/pageUser/index/components/user.vue +++ b/pageUser/index/components/user.vue @@ -41,7 +41,7 @@ - + diff --git a/pages/index/index.vue b/pages/index/index.vue index 35da704..33460f5 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -221,7 +221,11 @@ { title: '退出登录', icon: '/static/indexImg/PAGE_SALES_SUMMARY.svg', - pageUrl: 'PAGES_LOGIN' + pageUrl: 'PAGES_LOGIN', + clickFunc:()=>{ + storageManage.cleanByLogout() + go.to('PAGES_LOGIN',{},'redirect') + } } ]; diff --git a/pages/shopSetUp/index.vue b/pages/shopSetUp/index.vue index b1567ca..96e3e07 100644 --- a/pages/shopSetUp/index.vue +++ b/pages/shopSetUp/index.vue @@ -356,10 +356,11 @@ let showMap = () => { switchChange('address') }, fail: function(err) { - uni.showToast({ - title:err, - icon:'error' - }) + console.log(err); + // uni.showToast({ + // title:err, + // icon:'error' + // }) } }) diff --git a/pagesOrder/index/compoents/filter.vue b/pagesOrder/index/compoents/filter.vue index 3c01913..6d43b66 100644 --- a/pagesOrder/index/compoents/filter.vue +++ b/pagesOrder/index/compoents/filter.vue @@ -56,14 +56,14 @@ {{statusItem.label}} 取消 - 确定 + 确定 @@ -80,7 +80,7 @@ watch } from 'vue'; - const emits = defineEmits(['update:time', 'update:status','clearUser']) + const emits = defineEmits(['update:time', 'update:status','clearUser','updateStatus']) function userShowClose() { userShow.value = false @@ -187,7 +187,7 @@ function changeStatusSel(i) { statusData.sel = i - emits('update:status', i) + emits('updateStatus', i) } function datePickerConfirm(e) { @@ -195,8 +195,15 @@ emits('update:time', [e.start, e.end]) } - function changeAllListSel(i) { + function changeAllListSel(i,item) { statusData.allListSel = i + console.log(i); + } + function statusConfirm(){ + const status=statusData.allList[statusData.allListSel].key + statusData.sel=status + emits('updateStatus',status) + moreShowHide() } diff --git a/pagesOrder/index/index.vue b/pagesOrder/index/index.vue index 240164e..100d799 100644 --- a/pagesOrder/index/index.vue +++ b/pagesOrder/index/index.vue @@ -4,7 +4,7 @@ - +