Browse Source

界面取值调整

master
孙家正 2 years ago
parent
commit
c3e13e950e
  1. 4
      pages/home/login.vue
  2. 6
      pages/stock/list.vue
  3. 4
      pages/stock/record.vue

4
pages/home/login.vue

@ -1,4 +1,4 @@
<style lang="scss">
;<style lang="scss">
.container{
background-image:url(/static/login_bg.png);
background-size:calc(100% + 400rpx);
@ -109,7 +109,7 @@ export default {
onLoad(options){
this.formData.username=options.phone||""
if(process.env.NODE_ENV === 'development'){
this.formData.username="13383434048"//"18636155239"
this.formData.username="18788469459"//
this.formData.password="1qaz@WSX"
}

6
pages/stock/list.vue

@ -167,7 +167,7 @@
<d-form :label="`${({in:'入',out:'出'})[mode]}库类型`" field="inOutType" required type="select" :columns="inOutType.list" :value="inOutType.value" @select="inOutType.value=$event.map(v=>v.value);formData.inOutType=inOutType.value.at(-1)"/>
<d-form :label="`${({in:'入',out:'出'})[mode]}库批次号`" field="inOutBatchNo" required :disabled="formData.substanceType==2" :value="formData.inOutBatchNo" @input="formData.inOutBatchNo=$event" :btnText="formData.substanceType==1?'生成':''" :btnFun="()=>this.formData.inOutBatchNo=`${({in:'RK',out:'CK'})[this.mode]}${new Date().format('yyyyMMdd')}${new Date().getTime()}`"/>
<d-form :label="({1:`${({in:'入',out:'出'})[mode]}库数量`,2:'重量'})[formData.substanceType]" field="number" required :suffix="number.suffix" :value="formData.number" @input="formData.number=$event" type="digit"/>
<d-form label="操作日期" field="operationTime" required type="calendar" v-model="formData.operationTime"/>
<d-form label="操作日期" field="operationTime" required type="calendar" v-model="formData.operateTime"/>
<template v-if="formData.substanceType==2&&formData.inOutType=='out01'&&recoveryBatch.list.length>0">
<view style="display:flex;margin:-20rpx 0;">
<d-form label="规格" required field="specification" type="digit" suffix="kg" :value="formData.specification" @input="formData.specification=$event"/>
@ -209,7 +209,7 @@ export default{
pic:[],
number:"",
substanceType:"",
operationTime:"",
operateTime:"",
tradeWeight:"",
specification:"",
@ -228,7 +228,7 @@ export default{
if(!val)call(new Error(`${({in:'入',out:'出'})[this.mode]}库批次号必填!`));
else call()
},trigger:['blur','change']},
operationTime:{required:true,message:"请选择操作日期!",trigger:['blur','change']},
operateTime:{required:true,message:"请选择操作日期!",trigger:['blur','change']},
number:{required:true,validator:(rule,val,call)=>{
var title=({1:({in:'入',out:'出'})[this.mode],2:'交易重量'})[this.formData.substanceType]
if(!(val>0))call(new Error(`请输入${title}`));

4
pages/stock/record.vue

@ -141,7 +141,7 @@
<view class="company">
<text>{{v.supplier}}</text> <text>{{v.number}}{{v.packgeUnit}}({{v.equivalentAmount}}{{v.unit}})</text>
</view>
<view class="date"> 操作时间{{v.createTime}} </view>
<view class="date"> 操作日期{{v.operateTime}} </view>
</template>
<template v-else>
<view class="head">
@ -153,7 +153,7 @@
<text>{{v.number}}{{v.unit}}</text>
</view>
<view class="warehouse"> 所在仓库{{v.warehouseName}} </view>
<view class="date"> 操作时间{{v.createTime}} </view>
<view class="date"> 操作日期{{v.operateTime}} </view>
</template>
</view>
<u-empty v-if="list.length<=0" text="为查询到相关信息" width="70%" icon="/static/noData.png"/>

Loading…
Cancel
Save