This commit is contained in:
liushuai
2020-03-11 18:09:35 +08:00
parent b6c062607f
commit c099ccf0be
14 changed files with 312 additions and 140 deletions

BIN
dist.zip Normal file

Binary file not shown.

View File

@@ -4,7 +4,6 @@
<div style="white-space: nowrap">
<el-card>
<el-row>
<span>零件图号:</span>
<el-input v-model="partName" placeholder="零件图号" size="small" clearable style="width:180px;margin: 3px 0"/>
<el-button size="small" icon="el-icon-search" type="primary" plain style="margin-left: 10px" @click="pageSize=30; pageCurrent=1;searchTable()">查询</el-button>
<el-tooltip :open-delay="1200" effect="dark" content="已导出和未导出备料单" placement="top">

View File

@@ -27,11 +27,11 @@
{{ scope.row.操作工 }}
</template>
</el-table-column>
<el-table-column label="计划工时(分)" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.计划总工时 }}
</template>
</el-table-column>
<!--<el-table-column label="计划工时(分)" align="center" width="70px">-->
<!--<template slot-scope="scope">-->
<!--{{ scope.row.计划总工时 }}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column label="完成工时(分)" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.完成总工时 }}
@@ -86,11 +86,11 @@
{{ scope.row.完成数量 }}
</template>
</el-table-column>
<el-table-column label="计划工时(分)" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.计划工时 }}
</template>
</el-table-column>
<!--<el-table-column label="计划工时(分)" align="center" width="70px">-->
<!--<template slot-scope="scope">-->
<!--{{ scope.row.计划工时 }}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column label="完成工时(分)" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.完成工时 }}

View File

