更新设备维修、发货、精工车间工序工价/生产审核/工时统计、仓储盘点/库存查询/库位/入库,新增车间派工移动端及SQL脚本
This commit is contained in:
@@ -7,9 +7,12 @@
|
||||
<el-input v-model="DrawingNo" style="width: 200px " size="small" clearable placeholder="图号/型号"/>
|
||||
<el-input v-model="locationWarehouseValue" style="width:200px" placeholder="库位" size="small" clearable/>
|
||||
<el-button style="margin-left: 7px;width: 80px" type="primary" plain size="small" @click="searchTable()">查询</el-button>
|
||||
<el-button type="primary" icon="el-icon-printer" style="margin-left: 7px" plain size="small" @click="printReceiptDoc1()">打印</el-button>
|
||||
</div>
|
||||
<div>
|
||||
<el-table v-loading="loading" :data="tableData" highlight-current-row show-summary border stripe size="small" style="width: 731px" height="740px">
|
||||
<el-table ref="table" v-loading="loading" :data="tableData" highlight-current-row show-summary border stripe size="small" style="width: 731px" height="740px"
|
||||
@selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="50px"/>
|
||||
<el-table-column :width="setColumnWidth('序号')" type="index" label="序号" align="center"/>
|
||||
<el-table-column label="物料编码" align="center" show-overflow-tooltip><!-- 备注:修改人:Ld 修改时间:2026-06-29 14:24:00 -->
|
||||
<template slot-scope="scope">
|
||||
@@ -44,15 +47,57 @@
|
||||
@current-change="handleCurrentChanges"/>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-card v-show="false">
|
||||
<div style="width:900px;margin-left: 350px">
|
||||
<el-card>
|
||||
<div id="WGBLD" style="width: 840px;margin: 0 auto">
|
||||
<div style="width: 260px;margin: 0 auto 20px">
|
||||
<h3>浙江景耀数控物料库位清单</h3>
|
||||
</div>
|
||||
<div style="margin: 0 0 20px">
|
||||
<span style="float: right; font-size: 14px;margin-right: 10px">日期:{{ NowTime }}</span>
|
||||
</div>
|
||||
<table align="center" border="1 solid black" cellspacing="0px" width="100%">
|
||||
<tr id="tablehead12" style="height: 35px">
|
||||
<td colspan="3" style="text-align: center;width: 25%;font-size: 14px">物料编码</td>
|
||||
<td colspan="5" style="text-align: center;width: 30%;font-size: 14px">物料名称</td>
|
||||
<td colspan="4" style="text-align: center;width: 22%;font-size: 14px">图号或型号</td>
|
||||
<td colspan="6" style="text-align: center;width: 23%;font-size: 14px">库位</td>
|
||||
</tr>
|
||||
<tr v-for="(list, index) in returns" :key="index" style="height: 35px">
|
||||
<td colspan="3" style="text-align: center;width: 25%;font-size: 14px">{{ list.物料编码 }}</td>
|
||||
<td colspan="5" style="text-align: center;width: 30%;font-size: 14px">{{ list.物料名称 }}</td>
|
||||
<td colspan="4" style="text-align: center;width: 22%;font-size: 14px">{{ list.规格型号 }}</td>
|
||||
<td colspan="6" style="text-align: center;width: 23%;font-size: 14px">{{ list.库位 }}</td>
|
||||
</tr>
|
||||
<tr style="height: 35px">
|
||||
<td colspan="12" style="text-align: center;font-size: 14px">合计</td>
|
||||
<td colspan="6" style="text-align: center;">
|
||||
<div>
|
||||
<span style="float: right;margin-right: 24%;font-size: 14px">{{ returns.length }} 条</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<div style="margin-top: 15px"><span style="margin-left: 10px;font-size: 14px">制单:</span></div>
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { ExecDatabase } from '@/main'
|
||||
import { mapGetters } from 'vuex'
|
||||
import $ from 'jquery'
|
||||
import { getNowDAY } from '@/utils'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
NowTime: getNowDAY(),
|
||||
returns: [],
|
||||
multipleSelection: [],
|
||||
locationWarehouseValue: '', // 库位
|
||||
MaterialCode: '',
|
||||
MaterialName: '',
|
||||
@@ -130,6 +175,49 @@ export default {
|
||||
handleCurrentChanges(val) {
|
||||
this.pageCurrent = val
|
||||
this.searchTable()
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val
|
||||
},
|
||||
async printReceiptDoc1() {
|
||||
const aa = this.printReceiptDoc()
|
||||
if (aa === 2) {
|
||||
await this.sleep(500)
|
||||
await this.exportTable()
|
||||
} else if (aa === 1) {
|
||||
this.$message.warning('请勾选要打印的物料!!')
|
||||
}
|
||||
},
|
||||
sleep(ms) {
|
||||
return new Promise(resolve => setTimeout(resolve, ms))
|
||||
},
|
||||
exportTable() {
|
||||
const htmlNode = $('#WGBLD').html()
|
||||
const body = $('body')
|
||||
body.children().hide()
|
||||
const printNode = $(htmlNode)
|
||||
body.append(printNode)
|
||||
window.print()
|
||||
body.children().not('script').show()
|
||||
body.children().not('#app').hide()
|
||||
printNode.remove()
|
||||
},
|
||||
printReceiptDoc() {
|
||||
this.returns = []
|
||||
if (this.multipleSelection.length !== 0) {
|
||||
for (let i = 0; i < this.multipleSelection.length; i++) {
|
||||
this.returns.push({
|
||||
物料编码: this.multipleSelection[i].物料编号,
|
||||
物料名称: this.multipleSelection[i].物料名称,
|
||||
规格型号: this.multipleSelection[i].图号或型号,
|
||||
库位: this.multipleSelection[i].货位名称
|
||||
})
|
||||
}
|
||||
return 2
|
||||
} else {
|
||||
this.$message.warning('未勾选物料!!')
|
||||
return 1
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user