修改生产界面

master
夜笙歌 12 months ago
parent 328206b93d
commit ce46af16e0

@ -231,3 +231,11 @@ export function assignTask(data) {
data: data data: data
}) })
} }
// 查询物料安装情况
export function selectMaterialInstallationCircumstance(query) {
return request({
url: '/api/selectMaterialInstallationCircumstance',
method: 'get',
params: query
})
}

@ -156,6 +156,7 @@
size="small" size="small"
style="margin-right: 12px" style="margin-right: 12px"
type="text" type="text"
@click="SOP(scope.row)"
> >
SOP预览 SOP预览
</el-button> </el-button>
@ -441,6 +442,65 @@
</el-form> </el-form>
</el-dialog> </el-dialog>
<el-dialog
:visible.sync="SOPModel"
title="上传图纸"
width="30%"
@before-close="blueprintModel = false">
<el-upload
ref="drawingUpload"
:auto-upload="true"
:file-list="fileList"
:headers="headers"
:limit="0"
action="uploadImgUrl"
list-type="picture-card"
single
>
<i slot="default" class="el-icon-plus"></i>
<div slot="file" slot-scope="{file}">
<img
v-if="isAssetTypeAnImage(file.name)"
:alt="file.name"
:src="file.url" class="el-upload-list__item-thumbnail"
>
<span v-else>{{ file.name }}</span>
<span class="el-upload-list__item-actions">
<span
v-if="isAssetTypeAnImage(file.name)"
class="el-upload-list__item-preview"
@click="handlePictureCardPreview(file)"
>
<i class="el-icon-zoom-in"></i>
</span>
<span
class="el-upload-list__item-delete"
@click="handleDownload(file)"
>
<i class="el-icon-download"></i>
</span>
</span>
</div>
</el-upload>
<div slot="footer" class="dialog-footer">
<el-button @click="SOPModel = false"> </el-button>
</div>
</el-dialog>
<el-dialog
:visible.sync="pictureDetailModel"
append-to-body
title="图纸预览"
width="800"
>
<img
:src="dialogImageUrl"
style="display: block; max-width: 100%; margin: 0 auto"
/>
</el-dialog>
<!-- <el-dialog :visible.sync="assignModel" title="工位选择" width="80%">--> <!-- <el-dialog :visible.sync="assignModel" title="工位选择" width="80%">-->
<!-- <el-table :data="stationData" highlight-current-row--> <!-- <el-table :data="stationData" highlight-current-row-->
@ -515,6 +575,10 @@ export default {
dicts: ['wms_raw_return_task_type'], dicts: ['wms_raw_return_task_type'],
data() { data() {
return { return {
fileList: [],
SOPModel: false,
pictureDetailModel: false,
dialogImageUrl: '',
returnModelVisible: false, returnModelVisible: false,
returnModelForm:{}, returnModelForm:{},
WarehousesList:[], WarehousesList:[],
@ -629,6 +693,14 @@ export default {
} }
}, },
async mounted() { async mounted() {
setInterval(() => {
this.$notify.info({
title: '通知',
message: '通知公告',
position: 'bottom-right',
duration: 0
});
}, 60 * 1000)
getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => { getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => {
this.tableData = e.rows this.tableData = e.rows
this.totalNum1 = Math.ceil(e.total / 5) this.totalNum1 = Math.ceil(e.total / 5)
@ -1517,7 +1589,73 @@ export default {
return false; return false;
} }
}); });
} },
async SOP(e) {
this.fileList = []
console.log(e)
// const data = await fun()
// this.fileList = data.map(v=>v)
this.fileList = [
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
]
this.SOPModel = true;
},
//
handlePictureCardPreview(file) {
this.dialogImageUrl = file.url;
this.pictureDetailModel = true;
},
//
async handleDownload(file) {
this.fileDownload(file)
},
isAssetTypeAnImage(ext) {
let suffix = ext.lastIndexOf(".");
let name = ext.substr(suffix + 1);
return ['png', 'jpg', 'jpeg'].includes(name.toLowerCase())
},
} }
} }

