联调修改
This commit is contained in:
@@ -17,10 +17,9 @@
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">分切设备</span>
|
||||
</view>
|
||||
<view class="zd-col-12 filter_select">
|
||||
<uni-data-select v-model="index" :localdata="options"></uni-data-select>
|
||||
<view class="zd-col-17 filter_select">
|
||||
<uni-data-select v-model="index" :localdata="options" @change="selectChange"></uni-data-select>
|
||||
</view>
|
||||
<button class="zd-col-4 button-primary button-primary_s" @tap="_getSlitterNeedShaftPlans">查询</button>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper grid-wraper">
|
||||
@@ -105,8 +104,13 @@
|
||||
let res = await getSlitterDeviceBox()
|
||||
this.options = [...res]
|
||||
},
|
||||
async _getSlitterNeedShaftPlans () {
|
||||
let res = await getSlitterNeedShaftPlans(this.val1, this.index)
|
||||
selectChange (e) {
|
||||
if (e) {
|
||||
this._getSlitterNeedShaftPlans(e)
|
||||
}
|
||||
},
|
||||
async _getSlitterNeedShaftPlans (e) {
|
||||
let res = await getSlitterNeedShaftPlans(e)
|
||||
this.dataList = [...res]
|
||||
},
|
||||
async _doSendShaft () {
|
||||
|
||||
@@ -15,10 +15,32 @@
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">流转单号</span>
|
||||
<span class="filter_label">母卷号</span>
|
||||
</view>
|
||||
<view class="zd-col-17">
|
||||
<input v-model="val2" type="text" class="filter_input" @blur="handleConfirm" @confirm="handleConfirm">
|
||||
<search-box
|
||||
v-model="val2"
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">大/小卷</span>
|
||||
</view>
|
||||
<view class="zd-col-17 filter_picker">
|
||||
<picker @change="pickerChange" :value="index1" :range="options1" range-key="text">
|
||||
<view class="uni-input">{{index1 !== '' ? options1[index1].text : ''}}</view>
|
||||
</picker>
|
||||
</view>
|
||||
<uni-icons type="right" size="14" color="#999"></uni-icons>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">是否烘烤</span>
|
||||
</view>
|
||||
<view class="relative zd-col-17">
|
||||
<switch :checked="isChecked" color="#6798ef" style="transform:scale(0.8)"/>
|
||||
<text @tap="setWStatus" style="position: absolute;display: inline-block;width: 52px; height: 32px;left: 0;"></text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
@@ -35,12 +57,9 @@
|
||||
<span class="filter_label">时间</span>
|
||||
</view>
|
||||
<view class="zd-col-17">
|
||||
<uni-datetime-picker
|
||||
type="datetime"
|
||||
:value="time"
|
||||
@change="dateChange"
|
||||
/>
|
||||
<input v-model="val4" type="number" class="filter_input">
|
||||
</view>
|
||||
<view class="zd-col-2 filter_label">分</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper">
|
||||
@@ -48,7 +67,7 @@
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">母卷号</span>
|
||||
</view>
|
||||
<view class="zd-col-17 filter_msg">{{obj.roll_type}}</view>
|
||||
<view class="zd-col-17 filter_msg">{{obj.order_code}}</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
@@ -66,9 +85,9 @@
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-4 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !val1 || !val2 || !val3}" :disabled="disabled" @tap="_doModifyRawInfos">修改信息</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !val1 || !val2 || index1 === '' || !val3 || !val4}" :disabled="disabled" @tap="_doModifyRawInfos">修改信息</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_bakingQuality('1')">质检合格</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !val1 || !val2}" :disabled="disabled" @tap="_bakingQuality('2')">再次烘烤</button>
|
||||
<button class="zd-col-6 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_bakingQuality('0')">再次烘烤</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -87,33 +106,52 @@
|
||||
title: '',
|
||||
val1: '',
|
||||
val2: '',
|
||||
options1: [{value: '1', text: '大卷'}, {value: '2', text: '小卷'}],
|
||||
index1: '',
|
||||
isChecked: false,
|
||||
val3: '',
|
||||
time: '',
|
||||
obj: {roll_type: '-', is_baking: '-', msg: '-'},
|
||||
val4: '',
|
||||
obj: {order_code: '-', is_baking: '-', msg: '-'},
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
val1(value) {
|
||||
this.checkInputs(value, this.val2);
|
||||
},
|
||||
val2(value) {
|
||||
this.checkInputs(this.val1, value);
|
||||
}
|
||||
},
|
||||
onLoad (options) {
|
||||
this.title = options.title
|
||||
},
|
||||
methods: {
|
||||
clearUp () {
|
||||
this.val1 = ''
|
||||
this.val2 = ''
|
||||
this.val3 = ''
|
||||
this.time = ''
|
||||
this.obj = {roll_type: '-', is_baking: '-', msg: '-'}
|
||||
this.disabled = false
|
||||
},
|
||||
handleConfirm () {
|
||||
if (this.val2) {
|
||||
this._getHotTempPointInfo()
|
||||
}
|
||||
},
|
||||
async _getHotTempPointInfo () {
|
||||
let res = await getHotTempPointInfo(this.val1, this.val2)
|
||||
this.obj = res
|
||||
},
|
||||
checkInputs(val1, val2) {
|
||||
if (val1 && val2) {
|
||||
this._getHotTempPointInfo()
|
||||
}
|
||||
},
|
||||
pickerChange (e) {
|
||||
this.index1 = e.detail.value
|
||||
},
|
||||
setWStatus () {
|
||||
this.isChecked = !this.isChecked
|
||||
},
|
||||
clearUp () {
|
||||
this.val1 = ''
|
||||
this.val2 = ''
|
||||
this.index1 = ''
|
||||
this.isChecked = false
|
||||
this.val3 = ''
|
||||
this.val4 = ''
|
||||
this.obj = {order_code: '-', is_baking: '-', msg: '-'}
|
||||
this.disabled = false
|
||||
},
|
||||
async _bakingQuality (type) {
|
||||
this.disabled = true
|
||||
if (!this.val1) {
|
||||
@@ -131,17 +169,15 @@
|
||||
this.disabled = false
|
||||
}
|
||||
},
|
||||
dateChange (e) {
|
||||
this.time = e
|
||||
},
|
||||
async _doModifyRawInfos () {
|
||||
this.disabled = true
|
||||
if (!this.val1 || !this.val2 || !this.val3) {
|
||||
if (!this.val1 || !this.val2 || this.index1 === '' || !this.val3 || !this.val4) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await doModifyRawInfos(this.val1, this.val2, this.val3, this.time)
|
||||
let checked = this.isChecked ? '1' : '0'
|
||||
let res = await doModifyRawInfos(this.val1, this.val2, this.options1[this.index1].value, checked, this.val3, this.val4)
|
||||
this.clearUp()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<nav-bar :title="title"></nav-bar>
|
||||
<view class="zd_content">
|
||||
<view class="zd_wrapper">
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-row">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">点位</span>
|
||||
</view>
|
||||
@@ -13,6 +13,16 @@
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row mgb20">
|
||||
<button class="zd-col-11 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_needEmptyVehicle">呼叫空辊</button>
|
||||
<button class="zd-col-11 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_necessaryEmptyVehicle">空辊回库</button>
|
||||
</view>
|
||||
<view class="zd-row mgb20">
|
||||
<button class="zd-col-11 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_confirmBlanking('1')">允许进入</button>
|
||||
<button class="zd-col-11 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_confirmBlanking('2')">允许离开</button>
|
||||
</view>
|
||||
<view class="zd_wrapper">
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">流转单号</span>
|
||||
@@ -33,11 +43,8 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-3 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_needEmptyVehicle">呼叫空辊</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_necessaryEmptyVehicle">空辊回库</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1 || !val2}" :disabled="disabled" @tap="_needEmptyAxisv2">生箔下料</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_confirmBlanking">准备就绪</button>
|
||||
<button class="zd-col-8 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2}" :disabled="disabled" @tap="_needEmptyAxisv2">生箔下料</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -125,14 +132,14 @@
|
||||
this.disabled = false
|
||||
}
|
||||
},
|
||||
async _confirmBlanking () {
|
||||
async _confirmBlanking (type) {
|
||||
this.disabled = true
|
||||
if (!this.val1) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await confirmBlanking(this.val1)
|
||||
let res = await confirmBlanking(this.val1, type)
|
||||
this.clearUp()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
@@ -147,6 +154,4 @@
|
||||
</script>
|
||||
|
||||
<style lang="stylus" scoped>
|
||||
.button-primary
|
||||
font-size: 28rpx;
|
||||
</style>
|
||||
|
||||
@@ -4,15 +4,16 @@
|
||||
<view class="zd_content">
|
||||
<view class="zd_wrapper">
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-5">
|
||||
<view class="zd-col-3">
|
||||
<span class="filter_label">点位</span>
|
||||
</view>
|
||||
<view class="zd-col-14">
|
||||
<view class="zd-col-12">
|
||||
<search-box
|
||||
v-model="val1"
|
||||
/>
|
||||
</view>
|
||||
<button class="zd-col-4 button-primary button-primary_s" @tap="_queryOrderInfo">查询</button>
|
||||
<button class="zd-col-4 button-default button-primary_s" @tap="clearUp">清空</button>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper grid-wraper">
|
||||
@@ -20,38 +21,26 @@
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>母卷号</th>
|
||||
<th>子卷号</th>
|
||||
<th>序号</th>
|
||||
<th class="th_2">母卷号</th>
|
||||
<th>机台编号</th>
|
||||
<th>分切组</th>
|
||||
<th>生产顺序</th>
|
||||
<th>生产日期</th>
|
||||
<th>订单号</th>
|
||||
<th>纸筒/FRP管</th>
|
||||
<th>纸筒物料编码</th>
|
||||
<th>纸筒物料描述</th>
|
||||
<th>纸筒规格</th>
|
||||
<th>FRP管物料编码</th>
|
||||
<th>FRP管物料描述</th>
|
||||
<th>FRP管规格</th>
|
||||
<th>是否烘烤</th>
|
||||
<th>烘烤时间/分</th>
|
||||
<th>大小卷</th>
|
||||
<th>烘烤温度</th>
|
||||
<th>所在位置</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(e, i) in dataList" :key="i" @click="toCheck(e)" :class="{'checked': e.container_name === pkId}">
|
||||
<td>{{e.source_container_name}}</td>
|
||||
<td>{{e.container_name}}</td>
|
||||
<td>{{e.point_code}}</td>
|
||||
<td>{{e.split_group}}</td>
|
||||
<td>{{e.manufacture_sort}}</td>
|
||||
<td>{{e.manufacture_date}}</td>
|
||||
<td>{{e.mfg_order_name}}</td>
|
||||
<td>{{e.paper_tube_or_FRP}}</td>
|
||||
<td>{{e.paper_tube_material}}</td>
|
||||
<td>{{e.paper_tube_description}}</td>
|
||||
<td>{{e.paper_tube_model}}</td>
|
||||
<td>{{e.FRP_material}}</td>
|
||||
<td>{{e.FRP_description}}</td>
|
||||
<td>{{e.FRP_model}}</td>
|
||||
<tr v-for="(e, i) in dataList" :key="i" @click="toCheck(e)" :class="{'checked': e.workorder_id === pkId}">
|
||||
<td>{{ i + 1 }}</td>
|
||||
<td class="td_2">{{e.container_name}}</td>
|
||||
<td>{{e.resource_name}}</td>
|
||||
<td>{{['否', '是'][Number(e.is_baking)]}}</td>
|
||||
<td>{{e.baking_time}}</td>
|
||||
<td>{{['大卷', '小卷'][Number(e.is_baking) - 1]}}</td>
|
||||
<td>{{e.baking_temperature}}</td>
|
||||
<td>{{e.zc_point}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -59,11 +48,11 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-3 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_slitvehicleReturn">空轴送回</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1 || !pkId}" :disabled="disabled" @tap="_slitcallSlitterRoll">呼叫母卷</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_slitsendSlitterRoll">母卷送回</button>
|
||||
<button class="zd-col-5 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_slitallowCoiling">确认上料</button>
|
||||
<button class="zd-col-4 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_slitallowCoiling('1')">确认上料</button>
|
||||
<button class="zd-col-4 button-primary" :class="{'button-info': !val1}" :disabled="disabled" @tap="_slitallowCoiling('2')">允许离开</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -97,13 +86,14 @@
|
||||
this.dataList = [...res.data]
|
||||
},
|
||||
toCheck (e) {
|
||||
this.pkId = e.container_name === this.pkId ? '' : e.container_name
|
||||
this.pkObj = e.container_name === this.pkId ? e : {}
|
||||
this.pkId = e.workorder_id === this.pkId ? '' : e.workorder_id
|
||||
this.pkObj = e.workorder_id === this.pkId ? e : {}
|
||||
},
|
||||
clearUp () {
|
||||
this.index = ''
|
||||
this.val1 = ''
|
||||
this.val2 = ''
|
||||
this.dataList = []
|
||||
this.pkId = ''
|
||||
this.pkObj = {}
|
||||
this.disabled = false
|
||||
},
|
||||
async _slitvehicleReturn () {
|
||||
@@ -157,14 +147,14 @@
|
||||
this.disabled = false
|
||||
}
|
||||
},
|
||||
async _slitallowCoiling () {
|
||||
async _slitallowCoiling (type) {
|
||||
this.disabled = true
|
||||
if (!this.val1) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await slitallowCoiling(this.val1)
|
||||
let res = await slitallowCoiling(this.val1, type)
|
||||
this.clearUp()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
@@ -180,5 +170,5 @@
|
||||
|
||||
<style lang="stylus" scoped>
|
||||
.button-primary
|
||||
font-size: 28rpx;
|
||||
font-size: 24rpx;
|
||||
</style>
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-8 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !index2 || !val1}" :disabled="disabled" @tap="_bindSlitterSubVolumeInfo">子卷绑定</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !index1 || !index2 || !val1}" :disabled="disabled" @tap="_bindSlitterSubVolumeInfo">子卷绑定</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -83,12 +83,12 @@
|
||||
},
|
||||
async _bindSlitterSubVolumeInfo () {
|
||||
this.disabled = true
|
||||
if (!this.index2 || !this.val1) {
|
||||
if (!this.index1 || !this.index2 || !this.val1) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await bindSlitterSubVolumeInfo(this.index2, this.val1)
|
||||
let res = await bindSlitterSubVolumeInfo(this.index1, this.index2, this.val1)
|
||||
this.clearUp()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
@@ -3,16 +3,6 @@
|
||||
<nav-bar :title="title"></nav-bar>
|
||||
<view class="zd_content">
|
||||
<view class="zd_wrapper">
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">物料编码</span>
|
||||
</view>
|
||||
<view class="zd-col-17">
|
||||
<search-box
|
||||
v-model="val1"
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">管芯规格</span>
|
||||
@@ -26,14 +16,14 @@
|
||||
<span class="filter_label">管芯数量</span>
|
||||
</view>
|
||||
<view class="zd-col-19">
|
||||
<input v-model=" val2" type="number" class="filter_input">
|
||||
<input v-model="val1" type="number" class="filter_input">
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-7 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2 || index === ''}" :disabled="disabled" @tap="_gxconfirmedOutStorage">管芯出库</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || index === ''}" :disabled="disabled" @tap="_gxconfirmedOutStorage">管芯出库</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -53,7 +43,6 @@
|
||||
index: '',
|
||||
options: [],
|
||||
val1: '',
|
||||
val2: '',
|
||||
disabled: false
|
||||
};
|
||||
},
|
||||
@@ -68,18 +57,23 @@
|
||||
},
|
||||
clearUp () {
|
||||
this.val1 = ''
|
||||
this.val2 = ''
|
||||
this.index = ''
|
||||
this.disabled = false
|
||||
},
|
||||
async _gxconfirmedOutStorage () {
|
||||
this.disabled = true
|
||||
if (!this.val1 || !this.val2 || this.index === '') {
|
||||
if (!this.val1 || this.index === '') {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
let material_spec = ''
|
||||
this.options.map(el => {
|
||||
if (el.value === this.index) {
|
||||
material_spec = el.text
|
||||
}
|
||||
})
|
||||
try {
|
||||
let res = await gxconfirmedOutStorage(this.val2, this.val1, this.index)
|
||||
let res = await gxconfirmedOutStorage(this.val1, this.index, material_spec)
|
||||
this.clearUp()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
@@ -3,16 +3,6 @@
|
||||
<nav-bar :title="title"></nav-bar>
|
||||
<view class="zd_content">
|
||||
<view class="zd_wrapper">
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">物料编码</span>
|
||||
</view>
|
||||
<view class="zd-col-17">
|
||||
<search-box
|
||||
v-model="val1"
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-col-7">
|
||||
<span class="filter_label">管芯规格</span>
|
||||
@@ -21,19 +11,19 @@
|
||||
<zxz-uni-data-select v-model="index" filterable :localdata="options"></zxz-uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row border-bottom">
|
||||
<view class="zd-row">
|
||||
<view class="zd-col-5">
|
||||
<span class="filter_label">管芯数量</span>
|
||||
</view>
|
||||
<view class="zd-col-19">
|
||||
<input v-model=" val2" type="number" class="filter_input" @blur="handleBlur">
|
||||
<input v-model=" val1" type="number" class="filter_input" @blur="handleBlur">
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-7 button-default" @tap="clearUp">清空</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || !val2 || index === ''}" :disabled="disabled" @tap="_gxconfirmedInStorage">确认入库</button>
|
||||
<button class="zd-col-15 button-primary" :class="{'button-info': !val1 || index === ''}" :disabled="disabled" @tap="_gxconfirmedInStorage">确认入库</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -53,7 +43,6 @@
|
||||
index: '',
|
||||
options: [],
|
||||
val1: '',
|
||||
val2: '',
|
||||
qty: '',
|
||||
disabled: false
|
||||
};
|
||||
@@ -70,40 +59,45 @@
|
||||
async _gxremainingQty () {
|
||||
let res = await gxremainingQty()
|
||||
this.qty = res.qty
|
||||
if (Number(this.val2) > Number(this.qty)) {
|
||||
if (Number(this.val1) > Number(this.qty)) {
|
||||
uni.showToast({
|
||||
title: '管芯库空位不足!',
|
||||
icon: 'none'
|
||||
})
|
||||
this.val2 = ''
|
||||
this.val1 = ''
|
||||
}
|
||||
},
|
||||
handleBlur () {
|
||||
if (this.val2 !== '') {
|
||||
if (this.val1 !== '') {
|
||||
this._gxremainingQty()
|
||||
} else if (Number(this.val2) > 5) {
|
||||
} else if (Number(this.val1) > 5) {
|
||||
uni.showToast({
|
||||
title: '一次性最多只能入5根管芯!',
|
||||
icon: 'none'
|
||||
})
|
||||
this.val2 = ''
|
||||
this.val1 = ''
|
||||
}
|
||||
},
|
||||
clearUp () {
|
||||
this.val1 = ''
|
||||
this.val2 = ''
|
||||
this.index = ''
|
||||
this.qty = ''
|
||||
this.disabled = false
|
||||
},
|
||||
async _gxconfirmedInStorage () {
|
||||
this.disabled = true
|
||||
if (!this.val1 || !this.val2 || this.index === '') {
|
||||
if (!this.val1 || this.index === '') {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
let material_spec = ''
|
||||
this.options.map(el => {
|
||||
if (el.value === this.index) {
|
||||
material_spec = el.text
|
||||
}
|
||||
})
|
||||
try {
|
||||
let res = await gxconfirmedInStorage(this.val2, this.val1, this.index)
|
||||
let res = await gxconfirmedInStorage(this.val1, this.index, material_spec)
|
||||
this.clearUp()
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
Reference in New Issue
Block a user