diff --git a/rc-busness/ajax/getData.js b/rc-busness/ajax/getData.js index d57d9a1e..816fb394 100644 --- a/rc-busness/ajax/getData.js +++ b/rc-busness/ajax/getData.js @@ -81,11 +81,12 @@ export const isexistCart = (id, pet, address) => { /** * 删除购物车 */ -export const deleteCart = (productCode) => { +export const deleteCart = ( productCode) => { + debugger; var data = { - productCode: productCode + productCode } - return fetch('cancelCartProductInfo', data, 'POST') + return fetch('cancelCartProductInfo',productCode,'POST') } /** * 购物车批量提交 @@ -188,16 +189,14 @@ export const userquery = (stype,) => { return fetch('goods?petType=' + stype, data, 'POST') } //处方信息 -export const userque = (stype, curPage, curRow) => { - if (!curPage) - curPage = 1; - if (!curRow) - curRow = 10; - let queryTail = 'page=' + curPage + '&rows=' + curRow; - if (stype) - queryTail = '?stype=' + queryTail + '&' + queryTail; - else - queryTail = '?' + queryTail; +export const userque = (goodsName, curPage,curRow) => { + if(!curPage) + curPage=1; + if(!curRow) + curRow=10; + let queryTail='page='+curPage+'&rows='+curRow; + if(goodsName) + queryTail = '?goodsName='+goodsName; var data = { } return fetch('goods' + queryTail, data, 'POST') diff --git a/rc-busness/assets/css/openaddress.less b/rc-busness/assets/css/openaddress.less index 1be67eec..ee841367 100644 --- a/rc-busness/assets/css/openaddress.less +++ b/rc-busness/assets/css/openaddress.less @@ -22,8 +22,9 @@ .rc-button{ display: flex; align-items: center; - justify-content: center; - width: 375px; + justify-content: flex-end; + width: 100%; + height: 80px; background: #FFFFFF; box-shadow: 0px -3px 6px rgba(0, 0, 0, 0.1); @@ -38,6 +39,7 @@ opacity: 1; border-radius: 30px; background: #E2001A; display: flex; +margin-right: 20px; justify-content: center; align-items: center; font-size: 16px; diff --git a/rc-busness/components/tabs.vue b/rc-busness/components/tabs.vue index 92be0d68..a2c6336f 100644 --- a/rc-busness/components/tabs.vue +++ b/rc-busness/components/tabs.vue @@ -1,12 +1,11 @@ @@ -14,93 +13,25 @@ import { mapState, mapMutations } from "vuex"; export default { + props:["crumbs"], + name:"crumbs", data() { - return { - title: "", - path: "", - titleLists: [ - { - path: '/', - name: 'index', - meta:{ - title: '首页', - - } - } - - ], - showTab: true, - isShow: true, - }; - }, - - - watch: { - $route() { - this.setTitle(); - }, - }, - mounted() { - this.setTitle(); - }, - - methods: { - ...mapMutations(["changemessage",'selectMenu']), - setTitle() { - console.log(this.$route.matched); - console.log(this.titleLists); - let userinfo=[] - - - let saveUserInfo={ - path:'admin', - name:'1', - meta:'b341181c-aced-11e9-89bf-00163e0e8daf', - - } - userinfo.push(this.$route.matched); - let list=[]; - console.log(userinfo); - userinfo.map(item=>{ - console.log(item); - list=item; - }) - console.log(list); - let anlist={ - path:'admin', - name:'1', - meta:'b341181c-aced-11e9-89bf-00163e0e8daf', - } - list.forEach(element=>{ - console.log(element); - anlist=element - }) - for(let i in list){ - saveUserInfo.path=list[i].path; - saveUserInfo.name=list[i].name; - saveUserInfo.meta=list[i].meta; - } - console.log(saveUserInfo); - // store.commit('se', current.name); - this.selectMenu({ data: saveUserInfo }); - console.log(this.$store.state.tabsList); - this.titleLists=this.$store.state.tabsList; - // console.log(userlisa); - console.log(this.titleLists); - }, - }, - // created(){ - // let user=this.$store.state.tabsList; - // this.tags=user; - // console.log(this.tags); - // console.log(user); - // console.log(this.$store.state.tabsList) - // }, - - // mounted(){ - - // } + return { + homepageName:'首页' + }; + }, + created(){ + if(this.showTab != false) + this.showTab=true; + }, + watch: { + }, + mounted() { + }, + methods: { + ...mapMutations(["changemessage",'selectMenu']) + } }; diff --git a/rc-busness/pages/index.vue b/rc-busness/pages/index.vue index 40b9c591..be5fa08a 100644 --- a/rc-busness/pages/index.vue +++ b/rc-busness/pages/index.vue @@ -1164,7 +1164,7 @@ } window.addEventListener("scroll", this.handleScroll, true); this.userchufang();//查询处方粮商品信息 - + this.catmessage();//查询猫的信息 this.catclickGan(); this.catclickShi(); @@ -1468,9 +1468,9 @@ this.dataLoaded=false; let data=[]; if(stype==undefined||stype==null){ - data = await biaomessage(0,'',1,6); + data = await biaomessage(0,'',1,12); }else{ - data = await biaomessage(this.userserachlist,'',1,6); + data = await biaomessage(this.userserachlist,'',1,12); } if(data){ let userlist=[]; @@ -1546,12 +1546,14 @@ }, //请求处方量信息数据 - async userchufang() { + async userchufang(item) { + if(!item) + item = this.discounchufang[0].title; this.dataLoaded=false; let list=[]; - let data = await userque(); + let data = await userque(item,1,8); if(data){ - list=data.slice(0,6); + list=data.slice(0,8); this.processinformation=list; this.chufanlist=data; this.dataLoaded=true; @@ -1560,15 +1562,17 @@ //点击请求处方量标签信息数据 async userquery(item) { this.dataLoaded=false; + let list=[]; let data = await userquery(item); if(data){ - this.processinformation=data; + list=data.slice(0,8); + this.processinformation=list; this.dataLoaded=true; } }, //处方用粮筛选 userclick(item,index){ - this.userquery(index) + this.userchufang(index) }, //全价猫干粮筛选 catclickGan(){ diff --git a/rc-busness/pages/myorder/usertion.vue b/rc-busness/pages/myorder/usertion.vue index 078eebc3..fe588980 100644 --- a/rc-busness/pages/myorder/usertion.vue +++ b/rc-busness/pages/myorder/usertion.vue @@ -146,6 +146,7 @@