This commit is contained in:
liushuai
2020-03-12 22:20:08 +08:00
parent 296df85e78
commit 1a3012d5a6
17 changed files with 406 additions and 420 deletions

View File

@@ -25,7 +25,7 @@ export function searchTable(check, supplierNameValue, check1, MaterialsValue, ch
UserID: state.state.user.id, UserID: state.state.user.id,
ModularID: router.currentRoute.path, ModularID: router.currentRoute.path,
type: '1', type: '1',
name: '车间生产管理_外协零件_查询数据', name: '车间生产管理_外协零件_查询数据_新',
param: '外协厂家_check=' + check + '&外协厂家=' + supplierNameValue + '&外协状态_check=' + check1 + '&外协状态=' + MaterialsValue + '&时间_check=' + check2 + '&开始时间=' + time1 + '&结束时间=' + time2, param: '外协厂家_check=' + check + '&外协厂家=' + supplierNameValue + '&外协状态_check=' + check1 + '&外协状态=' + MaterialsValue + '&时间_check=' + check2 + '&开始时间=' + time1 + '&结束时间=' + time2,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
@@ -40,7 +40,7 @@ export function getExport(check, supplierNameValue, check1, MaterialsValue, chec
UserID: state.state.user.id, UserID: state.state.user.id,
ModularID: router.currentRoute.path, ModularID: router.currentRoute.path,
type: '1', type: '1',
name: '车间生产管理_外协零件_查询数据', name: '车间生产管理_外协零件_查询数据_新',
param: '外协厂家_check=' + check + '&外协厂家=' + supplierNameValue + '&外协状态_check=' + check1 + '&外协状态=' + MaterialsValue + '&时间_check=' + check2 + '&开始时间=' + time1 + '&结束时间=' + time2 param: '外协厂家_check=' + check + '&外协厂家=' + supplierNameValue + '&外协状态_check=' + check1 + '&外协状态=' + MaterialsValue + '&时间_check=' + check2 + '&开始时间=' + time1 + '&结束时间=' + time2
} }
}) })

View File

@@ -3,7 +3,7 @@ import state from '@/store'
import router from '@/router' import router from '@/router'
// 查询表格数据 // 查询表格数据
export function searchtable(check1, ManufacturerAbbreviation, check2, starttime, endTime, pageCurrent, pageSize) { export function searchtable(check1, ManufacturerAbbreviation, check2, starttime, endTime) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
@@ -12,8 +12,7 @@ export function searchtable(check1, ManufacturerAbbreviation, check2, starttime,
ModularID: router.currentRoute.path, ModularID: router.currentRoute.path,
type: '1', type: '1',
name: '车间生产管理工艺_外协付款_查询', name: '车间生产管理工艺_外协付款_查询',
param: '外协厂家_check=' + check1 + '&外协厂家=' + ManufacturerAbbreviation + '&时间_check=' + check2 + '&开始时间=' + starttime + '&结束时间=' + endTime, param: '外协厂家_check=' + check1 + '&外协厂家=' + ManufacturerAbbreviation + '&时间_check=' + check2 + '&开始时间=' + starttime + '&结束时间=' + endTime
Pagination: pageCurrent + '&' + pageSize
} }
}) })
} }

View File

@@ -24,22 +24,22 @@
<el-card style="width: 49.5%; float: left"> <el-card style="width: 49.5%; float: left">
<el-table v-loading="listLoading1" :data="tableData1" stripe size="mini" style="width: 100%" highlight-current-row border height="730"> <el-table v-loading="listLoading1" :data="tableData1" stripe size="mini" style="width: 100%" highlight-current-row border height="730">
<el-table-column align="center" label="零件名称" prop="零件名称" width="150px"> <el-table-column align="center" label="零件名称" prop="零件名称" width="110px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.零件名称 }} {{ scope.row.零件名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="零件图号" prop="零件图号" min-width="150px"> <el-table-column align="center" label="零件图号" prop="零件图号" min-width="120px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.零件图号 }} {{ scope.row.零件图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="入库数" width="70px"> <el-table-column align="center" label="入库数" width="65px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.入库数量 }} {{ scope.row.入库数量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="机床图号" prop="机床图号" width="120px"> <el-table-column align="center" label="机床图号" prop="机床图号" width="90px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床图号 }} {{ scope.row.机床图号 }}
</template> </template>
@@ -49,12 +49,12 @@
{{ scope.row.组号 }} {{ scope.row.组号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="货位名称" prop="货位名称" width="100px"> <el-table-column align="center" label="货位名称" prop="货位名称" width="80px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.货位名称 }} {{ scope.row.货位名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="入库时间" prop="入库时间" width="100px"> <el-table-column align="center" label="入库时间" prop="入库时间" width="90px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.入库时间 ? scope.row.入库时间.split(' ')[0] : '-' }} {{ scope.row.入库时间 ? scope.row.入库时间.split(' ')[0] : '-' }}
</template> </template>

View File

@@ -25,6 +25,7 @@
<el-radio v-model="radio" label="2" style="margin: 0 0 0 10px">通过</el-radio> <el-radio v-model="radio" label="2" style="margin: 0 0 0 10px">通过</el-radio>
<el-radio v-model="radio" label="3" style="margin: 0 0 0 10px">未过</el-radio> <el-radio v-model="radio" label="3" style="margin: 0 0 0 10px">未过</el-radio>
<el-button type="primary" plain size="small" icon="el-icon-search" style="margin-left: 10px" @click="total1=0;pageCurrent1=1;pageSize1=50;searchTable1()">查询</el-button> <el-button type="primary" plain size="small" icon="el-icon-search" style="margin-left: 10px" @click="total1=0;pageCurrent1=1;pageSize1=50;searchTable1()">查询</el-button>
<el-button type="success" size="small" icon="el-icon-download" style="margin-left:10px;margin-top: 3px;margin-right: 20px;float: right" plain @click="exportTable('')">导出</el-button>
</el-card> </el-card>
<el-card style="margin-top: 5px"> <el-card style="margin-top: 5px">
<el-table v-loading="loading1" :data="tableData1" size="mini" border stripe style="width: 100%" height="600px" highlight-current-row @row-click="searchTable2"> <el-table v-loading="loading1" :data="tableData1" size="mini" border stripe style="width: 100%" height="600px" highlight-current-row @row-click="searchTable2">
@@ -48,34 +49,29 @@
{{ scope.row.合同总额 }} {{ scope.row.合同总额 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="预付款(元)" align="center" min-width="60"> <el-table-column label="交货日期" align="center" min-width="60">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.预付款 }} {{ scope.row.交货日期 }}
</template>
</el-table-column>
<el-table-column label="规定到货时间" align="center" min-width="60">
<template slot-scope="scope">
{{ scope.row.规定到货时间 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="提交时间" align="center" min-width="60"> <el-table-column label="提交时间" align="center" min-width="60">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.提交时间 }} {{ scope.row.操作时间 ? scope.row.操作时间.split(' ')[0] : '' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="审核时间" align="center" min-width="60"> <el-table-column label="审核时间" align="center" min-width="60">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.审核时间 }} {{ scope.row.审核时间 ? scope.row.审核时间.split(' ')[0] : '' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="审核人" align="center" min-width="60"> <el-table-column label="审核人" align="center" min-width="60">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.审核人 }} {{ scope.row.姓名 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="审核结果" align="center" min-width="60"> <el-table-column label="审核结果" align="center" min-width="60">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.审核结果 }} {{ scope.row.审核情况内容 }}
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -147,6 +143,28 @@ export default {
this.total1 = response.data.total this.total1 = response.data.total
}) })
}, },
exportTable() {
var check1, check2, check3
this.billNames ? check1 = 1 : check1 = 0
this.dateRange ? check2 = 1 : (check2 = 0, this.dateRange = '')
this.personValue ? check3 = 1 : check3 = 0
var param = []
param[0] = ['查询全部', this.radio]
param[1] = ['供应商名称_check', check1]
param[2] = ['供应商名称', this.billNames]
param[3] = ['时间段_check', check2]
if (check2 === 0) {
param[4] = ['开始时间', '']
param[5] = ['结束时间', '']
} else {
param[4] = ['开始时间', this.dateRange[0]]
param[5] = ['结束时间', this.dateRange[1]]
}
param[6] = ['人员编号_check', check3]
param[7] = ['人员编号', this.personValue]
var Data = this.CreateData('2001', '报表_采购管理_合同审核查询_查询数据', param)
this.exportExcel_NPOI(Data)
},
searchTable2(row) { searchTable2(row) {
this.contractValue = parseInt(row.采购合同流水号) this.contractValue = parseInt(row.采购合同流水号)
searchTable2(this.contractValue).then(response => { searchTable2(this.contractValue).then(response => {

View File

@@ -131,7 +131,7 @@
</el-col> </el-col>
</el-row> </el-row>
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible" title="工序完成情况" center width="550px"> <el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible" title="工序完成情况" center width="650px">
<el-row> <el-row>
<span>零件图号:</span> <span>零件图号:</span>
<el-input v-model="SparePartsNumber" style="width: 150px" size="small"/> <el-input v-model="SparePartsNumber" style="width: 150px" size="small"/>
@@ -140,13 +140,13 @@
</el-row> </el-row>
<el-table <el-table
:data="tableData2" :data="tableData2"
style="width: 515px;margin-top: 20px" style="width: 615px;margin-top: 20px"
size="mini" size="mini"
height="320" height="320"
stripe stripe
highlight-current-row highlight-current-row
border> border>
<el-table-column align="center" label="工序顺序" width="70"> <el-table-column align="center" label="工序" width="70">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.工序顺序 }} {{ scope.row.工序顺序 }}
</template> </template>
@@ -156,7 +156,7 @@
{{ scope.row.工艺名称 }} {{ scope.row.工艺名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="工艺要求" width="100"> <el-table-column align="center" label="工艺要求" width="205">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.工艺要求 }} {{ scope.row.工艺要求 }}
</template> </template>
@@ -168,16 +168,16 @@
</el-table-column> </el-table-column>
<el-table-column align="center" label="工序完成" width="80"> <el-table-column align="center" label="工序完成" width="80">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.工序状态)===4" type="success" size="small">已完</el-tag> <el-tag v-if="parseInt(scope.row.工序状态)===4" type="success" size="small">已完</el-tag>
<el-tag v-if="parseInt(scope.row.工序状态)===5" type="warning" size="small">报废</el-tag> <el-tag v-if="parseInt(scope.row.工序状态)===5" type="warning" size="small">报废</el-tag>
<el-tag v-if="parseInt(scope.row.工序状态)!==4 && parseInt(scope.row.工序状态)!==5" type="primary" size="small">未完</el-tag> <el-tag v-if="parseInt(scope.row.工序状态)!==4 && parseInt(scope.row.工序状态)!==5" type="primary" size="small">未完</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="工序质检" width="80"> <el-table-column align="center" label="工序质检" width="80">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.是否质检)===1" type="success" size="small">合格</el-tag> <el-tag v-if="parseInt(scope.row.是否质检)===1" type="success" size="small">合格</el-tag>
<el-tag v-if="parseInt(scope.row.是否质检)===2" type="warning" size="small">不合格</el-tag> <el-tag v-if="parseInt(scope.row.是否质检)===2" type="warning" size="small">不合格</el-tag>
<el-tag v-if="parseInt(scope.row.是否质检)!==1 && parseInt(scope.row.是否质检)!==2" type="primary" size="small">未检</el-tag> <el-tag v-if="parseInt(scope.row.是否质检)!==1 && parseInt(scope.row.是否质检)!==2" type="primary" size="small">未检</el-tag>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

View File

@@ -32,7 +32,12 @@
<!--{{ scope.row.计划总工时 }}--> <!--{{ scope.row.计划总工时 }}-->
<!--</template>--> <!--</template>-->
<!--</el-table-column>--> <!--</el-table-column>-->
<el-table-column label="完成工时(分)" align="center" width="70px"> <el-table-column label="完成数量" align="center" width="80px">
<template slot-scope="scope">
{{ scope.row.总数量 }}
</template>
</el-table-column>
<el-table-column label="加工工时(分)" align="center" width="110px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.完成总工时 }} {{ scope.row.完成总工时 }}
</template> </template>
@@ -42,12 +47,7 @@
<!--{{ scope.row.修补准结总工时 }}--> <!--{{ scope.row.修补准结总工时 }}-->
<!--</template>--> <!--</template>-->
<!--</el-table-column>--> <!--</el-table-column>-->
<el-table-column label="完成数量" align="center" width="70px"> <el-table-column label="扫码工时(分)" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.总数量 }}
</template>
</el-table-column>
<el-table-column label="扫码工时(分)" align="center" width="70px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.扫码总工时 }} {{ scope.row.扫码总工时 }}
</template> </template>
@@ -76,12 +76,12 @@
{{ scope.row.零件名称 }} {{ scope.row.零件名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="工艺名称" align="center" width="70px" show-overflow-tooltip> <el-table-column label="工艺名称" align="center" width="80px" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.工艺名称 }} {{ scope.row.工艺名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="完成数" align="center" width="60px"> <el-table-column label="完成数" align="center" width="80px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.完成数量 }} {{ scope.row.完成数量 }}
</template> </template>
@@ -91,7 +91,7 @@
<!--{{ scope.row.计划工时 }}--> <!--{{ scope.row.计划工时 }}-->
<!--</template>--> <!--</template>-->
<!--</el-table-column>--> <!--</el-table-column>-->
<el-table-column label="完成工时(分)" align="center" width="70px"> <el-table-column label="加工工时(分)" align="center" width="110px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.完成工时 }} {{ scope.row.完成工时 }}
</template> </template>
@@ -101,16 +101,16 @@
<!--{{ scope.row.修补准结工时 }}--> <!--{{ scope.row.修补准结工时 }}-->
<!--</template>--> <!--</template>-->
<!--</el-table-column>--> <!--</el-table-column>-->
<el-table-column label="加工时间" align="center" width="115px"> <el-table-column label="扫码工时(分)" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.完成日期 }}
</template>
</el-table-column>
<el-table-column label="扫码工时(分)" align="center" width="70px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.扫码工时 }} {{ scope.row.扫码工时 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="完成日期" align="center" width="115px">
<template slot-scope="scope">
{{ scope.row.完成日期 }}
</template>
</el-table-column>
</el-table> </el-table>
<div> <div>
<el-pagination <el-pagination