@@ -437,7 +437,25 @@ export default {
})
},
handleDelete(row) {
this.deleteRow(delList, row.项目流水号, function() { this.fetchTableData1() })
this.$confirm('删除该项目,将不可恢复,是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delList(row.项目流水号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
this.fetchTableData1()
} else {
this.$message.error('请先删除机床信息')
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
addMachine(row) {
this.projectNum = row.项目流水号
@@ -460,12 +478,32 @@ export default {
}
},
deleteMachine(row) {
function a() {
// function a() {
// selectMachine(this.projectNum).then(response => {
// this.tableData2 = response.data
// })
// }
this.$confirm('删除该机床,将不可恢复,是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delMachine(row.机床流水号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
selectMachine(this.projectNum).then(response => {
this.tableData2 = response.data
})
} else {
this.$message.error('已经投产的机床不能删除')
}
this.deleteRow(delMachine, row.机床流水号, a)
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
editMachine(row) {
this.flag = 2

View File

@@ -2,7 +2,7 @@
<div class="app-container">
<el-card>
<el-input v-model="ManufacturerName" clearable placeholder="外协厂家名称" size="small" style="width:200px;margin: 10px 0 3px 0;" @keyup.enter.native="pageCurrent=1;pageSize=50;searchTable()" @clear="pageCurrent=1;pageSize=50;searchTable()"/>
<el-button type="primary" size="small" icon="el-icon-search" style="margin-left:20px" plain @click="getList()">查询</el-button>
<el-button type="primary" size="small" icon="el-icon-search" style="margin-left:20px" plain @click="pageCurrent=1;pageSize=50;searchTable()">查询</el-button>
<el-tooltip :open-delay="1200" effect="dark" content="新增外协厂家" placement="top">
<el-button type="distribution" icon="el-icon-circle-plus-outline" style="margin-left: 10px" size="small" @click="editType1('form');param = 0">外协厂家</el-button>
</el-tooltip>
@@ -94,7 +94,7 @@
</el-form-item>
</el-col>
</el-row>
<el-row v-show="FALSE">
<el-row v-show="false">
<el-col :span="12">
<el-form-item label="设备情况" prop="EquipmentCondition">
<el-input v-model="form.EquipmentCondition" placeholder="设备情况" clearable size="small"/>

View File

@@ -2,8 +2,10 @@
<div class="app-container">
<el-card>
<el-row>
<el-col style="margin-top: 3px;width: 150px;margin-left: 10px">
<el-col style="margin-top: 3px;width: 180px;margin-left: 10px">
<el-input v-model="MaterialName" placeholder="物料名称" size="small" clearable style="width: 170px"/>
<el-select
v-show="false"
v-model="MaterialCategoryValue"
placeholder="物料类别"
size="small"
@@ -17,8 +19,15 @@
:value="item.value"/>
</el-select>
</el-col>
<el-col style="margin-top: 3px;width: 150px;margin-left: 10px">
<el-col style="margin-top: 3px;width: 190px">
<el-input
v-model="MaterialSpecification"
placeholder="物料规格"
size="small"
clearable
style="width: 190px"/>
<el-select
v-show="false"
v-model="MaterialVarietyValue"
placeholder="物料品种"
size="small"
@@ -32,32 +41,42 @@
:value="item.value"/>
</el-select>
</el-col>
<el-col style="margin-top: 3px;width: 180px;margin-left: 10px">
<el-input v-model="MaterialName" placeholder="物料名称" size="small" clearable style="width: 170px"/>
</el-col>
<el-col style="margin-top: 3px;width: 180px;margin-left: 10px">
<el-input
v-model="FullNameOfMaterial"
placeholder="物料全称"
size="small"
clearable
style="width: 170px"/>
</el-col>
<el-col style="margin-top: 3px;width: 200px;margin-left: 10px">
<el-input
v-model="MaterialSpecification"
placeholder="物料规格"
size="small"
clearable
style="width: 190px"/>
</el-col>
<el-col style="margin-top: 3px;width: 200px;margin-left: 10px">
<el-col style="margin-top: 3px;width: 190px;margin-left: 10px">
<el-input
v-model="MaterialModel"
placeholder="物料型号"
size="small"
clearable
style="width: 190px"/>
<el-input
v-show="false"
v-model="FullNameOfMaterial"
placeholder="物料全称"
size="small"
clearable
style="width: 170px"/>
</el-col>
<el-col style="margin-top: 3px;width: 250px;margin-left: 10px">
<el-select
v-model="GonghuoshangValue"
placeholder="供货商"
filterable
style="width: 140px"
size="small"
clearable>
<el-option
v-for="item in Gonghuoshang"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-button
type="primary"
icon="el-icon-search"
size="small"
plain
@click="pageCurrent=1;searchMaterial()">查询
</el-button>
</el-col>
</el-row>
<!--<el-col style="width: 280px">-->
@@ -78,6 +97,7 @@
<el-row>
<el-col style="width: 150px;margin-left: 10px">
<el-select
v-show="false"
v-model="MaterialSourceValue"
placeholder="物料来源"
style="margin-bottom: 3px;margin-top: 10px;width: 140px"
@@ -91,19 +111,6 @@
</el-select>
</el-col>
<el-col style="width: 150px;margin-left: 10px">
<el-select
v-model="GonghuoshangValue"
placeholder="供货商"
filterable
style="margin-bottom: 3px;margin-top: 10px;width: 140px"
size="small"
clearable>
<el-option
v-for="item in Gonghuoshang"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<!--<el-input-->
<!--v-model="supplier"-->
<!--placeholder="供货商"-->
@@ -113,13 +120,6 @@
<!--@dblclick.native="param=0;openSupplier()"/>-->
</el-col>
<el-col style="margin-left: 10px;width: 550px">
<el-button
type="primary"
icon="el-icon-search"
size="small"
plain
@click="pageCurrent=1;searchMaterial()">查询
</el-button>
<el-button :disabled="parseInt(token) !== 11 && parseInt(token) !== 36" type="distribution" style="margin-bottom: 3px;margin-top: 10px" icon="el-icon-circle-plus-outline" size="small" @click="handleAdd()">物料</el-button>
<el-button
:disabled="parseInt(token) !== 11 && parseInt(token) !== 36"
@@ -171,7 +171,7 @@
{{ scope.row.参考价格 }}
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="150">
<el-table-column label="操作" fixed="right" align="center" width="110">
<template slot-scope="scope">
<el-tooltip :open-delay="1000" effect="dark" content="编辑">
<div style="display: inline-block">
@@ -518,17 +518,17 @@
<el-table-column label="操作" fixed="right" align="center" width="150">
<template slot-scope="scope">
<div style="display: inline-block">
<el-button type="primary" plain size="small" @click="Tongguo(scope.row)">通过</el-button>
<el-button type="text" size="small" @click="Tongguo(scope.row)">通过</el-button>
</div>
<div style="display: inline-block">
<el-popover
placement="bottom"
width="400"
width="380"
trigger="click">
<span>打回原因</span>
<el-input v-model="打回原因" placeholder="打回原因" size="small" clearable/>
<el-button type="danger" size="small" @click="queren()">确认</el-button>
<el-button slot="reference" type="danger" plain size="small" @click="Dahui(scope.row)">打回</el-button>
<el-input v-model="打回原因" :autosize="{ minRows: 1, maxRows: 4}" placeholder="打回原因" size="small" type="textarea" style="width: 200px" clearable/>
<el-button type="danger" size="small" style="margin-left: 10px" @click="queren()">确认</el-button>
<el-button slot="reference" type="text" size="small" @click="Dahui(scope.row)">打回</el-button>
</el-popover>
</div>
</template>
@@ -884,8 +884,24 @@ export default {
})
},
handleDelete(row) { // 删除
this.deleteRow(deleteData, row.物料流水号, function() {
this.$confirm('删除该物料信息,将不可恢复,是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteData(row.物料流水号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
this.searchMaterial()
} else {
this.$message.error('删除失败')
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
CategoryMaintenance() {

View File

@@ -3,7 +3,7 @@
<el-card>
<el-table :data="tableData1" :cell-style="changeCellStyle" highlight-current-row height="810" style="width: 100%;" size="mini" border>
<el-table-column label="序号" type="index" align="center" width="50"/>
<el-table-column label="项目名称" align="center" width="200px">
<el-table-column label="机床名称" align="center" width="200px">
<template slot-scope="scope">
{{ scope.row.项目名称 }}
</template>
@@ -13,6 +13,11 @@
{{ scope.row.申请人姓名 }}
</template>
</el-table-column>
<el-table-column label="申请时间" align="center" width="80px">
<template slot-scope="scope">
{{ scope.row.操作时间.split(' ')[0] }}
</template>
</el-table-column>
<el-table-column label="原物料名称" align="center" min-width="150px">
<template slot-scope="scope">
{{ scope.row.原物料名称 }}
@@ -43,7 +48,7 @@
{{ scope.row.新物料型号 }}
</template>
</el-table-column>
<el-table-column label="审核" width="200px" align="center" fixed="right">
<el-table-column label="审核" width="150px" align="center" fixed="right">
<template slot-scope="scope">
<el-button
size="mini"

View File

@@ -1,7 +1,7 @@
<template>
<div>
<el-card>
<el-row style="width: 600px">
<el-card style="width: 580px">
<el-row style="width: 580px">
<el-input v-model="partNumber" placeholder="零件图号" style="width: 180px" size="small" clearable/>
<el-button icon="el-icon-search" type="primary" plain size="small" @click="pageCurrent = 1;pageSize = 10;getTableData()">查询</el-button>
<el-upload
@@ -18,7 +18,7 @@
</el-upload>
</el-row>
</el-card>
<el-card>
<el-card style="width: 580px">
<el-table v-loading="loading" :data="tableData" border size="mini" style="width: 555px;height: 700px" height="520">
<el-table-column label="序号" align="center" type="index" width="50"/>
<el-table-column label="零件图号" align="center" width="180px">
@@ -33,7 +33,7 @@
</el-table-column>
<el-table-column label="上传时间" align="center" width="150px">
<template slot-scope="scope">
{{ scope.row.上传时间 }}
{{ scope.row.上传时间.split(' ')[0] }}
</template>
</el-table-column>
<el-table-column width="80px" label="零件图纸" align="center">

View File

@@ -2,7 +2,7 @@
<div>
<div style="width: 100%;overflow:auto">
<div style="white-space: nowrap">
<el-card style="margin-left: 0px;width:820px; display: inline-block;">
<el-card style="margin-left: 0px;width:740px; display: inline-block;">
<el-col>
<el-input v-model="partDrawingNumber" placeholder="零件图号" size="small" clearable style="margin: 3px 0;width: 180px" @keyup.enter.native="searchTable1"/>
<el-tooltip :open-delay="1200" effect="dark" content="查询备料零件" placement="top">
@@ -18,7 +18,7 @@
border
stripe
highlight-current-row
style="width:795px ;margin-top:3px;"
style="width:720px ;margin-top:3px;"
height="690"
size="mini"
@sort-change="sortChange"
@@ -34,12 +34,12 @@
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column label="零件图号" prop="零件图号" min-width="120" width="180" align="center" show-overflow-tooltip>
<el-table-column label="零件图号" prop="零件图号" min-width="120" width="160" align="center" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.零件图号 }}
</template>
</el-table-column>
<el-table-column label="零件名称" prop="零件名称" width="140" sortable="custom" align="center" show-overflow-tooltip>
<el-table-column label="零件名称" prop="零件名称" width="120" sortable="custom" align="center" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.零件名称 }}
</template>
@@ -49,7 +49,7 @@
{{ scope.row.批次数量 }}
</template>
</el-table-column>
<el-table-column label="材料" prop="材料" width="150" sortable="custom" align="center" show-overflow-tooltip>
<el-table-column label="材料" prop="材料" width="120" sortable="custom" align="center" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.材料 }}
</template>
@@ -126,7 +126,7 @@
{{ scope.row.采购单号 }}
</template>
</el-table-column>
<el-table-column label="外购计划单名称" prop="采购单名称" align="center" width="160">
<el-table-column label="外购备料单名称" prop="采购单名称" align="center" width="160">
<template slot-scope="scope">
{{ scope.row.采购单名称 }}
</template>
@@ -342,13 +342,13 @@
</el-form>
<div slot="footer" class="dialog-footer">
<el-button
v-show="title2==='创建外购计划单'"
v-show="title2==='创建外购备料单'"
type="primary"
size="small"
icon="el-icon-check"
@click="submitAddPurchaseOrder">确定</el-button>
<el-button
v-show="title2==='编辑采购计划单'"
v-show="title2==='编辑外购备料单'"
type="primary"
size="small"
icon="el-icon-check"
@@ -682,7 +682,7 @@ export default {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
this.title2 = '创建外购计划单'
this.title2 = '创建外购备料单'
this.form2.supplierNameValue = ''
this.form2.供应商名称 = ''
this.form2.计划完成日期 = ''
@@ -715,7 +715,7 @@ export default {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
this.title2 = '编辑采购计划单'
this.title2 = '编辑外购备料单'
this.form2.采购计划流水号 = row.采购计划流水号
this.form2.采购单名称 = row.采购单名称
this.form2.supplierNameValue = row.供应商
@@ -772,6 +772,7 @@ export default {
var param = []
param[0] = ['采购计划流水号', row.采购计划流水号]
param[1] = ['供应商', row.供应商名称]
param[2] = ['采购单号', row.采购单号]
var Data = this.CreateData('2001', '报表_备料管理_采购计划明细_查询数据', param)
this.exportExcel_NPOI(Data)
} else {

View File

@@ -24,7 +24,7 @@
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-button type="primary" plain size="small" icon="el-icon-search" style="margin-left: 10px" @click="searchTable4()">查询</el-button>
<el-button class="button111" size="small" icon="el-icon-plus" style="margin-left: 10px" @click="addArrivalOrder">新增到货单</el-button>
<el-button class="button111" size="small" icon="el-icon-plus" style="margin-left: 10px" @click="addArrivalOrder">到货单</el-button>
<el-button type="success" plain size="small" icon="el-icon-download" style="margin-left:10px" @click="downloadExcel()">导出</el-button>
</div>
</el-card>
@@ -119,9 +119,9 @@
<el-button :disabled="disable === '1'" type="text" size="mini" icon="el-icon-circle-plus-outline" @click="addArrivalCL(scope.row)">备料材料</el-button>
</div>
</el-tooltip>
<el-tooltip :open-delay="1200" effect="dark" content="删除" placement="top">
<el-tooltip :open-delay="1200" effect="dark" content="取消关联" placement="top">
<div style="display: inline-block">
<el-button :disabled="disable === '1'" type="text" size="mini" style="margin-left: 20px" icon="el-icon-delete" @click="deleteArrivalMX(scope.row)"/>
<el-button :disabled="disable === '1'" type="text" size="mini" style="margin-left: 20px" icon="el-icon-circle-close" @click="deleteArrivalMX(scope.row)"/>
</div>
</el-tooltip>
</template>
@@ -188,7 +188,7 @@
<template slot-scope="scope">
<el-tooltip effect="dark" content="取消关联" placement="top">
<div style="display: inline-block">
<el-button :disabled="disable === '1'" type="text" icon="el-icon-delete" size="mini" @click="deleteMateriel(scope.row)"/>
<el-button :disabled="disable === '1'" type="text" icon="el-icon-circle-close" size="mini" @click="deleteMateriel(scope.row)"/>
</div>
</el-tooltip>
</template>
@@ -229,7 +229,7 @@
@click="submitEditArrivalOrder">确定</el-button>
</div>
</el-dialog>
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible10" title="添加到货明细" center style="min-height: 400px" width="1600px">
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible10" title="添加到货明细" center style="min-height: 200px" width="1600px">
<el-form ref="form10" :model="form10" :rules="rules10" label-position="right" label-width="60px">
<el-row style="background-color: white">
<el-col :span="5" style="margin-left: 2%">
@@ -282,7 +282,7 @@
</el-form-item>
</el-row>
<el-row style="height: 50px">
<el-form-item label="金额" prop="金额">
<el-form-item label="金额(元)" prop="金额">
<el-input-number v-model="form10.金额" :precision="2" :step="1" size="medium"/>
</el-form-item>
</el-row>
@@ -292,7 +292,7 @@
</div>
</div>
<div style="width: 79%;float: left;margin-left: 10px">
<el-table :row-key="getRowKeys" :data="tableData20" border show-summary highlight-current-row stripe style="margin: 3px 0" height="550px" size="mini" @selection-change="handleSelectionChange">
<el-table :row-key="getRowKeys" :data="tableData20" border show-summary highlight-current-row stripe style="margin: 3px 0" height="350px" size="mini" @selection-change="handleSelectionChange">
<el-table-column :reserve-selection="true" type="selection" width="50" align="center"/>
<el-table-column label="采购单号" align="center" width="120">
<template slot-scope="scope">
@@ -324,12 +324,12 @@
{{ scope.row.到货数量 }}
</template>
</el-table-column>
<el-table-column label="到货数" align="center" width="120px">
<el-table-column label="到货数" align="center" width="120px">
<template slot-scope="scope">
<el-input-number v-model="scope.row.未到货数量" :disabled="disable === '1'" :max="scope.row.采购数量-parseInt(scope.row.到货数量)" :step="1" :min="0" size="mini" style="width:95px" @change="saveData(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="到货重量" align="center" width="120px" prop="到货重量">
<el-table-column label="到货重量(KG)" align="center" width="120px" prop="到货重量">
<template slot-scope="scope">
<el-input-number v-model="scope.row.到货重量" :disabled="disable === '1'" :step="1" :min="0" size="mini" style="width:95px" @change="saveData(scope.row)"/>
</template>
@@ -339,11 +339,11 @@
{{ scope.row.成品尺寸 }}
</template>
</el-table-column>
<el-table-column label="单位" align="center" width="60px">
<template slot-scope="scope">
{{ scope.row.单位 ? scope.row.单位 : '-' }}
</template>
</el-table-column>
<!--<el-table-column label="单位" align="center" width="60px">-->
<!--<template slot-scope="scope">-->
<!--{{ scope.row.单位 ? scope.row.单位 : '-' }}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column label="备注" align="center">
<template slot-scope="scope">
{{ scope.row.备注1 }}
@@ -451,12 +451,12 @@
{{ scope.row.到货数量 }}
</template>
</el-table-column>
<el-table-column label="到货数" align="center" width="120px">
<el-table-column label="到货数" align="center" width="120px">
<template slot-scope="scope">
<el-input-number v-model="scope.row.未到货数量" :disabled="disable === '1'" :max="scope.row.采购数量-parseInt(scope.row.到货数量)" :step="1" :min="0" size="mini" style="width:95px" @change="saveData(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="到货重量" align="center" width="120px">
<el-table-column label="到货重量(KG)" align="center" width="120px">
<template slot-scope="scope">
<el-input-number v-model="scope.row.到货重量" :disabled="disable === '1'" :step="1" :min="0" size="mini" style="width:95px" @change="saveData(scope.row)"/>
</template>
@@ -1073,7 +1073,7 @@ export default {
})
},
deleteArrivalMX(row) {
this.$confirm('确定删除该到货单明细?', '提示', {
this.$confirm('确定取消该物料的到货信息?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'

View File

@@ -70,7 +70,7 @@
:value="item.value"/>
</el-select>
<el-button type="primary" size="small" plain icon="el-icon-search" style="margin-left: 10px" @click="searchTable()">查询</el-button>
<el-button type="distribution" size="small" plain icon="el-icon-circle-plus-outline" style="margin-left: 10px" @click="addPurchaseOrder">采购计划单</el-button>
<el-button type="distribution" size="small" plain icon="el-icon-circle-plus-outline" style="margin-left: 10px" @click="addPurchaseOrder">计划单</el-button>
<!--<el-tooltip :open-delay="1200" effect="dark" content="保存选中的采购计划单" placement="top">-->
<!--<el-button type="baocun" size="small" icon="el-icon-download" style="margin-left: 10px" @click="saveMateriel">保存采购计划单</el-button>-->
<!--</el-tooltip>-->
@@ -187,26 +187,26 @@
</div>
</div>
<div>
<el-card style="width: 1100px;margin: 10px auto">
<div id="WGBLD" style="width: 1000px;margin: 0 auto">
<el-card style="width: 1137px">
<div id="WGBLD" style="width: 1037px;margin: 0 auto">
<table cellspacing="0px" align="center" border="1 solid black" width="100%">
<tr style="height: 60px">
<th colspan="14"><h3>江苏高精机电装备有限公司</h3></th>
<th colspan="12"><h3>江苏高精机电装备有限公司</h3></th>
</tr>
<tr style="height: 40px">
<th colspan="14"><h4>{{ 采购单名称 }}</h4></th>
<th colspan="12"><h4>{{ 采购单名称 }}</h4></th>
</tr>
<tr style="height: 40px">
<td colspan="2" style="text-align: center;width: 15%">下单单位</td>
<td colspan="5" style="text-align: center;width: 35%">{{ 下单单位 }}</td>
<td colspan="4" style="text-align: center;width: 35%">{{ 下单单位 }}</td>
<td colspan="2" style="text-align: center;width: 15%">单号</td>
<td colspan="5" style="text-align: center;width: 35%">{{ 单号 }}</td>
<td colspan="4" style="text-align: center;width: 35%">{{ 单号 }}</td>
</tr>
<tr style="height: 40px">
<td colspan="2" style="text-align: center;width: 15%">下单日期</td>
<td colspan="5" style="text-align: center;width: 35%">{{ 下单日期 }}</td>
<td colspan="4" style="text-align: center;width: 35%">{{ 下单日期 }}</td>
<td colspan="2" style="text-align: center;width: 15%">计划完成日期</td>
<td colspan="5" style="text-align: center;width: 35%">{{ 计划完成日期 }}</td>
<td colspan="4" style="text-align: center;width: 35%">{{ 计划完成日期 }}</td>
</tr>
</table>
<table cellspacing="0px" align="center" border="1 solid black" width="100%" style="margin-top: 0px">
@@ -215,17 +215,15 @@
<td colspan="2" style="text-align: center;width: 20%">物料编码</td>
<td colspan="2" style="text-align: center;width: 10%">名称</td>
<td colspan="2" style="text-align: center;width: 10%">材料</td>
<td colspan="2" style="text-align: center;width: 8%">单位</td>
<td colspan="2" style="text-align: center;width: 8%">数量</td>
<td colspan="2" style="text-align: center;width: 20%">成品尺寸</td>
<td style="text-align: center;width: 17%">备注</td>
</tr>
<tr v-for="(list, index) in tableData4" :key="index" style="height: 35px">
<tr v-for="(list, index) in tableData3" :key="index" style="height: 35px">
<td style="text-align: center;width: 7%">{{ index + 1 }}</td>
<td colspan="2" style="text-align: center;width: 20%">{{ list.物料零件编码 }}</td>
<td colspan="2" style="text-align: center;width: 10%">{{ list.零件名称 }}</td>
<td colspan="2" style="text-align: center;width: 10%">{{ list.材料 }}</td>
<td colspan="2" style="text-align: center;width: 8%">{{ list.单位 }}</td>
<td colspan="2" style="text-align: center;width: 8%">{{ list.数量 }}</td>
<td colspan="2" style="text-align: center;width: 20%">{{ list.成品尺寸 }}</td>
<td style="text-align: center;width: 17%">{{ list.备注 }}</td>
@@ -234,6 +232,36 @@
<div style="margin-top: 20px">联系人:___________ 联系电话:___________ </div>
</div>
</el-card>
<el-dialog v-el-drag-dialog :title="title2" :visible.sync="dialogVisible2" center style="min-height: 300px" width="350px">
<el-form ref="form2" :model="form2" :rules="rules2" label-position="right" label-width="80px">
<el-form-item label="计划名称" prop="计划名称">
<el-input v-model="form2.离线采购计划名称" size="small"/>
</el-form-item>
<el-form-item label="供应商" prop="supplierNameValue">
<el-select v-model="form2.supplierNameValue" placeholder="供应商" size="small" filterable>
<el-option
v-for="item in supplierNames"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button
v-show="title2==='创建外购备料计划'"
type="primary"
size="small"
icon="el-icon-check"
@click="submitAddPurchaseOrder">确定</el-button>
<el-button
v-show="title2==='编辑外购备料计划'"
type="primary"
size="small"
icon="el-icon-check"
@click="submitEditPurchaseOrder">确定</el-button>
</div>
</el-dialog>
</div>
</div>
</template>
@@ -279,7 +307,7 @@ export default {
离线采购计划流水号: ''
},
rules2: {
离线采购计划名称: [{ required: true, message: '请填写离线采购计划名称' }],
计划名称: [{ required: true, message: '请填写离线采购计划名称' }],
supplierNameValue: [{ required: true, message: '请选择供应商' }]
},
form3: {
@@ -483,7 +511,7 @@ export default {
}
this.form2.离线采购计划名称 = ''
this.form2.supplierNameValue = ''
this.title2 = '创建离线采购计划'
this.title2 = '创建外购备料计划'
this.dialogVisible2 = true
},
submitAddPurchaseOrder() { // 新建采购单
@@ -491,10 +519,10 @@ export default {
if (valid) {
addPurchaseOrder(this.form2.离线采购计划名称, this.form2.supplierNameValue).then(response => {
if (response.data[0].result === '1') {
this.$message.success('新建离线采购计划成功')
this.$message.success('新建离线外购备料成功')
this.searchTable()
this.dialogVisible2 = false
} else { this.$message.error('新建离线采购计划失败') }
} else { this.$message.error('新建离线外购备料失败') }
})
} else {
return false
@@ -505,7 +533,7 @@ export default {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
this.title2 = '编辑离线采购计划'
this.title2 = '编辑外购备料计划'
this.form2.离线采购计划流水号 = row.离线采购计划流水号
this.form2.离线采购计划名称 = row.离线采购计划名称
this.form2.supplierNameValue = row.供应商流水号
@@ -516,10 +544,10 @@ export default {
if (valid) {
editPurchaseOrder(this.form2.离线采购计划流水号, this.form2.离线采购计划名称, this.form2.supplierNameValue).then(response => {
if (response.data[0].result === '1') {
this.$message.success('修改离线采购计划成功')
this.$message.success('修改离线外购备料成功')
this.searchTable()
this.dialogVisible2 = false
} else { this.$message.error('修改离线采购计划失败') }
} else { this.$message.error('修改离线外购备料失败') }
})
} else {
return false
@@ -547,7 +575,7 @@ export default {
},
submitAddMaterial() {
if (!this.离线采购计划流水号) {
this.$message.warning('请选择离线采购计划')
this.$message.warning('请选择外购备料计划')
} else if (this.materielGroup.length === 0) {
this.$message.warning('请勾选物料')
} else {
@@ -642,6 +670,25 @@ export default {
.el-tag{
margin: 0
}
.el-form--label-left >>> .el-form-item__label {
text-align: right;
}
>>>.el-dialog--center .el-dialog__body {
text-align: initial;
padding: 20px 30px 20px
}
>>>.el-dialog__header {
padding: 20px 20px 0px;
}
>>>.el-dialog__footer {
padding: 0px 20px 20px;
/*text-align: right;*/
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
>>>.el-form-item {
margin-bottom: 13px;
}
</style>
<style lang="scss">
.button111{

View File

@@ -193,7 +193,7 @@
<el-date-picker v-model="form1.invoiceTime" size="small" type="date" value-format="yyyy-MM-dd" format="yyyy-MM-dd" placeholder="选择日期"/>
</el-form-item>
<el-form-item label="到票金额(元)" prop="money">
<el-input v-positive="'float'" v-model="form1.money" type="float" size="small" placeholder="开票金额"/>
<el-input v-positive="'float'" v-model="form1.money" type="number" class="editWorkTime" size="small" placeholder="开票金额" @change="Keeptwodecimalplaces"/>
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form1.remark" size="small"/>
@@ -245,7 +245,7 @@
<el-date-picker v-model="form1.invoiceTime" size="small" type="date" value-format="yyyy-MM-dd" format="yyyy-MM-dd" placeholder="选择日期"/>
</el-form-item>
<el-form-item label="到票金额(元)" prop="money">
<el-input v-positive="'float'" v-model="form1.money" type="float" size="small" placeholder="开票金额"/>
<el-input v-positive="'float'" v-model="form1.money" type="number" class="editWorkTime" size="small" placeholder="开票金额" @change="Keeptwodecimalplaces"/>
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form1.remark" size="small"/>
@@ -257,7 +257,7 @@
</div>
</el-dialog>
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible" title="关联到货单" center style="min-height: 200px" width="35%">
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible" title="关联到货单" center style="min-height: 200px" width="25%">
<el-table v-loading="" :data="tableData4" border stripe style="max-height: 460px;" height="230px" size="mini" highlight-current-row @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/>
<el-table-column label="到货单编号" align="center">
@@ -276,8 +276,8 @@
</template>
</el-table-column>
</el-table>
<span>合计<el-input v-model="SUM" size="mini" style="width: 80px; margin: 10px 10px 0 10px"/></span>
<el-button type="primary" size="small" icon="el-icon-download" style="float:right;margin: 10px 10px 0 10px" @click="addMateriel">关联到货单</el-button>
<span>合计<el-input v-positive="'float'" v-model="SUM" size="mini" type="number" style="width: 80px; margin: 10px 10px 0 10px" @change="Keeptwodecimalplaces"/></span>
<el-button type="primary" size="small" icon="el-icon-download" style="float:right;margin: 10px 10px 0 10px" @click="addMateriel">货票关联</el-button>
</el-dialog>
</div>
</template>
@@ -377,6 +377,10 @@ export default {
this.searchTable1()
},
methods: {
Keeptwodecimalplaces() {
this.form1.money = Number(this.form1.money).toFixed(2)
this.SUM = this.SUM * 1.00
},
getSummaries(param) { // 合计
const { columns, data } = param
const sums = []
@@ -513,7 +517,7 @@ export default {
this.dialogVisible2 = true
this.form1.invoiceNumValue = row.发票流水号
this.form1.invoiceTime = row.开票时间
this.form1.money = row.开票金额
this.form1.money = row.开票金额.toFixed(2)
this.form1.Number = row.发票号
this.form1.remark = row.备注
this.form1.supplierNameValue = parseInt(row.供应商)
@@ -567,8 +571,9 @@ export default {
handleSelectionChange(val) {
this.SUM = 0
for (let i = 0; i < val.length; i++) {
this.SUM += parseFloat(val[i].到货金额).toFixed(2)
this.SUM += parseFloat(val[i].到货金额)
}
console.log(this.SUM, 11)
this.arrest = val
},
// 选入
@@ -708,6 +713,14 @@ function saveAs(blob, filename = '下载文件.xls') {
margin-top: 1px;
margin-bottom: 1px;
}
.editWorkTime input::-webkit-outer-spin-button, input::-webkit-inner-spin-button {
-webkit-appearance: none;
text-align: center;
}
.editWorkTime input[type="number"]{
-moz-appearance: textfield;
text-align: center;
}
</style>
<style lang="scss">
.subTableHeader {
@@ -725,6 +738,13 @@ function saveAs(blob, filename = '下载文件.xls') {
background-color: #e9f0f9;
}
}
.editWorkTime input::-webkit-outer-spin-button, input::-webkit-inner-spin-button {
-webkit-appearance: none;
text-align: center;
}
.editWorkTime input[type="number"]{
-moz-appearance: textfield;
}
</style>
<style lang="scss">
.button111{

View File

@@ -2,7 +2,7 @@
<div class="app-container">
<div style="width: 100%;overflow:auto">
<div style="white-space: nowrap">
<el-card style="width: 1663px">
<el-card style="width: 1545px">
<el-col>
<el-input v-model="supplierName0" placeholder="供应商" style="width: 220px" size="small" clearable/>
<el-date-picker
@@ -40,13 +40,14 @@
:data="tableData1"
:row-key="getRowKeys"
:expand-row-keys="expands"
:summary-method="getSummaries1"
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
show-summary
border
stripe
style="margin-top: 3px;"
height="600px"
size="mini"
show-summary
highlight-current-row
@row-click="searchTable02">
<el-table-column label="供应商" prop="供应商名称" align="center" min-width="180" width="350" show-overflow-tooltip>
@@ -115,7 +116,7 @@
@current-change="handleCurrentChange1"/>
</div>
</el-card>
<el-card style="margin-left: 0px;width:524px; margin-left: 1px; display: inline-block;vertical-align: top">
<el-card style="margin-left: 0px;width:405px; margin-left: 1px; display: inline-block;vertical-align: top">
<el-table :data="gridData" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" :summary-method="getSummaries" border class="subTableHeader" size="mini" show-summary style="">
<el-table-column width="50" align="center" type="index" label="序号"/>
<el-table-column width="120" align="center" label="发票号">
@@ -123,12 +124,12 @@
{{ scope.row.发票号 }}
</template>
</el-table-column>
<el-table-column width="170" align="center" label="供应商" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.供应商名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="到票金额(元)" width="90px" prop="到票金额">
<!--<el-table-column width="170" align="center" label="供应商" show-overflow-tooltip>-->
<!--<template slot-scope="scope">-->
<!--{{ scope.row.供应商名称 }}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column align="center" label="到票金额(元)" width="120px" prop="到票金额">
<template slot-scope="scope">
{{ scope.row.开票金额.toFixed(2) }}
</template>
@@ -255,7 +256,7 @@ export default {
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '合计'
} else if (index === 3) {
} else if (index === 2) {
const values = data.map(item => Number(parseFloat(item['开票金额'])))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
@@ -274,6 +275,31 @@ export default {
})
return sums
},
getSummaries1(param) { // 合计
const { columns, data } = param
const sums = []
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '合计'
} else if (index === 3) {
const values = data.map(item => Number(parseFloat(item['请款金额'])))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] = sums[index].toFixed(2) + ' 元'
} else {
sums[index] = 'N/A'
}
}
})
return sums
},
exportExcel() {
this.dateRange ? this.check1 = 1 : (this.check1 = 0, this.dateRange = '')
this.supplierName0 ? this.check2 = 1 : (this.check2 = 0, this.supplierName0 = '')

View File

@@ -34,6 +34,7 @@ import { searchUrgentItem } from '@/api/ManufacturingCenter/InitialProduction'
import { searchTable1 as searchTableInvoice } from '@/api/PurchasingCenter/InvoiceSettlementApprove'
import { searchRequestFund } from '@/api/PurchasingCenter/PurchaseContractRequestFund'
import { getPickingList, setPickingList } from '@/api/Inventory/MaterialOut'
import { searchTable } from '@/api/PurchasingCenter/PurchaseMaterielModify'
export default {
components: {
Breadcrumb,
@@ -48,6 +49,7 @@ export default {
noticeContract4: null,
noticeContract5: null,
noticeContract6: null,
noticeContract7: null,
noticeContractJJ: null,
noticeFund: null,
noticeInvoice: null,
@@ -71,6 +73,8 @@ export default {
} else if (this.token.toString() === '11' || this.token.toString() === '12') {
this.comfirmMaterial()
this.timer = setInterval(this.comfirmMaterial, 1000 * 60 * 5)
this.comfirmMaterial_Update()
this.timer = setInterval(this.comfirmMaterial_Update, 1000 * 60 * 5)
} else if (this.token.toString() === '2' || this.token.toString() === '3') {
this.comfirmMaterial_CG()
this.timer = setInterval(this.comfirmMaterial_CG, 1000 * 60 * 5)
@@ -79,7 +83,7 @@ export default {
this.timer = setInterval(this.comfirmMaterial_KG, 1000 * 60 * 5)
} else if (this.token.toString() === '5') {
this.comfirmUrgentItem()
this.timer = setInterval(this.comfirmUrgentItem, 1000 * 60)
this.timer = setInterval(this.comfirmUrgentItem, 1000 * 60 * 5)
}
},
beforeDestroy() {
@@ -189,6 +193,22 @@ export default {
}
})
},
comfirmMaterial_Update() {
searchTable().then(res => {
if (res.data.length) {
this.noticeContract7 = null
this.noticeContract7 = this.$notify.success({
title: '提示',
message: '您有采购物料更改申请待审批,请及时处理,点击查看',
onClick: () => {
this.$router.push({ path: '/PurchasingCenter/PurchaseMaterielModify' })
setTimeout(this.noticeContract7.close(), 1000)
},
duration: 1000 * 60
})
}
})
},
checkApproval() {
searchTable1(1, 999, 0, null, null, 0, 0, 0, 0, 0, 0).then(res => {
if (res.data.total) {