Merge branch 'master' of http://192.168.0.149:10010/r/高精2.0
This commit is contained in:
@@ -57,3 +57,25 @@ export function getDaijiagong(num) {
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询总装
|
||||
export function getZongzhuang() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: 'SELECT 机床图号 FROM PDM_机床名称 where 机床装配实际开始时间 is not null and 机床装配实际完成时间 is null'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询部装
|
||||
export function getBuzhuang() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: 'SELECT 机床图号,组号,任务名称 FROM 车间管理_工作计划 inner join PDM_机床名称 on 车间管理_工作计划.机床流水号=PDM_机床名称.机床流水号 where 计划类型=1 and 是否工作=1 and 组号 <> \'\''
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 初始化合同
|
||||
export function initArrivalStateContact() {
|
||||
export function initArrivalStateContact(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '采购管理_采购请款表_查询数据'
|
||||
name: '采购管理_采购请款表_查询数据',
|
||||
param: `供应商流水号_check=1&供应商流水号=${num}`
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -61,3 +62,26 @@ export function submit(num) {
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询仓库到货情况
|
||||
export function searchArrivalState12(pageCurrent, pageSize, check1, num, check2, name) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '采购管理_仓库到货情况_查询数据_NEW',
|
||||
param: `采购合同流水号_check=${check1}&采购合同流水号=${num}&供应商流水号_check=${check2}&供应商流水号=${name}`,
|
||||
Pagination: pageCurrent + '&' + pageSize
|
||||
}
|
||||
})
|
||||
}
|
||||
export function searchgongyings() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '采购管理_仓库到货情况_供货商查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -11,18 +11,18 @@ export function initSupplier() {
|
||||
}
|
||||
})
|
||||
}
|
||||
// export function initSupplier(num) {
|
||||
// return request({
|
||||
// url: '',
|
||||
// method: 'post',
|
||||
// data: {
|
||||
// type: '3',
|
||||
// name: `SELECT distinct 供应商流水号,供应商名称
|
||||
// FROM 采购管理_询价单_视图
|
||||
// where not EXISTS (select * from 采购管理_采购合同_采购部 where 是否启用 = 1 and 是否未通过 is null and 询价单编号 = 采购合同编号) and 采购员流水号 = ${num}`
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
export function initSupplier11(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: ` SELECT distinct 供应商流水号,供应商名称
|
||||
FROM 采购管理_询价单_视图
|
||||
where not EXISTS (select * from 采购管理_采购合同_采购部 where 是否启用 = 1 and 是否未通过 is null and 询价单编号 = 采购合同编号) and 采购员流水号 = ${num}`
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询询价单列表 表1
|
||||
export function searchInquirySheet(check1, value1, check2, value2, check3, id, check4, supplier) {
|
||||
return request({
|
||||
|
||||
218
src/api/PurchasingCenter/MaterialMProcure.js
Normal file
218
src/api/PurchasingCenter/MaterialMProcure.js
Normal file
@@ -0,0 +1,218 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function getSupplier1(check, num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_供货商_查询数据_根据条件',
|
||||
param: '供货商_check=' + check + '=int&供货商=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
export function AddGonghuoshang(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '4',
|
||||
name: `insert into dbo.库存管理_供货商 (供货商) VALUES(\'${num}\')`
|
||||
}
|
||||
})
|
||||
}
|
||||
export function initDepartmentName() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料主文件_基本_物料部门_查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function initMaterialCategory(check, DepartmentValue) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料类别编号_查询数据_根据物料部门编号',
|
||||
param: '物料部门流水号_check=' + check + '=int&物料部门流水号=' + DepartmentValue
|
||||
}
|
||||
})
|
||||
}
|
||||
export function initMaterialVariety(MaterialCategoryValue) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料品种编号_查询数据',
|
||||
param: '物料类别流水号=' + MaterialCategoryValue
|
||||
}
|
||||
})
|
||||
}
|
||||
export function initMeasurementUnit() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_计量单位主文件_查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function initMaterialSource() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料来源_查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function searchmaterial(check1, MaterialName, check2, FullNameOfMaterial, check3, MaterialSpecification, check4, MaterialModel, pageCurrent, pageSize, check5, MaterialCategoryValue, check6, MaterialVarietyValue, check7, MeasurementUnitValue, check8, MaterialSourceValue, check9, supplierValue) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料主文件_基本_采购部_查询数据_分页',
|
||||
param: '物料流水号_check=0&物料代码_check=0&物料名称_check=' + check1 + '=int&物料名称=' + MaterialName + '&物料全名_check=' + check2 + '=int&物料全名=' + FullNameOfMaterial + '&物料规格_check=' + check3 + '=int&物料规格=' + MaterialSpecification + '&物料型号_check=' + check4 + '=int&物料型号=' + MaterialModel + '&物料类别流水号_check=' + check5 + '=int&物料类别流水号=' + MaterialCategoryValue + '&物料品种流水号_check=' + check6 + '=int&物料品种流水号=' + MaterialVarietyValue + '&供货商流水号_check=' + check9 + '&供货商流水号=' + supplierValue + '&计量单位流水号_check=' + check7 + '&计量单位流水号=' + MeasurementUnitValue + '&物料来源流水号_check=' + check8 + '&物料来源流水号=' + MaterialSourceValue + '&PageCurrent=' + pageCurrent + '=int&PageSize=' + pageSize + '=int&PageCount=1=int=output&ItemCount=1=int=output'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getSupplier(check, num, pageCurrent, pageSize) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_供货商_查询数据_根据条件',
|
||||
param: '供货商_check=' + check + '=int&供货商=' + num,
|
||||
Pagination: pageCurrent + '&' + pageSize
|
||||
}
|
||||
})
|
||||
}
|
||||
export function addData(MaterialVariety, MaterialName, FullNameOfMaterial, MaterialSpecification, MaterialModel, MeasurementUnitValue, MaterialSourceValue, supplierValue1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料主文件_基本_采购部_增加数据',
|
||||
param: '物料品种流水号=' + MaterialVariety + '&物料名称\\=' + MaterialName + '&物料全名\\=' + FullNameOfMaterial + '&物料规格\\=' + MaterialSpecification + '&物料型号\\=' + MaterialModel + '&计量单位流水号=' + MeasurementUnitValue + '&物料来源流水号=' + MaterialSourceValue + '&供货商流水号=' + supplierValue1
|
||||
}
|
||||
})
|
||||
}
|
||||
export function editData(MaterialValue, MaterialVariety, MaterialName, FullNameOfMaterial, MaterialSpecification, MaterialModel, MeasurementUnitValue, MaterialSourceValue, supplierValue1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料主文件_基本_修改数据',
|
||||
param: '物料流水号=' + MaterialValue + '&物料品种流水号=' + MaterialVariety + '&物料名称\\=' + MaterialName + '&物料全名\\=' + FullNameOfMaterial + '&物料规格\\=' + MaterialSpecification + '&物料型号\\=' + MaterialModel + '&计量单位流水号=' + MeasurementUnitValue + '&物料来源流水号=' + MaterialSourceValue + '&供货商流水号=' + supplierValue1
|
||||
}
|
||||
})
|
||||
}
|
||||
export function deleteData(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料主文件_基本_删除数据',
|
||||
param: '物料流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
export function searchCategory() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料类别编号_查询数据_根据物料部门编号'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function searchVarieties(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料品种编号_查询数据',
|
||||
param: '物料类别流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
export function editCategory(MaterialCategoryNum, MaterialCategory2, CategoryNumber) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料类别编号_修改数据',
|
||||
param: '物料类别流水号=' + MaterialCategoryNum + '&物料类别=' + MaterialCategory2 + '&类别编号=' + CategoryNumber
|
||||
}
|
||||
})
|
||||
}
|
||||
export function addCategory(MaterialCategory2, CategoryNumber) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料类别编号_增加数据',
|
||||
param: '物料类别=' + MaterialCategory2 + '&类别编号=' + CategoryNumber
|
||||
}
|
||||
})
|
||||
}
|
||||
export function deleteCategory(MaterialCategoryNum) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料类别编号_删除数据',
|
||||
param: '物料类别流水号=' + MaterialCategoryNum
|
||||
}
|
||||
})
|
||||
}
|
||||
export function editVariety(MaterialVarietyNum, MaterialCategoryNum, MaterialVariety2, VarietyNumber, Specifications1, Specifications2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料品种编号_修改数据',
|
||||
param: '物料品种流水号=' + MaterialVarietyNum + '&物料类别流水号=' + MaterialCategoryNum + '&物料品种=' + MaterialVariety2 + '&品种编号=' + VarietyNumber + '&规格1=' + Specifications1 + '&规格2=' + Specifications2
|
||||
}
|
||||
})
|
||||
}
|
||||
export function addVariety(MaterialCategoryNum, MaterialVariety2, VarietyNumber, Specifications1, Specifications2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料品种编号_增加数据',
|
||||
param: '物料类别流水号=' + MaterialCategoryNum + '&物料品种=' + MaterialVariety2 + '&品种编号=' + VarietyNumber + '&规格1=' + Specifications1 + '&规格2=' + Specifications2
|
||||
}
|
||||
})
|
||||
}
|
||||
export function deleteVariety(MaterialVarietyNum) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料品种编号_删除数据',
|
||||
param: '物料品种流水号=' + MaterialVarietyNum
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -216,3 +216,66 @@ export function deleteVariety(MaterialVarietyNum) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getMaterial() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料主文件_基本_采购部_查询未审核数量'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function searchmateria5(check1, MaterialName, check2, FullNameOfMaterial, check3, MaterialSpecification, check4, MaterialModel, pageCurrent, pageSize, check5, MaterialCategoryValue, check6, MaterialVarietyValue, check7, MeasurementUnitValue, check8, MaterialSourceValue, check9, supplierValue) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料主文件_基本_采购部_查询数据_分页1',
|
||||
param: '物料流水号_check=0&物料代码_check=0&物料名称_check=' + check1 + '=int&物料名称=' + MaterialName + '&物料全名_check=' + check2 + '=int&物料全名=' + FullNameOfMaterial + '&物料规格_check=' + check3 + '=int&物料规格=' + MaterialSpecification + '&物料型号_check=' + check4 + '=int&物料型号=' + MaterialModel + '&物料类别流水号_check=' + check5 + '=int&物料类别流水号=' + MaterialCategoryValue + '&物料品种流水号_check=' + check6 + '=int&物料品种流水号=' + MaterialVarietyValue + '&供货商流水号_check=' + check9 + '&供货商流水号=' + supplierValue + '&计量单位流水号_check=' + check7 + '&计量单位流水号=' + MeasurementUnitValue + '&物料来源流水号_check=' + check8 + '&物料来源流水号=' + MaterialSourceValue + '&PageCurrent=' + pageCurrent + '=int&PageSize=' + pageSize + '=int&PageCount=1=int=output&ItemCount=1=int=output'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function Dahui(num, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料主文件_基本_采购部_打回',
|
||||
param: '物料流水号=' + num + '&打回原因=' + num1
|
||||
}
|
||||
})
|
||||
}
|
||||
export function Tongguo(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料主文件_基本_采购部_通过',
|
||||
param: '物料流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getMaterial_NOTES() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_物料主文件_基本_采购部_未查看'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function setChakan() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_物料主文件_基本_采购部_查看变更'
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -1,27 +1,38 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function searchCailiao(name) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '备料管理_外购备料到货_材料查询',
|
||||
param: `供应商=${name}`
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询采购单
|
||||
export function searchPurchaseOrder(pageCurrent, pageSize, check1, num, check2, name) {
|
||||
export function searchPurchaseOrder(pageCurrent, pageSize, check1, num, check2, name, material) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '备料管理_采购计划_查询数据_到货',
|
||||
param: `采购单号_check=${check1}&采购单号=${num}&供应商_check=${check2}&供应商=${name}`,
|
||||
param: `采购单号_check=${check1}&采购单号=${num}&供应商_check=${check2}&供应商=${name}&材料=${material}`,
|
||||
Pagination: pageCurrent + '&' + pageSize
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询采购计划明细
|
||||
export function searchMateriel(num) {
|
||||
export function searchMateriel(num, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '备料管理_采购计划明细_查询数据_未选入',
|
||||
param: `采购计划流水号=${num}`
|
||||
param: `采购计划流水号=${num}&材料=${num1}`
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -97,14 +108,14 @@ export function deleteArrivalMX(num) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function EditArrivalOrderMX(num, num1, num2, num3, num4, num5) {
|
||||
export function EditArrivalOrderMX(num, num2, num3, num4, num5) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '备料管理_编辑到货单明细',
|
||||
param: `到货单明细流水号=${num}&材料=${num1}&数量=${num2}&单位=${num3}&单价=${num4}&金额=${num5}`
|
||||
param: `到货单明细流水号=${num}&数量=${num2}&单位=${num3}&单价=${num4}&金额=${num5}`
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 发票查询
|
||||
export function searchInvoice(pageCurrent, pageSize, check1, num1, check2, supplierName0) {
|
||||
export function searchInvoice(pageCurrent, pageSize, check1, num1, check2, supplierName0, num2, num3, num4, num5, num6) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '备料管理_发票_查询数据',
|
||||
param: '发票号_check=' + check1 + '&发票号=' + num1 + '&供应商名称_check=' + check2 + '&供应商名称=' + supplierName0,
|
||||
param: '发票号_check=' + check1 + '&发票号=' + num1 + '&供应商名称_check=' + check2 + '&供应商名称=' + supplierName0 + '&供应商流水号_check=' + num2 + '&供应商流水号=' + num3 + '&日期_check=' + num4 + '&开始日期=' + num5 + '&结束日期=' + num6,
|
||||
Pagination: pageCurrent + '&' + pageSize
|
||||
}
|
||||
})
|
||||
@@ -156,3 +156,13 @@ export function addMateriel(num, num1) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getGongyingshang() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '备料管理_发票_初始化获取供应商'
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -16,6 +16,8 @@ export const uploadInvoiceScan1 = `http://192.168.1.231:8411/submit/uploadInvoic
|
||||
export const download = `http://192.168.1.231:8411/submit/downloadFile.ashx` // ContractInformationManagement
|
||||
export const uploadPerson = `http://192.168.1.231:8411/submit/uploadPerson.ashx`
|
||||
export const uploadOP = `http://192.168.1.231:8411/submit/uploadOP.ashx`
|
||||
export const url = `http://192.168.0.110:8002/submit/MESCommonBase.ashx` // 采购件入库、离线件入库
|
||||
export const ExcelDownLoad = 'http://192.168.0.110:8002/submit/downloadFile.ashx' // 导出excel
|
||||
|
||||
// 技术中心程序发布时要更改下面所有的IP到0段
|
||||
export const ServerIP = `http://192.168.1.231:8411/webpage/file/`
|
||||
@@ -24,7 +26,7 @@ export const downloadFileMachine = `http://192.168.1.231:8411/submit/downloadFil
|
||||
export const MESUploadFile = `http://192.168.1.231:8411/submit/MESUploadFile.ashx`
|
||||
export const MESDownloadFile = `http://192.168.1.231:8411/submit/MESDownloadFile.ashx`
|
||||
const service = axios.create({
|
||||
baseURL: `http://192.168.1.231:8411/submit/MESCommonBase.ashx`,
|
||||
baseURL: `http://192.168.0.110:8002/submit/MESCommonBase.ashx`,
|
||||
timeout: 1500000 // 请求超时时间
|
||||
})
|
||||
export default service
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
<el-button type="primary" icon="el-icon-edit" size="small" @click="addMaterial()">新增</el-button>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-table :data="tableData1" stripe border style="max-height: 500px;" height="500px" size="mini" show-summary>
|
||||
<el-table :data="tableData1" stripe highlight-current-row border style="max-height: 500px;" height="500px" size="mini" show-summary>
|
||||
<el-table-column label="名称" align="center" width="150" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div slot="header" class="clearfix">
|
||||
<el-button size="small" type="primary" icon="el-icon-circle-plus-outline" style="margin: 0 0 0 10px" @click="ADD()">新建仓库</el-button>
|
||||
</div>
|
||||
<el-table :data="tableData" border stripe size="mini" style="width: 100%;max-height: 300px" height="300" @row-click="getWarehouse">
|
||||
<el-table :data="tableData" border stripe highlight-current-row size="mini" style="width: 100%;max-height: 300px" height="300" @row-click="getWarehouse">
|
||||
<el-table-column label="仓库编号" align="center" width="90" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.仓库编号 }}
|
||||
|
||||
336
src/views/Inventory/OfflinePartsStorage/index.vue
Normal file
336
src/views/Inventory/OfflinePartsStorage/index.vue
Normal file
@@ -0,0 +1,336 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-card>
|
||||
<span>供应商:</span>
|
||||
<el-select v-model="supplierValue" placeholder="请选择供应商" filterable size="small" style="width: 180px" @change="supplierChange();searchContractDetail()">
|
||||
<el-option
|
||||
v-for="item in supplier"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span style="margin-left: 5px">合同:</span>
|
||||
<el-select v-model="contractValue" placeholder="请选择合同" filterable clearable size="small" style="width: 180px" @change="searchContractDetail()">
|
||||
<el-option
|
||||
v-for="item in contract"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="success" size="small" style="margin-left: 10px" @click="searchContractDetail">查询明细</el-button>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-table ref="multipleTable" :data="table1" border stripe size="mini" highlight-current-row style="width: 100%;margin-bottom: 5px" @selection-change="handleSelectionChange">
|
||||
<el-table-column :selectable="selectable" type="selection" align="center" width="50px"/>
|
||||
<el-table-column label="合同编号" width="120px" align="center" show-overflow-tooltip prop="合同编号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.离线合同编号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="名称" width="150px" align="center" show-overflow-tooltip prop="物料名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格型号" width="180px" align="center" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料规格 + ' ' + scope.row.物料型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="采购数量" align="center" width="100" show-overflow-tooltip prop="数量">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.数量 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="已到数量" align="center" width="100" show-overflow-tooltip prop="到货数量">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.到货数量 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="到货数量" align="center" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.本次到货数量" :min="0" :max="scope.row.数量-scope.row.到货数量" :precision="2" size="mini" style="margin: 0;width: 100%"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<span v-show="false">仓库名称:</span>
|
||||
<el-select v-show="false" v-model="inventoryNumber" style="width: 200px" filterable size="small" placeholder="仓库名称" @change="getLocate">
|
||||
<el-option
|
||||
v-for="item in inventoryName"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span>货位名称:</span>
|
||||
<el-select v-model="locateNumber" style="width: 200px" filterable size="small" placeholder="货位名称">
|
||||
<el-option
|
||||
v-for="item in locateName"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="primary" style="margin-left: 5px" size="small" @click="submitInStorage">确认入库</el-button>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { url } from '@/utils/request'
|
||||
import axios from 'axios'
|
||||
import Cookie from 'js-cookie'
|
||||
|
||||
export default {
|
||||
name: 'OfflineInStorage',
|
||||
data() {
|
||||
return {
|
||||
searchType: '2', // 查询合同方式
|
||||
inventoryPeople: '',
|
||||
oldVal1: '',
|
||||
oldVal2: '',
|
||||
qrCode: '',
|
||||
supplierValue: '',
|
||||
supplier: [],
|
||||
contractValue: '',
|
||||
contract: [],
|
||||
supplierName: '', // 供应商名称
|
||||
contractNumber: '', // 合同编号
|
||||
table1: [],
|
||||
multipleSelection: [],
|
||||
locateType: '2', // 查询货位方式
|
||||
inventoryNumber: '', // 仓库流水号
|
||||
inventoryName: [], // 仓库名称
|
||||
locateNumber: '',
|
||||
locateName: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.initSupplier()
|
||||
this.getLocate()
|
||||
this.getpeopleid()
|
||||
},
|
||||
methods: {
|
||||
// 获取仓库
|
||||
async getHouse() {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_货位主文件_仓库查询'
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
this.inventoryName = []
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.inventoryName.push({
|
||||
label: res.data[i].仓库名称,
|
||||
value: res.data[i].仓库流水号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 获取货位
|
||||
async getLocate() {
|
||||
this.locateNumber = ''
|
||||
this.locateName = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_货位主文件_查询数据_查询全部'
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.locateName.push({
|
||||
label: res.data[i].货位名称,
|
||||
value: res.data[i].货位流水号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 明细可选
|
||||
selectable(row) {
|
||||
return Number(row.数量) !== Number(row.到货数量)
|
||||
},
|
||||
// 初始化供应商
|
||||
async initSupplier() {
|
||||
this.supplierValue = ''
|
||||
this.supplier = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: `select distinct 供应商流水号,供应商名称 from (
|
||||
select 供应商流水号,供应商名称,sum(数量) as 总采购数量,sum(到货数量) as 总到货数量
|
||||
from 采购管理_离线合同_视图
|
||||
where 离线合同状态 = 2
|
||||
group by 离线合同流水号,离线合同编号,离线合同名称,规定到货时间,供应商流水号,供应商名称,电子信箱,电话号码,传真,人员编号,采购员,离线合同状态,离线合同状态名称,创建日期,合同总额,离线合同备注, 已付金额
|
||||
having sum(数量) <> sum(到货数量)
|
||||
) as 已采购的离线合同`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.supplier.push({
|
||||
value: res.data[i].供应商流水号,
|
||||
label: res.data[i].供应商名称
|
||||
})
|
||||
}
|
||||
},
|
||||
// 根据供应商查合同
|
||||
async supplierChange() {
|
||||
this.contractValue = ''
|
||||
this.contract = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '采购管理_离线合同_查询数据',
|
||||
param: `供应商流水号_check=1&供应商流水号=${this.supplierValue}&未全部到货=1`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.contract.push({
|
||||
value: res.data[i].离线合同流水号,
|
||||
label: res.data[i].离线合同编号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 单选框改变
|
||||
radioChange() {
|
||||
this.qrCode = ''
|
||||
this.supplierValue = ''
|
||||
this.contractValue = ''
|
||||
this.contract = []
|
||||
this.table1 = []
|
||||
if (this.searchType === '1') {
|
||||
this.ifocus1()
|
||||
}
|
||||
},
|
||||
radioChange2() {
|
||||
this.locateNumber = ''
|
||||
if (this.searchType === '1') {
|
||||
this.ifocus2()
|
||||
}
|
||||
},
|
||||
// 初始化时让input框聚焦,可以直接扫描出结果,而不用点一下输入框
|
||||
ifocus1() {
|
||||
const input = document.getElementById('code3')
|
||||
input.focus()
|
||||
},
|
||||
ifocus2() {
|
||||
const input = document.getElementById('locate')
|
||||
input.focus()
|
||||
},
|
||||
onfocus1() {
|
||||
this.qrCode = ''
|
||||
},
|
||||
onfocus2() {
|
||||
this.locateNumber = ''
|
||||
},
|
||||
// 获取人员编号
|
||||
getpeopleid() {
|
||||
this.inventoryPeople = Cookie.get('id')
|
||||
},
|
||||
// 查询离线合同明细
|
||||
async searchContractDetail() {
|
||||
if (this.contractValue && this.searchType === '2') {
|
||||
this.qrCode = this.contractValue
|
||||
} else if (!this.supplierValue) {
|
||||
this.$message.error('请选择供货商')
|
||||
}
|
||||
if (this.contractValue) { this.contractValue_check = 1 } else { this.contractValue_check = 0 }
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '离线合同扫描合同打印物料_NEW',
|
||||
param: `供应商流水号=${this.supplierValue}&离线合同流水号_check=${this.contractValue_check}&离线合同流水号=${this.qrCode}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
res.data.map(v => {
|
||||
this.$set(v, '本次到货数量', v.数量 - v.到货数量)
|
||||
return v
|
||||
})
|
||||
if (res.data.length > 0) {
|
||||
this.supplierName = res.data[0].供应商名称
|
||||
this.contractNumber = res.data[0].离线合同编号
|
||||
} else {
|
||||
this.supplierName = ''
|
||||
this.contractNumber = ''
|
||||
}
|
||||
this.table1 = res.data
|
||||
this.oldVal1 = ''
|
||||
},
|
||||
// 多选
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val
|
||||
},
|
||||
// 提交入库
|
||||
submitInStorage() {
|
||||
if (this.multipleSelection.length === 0) {
|
||||
this.$message.warning('请勾选入库物料')
|
||||
} else if (!this.locateNumber) {
|
||||
this.$message.warning('请选择货位或者扫码货位二维码')
|
||||
} else {
|
||||
const materialGroup = []
|
||||
const numberGroup = []
|
||||
const partGroup = []
|
||||
for (let i = 0; i < this.multipleSelection.length; i++) {
|
||||
materialGroup.push(this.multipleSelection[i].物料流水号)
|
||||
numberGroup.push(this.multipleSelection[i].本次到货数量)
|
||||
partGroup.push(this.multipleSelection[i].离线合同明细流水号)
|
||||
}
|
||||
this.$confirm('确认入库?', '提示', {
|
||||
confirmButtonText: '确定入库',
|
||||
cancelButtonText: '取消操作',
|
||||
center: 'true',
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '采购管理_离线采购件入库_增加数据',
|
||||
param: `物料流水号组=${materialGroup}&离线合同明细流水号组=${partGroup}&数量组=${numberGroup}&货位流水号=${this.locateNumber}&入库人员流水号=${this.inventoryPeople}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.searchContractDetail()
|
||||
this.searchType = '2'
|
||||
this.locateType = '2'
|
||||
this.qrCode = ''
|
||||
this.locateNumber = ''
|
||||
} else { this.$message.error('入库失败') }
|
||||
}).catch(() => {
|
||||
this.$message('已取消操作')
|
||||
})
|
||||
}
|
||||
},
|
||||
codeChange1() {
|
||||
const input = document.getElementById('code3')
|
||||
input.blur()
|
||||
},
|
||||
codeChange2() {
|
||||
const input = document.getElementById('locate')
|
||||
input.blur()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style>
|
||||
.el-message-box{
|
||||
width: 300px!important;
|
||||
}
|
||||
</style>
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
475
src/views/Inventory/PurchasePartsStorage/index.vue
Normal file
475
src/views/Inventory/PurchasePartsStorage/index.vue
Normal file
@@ -0,0 +1,475 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-card>
|
||||
<span>供应商:</span>
|
||||
<el-select v-model="supplierValue" placeholder="请选择供应商" filterable size="small" style="width: 180px" @change="supplierChange();searchContractDetail()">
|
||||
<el-option
|
||||
v-for="item in supplier"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span style="margin-left: 5px">合同:</span>
|
||||
<el-select v-model="contractValue" placeholder="请选择合同" filterable clearable size="small" style="width: 180px" @change="searchContractDetail()">
|
||||
<el-option
|
||||
v-for="item in contract"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span style="margin-left: 5px">合同类型:</span>
|
||||
<el-select v-model="TypeValue" filterable size="small" placeholder="合同类型" style="width: 180px" @change="contractTypeChange">
|
||||
<el-option
|
||||
v-for="item in Type"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="success" size="small" style="margin-left: 10px" @click="searchContractDetail">查询明细</el-button>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-table ref="multipleTable" :data="table1" border stripe size="mini" highlight-current-row style="width: 100%;margin-bottom: 5px" @selection-change="handleSelectionChange">
|
||||
<el-table-column :selectable="selectable" type="selection" align="center" width="50px"/>
|
||||
<el-table-column label="合同编号" width="120px" align="center" show-overflow-tooltip prop="合同编号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.合同编号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="名称" width="150px" align="center" show-overflow-tooltip prop="物料名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格型号" width="180px" align="center" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料规格 + ' ' + scope.row.物料型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="采购数量" align="center" width="100" show-overflow-tooltip prop="数量">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.数量 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="已到数量" align="center" width="100" show-overflow-tooltip prop="到货数量">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.到货数量 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="到货数量" align="center" width="200" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.本次到货数量" :min="0" :max="scope.row.数量-scope.row.到货数量" :precision="2" size="mini" style="margin: 0;width: 100%"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<span v-show="false">仓库名称:</span>
|
||||
<el-select v-show="false" v-model="inventoryNumber" style="width: 200px" filterable size="small" placeholder="仓库名称" @change="getLocate">
|
||||
<el-option
|
||||
v-for="item in inventoryName"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span>货位名称:</span>
|
||||
<el-select v-model="locateNumber" style="width: 200px" filterable size="small" placeholder="货位名称">
|
||||
<el-option
|
||||
v-for="item in locateName"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="primary" style="margin-left: 5px" size="small" @click="submitInStorage">确认入库</el-button>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { url } from '@/utils/request'
|
||||
import axios from 'axios'
|
||||
import Cookie from 'js-cookie'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
Type: [
|
||||
{
|
||||
value: 1,
|
||||
label: '采购部采购合同'
|
||||
}, {
|
||||
value: 3,
|
||||
label: '车间采购合同'
|
||||
}, {
|
||||
value: 4,
|
||||
label: '车间离线合同'
|
||||
}
|
||||
],
|
||||
TypeValue: 1,
|
||||
supplierValue: '', // 供应商
|
||||
supplier: [],
|
||||
contractValue: '', // 合同
|
||||
contract: [],
|
||||
inventoryNumber: '', // 仓库流水号
|
||||
inventoryName: [], // 仓库名称
|
||||
locateNumber: '',
|
||||
locateName: [],
|
||||
table1: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.initSupplier()
|
||||
this.getLocate()
|
||||
this.getpeopleid()
|
||||
},
|
||||
methods: {
|
||||
// 获取人员编号
|
||||
getpeopleid() {
|
||||
this.inventoryPeople = Cookie.get('id')
|
||||
},
|
||||
// 获取仓库
|
||||
async getHouse() {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_货位主文件_仓库查询'
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
this.inventoryName = []
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.inventoryName.push({
|
||||
label: res.data[i].仓库名称,
|
||||
value: res.data[i].仓库流水号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 获取货位
|
||||
async getLocate() {
|
||||
this.locateNumber = ''
|
||||
this.locateName = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_货位主文件_查询数据_查询全部'
|
||||
// param: `仓库流水号=${this.inventoryNumber}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.locateName.push({
|
||||
label: res.data[i].货位名称,
|
||||
value: res.data[i].货位流水号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 初始化供应商
|
||||
async initSupplier() {
|
||||
if (this.TypeValue === 1) { // 采购合同
|
||||
this.supplierValue = ''
|
||||
this.supplier = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: `select distinct 供应商流水号,供应商名称 from (
|
||||
select 供应商流水号,供应商名称,sum(数量) as 总采购数量,sum(已到货数量) as 总到货数量
|
||||
from 库存管理_外购件_采购合同明细_视图
|
||||
group by 采购合同流水号,供应商流水号,供应商名称
|
||||
having sum(数量) <> sum(已到货数量)
|
||||
) as 已采购的离线合同`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.supplier.push({
|
||||
value: res.data[i].供应商流水号,
|
||||
label: res.data[i].供应商名称
|
||||
})
|
||||
}
|
||||
} else if (this.TypeValue === 3) { // 车间采购合同
|
||||
this.supplierValue = ''
|
||||
this.supplier = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: `select distinct 供应商流水号,供应商名称 from (
|
||||
select 供应商流水号,供应商名称,sum(数量) as 总采购数量,sum(已到货数量) as 总到货数量
|
||||
from 库存管理_车间采购_视图
|
||||
group by 采购合同流水号,供应商流水号,供应商名称
|
||||
having sum(数量) <> sum(已到货数量)
|
||||
) as 已采购的离线合同`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.supplier.push({
|
||||
value: res.data[i].供应商流水号,
|
||||
label: res.data[i].供应商名称
|
||||
})
|
||||
}
|
||||
} else if (this.TypeValue === 4) { // 车间离线合同
|
||||
this.supplierValue = ''
|
||||
this.supplier = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: `select distinct 供应商流水号,供应商名称 from (
|
||||
select 供应商流水号,供应商名称,sum(数量) as 总采购数量,sum(到货数量) as 总到货数量
|
||||
from 车间采购管理_离线合同明细_视图
|
||||
group by 离线合同流水号,供应商流水号,供应商名称
|
||||
having sum(数量) <> sum(到货数量)
|
||||
) as 已采购的离线合同`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.supplier.push({
|
||||
value: res.data[i].供应商流水号,
|
||||
label: res.data[i].供应商名称
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
// 根据供应商查合同
|
||||
async supplierChange() {
|
||||
if (this.TypeValue === 1) {
|
||||
this.contractValue = ''
|
||||
this.contract = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_根据供应商查合同_采购部',
|
||||
param: `供应商流水号=${this.supplierValue}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.contract.push({
|
||||
value: res.data[i].采购合同流水号,
|
||||
label: res.data[i].采购合同编号
|
||||
})
|
||||
}
|
||||
} else if (this.TypeValue === 3) {
|
||||
this.contractValue = ''
|
||||
this.contract = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_根据供应商查合同_车间采购',
|
||||
param: `供应商流水号=${this.supplierValue}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.contract.push({
|
||||
value: res.data[i].采购合同流水号,
|
||||
label: res.data[i].采购合同编号
|
||||
})
|
||||
}
|
||||
} else if (this.TypeValue === 4) {
|
||||
this.contractValue = ''
|
||||
this.contract = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_根据供应商查合同_离线采购',
|
||||
param: `供应商流水号=${this.supplierValue}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.contract.push({
|
||||
value: res.data[i].离线合同流水号,
|
||||
label: res.data[i].离线合同编号
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
// 查询
|
||||
async searchContractDetail() {
|
||||
this.table1 = []
|
||||
if (this.TypeValue === 1) {
|
||||
if (this.contractValue) { this.contractValue_check = 1 } else { this.contractValue_check = 0 }
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_外购件入库_采购部查询',
|
||||
param: `供应商流水号=${this.supplierValue}&采购合同流水号_check=${this.contractValue_check}&采购合同流水号=${this.contractValue}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
res.data.map(v => {
|
||||
this.$set(v, '本次到货数量', v.数量 - v.到货数量)
|
||||
return v
|
||||
})
|
||||
this.table1 = res.data
|
||||
} else if (this.TypeValue === 3) {
|
||||
if (this.contractValue) { this.contractValue_check = 1 } else { this.contractValue_check = 0 }
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_外购件入库_车间采购查询',
|
||||
param: `供应商流水号=${this.supplierValue}&采购合同流水号_check=${this.contractValue_check}&采购合同流水号=${this.contractValue}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
res.data.map(v => {
|
||||
this.$set(v, '本次到货数量', v.数量 - v.到货数量)
|
||||
return v
|
||||
})
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
if (!res.data[i].物料规格) { res.data[i].物料规格 = '' }
|
||||
if (!res.data[i].物料型号) { res.data[i].物料型号 = '' }
|
||||
}
|
||||
this.table1 = res.data
|
||||
} else if (this.TypeValue === 4) {
|
||||
if (this.contractValue) { this.contractValue_check = 1 } else { this.contractValue_check = 0 }
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_外购件入库_离线采购查询',
|
||||
param: `供应商流水号=${this.supplierValue}&采购合同流水号_check=${this.contractValue_check}&采购合同流水号=${this.contractValue}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
res.data.map(v => {
|
||||
this.$set(v, '本次到货数量', v.数量 - v.到货数量)
|
||||
return v
|
||||
})
|
||||
this.table1 = res.data
|
||||
}
|
||||
},
|
||||
// 合同类型变更
|
||||
contractTypeChange() {
|
||||
this.supplierValue = ''
|
||||
this.supplier = []
|
||||
this.contractValue = ''
|
||||
this.contract = []
|
||||
this.table1 = []
|
||||
this.initSupplier()
|
||||
},
|
||||
// 多选
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val
|
||||
},
|
||||
// 明细可选
|
||||
selectable(row) {
|
||||
return Number(row.数量) !== Number(row.到货数量)
|
||||
},
|
||||
// 确认入库
|
||||
submitInStorage() {
|
||||
if (this.multipleSelection.length === 0) {
|
||||
this.$message.warning('请勾选入库物料')
|
||||
} else if (!this.locateNumber) {
|
||||
this.$message.warning('请选择货位')
|
||||
} else {
|
||||
const materialGroup = []
|
||||
const numberGroup = []
|
||||
const partGroup = []
|
||||
const 组件零件流水号 = []
|
||||
const 组件零件基本件流水号 = []
|
||||
this.$confirm('确认入库?', '提示', {
|
||||
confirmButtonText: '确定入库',
|
||||
cancelButtonText: '取消操作',
|
||||
center: 'true',
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
if (this.TypeValue === 1) {
|
||||
for (let i = 0; i < this.multipleSelection.length; i++) {
|
||||
materialGroup.push(this.multipleSelection[i].物料流水号)
|
||||
numberGroup.push(this.multipleSelection[i].本次到货数量)
|
||||
partGroup.push(this.multipleSelection[i].采购合同明细流水号)
|
||||
组件零件流水号.push(this.multipleSelection[i].组件零件流水号)
|
||||
组件零件基本件流水号.push(this.multipleSelection[i].组件零件基本件流水号)
|
||||
}
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '采购件入库_外购件入库_循环执行',
|
||||
param: `物料流水号组=${materialGroup}&实际到货数量组=${numberGroup}&货位流水号=${this.locateNumber}&采购合同明细流水号组=${partGroup}&入库人员流水号=${this.inventoryPeople}&组件零件流水号组=${组件零件流水号}&组件零件基本件流水号组=${组件零件基本件流水号}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.searchContractDetail()
|
||||
} else { this.$message.error('入库失败') }
|
||||
} else if (this.TypeValue === 3) {
|
||||
for (let i = 0; i < this.multipleSelection.length; i++) {
|
||||
materialGroup.push(this.multipleSelection[i].物料流水号)
|
||||
numberGroup.push(this.multipleSelection[i].本次到货数量)
|
||||
partGroup.push(this.multipleSelection[i].请购单明细流水号)
|
||||
}
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '采购件入库_车间采购入库_循环执行',
|
||||
param: `物料流水号组=${materialGroup}&实际到货数量组=${numberGroup}&货位流水号=${this.locateNumber}&入库人员流水号=${this.inventoryPeople}&请购单明细流水号组=${partGroup}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.searchContractDetail()
|
||||
} else { this.$message.error('入库失败') }
|
||||
} else if (this.TypeValue === 4) {
|
||||
for (let i = 0; i < this.multipleSelection.length; i++) {
|
||||
materialGroup.push(this.multipleSelection[i].物料流水号)
|
||||
numberGroup.push(this.multipleSelection[i].本次到货数量)
|
||||
partGroup.push(this.multipleSelection[i].离线合同明细流水号)
|
||||
}
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '采购件入库_离线采购入库_循环执行',
|
||||
param: `物料流水号组=${materialGroup}&离线合同明细流水号组=${partGroup}&实际到货数量组=${numberGroup}&货位流水号=${this.locateNumber}&入库人员流水号=${this.inventoryPeople}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.searchContractDetail()
|
||||
} else { this.$message.error('入库失败') }
|
||||
}
|
||||
}).catch(() => {
|
||||
this.$message('已取消操作')
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.el-input{
|
||||
margin-right: 2px;
|
||||
}
|
||||
.searchForm .el-form-item{
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
</style>
|
||||
550
src/views/Inventory/PurchasePartsStorage/sadas.vue
Normal file
550
src/views/Inventory/PurchasePartsStorage/sadas.vue
Normal file
@@ -0,0 +1,550 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-card>
|
||||
<span>合同明细流水号:</span>
|
||||
<el-input id="code1" v-model="qrCode" size="small" placeholder="输入合同明细流水号" style="width: 200px" @keyup.native.enter="codeChange1()" @focus="qrCode=''"/>
|
||||
<span>合同类型:</span>
|
||||
<el-select v-model="contractType" filterable size="small" placeholder="合同类型" @change="contractTypeChange">
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="success" size="small" style="margin-left: 10px" @click="searchPartDetail">查询零件详情</el-button>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-form label-position="right" label-width="100px" class="searchForm">
|
||||
<el-row>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="机床号:">
|
||||
<el-input v-model="machine" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="组号:">
|
||||
<el-input v-model="team" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="物料名称:">
|
||||
<el-input v-model="materialname" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="物料型号:">
|
||||
<el-input v-model="materialtype" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="物料规格:">
|
||||
<el-input v-model="materialscale" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="零件名称:">
|
||||
<el-input v-model="partname" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="零件图号:">
|
||||
<el-input v-model="partpaint" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="供应商:">
|
||||
<el-input v-model="supplier" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="合同编号:">
|
||||
<el-input v-model="contractnumber" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="采购数量:">
|
||||
<el-input v-model="contractnum" readonly size="small" style="width: 200px" placeholder="无"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-form label-position="right" label-width="100px" class="searchForm">
|
||||
<el-row>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="仓库名称:">
|
||||
<el-select v-model="inventoryNumber" style="width: 200px" size="small" placeholder="仓库名称" @change="getLocate">
|
||||
<el-option
|
||||
v-for="item in inventoryName"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="货位名称:">
|
||||
<el-select v-model="locateNumber" style="width: 200px" size="small" placeholder="货位名称">
|
||||
<el-option
|
||||
v-for="item in locateName"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="入库数量:">
|
||||
<el-input-number v-model="inboundNumber" :min="0" style="width: 200px" size="small"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col style="width: 300px">
|
||||
<el-form-item label="重量/面积:">
|
||||
<el-input v-model="area" style="width: 90px" size="small"/>
|
||||
<el-select v-model="unit" style="width: 90px" size="small">
|
||||
<el-option
|
||||
v-for="item in basicUnit"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col style="width: 400px">
|
||||
<el-form-item label="备注:">
|
||||
<el-input v-model="inboundNote" style="width: 200px" size="small"/>
|
||||
<el-button type="primary" style="margin-left: 5px" size="small" @click="inBound">确定入库</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</el-card>
|
||||
<el-table v-show="false" :data="tableData" border style="width: 100%;margin-top:20px;">
|
||||
<el-table-column v-for="item of tableHeader" :key="item" :label="item">
|
||||
<el-table-column label="重量" width="120">
|
||||
<template slot-scope="scope">
|
||||
<!--{{ scope.row[${item}重量] }}-->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="金额" width="120">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.date }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { url } from '@/utils/request'
|
||||
import axios from 'axios'
|
||||
import Cookie from 'js-cookie'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
tableData: [],
|
||||
tableHeader: [],
|
||||
locateType: '2',
|
||||
qrCode: '',
|
||||
inboundNote: '',
|
||||
multipleSelection: [],
|
||||
oldVal: '',
|
||||
project: '',
|
||||
machine: '',
|
||||
team: '',
|
||||
materialname: '',
|
||||
materialtype: '',
|
||||
materialscale: '',
|
||||
supplier: '',
|
||||
contractnumber: '',
|
||||
contractnum: '',
|
||||
locateNumber: '',
|
||||
locateName: [],
|
||||
partname: '',
|
||||
partpaint: '',
|
||||
note: '',
|
||||
partnumber: '', // 物料流水号
|
||||
inboundNumber: 0, // 入库数量
|
||||
inventoryPeople: '', // 入库人员
|
||||
options: [
|
||||
{
|
||||
value: 1,
|
||||
label: '采购部采购合同'
|
||||
}, {
|
||||
value: 3,
|
||||
label: '车间采购合同'
|
||||
}, {
|
||||
value: 4,
|
||||
label: '车间离线合同'
|
||||
}
|
||||
],
|
||||
contractType: 1,
|
||||
exchange: '',
|
||||
purchasepart: true,
|
||||
Projectshow: true,
|
||||
basicpart: false,
|
||||
basicUnit: [], // 单位下拉框
|
||||
unit: '', // 单位
|
||||
requestcardnumber: '', // 请购单明细流水号
|
||||
area: '', // 面积或重量
|
||||
inventoryNumber: '', // 仓库流水号
|
||||
inventoryName: [], // 仓库名称
|
||||
teampartnumber: '', // 组件零件流水号
|
||||
teampartbasicnumber: '', // 组件零件基本件流水号
|
||||
unArrivalNum: 0 // 未到货数量
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getpeopleid()
|
||||
this.getHouse()
|
||||
},
|
||||
mounted() {
|
||||
this.getUnit()
|
||||
},
|
||||
methods: {
|
||||
// 获取人员编号
|
||||
getpeopleid() {
|
||||
this.inventoryPeople = Cookie.get('id')
|
||||
},
|
||||
// 合同类型变更
|
||||
contractTypeChange() {
|
||||
if (this.contractType === 3) { // 车间采购
|
||||
this.Projectshow = true
|
||||
this.basicpart = true
|
||||
} else if (this.contractType === 2 || this.contractType === 4) { // 采购离线,车间离线
|
||||
this.Projectshow = false
|
||||
this.basicpart = false
|
||||
} else { // 采购采购
|
||||
this.Projectshow = true
|
||||
this.basicpart = false
|
||||
}
|
||||
},
|
||||
// 异步加载零件详情
|
||||
async searchPartDetail() {
|
||||
if (this.contractType === 1) { // 采购合同
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_外购件入库_查询数据',
|
||||
param: `采购合同明细流水号=${this.qrCode}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data.length > 0) {
|
||||
if (res.data[0].组件零件流水号) { // 标准件和外购件
|
||||
this.purchasepart = true
|
||||
this.basicpart = false
|
||||
this.project = res.data[0].项目名称
|
||||
this.machine = res.data[0].机床图号
|
||||
this.team = res.data[0].组号
|
||||
this.materialname = res.data[0].物料名称
|
||||
this.materialtype = res.data[0].物料型号
|
||||
this.materialscale = res.data[0].物料规格
|
||||
this.partnumber = res.data[0].物料流水号
|
||||
} else {
|
||||
this.purchasepart = false
|
||||
this.basicpart = true
|
||||
this.project = res.data[0].基本件项目名称
|
||||
this.machine = res.data[0].基本件机床图号
|
||||
this.team = res.data[0].基本件组号
|
||||
this.partpaint = res.data[0].零件图号
|
||||
this.partname = res.data[0].零件名称
|
||||
}
|
||||
this.inboundNumber = res.data[0].未到货数量
|
||||
this.unArrivalNum = res.data[0].未到货数量
|
||||
this.supplier = res.data[0].供应商名称
|
||||
this.contractnumber = res.data[0].采购合同编号
|
||||
this.contractnum = res.data[0].数量
|
||||
this.teampartnumber = res.data[0].组件零件流水号
|
||||
this.teampartbasicnumber = res.data[0].组件零件基本件流水号
|
||||
} else {
|
||||
this.clear()
|
||||
}
|
||||
const param2 = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_交换件_入库查询',
|
||||
param: `采购合同明细流水号=${this.qrCode}`
|
||||
}
|
||||
}
|
||||
const res1 = await axios(param2)
|
||||
res1.data.length > 0 ? this.locateNumber = res1.data[0].货位流水号 : this.locateNumber = ''
|
||||
} else if (this.contractType === 2) { // 离线合同
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_离线合同外购件入库_查询数据',
|
||||
param: `离线合同明细流水号=${this.qrCode}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data.length > 0) {
|
||||
this.materialname = res.data[0].物料名称
|
||||
this.materialtype = res.data[0].物料型号
|
||||
this.materialscale = res.data[0].物料规格
|
||||
this.supplier = res.data[0].供应商名称
|
||||
this.contractnumber = res.data[0].离线合同编号
|
||||
this.contractnum = res.data[0].数量
|
||||
this.partnumber = res.data[0].物料流水号
|
||||
} else {
|
||||
this.clear()
|
||||
}
|
||||
} else if (this.contractType === 3) { // 车间采购合同
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_车间采购_零件详情查询',
|
||||
param: `采购合同明细流水号=${this.qrCode}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data.length > 0) {
|
||||
if (!res.data[0].基本件流水号) {
|
||||
this.purchasepart = true
|
||||
this.basicpart = false
|
||||
this.materialname = res.data[0].物料名称
|
||||
this.materialtype = res.data[0].物料型号
|
||||
this.materialscale = res.data[0].物料规格
|
||||
} else {
|
||||
this.purchasepart = false
|
||||
this.basicpart = true
|
||||
this.partpaint = res.data[0].零件图号
|
||||
this.partname = res.data[0].物料名称
|
||||
}
|
||||
this.project = res.data[0].项目名称
|
||||
this.machine = res.data[0].机床图号
|
||||
this.team = res.data[0].组号
|
||||
this.supplier = res.data[0].供应商名称
|
||||
this.contractnumber = res.data[0].采购合同编号
|
||||
this.contractnum = res.data[0].数量
|
||||
this.partnumber = res.data[0].物料流水号
|
||||
this.requestcardnumber = res.data[0].请购单明细流水号
|
||||
} else {
|
||||
this.clear()
|
||||
}
|
||||
} else if (this.contractType === 4) { // 车间离线合同
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_车间离线合同外购件入库_查询数据',
|
||||
param: `离线合同明细流水号=${this.qrCode}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data.length > 0) {
|
||||
this.materialname = res.data[0].物料名称
|
||||
this.materialtype = res.data[0].物料型号
|
||||
this.materialscale = res.data[0].物料规格
|
||||
this.supplier = res.data[0].供应商名称
|
||||
this.contractnumber = res.data[0].离线合同编号
|
||||
this.contractnum = res.data[0].数量
|
||||
this.partnumber = res.data[0].物料流水号
|
||||
} else {
|
||||
this.clear()
|
||||
}
|
||||
}
|
||||
},
|
||||
// 获取仓库
|
||||
async getHouse() {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_货位主文件_仓库查询'
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.inventoryName.push({
|
||||
label: res.data[i].仓库名称,
|
||||
value: res.data[i].仓库流水号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 获取货位
|
||||
async getLocate() {
|
||||
this.locateName = []
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_货位主文件_查询数据',
|
||||
param: `仓库流水号=${this.inventoryNumber}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.locateName.push({
|
||||
label: res.data[i].货位名称,
|
||||
value: res.data[i].货位流水号
|
||||
})
|
||||
}
|
||||
},
|
||||
// 获取单位
|
||||
async getUnit() {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '库存管理_车间采购_单位查询'
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.basicUnit.push({
|
||||
label: res.data[i].单位,
|
||||
value: res.data[i].单位编号
|
||||
})
|
||||
}
|
||||
this.unit = this.basicUnit[0].value
|
||||
},
|
||||
// 清空
|
||||
clear() {
|
||||
this.locateNumber = ''
|
||||
this.inboundNumber = 0
|
||||
// this.qrCode = ''
|
||||
this.locateNumber = ''
|
||||
this.inventoryNumber = ''
|
||||
this.project = ''
|
||||
this.machine = ''
|
||||
this.team = ''
|
||||
this.materialname = ''
|
||||
this.materialtype = ''
|
||||
this.materialscale = ''
|
||||
this.supplier = ''
|
||||
this.contractnumber = ''
|
||||
this.contractnum = ''
|
||||
this.partpaint = ''
|
||||
this.partname = ''
|
||||
this.locateNumber = ''
|
||||
this.inventoryNumber = ''
|
||||
this.partnumber = ''
|
||||
this.inboundNote = ''
|
||||
this.area = ''
|
||||
},
|
||||
// 执行入库
|
||||
async inBound() {
|
||||
if (this.inboundNumber && this.locateNumber) {
|
||||
if (this.contractType === 1) {
|
||||
if (this.qrCode) {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_外购件入库_修改数据',
|
||||
param: `物料流水号=${this.partnumber}&实际到货数量=${this.inboundNumber}&货位流水号=${this.locateNumber}&采购合同明细流水号=${this.qrCode}&入库人员流水号=${this.inventoryPeople}&备注=${this.inboundNote}&组件零件流水号=${this.teampartnumber}&组件零件基本件流水号=${this.teampartbasicnumber}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.clear()
|
||||
} else {
|
||||
this.$message.error('入库失败')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请扫描二维码')
|
||||
}
|
||||
} else if (this.contractType === 2) {
|
||||
if (this.qrCode) {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_离线物料货位_增加修改数据',
|
||||
param: `物料流水号=${this.partnumber}&实际到货数量=${this.inboundNumber}&货位流水号=${this.locateNumber}&离线合同明细流水号=${this.qrCode}&入库人员流水号=${this.inventoryPeople}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.clear()
|
||||
} else {
|
||||
this.$message.error('入库失败')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请扫描二维码')
|
||||
}
|
||||
} else if (this.contractType === 3) {
|
||||
if (this.requestcardnumber) {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_车间采购_零件入库',
|
||||
param: `物料流水号=${this.partnumber}&实际到货数量=${this.inboundNumber}&货位流水号=${this.locateNumber}&入库人员流水号=${this.inventoryPeople}&请购单明细流水号=${this.requestcardnumber}&备注=${this.inboundNote}&重量或面积=${this.area}&单位=${this.unit}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.clear()
|
||||
} else {
|
||||
this.$message.error('入库失败')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请扫描二维码')
|
||||
}
|
||||
} else if (this.contractType === 4) {
|
||||
if (this.qrCode) {
|
||||
const param = {
|
||||
url: url,
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '库存管理_车间离线物料货位_增加修改数据',
|
||||
param: `物料流水号=${this.partnumber}&实际到货数量=${this.inboundNumber}&货位流水号=${this.locateNumber}&离线合同明细流水号=${this.qrCode}&入库人员流水号=${this.inventoryPeople}`
|
||||
}
|
||||
}
|
||||
const res = await axios(param)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('入库成功')
|
||||
this.clear()
|
||||
} else {
|
||||
this.$message.error('入库失败')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请扫描二维码')
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请选择货位并填写入库数量')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.el-input{
|
||||
margin-right: 2px;
|
||||
}
|
||||
.searchForm .el-form-item{
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<el-card>
|
||||
<el-card class="cardSBJK">
|
||||
<div class="process">
|
||||
<el-tooltip :enterable="false" :id="OPNAME137" placement="top" @mouseover.native.prevent="changeActive($event)">
|
||||
<div slot="content">{{ tooltip1 }}<br>{{ tooltip2 }}<br>{{ tooltip3 }}<br>单击查看MES系统</div>
|
||||
@@ -491,20 +491,18 @@
|
||||
</el-row>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
<el-tooltip :enterable="false" :id="机床总装" placement="top" @mouseover.native.prevent="changeActive($event)">
|
||||
<div slot="content">{{ tooltip1 }}<br>{{ tooltip2 }}<br>{{ tooltip3 }}</div>
|
||||
<el-tooltip :id="机床总装" placement="bottom" @mouseover.native.prevent="changeActive($event)">
|
||||
<div slot="content" style="max-height: 200px;overflow: auto" v-html="returns1"/>
|
||||
<div :title="tooltip" style="position: relative;left:520px;top:-1170px; width: 100px;height: 28px;">
|
||||
<el-row>
|
||||
<!--<div :id="机床总装+circle" class="circle" style="margin-left: 13px"/>-->
|
||||
<div style="float: left;text-align: center;width: 60px;line-height: 12px;font-size: 15px;font-weight: bold;margin-left: 3px">{{ 机床总装 }}</div>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
<el-tooltip :enterable="false" :id="部件装配" placement="top" @mouseover.native.prevent="changeActive($event)">
|
||||
<div slot="content">{{ tooltip1 }}<br>{{ tooltip2 }}<br>{{ tooltip3 }}</div>
|
||||
<el-tooltip :id="部件装配" placement="bottom" @mouseover.native.prevent="changeActive($event)">
|
||||
<div slot="content" style="max-height: 200px;overflow: auto" v-html="returns2"/>
|
||||
<div :title="tooltip" style="position: relative;left:660px;top:-1198px; width: 100px;height: 28px;">
|
||||
<el-row>
|
||||
<!--<div :id="部件装配+circle" class="circle" style="margin-left: 13px"/>-->
|
||||
<div style="float: left;text-align: center;width: 60px;line-height: 12px;font-size: 15px;font-weight: bold;margin-left: 3px">{{ 部件装配 }}</div>
|
||||
</el-row>
|
||||
</div>
|
||||
@@ -515,12 +513,14 @@
|
||||
|
||||
<script>
|
||||
import $ from 'jquery'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { getwork_state, getOP_state, searchtooltip, getOP_state2, getDaijiagong } from '@/api/ManufacturingCenter/EquipmentMonitoring'
|
||||
import { getwork_state, getOP_state, searchtooltip, getOP_state2, getDaijiagong, getZongzhuang, getBuzhuang } from '@/api/ManufacturingCenter/EquipmentMonitoring'
|
||||
import { wsuri, name3 } from '@/utils/request'
|
||||
import { mapGetters } from 'vuex' // 暂无用
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
returns1: '',
|
||||
returns2: '',
|
||||
fang: '_fang',
|
||||
circle: '_circle',
|
||||
tooltip: '',
|
||||
@@ -583,12 +583,12 @@ export default {
|
||||
opname: ''
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
computed: { // 暂无用
|
||||
...mapGetters([
|
||||
'sidebar'
|
||||
])
|
||||
},
|
||||
watch: {
|
||||
watch: { // 暂无用
|
||||
sidebar(val) {
|
||||
console.log(val)
|
||||
}
|
||||
@@ -633,7 +633,7 @@ export default {
|
||||
},
|
||||
opclickshowPanel($event) {
|
||||
if ($event.path[2].id !== undefined && $event.path[2].id !== null && $event.path[2].id !== '') {
|
||||
var aaa = 'http://192.168.1.232/webpage/MesWebFun02.htm?opname=' + $event.path[2].id + '&ip=192.168.1.231&port=61101'
|
||||
var aaa = 'http://192.168.1.232/webpage/MesWebFun02.htm?opname=' + $event.path[2].id + '&ip=192.168.1.232&port=61101'
|
||||
window.open(aaa)
|
||||
}
|
||||
},
|
||||
@@ -672,24 +672,46 @@ export default {
|
||||
this.tooltip1 = ''
|
||||
this.tooltip2 = ''
|
||||
this.tooltip3 = ''
|
||||
this.returns1 = ''
|
||||
this.returns2 = ''
|
||||
if ($event.path[2].id === '机床总装') {
|
||||
this.tooltip1 = '无装配机床'
|
||||
getZongzhuang().then(res2 => {
|
||||
if (res2.data.length !== 0) {
|
||||
this.returns1 = '<div slot="content">总装机床:<br>'
|
||||
for (let i = 0; i < res2.data.length; i++) {
|
||||
this.returns1 = this.returns1 + res2.data[i].机床图号 + '<br>'
|
||||
}
|
||||
this.returns1 = this.returns1 + '</div>'
|
||||
} else {
|
||||
this.returns1 = '<div slot="content">无总装机床</div>'
|
||||
}
|
||||
})
|
||||
} else if ($event.path[2].id === '部件装配') {
|
||||
this.tooltip1 = '无装配部件'
|
||||
getBuzhuang().then(res3 => {
|
||||
if (res3.data.length !== 0) {
|
||||
this.returns2 = '<div slot="content">部件装配:<br>'
|
||||
for (let i = 0; i < res3.data.length; i++) {
|
||||
this.returns2 = this.returns2 + res3.data[i].机床图号 + ' ' + res3.data[i].任务名称 + '<br>'
|
||||
}
|
||||
this.returns2 = this.returns2 + '</div>'
|
||||
} else {
|
||||
this.returns2 = '<div slot="content">无装配部件</div>'
|
||||
}
|
||||
})
|
||||
} else if ($event.path[2].id === 'OP1470') {
|
||||
searchtooltip($event.path[2].id).then(response => {
|
||||
if (response.data[0].工艺计划流水号 === 0 || response.data[0].工艺计划流水号 === null) {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
getDaijiagong($event.path[2].id).then(res1 => {
|
||||
if (res1.data.length !== 0) {
|
||||
this.tooltip3 = '待热处理零件:' + res1.data[0].零件图号
|
||||
this.tooltip3 = '热处理零件:' + res1.data[0].零件图号
|
||||
} else {
|
||||
this.tooltip3 = '无零件热处理'
|
||||
this.tooltip3 = '热处理零件:无'
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
this.tooltip3 = '正在热处理:' + response.data[0].零件图号_零件工艺计划
|
||||
this.tooltip3 = '热处理零件:' + response.data[0].零件图号_零件工艺计划
|
||||
}
|
||||
this.tooltip2 = ''
|
||||
})
|
||||
@@ -699,14 +721,14 @@ export default {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
getDaijiagong($event.path[2].id).then(res1 => {
|
||||
if (res1.data.length !== 0) {
|
||||
this.tooltip3 = '待处理零件:' + res1.data[0].零件图号
|
||||
this.tooltip3 = '处理零件:' + res1.data[0].零件图号
|
||||
} else {
|
||||
this.tooltip3 = '无零件待处理'
|
||||
this.tooltip3 = '处理零件:无'
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
this.tooltip3 = '正在处理:' + response.data[0].零件图号_零件工艺计划
|
||||
this.tooltip3 = '处理零件:' + response.data[0].零件图号_零件工艺计划
|
||||
}
|
||||
this.tooltip2 = ''
|
||||
})
|
||||
@@ -716,14 +738,14 @@ export default {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
getDaijiagong($event.path[2].id).then(res1 => {
|
||||
if (res1.data.length !== 0) {
|
||||
this.tooltip3 = '待处理零件:' + res1.data[0].零件图号
|
||||
this.tooltip3 = '处理零件:' + res1.data[0].零件图号
|
||||
} else {
|
||||
this.tooltip3 = '无零件待处理'
|
||||
this.tooltip3 = '处理零件:无'
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
this.tooltip3 = '正在处理:' + response.data[0].零件图号_零件工艺计划
|
||||
this.tooltip3 = '处理零件:' + response.data[0].零件图号_零件工艺计划
|
||||
}
|
||||
this.tooltip2 = ''
|
||||
})
|
||||
@@ -733,14 +755,14 @@ export default {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
getDaijiagong($event.path[2].id).then(res1 => {
|
||||
if (res1.data.length !== 0) {
|
||||
this.tooltip3 = '待加工零件:' + res1.data[0].零件图号
|
||||
this.tooltip3 = '加工零件:' + res1.data[0].零件图号
|
||||
} else {
|
||||
this.tooltip3 = '无加工零件'
|
||||
this.tooltip3 = '加工零件:无'
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.tooltip1 = '设备名称:' + response.data[0].设备名称
|
||||
this.tooltip3 = '正在加工零件:' + response.data[0].零件图号_零件工艺计划
|
||||
this.tooltip3 = '加工零件:' + response.data[0].零件图号_零件工艺计划
|
||||
}
|
||||
getOP_state2($event.path[2].id).then(res => {
|
||||
if (res.data[0].状态代码 === '1') { this.tooltip2 = '设备状态:关机' } else if (res.data[0].状态代码 === '2') { this.tooltip2 = '设备状态:等待' } else if (res.data[0].状态代码 === '3') { this.tooltip2 = '设备状态:运行' } else if (res.data[0].状态代码 === '4') { this.tooltip2 = '设备状态:报警' }
|
||||
@@ -840,6 +862,9 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.cardSBJK{
|
||||
overflow: auto;
|
||||
}
|
||||
.process{
|
||||
text-align: center;
|
||||
margin-left: 0px;
|
||||
@@ -850,6 +875,7 @@ export default {
|
||||
background: url('../../../assets/img/img26.jpg') repeat;
|
||||
background-repeat:no-repeat;
|
||||
background-size:100% 100%;-moz-background-size:100% 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
/*绿色*/
|
||||
.circle{
|
||||
|
||||
@@ -88,11 +88,11 @@
|
||||
{{ scope.row.零件图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="重量" align="center" width="140px">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.重量1 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!--<el-table-column label="重量" align="center" width="140px">-->
|
||||
<!--<template slot-scope="scope">-->
|
||||
<!--{{ scope.row.重量1 }}-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
<el-table-column label="单价" align="center" width="140px">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.单价 }}
|
||||
|
||||
@@ -2,8 +2,16 @@
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<div slot="header">
|
||||
<span>供应商:</span>
|
||||
<el-select v-model="gongyingsValue" placeholder="供应商" size="small" filterable clearable @change="fetchData();searchTable1()">
|
||||
<el-option
|
||||
v-for="item in gongyings"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span>合同号:</span>
|
||||
<el-select v-model="contractNumValue" placeholder="合同号" size="small" filterable clearable>
|
||||
<el-select v-model="contractNumValue" placeholder="合同号" size="small" filterable clearable @change="searchTable1()">
|
||||
<el-option
|
||||
v-for="item in contractNum"
|
||||
:key="item.value"
|
||||
@@ -13,8 +21,6 @@
|
||||
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>
|
||||
</el-option>
|
||||
</el-select>
|
||||
<span>供应商:</span>
|
||||
<el-input v-model="supplierName" placeholder="供应商" size="small" clearable/>
|
||||
<el-button
|
||||
type="success"
|
||||
size="small"
|
||||
@@ -129,7 +135,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { initArrivalStateContact, searchArrivalState1, searchArrivalNum, submit } from '@/api/PurchasingCenter/ArrivalStateSearch'
|
||||
import { initArrivalStateContact, searchArrivalState12, searchArrivalNum, submit, searchgongyings } from '@/api/PurchasingCenter/ArrivalStateSearch'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
@@ -138,6 +144,8 @@ export default {
|
||||
return {
|
||||
check1: 0,
|
||||
check2: 0,
|
||||
gongyingsValue: '',
|
||||
gongyings: [],
|
||||
contractNumValue: '',
|
||||
contractNum: [],
|
||||
supplierName: '',
|
||||
@@ -157,12 +165,15 @@ export default {
|
||||
])
|
||||
},
|
||||
created() {
|
||||
this.fetchData()
|
||||
// this.fetchData()
|
||||
this.searchgongyings()
|
||||
this.searchTable1()
|
||||
},
|
||||
methods: {
|
||||
fetchData() {
|
||||
initArrivalStateContact().then(response => {
|
||||
this.contractNumValue = ''
|
||||
this.contractNum = []
|
||||
initArrivalStateContact(this.gongyingsValue).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.contractNum.push({
|
||||
label: response.data[i].采购合同编号,
|
||||
@@ -172,10 +183,20 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
searchgongyings() {
|
||||
searchgongyings().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.gongyings.push({
|
||||
label: response.data[i].供应商名称,
|
||||
value: response.data[i].供应商流水号
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
searchTable1() {
|
||||
this.contractNumValue ? this.check1 = 1 : this.check1 = 0
|
||||
this.supplierName ? this.check2 = 1 : this.check2 = 0
|
||||
searchArrivalState1(this.pageCurrent1, this.pageSize1, this.check1, this.contractNumValue, this.check2, this.supplierName).then(response => {
|
||||
this.gongyingsValue ? this.check2 = 1 : this.check2 = 0
|
||||
searchArrivalState12(this.pageCurrent1, this.pageSize1, this.check1, this.contractNumValue, this.check2, this.gongyingsValue).then(response => {
|
||||
this.tableData1 = response.data.rows
|
||||
this.total1 = response.data.total
|
||||
})
|
||||
|
||||
@@ -100,7 +100,7 @@
|
||||
height="500px"
|
||||
size="mini"
|
||||
@selection-change="handleSelectionChange1">
|
||||
<el-table-column :selectable="selectable" align="center" width="35" type="selection"/>
|
||||
<el-table-column :selectable="selectable" align="center" width="50" type="selection"/>
|
||||
<el-table-column v-if="switchValue" label="操作" align="center" width="100" fixed="left">
|
||||
<template slot-scope="scope">
|
||||
<el-button :disabled="parseInt(scope.row.询价状态编号)!==1||parseInt(scope.row.是否确认)!==1" type="primary" size="mini" @click="materialChange(scope.row)">物料变更</el-button>
|
||||
@@ -129,7 +129,7 @@
|
||||
<!--{{ scope.row.项目名称 }}-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
<el-table-column label="机床图号" align="center" min-width="100">
|
||||
<el-table-column label="机床图号" sortable align="center" min-width="100" prop="机床图号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床图号 }}
|
||||
</template>
|
||||
@@ -154,17 +154,17 @@
|
||||
<!--{{ scope.row.物料品种 }}-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
<el-table-column label="名称" align="center" min-width="100">
|
||||
<el-table-column label="名称" sortable align="center" min-width="100" prop="名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="图号或型号" align="center" min-width="100">
|
||||
<el-table-column label="图号或型号" sortable align="center" min-width="120" prop="物料型号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格" align="center" min-width="150">
|
||||
<el-table-column label="规格" sortable align="center" min-width="150" prop="物料规格">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料规格 }}
|
||||
</template>
|
||||
@@ -1418,7 +1418,6 @@ export default {
|
||||
this.groupValue ? check6 = 1 : check6 = 0
|
||||
searchMaterial(this.pageCurrent11, this.pageSize11, this.materialStatusValue[this.materialStatusValue.length - 1], check1, this.materialName, check2, this.materialSpec, check3, this.materialModel, this.id, check4, this.projectValue, check5, this.machineValue, check6, this.groupValue, 2).then(response => {
|
||||
this.tableData11 = response.data.rows
|
||||
console.log(response.data.rows)
|
||||
this.total11 = response.data.total
|
||||
const remark = []
|
||||
const supplier = []
|
||||
|
||||
@@ -3,6 +3,17 @@
|
||||
<el-card>
|
||||
<el-form label-width="90px" label-position="right">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="供应商:">
|
||||
<el-select v-model="supplierValue11" clearable filterable size="small" placeholder="供应商" style="width:100%" @focus="fetchData11()" @change="selectHetong()">
|
||||
<el-option
|
||||
v-for="item in supplier11"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="合同编号:">
|
||||
<el-select v-model="contractNumValue" filterable size="small" placeholder="合同编号" style="width:100%" @change="contractChange">
|
||||
@@ -14,6 +25,8 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="供应商:">
|
||||
<!--<el-select v-model="supplierValue" clearable filterable size="small" placeholder="供应商" style="width:100%" @focus="fetchData" @change="supplierChange">-->
|
||||
@@ -163,20 +176,20 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-tooltip :open-delay="1000" content="一键删除交货期" placement="right">
|
||||
<el-button type="danger" icon="el-icon-date" size="small" @click="deleteAllDate()"/>
|
||||
</el-tooltip>
|
||||
<span>①选择合同模板:</span>
|
||||
<el-radio-group v-model="demoRadio" size="small" @change="demoChange">
|
||||
<el-radio-button label="模板1"/>
|
||||
<el-radio-button label="模板2" disabled/>
|
||||
<!--<el-radio-button label="自定义" disabled/>-->
|
||||
</el-radio-group>
|
||||
<el-button type="primary" plain size="small" style="margin-left:10px;" @click="editContract()">预览合同</el-button>
|
||||
<!--<el-tooltip :open-delay="1000" content="一键删除交货期" placement="right">-->
|
||||
<!--<el-button type="danger" icon="el-icon-date" size="small" @click="deleteAllDate()"/>-->
|
||||
<!--</el-tooltip>-->
|
||||
<!--<span>①选择合同模板:</span>-->
|
||||
<!--<el-radio-group v-model="demoRadio" size="small" @change="demoChange">-->
|
||||
<!--<el-radio-button label="模板1"/>-->
|
||||
<!--<el-radio-button label="模板2" disabled/>-->
|
||||
<!--<!–<el-radio-button label="自定义" disabled/>–>-->
|
||||
<!--</el-radio-group>-->
|
||||
<!--<el-button type="primary" plain size="small" style="margin-left:10px;" @click="editContract()">预览合同</el-button>-->
|
||||
<!--<span>②确认合同总额:</span>-->
|
||||
<!--<el-input v-model="actualTotal" size="small" style="width: 100px"/>-->
|
||||
<!--<el-button type="primary" size="small" @click="submitTotal()">确认</el-button>-->
|
||||
<span>②递交审批:</span>
|
||||
<span>递交审批:</span>
|
||||
<el-tooltip :open-delay="1000" effect="dark" content="核对信息后生成合同" placement="top">
|
||||
<el-button type="success" size="small" @click="generateContract()">递交</el-button>
|
||||
</el-tooltip>
|
||||
@@ -195,7 +208,7 @@
|
||||
|
||||
<script>
|
||||
import Tinymce from '@/components/Tinymce'
|
||||
import { initSupplier, searchInquirySheet, searchSheetContract, doneContract, searchBaseInfo, savePrice, saveContractHeader, searchContractHeader, saveRemark } from '@/api/PurchasingCenter/CreatePurchaseContract'
|
||||
import { initSupplier11, initSupplier, searchInquirySheet, searchSheetContract, doneContract, searchBaseInfo, savePrice, saveContractHeader, searchContractHeader, saveRemark } from '@/api/PurchasingCenter/CreatePurchaseContract'
|
||||
import { convertCurrency } from '@/vendor/int2Chinese'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { sleep, groupBy } from '@/utils/tool'
|
||||
@@ -206,6 +219,8 @@ export default {
|
||||
inject: ['reload'],
|
||||
data() {
|
||||
return {
|
||||
supplierValue11: '', // 供应商查询条件
|
||||
supplier11: [],
|
||||
quickChangePrice: true,
|
||||
supplier: [],
|
||||
year: '',
|
||||
@@ -267,14 +282,49 @@ export default {
|
||||
])
|
||||
},
|
||||
created() {
|
||||
this.fetchData11()
|
||||
this.fetchData()
|
||||
this.initDirection()
|
||||
},
|
||||
methods: {
|
||||
fetchData11() {
|
||||
initSupplier11(this.id).then(res => {
|
||||
this.supplier11 = []
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.supplier11.push({
|
||||
value: res.data[i].供应商流水号,
|
||||
label: res.data[i].供应商名称
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
selectHetong() {
|
||||
this.contractNumValue = ''
|
||||
if (this.supplierValue11) { this.asdasd = 1 } else { this.asdasd = 0 }
|
||||
searchInquirySheet(0, 0, 0, 0, 1, this.id, this.asdasd, this.supplierValue11).then(response => { // 初始化询价单号
|
||||
this.contractNums = []
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.contractNums.push({
|
||||
value: response.data[i].询价单流水号,
|
||||
label: response.data[i].询价单编号,
|
||||
supplierName: response.data[i].供应商名称,
|
||||
supplierValue: response.data[i].供应商流水号,
|
||||
supplierAddress: response.data[i].地址,
|
||||
legalPerson: response.data[i].企业性质, // 法人
|
||||
trustee: response.data[i].注册资本 || '', // 受托人
|
||||
bank1: response.data[i].开户行 || '', // 开户行
|
||||
account1: response.data[i].帐号 || '', // 帐号
|
||||
taxCode1: response.data[i].税号 || '', // 税号
|
||||
phone1: response.data[i].电话号码 || '', // 电话
|
||||
fax1: response.data[i].传真 || '', // 传真
|
||||
postCode1: response.data[i].货期 || '' // 邮编
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
initDirection() {
|
||||
const direction = this.$getDirection()
|
||||
direction.on('keyup', function(e, val) {
|
||||
console.log(val)
|
||||
if (e.keyCode === 39) {
|
||||
direction.next()
|
||||
}
|
||||
@@ -371,7 +421,6 @@ export default {
|
||||
},
|
||||
fetchData() {
|
||||
initSupplier(this.id).then(res => {
|
||||
// this.id
|
||||
this.supplier = []
|
||||
for (let i = 0; i < res.data.length; i++) {
|
||||
this.supplier.push({
|
||||
@@ -509,6 +558,8 @@ export default {
|
||||
})
|
||||
}
|
||||
})
|
||||
this.demo1()
|
||||
this.editContract()
|
||||
},
|
||||
demoChange() { // 模板change
|
||||
switch (this.demoRadio) {
|
||||
@@ -678,106 +729,106 @@ export default {
|
||||
this.day = date.getDate()
|
||||
this.demoChange()
|
||||
await sleep(0)
|
||||
if (this.contractNumValue) {
|
||||
if (this.demoRadio) {
|
||||
// this.$refs.tinymce.destroyTinymce()
|
||||
document.getElementById('contractName') ? document.getElementById('contractName').innerHTML = this.contractName : ''
|
||||
document.getElementById('contractNum') ? document.getElementById('contractNum').innerHTML = this.contractNum : ''
|
||||
document.getElementById('supplierName') ? document.getElementById('supplierName').innerHTML = this.supplierName : ''
|
||||
document.getElementById('supplierAddress') ? document.getElementById('supplierAddress').innerHTML = this.supplierAddress : ''
|
||||
document.getElementById('legalPerson') ? document.getElementById('legalPerson').innerHTML = this.legalPerson : ''
|
||||
document.getElementById('payDate') ? document.getElementById('payDate').innerHTML = this.payDate : ''
|
||||
document.getElementById('payMethod') ? document.getElementById('payMethod').innerHTML = this.payMethod : ''
|
||||
document.getElementById('invoiceInfo') ? document.getElementById('invoiceInfo').innerHTML = this.invoiceInfo : ''
|
||||
document.getElementById('deliveryDate') ? document.getElementById('deliveryDate').innerHTML = this.deliveryDate : ''
|
||||
document.getElementById('otherInfo') ? document.getElementById('otherInfo').innerHTML = this.otherInfo : ''
|
||||
document.getElementById('hasTax') ? document.getElementById('hasTax').innerHTML = this.hasTax : ''
|
||||
document.getElementById('taxRate') ? document.getElementById('taxRate').innerHTML = this.taxRate * 100 + '%' : ''
|
||||
// 明细表
|
||||
// 移出旧数据
|
||||
const children = document.getElementsByClassName('tableData')
|
||||
const parent = document.getElementById('tbody')
|
||||
if (children.length !== 0) {
|
||||
for (let i = children.length - 1; i >= 0; i--) {
|
||||
parent.removeChild(children[i])
|
||||
}
|
||||
}
|
||||
const merge = []
|
||||
this.tableData1.map(v => {
|
||||
if ((this.hasTax === '含税' && v.含税单价.trim() !== '') || (this.hasTax === '未税' && v.未税单价.trim() !== '')) { // 筛掉未询到价格的物料
|
||||
merge.push({
|
||||
机床图号: v.机床图号,
|
||||
组号: v.组号,
|
||||
图号: v.图号,
|
||||
名称: v.名称,
|
||||
规格: v.规格,
|
||||
数量: Number(v.数量),
|
||||
计量单位: v.计量单位,
|
||||
单价: this.hasTax === '含税' ? v.含税单价 : v.未税单价,
|
||||
合计: (Number(v.数量) * (this.hasTax === '含税' ? Number(v.含税单价) : Number(v.未税单价))).toFixed(2),
|
||||
交货期: v.交货期 ? v.交货期.split(' ')[0] : '',
|
||||
备注: v.备注
|
||||
})
|
||||
}
|
||||
})
|
||||
let mergeData = []
|
||||
mergeData = groupBy(merge, ['图号', '名称', '规格', '计量单位', '单价', '交货期', '备注'])
|
||||
// 放入新数据
|
||||
const tr = []
|
||||
for (let i = 0; i < mergeData.length; i++) {
|
||||
tr[i] = document.createElement('tr')
|
||||
tr[i].setAttribute('class', 'tableData')
|
||||
tr[i].innerHTML = '<td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td>'
|
||||
const tableHead = $('#tableHead')
|
||||
tableHead ? tableHead.after(tr[i]) : ''
|
||||
}
|
||||
this.actualTotal = 0
|
||||
this.untaxTotal = 0
|
||||
this.taxTotal = 0
|
||||
for (let j = 0; j < this.tableData1.length; j++) {
|
||||
this.actualTotal += Number(this.tableData1[j].含税总额)
|
||||
this.untaxTotal += Number(this.tableData1[j].未税总额)
|
||||
this.taxTotal += Number(this.tableData1[j].含税总额)
|
||||
}
|
||||
for (let j = 0; j < mergeData.length; j++) {
|
||||
if (document.getElementsByClassName('tableData')[j]) {
|
||||
document.getElementsByClassName('tableData')[j].children[0].innerHTML = j + 1
|
||||
document.getElementsByClassName('tableData')[j].children[1].innerHTML = mergeData[j].机床图号_组号
|
||||
document.getElementsByClassName('tableData')[j].children[2].innerHTML = mergeData[j].名称
|
||||
document.getElementsByClassName('tableData')[j].children[3].innerHTML = mergeData[j].图号
|
||||
document.getElementsByClassName('tableData')[j].children[4].innerHTML = mergeData[j].规格
|
||||
document.getElementsByClassName('tableData')[j].children[5].innerHTML = mergeData[j].数量
|
||||
document.getElementsByClassName('tableData')[j].children[6].innerHTML = mergeData[j].计量单位
|
||||
document.getElementsByClassName('tableData')[j].children[7].innerHTML = mergeData[j].单价
|
||||
document.getElementsByClassName('tableData')[j].children[8].innerHTML = (Number(mergeData[j].数量) * Number(mergeData[j].单价)).toFixed(2)
|
||||
document.getElementsByClassName('tableData')[j].children[9].innerHTML = mergeData[j].交货期
|
||||
document.getElementsByClassName('tableData')[j].children[10].innerHTML = mergeData[j].备注
|
||||
}
|
||||
}
|
||||
this.actualTotal = this.actualTotal.toFixed(2)
|
||||
this.untaxTotal = this.untaxTotal.toFixed(2)
|
||||
this.taxTotal = this.taxTotal.toFixed(2)
|
||||
this.tax = (this.taxTotal - this.untaxTotal).toFixed(2)
|
||||
document.getElementById('untaxTotal') ? document.getElementById('untaxTotal').innerHTML = this.untaxTotal : ''
|
||||
document.getElementById('tax') ? document.getElementById('tax').innerHTML = this.tax : ''
|
||||
document.getElementById('taxTotal') ? document.getElementById('taxTotal').innerHTML = this.taxTotal : ''
|
||||
document.getElementsByClassName('actualTotal')[0] ? document.getElementsByClassName('actualTotal')[0].innerHTML = this.actualTotal : ''
|
||||
document.getElementsByClassName('actualTotal')[1] ? document.getElementsByClassName('actualTotal')[1].innerHTML = this.actualTotal : ''
|
||||
document.getElementById('actualTotal_zh') ? document.getElementById('actualTotal_zh').innerHTML = this.actualTotal_zh : ''
|
||||
document.getElementsByClassName('actualTotal')[0].innerHTML = this.actualTotal
|
||||
document.getElementsByClassName('actualTotal')[1].innerHTML = this.actualTotal
|
||||
document.getElementById('actualTotal_zh').innerHTML = convertCurrency(this.actualTotal)
|
||||
this.contentNew = document.getElementsByClassName('editor-content')[0].innerHTML
|
||||
this.$refs.tinymce.initTinymce()
|
||||
setTimeout(() => {
|
||||
this.$refs.tinymce.setContent(this.contentNew)
|
||||
}, 1000)
|
||||
} else {
|
||||
this.$message.warning('请先选择合同模板,再预览')
|
||||
// if (this.contractNumValue) {
|
||||
// if (this.demoRadio) {
|
||||
// this.$refs.tinymce.destroyTinymce()
|
||||
document.getElementById('contractName') ? document.getElementById('contractName').innerHTML = this.contractName : ''
|
||||
document.getElementById('contractNum') ? document.getElementById('contractNum').innerHTML = this.contractNum : ''
|
||||
document.getElementById('supplierName') ? document.getElementById('supplierName').innerHTML = this.supplierName : ''
|
||||
document.getElementById('supplierAddress') ? document.getElementById('supplierAddress').innerHTML = this.supplierAddress : ''
|
||||
document.getElementById('legalPerson') ? document.getElementById('legalPerson').innerHTML = this.legalPerson : ''
|
||||
document.getElementById('payDate') ? document.getElementById('payDate').innerHTML = this.payDate : ''
|
||||
document.getElementById('payMethod') ? document.getElementById('payMethod').innerHTML = this.payMethod : ''
|
||||
document.getElementById('invoiceInfo') ? document.getElementById('invoiceInfo').innerHTML = this.invoiceInfo : ''
|
||||
document.getElementById('deliveryDate') ? document.getElementById('deliveryDate').innerHTML = this.deliveryDate : ''
|
||||
document.getElementById('otherInfo') ? document.getElementById('otherInfo').innerHTML = this.otherInfo : ''
|
||||
document.getElementById('hasTax') ? document.getElementById('hasTax').innerHTML = this.hasTax : ''
|
||||
document.getElementById('taxRate') ? document.getElementById('taxRate').innerHTML = this.taxRate * 100 + '%' : ''
|
||||
// 明细表
|
||||
// 移出旧数据
|
||||
const children = document.getElementsByClassName('tableData')
|
||||
const parent = document.getElementById('tbody')
|
||||
if (children.length !== 0) {
|
||||
for (let i = children.length - 1; i >= 0; i--) {
|
||||
parent.removeChild(children[i])
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请先选择合同,再预览')
|
||||
}
|
||||
const merge = []
|
||||
this.tableData1.map(v => {
|
||||
if ((this.hasTax === '含税' && v.含税单价.trim() !== '') || (this.hasTax === '未税' && v.未税单价.trim() !== '')) { // 筛掉未询到价格的物料
|
||||
merge.push({
|
||||
机床图号: v.机床图号,
|
||||
组号: v.组号,
|
||||
图号: v.图号,
|
||||
名称: v.名称,
|
||||
规格: v.规格,
|
||||
数量: Number(v.数量),
|
||||
计量单位: v.计量单位,
|
||||
单价: this.hasTax === '含税' ? v.含税单价 : v.未税单价,
|
||||
合计: (Number(v.数量) * (this.hasTax === '含税' ? Number(v.含税单价) : Number(v.未税单价))).toFixed(2),
|
||||
交货期: v.交货期 ? v.交货期.split(' ')[0] : '',
|
||||
备注: v.备注
|
||||
})
|
||||
}
|
||||
})
|
||||
let mergeData = []
|
||||
mergeData = groupBy(merge, ['图号', '名称', '规格', '计量单位', '单价', '交货期', '备注'])
|
||||
// 放入新数据
|
||||
const tr = []
|
||||
for (let i = 0; i < mergeData.length; i++) {
|
||||
tr[i] = document.createElement('tr')
|
||||
tr[i].setAttribute('class', 'tableData')
|
||||
tr[i].innerHTML = '<td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td>'
|
||||
const tableHead = $('#tableHead')
|
||||
tableHead ? tableHead.after(tr[i]) : ''
|
||||
}
|
||||
this.actualTotal = 0
|
||||
this.untaxTotal = 0
|
||||
this.taxTotal = 0
|
||||
for (let j = 0; j < this.tableData1.length; j++) {
|
||||
this.actualTotal += Number(this.tableData1[j].含税总额)
|
||||
this.untaxTotal += Number(this.tableData1[j].未税总额)
|
||||
this.taxTotal += Number(this.tableData1[j].含税总额)
|
||||
}
|
||||
for (let j = 0; j < mergeData.length; j++) {
|
||||
if (document.getElementsByClassName('tableData')[j]) {
|
||||
document.getElementsByClassName('tableData')[j].children[0].innerHTML = j + 1
|
||||
document.getElementsByClassName('tableData')[j].children[1].innerHTML = mergeData[j].机床图号_组号
|
||||
document.getElementsByClassName('tableData')[j].children[2].innerHTML = mergeData[j].名称
|
||||
document.getElementsByClassName('tableData')[j].children[3].innerHTML = mergeData[j].图号
|
||||
document.getElementsByClassName('tableData')[j].children[4].innerHTML = mergeData[j].规格
|
||||
document.getElementsByClassName('tableData')[j].children[5].innerHTML = mergeData[j].数量
|
||||
document.getElementsByClassName('tableData')[j].children[6].innerHTML = mergeData[j].计量单位
|
||||
document.getElementsByClassName('tableData')[j].children[7].innerHTML = mergeData[j].单价
|
||||
document.getElementsByClassName('tableData')[j].children[8].innerHTML = (Number(mergeData[j].数量) * Number(mergeData[j].单价)).toFixed(2)
|
||||
document.getElementsByClassName('tableData')[j].children[9].innerHTML = mergeData[j].交货期
|
||||
document.getElementsByClassName('tableData')[j].children[10].innerHTML = mergeData[j].备注
|
||||
}
|
||||
}
|
||||
this.actualTotal = this.actualTotal.toFixed(2)
|
||||
this.untaxTotal = this.untaxTotal.toFixed(2)
|
||||
this.taxTotal = this.taxTotal.toFixed(2)
|
||||
this.tax = (this.taxTotal - this.untaxTotal).toFixed(2)
|
||||
document.getElementById('untaxTotal') ? document.getElementById('untaxTotal').innerHTML = this.untaxTotal : ''
|
||||
document.getElementById('tax') ? document.getElementById('tax').innerHTML = this.tax : ''
|
||||
document.getElementById('taxTotal') ? document.getElementById('taxTotal').innerHTML = this.taxTotal : ''
|
||||
document.getElementsByClassName('actualTotal')[0] ? document.getElementsByClassName('actualTotal')[0].innerHTML = this.actualTotal : ''
|
||||
document.getElementsByClassName('actualTotal')[1] ? document.getElementsByClassName('actualTotal')[1].innerHTML = this.actualTotal : ''
|
||||
document.getElementById('actualTotal_zh') ? document.getElementById('actualTotal_zh').innerHTML = this.actualTotal_zh : ''
|
||||
document.getElementsByClassName('actualTotal')[0].innerHTML = this.actualTotal
|
||||
document.getElementsByClassName('actualTotal')[1].innerHTML = this.actualTotal
|
||||
document.getElementById('actualTotal_zh').innerHTML = convertCurrency(this.actualTotal)
|
||||
this.contentNew = document.getElementsByClassName('editor-content')[0].innerHTML
|
||||
this.$refs.tinymce.initTinymce()
|
||||
setTimeout(() => {
|
||||
this.$refs.tinymce.setContent(this.contentNew)
|
||||
}, 1000)
|
||||
// } else {
|
||||
// this.$message.warning('请先选择合同模板,再预览')
|
||||
// }
|
||||
// } else {
|
||||
// this.$message.warning('请先选择合同,再预览')
|
||||
// }
|
||||
},
|
||||
demo2() {
|
||||
this.content = `demo2`
|
||||
@@ -808,33 +859,33 @@ export default {
|
||||
inquiryDetailNum_old.push(v.询价单明细流水号)
|
||||
}
|
||||
})
|
||||
if (this.contractNumValue) {
|
||||
if (this.demoRadio) {
|
||||
this.$confirm('此采购合同将递交审批,递交后该合同不可删除,确认完成编辑?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
doneContract(this.contractNum, this.contractName, this.deliveryDate, this.payDate, this.payMethod, this.invoiceInfo, this.otherInfo, this.actualTotal, this.id, this.supplierValue, this.单价是否含税, this.组件零件流水号组, this.组件零件基本件流水号组, this.数量组, this.单价组, this.交货期组, this.content, this.taxRate * 100, inquiryDetailNum_old, this.备注组).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('合同生成成功')
|
||||
this.reload()
|
||||
} else {
|
||||
this.$message.error('生成合同失败')
|
||||
}
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消操作'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('请先选择模板进行预览')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请先选择合同进行编辑')
|
||||
}
|
||||
// if (this.contractNumValue) {
|
||||
// if (this.demoRadio) {
|
||||
this.$confirm('此采购合同将递交审批,递交后该合同不可删除,确认完成编辑?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
doneContract(this.contractNum, this.contractName, this.deliveryDate, this.payDate, this.payMethod, this.invoiceInfo, this.otherInfo, this.actualTotal, this.id, this.supplierValue, this.单价是否含税, this.组件零件流水号组, this.组件零件基本件流水号组, this.数量组, this.单价组, this.交货期组, this.content, this.taxRate * 100, inquiryDetailNum_old, this.备注组).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('合同生成成功')
|
||||
this.reload()
|
||||
} else {
|
||||
this.$message.error('生成合同失败')
|
||||
}
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消操作'
|
||||
})
|
||||
})
|
||||
// } else {
|
||||
// this.$message.warning('请先选择模板进行预览')
|
||||
// }
|
||||
// } else {
|
||||
// this.$message.warning('请先选择合同进行编辑')
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
728
src/views/PurchasingCenter/MaterialMProcure/index.vue
Normal file
728
src/views/PurchasingCenter/MaterialMProcure/index.vue
Normal file
@@ -0,0 +1,728 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<el-row>
|
||||
<el-col style="width: 280px;margin-top: 3px">
|
||||
<span>物料类别:</span>
|
||||
<el-select
|
||||
v-model="MaterialCategoryValue"
|
||||
placeholder="请选择"
|
||||
size="small"
|
||||
clearable
|
||||
@change="searchMaterialVariety">
|
||||
<el-option
|
||||
v-for="item in MaterialCategory"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-col>
|
||||
<el-col style="width: 280px;margin-top: 3px">
|
||||
<span>物料品种:</span>
|
||||
<el-select
|
||||
v-model="MaterialVarietyValue"
|
||||
placeholder="请选择"
|
||||
size="small"
|
||||
clearable
|
||||
@change="searchMaterial">
|
||||
<el-option
|
||||
v-for="item in MaterialVariety"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-col>
|
||||
<el-col style="width: 280px;margin-top: 3px">
|
||||
<span>物料名称:</span>
|
||||
<el-input v-model="MaterialName" placeholder="物料名称" size="small" clearable />
|
||||
</el-col>
|
||||
<el-col style="width: 280px;margin-top: 3px">
|
||||
<span>物料全称:</span>
|
||||
<el-input
|
||||
v-model="FullNameOfMaterial"
|
||||
placeholder="物料全称"
|
||||
size="small"
|
||||
clearable/>
|
||||
</el-col>
|
||||
<el-col style="width: 280px;margin-top: 3px">
|
||||
<span>物料规格:</span>
|
||||
<el-input
|
||||
v-model="MaterialSpecification"
|
||||
placeholder="物料规格"
|
||||
size="small"
|
||||
clearable/>
|
||||
</el-col>
|
||||
<el-col style="width: 280px;margin-top: 3px">
|
||||
<span>物料型号:</span>
|
||||
<el-input
|
||||
v-model="MaterialModel"
|
||||
placeholder="物料型号"
|
||||
size="small"
|
||||
clearable/>
|
||||
</el-col>
|
||||
<el-col style="width: 280px">
|
||||
<span>计算单位:</span>
|
||||
<el-select
|
||||
v-model="MeasurementUnitValue"
|
||||
placeholder="请选择"
|
||||
style="margin-bottom: 3px;margin-top: 10px"
|
||||
size="small"
|
||||
clearable>
|
||||
<el-option
|
||||
v-for="item in MeasurementUnit"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-col>
|
||||
<el-col style="width: 280px">
|
||||
<span>物料来源:</span>
|
||||
<el-select
|
||||
v-model="MaterialSourceValue"
|
||||
placeholder="请选择"
|
||||
style="margin-bottom: 3px;margin-top: 10px"
|
||||
size="small"
|
||||
clearable>
|
||||
<el-option
|
||||
v-for="item in MaterialSource"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-col>
|
||||
<el-col style="width: 280px">
|
||||
<span style="margin-left: 15px">供货商:</span>
|
||||
<el-select
|
||||
v-model="GonghuoshangValue"
|
||||
placeholder="请选择"
|
||||
filterable
|
||||
style="margin-bottom: 3px;margin-top: 10px"
|
||||
size="small"
|
||||
clearable>
|
||||
<el-option
|
||||
v-for="item in Gonghuoshang"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<!--<el-input-->
|
||||
<!--v-model="supplier"-->
|
||||
<!--placeholder="供货商"-->
|
||||
<!--size="small"-->
|
||||
<!--style="margin-bottom: 3px;margin-top: 10px"-->
|
||||
<!--clearable-->
|
||||
<!--@dblclick.native="param=0;openSupplier()"/>-->
|
||||
</el-col>
|
||||
<el-col style="width: 550px">
|
||||
<el-button
|
||||
type="success"
|
||||
icon="el-icon-search"
|
||||
size="small"
|
||||
style="margin-left: 10px"
|
||||
@click="pageCurrent=1;searchMaterial()">查询</el-button>
|
||||
<el-button type="primary" style="margin-bottom: 3px;margin-top: 10px" icon="el-icon-circle-plus-outline" size="small" @click="handleAdd()">新增采购物料申请</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-card>
|
||||
|
||||
<el-card>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
style="width: 100%;margin-top: 3px"
|
||||
height="600"
|
||||
size="mini"
|
||||
highlight-current-row
|
||||
border
|
||||
stripe>
|
||||
<el-table-column align="center" label="物料名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="物料规格">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料规格 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="物料型号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="供货商">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.供货商 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="审核状态">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.是否通过===0" type="primary" size="small">未审核</el-tag>
|
||||
<el-tag v-if="scope.row.是否通过===1" type="success" size="small">已通过</el-tag>
|
||||
<el-tag v-if="scope.row.是否通过===2" type="danger" size="small">未通过</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="打回原因">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.打回原因 ? scope.row.打回原因 : '——' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!--<el-table-column label="操作" fixed="right" align="center" width="150">-->
|
||||
<!--<template slot-scope="scope">-->
|
||||
<!--<el-tooltip :open-delay="1000" effect="dark" content="编辑">-->
|
||||
<!--<div style="display: inline-block">-->
|
||||
<!--<el-button-->
|
||||
<!--:disabled="token !== 11 && token !== 36"-->
|
||||
<!--size="mini"-->
|
||||
<!--type="text"-->
|
||||
<!--icon="el-icon-edit-outline"-->
|
||||
<!--@click="handleEdit(scope.row)"/>-->
|
||||
<!--</div>-->
|
||||
<!--</el-tooltip>-->
|
||||
<!--<el-tooltip effect="dark" content="删除" placement="top">-->
|
||||
<!--<div style="display: inline-block">-->
|
||||
<!--<el-button-->
|
||||
<!--:disabled="token !== 11 && token !== 36"-->
|
||||
<!--size="mini"-->
|
||||
<!--type="text"-->
|
||||
<!--style="margin-left: 20px"-->
|
||||
<!--icon="el-icon-delete"-->
|
||||
<!--@click="handleDelete(scope.row)"/>-->
|
||||
<!--</div>-->
|
||||
<!--</el-tooltip>-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
</el-table>
|
||||
<div class="block" style="margin-top: 10px;">
|
||||
<el-pagination
|
||||
:current-page="pageCurrent"
|
||||
:page-sizes="[10, 20, 30, 40, 50]"
|
||||
:page-size="pageSize"
|
||||
:total="total"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"/>
|
||||
</div>
|
||||
</el-card>
|
||||
|
||||
<el-dialog v-el-drag-dialog :title="title" :visible.sync="dialogFormVisible1" center style="min-height: 300px" width="800px">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料类别" prop="物料类别流水号">
|
||||
<el-select
|
||||
v-model="form.物料类别流水号"
|
||||
style="width:200px"
|
||||
placeholder="请选择"
|
||||
size="small"
|
||||
clearable
|
||||
@change="searchMaterialVariety1">
|
||||
<el-option
|
||||
v-for="item in MaterialCategory1"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料品种" prop="物料品种流水号">
|
||||
<el-select v-model="form.物料品种流水号" style="width:200px" placeholder="请选择" size="small" clearable>
|
||||
<el-option
|
||||
v-for="item in MaterialVariety1"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料名称" prop="物料名称">
|
||||
<el-input v-model="form.物料名称" placeholder="物料名称" size="small" clearable style="width:200px"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料全名" prop="物料全名">
|
||||
<el-input v-model="form.物料全名" placeholder="物料全名" size="small" clearable style="width:200px"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料规格" prop="物料规格">
|
||||
<el-input v-model="form.物料规格" placeholder="物料规格" size="small" clearable style="width:200px"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料型号" prop="物料型号">
|
||||
<el-input v-model="form.物料型号" placeholder="物料型号" size="small" clearable style="width:200px"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="计量单位" prop="计量单位流水号">
|
||||
<el-select v-model="form.计量单位流水号" style="width:200px" placeholder="请选择" size="small">
|
||||
<el-option
|
||||
v-for="item in MeasurementUnit"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料来源" prop="物料来源流水号">
|
||||
<el-select v-model="form.物料来源流水号" style="width:200px" placeholder="请选择" size="small">
|
||||
<el-option
|
||||
v-for="item in MaterialSource"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="供货商" prop="GonghuoshangValue">
|
||||
<el-select
|
||||
v-model="form.GonghuoshangValue"
|
||||
placeholder="请选择"
|
||||
filterable
|
||||
style="width:200px"
|
||||
size="small"
|
||||
clearable>
|
||||
<el-option
|
||||
v-for="item in Gonghuoshang2"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<!--<el-input-->
|
||||
<!--v-model="form.供货商"-->
|
||||
<!--placeholder="供货商"-->
|
||||
<!--size="small"-->
|
||||
<!--clearable-->
|
||||
<!--style="width:200px"-->
|
||||
<!--@click.native="param=1;openSupplier()"/>-->
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="常用符号">
|
||||
Φ × ∠ — ○ ⊥ m² μ δ Ⅰ Ⅱ Ⅲ ∥ ±
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="cancel('form')">取消</el-button>
|
||||
<el-button v-show="title==='新增物料申请'" type="primary" @click="submitAdd('form')">提交技术审核</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
getSupplier1,
|
||||
AddGonghuoshang,
|
||||
initDepartmentName,
|
||||
initMaterialCategory,
|
||||
initMaterialVariety,
|
||||
initMeasurementUnit,
|
||||
initMaterialSource,
|
||||
searchmaterial,
|
||||
getSupplier,
|
||||
addData,
|
||||
editData,
|
||||
deleteData,
|
||||
searchCategory,
|
||||
searchVarieties,
|
||||
editCategory,
|
||||
addCategory,
|
||||
deleteCategory,
|
||||
editVariety,
|
||||
addVariety,
|
||||
deleteVariety
|
||||
} from '@/api/PurchasingCenter/MaterialMProcure'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
Gonghuoshang: [],
|
||||
Gonghuoshang2: [],
|
||||
GonghuoshangValue: '',
|
||||
form3: {
|
||||
供货商名称: ''
|
||||
},
|
||||
rules3: {
|
||||
供货商名称: [{ required: true, message: '请输入供货商名称', trigger: 'blur' }]
|
||||
},
|
||||
dialogFormVisible3: false,
|
||||
DepartmentValue: '', // 部门名称
|
||||
Department: [], // 部门数组
|
||||
MaterialCategoryValue: '', // 物料类别
|
||||
MaterialCategory: [], // 物料类别数组
|
||||
MaterialVarietyValue: '', // 物料品种
|
||||
MaterialVariety: [], // 物料品种数组
|
||||
MaterialName: '', // 物料名称
|
||||
FullNameOfMaterial: '', // 物料全称
|
||||
MaterialSpecification: '', // 物料规格
|
||||
MaterialModel: '', // 物料型号
|
||||
MeasurementUnitValue: '', // 计量单位
|
||||
MeasurementUnit: [], // 计量单位数组
|
||||
MaterialSourceValue: '', // 物料来源
|
||||
MaterialSource: [], // 物料来源数组
|
||||
supplier: '', // 供货商
|
||||
supplier1: '', // 供货商(弹框)
|
||||
supplierValue: '', // 供货商流水号
|
||||
ReferencePrice: '', // 参考价格
|
||||
supplierValue1: '',
|
||||
MaterialCategory1: [],
|
||||
MaterialVariety1: [],
|
||||
MaterialCategory2: '', // 物料类别
|
||||
CategoryNumber: '', // 类别编号
|
||||
VarietyNumber: '', // 品种编号
|
||||
MaterialVariety2: '', // 物料品种
|
||||
Specifications1: '', // 规格1
|
||||
Specifications2: '', // 规格2
|
||||
MaterialCategoryNum: '', // 物料类别流水号
|
||||
MaterialVarietyNum: '', // 物料品种流水号
|
||||
param: 0,
|
||||
tableData: [],
|
||||
pageCurrent: 1,
|
||||
pageSize: 30,
|
||||
total: null,
|
||||
tableData1: [],
|
||||
pageCurrent1: 1,
|
||||
pageSize1: 10,
|
||||
total1: null,
|
||||
tableData2: [],
|
||||
tableData3: [],
|
||||
dialogFormVisible: false,
|
||||
dialogFormVisible1: false,
|
||||
dialogFormVisible2: false,
|
||||
check1: '',
|
||||
check2: '',
|
||||
check3: '',
|
||||
check4: '',
|
||||
check5: '',
|
||||
check6: '',
|
||||
check7: '',
|
||||
check8: '',
|
||||
check9: '',
|
||||
check10: '',
|
||||
title: '',
|
||||
form: {
|
||||
物料流水号: '',
|
||||
物料类别流水号: '',
|
||||
物料品种流水号: '',
|
||||
物料名称: '',
|
||||
物料全名: '',
|
||||
物料规格: '',
|
||||
物料型号: '',
|
||||
计量单位流水号: '',
|
||||
物料来源流水号: '',
|
||||
GonghuoshangValue: ''
|
||||
},
|
||||
rules: {
|
||||
物料名称: [{ required: true, message: '请输入物料名称', trigger: 'blur' }],
|
||||
GonghuoshangValue: [{ required: true, message: '请选择供货商', trigger: 'change' }],
|
||||
物料类别流水号: [{ required: true, message: '请选择物料类别', trigger: 'change' }],
|
||||
物料品种流水号: [{ required: true, message: '请选择物料品种', trigger: 'change' }],
|
||||
计量单位流水号: [{ required: true, message: '请选择计量单位', trigger: 'change' }],
|
||||
物料来源流水号: [{ required: true, message: '请选择物料来源', trigger: 'change' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'name',
|
||||
'id',
|
||||
'token'
|
||||
])
|
||||
},
|
||||
created() {
|
||||
this.fetchData()
|
||||
this.searchMaterialCategory()
|
||||
this.getGonghuoshang()
|
||||
this.searchMaterial()
|
||||
},
|
||||
methods: {
|
||||
getGonghuoshang() { // 供货商初始化查询
|
||||
this.Gonghuoshang = []
|
||||
this.Gonghuoshang2 = []
|
||||
getSupplier1(0, 0).then(response => {
|
||||
response.data.map(v => {
|
||||
this.Gonghuoshang.push({
|
||||
label: v.供货商,
|
||||
value: v.供货商流水号
|
||||
})
|
||||
this.Gonghuoshang2.push({
|
||||
label: v.供货商,
|
||||
value: v.供货商流水号
|
||||
})
|
||||
})
|
||||
})
|
||||
},
|
||||
open() {
|
||||
if (this.$refs['form3'] !== undefined) {
|
||||
this.$refs['form3'].resetFields()
|
||||
}
|
||||
this.form3.供货商名称 = ''
|
||||
this.dialogFormVisible3 = true
|
||||
},
|
||||
AddGonghuoshang(formName) {
|
||||
this.$refs[formName].validate((valid) => {
|
||||
if (valid) {
|
||||
AddGonghuoshang(this.form3.供货商名称).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('添加成功')
|
||||
this.dialogFormVisible3 = false
|
||||
} else {
|
||||
this.dialogFormVisible3 = false
|
||||
this.$message.error('添加失败')
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
fetchData() {
|
||||
this.getSelect(initDepartmentName, ['物料部门名称', '物料部门流水号'], 'Department') // 物料部门
|
||||
this.getSelect(initMeasurementUnit, ['计量单位', '计量单位流水号'], 'MeasurementUnit') // 计量单位
|
||||
this.getSelect(initMaterialSource, ['物料来源', '物料来源流水号'], 'MaterialSource') // 物料来源
|
||||
},
|
||||
searchMaterialCategory() { // 获取物料类别
|
||||
this.MaterialCategory = []
|
||||
this.MaterialVariety = []
|
||||
this.MaterialCategoryValue = ''
|
||||
this.MaterialVarietyValue = ''
|
||||
this.getSelect(initMaterialCategory, ['物料类别', '物料类别流水号'], 'MaterialCategory', [0, this.DepartmentValue])
|
||||
},
|
||||
searchMaterialVariety() { // 初始化物料品种
|
||||
this.MaterialVariety = []
|
||||
this.MaterialVarietyValue = ''
|
||||
this.getSelect(initMaterialVariety, ['物料品种', '物料品种流水号'], 'MaterialVariety', this.MaterialCategoryValue)
|
||||
},
|
||||
searchMaterial() { // 物料查询
|
||||
this.MaterialName !== '' ? this.check1 = 1 : this.check1 = 0 // 物料名称
|
||||
this.FullNameOfMaterial !== '' ? this.check2 = 1 : this.check2 = 0 // 物料全称
|
||||
this.MaterialSpecification !== '' ? this.check3 = 1 : this.check3 = 0 // 物料规格
|
||||
this.MaterialModel !== '' ? this.check4 = 1 : this.check4 = 0 // 物料型号
|
||||
this.MaterialCategoryValue !== '' ? this.check5 = 1 : this.check5 = 0 // 物料类别
|
||||
this.MaterialVarietyValue !== '' ? this.check6 = 1 : this.check6 = 0 // 物料品种
|
||||
this.MeasurementUnitValue !== '' ? this.check7 = 1 : this.check7 = 0 // 计量单位
|
||||
this.MaterialSourceValue !== '' ? this.check8 = 1 : this.check8 = 0 // 物料来源
|
||||
this.GonghuoshangValue !== '' ? this.check9 = 1 : this.check9 = 0 // 供货商
|
||||
searchmaterial(this.check1, this.MaterialName, this.check2, this.FullNameOfMaterial, this.check3, this.MaterialSpecification, this.check4, this.MaterialModel, this.pageCurrent, this.pageSize, this.check5, this.MaterialCategoryValue, this.check6, this.MaterialVarietyValue, this.check7, this.MeasurementUnitValue, this.check8, this.MaterialSourceValue, this.check9, this.GonghuoshangValue).then(response => {
|
||||
this.tableData = response.data.result
|
||||
this.total = parseInt(response.data.output[0].ItemCount)
|
||||
})
|
||||
},
|
||||
openSupplier() {
|
||||
this.dialogFormVisible = true
|
||||
this.supplier1 = ''
|
||||
this.check10 = 0
|
||||
this.pageCurrent1 = 1
|
||||
this.pageSize1 = 10
|
||||
this.getTable(getSupplier, [this.check10, this.supplier1, this.pageCurrent1, this.pageSize1], ['tableData1', 'total1'])
|
||||
},
|
||||
searchSupplier() {
|
||||
this.supplier1 !== '' ? this.check10 = 1 : this.check10 = 0
|
||||
this.getTable(getSupplier, [this.check10, this.supplier1, this.pageCurrent1, this.pageSize1], ['tableData1', 'total1'])
|
||||
},
|
||||
selectSupplier(row) {
|
||||
if (this.param === 0) {
|
||||
this.supplierValue = row.供货商流水号
|
||||
} else if (this.param === 1) {
|
||||
this.supplierValue1 = row.供货商流水号
|
||||
}
|
||||
this.supplier1 = row.供货商
|
||||
},
|
||||
submitSupplier() {
|
||||
if (this.param === 0) {
|
||||
this.supplier = this.supplier1
|
||||
} else if (this.param === 1) {
|
||||
this.form.供货商 = this.supplier1
|
||||
}
|
||||
this.dialogFormVisible = false
|
||||
},
|
||||
cancel() { // 取消
|
||||
this.dialogFormVisible1 = false
|
||||
},
|
||||
searchMaterialVariety1() { // 物料品种
|
||||
this.MaterialVariety1 = []
|
||||
this.form.物料品种流水号 = ''
|
||||
this.getSelect(initMaterialVariety, ['物料品种', '物料品种流水号'], 'MaterialVariety1', this.form.物料类别流水号)
|
||||
},
|
||||
handleEdit(row) {
|
||||
this.supplierValue1 = ''
|
||||
this.MaterialCategory1 = []
|
||||
this.MaterialVariety1 = []
|
||||
this.supplierValue1 = row.供货商流水号
|
||||
this.getSelect(initMaterialCategory, ['物料类别', '物料类别流水号'], 'MaterialCategory1')
|
||||
this.getSelect(initMaterialVariety, ['物料品种', '物料品种流水号'], 'MaterialVariety1', row.物料类别流水号)
|
||||
this.editForm(row, 'form', [this.title = '编辑', this.dialogFormVisible1 = true])
|
||||
},
|
||||
submitEdit() {
|
||||
this.editTable(editData, [this.form.物料流水号, this.form.物料品种流水号, this.form.物料名称, this.form.物料全名, this.form.物料规格, this.form.物料型号, this.form.计量单位流水号, this.form.物料来源流水号, this.supplierValue1], 'form', function() {
|
||||
this.searchMaterial()
|
||||
this.dialogFormVisible1 = false
|
||||
})
|
||||
},
|
||||
handleAdd() {
|
||||
this.supplierValue1 = ''
|
||||
this.MaterialCategory1 = []
|
||||
this.MaterialVariety1 = []
|
||||
this.getSelect(initMaterialCategory, ['物料类别', '物料类别流水号'], 'MaterialCategory1')
|
||||
this.addForm('form', [this.dialogFormVisible1 = true, this.title = '新增物料申请'])
|
||||
},
|
||||
submitAdd() { // 提交增加
|
||||
this.addTable(addData, [this.form.物料品种流水号, this.form.物料名称, this.form.物料全名, this.form.物料规格, this.form.物料型号, this.form.计量单位流水号, this.form.物料来源流水号, this.form.GonghuoshangValue], 'form', function() {
|
||||
this.dialogFormVisible1 = false
|
||||
this.searchMaterial()
|
||||
})
|
||||
},
|
||||
handleDelete(row) { // 删除
|
||||
this.deleteRow(deleteData, row.物料流水号, function() {
|
||||
this.searchMaterial()
|
||||
})
|
||||
},
|
||||
CategoryMaintenance() {
|
||||
this.dialogFormVisible2 = true
|
||||
this.getData(searchCategory, 'tableData2')
|
||||
},
|
||||
selectMaterialCategory(row) {
|
||||
this.MaterialCategory2 = row.物料类别
|
||||
this.CategoryNumber = row.类别编号
|
||||
this.MaterialCategoryNum = row.物料类别流水号
|
||||
this.getData(searchVarieties, 'tableData3', row.物料类别流水号)
|
||||
},
|
||||
selectMaterialVariety(row) {
|
||||
this.MaterialVarietyNum = row.物料品种流水号
|
||||
this.VarietyNumber = row.品种编号
|
||||
this.MaterialVariety2 = row.物料品种
|
||||
this.Specifications1 = row.规格1
|
||||
this.Specifications2 = row.规格2
|
||||
},
|
||||
handleEdit1() {
|
||||
editCategory(this.MaterialCategoryNum, this.MaterialCategory2, this.CategoryNumber).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('编辑成功')
|
||||
this.getData(searchCategory, 'tableData2')
|
||||
this.tableData3 = []
|
||||
} else {
|
||||
this.$message.error('编辑失败')
|
||||
}
|
||||
})
|
||||
},
|
||||
handleAdd1() {
|
||||
addCategory(this.MaterialCategory2, this.CategoryNumber).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('增加成功')
|
||||
this.getData(searchCategory, 'tableData2')
|
||||
this.tableData3 = []
|
||||
} else {
|
||||
this.$message.error('增加失败')
|
||||
}
|
||||
})
|
||||
},
|
||||
handleDelete1(row) {
|
||||
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
deleteCategory(row.物料类别流水号).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('删除成功')
|
||||
this.getData(searchCategory, 'tableData2')
|
||||
this.tableData3 = []
|
||||
} else {
|
||||
this.$message.error('删除失败')
|
||||
}
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消删除'
|
||||
})
|
||||
})
|
||||
},
|
||||
handleEdit2() {
|
||||
editVariety(this.MaterialVarietyNum, this.MaterialCategoryNum, this.MaterialVariety2, this.VarietyNumber, this.Specifications1, this.Specifications2).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('编辑成功')
|
||||
this.getData(searchVarieties, 'tableData3', this.MaterialCategoryNum)
|
||||
} else {
|
||||
this.$message.error('编辑失败')
|
||||
}
|
||||
})
|
||||
},
|
||||
handleAdd2() {
|
||||
addVariety(this.MaterialCategoryNum, this.MaterialVariety2, this.VarietyNumber, this.Specifications1, this.Specifications2).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('增加成功')
|
||||
this.getData(searchVarieties, 'tableData3', this.MaterialCategoryNum)
|
||||
} else {
|
||||
this.$message.error('增加失败')
|
||||
}
|
||||
})
|
||||
},
|
||||
handleDelete2(row) {
|
||||
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
deleteVariety(row.物料品种流水号).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('删除成功')
|
||||
this.getData(searchVarieties, 'tableData3', this.MaterialCategoryNum)
|
||||
} else {
|
||||
this.$message.error('删除失败')
|
||||
}
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消删除'
|
||||
})
|
||||
})
|
||||
},
|
||||
handleSizeChange(val) {
|
||||
this.pageSize = val
|
||||
this.pageCurrent = 1
|
||||
this.searchMaterial()
|
||||
},
|
||||
handleCurrentChange(val) {
|
||||
this.pageCurrent = val
|
||||
this.searchMaterial()
|
||||
},
|
||||
handleSizeChange1(val) {
|
||||
this.pageSize1 = val
|
||||
this.pageCurrent1 = 1
|
||||
this.supplier1 !== '' ? this.check10 = 1 : this.check10 = 0
|
||||
this.getTable(getSupplier, [this.check10, this.supplier1, this.pageCurrent1, this.pageSize1], ['tableData1', 'total1'])
|
||||
},
|
||||
handleCurrentChange1(val) {
|
||||
this.pageCurrent1 = val
|
||||
this.supplier1 !== '' ? this.check10 = 1 : this.check10 = 0
|
||||
this.getTable(getSupplier, [this.check10, this.supplier1, this.pageCurrent1, this.pageSize1], ['tableData1', 'total1'])
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.el-select{
|
||||
width:190px
|
||||
}
|
||||
.el-input{
|
||||
width:190px
|
||||
}
|
||||
</style>
|
||||
@@ -113,7 +113,7 @@
|
||||
<!--clearable-->
|
||||
<!--@dblclick.native="param=0;openSupplier()"/>-->
|
||||
</el-col>
|
||||
<el-col style="width: 450px">
|
||||
<el-col style="width: 600px">
|
||||
<el-button
|
||||
type="success"
|
||||
icon="el-icon-search"
|
||||
@@ -131,6 +131,9 @@
|
||||
@click="CategoryMaintenance">维护物料类别
|
||||
</el-button>
|
||||
<el-button type="primary" style="margin-bottom: 3px;margin-top: 10px" icon="el-icon-circle-plus-outline" size="small" @click="open()">新增供货商</el-button>
|
||||
<el-badge :value="weishenhe" class="item">
|
||||
<el-button type="primary" plain size="small" @click="daishenhe()">采购部新增物料审核</el-button>
|
||||
</el-badge>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-card>
|
||||
@@ -480,6 +483,61 @@
|
||||
<el-button type="primary" @click="AddGonghuoshang('form3')">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible4" title="采购部新增物料审核" center style="min-height: 300px" width="700px">
|
||||
<el-form>
|
||||
<el-table
|
||||
:data="tableData5"
|
||||
style="width: 100%;margin-top: 3px"
|
||||
height="300"
|
||||
size="mini"
|
||||
highlight-current-row
|
||||
border
|
||||
stripe>
|
||||
<el-table-column align="center" label="物料名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="物料规格">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料规格 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="物料型号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="供货商">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.供货商 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" fixed="right" align="center" width="150">
|
||||
<template slot-scope="scope">
|
||||
<div style="display: inline-block">
|
||||
<el-button type="primary" plain size="small" @click="Tongguo(scope.row)">通过</el-button>
|
||||
</div>
|
||||
<div style="display: inline-block">
|
||||
<el-popover
|
||||
placement="bottom"
|
||||
width="400"
|
||||
trigger="click">
|
||||
<span>打回原因:</span>
|
||||
<el-input v-model="打回原因" placeholder="打回原因" size="small" clearable/>
|
||||
<el-button type="danger" size="small" @click="queren()">确认</el-button>
|
||||
<el-button slot="reference" type="danger" plain size="small" @click="Dahui(scope.row)">打回</el-button>
|
||||
</el-popover>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormVisible4=false">关闭</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -504,13 +562,22 @@ import {
|
||||
deleteCategory,
|
||||
editVariety,
|
||||
addVariety,
|
||||
deleteVariety
|
||||
deleteVariety,
|
||||
getMaterial,
|
||||
searchmateria5,
|
||||
Dahui,
|
||||
Tongguo
|
||||
} from '@/api/PurchasingCenter/MaterialManagement'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
打回原因: '',
|
||||
物料流水号: '',
|
||||
tableData5: [],
|
||||
dialogFormVisible4: false,
|
||||
weishenhe: 0,
|
||||
Gonghuoshang: [],
|
||||
Gonghuoshang2: [],
|
||||
GonghuoshangValue: '',
|
||||
@@ -605,11 +672,63 @@ export default {
|
||||
])
|
||||
},
|
||||
created() {
|
||||
this.getMaterial()
|
||||
this.fetchData()
|
||||
this.searchMaterialCategory()
|
||||
this.getGonghuoshang()
|
||||
this.searchMaterial()
|
||||
},
|
||||
methods: {
|
||||
// 通过
|
||||
Tongguo(row) {
|
||||
Tongguo(row.物料流水号).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.getMaterial()
|
||||
this.daishenhe()
|
||||
this.searchMaterial()
|
||||
this.$message.success('通过成功')
|
||||
} else { this.$message.error('通过失败') }
|
||||
})
|
||||
// this.$confirm('是否通过?', '提示', {
|
||||
// confirmButtonText: '确定',
|
||||
// cancelButtonText: '取消',
|
||||
// type: 'warning'
|
||||
// }).then(() => {
|
||||
// }).catch(() => {
|
||||
// this.$message({
|
||||
// type: 'info',
|
||||
// message: '已取消通过'
|
||||
// })
|
||||
// })
|
||||
},
|
||||
// 打回
|
||||
Dahui(row) {
|
||||
this.物料流水号 = row.物料流水号
|
||||
},
|
||||
// 打回确认
|
||||
queren() {
|
||||
Dahui(this.物料流水号, this.打回原因).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.getMaterial()
|
||||
this.daishenhe()
|
||||
this.$message.success('打回成功')
|
||||
} else { this.$message.error('打回失败') }
|
||||
})
|
||||
},
|
||||
// 查询采购部物料申请明细
|
||||
daishenhe() {
|
||||
this.tableData5 = []
|
||||
searchmateria5(0, 0, 0, 0, 0, 0, 0, 0, 1, 1000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0).then(response => {
|
||||
this.tableData5 = response.data.result
|
||||
this.dialogFormVisible4 = true
|
||||
})
|
||||
},
|
||||
// 查询待审核物料数量
|
||||
getMaterial() {
|
||||
getMaterial().then(response => {
|
||||
this.weishenhe = response.data[0].数量
|
||||
})
|
||||
},
|
||||
getGonghuoshang() { // 供货商初始化查询
|
||||
this.Gonghuoshang = []
|
||||
this.Gonghuoshang2 = []
|
||||
@@ -726,7 +845,7 @@ export default {
|
||||
this.editForm(row, 'form', [this.title = '编辑', this.dialogFormVisible1 = true])
|
||||
},
|
||||
submitEdit() {
|
||||
this.editTable(editData, [this.form.物料流水号, this.form.物料品种流水号, this.form.物料名称, this.form.物料全名, this.form.物料规格, this.form.物料型号, this.form.计量单位流水号, this.form.物料来源流水号, this.supplierValue1], 'form', function() {
|
||||
this.editTable(editData, [this.form.物料流水号, this.form.物料品种流水号, this.form.物料名称, this.form.物料全名, this.form.物料规格, this.form.物料型号, this.form.计量单位流水号, this.form.物料来源流水号, this.form.GonghuoshangValue], 'form', function() {
|
||||
this.searchMaterial()
|
||||
this.dialogFormVisible1 = false
|
||||
})
|
||||
|
||||
@@ -168,7 +168,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="单件重量" align="center" width="150px">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.单件重量" step="1" size="mini" style="width:120px" @change="save(scope.$index, scope.row)"/>
|
||||
<el-input-number v-model="scope.row.单件重量" :step="1" :min="0" size="mini" style="width:120px" @change="save(scope.$index, scope.row)"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="总重量" align="center" prop="总重量">
|
||||
@@ -233,7 +233,7 @@
|
||||
type="primary"
|
||||
size="small"
|
||||
icon="el-icon-check"
|
||||
@click="submitAddArrivalOrder">确定</el-button>
|
||||
@click="submitAddArrivalOrder">保存</el-button>
|
||||
<el-button
|
||||
v-show="title==='编辑到货单'"
|
||||
type="primary"
|
||||
@@ -246,18 +246,24 @@
|
||||
<el-dialog v-el-drag-dialog :title="title1" :visible.sync="dialogVisible1" center style="min-height: 200px" width="430px">
|
||||
<el-form ref="form1" :model="form1" :rules="rules1" label-position="right" label-width="120px">
|
||||
<el-row>
|
||||
<el-form-item label="材料" prop="材料">
|
||||
<el-input v-model="form1.材料" size="small"/>
|
||||
<el-form-item v-show="title1==='添加到货明细'" label="材料" prop="CailiaoValue">
|
||||
<el-select v-model="form1.CailiaoValue" placeholder="材料" size="small" filterable>
|
||||
<el-option
|
||||
v-for="item in Cailiao"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-form-item label="数量" prop="数量">
|
||||
<el-input-number v-model="form1.数量" :precision="2" :step="1" size="medium" @change="Calculation"/>
|
||||
<el-input-number v-model="form1.数量" :precision="2" :step="1" :min="0" size="medium" @change="Calculation"/>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-form-item label="单价" prop="单价">
|
||||
<el-input-number v-model="form1.单价" :precision="2" :step="1" size="medium" @change="Calculation"/>
|
||||
<el-input-number v-model="form1.单价" :precision="2" :step="1" :min="0" size="medium" @change="Calculation"/>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
@@ -272,12 +278,20 @@
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button
|
||||
v-show="title1==='添加到货明细'"
|
||||
type="warning"
|
||||
size="small"
|
||||
plain
|
||||
icon="el-icon-check"
|
||||
@click="submitAddArrivalOrderMX">保存</el-button>
|
||||
<el-button
|
||||
v-show="title1==='添加到货明细'"
|
||||
type="primary"
|
||||
plain
|
||||
size="small"
|
||||
icon="el-icon-check"
|
||||
@click="submitAddArrivalOrderMX">确定</el-button>
|
||||
@click="submitAddArrivalOrderMX1">继续添加</el-button>
|
||||
<el-button
|
||||
v-show="title1==='编辑到货明细'"
|
||||
type="primary"
|
||||
@@ -294,6 +308,8 @@
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="查询采购计划单" placement="top">
|
||||
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent2=1;pageSize2=10;total2=0;searchTable2()">查询</el-button>
|
||||
</el-tooltip>
|
||||
<span style="font-size: 15px;margin-left: 10px;font-weight: bold">材料:</span><span>{{ 材料111 }}</span>
|
||||
<span style="font-size: 15px;margin-left: 10px;font-weight: bold">材料数量:</span><span>{{ 材料数量 }}</span>
|
||||
</div>
|
||||
<el-table v-loading="" :data="tableData2" border stripe style="max-height: 460px;" height="230px" size="mini" highlight-current-row @row-click="searchTable3">
|
||||
<el-table-column label="采购计划单号" align="center">
|
||||
@@ -384,21 +400,28 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { searchPurchaseOrder, searchMateriel, addMateriel, searchArriveOrder, addPurchaseOrder, editPurchaseOrder, deletePurchaseOrder, saveWeight, searchTable5, searchSupplier, deleteArrivalMX, EditArrivalOrderMX, AddArrivalOrderMX, deleteMateriel, searchTable6 } from '@/api/WorkshopProcurement/NewArrivalList.js'
|
||||
import { searchCailiao, searchPurchaseOrder, searchMateriel, addMateriel, searchArriveOrder, addPurchaseOrder, editPurchaseOrder, deletePurchaseOrder, saveWeight, searchTable5, searchSupplier, deleteArrivalMX, EditArrivalOrderMX, AddArrivalOrderMX, deleteMateriel, searchTable6 } from '@/api/WorkshopProcurement/NewArrivalList.js'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
Cailiao: [],
|
||||
purchasingOrder: '',
|
||||
ArrivalOrderNumber: '',
|
||||
ArrivalOrderMXNumber: '',
|
||||
supplierName0: '',
|
||||
arrest: [],
|
||||
check: 0,
|
||||
材料111: '',
|
||||
Name: '',
|
||||
单价: '',
|
||||
数量: '',
|
||||
SUM: 0,
|
||||
ALLMoney: '',
|
||||
材料数量: '',
|
||||
材料名称: '',
|
||||
未绑定数量: '',
|
||||
tableData2: [],
|
||||
total2: 0,
|
||||
pageCurrent2: 1,
|
||||
@@ -413,12 +436,14 @@ export default {
|
||||
tableData5: [],
|
||||
到货单流水号: '',
|
||||
dateRange: '',
|
||||
中间变量: '',
|
||||
form: {
|
||||
备注: '',
|
||||
日期: '',
|
||||
supplierNameValue: ''
|
||||
},
|
||||
form1: {
|
||||
CailiaoValue: '',
|
||||
材料: '',
|
||||
数量: '',
|
||||
单位: 'KG',
|
||||
@@ -437,7 +462,7 @@ export default {
|
||||
日期: [{ required: true, message: '请选择日期' }]
|
||||
},
|
||||
rules1: {
|
||||
材料: [{ required: true, message: '请填写材料' }],
|
||||
CailiaoValue: [{ required: true, message: '请选择材料' }],
|
||||
数量: [{ required: true, message: '请填写数量' }],
|
||||
单位: [{ required: true, message: '请填写单位' }],
|
||||
单价: [{ required: true, message: '请填写单价' }]
|
||||
@@ -459,10 +484,21 @@ export default {
|
||||
this.searchTable4()
|
||||
},
|
||||
methods: {
|
||||
searchCailiao() {
|
||||
this.Cailiao = []
|
||||
searchCailiao(this.供应商111).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.Cailiao.push({
|
||||
value: response.data[i].材料,
|
||||
label: response.data[i].材料
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
searchTable2() { // 查询采购单列表
|
||||
this.purchasingOrder ? this.check3 = 1 : this.check3 = 0
|
||||
this.supplierName0 ? this.check4 = 1 : this.check4 = 0
|
||||
searchPurchaseOrder(this.pageCurrent2, this.pageSize2, this.check3, this.purchasingOrder, this.check4, this.supplierName0).then(response => {
|
||||
searchPurchaseOrder(this.pageCurrent2, this.pageSize2, this.check3, this.purchasingOrder, this.check4, this.supplierName0, this.材料111).then(response => {
|
||||
this.tableData2 = response.data.rows
|
||||
this.total2 = response.data.total
|
||||
})
|
||||
@@ -477,7 +513,7 @@ export default {
|
||||
},
|
||||
searchTable3(row) { // 查询采购计划明细
|
||||
this.采购计划流水号 = row.采购计划流水号
|
||||
searchMateriel(this.采购计划流水号).then(response => {
|
||||
searchMateriel(this.采购计划流水号, this.材料111).then(response => {
|
||||
this.tableData3 = response.data
|
||||
})
|
||||
},
|
||||
@@ -529,7 +565,12 @@ export default {
|
||||
const { columns, data } = param
|
||||
const sums = []
|
||||
columns.forEach((column, index) => {
|
||||
if (index === 5) {
|
||||
if (index === 3) {
|
||||
sums[index] = '未绑定数量:'
|
||||
return
|
||||
} else if (index === 4) {
|
||||
sums[index] = this.未绑定数量
|
||||
} if (index === 5) {
|
||||
sums[index] = '总重量:'
|
||||
return
|
||||
} else if (index === 6) {
|
||||
@@ -579,19 +620,35 @@ export default {
|
||||
})
|
||||
},
|
||||
save(index, row) {
|
||||
this.SUM = 0
|
||||
this.allWeight = parseInt(row.批次数量 * row.单件重量 * 100) / 100
|
||||
this.ALLMoney = parseInt(this.allWeight * this.单价 * 100) / 100
|
||||
saveWeight(row.采购计划明细流水号, row.单件重量, this.allWeight, this.ALLMoney).then(response => {
|
||||
console.log(response)
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('录入成功')
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
this.tableData6 = response.data
|
||||
})
|
||||
} else {
|
||||
this.$message.error('录入失败')
|
||||
}
|
||||
})
|
||||
for (let i = 0; i < this.tableData6.length; i++) {
|
||||
this.SUM += parseFloat(this.tableData6[i].单件重量) * parseFloat(this.tableData6[i].批次数量)
|
||||
}
|
||||
if (this.数量 - this.SUM < 0) {
|
||||
this.$message.warning('总重量已超出上限')
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
this.tableData6 = response.data
|
||||
if (response.data.length !== 0) {
|
||||
this.未绑定数量 = response.data[0].未绑定数量
|
||||
}
|
||||
})
|
||||
} else {
|
||||
saveWeight(row.采购计划明细流水号, row.单件重量, this.allWeight, this.ALLMoney).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('录入成功')
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
this.tableData6 = response.data
|
||||
if (response.data.length !== 0) {
|
||||
this.未绑定数量 = response.data[0].未绑定数量
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.error('录入失败')
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
Calculation() {
|
||||
this.form1.金额 = this.form1.单价 * this.form1.数量
|
||||
@@ -692,6 +749,7 @@ export default {
|
||||
searchTable5(row) {
|
||||
this.tableData6 = []
|
||||
this.到货单流水号 = row.到货单流水号
|
||||
this.ArrivalOrderNumber = row.到货单流水号
|
||||
searchTable5(this.到货单流水号).then(response => {
|
||||
this.tableData5 = response.data
|
||||
})
|
||||
@@ -700,8 +758,10 @@ export default {
|
||||
if (this.$refs['form1'] !== undefined) {
|
||||
this.$refs['form1'].resetFields()
|
||||
}
|
||||
this.供应商111 = row.供应商流水号
|
||||
this.searchCailiao()
|
||||
this.title1 = '添加到货明细'
|
||||
this.form1.材料 = ''
|
||||
this.form1.CailiaoValue = ''
|
||||
this.form1.数量 = ''
|
||||
this.form1.单价 = ''
|
||||
this.form1.金额 = ''
|
||||
@@ -709,29 +769,42 @@ export default {
|
||||
this.dialogVisible1 = true
|
||||
},
|
||||
submitAddArrivalOrderMX() {
|
||||
this.form1.金额 = this.form1.数量 * this.form1.单价
|
||||
this.$refs['form1'].validate((valid) => {
|
||||
if (valid) {
|
||||
AddArrivalOrderMX(this.ArrivalOrderNumber, this.form1.材料, this.form1.数量, this.form1.单位, this.form1.单价, this.form1.金额).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('新增到货材料成功')
|
||||
searchTable5(this.ArrivalOrderNumber).then(response => {
|
||||
this.tableData5 = response.data
|
||||
})
|
||||
this.dialogVisible1 = false
|
||||
} else { this.$message.error('新建到货单失败') }
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
if (this.form1.数量 > 0) {
|
||||
this.form1.金额 = this.form1.数量 * this.form1.单价
|
||||
this.$refs['form1'].validate((valid) => {
|
||||
if (valid) {
|
||||
AddArrivalOrderMX(this.ArrivalOrderNumber, this.form1.CailiaoValue, this.form1.数量, this.form1.单位, this.form1.单价, this.form1.金额).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('新增到货材料成功')
|
||||
searchTable5(this.ArrivalOrderNumber).then(response => {
|
||||
this.tableData5 = response.data
|
||||
})
|
||||
// this.dialogVisible1 = false
|
||||
} else { this.$message.error('新建到货单失败') }
|
||||
})
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.error('数量不能为0')
|
||||
}
|
||||
},
|
||||
submitAddArrivalOrderMX1() {
|
||||
this.searchCailiao()
|
||||
this.form1.CailiaoValue = ''
|
||||
this.form1.数量 = ''
|
||||
this.form1.单价 = ''
|
||||
this.form1.金额 = ''
|
||||
},
|
||||
editArrivalMX(row) {
|
||||
if (this.$refs['form1'] !== undefined) {
|
||||
this.$refs['form1'].resetFields()
|
||||
}
|
||||
this.供应商111 = row.供应商流水号
|
||||
this.searchCailiao()
|
||||
this.title1 = '编辑到货明细'
|
||||
this.form1.材料 = row.材料
|
||||
// this.form1.CailiaoValue = row.材料
|
||||
this.form1.数量 = row.数量
|
||||
this.form1.单位 = row.单位
|
||||
this.form1.单价 = row.单价
|
||||
@@ -740,10 +813,11 @@ export default {
|
||||
this.dialogVisible1 = true
|
||||
},
|
||||
submitEditArrivalOrderMX() {
|
||||
this.form1.CailiaoValue = '1'
|
||||
this.form1.金额 = this.form1.数量 * this.form1.单价
|
||||
this.$refs['form1'].validate((valid) => {
|
||||
if (valid) {
|
||||
EditArrivalOrderMX(this.ArrivalOrderMXNumber, this.form1.材料, this.form1.数量, this.form1.单位, this.form1.单价, this.form1.金额).then(response => {
|
||||
EditArrivalOrderMX(this.ArrivalOrderMXNumber, this.form1.数量, this.form1.单位, this.form1.单价, this.form1.金额).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('编辑到货材料成功')
|
||||
searchTable5(this.ArrivalOrderNumber).then(response => {
|
||||
@@ -781,19 +855,26 @@ export default {
|
||||
searchTable6(row) {
|
||||
this.ArrivalOrderMXNumber = row.到货单明细流水号
|
||||
this.单价 = row.单价
|
||||
this.数量 = row.数量
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
this.tableData6 = response.data
|
||||
if (response.data.length !== 0) {
|
||||
this.中间变量 = response.data[0].单件重量
|
||||
this.未绑定数量 = response.data[0].未绑定数量
|
||||
}
|
||||
})
|
||||
},
|
||||
addArrivalCL(row) {
|
||||
this.材料111 = row.材料
|
||||
this.材料数量 = row.数量
|
||||
this.supplierName0 = row.供应商流水号
|
||||
this.ArrivalOrderMXNumber = row.到货单明细流水号
|
||||
this.tableData3 = []
|
||||
this.dialogVisible2 = true
|
||||
this.searchTable2()
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
this.arrest = val
|
||||
console.log(val)
|
||||
},
|
||||
// 选入
|
||||
addMateriel() {
|
||||
@@ -811,12 +892,14 @@ export default {
|
||||
addMateriel(this.ArrivalOrderMXNumber, this.工艺计划流水号组, this.采购计划明细流水号组).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('关联成功')
|
||||
this.dialogVisible2 = false
|
||||
searchMateriel(this.采购计划流水号).then(response => {
|
||||
this.tableData3 = response.data
|
||||
})
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
this.tableData6 = response.data
|
||||
if (response.data.length !== 0) {
|
||||
this.未绑定数量 = response.data[0].未绑定数量
|
||||
}
|
||||
})
|
||||
} else { this.$message.error('关联失败') }
|
||||
})
|
||||
@@ -828,12 +911,14 @@ export default {
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
console.log(row)
|
||||
deleteMateriel(row.到货单明细绑定流水号, row.采购计划明细流水号).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('取消成功')
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
this.tableData6 = response.data
|
||||
if (response.data.length !== 0) {
|
||||
this.未绑定数量 = response.data[0].未绑定数量
|
||||
}
|
||||
})
|
||||
} else { this.$message.error('取消失败') }
|
||||
})
|
||||
|
||||
@@ -1,24 +1,41 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<span>发票号:</span>
|
||||
<el-input v-model="invoiceNum" placeholder="发票号" size="small" style="margin: 3px 0;width: 130px" clearable/>
|
||||
<span style="margin-left: 10px">供应商:</span>
|
||||
<el-input v-model="supplierName0" placeholder="供应商" size="small" style="width:130px" clearable/>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="查询外购备料发票信息" placement="top">
|
||||
<el-button
|
||||
type="success"
|
||||
<el-row>
|
||||
<span>发票号:</span>
|
||||
<el-input v-model="invoiceNum" placeholder="发票号" size="small" style="margin: 3px 0;width: 180px" clearable/>
|
||||
<span>供应商:</span>
|
||||
<el-input v-show="false" v-model="supplierName0" placeholder="供应商" size="small" style="width:130px" clearable @focus="fetchData"/>
|
||||
<el-select v-model="gongyingshangValue" placeholder="供应商" style="width: 180px" size="small" filterable clearable @change="searchTable1">
|
||||
<el-option
|
||||
v-for="item in gongyingshang"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span v-show="false" class="demonstration">时间段:</span>
|
||||
<el-date-picker
|
||||
v-show="false"
|
||||
v-model="startTime"
|
||||
value-format="yyyy-MM-dd"
|
||||
size="small"
|
||||
icon="el-icon-search"
|
||||
style="margin-left: 10px"
|
||||
@click="total1=0;pageCurrent1=1;pageSize1=10;searchTable1()">查询</el-button>
|
||||
</el-tooltip>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
icon="el-icon-circle-plus-outline"
|
||||
style="margin-left: 10px"
|
||||
@click="addTable1()">新增发票</el-button>
|
||||
style="width: 180px"
|
||||
type="date"
|
||||
placeholder="选择日期"/>
|
||||
<span v-show="false" class="demonstration">~</span>
|
||||
<el-date-picker
|
||||
v-show="false"
|
||||
v-model="endTime"
|
||||
value-format="yyyy-MM-dd"
|
||||
size="small"
|
||||
style="width: 180px"
|
||||
type="date"
|
||||
placeholder="选择日期"/>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="查询外购备料发票信息" placement="top">
|
||||
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="total1=0;pageCurrent1=1;pageSize1=10;searchTable1()">查询</el-button>
|
||||
</el-tooltip>
|
||||
<el-button type="primary" size="small" icon="el-icon-circle-plus-outline" style="margin-left: 10px" @click="addTable1()">新增发票</el-button>
|
||||
</el-row>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-table
|
||||
@@ -97,7 +114,7 @@
|
||||
{{ scope.row.备注 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="操作" fixed="right" width="250px">
|
||||
<el-table-column align="center" label="操作" fixed="right" width="300px">
|
||||
<template slot-scope="scope">
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="关联到货单" placement="top">
|
||||
<div style="display: inline-block">
|
||||
@@ -109,6 +126,7 @@
|
||||
@click="aboutArrival(scope.row)">关联到货单</el-button>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left:10px" @click="downloadExcel(scope.row)">导出</el-button>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="编辑" placement="top">
|
||||
<div style="display: inline-block">
|
||||
<el-button
|
||||
@@ -234,12 +252,19 @@
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>import { searchInvoice, addInvoice, editInvoice, deleteInvoice, searchSupplier, searchInvoiceDetail, searchArriveOrder, addMateriel, deleteInvoiceMX } from '@/api/WorkshopProcurement/OutsourcingMaterialsInvoice'
|
||||
<script>
|
||||
import { searchInvoice, addInvoice, editInvoice, deleteInvoice, searchSupplier, searchInvoiceDetail, searchArriveOrder, addMateriel, deleteInvoiceMX, getGongyingshang } from '@/api/WorkshopProcurement/OutsourcingMaterialsInvoice'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { ExcelDownLoad } from '@/utils/request'
|
||||
|
||||
export default {
|
||||
name: '', // 发票交接单
|
||||
data() {
|
||||
return {
|
||||
gongyingshangValue: '',
|
||||
gongyingshang: [],
|
||||
startTime: '',
|
||||
endTime: '',
|
||||
contractNumValue: '',
|
||||
supplierName0: '',
|
||||
contractNums: [],
|
||||
@@ -305,11 +330,23 @@ export default {
|
||||
})
|
||||
}
|
||||
})
|
||||
this.gongyingshangValue = ''
|
||||
this.gongyingshang = []
|
||||
getGongyingshang().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.gongyingshang.push({
|
||||
label: response.data[i].供应商名称,
|
||||
value: response.data[i].供应商
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
searchTable1() {
|
||||
this.invoiceNum ? this.check1 = 1 : this.check1 = 0
|
||||
this.supplierName0 ? this.check2 = 1 : this.check2 = 0
|
||||
searchInvoice(this.pageCurrent1, this.pageSize1, this.check1, this.invoiceNum, this.check2, this.supplierName0).then(response => {
|
||||
this.gongyingshangValue ? this.check3 = 1 : this.check3 = 0
|
||||
this.startTime && this.endTime ? this.check4 = 1 : this.check4 = 0
|
||||
searchInvoice(this.pageCurrent1, this.pageSize1, this.check1, this.invoiceNum, this.check2, this.supplierName0, this.check3, this.gongyingshangValue, this.check4, this.startTime, this.endTime).then(response => {
|
||||
for (let j = 0; j < response.data.rows.length; j++) {
|
||||
response.data.rows[j].开票金额 = parseInt(response.data.rows[j].开票金额 * 100) / 100
|
||||
if (response.data.rows[j].开票时间 !== null) {
|
||||
@@ -438,7 +475,6 @@ export default {
|
||||
})
|
||||
},
|
||||
deleteTable1(row) {
|
||||
console.log(row)
|
||||
this.$confirm('确认删除吗?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
@@ -506,9 +542,56 @@ export default {
|
||||
message: '已取消操作'
|
||||
})
|
||||
})
|
||||
},
|
||||
downloadExcel(row) {
|
||||
const _ExcelDownLoad = ExcelDownLoad
|
||||
this.download(`${_ExcelDownLoad}?Fapiao=${row.发票流水号}&name=${row.供应商名称}`)
|
||||
},
|
||||
/**
|
||||
* 下载
|
||||
* @param {String} url 目标文件地址
|
||||
* @param {String} filename 想要保存的文件名称
|
||||
*/
|
||||
download(url) {
|
||||
this.getBlob(url, function(blob, filename) {
|
||||
saveAs(blob, filename)
|
||||
})
|
||||
},
|
||||
getBlob(url, cb) {
|
||||
var xhr = new XMLHttpRequest()
|
||||
xhr.open('GET', url, true)
|
||||
xhr.responseType = 'blob'
|
||||
xhr.onload = function() {
|
||||
if (xhr.status === 200) {
|
||||
const name = xhr.getResponseHeader('content-disposition').split('=')[1]
|
||||
cb(xhr.response, name)
|
||||
}
|
||||
}
|
||||
xhr.send()
|
||||
}
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 保存
|
||||
* @param {Blob} blob
|
||||
* @param {String} filename 想要保存的文件名称
|
||||
*/
|
||||
function saveAs(blob, filename = '下载文件.xls') {
|
||||
if (window.navigator.msSaveOrOpenBlob) {
|
||||
navigator.msSaveBlob(blob, filename)
|
||||
} else {
|
||||
var link = document.createElement('a')
|
||||
var body = document.querySelector('body')
|
||||
link.href = window.URL.createObjectURL(blob)
|
||||
link.download = filename
|
||||
// fix Firefox
|
||||
link.style.display = 'none'
|
||||
body.appendChild(link)
|
||||
link.click()
|
||||
body.removeChild(link)
|
||||
window.URL.revokeObjectURL(link.href)
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
@@ -1,24 +1,26 @@
|
||||
<template>
|
||||
<el-menu class="navbar" mode="horizontal" style="background: rgb(87,177,253)!important;">
|
||||
<hamburger :toggle-click="toggleSideBar" :is-active="sidebar.opened" class="hamburger-container"/>
|
||||
<breadcrumb />
|
||||
<el-dropdown class="avatar-container" trigger="click">
|
||||
<div class="avatar-wrapper">
|
||||
<img :src="require('@/assets/img/user.jpg')" class="user-avatar">
|
||||
<i class="el-icon-caret-bottom"/>
|
||||
</div>
|
||||
<el-dropdown-menu slot="dropdown" class="user-dropdown">
|
||||
<router-link class="inlineBlock" to="/">
|
||||
<el-dropdown-item>
|
||||
主页
|
||||
<div>
|
||||
<el-menu class="navbar" mode="horizontal" style="background: rgb(87,177,253)!important;">
|
||||
<hamburger :toggle-click="toggleSideBar" :is-active="sidebar.opened" class="hamburger-container"/>
|
||||
<breadcrumb />
|
||||
<el-dropdown class="avatar-container" trigger="click">
|
||||
<div class="avatar-wrapper">
|
||||
<img :src="require('@/assets/img/user.jpg')" class="user-avatar">
|
||||
<i class="el-icon-caret-bottom"/>
|
||||
</div>
|
||||
<el-dropdown-menu slot="dropdown" class="user-dropdown">
|
||||
<router-link class="inlineBlock" to="/">
|
||||
<el-dropdown-item>
|
||||
主页
|
||||
</el-dropdown-item>
|
||||
</router-link>
|
||||
<el-dropdown-item divided @click.native="logout">
|
||||
<span style="display:block;">退出</span>
|
||||
</el-dropdown-item>
|
||||
</router-link>
|
||||
<el-dropdown-item divided @click.native="logout">
|
||||
<span style="display:block;">退出</span>
|
||||
</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
</el-menu>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
</el-menu>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
@@ -26,6 +28,7 @@ import { mapGetters } from 'vuex'
|
||||
import Breadcrumb from '@/components/Breadcrumb'
|
||||
import Hamburger from '@/components/Hamburger'
|
||||
import { searchTable1 } from '@/api/PurchasingCenter/PurchaseContractApproval'
|
||||
import { getMaterial, getMaterial_NOTES, setChakan } from '@/api/PurchasingCenter/MaterialManagement'
|
||||
import { initApproval, initApprovalOffline } from '@/api/PurchasingCenter/FundApproval'
|
||||
import { searchTable1 as searchTableInvoice } from '@/api/PurchasingCenter/InvoiceSettlementApprove'
|
||||
export default {
|
||||
@@ -47,6 +50,7 @@ export default {
|
||||
'avatar',
|
||||
'name',
|
||||
'id',
|
||||
'token',
|
||||
'token'
|
||||
])
|
||||
},
|
||||
@@ -54,12 +58,52 @@ export default {
|
||||
if (this.id.toString() === '3') {
|
||||
this.checkApproval()
|
||||
this.timer = setInterval(this.checkApproval, 1000 * 60 * 5)
|
||||
} else if (this.token.toString() === '11' || this.token.toString() === '12') {
|
||||
this.comfirmMaterial()
|
||||
this.timer = setInterval(this.comfirmMaterial, 1000 * 60 * 5)
|
||||
} else if (this.token.toString() === '2' || this.token.toString() === '3') {
|
||||
this.comfirmMaterial_CG()
|
||||
this.timer = setInterval(this.comfirmMaterial_CG, 1000 * 60 * 5)
|
||||
}
|
||||
},
|
||||
beforeDestroy() {
|
||||
clearInterval(this.timer)
|
||||
},
|
||||
methods: {
|
||||
comfirmMaterial_CG() {
|
||||
getMaterial_NOTES().then(res => {
|
||||
if (res.data.length) {
|
||||
this.noticeContract = null
|
||||
this.noticeContract = this.$notify.success({
|
||||
title: '提示',
|
||||
message: '有新采购物料审批结果,点击查看',
|
||||
onClick: () => {
|
||||
setChakan().then(res => {
|
||||
this.$router.push({ path: '/PurchasingCenter/MaterialMProcure' })
|
||||
setTimeout(this.noticeContract.close(), 1000)
|
||||
})
|
||||
},
|
||||
duration: 1000 * 60
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
comfirmMaterial() {
|
||||
getMaterial().then(res => {
|
||||
if (res.data.length) {
|
||||
this.noticeContract = null
|
||||
this.noticeContract = this.$notify.success({
|
||||
title: '提示',
|
||||
message: '您有采购物料申请待审批,请及时处理,点击查看',
|
||||
onClick: () => {
|
||||
this.$router.push({ path: '/PurchasingCenter/MaterialManagement' })
|
||||
setTimeout(this.noticeContract.close(), 1000)
|
||||
},
|
||||
duration: 1000 * 60
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
checkApproval() {
|
||||
searchTable1(1, 999, 0, null, null, 0, 0, 0, 0, 0, 0).then(res => {
|
||||
if (res.data.total) {
|
||||
@@ -166,4 +210,3 @@ export default {
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user