View File

@@ -73,7 +73,7 @@
<el-divider content-position="right">生命周期</el-divider> <el-divider content-position="right">生命周期</el-divider>
<div class="text item"> <div class="text item">
<el-row> <el-row>
<el-col :span="3"> <el-col :span="4">
<el-timeline style="margin-top: 40px"> <el-timeline style="margin-top: 40px">
<el-timeline-item <el-timeline-item
v-for="(activity, index) in activities" v-for="(activity, index) in activities"
@@ -90,84 +90,51 @@
<el-col :span="1"> <el-col :span="1">
<div style="width:1px;border:0.1px solid #DCDFE6;float:left;height:450px;"/> <div style="width:1px;border:0.1px solid #DCDFE6;float:left;height:450px;"/>
</el-col> </el-col>
<el-col :span="20" style="margin-top: 30px"> <el-col :span="19" style="margin-top: 30px">
<div class="main"> <div class="main">
<div v-show="show" style="line-height: 130px;text-align: center"> <el-table :data="tableData1" :row-class-name="tableRowClassName1" class="table" style="max-height: 830px" highlight-current-row empty-text=" " border>
<div> <el-table-column align="center" label="工序" show-overflow-tooltip width="100">
请查询 <template slot-scope="scope">
</div> {{ scope.row.工序顺序 }}
</div> </template>
<div class="sudoku_row" > </el-table-column>
<div v-for="(sudoku,index) in sudokus" :class="curSelect==sudoku.id?'opacity':''" :key="index" class="sudoku_item " @touchstart="touchstart(index)" @touchend="touchend"> <el-table-column align="center" label="工艺名" show-overflow-tooltip min-width="120">
<div class="text"> <template slot-scope="scope">
{{ sudoku.id }} {{ scope.row.工艺名称 }}
</div> </template>
<div :style="{width: '100px',height: '100px',border: '1px solid grey','text-align': 'center', 'background-color': sudoku.color}" class="text"> </el-table-column>
<el-row style="margin-top: 10px"> <!--<el-table-column align="center" label="已完数量" show-overflow-tooltip min-width="70">-->
<div style="height: 20px"> <!--<template slot-scope="scope">-->
{{ sudoku.procedure }} <!--{{ scope.row.完成数量 }}-->
</div> <!--</template>-->
</el-row> <!--</el-table-column>-->
<el-row style="margin-top: 2px"> <el-table-column align="center" label="投产数" width="100">
<div style="height: 20px"> <template slot-scope="scope">
{{ sudoku.planningTime }} {{ scope.row.批次数量 }}
</div> </template>
</el-row> </el-table-column>
<el-row style="margin-top: 2px"> <el-table-column align="center" label="完成数" width="100">
<div style="height: 20px"> <template slot-scope="scope">
{{ sudoku.actualTime }} {{ scope.row.完成数量 }}
</div> </template>
</el-row> </el-table-column>
<el-row style="margin-top: 2px"> <el-table-column align="center" label="操作者" show-overflow-tooltip width="120">
<div style="height: 20px"> <template slot-scope="scope">
{{ sudoku.name }} {{ scope.row.操作者 }}
</div> </template>
</el-row> </el-table-column>
</div> <el-table-column align="center" label="扫码开始" width="160">
</div> <template slot-scope="scope">
</div> {{ scope.row.加工开始时间 }}
</template>
</el-table-column>
<el-table-column align="center" label="加工完成" width="160">
<template slot-scope="scope">
{{ scope.row.完成日期 }}
</template>
</el-table-column>
</el-table>
</div> </div>
<el-row :gutter="20" style="margin-top: 50px">
<el-col :span="11">
<div style="width: 100%;height: 200px;border: 1px solid #DCDFE6">
<el-row style="margin-top: 15px;margin-right: 15px">
<span style="float: right">备料信息</span>
</el-row>
<el-row style="margin-top: 30px;margin-left: 10px">
<span style="width:80px;margin-left: 10px">备料单<el-tag size="small" type="success">{{ isMaterials }}</el-tag></span>
<span style="width:80px;margin-left: 20px">备料类型<el-tag size="small" type="success">{{ materialsType }}</el-tag></span>
<span style="width:80px;margin-left: 20px">下料员<el-tag size="small" type="success">{{ Cutter }}</el-tag></span>
<span style="width:80px;margin-left: 20px">确认日期<el-tag size="small" type="success">{{ confirmationTime }}</el-tag></span>
</el-row>
<el-row style="margin-top: 30px;margin-left: 30px">
<el-steps :space="200" :active="active" finish-status="success">
<el-step title="创建备料"/>
<el-step title="备料确认"/>
</el-steps>
</el-row>
</div>
</el-col>
<el-col :span="11">
<div style="width: 100%;height: 200px;border: 1px solid #DCDFE6">
<el-row style="margin-top: 15px;margin-right: 15px">
<span style="float: right">外协信息</span>
</el-row>
<el-row style="margin-top: 30px;margin-left: 10px">
<span style="width:80px;margin-left: 10px">是否序间外协<el-tag size="small" type="success">{{ isOut }}</el-tag></span>
<span style="width:80px;margin-left: 20px">外协工序<el-tag size="small" type="success">{{ outName }}</el-tag></span>
<span style="width:80px;margin-left: 20px">检验日期<el-tag size="small" type="success">{{ outTime }}</el-tag></span>
</el-row>
<el-row style="margin-top: 30px;margin-left: 30px;margin-right: 30px">
<el-steps :active="active1" finish-status="success">
<el-step title="序间外协"/>
<el-step title="价格预算"/>
<el-step title="任务执行"/>
<el-step title="到货质检"/>
</el-steps>
</el-row>
</div>
</el-col>
</el-row>
</el-col> </el-col>
</el-row> </el-row>
<el-divider content-position="right">跳转链接</el-divider> <el-divider content-position="right">跳转链接</el-divider>
@@ -187,7 +154,9 @@
</template> </template>
<script> <script>
import { SelectPart, SelectProcessingProgress, SelectPreparation, SelectOut } from '@/api/ManufacturingCenter/TraceabilityOfParts' import { SelectPart, SelectProcessingProgress } from '@/api/ManufacturingCenter/TraceabilityOfParts'
import { gettabledata1 } from '@/api/ManufacturingCenter/ProcessingStatusNew'
export default { export default {
data() { data() {
return { return {
@@ -202,6 +171,7 @@ export default {
searchPick: '', searchPick: '',
materialsType: '请查询', materialsType: '请查询',
restaurantsPick: [], restaurantsPick: [],
tableData1: [],
show: true, show: true,
show1: false, show1: false,
// typeA: true, // typeA: true,
@@ -343,6 +313,13 @@ export default {
} }
this.show = true this.show = true
}, },
// 工序状态变色
tableRowClassName1({ row, rowIndex }) {
row.index = rowIndex
if (parseInt(row.工序状态) > 3) {
return 'CompleteColor'
}
},
handleSelect(item) { handleSelect(item) {
this.sudokus = [] this.sudokus = []
this.show = false this.show = false
@@ -377,41 +354,6 @@ export default {
}) })
} }
}) })
SelectPreparation(item.name).then(response => {
if (response.data.length !== 0) {
if (response.data[0].类型.toString() === '0') {
this.isMaterials = '未创建'
this.materialsType = '未创建'
this.Cutter = '未创建'
this.confirmationTime = '未创建'
this.active = '0'
} else if (response.data[0].类型.toString() === '1') {
this.isMaterials = '已创建'
this.materialsType = '自家备料'
this.Cutter = '未确认'
this.confirmationTime = '未确认'
this.active = '1'
} else if (response.data[0].类型.toString() === '2') {
this.isMaterials = '已创建'
this.materialsType = '外购备料'
this.Cutter = '未确认'
this.confirmationTime = '未确认'
this.active = '1'
} else if (response.data[0].类型.toString() === '3') {
this.isMaterials = '已创建'
this.materialsType = '自家备料'
this.active = '2'
response.data[0].下料员 !== null && response.data[0].下料员 !== '' ? this.Cutter = response.data[0].下料员 : this.Cutter = '未确认'
response.data[0].确认时间 !== null && response.data[0].确认时间 !== '' ? this.confirmationTime = response.data[0].确认时间.substring(0, 10) : this.confirmationTime = '未确认'
} else if (response.data[0].类型.toString() === '4') {
this.isMaterials = '已创建'
this.materialsType = '外购备料'
this.active = '2'
response.data[0].下料员 !== null && response.data[0].下料员 !== '' ? this.Cutter = response.data[0].下料员 : this.Cutter = '未确认'
response.data[0].确认时间 !== null && response.data[0].确认时间 !== '' ? this.confirmationTime = response.data[0].确认时间.substring(0, 10) : this.confirmationTime = '未确认'
}
}
})
SelectPart(0, '', 0, '', 0, '', 1, this.searchPick, 0, '', 0, '', 0, '', '', '', '').then(response => { SelectPart(0, '', 0, '', 0, '', 1, this.searchPick, 0, '', 0, '', 0, '', '', '', '').then(response => {
console.log(response, 8) console.log(response, 8)
for (let i = 0; i < this.activities.length; i++) { for (let i = 0; i < this.activities.length; i++) {
@@ -423,55 +365,24 @@ export default {
} }
} }
}) })
SelectOut(item.name).then(response => { console.log(item, 11)
console.log(response, 87633) this.tableData1 = []
if (response.data[0].状态编号.toString() === '1') { gettabledata1(item.name).then(response => {
this.isOut = '是' if (response.data.length !== 0) {
this.active1 = '1'
this.outName = ''
this.outTime = '未到货检验'
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
if (i === 0) { console.log(response.data[i])
this.outName = response.data[i].外协工序 this.tableData1.push({
} else { 工艺名称: response.data[i].工艺名称,
this.outName = this.outName + '、' + response.data[i].外协工序 工序顺序: response.data[i].工序顺序,
} 加工开始时间: response.data[i].加工开始时间 ? response.data[i].加工开始时间 : '',
} 完成日期: response.data[i].加工完成时间 ? response.data[i].加工完成时间 : '',
} else if (response.data[0].状态编号.toString() === '2') { 操作者: response.data[i].姓名,
this.isOut = '是' 批次数量: response.data[i].批次数量,
this.active1 = '2' 工序流水号: response.data[i].工序流水号,
this.outName = '' 完成过程流水号: response.data[i].完成过程流水号,
this.outTime = '未到货检验' 工序状态: response.data[i].工序状态,
for (let i = 0; i < response.data.length; i++) { 完成数量: response.data[i].完成数量
if (i === 0) { })
this.outName = response.data[i].外协工序
} else {
this.outName = this.outName + '、' + response.data[i].外协工序
}
}
} else if (response.data[0].状态编号.toString() === '3') {
this.isOut = '是'
this.active1 = '3'
this.outName = ''
this.outTime = '未到货检验'
for (let i = 0; i < response.data.length; i++) {
if (i === 0) {
this.outName = response.data[i].外协工序
} else {
this.outName = this.outName + '、' + response.data[i].外协工序
}
}
} else if (response.data[0].状态编号.toString() === '4') {
this.isOut = '是'
this.active1 = '4'
this.outName = ''
this.outTime = response.data[0].检验日期
for (let i = 0; i < response.data.length; i++) {
if (i === 0) {
this.outName = response.data[i].外协工序
} else {
this.outName = this.outName + '、' + response.data[i].外协工序
}
} }
} }
}) })
@@ -520,7 +431,7 @@ export default {
overflow-x: auto; overflow-x: auto;
color: #000; color: #000;
font-size: 16px; font-size: 16px;
height: 130px; height: 430px;
} }
.main p{height:300px;} .main p{height:300px;}
/*-------滚动条整体样式----*/ /*-------滚动条整体样式----*/
@@ -541,3 +452,8 @@ export default {
background:white; background:white;
} }
</style> </style>
<style>
.CompleteColor{
background: #9bd7fc !important;
}
</style>

