This commit is contained in:
2026-01-09 10:19:19 +08:00
parent e05a972dbd
commit ddf1525626
7 changed files with 248 additions and 38 deletions

View File

@@ -25,18 +25,19 @@
<span class="filter_label">物料编码</span>
</view>
<view class="zd-col-13">
<search-box v-model="materialData.material_code"/>
<!-- <search-box v-model="materialData.material_code"/> -->
<input type="text" class="filter_input" v-model="materialData.material_code" disabled>
</view>
<button class="mini-btn" type="primary" @tap="toJump('material?title=物料维护')">查询</button>
<button class="mini-btn" type="primary" @tap="toJump('mater-save?title=物料维护')">查询</button>
</view>
<view class="zd-row border-bottom">
<view class="zd-col-5">
<view class="zd-col-6">
<span class="filter_label">批号</span>
</view>
<view class="zd-col-14">
<view class="zd-col-13">
<input type="text" class="filter_input" v-model="val2">
</view>
<button class="mini-btn" type="primary" @tap="_queryHistoryTask">查询</button>
<button class="mini-btn" type="primary" @tap="_queryIvt">查询</button>
</view>
</view>
<view class="zd_wrapper grid-wraper">
@@ -51,7 +52,6 @@
<th>批号</th>
<th>数量</th>
<th>单位</th>
<th>供应商</th>
<th>类别</th>
<th>规格</th>
<th>型号</th>
@@ -62,18 +62,17 @@
<tbody>
<tr v-for="(e, i) in dataList" :key="i">
<td>{{i+1}}</td>
<td>{{e.vehicle_code}}</td>
<td>{{e.point_code1}}</td>
<td>{{e.point_code2}}</td>
<td>{{e.task_code}}</td>
<td>{{e.config_name}}</td>
<td>{{e.car_no}}</td>
<td>{{e.remark}}</td>
<td>{{e.remark}}</td>
<td>{{e.remark}}</td>
<td>{{e.remark}}</td>
<td>{{e.remark}}</td>
<td>{{e.remark}}</td>
<td>{{e.struct_code}}</td>
<td>{{e.material_code}}</td>
<td>{{e.material_name}}</td>
<td>{{e.pcsn}}</td>
<td>{{e.canuse_qty}}</td>
<td>{{e.qty_unit_name}}</td>
<td>{{e.class_name}}</td>
<td>{{e.material_spec}}</td>
<td>{{e.material_model}}</td>
<td>{{e.insert_time}}</td>
<td>{{e.storagevehicle_code}}</td>
</tr>
</tbody>
</table>
@@ -86,7 +85,7 @@
<script>
import NavBar from '@/components/NavBar.vue'
import SearchBox from '@/components/SearchBox.vue'
import {queryHistoryTask} from '@/utils/getData2.js'
import {queryIvt} from '@/utils/getData3.js'
export default {
components: {
NavBar,
@@ -95,9 +94,10 @@
data() {
return {
title: '',
options1: [],
options: [{text:'原粉', value: '1'}, {text:'辅料', value: '2'}, {text:'批料室', value: '3'}, {text:'中间站', value: '4'}, {text:'内包材', value: '5'}, {text:'外包材', value: '6'}],
index1: '',
// options1: [],
materialData: {},
options1: [{text:'原料', value: 'WYL01'}, {text:'辅料', value: 'WFL01'}, {text:'批料室', value: 'PZC01'}, {text:'中间站', value: 'ZZC01'}, {text:'内包材', value: 'NBC01'}, {text:'外包材', value: 'WBC01'}],
index1: 'WYL01',
val1: '',
val2: '',
dataList: []
@@ -105,7 +105,12 @@
},
onLoad (options) {
this.title = options.title
this._queryHistoryTask()
},
onShow () {
if (this.$store.getters.publicObj !== '') {
this.materialData = this.$store.getters.publicObj
this.$store.dispatch('setPublicObj', '')
}
},
methods: {
toEmpty () {
@@ -115,12 +120,12 @@
},
toJump (name) {
uni.navigateTo({
url: `/pages/hdyy/wbc/${name}`
url: `/pages/hdyy/tygn/${name}`
})
},
async _queryHistoryTask () {
async _queryIvt () {
try {
let res = await queryHistoryTask(this.val1)
let res = await queryIvt(this.index1, this.val1, this.materialData.material_code, this.val2)
if (res && res.data) {
this.dataList = [...res.data]
} else {