分切下料2
This commit is contained in:
@@ -73,7 +73,7 @@
|
||||
async _showManualView () {
|
||||
let res = await showManualView()
|
||||
if (res) {
|
||||
this.dataList = [...res.data]
|
||||
this.dataList = [...res]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -265,7 +265,7 @@
|
||||
async _showManualView () {
|
||||
let res = await showManualView()
|
||||
if (res) {
|
||||
this.dataList = [...res.data]
|
||||
this.dataList = [...res]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,31 +16,52 @@
|
||||
<uni-data-select v-model="index" :localdata="options" @change="selectChange"></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper">
|
||||
<view class="filter_item">
|
||||
<view class="filter_label_wraper">
|
||||
<span class="filter_label">子卷号</span>
|
||||
</view>
|
||||
<view class="filter_input_wraper mgr20">
|
||||
<view class="filter_input_wraper">
|
||||
<search-box
|
||||
v-model="val1"
|
||||
/>
|
||||
</view>
|
||||
<button class="zd-col-4 btn-submit btn-success" @tap="handleAdd">添加</button>
|
||||
</view>
|
||||
<view class="zd-row">
|
||||
<view class="zd-col-19">
|
||||
<view class="filter_item">
|
||||
<view class="filter_label">轴位置</view>
|
||||
<view class="filter_input_wraper">
|
||||
<radio-group @change="radioChange">
|
||||
<label class="mgr20" v-for="(item, index) in options1" :key="item.value">
|
||||
<radio :value="item.value" :checked="index === current" style="transform:scale(0.8)" />
|
||||
<text class="filter_unit">{{item.text}}</text>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd-col-4">
|
||||
<button class="mini-btn" size="mini" style="display: block;" type="primary" @tap="handleAdd">添加</button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zd_wrapper grid-wraper">
|
||||
<view class="slide_new">
|
||||
<view class="slide_new slide">
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="78%">子卷号</th>
|
||||
<th width="22%">操作</th>
|
||||
<th width="60%">子卷号</th>
|
||||
<th width="20%">轴位置</th>
|
||||
<th width="20%">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(e, i) in dataList" :key="i">
|
||||
<td>{{e}}</td>
|
||||
<td><button class="btn-submit btn-success" @tap="handleDelete(i)">删除</button></td>
|
||||
<td>{{e.container_name}}</td>
|
||||
<td>{{ options1 | findByValue(e.site)}}</td>
|
||||
<td><button class="mini-btn" size="mini" type="primary" @tap="handleDelete(i)">删除</button></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -71,6 +92,9 @@
|
||||
index: '',
|
||||
options2: [],
|
||||
index2: '',
|
||||
options1: [{value: '1', text: '上轴'}, {value: '2', text: '下轴'}],
|
||||
index1: '1',
|
||||
current: 0,
|
||||
val1: '',
|
||||
dataList: [],
|
||||
disabled: false
|
||||
@@ -103,6 +127,9 @@
|
||||
selectChange (e) {
|
||||
this.index = e
|
||||
},
|
||||
radioChange (e) {
|
||||
this.index1 = e.detail.value
|
||||
},
|
||||
handleAdd () {
|
||||
if (!this.val1.trim()) {
|
||||
return
|
||||
@@ -111,7 +138,7 @@
|
||||
if (index !== -1) {
|
||||
this.dataList.splice(index, 1)
|
||||
}
|
||||
this.dataList.push(this.val1)
|
||||
this.dataList.push({container_name: this.val1, site: this.index1})
|
||||
this.val1 = ''
|
||||
},
|
||||
handleDelete (index) {
|
||||
@@ -145,10 +172,4 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.slide_new table {
|
||||
table-layout: auto;
|
||||
}
|
||||
</style>
|
||||
</script>
|
||||
Reference in New Issue
Block a user