更新
This commit is contained in:
71
src/api/Inventory/PurchaseOutRecord.js
Normal file
71
src/api/Inventory/PurchaseOutRecord.js
Normal file
@@ -0,0 +1,71 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 初始化项目
|
||||
export function initProject() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: 'PDM_项目名称_查询数据_按时间排序'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 机床查询
|
||||
export function searchMachine(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: 'PDM_机床名称_查询数据',
|
||||
param: '项目流水号_check=1&项目流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 分组查询
|
||||
export function searchGroup(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: 'PDM_组件名称_查询数据',
|
||||
param: '机床流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询记录
|
||||
export function searchRecord(project, machine, group, name, spec, model) {
|
||||
let execName = `select PDM_机床名称.项目流水号,PDM_组件名称.机床流水号,出库记录.* from(select 组件流水号,名称,物料规格 as 规格,物料型号 as 图号或型号,出库数量,备注 as 领料人,滞货出库时间 as 出库时间 from 车间装配管理_领料单_领料单明细 where 滞货出库时间 is not null
|
||||
union
|
||||
select 组件流水号,物料名称 as 名称,物料规格 as 规格,物料型号 as 图号或型号,出库数量,备注 as 领料人,出库时间 from 库存管理_基础表_离线采购件出库
|
||||
inner join 库存管理_物料主文件_基本 on 库存管理_物料主文件_基本.物料流水号 = 库存管理_基础表_离线采购件出库.物料流水号
|
||||
union
|
||||
select 组件流水号,物料名称 as 名称,物料规格 as 规格,物料型号 as 图号或型号,出库数量,库存管理_基础表_外购件出库.备注 as 领料人,出库时间 from 库存管理_基础表_外购件出库
|
||||
inner join 采购管理_采购合同明细_采购部 on 采购管理_采购合同明细_采购部.采购合同明细流水号 = 库存管理_基础表_外购件出库.采购合同明细流水号
|
||||
left join MRP_计划订单_组件零件清单 on MRP_计划订单_组件零件清单.组件零件流水号 = 采购管理_采购合同明细_采购部.组件零件流水号
|
||||
inner join MRP_计划订单_机床组件清单 on MRP_计划订单_机床组件清单.机床组件流水号 = MRP_计划订单_组件零件清单.机床组件流水号
|
||||
inner join 库存管理_物料主文件_基本 on 库存管理_物料主文件_基本.物料流水号 = MRP_计划订单_组件零件清单.物料流水号
|
||||
union
|
||||
select 组件流水号,'' as 规格,零件图号 as 图号或型号,零件名称 as 名称,出库数量,库存管理_基础表_外购件出库.备注 as 领料人,出库时间 from 库存管理_基础表_外购件出库
|
||||
inner join 采购管理_采购合同明细_采购部 on 采购管理_采购合同明细_采购部.采购合同明细流水号 = 库存管理_基础表_外购件出库.采购合同明细流水号
|
||||
left join MRP_计划订单_组件零件清单_基本件_采购 on MRP_计划订单_组件零件清单_基本件_采购.组件零件基本件流水号 = 采购管理_采购合同明细_采购部.组件零件基本件流水号
|
||||
inner join PDM_零件明细表_基本件 on PDM_零件明细表_基本件.基本件流水号 = MRP_计划订单_组件零件清单_基本件_采购.基本件流水号
|
||||
) as 出库记录 inner join PDM_组件名称 on PDM_组件名称.组件流水号 = 出库记录.组件流水号 inner join PDM_机床名称 on PDM_机床名称.机床流水号 = PDM_组件名称.机床流水号
|
||||
where PDM_组件名称.组件流水号 is not null`
|
||||
if (project) { execName += ` and PDM_机床名称.项目流水号 = ${project} ` }
|
||||
if (machine) { execName += ` and PDM_组件名称.机床流水号 = ${machine} ` }
|
||||
if (group) { execName += ` and PDM_组件名称.组件流水号 = ${group} ` }
|
||||
if (name) { execName += ` and 出库记录.名称 like '%${name}%' ` }
|
||||
if (spec) { execName += ` and 出库记录.规格 like '%${spec}%' ` }
|
||||
if (model) { execName += ` and 出库记录.图号或型号 like '%${model}%' ` }
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: execName
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -71,3 +71,15 @@ export function searchtable2(num) {
|
||||
}
|
||||
})
|
||||
}
|
||||
// 在制零件工艺修改
|
||||
export function returnEdit(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_在制零件工艺调整_修改工艺',
|
||||
param: '工艺计划流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
481
src/api/ManufacturingCenter/ProcessQuotaEstablishment.js
Normal file
481
src/api/ManufacturingCenter/ProcessQuotaEstablishment.js
Normal file
@@ -0,0 +1,481 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 典艺查询<高精原有数据>
|
||||
export function searchProcess11(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_原零件工艺查询_MESWORK',
|
||||
param: '零件图号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 典艺查询<高精原有数据>
|
||||
export function numChange(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_原零件工艺明细查询_MESWORK',
|
||||
param: '典艺流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 保存主表工艺
|
||||
export function selectRequest(num0, num1, num2, num3, request0) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_修改数据_根据工序流水号和工艺计划流水号',
|
||||
param: '工序流水号=' + num0 + '&工艺计划流水号=' + num1 + '&工艺编号=' + num2 + '&工艺顺序=' + num3 + '&工艺要求=' + request0
|
||||
}
|
||||
})
|
||||
}
|
||||
// 初始化 工艺员A
|
||||
export function initCraftmen() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
|
||||
param: '考核部门编号=20'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询 未编制 零件号
|
||||
export function getPartnames1(num1, num2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工艺计划_编制工艺_按人员查',
|
||||
param: '工艺人员编号=' + num1 + '&零件图号=' + num2
|
||||
}
|
||||
})
|
||||
}
|
||||
// 初始化 已编制 零件号
|
||||
export function getPartnames2(num1, num2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工艺计划_查询已完成工艺制定零件',
|
||||
param: '工艺人员编号=' + num1 + '&零件图号=' + num2
|
||||
}
|
||||
})
|
||||
}
|
||||
// 零件详细信息
|
||||
export function detailInfo(serialNum) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工艺计划_查已投产零件信息',
|
||||
param: '工艺计划流水号=' + serialNum + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 初始化材质
|
||||
export function getMaterial(pageCurrent, pageSize) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_材质表_查询数据',
|
||||
Pagination: pageCurrent + '&' + pageSize
|
||||
}
|
||||
})
|
||||
}
|
||||
// 根据材质名称查材质
|
||||
export function searchMaterial(pageCurrent, pageSize, name) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_材质表_查询数据_根据材料名称',
|
||||
param: '材料名称=' + name,
|
||||
Pagination: pageCurrent + '&' + pageSize
|
||||
}
|
||||
})
|
||||
}
|
||||
// 典型工艺选择零件分类A
|
||||
export function typicalProcess() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_典型工艺名称_分类_查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 典型工艺选择零件名称、工艺号、备注
|
||||
export function FcK(serialNum) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_典型工艺名称_查询数据_查典型工艺名称',
|
||||
param: '典型工艺名称分类流水号=' + serialNum + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 典型工艺查询
|
||||
export function searchProcess(check1, a, check2, b, check3, c) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_典型工艺名称_查询数据_综合查询',
|
||||
param: '典型工艺名称分类流水号_check=' + check1 + '=bit&典型工艺名称分类流水号=' + a + '=int&典型工艺流水号_check=' + check2 + '=bit&典型工艺流水号=' + b + '=int&典型工艺流水号1_check=' + check3 + '=bit&典型工艺流水号1=' + c + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 初始化工艺名称
|
||||
export function processNameClick() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_工艺分类名称_查询数据_零件工艺制定专用'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 工艺名称查询
|
||||
export function processNameSelect(val) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_工艺名称_查询数据',
|
||||
param: '工艺分类流水号_check=1=bit&工艺分类流水号=' + val + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 工艺要求查询
|
||||
export function processRequestSelect(val) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理_基础表_工艺要求_查询数据',
|
||||
param: '工艺编号=' + val + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 初始化公差A
|
||||
export function initTolerance() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_公差对照表_查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 公差查询
|
||||
export function searchTolerance(val1, val2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_基础表_公差对照表_公差_查询数据',
|
||||
param: '输入数值=' + val1 + '&参数=' + val2
|
||||
}
|
||||
})
|
||||
}
|
||||
// 工艺定额人员查询
|
||||
export function initPerson() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
|
||||
param: '考核部门编号=9'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 完艺工艺查询
|
||||
export function searchWYgongyi(check1, tuhao, check2, bianhao, check3, start, end, check4, name) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工艺计划_查询数据_根据零件图号查询已投产的工艺计划流水号',
|
||||
param: '零件图号_check=' + check1 + '&零件图号=' + tuhao + '&工艺员编号_check=' + check2 + '&工艺员编号=' + bianhao + '&工艺时间_check=' + check3 + '&工艺开始时间=' + start + '=datetime&工艺结束时间=' + end + '=datetime&零件名称_check=' + check4 + '&零件名称=' + name
|
||||
}
|
||||
})
|
||||
}
|
||||
// 完艺工艺要求查询
|
||||
export function gongyiYQ(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工艺计划_查询数据',
|
||||
param: '工艺计划流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 完艺工艺拷贝
|
||||
export function gongyiCopy(num1, num2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工序_工艺拷贝_工艺计划流水号',
|
||||
param: '工艺计划流水号_完成工艺=' + num1 + '=int&工艺计划流水号_被拷工艺=' + num2 + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面选择零件号查主表
|
||||
export function mainTable(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_零件工序_查询工序信息',
|
||||
param: '工艺计划流水号=' + num + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面主表难度等级修改
|
||||
export function hardEdit(num, hard) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_修改数据_工艺难度等级',
|
||||
param: '工序流水号=' + num + '=int&工艺难度等级=' + hard
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面主表工艺要求修改
|
||||
export function requestEdit(num, request0) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_修改数据_工艺要求_根据工序流水号',
|
||||
param: '工序流水号=' + num + '=int&工艺要求=' + request0
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面主表插入功能
|
||||
export function insertOne(num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_修改数据_工艺计划流水号和工序流水号',
|
||||
param: '工艺计划流水号=' + num0 + '=int&工序流水号=' + num1 + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面主表删除功能
|
||||
export function deleteOne(num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_删除数据_工序流水号',
|
||||
param: '工艺计划流水号=' + num0 + '=int&工序流水号=' + num1 + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面主表上移功能
|
||||
export function upOne(num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_修改数据_上移工序',
|
||||
param: '工艺计划流水号=' + num0 + '=int&工序流水号=' + num1 + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 主界面主表下移功能
|
||||
export function downOne(num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_修改数据_下移工序',
|
||||
param: '工艺计划流水号=' + num0 + '=int&工序流水号=' + num1 + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 保存变更材质
|
||||
export function saveMaterial(num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工艺计划_修改零件材料',
|
||||
param: '工艺计划流水号=' + num0 + '&材料流水号=' + num1
|
||||
}
|
||||
})
|
||||
}
|
||||
// 核准保存
|
||||
export function saveApprove(num0, num1, request0, spec, num2, outhelp, num3, num4, weight, area, num5, level) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_增加数据_同时修改工艺计划',
|
||||
param: '工艺计划流水号=' + num0 + '&工艺编号=' + num1 + '&工艺要求=' + request0 + '&原材料规格=' + spec + '&工序顺序=' + num2 + '&工序间是否外协=' + outhelp + '&工序流水号=' + num3 + '&材料流水号=' + num4 + '&重量=' + weight + '&面积=' + area + '&工艺人员编号=' + num5 + '&工艺难度等级=' + level
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// 粘贴
|
||||
export function pasteTable(oldNum, newNum) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工艺计划_拷贝零件工艺',
|
||||
param: '工艺计划流水号旧=' + oldNum + '&工艺计划流水号新=' + newNum
|
||||
}
|
||||
})
|
||||
}
|
||||
// 删除
|
||||
export function deleteTable(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_删除零件工艺',
|
||||
param: '工艺计划流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 在制零件工艺修改
|
||||
export function returnEdit(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_在制零件工艺调整_修改工艺',
|
||||
param: '工艺计划流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询工艺记录
|
||||
export function searchRecord(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '1',
|
||||
name: '车间生产管理工艺_在制零件工艺调整_查询工艺',
|
||||
param: '工艺计划流水号=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
// 重量拷贝
|
||||
export function WeightCopy(num, num2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_重量拷贝_工艺计划流水号',
|
||||
param: '工艺计划流水号=' + num + '&重量信息=' + num2
|
||||
}
|
||||
})
|
||||
}
|
||||
// 保存变更材质
|
||||
export function saveWeight(num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工艺计划_修改零件重量',
|
||||
param: '工艺计划流水号=' + num0 + '&重量=' + num1
|
||||
}
|
||||
})
|
||||
}
|
||||
// 单件工时改变
|
||||
export function singleChange(val1, val2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_单件准结定额_修改数据',
|
||||
param: '工序流水号=' + val1 + '&单件定额工时=' + val2
|
||||
}
|
||||
})
|
||||
}
|
||||
// 准结工时改变
|
||||
export function readyChange(val1, val2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_单件准结定额_修改数据',
|
||||
param: '工序流水号=' + val1 + '&准结定额工时=' + val2
|
||||
}
|
||||
})
|
||||
}
|
||||
// 未编制定额保存
|
||||
export function TableAddLi1(a, b) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_定额任务分配_保存数据',
|
||||
param: '工艺计划流水号=' + a + '=string&人员编号=' + b + '=string'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 已编制定额保存
|
||||
export function TableAddLi(a, b, c, num0, num1) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_零件工序_增加数据_修改数据',
|
||||
param: '单件定额工时=' + a + '=string&准结定额工时=' + b + '=string&零件图号=' + c + '=string&工序流水号=' + num0 + '=int&工艺计划流水号=' + num1 + '=int'
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -60,3 +60,22 @@ export function getTable2(stepNumber) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getExport(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: `select 机床流水号,组件流水号,车间生产管理工艺_零件工艺计划.工艺计划流水号,车间生产管理工艺_零件工艺计划.零件图号_零件工艺计划,车间生产管理工艺_零件工序_视图.零件名称,待加工工序顺序,车间生产管理工艺_零件工序.工序流水号,车间生产管理工艺_零件工序.工艺编号,车间生产管理工艺_基础表_工艺名称.工艺名称,批次数量,材料
|
||||
from ( select 工艺计划流水号,min(工序顺序) as 待加工工序顺序
|
||||
from 车间生产管理工艺_零件工序_视图
|
||||
where 完成日期_短 is null and 考核状态 = 6
|
||||
group by 工艺计划流水号) as 当前加工工序表
|
||||
inner join 车间生产管理工艺_零件工艺计划 on 当前加工工序表.工艺计划流水号 = 车间生产管理工艺_零件工艺计划.工艺计划流水号
|
||||
inner join 车间生产管理工艺_零件工序 on 当前加工工序表.工艺计划流水号 = 车间生产管理工艺_零件工序.工艺计划流水号 and 当前加工工序表.待加工工序顺序 = 车间生产管理工艺_零件工序.工序顺序
|
||||
inner join 车间生产管理工艺_基础表_工艺名称 on 车间生产管理工艺_基础表_工艺名称.工艺编号 = 车间生产管理工艺_零件工序.工艺编号
|
||||
inner join 车间生产管理工艺_零件工序_视图 on 车间生产管理工艺_零件工序_视图.工艺计划流水号 = 车间生产管理工艺_零件工艺计划.工艺计划流水号 and 当前加工工序表.待加工工序顺序 = 车间生产管理工艺_零件工序_视图.工序顺序
|
||||
where 组件流水号 = ${num}`
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
1
src/icons/svg/ProcessQuotaEstablishment.svg
Normal file
1
src/icons/svg/ProcessQuotaEstablishment.svg
Normal file
@@ -0,0 +1 @@
|
||||
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1545972017991" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1585" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M905.216 401.408 905.216 401.408c-26.624-28.672-65.536-45.056-104.448-45.056-4.096 0-8.192 0-10.24 0L790.528 180.224c0-18.432-16.384-34.816-34.816-34.816L108.544 145.408c-18.432 0-34.816 16.384-34.816 34.816l0 647.168c0 18.432 16.384 34.816 34.816 34.816l647.168 0c18.432 0 34.816-16.384 34.816-34.816l0-176.128c4.096 0 6.144 0 10.24 0 40.96 0 77.824-16.384 104.448-43.008 26.624-26.624 43.008-63.488 43.008-104.448C948.224 462.848 931.84 428.032 905.216 401.408zM448.512 188.416l286.72 0 0 182.272c-14.336 8.192-26.624 16.384-38.912 28.672-20.48 20.48-34.816 45.056-40.96 75.776L448.512 475.136 448.512 188.416zM415.744 794.624l-286.72 0 0-286.72 286.72 0L415.744 794.624zM415.744 475.136l-286.72 0 0-286.72 286.72 0L415.744 475.136zM735.232 794.624l-286.72 0 0-286.72 204.8 0c2.048 38.912 18.432 73.728 43.008 100.352 10.24 10.24 24.576 20.48 38.912 26.624L735.232 794.624zM800.768 608.256c-57.344 0-104.448-47.104-104.448-104.448 0-57.344 47.104-104.448 104.448-104.448s104.448 47.104 104.448 104.448C905.216 561.152 858.112 608.256 800.768 608.256z" p-id="1586"></path><path d="M849.92 460.8 849.92 460.8c4.096-4.096 12.288-4.096 18.432 0 4.096 4.096 4.096 12.288 0 18.432l-79.872 79.872c-4.096 6.144-12.288 6.144-18.432 0l0 0-36.864-36.864c-4.096-4.096-4.096-12.288 0-18.432 6.144-4.096 12.288-4.096 18.432 0L778.24 532.48 849.92 460.8 849.92 460.8z" p-id="1587"></path><path d="M301.056 593.92 301.056 593.92c6.144-6.144 16.384-6.144 22.528 0 6.144 6.144 6.144 16.384 0 22.528L286.72 655.36l38.912 38.912c6.144 6.144 6.144 16.384 0 22.528-6.144 6.144-16.384 6.144-22.528 0l-38.912-38.912-38.912 38.912c-6.144 6.144-16.384 6.144-22.528 0-6.144-6.144-6.144-16.384 0-22.528l38.912-38.912-38.912-38.912c-6.144-6.144-6.144-16.384 0-22.528 6.144-6.144 16.384-6.144 22.528 0l38.912 38.912L301.056 593.92 301.056 593.92z" p-id="1588"></path><path d="M245.76 253.952 245.76 253.952c0-8.192 8.192-16.384 16.384-16.384 8.192 0 16.384 8.192 16.384 16.384l0 55.296 55.296 0c8.192 0 16.384 6.144 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384l-55.296 0 0 55.296c0 10.24-8.192 16.384-16.384 16.384-10.24 0-16.384-8.192-16.384-16.384l0-55.296L190.464 342.016c-10.24 0-16.384-8.192-16.384-16.384 0-10.24 8.192-16.384 16.384-16.384L245.76 309.248 245.76 253.952 245.76 253.952z" p-id="1589"></path><path d="M665.6 671.744 665.6 671.744c8.192 0 16.384 8.192 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384-120.832 0-22.528 0-143.36 0-8.192 0-16.384-8.192-16.384-16.384 0-8.192 6.144-16.384 16.384-16.384C641.024 671.744 544.768 671.744 665.6 671.744L665.6 671.744z" p-id="1590"></path><path d="M665.6 606.208 665.6 606.208c8.192 0 16.384 8.192 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384-120.832 0-22.528 0-143.36 0-8.192 0-16.384-8.192-16.384-16.384 0-10.24 6.144-16.384 16.384-16.384C641.024 606.208 544.768 606.208 665.6 606.208L665.6 606.208z" p-id="1591"></path><path d="M665.6 309.248 665.6 309.248c8.192 0 16.384 6.144 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384-120.832 0-22.528 0-143.36 0-8.192 0-16.384-8.192-16.384-16.384 0-10.24 6.144-16.384 16.384-16.384C641.024 309.248 544.768 309.248 665.6 309.248L665.6 309.248z" p-id="1592"></path></svg>
|
||||
|
After Width: | Height: | Size: 3.5 KiB |
1
src/icons/svg/PurchaseOutRecord.svg
Normal file
1
src/icons/svg/PurchaseOutRecord.svg
Normal file
@@ -0,0 +1 @@
|
||||
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1545972017991" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1585" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M905.216 401.408 905.216 401.408c-26.624-28.672-65.536-45.056-104.448-45.056-4.096 0-8.192 0-10.24 0L790.528 180.224c0-18.432-16.384-34.816-34.816-34.816L108.544 145.408c-18.432 0-34.816 16.384-34.816 34.816l0 647.168c0 18.432 16.384 34.816 34.816 34.816l647.168 0c18.432 0 34.816-16.384 34.816-34.816l0-176.128c4.096 0 6.144 0 10.24 0 40.96 0 77.824-16.384 104.448-43.008 26.624-26.624 43.008-63.488 43.008-104.448C948.224 462.848 931.84 428.032 905.216 401.408zM448.512 188.416l286.72 0 0 182.272c-14.336 8.192-26.624 16.384-38.912 28.672-20.48 20.48-34.816 45.056-40.96 75.776L448.512 475.136 448.512 188.416zM415.744 794.624l-286.72 0 0-286.72 286.72 0L415.744 794.624zM415.744 475.136l-286.72 0 0-286.72 286.72 0L415.744 475.136zM735.232 794.624l-286.72 0 0-286.72 204.8 0c2.048 38.912 18.432 73.728 43.008 100.352 10.24 10.24 24.576 20.48 38.912 26.624L735.232 794.624zM800.768 608.256c-57.344 0-104.448-47.104-104.448-104.448 0-57.344 47.104-104.448 104.448-104.448s104.448 47.104 104.448 104.448C905.216 561.152 858.112 608.256 800.768 608.256z" p-id="1586"></path><path d="M849.92 460.8 849.92 460.8c4.096-4.096 12.288-4.096 18.432 0 4.096 4.096 4.096 12.288 0 18.432l-79.872 79.872c-4.096 6.144-12.288 6.144-18.432 0l0 0-36.864-36.864c-4.096-4.096-4.096-12.288 0-18.432 6.144-4.096 12.288-4.096 18.432 0L778.24 532.48 849.92 460.8 849.92 460.8z" p-id="1587"></path><path d="M301.056 593.92 301.056 593.92c6.144-6.144 16.384-6.144 22.528 0 6.144 6.144 6.144 16.384 0 22.528L286.72 655.36l38.912 38.912c6.144 6.144 6.144 16.384 0 22.528-6.144 6.144-16.384 6.144-22.528 0l-38.912-38.912-38.912 38.912c-6.144 6.144-16.384 6.144-22.528 0-6.144-6.144-6.144-16.384 0-22.528l38.912-38.912-38.912-38.912c-6.144-6.144-6.144-16.384 0-22.528 6.144-6.144 16.384-6.144 22.528 0l38.912 38.912L301.056 593.92 301.056 593.92z" p-id="1588"></path><path d="M245.76 253.952 245.76 253.952c0-8.192 8.192-16.384 16.384-16.384 8.192 0 16.384 8.192 16.384 16.384l0 55.296 55.296 0c8.192 0 16.384 6.144 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384l-55.296 0 0 55.296c0 10.24-8.192 16.384-16.384 16.384-10.24 0-16.384-8.192-16.384-16.384l0-55.296L190.464 342.016c-10.24 0-16.384-8.192-16.384-16.384 0-10.24 8.192-16.384 16.384-16.384L245.76 309.248 245.76 253.952 245.76 253.952z" p-id="1589"></path><path d="M665.6 671.744 665.6 671.744c8.192 0 16.384 8.192 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384-120.832 0-22.528 0-143.36 0-8.192 0-16.384-8.192-16.384-16.384 0-8.192 6.144-16.384 16.384-16.384C641.024 671.744 544.768 671.744 665.6 671.744L665.6 671.744z" p-id="1590"></path><path d="M665.6 606.208 665.6 606.208c8.192 0 16.384 8.192 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384-120.832 0-22.528 0-143.36 0-8.192 0-16.384-8.192-16.384-16.384 0-10.24 6.144-16.384 16.384-16.384C641.024 606.208 544.768 606.208 665.6 606.208L665.6 606.208z" p-id="1591"></path><path d="M665.6 309.248 665.6 309.248c8.192 0 16.384 6.144 16.384 16.384 0 8.192-8.192 16.384-16.384 16.384-120.832 0-22.528 0-143.36 0-8.192 0-16.384-8.192-16.384-16.384 0-10.24 6.144-16.384 16.384-16.384C641.024 309.248 544.768 309.248 665.6 309.248L665.6 309.248z" p-id="1592"></path></svg>
|
||||
|
After Width: | Height: | Size: 3.5 KiB |
@@ -17,13 +17,7 @@ export const uploadInvoiceScan = `http://192.168.1.231:8411/submit/uploadInvoice
|
||||
export const uploadInvoiceScan1 = `http://192.168.1.231:8411/submit/uploadInvoiceScan1.ashx` // invoice(workshop)
|
||||
export const download = `http://192.168.1.231:8411/submit/downloadFile.ashx` // ContractInformationManagement
|
||||
const service = axios.create({
|
||||
// baseURL: `http://192.168.1.149:8411/submit/MESCommonBase.ashx`,
|
||||
// baseURL: `http://192.168.1.149:8411/submit/MESCommonBase.ashx`,
|
||||
// baseURL: `http://localhost:8411/submit/MESCommonBase.ashx`,
|
||||
// baseURL: `http://localhost:8411/submit/MESCommonBase.ashx`,
|
||||
baseURL: `http://192.168.1.231:8411/submit/MESCommonBase.ashx`,
|
||||
// baseURL: `http://localhost:8077/submit/MESCommonBase.ashx`,
|
||||
// baseURL: `http://192.168.0.112:8411/submit/MESCommonBase.ashx`,
|
||||
timeout: 1500000 // 请求超时时间
|
||||
})
|
||||
|
||||
|
||||
133
src/vendor/Export2Excel.js
vendored
133
src/vendor/Export2Excel.js
vendored
@@ -1,7 +1,7 @@
|
||||
/* eslint-disable */
|
||||
require('script-loader!file-saver');
|
||||
require('script-loader!@/vendor/Blob');
|
||||
require('script-loader!xlsx/dist/xlsx.core.min');
|
||||
import XLSX from 'xlsx'
|
||||
|
||||
function generateArray(table) {
|
||||
var out = [];
|
||||
var rows = table.querySelectorAll('tr');
|
||||
@@ -28,15 +28,24 @@ function generateArray(table) {
|
||||
if (rowspan || colspan) {
|
||||
rowspan = rowspan || 1;
|
||||
colspan = colspan || 1;
|
||||
ranges.push({s: {r: R, c: outRow.length}, e: {r: R + rowspan - 1, c: outRow.length + colspan - 1}});
|
||||
}
|
||||
;
|
||||
ranges.push({
|
||||
s: {
|
||||
r: R,
|
||||
c: outRow.length
|
||||
},
|
||||
e: {
|
||||
r: R + rowspan - 1,
|
||||
c: outRow.length + colspan - 1
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
//Handle Value
|
||||
outRow.push(cellValue !== "" ? cellValue : null);
|
||||
|
||||
//Handle Colspan
|
||||
if (colspan) for (var k = 0; k < colspan - 1; ++k) outRow.push(null);
|
||||
if (colspan)
|
||||
for (var k = 0; k < colspan - 1; ++k) outRow.push(null);
|
||||
}
|
||||
out.push(outRow);
|
||||
}
|
||||
@@ -51,16 +60,30 @@ function datenum(v, date1904) {
|
||||
|
||||
function sheet_from_array_of_arrays(data, opts) {
|
||||
var ws = {};
|
||||
var range = {s: {c: 10000000, r: 10000000}, e: {c: 0, r: 0}};
|
||||
var range = {
|
||||
s: {
|
||||
c: 10000000,
|
||||
r: 10000000
|
||||
},
|
||||
e: {
|
||||
c: 0,
|
||||
r: 0
|
||||
}
|
||||
};
|
||||
for (var R = 0; R != data.length; ++R) {
|
||||
for (var C = 0; C != data[R].length; ++C) {
|
||||
if (range.s.r > R) range.s.r = R;
|
||||
if (range.s.c > C) range.s.c = C;
|
||||
if (range.e.r < R) range.e.r = R;
|
||||
if (range.e.c < C) range.e.c = C;
|
||||
var cell = {v: data[R][C]};
|
||||
var cell = {
|
||||
v: data[R][C]
|
||||
};
|
||||
if (cell.v == null) continue;
|
||||
var cell_ref = XLSX.utils.encode_cell({c: C, r: R}); // here
|
||||
var cell_ref = XLSX.utils.encode_cell({
|
||||
c: C,
|
||||
r: R
|
||||
});
|
||||
|
||||
if (typeof cell.v === 'number') cell.t = 'n';
|
||||
else if (typeof cell.v === 'boolean') cell.t = 'b';
|
||||
@@ -68,8 +91,7 @@ function sheet_from_array_of_arrays(data, opts) {
|
||||
cell.t = 'n';
|
||||
cell.z = XLSX.SSF._table[14];
|
||||
cell.v = datenum(cell.v);
|
||||
}
|
||||
else cell.t = 's';
|
||||
} else cell.t = 's';
|
||||
|
||||
ws[cell_ref] = cell;
|
||||
}
|
||||
@@ -93,16 +115,15 @@ function s2ab(s) {
|
||||
|
||||
export function export_table_to_excel(id) {
|
||||
var theTable = document.getElementById(id);
|
||||
console.log('a')
|
||||
var oo = generateArray(theTable);
|
||||
var ranges = oo[1];
|
||||
|
||||
/* original data */
|
||||
var data = oo[0];
|
||||
var ws_name = "SheetJS";
|
||||
console.log(data);
|
||||
|
||||
var wb = new Workbook(), ws = sheet_from_array_of_arrays(data);
|
||||
var wb = new Workbook(),
|
||||
ws = sheet_from_array_of_arrays(data);
|
||||
|
||||
/* add ranges to worksheet */
|
||||
// ws['!cols'] = ['apple', 'banan'];
|
||||
@@ -112,30 +133,88 @@ export function export_table_to_excel(id) {
|
||||
wb.SheetNames.push(ws_name);
|
||||
wb.Sheets[ws_name] = ws;
|
||||
|
||||
var wbout = XLSX.write(wb, {bookType: 'xlsx', bookSST: false, type: 'binary'});
|
||||
var wbout = XLSX.write(wb, {
|
||||
bookType: 'xlsx',
|
||||
bookSST: false,
|
||||
type: 'binary'
|
||||
});
|
||||
|
||||
saveAs(new Blob([s2ab(wbout)], {type: "application/octet-stream"}), "test.xlsx")
|
||||
saveAs(new Blob([s2ab(wbout)], {
|
||||
type: "application/octet-stream"
|
||||
}), "test.xlsx")
|
||||
}
|
||||
|
||||
function formatJson(jsonData) {
|
||||
console.log(jsonData)
|
||||
}
|
||||
export function export_json_to_excel(th, jsonData, defaultTitle) {
|
||||
|
||||
export function export_json_to_excel({
|
||||
multiHeader = [],
|
||||
header,
|
||||
data,
|
||||
filename,
|
||||
merges = [],
|
||||
autoWidth = true,
|
||||
bookType= 'xlsx'
|
||||
} = {}) {
|
||||
/* original data */
|
||||
filename = filename || 'excel-list'
|
||||
data = [...data]
|
||||
data.unshift(header);
|
||||
|
||||
for (let i = multiHeader.length-1; i > -1; i--) {
|
||||
data.unshift(multiHeader[i])
|
||||
}
|
||||
|
||||
var data = jsonData;
|
||||
data.unshift(th);
|
||||
var ws_name = "SheetJS";
|
||||
var wb = new Workbook(),
|
||||
ws = sheet_from_array_of_arrays(data);
|
||||
|
||||
var wb = new Workbook(), ws = sheet_from_array_of_arrays(data);
|
||||
if (merges.length > 0) {
|
||||
if (!ws['!merges']) ws['!merges'] = [];
|
||||
merges.forEach(item => {
|
||||
ws['!merges'].push(XLSX.utils.decode_range(item))
|
||||
})
|
||||
}
|
||||
|
||||
if (autoWidth) {
|
||||
/*设置worksheet每列的最大宽度*/
|
||||
const colWidth = data.map(row => row.map(val => {
|
||||
/*先判断是否为null/undefined*/
|
||||
if (val == null) {
|
||||
return {
|
||||
'wch': 10
|
||||
};
|
||||
}
|
||||
/*再判断是否为中文*/
|
||||
else if (val.toString().charCodeAt(0) > 255) {
|
||||
return {
|
||||
'wch': val.toString().length * 2
|
||||
};
|
||||
} else {
|
||||
return {
|
||||
'wch': val.toString().length
|
||||
};
|
||||
}
|
||||
}))
|
||||
/*以第一行为初始值*/
|
||||
let result = colWidth[0];
|
||||
for (let i = 1; i < colWidth.length; i++) {
|
||||
for (let j = 0; j < colWidth[i].length; j++) {
|
||||
if (result[j]['wch'] < colWidth[i][j]['wch']) {
|
||||
result[j]['wch'] = colWidth[i][j]['wch'];
|
||||
}
|
||||
}
|
||||
}
|
||||
ws['!cols'] = result;
|
||||
}
|
||||
|
||||
/* add worksheet to workbook */
|
||||
wb.SheetNames.push(ws_name);
|
||||
wb.Sheets[ws_name] = ws;
|
||||
|
||||
var wbout = XLSX.write(wb, {bookType: 'xlsx', bookSST: false, type: 'binary'});
|
||||
var title = defaultTitle || '列表'
|
||||
saveAs(new Blob([s2ab(wbout)], {type: "application/octet-stream"}), title + ".xlsx")
|
||||
var wbout = XLSX.write(wb, {
|
||||
bookType: bookType,
|
||||
bookSST: false,
|
||||
type: 'binary'
|
||||
});
|
||||
saveAs(new Blob([s2ab(wbout)], {
|
||||
type: "application/octet-stream"
|
||||
}), `${filename}.${bookType}`);
|
||||
}
|
||||
|
||||
@@ -42,9 +42,9 @@
|
||||
{{ scope.row.零件图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="入库数量" width="120px">
|
||||
<el-table-column align="center" label="出库数量" width="120px">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.入库数量 }}
|
||||
{{ scope.row.出库数量 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="机床图号" width="120px">
|
||||
@@ -57,19 +57,14 @@
|
||||
{{ scope.row.组号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="仓库名称" width="120px">
|
||||
<el-table-column align="center" label="领料人">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.仓库名称 }}
|
||||
{{ scope.row.出库备注 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="货位名称" width="120px">
|
||||
<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.入库时间 }}
|
||||
{{ scope.row.出库时间 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
141
src/views/Inventory/PurchaseOutRecord/index.vue
Normal file
141
src/views/Inventory/PurchaseOutRecord/index.vue
Normal file
@@ -0,0 +1,141 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<div slot="header" class="clearfix">
|
||||
<span>项目名称:</span>
|
||||
<el-select v-model="projectValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="projectChange">
|
||||
<el-option
|
||||
v-for="item in project"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span>机床图号:</span>
|
||||
<el-select v-model="machineValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="machineChange">
|
||||
<el-option
|
||||
v-for="item in machine"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span>组号:</span>
|
||||
<el-select v-model="groupValue" style="width:140px" placeholder="请选择" size="small" clearable filterable>
|
||||
<el-option
|
||||
v-for="item in group"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<span>名称:</span>
|
||||
<el-input v-model="name" clearable size="small" style="width:150px" />
|
||||
<span>规格:</span>
|
||||
<el-input v-model="spec" clearable size="small" style="width:150px" />
|
||||
<span>图号或型号:</span>
|
||||
<el-input v-model="model" clearable size="small" style="width:150px" />
|
||||
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="searchRecord()">查询</el-button>
|
||||
</div>
|
||||
<el-table :data="tableData" border size="mini" style="width: 100%;" height="600">
|
||||
<el-table-column label="名称" align="center" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="图号或型号" align="center" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.图号或型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="规格" align="center" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.规格 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="出库数量" align="center" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.出库数量 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="领料人" align="center" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.领料人 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="出库时间" align="center" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.出库时间 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { initProject, searchMachine, searchGroup, searchRecord } from '@/api/Inventory/PurchaseOutRecord'
|
||||
export default {
|
||||
name: 'PurchaseOutRecord',
|
||||
data() {
|
||||
return {
|
||||
projectValue: '', // 项目名称
|
||||
project: [],
|
||||
machineValue: '',
|
||||
machine: [],
|
||||
groupValue: '',
|
||||
group: [],
|
||||
name: '',
|
||||
spec: '',
|
||||
model: '',
|
||||
tableData: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.getSelect(initProject, ['项目名称', '项目流水号'], 'project')
|
||||
},
|
||||
methods: {
|
||||
projectChange() {
|
||||
this.machine = []
|
||||
this.machineValue = ''
|
||||
this.group = []
|
||||
this.groupValue = ''
|
||||
searchMachine(this.projectValue).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.machine.push({
|
||||
value: response.data[i].机床流水号,
|
||||
label: response.data[i].机床图号
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
machineChange() {
|
||||
this.group = []
|
||||
this.groupValue = ''
|
||||
searchGroup(this.machineValue).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.group.push({
|
||||
value: response.data[i].组件流水号,
|
||||
label: response.data[i].组号
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
searchRecord() {
|
||||
if (!this.projectValue) {
|
||||
this.$message.warning('请选择项目')
|
||||
return
|
||||
}
|
||||
searchRecord(this.projectValue, this.machineValue, this.groupValue, this.name, this.spec, this.model).then(res => {
|
||||
this.tableData = res.data
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.el-card{
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
span{
|
||||
margin: 10px 0 10px 10px;
|
||||
}
|
||||
</style>
|
||||
@@ -32,15 +32,13 @@
|
||||
</el-col>
|
||||
<el-col style="width: 290px">
|
||||
<span>工艺员:</span>
|
||||
<el-select v-model="personValue" placeholder="工艺员" size="small" clearable>
|
||||
<el-select v-model="personValue" placeholder="工艺员" size="small" clearable style="width: 100px">
|
||||
<el-option
|
||||
v-for="item in person"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-col>
|
||||
<el-col style="width: 290px">
|
||||
<el-button type="success" size="small" style="margin-left: 10px" icon="el-icon-search" @click="pageCurrent=1;pageSize=10;total=0;searchData()">查询</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@@ -81,6 +79,9 @@
|
||||
</div>
|
||||
</el-card>
|
||||
<el-card v-if="tableData2.length">
|
||||
<div slot="header">
|
||||
<el-button v-show="true" type="danger" icon="el-icon-edit" size="small" @click="returnEdit">在制零件工艺调整</el-button>
|
||||
</div>
|
||||
<table class="tg">
|
||||
<tr>
|
||||
<td class="tg-x61c" colspan="4" rowspan="2">江苏高精</td>
|
||||
@@ -151,7 +152,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { initMachineProject, searchgroup, initPerson, search, searchtable1 } from '@/api/ManufacturingCenter/PartWorkCraftSelect_rdlc'
|
||||
import { initMachineProject, searchgroup, initPerson, search, searchtable1,
|
||||
returnEdit } from '@/api/ManufacturingCenter/PartWorkCraftSelect_rdlc'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
@@ -187,6 +189,33 @@ export default {
|
||||
this.searchData()
|
||||
},
|
||||
methods: {
|
||||
returnEdit() { // 在制零件工艺修改
|
||||
if (this.partNumValue === '' || this.partNumValue === null) {
|
||||
this.$message.error('请选择零件')
|
||||
} else {
|
||||
this.$confirm(`此操作会将 ${this.零件图号} 打回至未编制状态, 是否继续?`, '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
returnEdit(this.partNumValue).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('打回成功')
|
||||
this.partNumValue = ''
|
||||
this.tableData = []
|
||||
this.tableData2 = []
|
||||
} else {
|
||||
this.$message.error('打回失败')
|
||||
}
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消操作'
|
||||
})
|
||||
})
|
||||
}
|
||||
},
|
||||
fetchData() {
|
||||
initMachineProject().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
@@ -227,12 +256,13 @@ export default {
|
||||
this.personValue ? check4 = 1 : check4 = 0
|
||||
search(this.pageCurrent, this.pageSize, check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.PrNum, check4, this.personValue).then(response => {
|
||||
this.tableData = response.data.rows
|
||||
console.log(response)
|
||||
this.total = response.data.total
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
click(row) {
|
||||
this.partNumValue = row.工艺计划流水号
|
||||
this.零件图号 = row.零件图号
|
||||
searchtable1(row.工艺计划流水号).then(response => {
|
||||
this.tableData2 = response.data
|
||||
})
|
||||
|
||||
1609
src/views/ManufacturingCenter/ProcessQuotaEstablishment/index.vue
Normal file
1609
src/views/ManufacturingCenter/ProcessQuotaEstablishment/index.vue
Normal file
File diff suppressed because it is too large
Load Diff
@@ -48,6 +48,7 @@
|
||||
type="date"
|
||||
placeholder="选择日期"/>
|
||||
<el-button type="success" class="el-icon-search" size="small" style="margin: 10px 0 0 10px" @click="getTableData();pageCurrent=1;pageSize=10;total = 0">查询</el-button>
|
||||
<el-button type="warning" class="el-icon-download" size="small" style="margin: 10px 0 0 10px" @click="exportExcel">导出</el-button>
|
||||
</el-row>
|
||||
</el-card>
|
||||
|
||||
@@ -309,7 +310,7 @@
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { getNames, getMachines, getGroups, getTable, getTable2 } from '@/api/ManufacturingCenter/ProcessingStatus'
|
||||
import { getNames, getMachines, getGroups, getTable, getTable2, getExport } from '@/api/ManufacturingCenter/ProcessingStatus'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
@@ -384,6 +385,33 @@ export default {
|
||||
this.getTableData()
|
||||
},
|
||||
methods: {
|
||||
formatJson(filterVal, jsonData) {
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
return v[j]
|
||||
}))
|
||||
},
|
||||
exportExcel() {
|
||||
if (!this.Group) {
|
||||
this.$message.warning('请选择分组')
|
||||
return
|
||||
}
|
||||
getExport(this.Group).then(res => {
|
||||
console.log(res.data)
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['图号及规格', '制品名称', '计划数', '材料', '当前工序名']
|
||||
const filterVal = ['零件图号_零件工艺计划', '零件名称', '批次数量', '材料', '工艺名称']
|
||||
const list = res.data
|
||||
const data = this.formatJson(filterVal, list)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: '加工进度表',
|
||||
autoWidth: true,
|
||||
bookType: 'xlsx'
|
||||
})
|
||||
})
|
||||
})
|
||||
},
|
||||
// 查询供应商名称
|
||||
fetchData() {
|
||||
this.projects = []
|
||||
|
||||
@@ -431,7 +431,7 @@
|
||||
@current-change="handleCurrentChange1"/>
|
||||
<div style="float:right">
|
||||
<el-button type="primary" size="small" style="margin:5px 10px 10px 10px" @click="Discharge">虚拟排产</el-button>
|
||||
<el-button :disabled="listLoading1" type="primary" size="small" style="margin:5px 10px 10px 10px" @click="Plan" >确定零件计划</el-button>
|
||||
<el-button v-if="可以确定零件计划" type="primary" size="small" style="margin:5px 10px 10px 10px" @click="Plan" >确定零件计划</el-button>
|
||||
<el-button type="danger" size="small" icon="el-icon-upload2" style="float:right;margin:5px 50px 10px 10px" @click="allOut">全部选出</el-button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -620,6 +620,7 @@ export default {
|
||||
directives: { elDragDialog },
|
||||
data() {
|
||||
return {
|
||||
可以确定零件计划: false,
|
||||
bianliang1: [],
|
||||
count: 0,
|
||||
是否扫描: false,
|
||||
@@ -1226,6 +1227,12 @@ export default {
|
||||
this.计划日期.push(response.data[i].计划日期)
|
||||
}
|
||||
})
|
||||
this.可以确定零件计划 = true
|
||||
for (let i = 0; i < this.planDate.length; i++) {
|
||||
for (let j = 0; j < this.planDate[i].length; j++) {
|
||||
this.可以确定零件计划 = this.可以确定零件计划 && !!this.planDate[i][j]
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
} else {
|
||||
@@ -1435,6 +1442,7 @@ export default {
|
||||
this.bianliang1.push(this.tableData1[i].工艺计划流水号)
|
||||
}
|
||||
discharge(this.bianliang1).then(response => {
|
||||
console.log(response.data)
|
||||
this.Selection1()
|
||||
})
|
||||
},
|
||||
|
||||
@@ -11,6 +11,11 @@ const tableToExcel = (function() {
|
||||
return function(table, filename, sheetname) {
|
||||
if (!table.nodeType) table = document.getElementById(table)
|
||||
const ctx = { worksheet: sheetname || 'Worksheet', table: table.innerHTML }
|
||||
const blob = new Blob([format(template, ctx)])
|
||||
if ('msSaveOrOpenBlob' in navigator) {
|
||||
window.navigator.msSaveOrOpenBlob(blob, filename + '.xls')
|
||||
return
|
||||
}
|
||||
const aTag = document.createElement('a')
|
||||
aTag.href = uri + base64(format(template, ctx))
|
||||
aTag.download = filename
|
||||
|
||||
@@ -640,7 +640,7 @@ export default {
|
||||
|
||||
<style>
|
||||
.el-table .warning-row {
|
||||
background: red;
|
||||
background: yellowgreen;
|
||||
}
|
||||
.rgb196{
|
||||
background: palevioletred;
|
||||
|
||||
Reference in New Issue
Block a user