@ -598,8 +598,7 @@
</div> </div>
</el-upload> </el-upload>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="SOPModel = false"> </el-button> <el-button @click="SOPModel = false"> </el-button>
<el-button @click="SOPModel = false"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
@ -629,9 +628,13 @@ import {
applyRawOutstock, applyRawOutstock,
getProductPlans, getProductPlans,
insertProductPlanDetails, insertProductPlanDetails,
getProductPlanDetails, startProductPlanDetail, completeProductPlanDetail, getProductPlanDetails,
startProductPlanDetail,
completeProductPlanDetail,
firstFloorProduceInstock, firstFloorProduceInstock,
scanMaterial2Confirm, applyRawReturn scanMaterial2Confirm,
applyRawReturn,
selectMaterialInstallationCircumstance
} from '@/api/board' } from '@/api/board'
import {getToken} from "@/utils/auth"; import {getToken} from "@/utils/auth";
@ -709,6 +712,14 @@ export default {
} }
}, },
mounted() { mounted() {
setInterval(() => {
this.$notify.info({
title: '通知',
message: '通知公告',
position: 'bottom-right',
duration: 0
});
}, 60 * 1000)
getProductPlans({pageNum: 1, pageSize: 5}).then(e => { getProductPlans({pageNum: 1, pageSize: 5}).then(e => {
this.tableData = e.rows this.tableData = e.rows
this.totalNum1 = Math.ceil(e.total / 5) this.totalNum1 = Math.ceil(e.total / 5)
@ -1003,12 +1014,11 @@ export default {
} }
}, },
// / // /
getDetail(e) { async getDetail(e) {
console.log(e.row)
this.planId = e.row.planId this.planId = e.row.planId
this.nowMaterial = e.row.materialName this.nowMaterial = e.row.materialName
this.nowNum2 = 1 this.nowNum2 = 1
getProductPlanDetails({pageNum: 1, pageSize: 5, planId: e.row.planId}).then(res => { await getProductPlanDetails({pageNum: 1, pageSize: 5, planId: e.row.planId}).then(res => {
if (res.rows.length === 0) { if (res.rows.length === 0) {
this.$confirm('是否生成计划明细', '确认', { this.$confirm('是否生成计划明细', '确认', {
confirmButtonText: '确定', confirmButtonText: '确定',
@ -1040,7 +1050,12 @@ export default {
} }
}) })
const table1 = await selectMaterialInstallationCircumstance({
installType:1,
planDetailId:e.row.planDetailId,
materialBomId:e.row.materialBomId
})
console.log(table1)
}, },
// //
getMaterials(val) { getMaterials(val) {

@ -199,7 +199,7 @@
</div> </div>
<div class="chartBox chartBox4"> <div class="chartBox chartBox4">
<div class="title">当日产量</div> <div class="title">每周产量</div>
<div class="chart"> <div class="chart">
<Chart ref="chart4"></Chart> <Chart ref="chart4"></Chart>
</div> </div>
@ -466,6 +466,14 @@ export default {
} }
}, },
mounted() { mounted() {
setInterval(() => {
this.$notify.info({
title: '通知',
message: '通知公告',
position: 'bottom-right',
duration: 0
});
}, 60 * 1000)
getProductPlans({pageNum: 1, pageSize: 5}).then(e => { getProductPlans({pageNum: 1, pageSize: 5}).then(e => {
this.tableData = e.rows this.tableData = e.rows
this.totalNum1 = Math.ceil(e.total / 5) this.totalNum1 = Math.ceil(e.total / 5)

@ -177,7 +177,7 @@
</div> </div>
<div class="chartBox chartBox4"> <div class="chartBox chartBox4">
<div class="title">周产量</div> <div class="title">周产量</div>
<div class="chart"> <div class="chart">
<Chart ref="chart4"></Chart> <Chart ref="chart4"></Chart>
</div> </div>
@ -271,6 +271,7 @@ export default {
this.$notify.info({ this.$notify.info({
title: '通知', title: '通知',
message: '通知公告', message: '通知公告',
position: 'bottom-right',
duration: 0 duration: 0
}); });
}, 60 * 1000) }, 60 * 1000)

@ -115,6 +115,7 @@
<el-button <el-button
size="small" size="small"
type="text" type="text"
@click="SOP(scope.row)"
> >
SOP预览 SOP预览
</el-button> </el-button>
@ -123,6 +124,7 @@
confirm-button-text='是' confirm-button-text='是'
icon="el-icon-info" icon="el-icon-info"
icon-color="red" icon-color="red"
style="margin-left: 8px"
title="确定开始计划吗?" title="确定开始计划吗?"
@confirm="startPlan(scope.row)" @confirm="startPlan(scope.row)"
> >
@ -148,7 +150,7 @@
</div> </div>
<div class="chartBox chartBox4"> <div class="chartBox chartBox4">
<div class="title">当日产量</div> <div class="title">每周产量</div>
<div class="chart"> <div class="chart">
<Chart ref="chart4"></Chart> <Chart ref="chart4"></Chart>
</div> </div>
@ -161,6 +163,63 @@
</el-row> </el-row>
</div> </div>
<el-dialog
:visible.sync="SOPModel"
title="上传图纸"
width="30%"
@before-close="blueprintModel = false">
<el-upload
ref="drawingUpload"
:auto-upload="true"
:file-list="fileList"
:headers="headers"
:limit="0"
action="uploadImgUrl"
list-type="picture-card"
single
>
<i slot="default" class="el-icon-plus"></i>
<div slot="file" slot-scope="{file}">
<img
v-if="isAssetTypeAnImage(file.name)"
:alt="file.name"
:src="file.url" class="el-upload-list__item-thumbnail"
>
<span v-else>{{ file.name }}</span>
<span class="el-upload-list__item-actions">
<span
v-if="isAssetTypeAnImage(file.name)"
class="el-upload-list__item-preview"
@click="handlePictureCardPreview(file)"
>
<i class="el-icon-zoom-in"></i>
</span>
<span
class="el-upload-list__item-delete"
@click="handleDownload(file)"
>
<i class="el-icon-download"></i>
</span>
</span>
</div>
</el-upload>
<div slot="footer" class="dialog-footer">
<el-button @click="SOPModel = false"> </el-button>
</div>
</el-dialog>
<el-dialog
:visible.sync="pictureDetailModel"
append-to-body
title="图纸预览"
width="800"
>
<img
:src="dialogImageUrl"
style="display: block; max-width: 100%; margin: 0 auto"
/>
</el-dialog>
</div> </div>
</template> </template>
@ -193,6 +252,10 @@ export default {
}, },
data() { data() {
return { return {
fileList: [],
SOPModel: false,
pictureDetailModel: false,
dialogImageUrl: '',
nowNum1: 1, nowNum1: 1,
totalNum1: 0, totalNum1: 0,
form: {}, form: {},
@ -201,6 +264,14 @@ export default {
} }
}, },
mounted() { mounted() {
setInterval(() => {
this.$notify.info({
title: '通知',
message: '通知公告',
position: 'bottom-right',
duration: 0
});
}, 60 * 1000)
this.$refs.chart2.setData({ this.$refs.chart2.setData({
tooltip: { tooltip: {
trigger: 'axis', trigger: 'axis',
@ -767,7 +838,74 @@ export default {
message: '已取消' message: '已取消'
}); });
}); });
} },
async SOP(e) {
this.fileList = []
console.log(e)
// const data = await fun()
// this.fileList = data.map(v=>v)
this.fileList = [
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: 'Snipaste_2023-09-04_08-16-59.png',
url: 'http://175.27.215.92:9665/statics/2024/04/17/Snipaste_2023-09-04_08-16-59_20240417142903A013.png'
},
{
name: '会议纪要 0825_20240417143926A014.docx',
url: 'http://175.27.215.92:9665/statics/2024/04/17/会议纪要 0825_20240417143926A014.docx'
},
]
this.SOPModel = true;
},
//
handlePictureCardPreview(file) {
this.dialogImageUrl = file.url;
this.pictureDetailModel = true;
},
//
async handleDownload(file) {
this.fileDownload(file)
},
isAssetTypeAnImage(ext) {
let suffix = ext.lastIndexOf(".");
let name = ext.substr(suffix + 1);
return ['png', 'jpg', 'jpeg'].includes(name.toLowerCase())
},
} }
} }
</script> </script>

Loading…
Cancel
Save