From f9179190e432c87178809b68cf47cabaf6262375 Mon Sep 17 00:00:00 2001 From: dingtalk_umvbsp Date: Fri, 10 Feb 2023 17:21:46 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BB=93=E5=BA=93=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E9=A1=B5=E9=9D=A2=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/home/index.vue | 2 +- pages/stock/mana.vue | 1 + pages/warehouse/info.vue | 7 +++++-- pages/warehouse/mana.vue | 39 ++++++++++++++++++++++++++++++--------- uni.scss | 2 +- 5 files changed, 38 insertions(+), 13 deletions(-) diff --git a/pages/home/index.vue b/pages/home/index.vue index b9e2efe..c867c38 100644 --- a/pages/home/index.vue +++ b/pages/home/index.vue @@ -305,7 +305,7 @@ - 地块管理 更多>> + 地块管理 更多>> {{v.plotName}} {{v.realityArea}}亩 diff --git a/pages/stock/mana.vue b/pages/stock/mana.vue index 5af2748..7f68564 100644 --- a/pages/stock/mana.vue +++ b/pages/stock/mana.vue @@ -171,6 +171,7 @@ export default { }, onLoad(options){ this.searchVal.warehouseId=options.id + this.searchVal.substanceType=options.goodsType||"nz" this.search() }, methods:{ diff --git a/pages/warehouse/info.vue b/pages/warehouse/info.vue index c33c7db..6c39e87 100644 --- a/pages/warehouse/info.vue +++ b/pages/warehouse/info.vue @@ -33,8 +33,8 @@ import request from '@/common/request.js' warehouseVolume:{label:"仓库容量(㎡)", type:"digit",placeholder:"请输入仓库容量"}, goodsType:{label:"存储物品类型",type:"select",columns:[],value:[]}, warehouseType:{label:"仓库类型",type:"select",columns:[],value:[]}, - contactPeople:{label:"基地管理员"}, - contactNumber:{label:"管理员联系方式"}, + contactPeople:{label:"基地管理员", disabled:this.$store.getters['userInfo'].roleCode=="baseAdmin"}, + contactNumber:{label:"管理员联系方式", disabled:this.$store.getters['userInfo'].roleCode=="baseAdmin"}, warehousePic:{label:"仓库图片",type:"upImg",num:3}, }, formData:{ @@ -75,6 +75,9 @@ import request from '@/common/request.js' this.init() if(options.id){ this.getDetail(options.id) + }else if(this.$store.getters['userInfo'].roleCode=="baseAdmin"){ + this.formData.contactPeople=this.$store.getters['userInfo'].realname + this.formData.contactNumber=this.$store.getters['userInfo'].phone } }, methods:{ diff --git a/pages/warehouse/mana.vue b/pages/warehouse/mana.vue index e9e761f..aff7ef1 100644 --- a/pages/warehouse/mana.vue +++ b/pages/warehouse/mana.vue @@ -11,9 +11,26 @@ .item{ margin-top:0; display:flex; - .u-transition{ - flex-shrink: 0; + &>.img{ + display:flex; + flex-direction: column; + justify-content: space-between; margin-right:28rpx; + width:164rpx; + .u-transition{ + flex-shrink: 0; + } + &>text{ + color:rgba(var(--c),1); + background:rgba(var(--c),0.1); + font-size:24rpx; + padding:10rpx; + text-align: center; + margin-bottom:-10rpx; + &:before{ + margin-right:6rpx; + } + } } .info{ flex-grow: 1; @@ -72,23 +89,27 @@ - + - - - + + + + + 农产品 + 农资 + {{v.warehouseName}} {{v.warehouseAddress}} - 库存种类:{{v.inventoryType||0}}种 {{v.capacity||0}}㎡ + 库存种类:{{v.inventoryCount||0}}种 {{v.capacity||0}}㎡ 修改 删除 - 查看库存 + 查看库存 @@ -128,7 +149,7 @@ import request,{host} from '@/common/request.js' body: this.searchVal }) if(res.statu){ - this.list=this.list.concat(res.data.warehouseList.map(v=>({...v,warehousePic:(v.warehousePic||'').split(",").filter(v=>v)}))) + this.list=this.list.concat(res.data.records.map(v=>({...v,warehousePic:(v.warehousePic||'').split(",").filter(v=>v)}))) this.total=res.data.total this.searchVal.pageNo++ if(this.list.length==this.total)uni.showToast({title:"加载完成!",icon:"none"}) diff --git a/uni.scss b/uni.scss index bed6796..7048b2f 100644 --- a/uni.scss +++ b/uni.scss @@ -77,7 +77,7 @@ $uni-font-size-paragraph:15px; @import '@/common/main.css'; @import 'uview-ui/theme.scss'; -@import url('https://at.alicdn.com/t/c/font_3852037_dzizkbp2jzo.css'); +@import url('https://at.alicdn.com/t/c/font_3852037_xnap1h9v4h.css'); [class*=plant-]{ font-family: "plantMana" !important; font-size: 16px;