View File

@@ -50,7 +50,7 @@
<el-table <el-table
v-loading="listLoading1" v-loading="listLoading1"
:data="tableData1" :data="tableData1"
style="margin-top: 3px;width: 1355px" style="margin-top: 3px;width: 650px"
height="600" height="600"
border border
stripe stripe
@@ -67,11 +67,11 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="进程" width="100"> <!-- <el-table-column align="center" label="进程" width="100">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
{{ scope.row.执行进度名 }} <!-- {{ scope.row.执行进度名 }}-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column align="center" label="签订日期" width="86"> <el-table-column align="center" label="签订日期" width="86">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.合同签订日期 }} {{ scope.row.合同签订日期 }}
@@ -82,26 +82,26 @@
{{ scope.row.姓名 }} {{ scope.row.姓名 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="客户名称" prop="客户名称" width="220" show-overflow-tooltip> <!-- <el-table-column align="center" label="客户名称" prop="客户名称" width="220" show-overflow-tooltip>-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
{{ scope.row.客户名称 }} <!-- {{ scope.row.客户名称 }}-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column align="center" label="联系人" width="90" show-overflow-tooltip> <!-- <el-table-column align="center" label="联系人" width="90" show-overflow-tooltip>-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
{{ scope.row.联系人 }} <!-- {{ scope.row.联系人 }}-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column align="center" label="联系电话" width="110" show-overflow-tooltip> <!-- <el-table-column align="center" label="联系电话" width="110" show-overflow-tooltip>-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
{{ scope.row.电话 }} <!-- {{ scope.row.电话 }}-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column align="center" label="合同信息备注" width="175" show-overflow-tooltip> <!-- <el-table-column align="center" label="合同信息备注" width="175" show-overflow-tooltip>-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
{{ scope.row.合同信息备注 }} <!-- {{ scope.row.合同信息备注 }}-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column label="操作" align="center" width="190px"> <el-table-column label="操作" align="center" width="190px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@@ -143,11 +143,21 @@
border border
stripe stripe
size="mini"> size="mini">
<el-table-column align="center" label="履约保证金金额" style="padding:0px"> <el-table-column align="center" label="履约金总额(万元)" width="140px" style="padding:0px">
<template slot-scope="scope">
<el-tag type="primary" size="mini">{{ Number(scope.row.履约保证金总额).toFixed(2) }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="投标转履约金额(万元)" width="170px" style="padding:0px;">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag type="primary" size="mini">{{ Number(scope.row.履约保证金金额).toFixed(2) }}</el-tag> <el-tag type="primary" size="mini">{{ Number(scope.row.履约保证金金额).toFixed(2) }}</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="追加履约金额(万元)" width="150px" style="padding:0px">
<template slot-scope="scope">
<el-tag type="primary" size="mini">{{ (Number(scope.row.履约保证金总额) - Number(scope.row.履约保证金金额)).toFixed(2) }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="保证金类型"> <el-table-column align="center" label="保证金类型">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.保证金类型 }} {{ scope.row.保证金类型 }}
@@ -163,6 +173,11 @@
{{ scope.row.提前X天提醒我 }}天内收回 {{ scope.row.提前X天提醒我 }}天内收回
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="缴纳时间">
<template slot-scope="scope">
{{ scope.row.缴纳时间?scope.row.缴纳时间.split(' ')[0]: '-' }}
</template>
</el-table-column>
<el-table-column align="center" label="是否收回"> <el-table-column align="center" label="是否收回">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.是否收回) === 1" slot="reference" size="mini" type="success" style="width: 66px">已收回</el-tag> <el-tag v-if="parseInt(scope.row.是否收回) === 1" slot="reference" size="mini" type="success" style="width: 66px">已收回</el-tag>
@@ -174,7 +189,7 @@
{{ Number(scope.row.收回金额).toFixed(2) }} {{ Number(scope.row.收回金额).toFixed(2) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="实际收回日期"> <el-table-column align="center" label="收回时间">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.实际收回日期 === '' || scope.row.实际收回日期 === null ? scope.row.实际收回日期 = '暂未收回' : scope.row.实际收回日期 }} {{ scope.row.实际收回日期 === '' || scope.row.实际收回日期 === null ? scope.row.实际收回日期 = '暂未收回' : scope.row.实际收回日期 }}
</template> </template>
@@ -277,7 +292,7 @@
placeholder="请选择实际收回日期"/> placeholder="请选择实际收回日期"/>
</el-form-item> </el-form-item>
<el-form-item label="收回金额(万元)" prop="收回金额"> <el-form-item label="收回金额(万元)" prop="收回金额">
<el-input-number v-model="form.收回金额" :precision="2" :min="0" :step="1" :max="maxrecmoney" style="width: 150px" size="small"/> <el-input-number v-model="form.收回金额" :precision="2" :min="0" :step="1" :max="maxrecmoney" disabled style="width: 150px" size="small"/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@@ -288,12 +303,12 @@
</div> </div>
</el-dialog> </el-dialog>
<el-dialog v-el-drag-dialog :title="title1" :visible.sync="dialogFormVisible1" center style="min-height: 300px" width="600px"> <el-dialog v-el-drag-dialog :title="title1" :visible.sync="dialogFormVisible1" center style="min-height: 300px" width="700px">
<el-form ref="form2" :model="form2" :rules="rules2" label-position="left" label-width="105px" class="demo-ruleForm"> <el-form ref="form2" :model="form2" :rules="rules2" label-position="left" label-width="150px" class="demo-ruleForm">
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="履约金(万元)" prop="保证金金额"> <el-form-item label="项目履约金(万元)" prop="保证金金额">
<el-input-number v-model="form2.保证金金额" :precision="2" :min="0" :step="1" style="width: 150px" size="small"/> <el-input-number v-model="form2.保证金金额" :precision="2" :min="minmoney" :step="1" style="width: 150px" size="small" @change="jisuan"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
@@ -326,6 +341,32 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row>
<el-col :span="12">
<el-form-item label="投标金转入(万元)" prop="投标保证金金额">
<el-input-number v-model="form2.投标保证金金额" :precision="2" :min="0" :step="1" disabled style="width: 150px" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="追加履约金金额(万元)" prop="追加金额">
<el-input-number v-model="form2.追加金额" :precision="2" :step="1" disabled style="width: 150px" size="small"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="缴纳时间" prop="缴纳时间">
<el-date-picker
v-model="form2.timer"
type="date"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
placeholder="选择日期"
style="width: 150px;height: 32px"
size="small"/>
</el-form-item>
</el-col>
</el-row>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button size="small" icon="el-icon-circle-close" @click="callOffPerformanceBondDialog('form2')">取消</el-button> <el-button size="small" icon="el-icon-circle-close" @click="callOffPerformanceBondDialog('form2')">取消</el-button>
@@ -413,6 +454,7 @@ export default {
customerName_check: '', customerName_check: '',
customerName: '', // 客户名称 customerName: '', // 客户名称
maxrecmoney: 0.00, maxrecmoney: 0.00,
minmoney: 0.00,
form: { form: {
实际收回日期: '', 实际收回日期: '',
收回金额: '' 收回金额: ''
@@ -421,7 +463,10 @@ export default {
保证金金额: '', 保证金金额: '',
保证金类型: 1, 保证金类型: 1,
收回条件: 1, 收回条件: 1,
截止时间: 15 截止时间: 15,
投标保证金金额: 0,
追加金额: 0,
timer: new Date()
}, },
rules: { // 表单验证规则 rules: { // 表单验证规则
实际收回日期: [{ required: true, message: '请选择实际收回日期', trigger: 'change' }], 实际收回日期: [{ required: true, message: '请选择实际收回日期', trigger: 'change' }],
@@ -444,6 +489,23 @@ export default {
this.fetchTableData1() this.fetchTableData1()
}, },
methods: { methods: {
getNowFormatDate() {
console.log(this.form2.timer)
var year = this.form2.timer.getFullYear()
var month = this.form2.timer.getMonth() + 1
var day = this.form2.timer.getDate()
if (month >= 1 && month <= 9) {
month = '0' + month
}
if (day >= 1 && day <= 9) {
day = '0' + day
}
this.form2.timer = year + '-' + month + '-' + day
console.log(this.form2.timer)
},
jisuan() {
this.form2.追加金额 = this.form2.保证金金额 - this.form2.投标保证金金额
},
formatJson(filterVal, jsonData) { formatJson(filterVal, jsonData) {
return jsonData.map(v => filterVal.map(j => { return jsonData.map(v => filterVal.map(j => {
return v[j] return v[j]
@@ -535,7 +597,7 @@ export default {
const data = response.data const data = response.data
for (let i = 0; i < data.rows.length; i++) { for (let i = 0; i < data.rows.length; i++) {
data.rows[i].合同签订日期 = data.rows[i].合同签订日期.substring(0, data.rows[i].合同签订日期.length - 8) data.rows[i].合同签订日期 = data.rows[i].合同签订日期.substring(0, data.rows[i].合同签订日期.length - 8)
parseInt(data.rows[i].履约保证金类型) !== 0 ? data.rows[i].是否禁用增加履约保证金 = true : data.rows[i].是否禁用增加履约保证金 = false parseInt(data.rows[i].是否追加履约保证金) !== 0 ? data.rows[i].是否禁用增加履约保证金 = true : data.rows[i].是否禁用增加履约保证金 = false
parseInt(data.rows[i].履约保证金类型) !== 0 ? data.rows[i].是否禁用增加履约保函 = true : data.rows[i].是否禁用增加履约保函 = false parseInt(data.rows[i].履约保证金类型) !== 0 ? data.rows[i].是否禁用增加履约保函 = true : data.rows[i].是否禁用增加履约保函 = false
} }
this.tableData1 = data.rows this.tableData1 = data.rows
@@ -557,51 +619,55 @@ export default {
}, },
// 履约保证金查询 // 履约保证金查询
fetchTableData2(row) { fetchTableData2(row) {
console.log(row, 911) this.tableData2 = []
this.projectId = row.项目流水号 if (parseInt(row.是否追加履约保证金) !== 0) {
typeOfPerformanceBond(this.projectId).then(response => { console.log(row, 911)
const data = response.data[0].履约保证金类型 this.projectId = row.项目流水号
return data typeOfPerformanceBond(this.projectId).then(response => {
}).then(data => { const data = response.data[0].履约保证金类型
if (data === 1) { return data
this.activeName = 'first' }).then(data => {
this.listLoading2 = true if (data === 1) {
this.performanceBondDisabled = false this.activeName = 'first'
this.performanceGuaranteeDisabled = true this.listLoading2 = true
searchTableData2(this.projectId).then(response => { this.performanceBondDisabled = false
this.listLoading2 = false this.performanceGuaranteeDisabled = true
const data = response.data searchTableData2(this.projectId).then(response => {
for (let i = 0; i < data.length; i++) { this.listLoading2 = false
data[i].实际收回日期 !== '' && data[i].实际收回日期 !== null ? data[i].实际收回日期 = data[i].实际收回日期.substring(0, data[i].实际收回日期.length - 8) : data[i].实际收回日期 const data = response.data
data[i].节点日期 !== '' && data[i].节点日期 !== null ? data[i].节点日期 = data[i].节点日期.substring(0, data[i].节点日期.length - 8) : data[i].节点日期 for (let i = 0; i < data.length; i++) {
data[i].计划收款日期 !== '' && data[i].计划收款日期 !== null ? data[i].计划收款日期 = data[i].计划收款日期.substring(0, data[i].计划收款日期.length - 8) : data[i].计划收款日期 data[i].实际收回日期 !== '' && data[i].实际收回日期 !== null ? data[i].实际收回日期 = data[i].实际收回日期.substring(0, data[i].实际收回日期.length - 8) : data[i].实际收回日期
data[i].计划收款日期 === '' || data[i].计划收款日期 === null || parseInt(data[i].是否收回) === 1 ? data[i].是否禁用收回 = true : data[i].是否禁用收回 = false data[i].节点日期 !== '' && data[i].节点日期 !== null ? data[i].节点日期 = data[i].节点日期.substring(0, data[i].节点日期.length - 8) : data[i].节点日期
parseInt(data[i].是否收回) === 1 ? data[i].是否禁用编辑 = true : data[i].是否禁用编辑 = false data[i].计划收款日期 !== '' && data[i].计划收款日期 !== null ? data[i].计划收款日期 = data[i].计划收款日期.substring(0, data[i].计划收款日期.length - 8) : data[i].计划收款日期
parseInt(data[i].是否收回) === 1 ? data[i].是否禁用删除 = true : data[i].是否禁用删除 = false data[i].计划收款日期 === '' || data[i].计划收款日期 === null || parseInt(data[i].是否收回) === 1 ? data[i].是否禁用收回 = true : data[i].是否禁用收回 = false
} parseInt(data[i].是否收回) === 1 ? data[i].是否禁用编辑 = true : data[i].是否禁用编辑 = false
this.tableData2 = data parseInt(data[i].是否收回) === 1 ? data[i].是否禁用删除 = true : data[i].是否禁用删除 = false
}) }
} else if (data === 2) { this.tableData2 = data
this.activeName = 'second' })
this.performanceBondDisabled = true } else if (data === 2) {
this.performanceGuaranteeDisabled = false this.activeName = 'second'
this.performanceGuaranteeShow = true this.performanceBondDisabled = true
this.getFileList() this.performanceGuaranteeDisabled = false
} else { this.performanceGuaranteeShow = true
this.$message.warning('未缴纳履约保证金') this.getFileList()
this.tableData2 = [] } else {
this.performanceGuaranteeShow = false this.$message.warning('未缴纳履约保证金')
this.performanceBondDisabled = true this.tableData2 = []
this.performanceGuaranteeDisabled = true this.performanceGuaranteeShow = false
} this.performanceBondDisabled = true
}) this.performanceGuaranteeDisabled = true
}
})
}
}, },
takeBack(row) { takeBack(row) {
this.addForm('form') this.addForm('form')
this.performanceBondCode = row.履约保证金流水号 this.performanceBondCode = row.履约保证金流水号
this.form.收回金额 = Number(row.收回金额).toFixed(2) // this.form.收回金额 = Number(row.收回金额).toFixed(2)
console.log((row.履约保证金金额).toFixed(2)) this.form.收回金额 = row.履约保证金总额
this.maxrecmoney = row.履约保证金金额 // console.log((row.履约保证金金额).toFixed(2))
this.maxrecmoney = row.履约保证金总额
this.dialogTimeVisible = true this.dialogTimeVisible = true
}, },
callOffTime() { callOffTime() {
@@ -663,6 +729,11 @@ export default {
this.dialogFormVisible1 = true this.dialogFormVisible1 = true
this.projectId = row.项目流水号 this.projectId = row.项目流水号
this.tableData2 = [] this.tableData2 = []
this.form2.投标保证金金额 = row.履约保证金金额
// this.minmoney = Number(this.form2.投标保证金金额)
this.jisuan()
this.fetchTableData1()
this.getNowFormatDate()
}, },
callOffPerformanceBondDialog() { callOffPerformanceBondDialog() {
this.dialogFormVisible1 = false this.dialogFormVisible1 = false
@@ -671,7 +742,7 @@ export default {
this.$refs[formName].validate((valid) => { this.$refs[formName].validate((valid) => {
if (valid) { if (valid) {
if (this.flag === 1) { if (this.flag === 1) {
addPerformanceBond(this.projectId, this.form2.保证金金额, this.form2.保证金类型, this.form2.收回条件, this.form2.截止时间).then(response => { addPerformanceBond(this.projectId, this.form2.保证金金额, this.form2.保证金类型, this.form2.收回条件, this.form2.截止时间, this.form2.timer).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('操作成功') this.$message.success('操作成功')
this.fetchTableData1() this.fetchTableData1()
@@ -717,7 +788,7 @@ export default {
} }
}) })
} else if (this.flag === 2) { } else if (this.flag === 2) {
editPerformanceBond(this.projectId, this.form2.保证金金额, this.form2.保证金类型, this.form2.收回条件, this.form2.截止时间, this.performanceBondCode).then(response => { editPerformanceBond(this.projectId, this.form2.保证金金额, this.form2.保证金类型, this.form2.收回条件, this.form2.截止时间, this.performanceBondCode, this.form2.timer).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('操作成功') this.$message.success('操作成功')
this.dialogFormVisible1 = false this.dialogFormVisible1 = false
@@ -768,10 +839,13 @@ export default {
openEditPerformanceBondDialog(row) { openEditPerformanceBondDialog(row) {
this.dialogFormVisible1 = true this.dialogFormVisible1 = true
this.performanceBondCode = row.履约保证金流水号 this.performanceBondCode = row.履约保证金流水号
this.form2.保证金金额 = row.履约保证金 this.form2.保证金金额 = row.履约保证金
this.form2.保证金类型 = row.保金类型 this.form2.保证金类型 = row.保金类型
this.form2.投标保证金金额 = row.履约保证金金额
this.jisuan()
this.form2.收回条件 = parseInt(row.执行进度流水号) this.form2.收回条件 = parseInt(row.执行进度流水号)
this.title1 = '编辑履约保证金' this.title1 = '编辑履约保证金'
this.getNowFormatDate()
}, },
delPerformanceBond(row) { delPerformanceBond(row) {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', { this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {

View File

@@ -94,7 +94,7 @@
</el-table-column> </el-table-column>
<el-table-column align="center" label="缴纳时间" width="87" show-overflow-tooltip> <el-table-column align="center" label="缴纳时间" width="87" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.交付日期 }} {{ scope.row.交付日期.split(' ')[0] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="扣款金额(万元)" prop="扣款金额" width="120" show-overflow-tooltip> <el-table-column align="center" label="扣款金额(万元)" prop="扣款金额" width="120" show-overflow-tooltip>
@@ -159,7 +159,7 @@
<el-tooltip :open-delay="1000" class="item" effect="dark" content="收回" placement="top"> <el-tooltip :open-delay="1000" class="item" effect="dark" content="收回" placement="top">
<div style="display: inline-block"> <div style="display: inline-block">
<el-button <el-button
:disabled="scope.row.是否禁用收回 || !scope.row.是否禁用增加安全保证金" :disabled="scope.row.是否禁用收回 || !scope.row.是否禁用增加安全保证金 ||Number(scope.row.未收金额)<=0"
size="mini" size="mini"
type="text" type="text"
icon="el-icon-money" icon="el-icon-money"
@@ -917,9 +917,9 @@ export default {
this.listLoadingProject = false this.listLoadingProject = false
const data = response.data const data = response.data
for (let i = 0; i < data.rows.length; i++) { for (let i = 0; i < data.rows.length; i++) {
data.rows[i].合同签订日期 = data.rows[i].合同签订日期.substring(0, data.rows[i].合同签订日期.length - 8) // data.rows[i].合同签订日期 = data.rows[i].合同签订日期.substring(0, data.rows[i].合同签订日期.length - 8)
parseInt(data.rows[i].安全保证金类型) === 1 ? data.rows[i].是否禁用增加安全保证金 = true : data.rows[i].是否禁用增加安全保证金 = false parseInt(data.rows[i].安全保证金类型) === 1 ? data.rows[i].是否禁用增加安全保证金 = true : data.rows[i].是否禁用增加安全保证金 = false
data.rows[i].交付日期 = data.rows[i].交付日期.substring(0, data.rows[i].交付日期.length - 8) // data.rows[i].交付日期 = data.rows[i].交付日期.substring(0, data.rows[i].交付日期.length - 8)
} }
this.projectTableData = data.rows this.projectTableData = data.rows

View File

@@ -3,7 +3,7 @@
<el-card> <el-card>
<div style="margin-top: 7px; margin-bottom: 7px"> <div style="margin-top: 7px; margin-bottom: 7px">
<el-input v-model="supplierNameValue" size="small" placeholder="外协厂家零件图号表单号项目名称" style="width: 220px" clearable/> <el-input v-model="supplierNameValue" size="small" placeholder="外协厂家零件图号表单号项目名称" style="width: 220px" clearable/>
<el-date-picker v-model="timer" type="daterange" value-format="yyyy-MM-dd" size="small" range-separator="~" start-placeholder="开始日期" end-placeholder="结束日期"/> <el-date-picker v-model="timer" type="daterange" value-format="yyyy-MM-dd" size="small" range-separator="~" start-placeholder="开始日期" end-placeholder="结束日期" style="width: 240px"/>
<el-select v-model="MaterialsValue" placeholder="外协状态" filterable size="small" style="width: 120px" clearable> <el-select v-model="MaterialsValue" placeholder="外协状态" filterable size="small" style="width: 120px" clearable>
<el-option <el-option
v-for="item in Materials" v-for="item in Materials"
@@ -12,11 +12,11 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<el-button icon="el-icon-search" type="primary" size="small" plain @click="pageCurrent = 1;pageSize = 50;getTableData()">查询</el-button> <el-button icon="el-icon-search" type="primary" size="small" plain @click="pageCurrent = 1;pageSize = 50;getTableData()">查询</el-button>
<el-button type="primary" class="el-icon-download" size="small" style="margin: 10px 0 0 10px" plain @click="exportExcel">导出</el-button> <el-button type="success" class="el-icon-download" size="small" style="margin: 10px 0 0 10px" plain @click="exportExcel">导出</el-button>
</div> </div>
</el-card> </el-card>
<el-card> <el-card>
<el-table v-loading="loading" :data="tableData" border stripe size="mini" height="700" style="width: 1210px"> <el-table v-loading="loading" :data="tableData" border stripe size="mini" height="650" style="width: 1350px">
<el-table-column label="序号" align="center" type="index" width="50"/> <el-table-column label="序号" align="center" type="index" width="50"/>
<el-table-column label="外协状态" align="center" width="90px"> <el-table-column label="外协状态" align="center" width="90px">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -49,19 +49,29 @@
{{ scope.row.外协工序 }} {{ scope.row.外协工序 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="外协工时(分)" align="center" width="110">
<template slot-scope="scope">
{{ scope.row.外协工时 }}
</template>
</el-table-column>
<el-table-column label="工时费用(元)" align="center" width="110">
<template slot-scope="scope">
{{ scope.row.加工价格_成交 }}
</template>
</el-table-column>
<el-table-column label="外协厂家" align="center" width="160px"> <el-table-column label="外协厂家" align="center" width="160px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.外协厂家名称 }} {{ scope.row.外协厂家名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="外协单号" align="center" width="200"> <el-table-column label="外协单号" align="center" width="180">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.表单号 }} {{ scope.row.表单号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="外协日期" align="center" width="100"> <el-table-column label="外协日期" align="center" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.任务下达日期.substr(0,10) }} {{ scope.row.任务下达日期.split(' ')[0] }}
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -76,7 +86,7 @@
@current-change="handleCurrentChanges"/> @current-change="handleCurrentChanges"/>
</div> </div>
</el-card> </el-card>
<el-card> <el-card v-show="false">
<div id="myChart1" :style="{width: '100%', height: '400px', margin: 'auto'}"/> <div id="myChart1" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
</el-card> </el-card>
</div> </div>
@@ -85,7 +95,6 @@
<script> <script>
import { searchTable, getprocedure, search1 } from '@/api/Outsourcing/OutsourcingPartsQuery' import { searchTable, getprocedure, search1 } from '@/api/Outsourcing/OutsourcingPartsQuery'
import echarts from 'echarts' import echarts from 'echarts'
export default { export default {
data() { data() {
return { return {
@@ -103,6 +112,7 @@ export default {
}], }],
tableData: [], tableData: [],
procedure: [], procedure: [],
procedureTime: [],
pageCurrent: 1, pageCurrent: 1,
pageSize: 50, pageSize: 50,
tableData1: [] tableData1: []
@@ -119,7 +129,6 @@ export default {
})) }))
}, },
exportExcel() { exportExcel() {
this.tableData1 = []
let check, check1, check2 let check, check1, check2
this.supplierNameValue ? check = 1 : check = 0 this.supplierNameValue ? check = 1 : check = 0
if (this.MaterialsValue !== '' && this.MaterialsValue !== null) { if (this.MaterialsValue !== '' && this.MaterialsValue !== null) {
@@ -135,49 +144,21 @@ export default {
} else { } else {
check2 = 1 check2 = 1
} }
searchTable(check, this.supplierNameValue, check1, this.MaterialsValue, check2, this.timer[0], this.timer[1], 100000000, this.pageCurrent).then(response => { var param = []
for (let i = 0; i < response.data.rows.length; i++) { param[0] = ['外协厂家_check', check]
this.tableData1.push({ param[1] = ['外协厂家', this.supplierNameValue]
到货状态: response.data.rows[i].到货状态 === '0' ? '未到' : '已到', param[2] = ['外协状态_check', check1]
项目名称: response.data.rows[i].项目名称, param[3] = ['外协状态', this.MaterialsValue]
零件图号: response.data.rows[i].零件图号, param[4] = ['时间_check', check2]
零件名称: response.data.rows[i].零件名称, if (check2 === 0) {
批次数量: response.data.rows[i].批次数量, param[5] = ['开始时间', '']
外协厂家名称: response.data.rows[i].外协厂家名称, param[6] = ['结束时间', '']
表单号: response.data.rows[i].表单号, } else {
工艺计划流水号: response.data.rows[i].工艺计划流水号, param[5] = ['开始时间', this.timer[0]]
单件是否外协: response.data.rows[i].单件是否外协, param[6] = ['结束时间', this.timer[1]]
任务下达日期: response.data.rows[i].任务下达日期 ? response.data.rows[i].任务下达日期.split(' ')[0] : '', }
外协工序: '' var Data = this.CreateData('2001', '报表_车间生产管理_外协零件_查询数据_新', param)
}) this.exportExcel_NPOI(Data)
}
for (let i = 0; i < this.tableData1.length; i++) {
getprocedure(this.tableData1[i].工艺计划流水号, this.tableData1[i].单件是否外协).then(response => {
this.procedure[i] = ''
for (let j = 0; j < response.data.length; j++) {
this.procedure[i] = this.procedure[i] + ' ' + response.data[j].工艺名称简称
}
this.tableData1[i].外协工序 = this.procedure[i]
})
}
}).then(() => {
setTimeout(this.exportExcel1, 500)
})
},
exportExcel1() {
import('@/vendor/Export2Excel').then(excel => {
const tHeader = ['外协状态', '项目名称', '零件图号', '零件名称', '数量', '外协工序', '外协厂家', '外协单号', '外协日期']
const filterVal = ['到货状态', '项目名称', '零件图号', '零件名称', '批次数量', '外协工序', '外协厂家名称', '表单号', '任务下达日期']
const list = this.tableData1
const data = this.formatJson(filterVal, list)
excel.export_json_to_excel({
header: tHeader,
data,
filename: '外协零件表',
autoWidth: true,
bookType: 'xlsx'
})
})
}, },
getTableData() { getTableData() {
this.tableData = [] this.tableData = []
@@ -198,22 +179,7 @@ export default {
check2 = 1 check2 = 1
} }
searchTable(check, this.supplierNameValue, check1, this.MaterialsValue, check2, this.timer[0], this.timer[1], this.pageSize, this.pageCurrent).then(response => { searchTable(check, this.supplierNameValue, check1, this.MaterialsValue, check2, this.timer[0], this.timer[1], this.pageSize, this.pageCurrent).then(response => {
for (let i = 0; i < response.data.rows.length; i++) { this.tableData = response.data.rows
this.tableData.push({
到货状态: response.data.rows[i].到货状态,
项目名称: response.data.rows[i].项目名称,
零件图号: response.data.rows[i].零件图号,
零件名称: response.data.rows[i].零件名称,
批次数量: response.data.rows[i].批次数量,
外协厂家名称: response.data.rows[i].外协厂家名称,
表单号: response.data.rows[i].表单号,
工艺计划流水号: response.data.rows[i].工艺计划流水号,
单件是否外协: response.data.rows[i].单件是否外协,
任务下达日期: response.data.rows[i].任务下达日期,
外协工序: ''
})
}
this.getProcedure(this.tableData)
this.total = response.data.total this.total = response.data.total
this.loading = false this.loading = false
}) })
@@ -222,10 +188,13 @@ export default {
for (let i = 0; i < row.length; i++) { for (let i = 0; i < row.length; i++) {
getprocedure(row[i].工艺计划流水号, row[i].单件是否外协).then(response => { getprocedure(row[i].工艺计划流水号, row[i].单件是否外协).then(response => {
this.procedure[i] = '' this.procedure[i] = ''
this.procedureTime[i] = 0
for (let j = 0; j < response.data.length; j++) { for (let j = 0; j < response.data.length; j++) {
this.procedure[i] = this.procedure[i] + ' ' + response.data[j].工艺名称简称 this.procedure[i] = this.procedure[i] + ' ' + response.data[j].工艺名称简称
this.procedureTime[i] = parseInt(this.procedureTime[i]) + parseInt(response.data[j].单件定额工时) * row[i].批次数量 + parseInt(response.data[j].准结定额工时)
} }
this.tableData[i].外协工序 = this.procedure[i] this.tableData[i].外协工序 = this.procedure[i]
this.tableData[i].外协工时 = this.procedureTime[i]
}) })
} }
}, },

View File

@@ -1,7 +1,7 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-card style="width: 1050px"> <el-row style="width: 720px">
<el-row style="width: 1020px"> <el-card style="margin-bottom: 5px">
<el-row> <el-row>
<el-input v-model="ManufacturerName" size="small" placeholder="外协厂家" clearable style="width:200px"/> <el-input v-model="ManufacturerName" size="small" placeholder="外协厂家" clearable style="width:200px"/>
<el-date-picker <el-date-picker
@@ -15,9 +15,10 @@
style="width:250px;margin-left: 5px;margin-top: 10px;margin-bottom: 10px" style="width:250px;margin-left: 5px;margin-top: 10px;margin-bottom: 10px"
start-placeholder="开始日期" start-placeholder="开始日期"
end-placeholder="结束日期"/> end-placeholder="结束日期"/>
<el-button type="primary" class="el-icon-search" style="margin-left: 20px" size="small" plain @click="pageCurrent=1;pageSize=50;getParts()">查询</el-button> <el-button type="primary" class="el-icon-search" style="margin-left: 20px" size="small" plain @click="getParts()">查询</el-button>
<el-button type="success" plain class="el-icon-download" style="margin-left: 30px" size="small" @click="exportExcel">导出</el-button>
</el-row> </el-row>
<el-table v-loading="loading" :data="tableData" size="mini" highlight-current-row height="300" style="width: 690px;" border element-loading-text="拼命加载中" @row-click="rowClick"> <el-table v-loading="loading" :data="tableData" size="mini" highlight-current-row height="300" style="width: 690px;margin-bottom: 10px" border element-loading-text="拼命加载中" @row-click="rowClick">
<el-table-column label="厂家" prop="外协厂家名称" align="center" width="230px"> <el-table-column label="厂家" prop="外协厂家名称" align="center" width="230px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.外协厂家名称 }} {{ scope.row.外协厂家名称 }}
@@ -44,25 +45,16 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="block"> </el-card>
<el-pagination </el-row>
v-if="!loading" <el-col style="width: 520px">
:current-page="pageCurrent" <el-card>
:page-sizes="[50, 100]"
:page-size="pageSize"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-row>
<el-col style="width: 520px">
<el-row> <el-row>
<span style="margin-top: 10px">开票明细:</span> <span style="margin-top: 10px">开票明细:</span>
<el-button type="distribution" size="small" icon="el-icon-circle-plus-outline" style="margin-left:10px" @click="handleAdd1('form1')">开票</el-button> <el-button type="distribution" size="small" icon="el-icon-circle-plus-outline" style="margin-left:10px" @click="handleAdd1('form1')">开票</el-button>
</el-row> </el-row>
<el-table v-loading="loading2" :data="tableData2" size="mini" stripe height="400" style="width: 100%" border element-loading-text="拼命加载中"> <el-table v-loading="loading2" :data="tableData2" size="mini" stripe height="400" style="width: 100%" border element-loading-text="拼命加载中">
<el-table-column label="发票号" prop="发票号" align="center" width="160px"> <el-table-column label="发票号" prop="发票号" align="center" width="150px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.发票号 }} {{ scope.row.发票号 }}
</template> </template>
@@ -72,7 +64,7 @@
{{ scope.row.开票金额 }} {{ scope.row.开票金额 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="开票日期" align="center" width="100px" prop="开票日期"> <el-table-column label="开票日期" align="center" width="90px" prop="开票日期">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.开票时间 }} {{ scope.row.开票时间 }}
</template> </template>
@@ -95,8 +87,10 @@
@size-change="handleSizeChange2" @size-change="handleSizeChange2"
@current-change="handleCurrentChange2"/> @current-change="handleCurrentChange2"/>
</div> </div>
</el-col> </el-card>
<el-col style="width: 350px"> </el-col>
<el-col style="width: 370px;margin-left: 5px">
<el-card>
<el-row> <el-row>
<span style="margin-top: 10px">付款明细:</span> <span style="margin-top: 10px">付款明细:</span>
<el-button type="distribution" size="small" icon="el-icon-circle-plus-outline" style="margin-left:10px" @click="handleAdd2('form2')">付款</el-button> <el-button type="distribution" size="small" icon="el-icon-circle-plus-outline" style="margin-left:10px" @click="handleAdd2('form2')">付款</el-button>
@@ -130,13 +124,13 @@
@size-change="handleSizeChange3" @size-change="handleSizeChange3"
@current-change="handleCurrentChange3"/> @current-change="handleCurrentChange3"/>
</div> </div>
</el-col> </el-card>
</el-card> </el-col>
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible1" :title="title1" center style="min-height: 300px" width="400px"> <el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible1" :title="title1" center style="min-height: 300px" width="400px">
<el-form ref="form1" :model="form1" :rules="rules" label-position="left" label-width="120px" class="demo-ruleForm"> <el-form ref="form1" :model="form1" :rules="rules" label-position="left" label-width="120px" class="demo-ruleForm">
<el-row> <el-row>
<el-form-item label="票号" prop="发票号" > <el-form-item label="到票票号" prop="发票号" >
<el-input v-model="form1.发票号" placeholder="发票号" style="width:200px" clearable size="small"/> <el-input v-model="form1.发票号" placeholder="发票号" style="width:200px" clearable size="small"/>
</el-form-item> </el-form-item>
</el-row> </el-row>
@@ -257,11 +251,10 @@ export default {
var check2 var check2
this.startTime ? check2 = 1 : (check2 = 0, this.startTime = '') this.startTime ? check2 = 1 : (check2 = 0, this.startTime = '')
this.ManufacturerName ? check = 1 : check = 0 this.ManufacturerName ? check = 1 : check = 0
searchtable(check, this.ManufacturerName, check2, this.startTime[0], this.startTime[1], this.pageCurrent, this.pageSize).then(response => { searchtable(check, this.ManufacturerName, check2, this.startTime[0], this.startTime[1]).then(response => {
this.loading = false this.loading = false
if (response.data.rows.length !== 0) { if (response.data.length !== 0) {
this.tableData = response.data.rows this.tableData = response.data
this.total = response.data.total
} }
}) })
}, },
@@ -320,7 +313,7 @@ export default {
} }
if (this.外协厂家流水号) { if (this.外协厂家流水号) {
this.param1 = 1 this.param1 = 1
this.title1 = '新增票' this.title1 = '新增票'
this.form1.发票号 = '' this.form1.发票号 = ''
this.form1.开票时间 = '' this.form1.开票时间 = ''
this.form1.开票金额 = '' this.form1.开票金额 = ''
@@ -482,6 +475,29 @@ export default {
} }
}) })
}, },
exportExcel() {
if (this.tableData.length !== 0) {
var check
var check2
this.startTime ? check2 = 1 : (check2 = 0, this.startTime = '')
this.ManufacturerName ? check = 1 : check = 0
var param = []
param[0] = ['外协厂家_check', check]
param[1] = ['外协厂家', this.machineNameValue]
param[2] = ['时间_check', check2]
if (check2 === 0) {
param[3] = ['开始时间', '']
param[4] = ['结束时间', '']
} else {
param[3] = ['开始时间', this.startTime[0]]
param[4] = ['结束时间', this.startTime[1]]
}
var Data = this.CreateData('2001', '报表_车间生产管理工艺_外协付款_查询', param)
this.exportExcel_NPOI(Data)
} else {
this.$message.warning('暂无数据')
}
},
callOff2(formName) { callOff2(formName) {
this.dialogFormVisible2 = false this.dialogFormVisible2 = false
this.$refs[formName].resetFields() this.$refs[formName].resetFields()
@@ -512,16 +528,6 @@ export default {
}) })
}) })
}, },
// 分页
handleSizeChange(val) {
this.pageCurrent = 1
this.pageSize = val
this.getParts()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.getParts()
},
handleSizeChange2(val) { handleSizeChange2(val) {
this.pageCurrent2 = 1 this.pageCurrent2 = 1
this.pageSize2 = val this.pageSize2 = val

View File

@@ -1,10 +1,10 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-card> <el-card>
<el-input v-model="partNumber" size="small" placeholder="零件号" clearable style="width:160px"/> <el-input v-model="partNumber" size="small" placeholder="零件号" clearable style="width:160px;margin-top: 3px"/>
<el-button type="primary" size="mini" icon="el-icon-search" style="margin-left:20px" plain @click="getList()">查询</el-button> <el-button type="primary" size="mini" icon="el-icon-search" style="margin-left:20px" plain @click="getList()">查询</el-button>
<el-button type="danger" plain size="mini" icon="el-icon-caret-right" style="float: right;margin-right:10px" @click="getBack()">打回车间</el-button> <el-button type="danger" plain size="mini" icon="el-icon-caret-right" style="float: right;margin-right:10px" @click="getBack()">打回车间</el-button>
<el-table v-loading="loading1" ref="multipleTable" :data="List1" border size="mini" stripe highlight-current-row height="265" style="width: 100%;margin-top: 20px" @selection-change="handleSelectionChange"> <el-table v-loading="loading1" ref="multipleTable" :data="List1" border size="mini" stripe highlight-current-row height="265" style="width: 100%;margin-top: 3px" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55"/> <el-table-column type="selection" width="55"/>
<el-table-column label="项目名称" prop="项目名称" align="center" show-overflow-tooltip> <el-table-column label="项目名称" prop="项目名称" align="center" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
@@ -34,11 +34,11 @@
</el-table> </el-table>
</el-card> </el-card>
<el-card> <el-card>
<el-col :span="8"> <el-col style="margin-right: 5px; width: 500px">
<el-input v-model="manufacturers" size="small" placeholder="外协厂家或表单号" style="width:160px" clearable @keyup.enter.native="fetchData()"/> <el-input v-model="manufacturers" size="small" placeholder="外协厂家或表单号" style="width:160px" clearable @keyup.enter.native="fetchData()"/>
<el-button type="primary" size="mini" icon="el-icon-search" style="margin-left:10px" plain @click="fetchData()">查询</el-button> <el-button type="primary" size="mini" icon="el-icon-search" style="margin-left:10px" plain @click="fetchData()">查询</el-button>
<el-checkbox v-model="isChecked" size="small" label="历史"/> <el-checkbox v-model="isChecked" size="small" label="历史"/>
<el-button type="distribution" size="mini" plain icon="el-icon-circle-plus-outline" style="margin-left:1px" @click="handleAdd()">新增</el-button> <el-button type="distribution" size="mini" plain icon="el-icon-circle-plus-outline" style="margin-left:1px" @click="handleAdd()">外协任务</el-button>
<el-table v-loading="loading2" :data="List" highlight-current-row height="550" size="mini" border @row-click="searchProcess" > <el-table v-loading="loading2" :data="List" highlight-current-row height="550" size="mini" border @row-click="searchProcess" >
<el-table-column label="表单号" prop="表单号" align="center" min-width="155px"> <el-table-column label="表单号" prop="表单号" align="center" min-width="155px">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -58,10 +58,10 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
</el-col> </el-col>
<el-col :span="16"> <el-col :span="15" style="float: right">
<div> <div>
<el-button type="warning" size="mini" icon="el-icon-arrow-down" style="margin-top:3px" plain @click="getSpareParts">选入零件</el-button> <el-button type="warning" size="mini" icon="el-icon-arrow-down" style="margin-top:3px" plain @click="getSpareParts">选入零件</el-button>
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left:10px;margin-top: 3px;float: right" plain @click="exportTable('RWD')">导出任务单</el-button> <el-button type="primary" size="mini" icon="el-icon-download" style="margin-left:10px;margin-top: 3px;margin-right: 20px;float: right" plain @click="exportTable('RWD')">导出任务单</el-button>
<el-tooltip :open-delay="1200" effect="dark" content="成交" placement="top"> <el-tooltip :open-delay="1200" effect="dark" content="成交" placement="top">
<el-button type="success" size="mini" icon="el-icon-upload2" style="margin-left:10px;margin-top: 3px;float: right" plain @click="Deal">提交</el-button> <el-button type="success" size="mini" icon="el-icon-upload2" style="margin-left:10px;margin-top: 3px;float: right" plain @click="Deal">提交</el-button>
</el-tooltip> </el-tooltip>

View File

@@ -2,7 +2,6 @@
<div class="app-container"> <div class="app-container">
<el-col :span="10"> <el-col :span="10">
<el-card> <el-card>
<span>厂家:</span>
<el-input v-model="manufacturers" size="small" placeholder="厂家或外协任务单号" style="width:160px" clearable @keyup.enter.native="pageSize=20;pageList=1;fetchData()"/> <el-input v-model="manufacturers" size="small" placeholder="厂家或外协任务单号" style="width:160px" clearable @keyup.enter.native="pageSize=20;pageList=1;fetchData()"/>
<el-button type="primary" size="mini" icon="el-icon-search" style="margin-left:10px" plain @click="pageSize=10;pageList=1;fetchData()">查询</el-button> <el-button type="primary" size="mini" icon="el-icon-search" style="margin-left:10px" plain @click="pageSize=10;pageList=1;fetchData()">查询</el-button>
</el-card> </el-card>

View File

@@ -305,7 +305,7 @@
<el-form ref="form2" :model="form2" :rules="rules2" label-position="right" label-width="120px"> <el-form ref="form2" :model="form2" :rules="rules2" label-position="right" label-width="120px">
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="外购计划单名称" prop="采购计划单名称"> <el-form-item label="外购备料单名称" prop="采购计划单名称">
<el-input v-model="form2.采购单名称" size="small"/> <el-input v-model="form2.采购单名称" size="small"/>
</el-form-item> </el-form-item>
</el-col> </el-col>

View File

@@ -287,7 +287,7 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-table v-show="type!==4" ref="multipleTable" :data="tableData03" border style="width: 100%;max-height: 250px;" height="250px" size="mini" @selection-change="handleSelectionChange"> <el-table v-show="type!==4" ref="multipleTable" :data="tableData02" border style="width: 100%;max-height: 250px;" height="250px" size="mini" @selection-change="handleSelectionChange">
<el-table-column :selectable="selectable" type="selection" align="center" width="45"/> <el-table-column :selectable="selectable" type="selection" align="center" width="45"/>
<el-table-column label="名称" align="center" width="100"> <el-table-column label="名称" align="center" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -296,12 +296,12 @@
</el-table-column> </el-table-column>
<el-table-column label="图号或型号" align="center" min-width="150"> <el-table-column label="图号或型号" align="center" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.物料型号 ? scope.row.物料型号 : scope.row.零件图号 }} {{ scope.row.图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="规格" align="center" min-width="150"> <el-table-column label="规格" align="center" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.物料规格 ? scope.row.物料规格 : scope.row.规格 }} {{ scope.row.规格 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="采购数量" align="center" width="80"> <el-table-column label="采购数量" align="center" width="80">
@@ -654,6 +654,7 @@ export default {
searchTable02(row) { searchTable02(row) {
this.tableData02 = [] this.tableData02 = []
this.tableData03 = [] this.tableData03 = []
console.log(row, 222)
if (this.contractType === '采购合同') { if (this.contractType === '采购合同') {
if (row.模板类型 === 4) { if (row.模板类型 === 4) {
this.type = row.模板类型 this.type = row.模板类型
@@ -662,14 +663,17 @@ export default {
this.$set(data, '本次到票数量', 0) this.$set(data, '本次到票数量', 0)
data.本次到票数量 = data.已到货数量 - data.到票数量 data.本次到票数量 = data.已到货数量 - data.到票数量
this.tableData03.push(data) this.tableData03.push(data)
console.log(this.tableData03, 111)
}) })
}) })
} else { } else {
searchPurchaseDetail(row.采购合同流水号).then(response => { searchPurchaseDetail(row.采购合同流水号).then(response => {
console.log(response, 88)
response.data.map(data => { response.data.map(data => {
this.$set(data, '本次到票数量', 0) this.$set(data, '本次到票数量', 0)
data.本次到票数量 = data.已到货数量 - data.到票数量 data.本次到票数量 = data.已到货数量 - data.到票数量
this.tableData02.push(data) this.tableData02.push(data)
console.log(this.tableData02, 111)
}) })
}) })
} }
@@ -681,6 +685,7 @@ export default {
this.tableData02.push(data) this.tableData02.push(data)
}) })
}) })
console.log(this.tableData03, 112)
} }
}, },
handleSelectionChange(val) { handleSelectionChange(val) {

View File

@@ -121,7 +121,7 @@
</el-tooltip> </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"> <div style="display: inline-block">
<el-button :disabled="disable === '1'" type="text" size="mini" style="margin-left: 20px" icon="el-icon-circle-close" @click="deleteArrivalMX(scope.row)"/> <el-button :disabled="disable === '1'" type="text" size="mini" style="margin-left: 20px" icon="el-icon-top" @click="deleteArrivalMX(scope.row)"/>
</div> </div>
</el-tooltip> </el-tooltip>
</template> </template>
@@ -188,7 +188,7 @@
<template slot-scope="scope"> <template slot-scope="scope">
<el-tooltip effect="dark" content="取消关联" placement="top"> <el-tooltip effect="dark" content="取消关联" placement="top">
<div style="display: inline-block"> <div style="display: inline-block">
<el-button :disabled="disable === '1'" type="text" icon="el-icon-circle-close" size="mini" @click="deleteMateriel(scope.row)"/> <el-button :disabled="disable === '1'" type="text" icon="el-icon-top" size="mini" @click="deleteMateriel(scope.row)"/>
</div> </div>
</el-tooltip> </el-tooltip>
</template> </template>
@@ -326,12 +326,12 @@
</el-table-column> </el-table-column>
<el-table-column label="到货件数" align="center" width="120px"> <el-table-column label="到货件数" align="center" width="120px">
<template slot-scope="scope"> <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)"/> <el-input-number v-model="scope.row.未到货数量" :disabled="disable === '1'" :max="scope.row.采购数量-parseInt(scope.row.到货数量)" :step="1" :min="0.00" size="mini" style="width:100%" @change="saveData(scope.row)"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="到货重量(KG)" align="center" width="120px" prop="到货重量"> <el-table-column label="到货重量(KG)" align="center" width="150px" prop="到货重量">
<template slot-scope="scope"> <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)"/> <el-input-number v-model="scope.row.到货重量" :disabled="disable === '1'" :step="1" :min="0.00" size="mini" style="width:100%" @change="saveData(scope.row)"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="成品尺寸(长、宽、高)" align="center" width="170px"> <el-table-column label="成品尺寸(长、宽、高)" align="center" width="170px">
@@ -451,7 +451,7 @@
{{ scope.row.到货数量 }} {{ scope.row.到货数量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="到货件数" align="center" width="120px"> <el-table-column label="到货件数" align="center" width="90px">
<template slot-scope="scope"> <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)"/> <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> </template>

View File

@@ -235,7 +235,7 @@
<el-dialog v-el-drag-dialog :title="title2" :visible.sync="dialogVisible2" center style="min-height: 300px" width="350px"> <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 ref="form2" :model="form2" :rules="rules2" label-position="right" label-width="80px">
<el-form-item label="计划名称" prop="计划名称"> <el-form-item label="计划名称" prop="计划名称">
<el-input v-model="form2.离线采购计划名称" size="small"/> <el-input v-model="form2.计划名称" size="small"/>
</el-form-item> </el-form-item>
<el-form-item label="供应商" prop="supplierNameValue"> <el-form-item label="供应商" prop="supplierNameValue">
<el-select v-model="form2.supplierNameValue" placeholder="供应商" size="small" filterable> <el-select v-model="form2.supplierNameValue" placeholder="供应商" size="small" filterable>
@@ -302,12 +302,12 @@ export default {
计划完成日期: '', 计划完成日期: '',
采购单名称: '', 采购单名称: '',
form2: { form2: {
离线采购计划名称: '', 计划名称: '',
supplierNameValue: '', supplierNameValue: '',
离线采购计划流水号: '' 离线采购计划流水号: ''
}, },
rules2: { rules2: {
计划名称: [{ required: true, message: '请填写离线采购计划名称' }], 计划名称: [{ required: true, message: '请填写计划名称' }],
supplierNameValue: [{ required: true, message: '请选择供应商' }] supplierNameValue: [{ required: true, message: '请选择供应商' }]
}, },
form3: { form3: {
@@ -509,7 +509,7 @@ export default {
if (this.$refs['form2'] !== undefined) { if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields() this.$refs['form2'].resetFields()
} }
this.form2.离线采购计划名称 = '' this.form2.计划名称 = ''
this.form2.supplierNameValue = '' this.form2.supplierNameValue = ''
this.title2 = '创建外购备料计划' this.title2 = '创建外购备料计划'
this.dialogVisible2 = true this.dialogVisible2 = true
@@ -517,7 +517,7 @@ export default {
submitAddPurchaseOrder() { // 新建采购单 submitAddPurchaseOrder() { // 新建采购单
this.$refs['form2'].validate((valid) => { this.$refs['form2'].validate((valid) => {
if (valid) { if (valid) {
addPurchaseOrder(this.form2.离线采购计划名称, this.form2.supplierNameValue).then(response => { addPurchaseOrder(this.form2.计划名称, this.form2.supplierNameValue).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('新建离线外购备料成功') this.$message.success('新建离线外购备料成功')
this.searchTable() this.searchTable()
@@ -535,14 +535,14 @@ export default {
} }
this.title2 = '编辑外购备料计划' this.title2 = '编辑外购备料计划'
this.form2.离线采购计划流水号 = row.离线采购计划流水号 this.form2.离线采购计划流水号 = row.离线采购计划流水号
this.form2.离线采购计划名称 = row.离线采购计划名称 this.form2.计划名称 = row.离线采购计划名称
this.form2.supplierNameValue = row.供应商流水号 this.form2.supplierNameValue = row.供应商流水号
this.dialogVisible2 = true this.dialogVisible2 = true
}, },
submitEditPurchaseOrder() { submitEditPurchaseOrder() {
this.$refs['form2'].validate((valid) => { this.$refs['form2'].validate((valid) => {
if (valid) { if (valid) {
editPurchaseOrder(this.form2.离线采购计划流水号, this.form2.离线采购计划名称, this.form2.supplierNameValue).then(response => { editPurchaseOrder(this.form2.离线采购计划流水号, this.form2.计划名称, this.form2.supplierNameValue).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('修改离线外购备料成功') this.$message.success('修改离线外购备料成功')
this.searchTable() this.searchTable()