质检页面bug修改
This commit is contained in:
@@ -7,8 +7,8 @@ const os = require('os')
|
|||||||
|
|
||||||
const networkInterfaces = os.networkInterfaces()
|
const networkInterfaces = os.networkInterfaces()
|
||||||
|
|
||||||
const ip = networkInterfaces['WLAN'][1] ? networkInterfaces['WLAN'][1].address : networkInterfaces['WLAN'][0].address
|
// const ip = networkInterfaces['WLAN'][1] ? networkInterfaces['WLAN'][1].address : networkInterfaces['WLAN'][0].address
|
||||||
// const ip = '127.0.0.1'
|
const ip = '127.0.0.1'
|
||||||
module.exports = {
|
module.exports = {
|
||||||
dev: {
|
dev: {
|
||||||
// Paths
|
// Paths
|
||||||
|
|||||||
@@ -1,74 +1,38 @@
|
|||||||
import request from '@/utils/request'
|
import request from '@/utils/request'
|
||||||
|
|
||||||
// 初始化 外协厂商
|
|
||||||
export function initOutHelp() {
|
|
||||||
return request({
|
|
||||||
url: '',
|
|
||||||
method: 'post',
|
|
||||||
data: {
|
|
||||||
type: '1',
|
|
||||||
name: '车间生产管理工艺_基础表_外协厂家_查询数据'
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 查询表格数据
|
// 查询表格数据
|
||||||
export function searchtable(num2, ManufacturerName, num10, ManufacturerAbbreviation, num3, address, num4, roleName, phNumber, Fax, pageCurrent, pageSize) {
|
export function searchtable(check1, ManufacturerAbbreviation, check2, starttime, endTime, pageCurrent, pageSize) {
|
||||||
return request({
|
return request({
|
||||||
url: '',
|
url: '',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: {
|
data: {
|
||||||
type: '1',
|
type: '1',
|
||||||
name: '车间生产管理_外协加工任务单_查询数据_付款计划',
|
name: '车间生产管理工艺_外协付款_查询',
|
||||||
param: '外协加工任务单_check=0&外协加工任务单流水号=0&表单号_check=' + num2 + '&表单号=' + ManufacturerName + '&外协厂家_check=' + num10 + '&外协厂家=' + ManufacturerAbbreviation + '&任务下达日期时间_check=' + num3 + '&开始时间=' + address + '&结束时间=' + num4 + '&实际付款时间段_check=' + roleName + '&实际付款开始时间=' + phNumber + '&实际付款结束时间=' + Fax + '&外协计划员编号_check=0&外协计划员编号=0',
|
param: '外协厂家_check=' + check1 + '&外协厂家=' + ManufacturerAbbreviation + '&时间_check=' + check2 + '&开始时间=' + starttime + '&结束时间=' + endTime,
|
||||||
Pagination: pageCurrent + '&' + pageSize
|
Pagination: pageCurrent + '&' + pageSize
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 修改实际付款日期
|
export function getInvoice(Number, pageCurrent, pageSize) {
|
||||||
export function payTime(num, time) {
|
|
||||||
return request({
|
|
||||||
url: '',
|
|
||||||
method: 'post',
|
|
||||||
data: {
|
|
||||||
type: '2',
|
|
||||||
name: '车间生产管理_外协加工任务单_修改数据_实际付款时间',
|
|
||||||
param: '外协加工任务单流水号=' + num + '&实际付款时间=' + time
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 修改扣款数据、扣款说明
|
|
||||||
export function WithdrawingEdit(num, quality, Explain) {
|
|
||||||
return request({
|
|
||||||
url: '',
|
|
||||||
method: 'post',
|
|
||||||
data: {
|
|
||||||
type: '2',
|
|
||||||
name: '车间生产管理_外协扣款_编辑数据',
|
|
||||||
param: '外协加工任务单流水号=' + num + '&扣款_质量=' + quality + '&扣款说明=' + Explain
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 单据状态: 1 未成交 2 成交 3 作废
|
|
||||||
export function payment(num) {
|
|
||||||
return request({
|
|
||||||
url: '',
|
|
||||||
method: 'post',
|
|
||||||
data: {
|
|
||||||
type: '2',
|
|
||||||
name: '车间生产管理_外协加工任务单_修改数据_作废',
|
|
||||||
param: '外协加工任务单流水号=' + num + '&单据状态=3'
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 查询零件信息
|
|
||||||
export function getParts(check, Number, pageCurrent, pageSize) {
|
|
||||||
return request({
|
return request({
|
||||||
url: '',
|
url: '',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: {
|
data: {
|
||||||
type: '1',
|
type: '1',
|
||||||
name: '车间生产管理工艺_外协发票管理_查询数据',
|
name: '车间生产管理工艺_外协发票管理_查询数据',
|
||||||
param: '外协厂家流水号_check=' + check + '&外协厂家流水号=' + Number + '=int',
|
param: '外协厂家流水号_check=1&外协厂家流水号=' + Number,
|
||||||
|
Pagination: pageCurrent + '&' + pageSize
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
export function getPayment(Number, pageCurrent, pageSize) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '1',
|
||||||
|
name: '车间生产管理工艺_外协付款记录_查询数据',
|
||||||
|
param: '外协厂家流水号=' + Number,
|
||||||
Pagination: pageCurrent + '&' + pageSize
|
Pagination: pageCurrent + '&' + pageSize
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -12,14 +12,14 @@ export function initOutHelp() {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 初始化获取已生成的外协加工任务单
|
// 初始化获取已生成的外协加工任务单
|
||||||
export function getTable(checked, contractNumber, checked1, manufacturers, checked2, time1, time2, num, pageCurrent, pageSize, documentStatus, num3) {
|
export function getTable(checked, contractNumber, checked1, manufacturers, checked2, time1, time2, num, pageCurrent, pageSize, documentStatus, num3, check) {
|
||||||
return request({
|
return request({
|
||||||
url: '',
|
url: '',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: {
|
data: {
|
||||||
type: '1',
|
type: '1',
|
||||||
name: '车间生产管理_外协加工任务单_查询数据',
|
name: '车间生产管理_外协加工任务单_查询数据_2020',
|
||||||
param: '外协加工任务单_check=0&外协加工任务单流水号=null&表单号_check=' + checked + '&表单号=' + contractNumber + '&外协厂家_check=' + checked1 + '&外协厂家=' + manufacturers + '&任务下达日期_时间段=' + checked2 + '&开始时间=' + time1 + '&结束时间=' + time2 + '&单据状态_check=' + num3 + '&单据状态=' + documentStatus + '&外协员编号_check=0&外协员编号=' + num,
|
param: '外协加工任务单_check=0&外协加工任务单流水号=null&表单号_check=' + checked + '&表单号=' + contractNumber + '&外协厂家_check=' + checked1 + '&外协厂家=' + manufacturers + '&任务下达日期_时间段=' + checked2 + '&开始时间=' + time1 + '&结束时间=' + time2 + '&单据状态_check=' + num3 + '&单据状态=' + documentStatus + '&外协员编号_check=0&外协员编号=' + num + '&查询历史_check=' + check,
|
||||||
Pagination: pageCurrent + '&' + pageSize
|
Pagination: pageCurrent + '&' + pageSize
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -177,7 +177,7 @@ export default {
|
|||||||
selecttable22(this.check1, this.machineNumberValue, this.check2, this.groupNumberValue, this.check3, this.TestValue, this.check4, this.qualityInspectionValue).then(response => {
|
selecttable22(this.check1, this.machineNumberValue, this.check2, this.groupNumberValue, this.check3, this.TestValue, this.check4, this.qualityInspectionValue).then(response => {
|
||||||
import('@/vendor/Export2Excel').then(excel => {
|
import('@/vendor/Export2Excel').then(excel => {
|
||||||
const tHeader = ['是否合格', '机床图号', '机床名称', '组号', '部件名称', '检测项', '检测项明细', '备注']
|
const tHeader = ['是否合格', '机床图号', '机床名称', '组号', '部件名称', '检测项', '检测项明细', '备注']
|
||||||
const filterVal = ['是否合格', '机床图号', '机床名称', '组号', '组件名称', '检测项', '检测项明细', '备注']
|
const filterVal = ['合格情况', '机床图号', '机床名称', '组号', '组件名称', '检测项', '检测项明细', '备注']
|
||||||
const list = response.data
|
const list = response.data
|
||||||
const data = this.formatJson(filterVal, list)
|
const data = this.formatJson(filterVal, list)
|
||||||
excel.export_json_to_excel({
|
excel.export_json_to_excel({
|
||||||
|
|||||||
@@ -579,7 +579,7 @@ export default {
|
|||||||
selecttable22(this.check1, this.machineNumberValue, this.check2, this.groupNumberValue, this.check3, this.SpareParts, this.check4, this.QualityTypeValue, this.check5, this.startTime, this.check6, this.endTime, this.check7, this.qualityInspectionValue, this.check8, this.personNum).then(response => {
|
selecttable22(this.check1, this.machineNumberValue, this.check2, this.groupNumberValue, this.check3, this.SpareParts, this.check4, this.QualityTypeValue, this.check5, this.startTime, this.check6, this.endTime, this.check7, this.qualityInspectionValue, this.check8, this.personNum).then(response => {
|
||||||
import('@/vendor/Export2Excel').then(excel => {
|
import('@/vendor/Export2Excel').then(excel => {
|
||||||
const tHeader = ['是否禁用', '机床图号', '机床名称', '组号', '零件图号', '零件名称', '零件数量', '规格或材料', '工序名称', '质检类型', '检验数量', '不合格数量', '不合格原因', '处理结果', '质检时间', '备注']
|
const tHeader = ['是否禁用', '机床图号', '机床名称', '组号', '零件图号', '零件名称', '零件数量', '规格或材料', '工序名称', '质检类型', '检验数量', '不合格数量', '不合格原因', '处理结果', '质检时间', '备注']
|
||||||
const filterVal = ['是否禁用', '机床图号', '机床名称', '组号', '零件图号', '零件名称', '零件数量', '规格或材料', '工艺名称', '质检类型', '数量', '不合格数量', '不合格原因文本', '不合格处理文本', '操作时间', '备注']
|
const filterVal = ['禁用情况', '机床图号', '机床名称', '组号', '零件图号', '零件名称', '零件数量', '规格或材料', '工艺名称', '质检类型', '数量', '不合格数量', '不合格原因文本', '不合格处理文本', '操作时间', '备注']
|
||||||
const list = response.data
|
const list = response.data
|
||||||
const data = this.formatJson(filterVal, list)
|
const data = this.formatJson(filterVal, list)
|
||||||
excel.export_json_to_excel({
|
excel.export_json_to_excel({
|
||||||
|
|||||||
@@ -553,7 +553,7 @@
|
|||||||
<div style="margin-top: 6px">
|
<div style="margin-top: 6px">
|
||||||
<div class="circle4" style="margin-top: 3px"/>
|
<div class="circle4" style="margin-top: 3px"/>
|
||||||
<el-tooltip>
|
<el-tooltip>
|
||||||
<div slot="content">设备开机<br/>电流计正常工作<br/> 工控机关机</div>
|
<div slot="content">设备开机<br>电流计正常工作<br>工控机关机</div>
|
||||||
<span style="margin-left: 5px">电脑关机</span>
|
<span style="margin-left: 5px">电脑关机</span>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -198,6 +198,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { getData, initProcessing, addTable, editTable, deleteTable, setUp, generate } from '@/api/ManufacturingCenter/WorkshopEquipmentManagement'
|
import { getData, initProcessing, addTable, editTable, deleteTable, setUp, generate } from '@/api/ManufacturingCenter/WorkshopEquipmentManagement'
|
||||||
|
import { getNowTime } from '@/utils/tool'
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -85,14 +85,6 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="操作" align="center" width="160">
|
<el-table-column label="操作" align="center" width="160">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<!--<el-tooltip :open-delay="1200" effect="dark" content="增加机床" placement="top">-->
|
|
||||||
<!--<el-button-->
|
|
||||||
<!--size="mini"-->
|
|
||||||
<!--type="warning"-->
|
|
||||||
<!--plain-->
|
|
||||||
<!--icon="el-icon-plus"-->
|
|
||||||
<!--@click.stop="addMachine(scope.row);flag = 1">机床</el-button>-->
|
|
||||||
<!--</el-tooltip>-->
|
|
||||||
<el-button
|
<el-button
|
||||||
size="mini"
|
size="mini"
|
||||||
type="text"
|
type="text"
|
||||||
|
|||||||
@@ -1,294 +1,151 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
<!--<el-card>-->
|
|
||||||
<!--<span>表单号:</span>-->
|
|
||||||
<!--<el-input v-model="FormNumber" placeholder="表单号" clearable size="small" style="width:190px;margin:10px;"/>-->
|
|
||||||
<!--<span>任务下达时间段:</span>-->
|
|
||||||
<!--<el-date-picker-->
|
|
||||||
<!--v-model="date1"-->
|
|
||||||
<!--style="width:190px;margin:10px;"-->
|
|
||||||
<!--size="small"-->
|
|
||||||
<!--type="date"-->
|
|
||||||
<!--value-format="yyyy-MM-dd"-->
|
|
||||||
<!--format="yyyy-MM-dd"-->
|
|
||||||
<!--placeholder="选择日期"/>-->
|
|
||||||
<!--<span>~</span>-->
|
|
||||||
<!--<el-date-picker-->
|
|
||||||
<!--v-model="date2"-->
|
|
||||||
<!--style="width:190px;margin:10px;"-->
|
|
||||||
<!--size="small"-->
|
|
||||||
<!--type="date"-->
|
|
||||||
<!--value-format="yyyy-MM-dd"-->
|
|
||||||
<!--format="yyyy-MM-dd"-->
|
|
||||||
<!--placeholder="选择日期"/>-->
|
|
||||||
<!--<span>实际付款时间段:</span>-->
|
|
||||||
<!--<el-date-picker-->
|
|
||||||
<!--v-model="date3"-->
|
|
||||||
<!--style="width:190px;margin:10px;"-->
|
|
||||||
<!--size="small"-->
|
|
||||||
<!--type="date"-->
|
|
||||||
<!--value-format="yyyy-MM-dd"-->
|
|
||||||
<!--format="yyyy-MM-dd"-->
|
|
||||||
<!--placeholder="选择日期"/>-->
|
|
||||||
<!--<span>~</span>-->
|
|
||||||
<!--<el-date-picker-->
|
|
||||||
<!--v-model="date4"-->
|
|
||||||
<!--style="width:190px;margin:10px;"-->
|
|
||||||
<!--size="small"-->
|
|
||||||
<!--type="date"-->
|
|
||||||
<!--value-format="yyyy-MM-dd"-->
|
|
||||||
<!--format="yyyy-MM-dd"-->
|
|
||||||
<!--placeholder="选择日期"/>-->
|
|
||||||
<!--</el-card>-->
|
|
||||||
<el-card>
|
<el-card>
|
||||||
<el-row>
|
<el-col :span="8">
|
||||||
<span>厂家:</span>
|
<el-row>
|
||||||
<el-select v-model="ManufacturerNameValue" placeholder="选择外协厂家" filterable clearable size="small" style="width:190px;margin:10px;">
|
<span>外协厂家:</span>
|
||||||
<el-option
|
<el-input v-model="ManufacturerName" size="small" placeholder="外协厂家" clearable style="width:200px"/>
|
||||||
v-for="item in ManufacturerName"
|
<el-button type="success" class="el-icon-search" size="small" @click="pageCurrent=1;pageSize=20;getParts()">查询</el-button>
|
||||||
:key="item.value"
|
</el-row>
|
||||||
:label="item.label"
|
<el-table v-loading="loading" :data="tableData" size="mini" stripe height="500" style="width: 100%;" border element-loading-text="拼命加载中" @row-click="rowClick">
|
||||||
:value="item.value"/>
|
<el-table-column label="厂家" prop="外协厂家名称" align="center" width="230px">
|
||||||
</el-select>
|
<template slot-scope="scope">
|
||||||
<el-button type="primary" class="el-icon-search" size="small" plain @click="pageCurrent=1;pageSize=20;searchTable()">查询</el-button>
|
{{ scope.row.外协厂家名称 }}
|
||||||
</el-row>
|
</template>
|
||||||
<el-table v-loading="loading" :data="tableData" height="500" size="mini" stripe style="width: 100%;" border highlight-current-row element-loading-text="拼命加载中">
|
</el-table-column>
|
||||||
<el-table-column label="序号" type="index" align="center" fixed="left" width="50"/>
|
<el-table-column label="外协金额" prop="总价" align="center" width="200px">
|
||||||
<el-table-column label="付款" prop="实际付款时间" width="65" align="center" fixed="left">
|
<template slot-scope="scope">
|
||||||
<template slot-scope="scope">
|
{{ scope.row.总价 }}
|
||||||
<el-tag v-if="scope.row.实际付款时间!==''" type="success" size="small">已付</el-tag>
|
</template>
|
||||||
<el-tag v-else type="info" size="small">未付</el-tag>
|
</el-table-column>
|
||||||
</template>
|
<el-table-column label="到票金额" align="center" width="130px" prop="开票金额">
|
||||||
</el-table-column>
|
<template slot-scope="scope">
|
||||||
<el-table-column label="到货" prop="单据状态" width="65" align="center" fixed="left">
|
{{ parseFloat(scope.row.开票金额).toFixed(2) }}
|
||||||
<template slot-scope="scope">
|
</template>
|
||||||
<el-tag v-if="scope.row.单据状态==='3'" type="success" size="small">已到</el-tag>
|
</el-table-column>
|
||||||
<el-tag v-else type="info" size="small">未到</el-tag>
|
<el-table-column label="付款金额" align="center">
|
||||||
</template>
|
<template slot-scope="scope">
|
||||||
</el-table-column>
|
{{ scope.row.备注 }}
|
||||||
<el-table-column label="单据号" prop="表单号" align="center" width="180px" fixed="left">
|
</template>
|
||||||
<template slot-scope="scope">
|
</el-table-column>
|
||||||
{{ scope.row.表单号 }}
|
<el-table-column label="未付金额" align="center">
|
||||||
</template>
|
<template slot-scope="scope">
|
||||||
</el-table-column>
|
{{ scope.row.备注 }}
|
||||||
<el-table-column label="外协厂家" prop="外协厂家名称" align="center" min-width="190px" show-overflow-tooltip>
|
</template>
|
||||||
<template slot-scope="scope">
|
</el-table-column>
|
||||||
{{ scope.row.外协厂家名称 }}
|
<el-table-column label="操作" align="center" width="200px">
|
||||||
</template>
|
<template slot-scope="scope">
|
||||||
</el-table-column>
|
<el-button size="mini" type="primary" plain class="el-icon-edit" @click="handleChange1(scope.$index, scope.row, 'form');param = 1">编辑</el-button>
|
||||||
<el-table-column label="总价" align="center" min-width="100px">
|
<el-button size="mini" type="danger" plain class="el-icon-delete" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
|
||||||
<template slot-scope="scope">
|
</template>
|
||||||
{{ parseFloat(scope.row.总价).toFixed(2) }}
|
</el-table-column>
|
||||||
</template>
|
</el-table>
|
||||||
</el-table-column>
|
<div class="block">
|
||||||
<el-table-column label="扣款金额" align="center" min-width="100px">
|
<el-pagination
|
||||||
<template slot-scope="scope">
|
v-if="!loading"
|
||||||
{{ parseFloat(scope.row.扣款_质量).toFixed(2) }}
|
:current-page="pageCurrent"
|
||||||
</template>
|
:page-sizes="[20, 30, 40]"
|
||||||
</el-table-column>
|
:page-size="pageSize"
|
||||||
<!--<el-table-column label="计划扣款" align="center" min-width="70px">-->
|
:total="total"
|
||||||
<!--<template slot-scope="scope">-->
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
<!--{{ scope.row.扣款_计划 }}-->
|
@size-change="handleSizeChange"
|
||||||
<!--</template>-->
|
@current-change="handleCurrentChange"/>
|
||||||
<!--</el-table-column>-->
|
</div>
|
||||||
<!--<el-table-column label="其他扣款" align="center" min-width="70px">-->
|
</el-col>
|
||||||
<!--<template slot-scope="scope">-->
|
<el-col :span="8">
|
||||||
<!--{{ scope.row.扣款_其他 }}-->
|
<el-table v-loading="loading2" :data="tableData2" size="mini" stripe height="500" style="width: 100%;" border element-loading-text="拼命加载中">
|
||||||
<!--</template>-->
|
<el-table-column label="厂家" prop="外协厂家名称" align="center" width="230px">
|
||||||
<!--</el-table-column>-->
|
<template slot-scope="scope">
|
||||||
<el-table-column label="应付金额" align="center" min-width="100px">
|
{{ scope.row.外协厂家名称 }}
|
||||||
<template slot-scope="scope">
|
</template>
|
||||||
{{ scope.row.实际付款时间 === '' ? parseFloat(scope.row.应付总额).toFixed(2) : '-' }}
|
</el-table-column>
|
||||||
</template>
|
<el-table-column label="外协金额" prop="总价" align="center" width="200px">
|
||||||
</el-table-column>
|
<template slot-scope="scope">
|
||||||
<el-table-column label="扣款说明" align="center" min-width="120px">
|
{{ scope.row.总价 }}
|
||||||
<template slot-scope="scope">
|
</template>
|
||||||
{{ scope.row.扣款说明 }}
|
</el-table-column>
|
||||||
</template>
|
<el-table-column label="到票金额" align="center" width="130px" prop="开票金额">
|
||||||
</el-table-column>
|
<template slot-scope="scope">
|
||||||
<el-table-column label="任务下达日期" prop="任务下达日期" align="center" min-width="125px">
|
{{ parseFloat(scope.row.开票金额).toFixed(2) }}
|
||||||
<template slot-scope="scope">
|
</template>
|
||||||
{{ scope.row.任务下达日期 }}
|
</el-table-column>
|
||||||
</template>
|
<el-table-column label="付款金额" align="center">
|
||||||
</el-table-column>
|
<template slot-scope="scope">
|
||||||
<el-table-column label="外协员" prop="外协员姓名" align="center" width="90px">
|
{{ scope.row.备注 }}
|
||||||
<template slot-scope="scope">
|
</template>
|
||||||
{{ scope.row.外协员姓名 }}
|
</el-table-column>
|
||||||
</template>
|
<el-table-column label="未付金额" align="center">
|
||||||
</el-table-column>
|
<template slot-scope="scope">
|
||||||
<!--<el-table-column label="加工价格" align="center">-->
|
{{ scope.row.备注 }}
|
||||||
<!--<el-table-column label="预算总价" align="center" width="85px">-->
|
</template>
|
||||||
<!--<template slot-scope="scope">-->
|
</el-table-column>
|
||||||
<!--{{ scope.row.加工价格_预算_总价 }}-->
|
<el-table-column label="操作" align="center" width="200px">
|
||||||
<!--</template>-->
|
<template slot-scope="scope">
|
||||||
<!--</el-table-column>-->
|
<el-button size="mini" type="primary" plain class="el-icon-edit" @click="handleChange1(scope.$index, scope.row, 'form');param = 1">编辑</el-button>
|
||||||
<!--<el-table-column label="成交总价" align="center" width="85px">-->
|
<el-button size="mini" type="danger" plain class="el-icon-delete" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
|
||||||
<!--<template slot-scope="scope">-->
|
</template>
|
||||||
<!--{{ scope.row.加工价格_成交_总价 }}-->
|
</el-table-column>
|
||||||
<!--</template>-->
|
</el-table>
|
||||||
<!--</el-table-column>-->
|
<div class="block">
|
||||||
<!--</el-table-column>-->
|
<el-pagination
|
||||||
<!--<el-table-column label="材料费" align="center" min-width="70px">-->
|
v-if="!loading2"
|
||||||
<!--<template slot-scope="scope">-->
|
:current-page="pageCurrent2"
|
||||||
<!--{{ scope.row.材料价格_价格_总价 }}-->
|
:page-sizes="[20, 30, 40]"
|
||||||
<!--</template>-->
|
:page-size="pageSize2"
|
||||||
<!--</el-table-column>-->
|
:total="total2"
|
||||||
<!--<el-table-column label="运费" align="center" min-width="70px">-->
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
<!--<template slot-scope="scope">-->
|
@size-change="handleSizeChange2"
|
||||||
<!--{{ scope.row.运费 }}-->
|
@current-change="handleCurrentChange2"/>
|
||||||
<!--</template>-->
|
</div>
|
||||||
<!--</el-table-column>-->
|
</el-col>
|
||||||
<!--<el-table-column label="其他费用" align="center" min-width="70px">-->
|
<el-col :span="8">
|
||||||
<!--<template slot-scope="scope">-->
|
<el-table v-loading="loading3" :data="tableData3" size="mini" stripe height="500" style="width: 100%;" border element-loading-text="拼命加载中">
|
||||||
<!--{{ scope.row.其他价格_总价 }}-->
|
<el-table-column label="厂家" prop="外协厂家名称" align="center" width="230px">
|
||||||
<!--</template>-->
|
<template slot-scope="scope">
|
||||||
<!--</el-table-column>-->
|
{{ scope.row.外协厂家名称 }}
|
||||||
<!--<el-table-column label="总价" align="center" min-width="70px">-->
|
</template>
|
||||||
<!--<template slot-scope="scope">-->
|
</el-table-column>
|
||||||
<!--{{ scope.row.总价 }}-->
|
<el-table-column label="外协金额" prop="总价" align="center" width="200px">
|
||||||
<!--</template>-->
|
<template slot-scope="scope">
|
||||||
<!--</el-table-column>-->
|
{{ scope.row.总价 }}
|
||||||
<!--<el-table-column label="付款日期" align="center" width="240px">-->
|
</template>
|
||||||
<!--<el-table-column label="入库" align="center" min-width="70px">-->
|
</el-table-column>
|
||||||
<!--<template slot-scope="scope">-->
|
<el-table-column label="到票金额" align="center" width="130px" prop="开票金额">
|
||||||
<!--{{ scope.row.入库时间 }}-->
|
<template slot-scope="scope">
|
||||||
<!--</template>-->
|
{{ parseFloat(scope.row.开票金额).toFixed(2) }}
|
||||||
<!--</el-table-column>-->
|
</template>
|
||||||
<!--<el-table-column label="计划" align="center" min-width="70px">-->
|
</el-table-column>
|
||||||
<!--<template slot-scope="scope">-->
|
<el-table-column label="付款金额" align="center">
|
||||||
<!--{{ scope.row.计划付款时间 }}-->
|
<template slot-scope="scope">
|
||||||
<!--</template>-->
|
{{ scope.row.备注 }}
|
||||||
<!--</el-table-column>-->
|
</template>
|
||||||
<!--<el-table-column label="实际" align="center" min-width="70px">-->
|
</el-table-column>
|
||||||
<!--<template slot-scope="scope">-->
|
<el-table-column label="未付金额" align="center">
|
||||||
<!--{{ scope.row.实际付款时间 }}-->
|
<template slot-scope="scope">
|
||||||
<!--</template>-->
|
{{ scope.row.备注 }}
|
||||||
<!--</el-table-column>-->
|
</template>
|
||||||
<!--</el-table-column>-->
|
</el-table-column>
|
||||||
<el-table-column label="操作" align="center" width="200px" fixed="right">
|
<el-table-column label="操作" align="center" width="200px">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<!--<el-tooltip :open-delay="1200" effect="dark" content="记录外协付款到票信息" placement="top">-->
|
<el-button size="mini" type="primary" plain class="el-icon-edit" @click="handleChange1(scope.$index, scope.row, 'form');param = 1">编辑</el-button>
|
||||||
<!--<el-button :disabled="scope.row.实际付款时间!==''" size="mini" type="primary" plain class="el-icon-check" @click="editType1(scope.row, 'form');param = 0">到票</el-button>-->
|
<el-button size="mini" type="danger" plain class="el-icon-delete" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
|
||||||
<!--</el-tooltip>-->
|
</template>
|
||||||
<el-tooltip :open-delay="1200" effect="dark" content="记录外协扣款信息" placement="top">
|
</el-table-column>
|
||||||
<el-button :disabled="scope.row.实际付款时间!==''" size="mini" type="primary" plain class="el-icon-edit" @click="Withdrawing(scope.$index, scope.row, 'form2')">扣款</el-button>
|
</el-table>
|
||||||
</el-tooltip>
|
<div class="block">
|
||||||
<el-tooltip :open-delay="1200" effect="dark" content="付款信息" placement="top">
|
<el-pagination
|
||||||
<el-button :disabled="scope.row.实际付款时间!==''||scope.row.单据状态!=='3'" size="mini" type="success" class="el-icon-check" @click="payment(scope.$index, scope.row)">付款</el-button>
|
v-if="!loading3"
|
||||||
</el-tooltip>
|
:current-page="pageCurrent3"
|
||||||
</template>
|
:page-sizes="[20, 30, 40]"
|
||||||
</el-table-column>
|
:page-size="pageSize3"
|
||||||
</el-table>
|
:total="total3"
|
||||||
<div class="block">
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
<el-pagination
|
@size-change="handleSizeChange3"
|
||||||
v-if="!loading"
|
@current-change="handleCurrentChange3"/>
|
||||||
:current-page="pageCurrent"
|
</div>
|
||||||
:page-sizes="[20, 30, 40]"
|
</el-col>
|
||||||
:page-size="pageSize"
|
|
||||||
:total="total"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
@size-change="handleSizeChange"
|
|
||||||
@current-change="handleCurrentChange"/>
|
|
||||||
</div>
|
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
<el-card>
|
|
||||||
<el-row>
|
|
||||||
<span>厂家:</span>
|
|
||||||
<el-select v-model="ManufacturerNameValue2" placeholder="选择外协厂家" filterable clearable size="small" style="width:190px;margin:10px;">
|
|
||||||
<el-option
|
|
||||||
v-for="item in ManufacturerName2"
|
|
||||||
:key="item.value"
|
|
||||||
:label="item.label"
|
|
||||||
:value="item.value"/>
|
|
||||||
</el-select>
|
|
||||||
<el-button type="success" class="el-icon-search" size="small" @click="pageCurrent2=1;pageSize2=20;getParts()">查询</el-button>
|
|
||||||
<el-tooltip :open-delay="1200" effect="dark" content="记录外协付款到票信息" placement="top">
|
|
||||||
<el-button size="small" type="primary" plain class="el-icon-check" @click="editType1('form');param = 0">到票</el-button>
|
|
||||||
</el-tooltip>
|
|
||||||
</el-row>
|
|
||||||
<el-table v-loading="loading2" :data="tableData2" :summary-method="getSummaries" size="mini" stripe height="370" show-summary style="width: 100%;" border element-loading-text="拼命加载中">
|
|
||||||
<el-table-column label="厂家" prop="发票号" align="center" width="230px">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ scope.row.外协厂家名称 }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="发票号" prop="发票号" align="center" width="200px">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ scope.row.发票号 }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<!--<el-table-column label="接收人" prop="接收人" align="center" width="100px">-->
|
|
||||||
<!--<template slot-scope="scope">-->
|
|
||||||
<!--{{ scope.row.接收人 }}-->
|
|
||||||
<!--</template>-->
|
|
||||||
<!--</el-table-column>-->
|
|
||||||
<!--<el-table-column label="开户行" align="center" width="150px" show-overflow-tooltip="">-->
|
|
||||||
<!--<template slot-scope="scope">-->
|
|
||||||
<!--{{ scope.row.开户行 }}-->
|
|
||||||
<!--</template>-->
|
|
||||||
<!--</el-table-column>-->
|
|
||||||
<el-table-column label="开票金额" align="center" width="130px" prop="开票金额">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ parseFloat(scope.row.开票金额).toFixed(2) }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="开票日期" align="center" width="100px">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ scope.row.开票时间 === '1900/1/1' ? '-' : scope.row.开票时间 }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="接收日期" align="center" width="100px">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ scope.row.接收时间 === '1900/1/1' ? '-' : scope.row.接收时间 }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="备注" align="center">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
{{ scope.row.备注 }}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" align="center" width="200px">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<el-button size="mini" type="primary" plain class="el-icon-edit" @click="handleChange1(scope.$index, scope.row, 'form');param = 1">编辑</el-button>
|
|
||||||
<el-button size="mini" type="danger" plain class="el-icon-delete" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<div class="block">
|
|
||||||
<el-pagination
|
|
||||||
v-if="!loading2"
|
|
||||||
:current-page="pageCurrent2"
|
|
||||||
:page-sizes="[20, 30, 40]"
|
|
||||||
:page-size="pageSize2"
|
|
||||||
:total="total2"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
@size-change="handleSizeChange2"
|
|
||||||
@current-change="handleCurrentChange2"/>
|
|
||||||
</div>
|
|
||||||
</el-card>
|
|
||||||
|
|
||||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible2" title="扣款" center style="min-height: 300px" width="500px">
|
|
||||||
<el-form ref="form2" :model="form2" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">
|
|
||||||
<el-form-item label="扣款金额" prop="质量" style="margin-left: 70px">
|
|
||||||
<el-input v-model="form2.质量" placeholder="扣款金额" size="small" style="width:200px"/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="扣款说明" prop="扣款说明" style="margin-left: 70px">
|
|
||||||
<el-input v-model="form2.扣款说明" placeholder="扣款说明" size="small" style="width:200px"/>
|
|
||||||
</el-form-item>
|
|
||||||
<!--<el-form-item label="计划" style="margin-left: 200px">-->
|
|
||||||
<!--<el-input v-model="form2.计划" placeholder="计划" size="small" style="width:200px"/>-->
|
|
||||||
<!--</el-form-item>-->
|
|
||||||
<!--<el-form-item label="其他" style="margin-left: 200px">-->
|
|
||||||
<!--<el-input v-model="form2.其他" placeholder="其他" size="small" style="width:200px"/>-->
|
|
||||||
<!--</el-form-item>-->
|
|
||||||
</el-form>
|
|
||||||
<div slot="footer" class="dialog-footer">
|
|
||||||
<el-button @click="callOff2('form2')">取消</el-button>
|
|
||||||
<el-button type="primary" @click="submit2('form2')">确定</el-button>
|
|
||||||
</div>
|
|
||||||
</el-dialog>
|
|
||||||
|
|
||||||
<el-dialog v-el-drag-dialog :title="title1" :visible.sync="dialogFormVisible" center style="min-height: 300px" width="700px">
|
<el-dialog v-el-drag-dialog :title="title1" :visible.sync="dialogFormVisible" center style="min-height: 300px" width="700px">
|
||||||
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="90px" class="demo-ruleForm">
|
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="90px" class="demo-ruleForm">
|
||||||
<el-row v-show="title1==='到票'">
|
<el-row v-show="title1==='到票'">
|
||||||
@@ -330,38 +187,6 @@
|
|||||||
placeholder="开票时间"/>
|
placeholder="开票时间"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
|
||||||
<el-form-item label="开户行" prop="开户行">
|
|
||||||
<el-input v-model="form.开户行" placeholder="开户行" style="width:200px" clearable size="small" />
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="12">
|
|
||||||
<el-form-item label="接收人" prop="接收人">
|
|
||||||
<el-input v-model="form.接收人" placeholder="接收人" style="width:200px" clearable size="small"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="12">
|
|
||||||
<el-form-item label="接收时间" prop="接收时间">
|
|
||||||
<el-date-picker
|
|
||||||
v-model="form.接收时间"
|
|
||||||
style="width:200px"
|
|
||||||
size="small"
|
|
||||||
type="date"
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
format="yyyy-MM-dd"
|
|
||||||
clearable
|
|
||||||
placeholder="接收时间"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="24">
|
|
||||||
<el-form-item label="备注" prop="备注">
|
|
||||||
<el-input v-model="form.备注" :rows="2" placeholder="备注" type="textarea" style="width:527px" clearable size="small"/>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div slot="footer" class="dialog-footer">
|
<div slot="footer" class="dialog-footer">
|
||||||
@@ -373,16 +198,14 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { initOutHelp, searchtable, payTime, WithdrawingEdit, getParts, edittype, handlechange, handledelete } from '@/api/Outsourcing/OutsourcingPaymentPlanManagement'
|
import { searchtable, getInvoice, getPayment, edittype, handlechange, handledelete } from '@/api/Outsourcing/OutsourcingPaymentPlanManagement'
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
fukuanshijian: '',
|
ManufacturerName: '', // 外协厂家
|
||||||
|
外协厂家流水号: '',
|
||||||
title1: '',
|
title1: '',
|
||||||
dialogFormVisible: false,
|
dialogFormVisible: false,
|
||||||
renwudan: '',
|
|
||||||
count1: 0,
|
|
||||||
count2: 0,
|
|
||||||
form: {
|
form: {
|
||||||
外协厂家: '',
|
外协厂家: '',
|
||||||
发票号: '',
|
发票号: '',
|
||||||
@@ -394,230 +217,95 @@ export default {
|
|||||||
备注: ''
|
备注: ''
|
||||||
},
|
},
|
||||||
外协厂家: [],
|
外协厂家: [],
|
||||||
实际付款时间: '',
|
rules: {},
|
||||||
loading: false,
|
loading: false,
|
||||||
loading2: false,
|
|
||||||
zhongjianbianliang: '',
|
|
||||||
dialogFormVisible2: false,
|
|
||||||
form2: {
|
|
||||||
质量: '',
|
|
||||||
计划: '',
|
|
||||||
其他: '',
|
|
||||||
扣款说明: ''
|
|
||||||
},
|
|
||||||
rules: {
|
|
||||||
外协厂家: [{ required: true, message: '请选择外协厂家', trigger: 'change' }],
|
|
||||||
发票号: [{ required: true, message: '请输入发票号', trigger: 'blur' }],
|
|
||||||
开票金额: [{ required: true, message: '请输入开票金额', trigger: 'blur' }],
|
|
||||||
质量: [{ required: true, message: '请输入扣款金额', trigger: 'blur' }],
|
|
||||||
扣款说明: [{ required: true, message: '请输入扣款说明', trigger: 'blur' }]
|
|
||||||
},
|
|
||||||
date1: '',
|
|
||||||
date2: '',
|
|
||||||
date3: '',
|
|
||||||
date4: '',
|
|
||||||
FormNumber: '',
|
|
||||||
ManufacturerNameValue: '',
|
|
||||||
ManufacturerName: [], // 厂家名称
|
|
||||||
ManufacturerNameValue2: '',
|
|
||||||
ManufacturerName2: [], // 厂家名称
|
|
||||||
FormNumber_check: false,
|
|
||||||
ManufacturerNameValue_check: false,
|
|
||||||
date1_check: false,
|
|
||||||
date3_check: false,
|
|
||||||
tableData: [], // 表格数据
|
tableData: [], // 表格数据
|
||||||
total: null, // 总条数
|
total: null, // 总条数
|
||||||
pageSize: 20, // 每页显示条数
|
pageSize: 20, // 每页显示条数
|
||||||
pageCurrent: 1, // 后台获取页
|
pageCurrent: 1, // 后台获取页
|
||||||
|
loading2: false,
|
||||||
tableData2: [], // 表格数据
|
tableData2: [], // 表格数据
|
||||||
total2: null, // 总条数
|
total2: null, // 总条数
|
||||||
pageSize2: 20, // 每页显示条数
|
pageSize2: 20, // 每页显示条数
|
||||||
pageCurrent2: 1 // 后台获取页
|
pageCurrent2: 1, // 后台获取页
|
||||||
|
loading3: false,
|
||||||
|
tableData3: [], // 表格数据
|
||||||
|
total3: null, // 总条数
|
||||||
|
pageSize3: 20, // 每页显示条数
|
||||||
|
pageCurrent3: 1 // 后台获取页
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.fetchData()
|
|
||||||
this.searchTable()
|
|
||||||
this.getParts()
|
this.getParts()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getSummaries(param) {
|
// 获取表格1数据
|
||||||
const { data } = param
|
|
||||||
const sums = ['', '', 0, '', '', '', '']
|
|
||||||
sums[0] = '合计'
|
|
||||||
for (let i = 0; i < data.length; i++) {
|
|
||||||
sums[2] += parseInt(data[i].开票金额)
|
|
||||||
}
|
|
||||||
// sums[2] = Math.round(sums[2] * 100) / 100 + ' 元'
|
|
||||||
sums[2] = parseFloat(sums[2]).toFixed(2) + ' 元'
|
|
||||||
return sums
|
|
||||||
},
|
|
||||||
// 初始化外协厂家
|
|
||||||
fetchData() {
|
|
||||||
this.ManufacturerName = []
|
|
||||||
this.ManufacturerName2 = []
|
|
||||||
this.外协厂家 = []
|
|
||||||
initOutHelp().then(response => {
|
|
||||||
for (let i = 0; i < response.data.length; i++) {
|
|
||||||
this.ManufacturerName.push({
|
|
||||||
label: response.data[i].外协厂家名称,
|
|
||||||
value: response.data[i].外协厂家流水号
|
|
||||||
})
|
|
||||||
this.ManufacturerName2.push({
|
|
||||||
label: response.data[i].外协厂家名称,
|
|
||||||
value: response.data[i].外协厂家流水号
|
|
||||||
})
|
|
||||||
this.外协厂家.push({
|
|
||||||
label: response.data[i].外协厂家名称,
|
|
||||||
value: response.data[i].外协厂家流水号
|
|
||||||
})
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 查询表格数据
|
|
||||||
searchTable() {
|
|
||||||
this.loading = true
|
|
||||||
if (this.FormNumber === '' || this.FormNumber === null) {
|
|
||||||
this.FormNumber_check = false
|
|
||||||
} else {
|
|
||||||
this.FormNumber_check = true
|
|
||||||
}
|
|
||||||
if (this.ManufacturerNameValue === '' || this.ManufacturerNameValue === null) {
|
|
||||||
this.ManufacturerNameValue_check = false
|
|
||||||
} else {
|
|
||||||
this.ManufacturerNameValue_check = true
|
|
||||||
}
|
|
||||||
if (this.date1 === '' || this.date1 === null) {
|
|
||||||
this.date1_check = false
|
|
||||||
} else {
|
|
||||||
this.date1_check = true
|
|
||||||
}
|
|
||||||
if (this.date3 === '' || this.date3 === null) {
|
|
||||||
this.date3_check = false
|
|
||||||
} else {
|
|
||||||
this.date3_check = true
|
|
||||||
}
|
|
||||||
this.tableData = []
|
|
||||||
searchtable(this.FormNumber_check, this.FormNumber, this.ManufacturerNameValue_check, this.ManufacturerNameValue, this.date1_check, this.date1, this.date2, this.date3_check, this.date3, this.date4, this.pageCurrent, this.pageSize).then(response => {
|
|
||||||
for (let i = 0; i < response.data.rows.length; i++) {
|
|
||||||
response.data.rows[i].任务下达日期 = response.data.rows[i].任务下达日期.substring(0, response.data.rows[i].任务下达日期.indexOf(' '))
|
|
||||||
response.data.rows[i].实际付款时间 = response.data.rows[i].实际付款时间.substring(0, response.data.rows[i].实际付款时间.indexOf(' '))
|
|
||||||
}
|
|
||||||
this.tableData = response.data.rows
|
|
||||||
this.total = response.data.total
|
|
||||||
}).then(() => {
|
|
||||||
this.loading = false
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 付款
|
|
||||||
payment(index, row) {
|
|
||||||
this.$confirm('请仔细核对信息,确定后不可更改, 是否继续?', '提示', {
|
|
||||||
confirmButtonText: '确定',
|
|
||||||
cancelButtonText: '取消',
|
|
||||||
type: 'success'
|
|
||||||
}).then(() => {
|
|
||||||
var time = new Date()
|
|
||||||
var month = time.getMonth() + 1
|
|
||||||
var day = time.getDate()
|
|
||||||
if (month >= 1 && month <= 9) {
|
|
||||||
month = '0' + month
|
|
||||||
}
|
|
||||||
if (day >= 1 && day <= 9) {
|
|
||||||
day = '0' + day
|
|
||||||
}
|
|
||||||
this.实际付款时间 = time.getFullYear() + '/' + month + '/' + day
|
|
||||||
payTime(row.外协加工任务单流水号, this.实际付款时间).then(response => {
|
|
||||||
if (response.data[0].result === '1') {
|
|
||||||
this.$message.success('付款成功')
|
|
||||||
this.searchTable()
|
|
||||||
} else {
|
|
||||||
this.$message.error('付款失败')
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}).catch(() => {
|
|
||||||
this.$message({
|
|
||||||
type: 'info',
|
|
||||||
message: '已取消付款'
|
|
||||||
})
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 打开扣款编辑
|
|
||||||
Withdrawing(index, row) {
|
|
||||||
if (this.$refs['form2'] !== undefined) {
|
|
||||||
this.$refs['form2'].resetFields()
|
|
||||||
}
|
|
||||||
this.form2.质量 = row.扣款_质量
|
|
||||||
this.form2.计划 = row.扣款_计划
|
|
||||||
this.form2.其他 = row.扣款_其他
|
|
||||||
this.form2.扣款说明 = row.扣款说明
|
|
||||||
this.liushuihao = row.外协加工任务单流水号
|
|
||||||
this.dialogFormVisible2 = true
|
|
||||||
},
|
|
||||||
// 扣款编辑确定
|
|
||||||
submit2(formName) {
|
|
||||||
this.$refs[formName].validate((valid) => {
|
|
||||||
if (valid) {
|
|
||||||
this.WithdrawingEdit()
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 扣款编辑
|
|
||||||
WithdrawingEdit() {
|
|
||||||
WithdrawingEdit(this.liushuihao, this.form2.质量, this.form2.扣款说明).then(response => {
|
|
||||||
if (response.data[0].result === '1') {
|
|
||||||
this.$message.success('修改成功')
|
|
||||||
this.searchTable()
|
|
||||||
} else {
|
|
||||||
this.$message.error('修改失败')
|
|
||||||
}
|
|
||||||
this.dialogFormVisible2 = false
|
|
||||||
})
|
|
||||||
},
|
|
||||||
// 关闭扣款编辑
|
|
||||||
callOff2(formName) {
|
|
||||||
this.dialogFormVisible2 = false
|
|
||||||
this.$refs[formName].resetFields()
|
|
||||||
},
|
|
||||||
// 获取表格2数据
|
|
||||||
getParts() {
|
getParts() {
|
||||||
|
this.loading = true
|
||||||
|
this.tableData = []
|
||||||
|
var check
|
||||||
|
var check2 = 0
|
||||||
|
this.ManufacturerName ? check = 1 : check = 0
|
||||||
|
searchtable(check, this.ManufacturerName, check2, '', '', this.pageCurrent, this.pageSize).then(response => {
|
||||||
|
this.loading = false
|
||||||
|
if (response.data.rows.length !== 0) {
|
||||||
|
this.tableData = response.data.rows
|
||||||
|
this.total = response.data.total
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
rowClick(row) {
|
||||||
|
this.外协厂家流水号 = row.外协厂家流水号
|
||||||
this.loading2 = true
|
this.loading2 = true
|
||||||
this.tableData2 = []
|
this.tableData2 = []
|
||||||
let check
|
this.loading3 = true
|
||||||
this.ManufacturerNameValue2 ? check = 1 : check = 0
|
this.tableData3 = []
|
||||||
getParts(check, this.ManufacturerNameValue2, this.pageCurrent2, this.pageSize2).then(response => {
|
getInvoice(row.外协厂家流水号, this.pageCurrent2, this.pageSize2).then(response => {
|
||||||
|
console.log(response.data, 2)
|
||||||
|
this.loading2 = false
|
||||||
|
if (response.data.rows.length !== 0) {
|
||||||
|
this.tableData2 = response.data.rows
|
||||||
|
this.total2 = response.data.total
|
||||||
|
}
|
||||||
|
})
|
||||||
|
getPayment(this.外协厂家流水号, this.pageCurrent2, this.pageSize2).then(response => {
|
||||||
|
console.log(response.data, 3)
|
||||||
|
this.loading3 = false
|
||||||
|
if (response.data.rows.length !== 0) {
|
||||||
|
this.tableData3 = response.data.rows
|
||||||
|
this.total3 = response.data.total
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 发票
|
||||||
|
getInvoice(row) {
|
||||||
|
this.loading2 = true
|
||||||
|
this.tableData2 = []
|
||||||
|
getInvoice(this.外协厂家流水号, this.pageCurrent2, this.pageSize2).then(response => {
|
||||||
|
console.log(response.data, 2)
|
||||||
this.loading2 = false
|
this.loading2 = false
|
||||||
if (response.data.rows.length !== 0) {
|
if (response.data.rows.length !== 0) {
|
||||||
for (let i = 0; i < response.data.rows.length; i++) {
|
|
||||||
response.data.rows[i].开票时间 = response.data.rows[i].开票时间.substring(0, response.data.rows[i].开票时间.indexOf(' '))
|
|
||||||
response.data.rows[i].接收时间 = response.data.rows[i].接收时间.substring(0, response.data.rows[i].接收时间.indexOf(' '))
|
|
||||||
}
|
|
||||||
this.tableData2 = response.data.rows
|
this.tableData2 = response.data.rows
|
||||||
this.total2 = response.data.total
|
this.total2 = response.data.total
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getParts2() {
|
// 付款
|
||||||
this.loading2 = true
|
getPayment(row) {
|
||||||
this.tableData2 = []
|
this.loading3 = true
|
||||||
getParts(this.zhongjianbianliang, this.pageCurrent2, this.pageSize2).then(response => {
|
this.tableData3 = []
|
||||||
for (let i = 0; i < response.data.rows.length; i++) {
|
getPayment(this.外协厂家流水号, this.pageCurrent2, this.pageSize2).then(response => {
|
||||||
response.data.rows[i].开票时间 = response.data.rows[i].开票时间.substring(0, response.data.rows[i].开票时间.indexOf(' '))
|
console.log(response.data, 3)
|
||||||
response.data.rows[i].接收时间 = response.data.rows[i].接收时间.substring(0, response.data.rows[i].接收时间.indexOf(' '))
|
this.loading3 = false
|
||||||
|
if (response.data.rows.length !== 0) {
|
||||||
|
this.tableData3 = response.data.rows
|
||||||
|
this.total3 = response.data.total
|
||||||
}
|
}
|
||||||
this.tableData2 = response.data.rows
|
|
||||||
this.total2 = response.data.total
|
|
||||||
}).then(() => {
|
|
||||||
this.loading2 = false
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 点击增加
|
// 点击增加
|
||||||
editType1(formName) {
|
editType1(formName) {
|
||||||
this.count1 = this.count1 + 1
|
|
||||||
if (this.count1 !== 1) {
|
|
||||||
this.$refs[formName].resetFields()
|
|
||||||
}
|
|
||||||
this.title1 = '到票'
|
this.title1 = '到票'
|
||||||
// this.renwudan = row.外协加工任务单流水号
|
|
||||||
this.form.发票号 = ''
|
this.form.发票号 = ''
|
||||||
this.form.开户行 = ''
|
this.form.开户行 = ''
|
||||||
this.form.开票时间 = ''
|
this.form.开票时间 = ''
|
||||||
@@ -646,16 +334,6 @@ export default {
|
|||||||
},
|
},
|
||||||
// 编辑打开
|
// 编辑打开
|
||||||
handleChange1(index, row, formName) {
|
handleChange1(index, row, formName) {
|
||||||
this.count2 = this.count2 + 1
|
|
||||||
if (this.count2 !== 1) {
|
|
||||||
this.$refs[formName].resetFields()
|
|
||||||
}
|
|
||||||
if (row.开票时间 === '1900/1/1') {
|
|
||||||
row.开票时间 = ''
|
|
||||||
}
|
|
||||||
if (row.接收时间 === '1900/1/1') {
|
|
||||||
row.接收时间 = ''
|
|
||||||
}
|
|
||||||
this.form.外协厂家 = row.外协厂家流水号
|
this.form.外协厂家 = row.外协厂家流水号
|
||||||
this.form.发票号 = row.发票号
|
this.form.发票号 = row.发票号
|
||||||
this.form.开户行 = row.开户行
|
this.form.开户行 = row.开户行
|
||||||
@@ -711,8 +389,8 @@ export default {
|
|||||||
type: 'warning'
|
type: 'warning'
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
handledelete(row.id).then(response => {
|
handledelete(row.id).then(response => {
|
||||||
if (this.tableData2 && this.tableData2.length === 1 && this.pageCurrent2 > 1) {
|
if (this.tableData && this.tableData.length === 1 && this.pageCurrent > 1) {
|
||||||
this.pageCurrent2--
|
this.pageCurrent--
|
||||||
}
|
}
|
||||||
if (response.data[0].result === '1') {
|
if (response.data[0].result === '1') {
|
||||||
this.$notify({
|
this.$notify({
|
||||||
@@ -736,21 +414,29 @@ export default {
|
|||||||
handleSizeChange(val) {
|
handleSizeChange(val) {
|
||||||
this.pageCurrent = 1
|
this.pageCurrent = 1
|
||||||
this.pageSize = val
|
this.pageSize = val
|
||||||
this.searchTable()
|
this.getParts()
|
||||||
},
|
},
|
||||||
handleCurrentChange(val) {
|
handleCurrentChange(val) {
|
||||||
this.pageCurrent = val
|
this.pageCurrent = val
|
||||||
this.searchTable()
|
this.getParts()
|
||||||
},
|
},
|
||||||
handleSizeChange2(val) {
|
handleSizeChange2(val) {
|
||||||
this.pageCurrent2 = 1
|
this.pageCurrent2 = 1
|
||||||
this.pageSize2 = val
|
this.pageSize2 = val
|
||||||
this.getParts()
|
this.getInvoice()
|
||||||
},
|
},
|
||||||
handleCurrentChange2(val) {
|
handleCurrentChange2(val) {
|
||||||
this.pageCurrent2 = val
|
this.pageCurrent2 = val
|
||||||
this.tableData2 = []
|
this.getInvoice()
|
||||||
this.getParts()
|
},
|
||||||
|
handleSizeChange3(val) {
|
||||||
|
this.pageCurrent3 = 1
|
||||||
|
this.pageSize3 = val
|
||||||
|
this.getPayment()
|
||||||
|
},
|
||||||
|
handleCurrentChange3(val) {
|
||||||
|
this.pageCurrent3 = val
|
||||||
|
this.getPayment()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -764,4 +450,3 @@ export default {
|
|||||||
background: #AEF199;
|
background: #AEF199;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
@@ -84,6 +84,7 @@
|
|||||||
<span>厂家:</span>
|
<span>厂家:</span>
|
||||||
<el-input v-model="manufacturers" size="small" placeholder="外协厂家" style="width:160px" clearable @keyup.enter.native="pageSize=20;pageList=1;fetchData()" @clear="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()" @clear="pageSize=20;pageList=1;fetchData()"/>
|
||||||
<el-button type="success" size="mini" icon="el-icon-search" style="margin-left:10px" @click="pageSize=20;pageList=1;fetchData()">查询</el-button>
|
<el-button type="success" size="mini" icon="el-icon-search" style="margin-left:10px" @click="pageSize=20;pageList=1;fetchData()">查询</el-button>
|
||||||
|
<el-checkbox v-model="isChecked" size="small" label="编辑已提交"/>
|
||||||
<el-button type="primary" size="mini" icon="el-icon-circle-plus-outline" style="margin-left:10px" @click="handleAdd()">新增</el-button>
|
<el-button type="primary" size="mini" icon="el-icon-circle-plus-outline" style="margin-left:10px" @click="handleAdd()">新增</el-button>
|
||||||
<el-table v-loading="loading2" :data="List" highlight-current-row height="450" size="mini" stripe border @row-click="searchProcess" >
|
<el-table v-loading="loading2" :data="List" highlight-current-row height="450" size="mini" stripe border @row-click="searchProcess" >
|
||||||
<el-table-column label="表单号" prop="表单号" align="center" min-width="155px">
|
<el-table-column label="表单号" prop="表单号" align="center" min-width="155px">
|
||||||
@@ -341,6 +342,7 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
isChecked: false,
|
||||||
bianliang: [],
|
bianliang: [],
|
||||||
card: false,
|
card: false,
|
||||||
费用: '',
|
费用: '',
|
||||||
@@ -536,7 +538,7 @@ export default {
|
|||||||
}
|
}
|
||||||
this.List = []
|
this.List = []
|
||||||
this.List3 = []
|
this.List3 = []
|
||||||
getTable(this.num, this.formNumber, this.num1, this.manufacturers, this.num2, this.time1, this.time2, this.id, this.pageList, this.pageSize, this.documentStatus, this.num3).then(response => {
|
getTable(this.num, this.formNumber, this.num1, this.manufacturers, this.num2, this.time1, this.time2, this.id, this.pageList, this.pageSize, this.documentStatus, this.num3, this.isChecked).then(response => {
|
||||||
this.total = parseInt(response.data.total)
|
this.total = parseInt(response.data.total)
|
||||||
for (let i = 0; i < response.data.rows.length; i++) {
|
for (let i = 0; i < response.data.rows.length; i++) {
|
||||||
if (response.data.rows[i].任务下达日期 !== null) {
|
if (response.data.rows[i].任务下达日期 !== null) {
|
||||||
|
|||||||
Reference in New Issue
Block a user