处理clearable不起作用的冲突,删除我测试部分,保留曹鑫宇程序

This commit is contained in:
hedekun
2018-11-27 14:37:14 +08:00
112 changed files with 8878 additions and 1557 deletions

View File

@@ -7,7 +7,7 @@ const os = require('os')
const networkInterfaces = os.networkInterfaces() const networkInterfaces = os.networkInterfaces()
const ip = networkInterfaces['WLAN'][1].address const ip = networkInterfaces['WLAN'][1] ? networkInterfaces['WLAN'][1].address : networkInterfaces['WLAN'][0].address
module.exports = { module.exports = {
dev: { dev: {

View File

@@ -1,11 +1,29 @@
<template> <template>
<div id="app"> <div id="app">
<router-view/> <router-view v-if="isRouterAlive"/>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
name: 'App' name: 'App',
provide() {
return {
reload: this.reload
}
},
data() {
return {
isRouterAlive: true
}
},
methods: {
reload() {
this.isRouterAlive = false
this.$nextTick(function() {
this.isRouterAlive = true
})
}
}
} }
</script> </script>

View File

@@ -95,26 +95,26 @@ export function searchDetail(num) {
}) })
} }
// 增加组件工艺 // 增加组件工艺
export function submitAdd(machineNumberValue, SerialNumber, Group, AssemblyTask) { export function submitAdd(machineNumberValue, SerialNumber, Group, AssemblyTask, GroupNumberValue1) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '2', type: '2',
name: '车间装配管理_组件工艺_增加数据', name: '车间装配管理_组件工艺_增加数据',
param: '机床流水号=' + machineNumberValue + '&序号=' + SerialNumber + '&组号=' + Group + '&装配任务=' + AssemblyTask param: '机床流水号=' + machineNumberValue + '&序号=' + SerialNumber + '&组号=' + Group + '&装配任务=' + AssemblyTask + '&组件流水号=' + GroupNumberValue1
} }
}) })
} }
// 编辑组件工艺 // 编辑组件工艺
export function submitEdit(GroupProcessNumber, SerialNumber, Group, AssemblyTask) { export function submitEdit(GroupProcessNumber, SerialNumber, Group, AssemblyTask, GroupNumberValue1) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '2', type: '2',
name: '车间装配管理_组件工艺_编辑数据', name: '车间装配管理_组件工艺_编辑数据',
param: '组件工艺流水号=' + GroupProcessNumber + '&序号=' + SerialNumber + '&组号=' + Group + '&装配任务=' + AssemblyTask param: '组件工艺流水号=' + GroupProcessNumber + '&序号=' + SerialNumber + '&组号=' + Group + '&装配任务=' + AssemblyTask + '&组件流水号=' + GroupNumberValue1
} }
}) })
} }

View File

@@ -0,0 +1,240 @@
import request from '@/utils/request'
// 初始化 工艺员A
export function initCraftmen() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=17'
}
})
}
// 初始化 工序分类
export function initprocessNameClass() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_工序分类_查询数据'
}
})
}
// 初始化 机床分类
export function initmachineType() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_机床分类_查询数据'
}
})
}
// 查询机床编号
export function SearchMachine(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_典型机床_查询数据',
param: '机床分类流水号=' + num
}
})
}
// 查询工序名称
export function initProcessName(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_工序名称_查询数据',
param: '工序分类流水号=' + num
}
})
}
// 查询组件
export function searchGroup(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_组件名称_查询数据',
param: '机床流水号=' + num
}
})
}
// 查询组件工艺
export function searchDetail(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_组件工艺_查询数据',
param: '机床流水号=' + num
}
})
}
// 增加组件工艺
export function submitAdd(machineNumberValue, SerialNumber, Group, AssemblyTask, GroupNumberValue1) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_组件工艺_增加数据',
param: '机床流水号=' + machineNumberValue + '&序号=' + SerialNumber + '&组号=' + Group + '&装配任务=' + AssemblyTask + '&组件流水号=' + GroupNumberValue1
}
})
}
// 编辑组件工艺
export function submitEdit(GroupProcessNumber, SerialNumber, Group, AssemblyTask, GroupNumberValue1) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_组件工艺_编辑数据',
param: '组件工艺流水号=' + GroupProcessNumber + '&序号=' + SerialNumber + '&组号=' + Group + '&装配任务=' + AssemblyTask + '&组件流水号=' + GroupNumberValue1
}
})
}
// 删除组件工艺
export function deleteGroup(GroupProcessNumber) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_组件工艺_删除数据',
param: '组件工艺流水号=' + GroupProcessNumber
}
})
}
// 查询工序
export function searchProcess(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_装配工序_查询数据',
param: '组件工艺流水号=' + num
}
})
}
// 增加工序
export function insertOne(num) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序_增加数据',
param: '组件工艺流水号=' + num
}
})
}
// 编辑工序
export function update(num, num1, num2, num3, num4) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序_编辑数据',
param: '装配工序流水号=' + num + '&序号=' + num1 + '&工序名称=' + num2 + '&工艺内容及装配具体要求=' + num3 + '&质检=' + num4
}
})
}
// 编辑工序1
export function update1(num, num1, num2, num3) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序_编辑数据',
param: '装配工序流水号=' + num + '&序号=' + num1 + '&工序名称=' + num2 + '&工艺内容及装配具体要求=' + num3
}
})
}
// 编辑工时
export function update2(num, num1) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序工时_编辑数据',
param: '装配工序流水号=' + num + '&工艺工时=' + num1
}
})
}
// 保存
export function saveApprove(num) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_机床工艺_定额完成',
param: '机床流水号=' + num
}
})
}
// 上移
export function upOne(num, num1, num2) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序_上移',
param: '装配工序流水号=' + num + '&组件工艺流水号=' + num1 + '&工序顺序=' + num2
}
})
}
// 下移
export function downOne(num, num1, num2) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序_下移',
param: '装配工序流水号=' + num + '&组件工艺流水号=' + num1 + '&工序顺序=' + num2
}
})
}
// 删除工序
export function deleteOne(num) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_装配工序_删除数据',
param: '装配工序流水号=' + num
}
})
}
// 工艺删除
export function deleteTable(num) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间装配管理_机床工艺_删除数据',
param: '机床流水号=' + num
}
})
}

View File

@@ -0,0 +1,63 @@
import request from '@/utils/request'
// 初始化获取工艺
export function getTechnology() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_基础表_工艺名称_查询数据',
param: '工艺分类流水号_check=0'
}
})
}
// 查询表格数据
export function searchtable(pageCurrent, pageSize, num1, ManufacturerNumber) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '设备管理_设备加工能力_查询数据_设备维护',
param: '设备名称_check=' + num1 + '&设备名称=' + ManufacturerNumber,
Pagination: pageCurrent + '&' + pageSize
}
})
}
// 增加
export function edittype(ManufacturerNumber, ManufacturerName, ManufacturerAbbreviation, address, phNumber, Fax, Remarks, category, attention, EquipmentCondition) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '设备管理_设备加工能力_增加数据_设备维护New',
param: '设备名称=' + ManufacturerNumber + '&设备型号=' + ManufacturerName + '&设备性能指标=' + ManufacturerAbbreviation + '&设备工时系数=' + address + '&工艺编号=' + phNumber + '&班次类型=' + Fax + '&设备加工能力工时=' + Remarks + '&整改工时系数=' + category + '&设备编号=' + attention + '&预留工时系数=' + EquipmentCondition
}
})
}
// 编辑
export function handlechange(num, ManufacturerNumber, ManufacturerName, ManufacturerAbbreviation, address, phNumber, Fax, Remarks, category, attention, EquipmentCondition) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '设备管理_设备加工能力_修改数据_设备维护New',
param: '设备流水号=' + num + '&设备名称=' + ManufacturerNumber + '&设备型号=' + ManufacturerName + '&设备性能指标=' + ManufacturerAbbreviation + '&设备工时系数=' + address + '&工艺属性代码=' + phNumber + '&班次类型=' + Fax + '&设备加工能力工时=' + Remarks + '&整改工时系数=' + category + '&设备编号=' + attention + '&预留工时系数=' + EquipmentCondition
}
})
}
// 删除
export function handledelete(CoManufacturerFlowNumber) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '设备管理_设备加工能力_删除数据_设备维护',
param: '设备流水号=' + CoManufacturerFlowNumber
}
})
}

View File

@@ -0,0 +1,47 @@
import request from '@/utils/request'
export function featchMaterial(num1, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_材质表_查询数据_根据材料名称',
param: '材料名称=' + num1,
pagination: pageCurrent + '&' + pageSize
}
})
}
export function addMaterial(num1) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_材质表_增加数据',
param: '材料=' + num1
}
})
}
export function delMaterial(num1) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_材质表_删除数据',
param: '材料流水号=' + num1
}
})
}
export function editMaterial(num1, num2) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_材质表_修改数据',
param: '材料流水号=' + num1 + '=int&材料=' + num2
}
})
}

View File

@@ -0,0 +1,59 @@
import request from '@/utils/request'
export function InitRolefunction(pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '菜单系统模块_项目角色_查询数据_MESWORK',
Pagination: pageCurrent + '&' + pageSize
}
})
}
export function deleteData(code) {
return request({
url: '',
method: 'post',
data: {
type: 2,
name: '菜单系统模块_项目角色_删除_MESWORK',
param: '角色编号=' + code + '=int'
}
})
}
export function searchTable(num, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '菜单系统模块_项目角色_查询数据_MESWORK',
param: '角色功能=' + num + '=string',
Pagination: pageCurrent + '&' + pageSize
}
})
}
export function addData(code) {
return request({
url: '',
method: 'post',
data: {
type: 2,
name: '菜单系统模块_项目角色_增加_MESWORK',
param: '角色功能=' + code + '=string'
}
})
}
export function addData2(code1, num1) {
return request({
url: '',
method: 'post',
data: {
type: 2,
name: '菜单系统模块_项目角色_修改数据_MESWORK',
param: '角色功能=' + code1 + '&角色编号=' + num1
}
})
}

View File

@@ -0,0 +1,151 @@
import request from '@/utils/request.js'
// 查询项目名称
export function dialogtablevisible() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_部门关系_查询节点',
param: '子节点=0'
}
})
}
export function dialogtablevisible1() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_部门关系_查询节点',
param: '子节点=0'
}
})
}
export function addData1(code, groupNum) {
return request({
url: '',
method: 'post',
data: {
type: 2,
name: '菜单系统模块_项目角色员工综合_增加数据',
param: '人员编号=' + code + '=int&角色编号=' + groupNum + '=int&项目编号=10=int'
}
})
}
export function addData2(lsh, code, groupNum) {
return request({
url: '',
method: 'post',
data: {
type: 2,
name: '菜单系统模块_项目角色员工综合_修改数据',
param: '人员角色流水号=' + lsh + '&人员编号=' + code + '&角色编号=' + groupNum
}
})
}
// 初始化科室
export function initDepartment() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_部门关系_查询节点'
}
})
}
// 初始化人员信息 弹出框
export function getTree() {
return request({
url: '',
method: 'post',
data: {
type: 1,
name: '人事档案管理_部门关系_查询节点',
param: '子节点=0=int'
}
})
}
export function fn(data, pid) {
const result = []
let temp
for (let i = 0; i < data.length; i++) {
if (data[i].父节点 === pid) {
const obj = { label: data[i].节点名称, id: data[i].子节点 }
temp = fn(data, data[i].子节点)
if (temp.length > 0) {
obj.children = temp
}
result.push(obj)
}
}
return result
}
export function getTable8(code) {
return request({
url: '',
method: 'post',
data: {
type: 1,
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=' + code + '=int'
}
})
}
export function handledelete(ryjslsh) {
return request({
url: '',
method: 'post',
data: {
type: 2,
name: '菜单系统模块_项目角色员工综合_删除数据',
param: '人员角色流水号=' + ryjslsh + '=string'
}
})
}
export function deleteData(Number) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '菜单系统模块_项目角色员工综合_删除数据',
param: '人员角色流水号=' + Number + '=int'
}
})
}
export function searchdesigner(num2) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=' + num2 + '=int'
}
})
}
export function initOrderType() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '菜单系统模块_项目角色_查询数据_new'
}
})
}
export function searchTable(check1, staffName, check2, systemAdministrator, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '菜单系统模块_项目角色员工综合_查询数据',
param: '姓名_check=' + check1 + '=int&姓名=' + staffName + '=string&角色编号_check=' + check2 + ' =int&角色编号=' + systemAdministrator + '=int',
Pagination: pageCurrent + '&' + pageSize
}
})
}

View File

@@ -0,0 +1,157 @@
import request from '@/utils/request'
// 查工艺分类名称
export function searchProcessClassification(ProcessClassification) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_基础表_工艺分类名称_查询数据',
param: '工艺分类名称=' + ProcessClassification
}
})
}
// 增加工艺分类
export function addProcessClassification(ProcessClassification) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_基础表_工艺分类名称_增加数据',
param: '工艺分类名称=' + ProcessClassification
}
})
}
// 编辑工艺分类
export function editProcessClassification(ProcessClassificationNum, ProcessClassification) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_基础表_工艺分类名称_修改数据',
param: '工艺分类流水号=' + ProcessClassificationNum + '&工艺分类名称=' + ProcessClassification
}
})
}
// 通过工艺编分类流水号查工艺分类名称
export function searchProcessClassificationOfProcessClassificationNum(ProcessNum) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_基础表_工艺分类名称_根据流水号_查询数据_MESWORK',
param: '工艺分类流水号=' + ProcessNum
}
})
}
// 删除工艺分类
export function delProcessClassification(ProcessClassificationNum) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_基础表_工艺分类名称_删除数据',
param: '工艺分类流水号=' + ProcessClassificationNum
}
})
}
// 通过工艺分类流水号查工艺名称
export function searchProcessNameOfProcessClassification(ProcessClassificationNum) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_基础表_工艺名称_查询数据_按工艺分类流水号查_MESWORK',
param: '工艺分类流水号=' + ProcessClassificationNum
}
})
}
// 通过工艺编号查工艺要求
export function searchTechnologicalRequirementsOfProcessNum(ProcessNum) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理_基础表_工艺要求_查询数据',
param: '工艺编号=' + ProcessNum
}
})
}
// 增加工艺
export function addProcess(ProcessClassificationNum, ProcessName, ShortName) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: 'dbo.车间生产管理工艺_基础表_工艺名称_增加数据',
param: '工艺分类流水号=' + ProcessClassificationNum + '&工艺名称=' + ProcessName + '&工艺名称简称=' + ShortName
}
})
}
// 编辑工艺
export function editProcess(ProcessClassificationNum, ProcessName, ShortName) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_基础表_工艺名称_修改名称及简称',
param: '工艺编号=' + ProcessClassificationNum + '&工艺名称=' + ProcessName + '&工艺名称简称=' + ShortName
}
})
}
// 删除工艺
export function delProcess(ProcessNum) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理工艺_基础表_工艺名称_删除数据',
param: '工艺编号=' + ProcessNum
}
})
}
// 新增工艺要求
export function addTechnologicalRequirements(ProcessClassificationNum, ProcessName) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理_基础表_工艺要求_增加数据',
param: '工艺编号=' + ProcessClassificationNum + '&工艺要求=' + ProcessName
}
})
}
// 编辑工艺要求
export function editTechnologicalRequirements(ProcessClassificationNum, ProcessName) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理_基础表_工艺要求_修改数据',
param: '工艺要求流水号=' + ProcessClassificationNum + '&工艺要求=' + ProcessName
}
})
}
// 删除工艺要求
export function delTechnologicalRequirements(ProcessClassificationNum) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '车间生产管理_基础表_工艺要求_删除数据',
param: '工艺要求流水号=' + ProcessClassificationNum
}
})
}

View File

@@ -0,0 +1,97 @@
import request from '@/utils/request'
// 初始化设备名称
export function getEquipment(id, equipmentNum) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '设备管理_设备名称与班次关系_查询数据',
param: `查询代码=${id}=int&设备流水号=${equipmentNum}`
}
})
}
export function getDepartment() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '设备管理_部门查询'
}
})
}
export function getTablePeople(number) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: `考核部门编号=${number}`
}
})
}
export function getTableData(equipmentCheck, equipmentNameValue, operatorCheck, operatorNumber, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '设备管理_设备名称_人员关系_查询数据',
param: `设备流水号_check=${equipmentCheck}&设备流水号=${equipmentNameValue}&操作者编号_check=${operatorCheck}&操作者编号=${operatorNumber}`,
pagination: pageCurrent + '&' + pageSize
}
})
}
export function deleteTable(number) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '设备管理_设备名称_人员关系_删除数据',
param: '设备人员关系流水号=' + number + '=int'
}
})
}
export function getStaff() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '设备管理_基础表_班次表_查询班次'
}
})
}
export function addTable(equipmentNumber, equipment, shift, operator, operatorNumber) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '设备管理_设备名称_人员关系_增加数据',
param: '设备流水号=' + equipmentNumber + '=int&设备名称=' + equipment + '=string&班次代码=' + shift + '=int&操作者=' + operator + '=string&操作者编号=' + operatorNumber + '=int'
}
})
}
export function editTable(equipment, equipmentNumber, shift, operator, operatorNumber, Number) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '设备管理_设备名称_人员关系_修改数据',
param: '设备流水号=' + equipmentNumber + '=int&设备名称=' + equipment + '=string&班次代码=' + shift + '=int&操作者=' + operator + '=string&操作者编号=' + operatorNumber + '=int&设备人员关系流水号=' + Number + '=int'
}
})
}

View File

@@ -59,14 +59,14 @@ export function searchContractDetail(contractnumber) {
}) })
} }
// 直达件查询 // 直达件查询
export function searchDirectPart(pageCurrent, pageSize, project_check, project, machine_check, machine, group_check, group, contract) { export function searchDirectPart(pageCurrent, pageSize, project_check, project, machine_check, machine, group_check, group, contract_check, contract) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '库存管理_直达件_零件查询', name: '库存管理_直达件_零件查询',
param: '项目流水号_check=' + project_check + '&项目流水号=' + project + '&机床流水号_check=' + machine_check + '&机床流水号=' + machine + '&组件流水号_check=' + group_check + '&组件流水号=' + group + '&合同流水号=' + contract, param: '项目流水号_check=' + project_check + '&项目流水号=' + project + '&机床流水号_check=' + machine_check + '&机床流水号=' + machine + '&组件流水号_check=' + group_check + '&组件流水号=' + group + '&合同流水号_check=' + contract_check + '&合同流水号=' + contract,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
}) })
@@ -79,7 +79,7 @@ export function searchPeople() {
data: { data: {
type: '1', type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号', name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=' + 18 param: '考核部门编号=18'
} }
}) })
} }

View File

@@ -0,0 +1,48 @@
import request from '@/utils/request'
// 查询零件入库情况
export function searchTable(partnumber) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: 'MES_机加工MES_库存管理_入库模块_零件基础信息查询_根据零件图号',
param: '零件图号=' + partnumber + '=string'
}
})
}
// 仓库查询
export function getinventory() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '库存管理_货位主文件_仓库查询'
}
})
}
// 货位查询
export function getlocate(housenumber) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '库存管理_货位主文件_查询数据',
param: '仓库流水号=' + housenumber + '=int'
}
})
}
// 修改入库数量
export function insertOne(num0, num1, people, num4, num5, num6, num7) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: 'MES_机加工MES_库存管理_入库模块_增加入库信息_修改入库数量',
param: '工艺计划流水号=' + num0 + '=int&入库数量=' + num1 + '=int&收件人员编号=' + people + '=int&送件人员编号=1001' + '&漆塑=' + num4 + '&仓库流水号=' + num5 + '&货位流水号=' + num6 + '&备注=' + num7
}
})
}

View File

@@ -171,4 +171,29 @@ export function searchGeneralPart(pageCurrent, pageSize, project_check, project,
} }
}) })
} }
// 车间采购基本件查询
export function searchHourseBasicPart(pageCurrent, pageSize, project_check, project, machine_check, machine, group_check, group) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '库存管理_库存盘点_车间采购基本件查询',
param: '项目流水号_check=' + project_check + '&项目流水号=' + project + '&机床流水号_check=' + machine_check + '&机床流水号=' + machine + '&组件流水号_check=' + group_check + '&组件流水号=' + group,
Pagination: pageCurrent + '&' + pageSize
}
})
}
// 车间采购外购件查询
export function searchHoursePurchasePart(pageCurrent, pageSize, project_check, project, machine_check, machine, group_check, group) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '库存管理_库存盘点_车间采购外购件查询',
param: '项目流水号_check=' + project_check + '&项目流水号=' + project + '&机床流水号_check=' + machine_check + '&机床流水号=' + machine + '&组件流水号_check=' + group_check + '&组件流水号=' + group,
Pagination: pageCurrent + '&' + pageSize
}
})
}

View File

@@ -1,14 +1,14 @@
import request from '@/utils/request' import request from '@/utils/request'
// 领料单查询 // 领料单查询
export function searchList(listNumber) { export function searchList(listNumber_check, listNumber) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '车间装配管理_领料单_领料单查询', name: '车间装配管理_领料单_领料单查询',
param: '领料单编号=' + listNumber param: '领料单编号_check=' + listNumber_check + '&领料单编号=' + listNumber
} }
}) })
} }
@@ -24,6 +24,18 @@ export function searchListDetail(listNumber) {
} }
}) })
} }
// 领料单明细出库
export function ListDetailOut(listNumber) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间装配管理_领料单_领料单明细出库',
param: '领料单明细流水号=' + listNumber
}
})
}
// 外购件零件出库 // 外购件零件出库
export function PurchasePart(data1, data2, data3, data4, data5) { export function PurchasePart(data1, data2, data3, data4, data5) {
return request({ return request({

View File

@@ -75,18 +75,19 @@ export function searchHoursePart(pageCurrent, pageSize, project_check, project,
}) })
} }
// 领料单查询 // 领料单查询
export function searchList(pageCurrent, pageSize, listNumber) { export function searchList(pageCurrent, pageSize, listNumber_check, listNumber) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '车间装配管理_领料单_领料单查询', name: '车间装配管理_领料单_领料单查询',
param: '领料单编号=' + listNumber, param: '领料单编号_check=' + listNumber_check + '&领料单编号=' + listNumber,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
}) })
} }
// 领料单明细查询 // 领料单明细查询
export function searchListDetail(listNumber) { export function searchListDetail(listNumber) {
return request({ return request({
@@ -136,14 +137,14 @@ export function dropListDetail(DetailNumberx) {
}) })
} }
// 增加领料单明细 // 增加领料单明细
export function addListDetail(PickingListNumberx, projectnumber, machinenumber, teamNumber, project, machine, team, materialName, materialNumber, materialType, outNumber, partType, Note, data1, data2, data3, data4, data5) { export function addListDetail(PickingListNumberx, projectnumber, machinenumber, teamNumber, project, machine, team, materialName, materialNumber, materialType, outNumber, partType, Note, data1, data2, data3, data4, data5, data6, data7) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '2', type: '2',
name: '车间装配管理_领料单_领料单明细增加', name: '车间装配管理_领料单_领料单明细增加',
param: '领料单流水号=' + PickingListNumberx + '&项目流水号=' + projectnumber + '&机床流水号=' + machinenumber + '&组件流水号=' + teamNumber + '&项目名称=' + project + '&机床名称=' + machine + '&组件名称=' + team + '&物料名称=' + materialName + '&物料型号=' + materialNumber + '&物料规格=' + materialType + '&出库数量=' + outNumber + '&零件类型=' + partType + '&备注=' + Note + '&工艺计划流水号=' + data1 + '&收件信息ID=' + data2 + '&组件零件流水号=' + data3 + '&采购合同明细流水号=' + data4 + '&货位流水号=' + data5 param: '领料单流水号=' + PickingListNumberx + '&项目流水号=' + projectnumber + '&机床流水号=' + machinenumber + '&组件流水号=' + teamNumber + '&项目名称=' + project + '&机床图号=' + machine + '&组=' + team + '&物料名称=' + materialName + '&物料型号=' + materialNumber + '&物料规格=' + materialType + '&出库数量=' + outNumber + '&零件类型=' + partType + '&备注=' + Note + '&工艺计划流水号=' + data1 + '&收件信息ID=' + data2 + '&组件零件流水号=' + data3 + '&采购合同明细流水号=' + data4 + '&货位流水号=' + data5 + '&车间外购=' + data6 + '&物料与货位对照流水号=' + data7
} }
}) })
} }

View File

@@ -1,12 +1,13 @@
import request from '@/utils/request' import request from '@/utils/request'
// 替换单查询 // 替换单查询
export function searchSubstitutedCard() { export function searchSubstitutedCard(...params) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '库存管理_替换件_替换单查询' name: '库存管理_替换件_替换单查询',
param: `替换单编号_check=${params[0]}&替换单编号=${params[1]}&替换件名称_check=${params[2]}&替换件名称=${params[3]}`
} }
}) })
} }

View File

@@ -44,3 +44,27 @@ export function searchTable(check, entryNameValue, check1, machine, check2, grou
} }
}) })
} }
export function searchPurchaseTable(check, entryNameValue, check1, machine, check2, groupNum, check3, year, check4, month, check5, time, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_外购件成组配套_查询数据',
param: '项目流水号_check=' + check + '=int&项目流水号=' + entryNameValue + '=int&机床流水号_check=' + check1 + '=int&机床流水号=' + machine + '=int&组件流水号_check=' + check2 + '=int&组件流水号=' + groupNum + '=int&年_check=' + check3 + '=int&年=' + year + '=string&月_check=' + check4 + '=int&月=' + month + '=int&入库时间_check=' + check5 + '=int&入库时间=' + time + '=string',
pagination: pageCurrent + '&' + pageSize
}
})
}
export function searchTable1(check, entryNameValue, check1, machine, check2, groupNum, check3, year, check4, month, check5, time, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '库存管理_车间采购出库_零件查询',
param: '项目流水号_check=' + check + '=int&项目流水号=' + entryNameValue + '=int&机床流水号_check=' + check1 + '=int&机床流水号=' + machine + '=int&组件流水号_check=' + check2 + '=int&组件流水号=' + groupNum + '=int&年_check=' + check3 + '=int&年=' + year + '=string&月_check=' + check4 + '=int&月=' + month + '=int&入库时间_check=' + check5 + '=int&入库时间=' + time + '=string',
pagination: pageCurrent + '&' + pageSize
}
})
}

View File

@@ -0,0 +1,62 @@
import request from '@/utils/request'
// 初始化工艺员
export function initCraftmen() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=17'
}
})
}
// 根据工艺员查零件
export function searchPart(person) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_在制零件工艺调整_被调整零件查询',
param: '工艺人员编号=' + person
}
})
}
// 根据零件查工艺 旧
export function searchProcessOld(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_在制零件工艺调整_查询工艺',
param: '工艺计划流水号=' + num
}
})
}
// 根据零件查工艺 新
export function searchProcessNew(num) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_零件工序_查询工序信息',
param: '工艺计划流水号=' + num
}
})
}
// 查询各工艺员调整工艺情况
export function searchChart() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间生产管理工艺_在制零件工艺调整_被调整零件数量查询'
}
})
}

View File

@@ -174,7 +174,7 @@ export function initPerson() {
data: { data: {
type: '1', type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号', name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=17=int' param: '考核部门编号=17'
} }
}) })
} }

View File

@@ -235,7 +235,7 @@ export function updateDate(num1, num2, date) {
method: 'post', method: 'post',
data: { data: {
type: '2', type: '2',
name: '车间生产管理工艺_新排产算法_制定计划_调整计划_增加数据New', name: '车间生产管理工艺_新排产算法_制定计划_调整计划_增加数据New1',
param: '工序流水号=' + num1 + '&调整人编号=' + num2 + '&调整计划完成日期=' + date param: '工序流水号=' + num1 + '&调整人编号=' + num2 + '&调整计划完成日期=' + date
} }
}) })

View File

@@ -23,14 +23,15 @@ export function getPartsName(num) {
}) })
} }
export function getTableData(partsCategoriesCheck, partsCategories, partsNameCheck, partsName) { export function getTableData(pageCurrent, pageSize, partsCategoriesCheck, partsCategories, partsNameCheck, partsName) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '车间生产管理工艺_基础表_典型工艺名称_查询数据_综合查询', name: '车间生产管理工艺_基础表_典型工艺名称_查询数据_综合查询',
param: `典型工艺名称分类流水号_check=${partsCategoriesCheck}&典型工艺名称分类流水号=${partsCategories}&典型工艺流水号_check=${partsNameCheck}&典型工艺流水号=${partsName}&典型工艺流水号1_check=0` param: `典型工艺名称分类流水号_check=${partsCategoriesCheck}&典型工艺名称分类流水号=${partsCategories}&典型工艺流水号_check=${partsNameCheck}&典型工艺流水号=${partsName}&典型工艺流水号1_check=0`,
Pagination: pageCurrent + '&' + pageSize
} }
}) })
} }

View File

@@ -6,7 +6,7 @@ export function getData(check, equipmentName, pageCurrent, pageSize) {
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '设备管理_设备加工能力_查询数据_设备维护', name: '设备管理_设备加工能力_查询数据_设备维护NEW',
param: '设备名称_check=' + check + '=int&设备名称=' + equipmentName, param: '设备名称_check=' + check + '=int&设备名称=' + equipmentName,
pagination: pageCurrent + '&' + pageSize pagination: pageCurrent + '&' + pageSize
} }

View File

@@ -87,6 +87,16 @@ export function searchProjectNumber() {
} }
}) })
} }
export function searchProjectNumber2() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '合同信息管理_项目名称_总_查询_增加限制'
}
})
}
export function searchProjectName(num1) { export function searchProjectName(num1) {
return request({ return request({
url: '', url: '',

View File

@@ -0,0 +1,257 @@
import request from '@/utils/request'
// 初始化形目名称
export function searchProjectName() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_总装箱单_查询'
}
})
}
// 查询装箱单总单据信息
export function searchPackingList() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_总装箱单_查询_通过编号',
param: '装箱单编号=' + arguments[0]
}
})
}
// 查询备件
export function searchSparePart() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_备件_查询数据',
param: '装箱单编号=' + arguments[0]
}
})
}
// 查询随机文件
export function searchFile() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_随机文件_查询数据',
param: '装箱单编号=' + arguments[0]
}
})
}
// 查询主机
export function searchHost() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_主机_查询数据',
param: '装箱单编号=' + arguments[0]
}
})
}
// 查询机床所属部件
export function searchParts() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_机床所属部件_查询数据',
param: '代号=' + arguments[0]
}
})
}
// 查询发货单
export function searchInvoice() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_发货单_查询数据',
param: '装箱单编号=' + arguments[0]
}
})
}
// 收货地址初始化
export function addressSearch(pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_收货地址查询',
Pagination: pageCurrent + '&' + pageSize
}
})
}
// 省份初始化
export function provinceSearch() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_省份查询'
}
})
}
export function citySearch(num1) {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_市名查询_根据省流水号',
param: '省份流水号=' + num1
}
})
}
export function deleteAdress(num1) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_收货地址删除',
param: '收货地址流水号=' + num1
}
})
}
export function addAdress(num1, num2, num3, num4, num5) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_收货地址增加',
param: '省份流水号=' + num1 + '&市流水号=' + num2 + '&详细地址=' + num3 + '&联系人=' + num4 + '&联系方式=' + num5
}
})
}
export function editAdress(num1, num2, num3, num4, num5, num6) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_收货地址修改',
param: '省份流水号=' + num1 + '&市流水号=' + num2 + '&详细地址=' + num3 + '&联系人=' + num4 + '&联系方式=' + num5 + '&收货地址流水号=' + num6
}
})
}
export function addInvoice() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_发货单_增加数据',
param: '装箱单编号=' + arguments[0] + '&车辆牌号=' + arguments[1] + '&运输状态=' + arguments[2] + '&收货地址流水号=' + arguments[3] + '&发货日期=' + arguments[4]
}
})
}
export function delInvoice() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_发货单_删除数据',
param: '发货单编号=' + arguments[0]
}
})
}
export function editInvoice() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_发货单_修改数据',
param: '车辆牌号=' + arguments[0] + '&运输状态=' + arguments[1] + '&收货地址流水号=' + arguments[2] + '&发货日期=' + arguments[3] + '&发货单编号=' + arguments[4]
}
})
}
export function searchCargoBox() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_货箱号_查询数据',
param: '发货单编号=' + arguments[0]
}
})
}
export function addCargoBox() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_货箱号_增加数据',
param: '发货单编号=' + arguments[0]
}
})
}
export function delCargoBox() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_货箱号_删除数据',
param: '货箱号编号=' + arguments[0]
}
})
}
export function submitMoveInto() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_货箱明细_移入',
param: '货箱号编号=' + arguments[0] + '&代号=' + arguments[1] + '&名称=' + arguments[2] + '&规格=' + arguments[3] + '&数量=' + arguments[4] + '&备注=' + arguments[5] + '&部件编号=' + arguments[6] + '&@备件编号=' + arguments[7] + '&文件编号=' + arguments[8]
}
})
}
export function searchCargoBoxDetailed() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '发货管理_货箱明细_查询',
param: '货箱号编号=' + arguments[0]
}
})
}
export function submitRremove() {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '发货管理_货箱明细_移除',
param: '货箱明细编号=' + arguments[0] + '&数量=' + arguments[1] + '&部件编号=' + arguments[2] + '&备件编号=' + arguments[3] + '&文件编号=' + arguments[4] + '&货箱号编号=' + arguments[5]
}
})
}

View File

@@ -20,7 +20,7 @@ export function searchTable1(pageCurrent, pageSize, check1, start, end, check2,
data: { data: {
type: '1', type: '1',
name: '采购管理_请款表_查询数据', name: '采购管理_请款表_查询数据',
param: '时间段_check=' + check1 + '&开始时间=' + start + '&结束时间=' + end + '&合同号_check=' + check2 + '&采购合同编号=' + num1 + '&采购员_check=' + check3 + '&采购员姓名=' + name1 + '&供应商_check=' + check4 + '&供应商名称=' + name2, param: '时间段_check=' + check1 + '&开始时间=' + start + '&结束时间=' + end + '&合同号_check=' + check2 + '&采购合同编号=' + num1 + '&采购员_check=' + check3 + '&采购员流水号=' + name1 + '&供应商_check=' + check4 + '&供应商名称=' + name2,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
}) })

View File

@@ -0,0 +1,197 @@
import request from '@/utils/request'
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
}
})
}

View File

@@ -168,3 +168,15 @@ export function searchContractDemo(num1 = null) {
} }
}) })
} }
// 设置安全库存
export function setSafeValue(...params) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '采购管理_离线合同_物料安全库存_修改数据',
param: `物料流水号=${params[0]}&安全库存量=${params[1]}`
}
})
}

View File

@@ -47,4 +47,15 @@ export function allocateTask(group, person) {
param: `标准件和外购件流水号组=${group}&人员编号=${person}` param: `标准件和外购件流水号组=${group}&人员编号=${person}`
} }
}) })
}// 执行退回
export function executeReturn(...params) {
return request({
url: '',
method: 'post',
data: {
type: '2',
name: '采购部采购_退回物料',
param: `标准件和外购件流水号组=${params[0]}&组件零件流水号组=${params[1]}`
}
})
} }

View File

@@ -49,8 +49,8 @@ export function deleteInvoice(num1) {
} }
}) })
} }
// 传送人接收人初始化 采购科改16 // 传送人初始化 采购科改16
export function initPerson() { export function initSender() {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
@@ -61,6 +61,18 @@ export function initPerson() {
} }
}) })
} }
// 接收人初始化 财务部7
export function initReceiver() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '人事档案管理_人员_部门与人员_查询数据_根据部门编号',
param: '考核部门编号=7'
}
})
}
// 初始化合同号 // 初始化合同号
export function initContract() { export function initContract() {
return request({ return request({

View File

@@ -8,7 +8,7 @@ export function searchTable1(pageCurrent, pageSize, check1, start, end, check2,
data: { data: {
type: '1', type: '1',
name: '车间采购管理_请款表_查询数据', name: '车间采购管理_请款表_查询数据',
param: '时间段_check=' + check1 + '&开始时间=' + start + '&结束时间=' + end + '&合同号_check=' + check2 + '&采购合同编号=' + num1 + '&采购员_check=' + check3 + '&采购员姓名=' + name1 + '&供应商_check=' + check4 + '&供应商名称=' + name2, param: '时间段_check=' + check1 + '&开始时间=' + start + '&结束时间=' + end + '&合同号_check=' + check2 + '&采购合同编号=' + num1 + '&采购员_check=' + check3 + '&采购员流水号=' + name1 + '&供应商_check=' + check4 + '&供应商名称=' + name2,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
}) })

View File

@@ -7,7 +7,7 @@ export function initContract() {
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '采购管理_采购合同_查询_cjn' name: '车间采购管理_采购合同_查询_cjn'
} }
}) })
} }

View File

@@ -7,7 +7,7 @@ export function initContract() {
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '采购管理_采购合同_查询_cjn' name: '车间采购管理_采购合同_查询_cjn'
} }
}) })
} }

View File

@@ -11,6 +11,17 @@ export function initContract() {
} }
}) })
} }
// 初始化合同号
export function initContract1() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '车间采购管理_采购合同变更_合同初始化'
}
})
}
// 初始化采购员(考核部门编号采购部2) // 初始化采购员(考核部门编号采购部2)
export function initBuyer() { export function initBuyer() {
return request({ return request({
@@ -56,7 +67,7 @@ export function searchTable3(pageCurrent, pageSize, check1, start, end, check2,
data: { data: {
type: '1', type: '1',
name: '车间采购管理_采购合同变更_查询数据_根据条件_cjn', name: '车间采购管理_采购合同变更_查询数据_根据条件_cjn',
param: '时间段_check=' + check1 + '&开始时间=' + start + '=datetime&结束时间=' + end + '=datetime&采购合同流水号_check=' + check2 + '&采购合同流水号=' + contract + '&人员编号_check=' + check3 + '&人员编号=' + name + '&供应商名称_check=' + check4 + '&供应商名称=' + supplier, param: '时间段_check=' + check1 + '&开始时间=' + start + '=datetime&结束时间=' + end + '=datetime&采购合同变更流水号_check=' + check2 + '&采购合同变更流水号=' + contract + '&人员编号_check=' + check3 + '&人员编号=' + name + '&供应商名称_check=' + check4 + '&供应商名称=' + supplier,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
}) })

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Svg Vector Icons : http://www.sfont.cn -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 1000 1000" enable-background="new 0 0 1000 1000" xml:space="preserve">
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
<g><g transform="translate(0.000000,511.000000) scale(0.100000,-0.100000)"><path d="M2005.1,2538.4c-82.4-44.1-145.6-122.6-166.7-201.2l-19.2-82.4h-364c-358.3,0-362.1,0-408.1-47.9c-63.2-61.3-65.1-164.8-5.7-220.3c40.2-38.3,61.3-38.3,1212.8-38.3h1172.6l40.2-44.1c59.4-63.2,53.7-137.9-13.4-206.9l-55.6-55.6H1938H480l-46-47.9c-47.9-46-65.1-147.5-32.6-193.5c40.2-63.2,95.8-65.1,1343.1-65.1c1222.4,0,1247.3,0,1285.6-38.3c59.4-59.4,51.7-159-21.1-218.4l-59.4-49.8H1869H786.5l-46-47.9c-67.1-65.1-65.1-164.8,1.9-218.4c49.8-40.2,65.1-40.2,1419.7-40.2c927.3,0,1381.4-5.7,1406.3-21.1c55.6-28.7,76.6-99.6,53.6-170.5c-42.1-118.8,30.7-115-1774.2-115c-1737.8-1.9-1678.4,1.9-1726.3-90.1C89.1,266.1,93,216.3,135.1,164.6l36.4-46l1212.8-9.6l1210.9-9.6l36.4-49.8c53.6-70.9,32.6-160.9-47.9-210.8c-55.6-32.6-101.6-36.4-515.4-36.4c-251,0-456-5.7-456-13.4c0-9.6-23-274-49.8-588.2c-69-793.2-88.1-764.5,473.2-774l356.4-7.7l32.6,137.9c143.7,641.9,860.3,1021.2,1421.7,754.9c160.9-74.7,321.9-235.7,400.4-398.5c63.2-128.4,116.9-362.1,101.5-446.4c-5.7-32.6,51.7-34.5,1544.3-34.5h1550l24.9,124.5c36.4,176.3,126.5,346.8,258.7,488.6c195.4,208.8,429.2,325.7,695.5,346.8c525,46,969.5-360.2,969.5-883.3c0-84.3,1.9-86.2,63.2-86.2c143.7,0,274,76.6,318.1,189.7c30.6,72.8,139.9,1373.7,126.4,1486.8c-21.1,174.4-92,274-578.6,802.8c-400.4,436.8-477.1,513.5-574.8,559.5l-111.1,55.6l-588.2,5.7c-442.6,3.8-590.1,11.5-590.1,28.7c0,13.4,13.4,160.9,28.7,329.6c36.4,388.9,36.4,496.2,0,565.2c-63.2,122.6,118.8,115-2791.6,115C2798.3,2559.5,2031.9,2553.8,2005.1,2538.4z M8613.3,1231.8c47.9-24.9,205-180.1,440.7-436.8c201.2-220.3,367.9-408.1,371.7-417.7c7.7-19.2-1793.3-21.1-1804.8-1.9c-3.8,5.8,9.6,193.5,28.7,413.8c19.2,222.3,36.4,421.5,36.4,446.4v44.1l427.3-5.8C8486.8,1268.2,8548.1,1264.3,8613.3,1231.8z"/><path d="M3250.5-816.4c-321.9-84.3-574.8-348.7-641.9-674.4c-65.1-314.2,90.1-638,371.7-776c385.1-189.7,887.1,1.9,1086.4,415.8c55.6,113,65.1,155.2,70.9,312.3c9.6,235.7-32.6,356.4-180.1,515.4C3781.2-831.8,3505.3-751.3,3250.5-816.4z M3541.7-1215c76.6-28.7,139.9-92,180.1-180.1c47.9-103.5,46-191.6-9.6-308.5c-136-291.2-548-329.5-682.1-65.1c-97.7,191.6-3.8,444.5,201.2,538.4C3317.5-1190,3459.3-1182.4,3541.7-1215z"/><path d="M8281.8-820.2c-419.6-118.8-705.1-538.4-634.2-933.1c88.1-486.7,582.5-726.2,1046.1-505.8c509.7,241.4,661,890.9,295.1,1256.9C8816.3-829.8,8519.4-753.2,8281.8-820.2z M8601.7-1220.7c350.6-183.9,191.6-720.4-214.6-724.2c-111.1-1.9-187.8,30.6-264.4,113c-222.2,233.7-17.2,638,325.7,638C8504-1193.9,8573-1205.4,8601.7-1220.7z"/></g></g>
</svg>

After

Width:  |  Height:  |  Size: 2.9 KiB

View 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="1532937900139" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1990" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M737 942a207 207 0 1 1 207-207 207.234 207.234 0 0 1-207 207z m0-342a135 135 0 1 0 135 135 135.152 135.152 0 0 0-135-135z m-36 60h72v54h40v72H701V660zM508 906H174a96.11 96.11 0 0 1-96-96V174a96.108 96.108 0 0 1 96-96h540a96.11 96.11 0 0 1 96 96v304h-72V174a24.028 24.028 0 0 0-24-24H174a24.028 24.028 0 0 0-24 24v636a24.028 24.028 0 0 0 24 24h334v72zM292.74 464L188 356.624l51.4-50.094 50.814 52.09 98.042-110.632L442 295.566zM666 414H460v-72h206v72zM292.74 716L188 608.624l51.4-50.094 50.814 52.09 98.042-110.632L442 547.566z" p-id="1991" fill="#ffffff"></path></svg>

After

Width:  |  Height:  |  Size: 954 B

View 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="1532937378997" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2118" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M128 384h128v512H128zM320 128h128v768H320zM512 544h128v352H512zM896 576a96 96 0 0 0-64-90.53V576h-64v-90.53a96 96 0 0 0 0 181.06v216.31A13.16 13.16 0 0 0 781.16 896h37.68A13.16 13.16 0 0 0 832 882.84V666.53A96 96 0 0 0 896 576z" p-id="2119" fill="#ffffff"></path></svg>

After

Width:  |  Height:  |  Size: 655 B

View 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="1532937719569" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4070" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M596.48 332.288l-368.64-2.048c-14.336 0-25.6-11.776-25.6-25.6 0-14.336 11.776-25.6 25.6-25.6l368.64 2.048c14.336 0 25.6 11.776 25.6 25.6 0 14.336-11.776 25.6-25.6 25.6zM601.6 521.728l-368.64-2.048c-14.336 0-25.6-11.776-25.6-25.6 0-14.336 11.776-25.6 25.6-25.6l368.64 2.048c14.336 0 25.6 11.776 25.6 25.6 0 14.336-11.776 25.6-25.6 25.6zM471.04 711.168l-235.52-2.048c-14.336 0-25.6-11.776-25.6-25.6s11.776-25.6 25.6-25.6l235.52 2.048c14.336 0 25.6 11.776 25.6 25.6 0 14.336-11.776 25.6-25.6 25.6zM788.992 939.52c-78.848 0-143.36-64.512-143.36-143.36s64.512-143.36 143.36-143.36 143.36 64.512 143.36 143.36-64.512 143.36-143.36 143.36z m0-235.52c-50.688 0-92.16 41.472-92.16 92.16s41.472 92.16 92.16 92.16 92.16-41.472 92.16-92.16-41.472-92.16-92.16-92.16z" p-id="4071"></path><path d="M785.92 683.52c-14.336 0-25.6-11.264-25.6-25.6v-40.96c0-14.336 11.264-25.6 25.6-25.6s25.6 11.264 25.6 25.6v40.96c0 14.336-11.264 25.6-25.6 25.6zM691.712 726.016c-6.656 0-13.312-2.56-18.432-7.68l-29.696-30.72c-9.728-10.24-9.728-26.624 0.512-36.352 10.24-9.728 26.624-9.728 36.352 0.512l29.696 30.72c9.728 10.24 9.728 26.624-0.512 36.352-5.12 4.608-11.264 7.168-17.92 7.168zM652.8 821.76h-40.96c-14.336 0-25.6-11.264-25.6-25.6s11.264-25.6 25.6-25.6h40.96c14.336 0 25.6 11.264 25.6 25.6s-11.264 25.6-25.6 25.6zM663.552 948.736c-6.656 0-13.312-2.56-17.92-7.68-10.24-10.24-10.24-26.112 0-36.352l30.208-30.208c10.24-10.24 26.112-10.24 36.352 0s10.24 26.112 0 36.352l-30.208 30.208c-5.12 5.12-11.776 7.68-18.432 7.68zM791.04 1000.96c-14.336 0-25.6-11.264-25.6-25.6v-46.08c0-14.336 11.264-25.6 25.6-25.6s25.6 11.264 25.6 25.6v46.08c0 14.336-11.264 25.6-25.6 25.6zM916.48 947.712c-6.656 0-13.312-2.56-17.92-7.68l-30.208-30.208c-10.24-10.24-10.24-26.112 0-36.352s26.112-10.24 36.352 0l30.208 30.208c10.24 10.24 10.24 26.112 0 36.352-5.12 5.12-11.776 7.68-18.432 7.68zM970.24 821.76h-46.08c-14.336 0-25.6-11.264-25.6-25.6s11.264-25.6 25.6-25.6h46.08c14.336 0 25.6 11.264 25.6 25.6s-11.264 25.6-25.6 25.6zM884.736 724.992c-6.656 0-13.312-2.56-17.92-7.68-10.24-10.24-10.24-26.112 0-36.352l30.208-30.208c10.24-10.24 26.112-10.24 36.352 0s10.24 26.112 0 36.352l-30.208 30.208c-5.12 5.12-11.776 7.68-18.432 7.68zM317.44 1005.056H38.4c-14.336 0-25.6-11.264-25.6-25.6V35.84c0-14.336 11.264-25.6 25.6-25.6h733.696c14.336 0 25.6 11.264 25.6 25.6v276.992c0 14.336-11.264 25.6-25.6 25.6s-25.6-11.264-25.6-25.6V61.44H64v892.416H317.44c14.336 0 25.6 11.264 25.6 25.6s-11.264 25.6-25.6 25.6z" p-id="4072"></path></svg>

After

Width:  |  Height:  |  Size: 2.8 KiB

View 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="1539331081532" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2108" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M357.856 506.24L230.72 434.4a22.4 22.4 0 0 0-29.664 6.976 19.744 19.744 0 0 0 7.392 27.936l127.136 71.872a22.4 22.4 0 0 0 29.664-6.976 19.776 19.776 0 0 0-7.392-27.968z" p-id="2109"></path><path d="M906.048 407.52c-11.968 0-21.632 9.12-21.632 20.384v251.584l-363.552 193.408V516.544c0-1.568-0.608-2.944-0.928-4.416l371.328-198.272a19.808 19.808 0 0 0-0.96-35.904L508.928 98.272a22.944 22.944 0 0 0-19.328 0L108.224 277.952a19.296 19.296 0 0 0-10.464 23.424 18.336 18.336 0 0 0-1.44 6.752v383.296c0 7.168 3.968 13.76 10.432 17.44l381.376 216.352 0.16 0.064c0.256 0.128 0.576 0.128 0.8 0.288a22.976 22.976 0 0 0 8.608 2.304c0.992 0.064 1.952-0.096 2.944-0.16a22.08 22.08 0 0 0 7.456-1.76c0.608-0.256 1.184-0.128 1.792-0.448l406.816-216.384a20.16 20.16 0 0 0 11.008-17.728v-263.488c-0.032-11.232-9.728-20.384-21.664-20.384zM477.664 871.712L139.488 679.872v-348.8l339.104 181.056c-0.352 1.472-0.928 2.848-0.928 4.416v355.168zM834.656 297.28l-335.392 179.072L163.904 297.28l335.328-158.016L834.656 297.28z" p-id="2110"></path></svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Svg Vector Icons : http://www.sfont.cn -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 1000 1000" enable-background="new 0 0 1000 1000" xml:space="preserve">
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
<g><path d="M667.5,650c4.7,3.4,10.4,5.5,16.7,5.5c15.7,0,28.4-12.7,28.4-28.4c0-9.9-5-18.5-12.7-23.6l0,0c-33.9-23-71.2-41.3-111-54c91.6-47.6,154.3-143.3,154.3-253.7C743.2,138,615.3,10,457.4,10c-157.9,0-285.8,128-285.8,285.8c0,110.4,62.6,206.1,154.2,253.7c-174,55.5-300.2,217.9-301.3,410c0,0.2,0.1,2.5,0.1,2.5c1,14.8,13.2,26.6,28.2,26.6c15.1,0,27.5-11.8,28.5-26.6c0-207.6,168.3-376,376-376c77.8,0,150.1,23.6,210,64.1L667.5,650z M228.7,295.8c0-126.3,102.4-228.7,228.7-228.7c126.3,0,228.7,102.4,228.7,228.7c0,126.3-102.4,228.7-228.7,228.7C331.1,524.5,228.7,422.1,228.7,295.8z"/><path d="M947.9,786.1H827.4V666.6c0-15.2-12.3-27.6-27.6-27.6s-27.6,12.3-27.6,27.6v119.5H652c-15.2,0-27.6,12.3-27.6,27.6c0,15.2,12.3,27.6,27.6,27.6h120.3v121.2c0,15.2,12.3,27.6,27.6,27.6s27.6-12.3,27.6-27.6V841.2h120.5c15.2,0,27.6-12.3,27.6-27.6C975.4,798.4,963.1,786.1,947.9,786.1z"/></g>
</svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Svg Vector Icons : http://www.sfont.cn -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 1000 1000" enable-background="new 0 0 1000 1000" xml:space="preserve">
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
<g><g transform="translate(0.000000,511.000000) scale(0.100000,-0.100000)"><path d="M4391.9,4998.3c-285.2-50.9-482.8-136.5-790.4-342.2c-413.5-275-778.2-686.5-935-1055.2c-120.2-283.1-154.8-456.3-152.8-792.4c0-285.2,20.4-427.8,81.5-590.8c10.2-22.4-2-30.6-50.9-30.6c-40.7,0-85.6-20.4-128.3-59.1c-63.1-57-67.2-67.2-73.3-222c-10.2-203.7,32.6-419.6,138.5-721.1c85.6-246.5,185.4-411.5,266.9-448.2c44.8-20.4,57-46.9,85.6-191.5C2974.1-133.2,3324.5-638.4,3831.7-889c497.1-244.5,994.1-273,1476.9-79.4c529.6,211.8,892.2,666.1,1069.5,1346.5l65.2,250.6l63.2-6.1c85.5-8.2,152.8,50.9,238.3,213.9c132.4,256.7,238.4,660,238.4,914.7c0,160.9-28.5,248.5-101.9,299.4l-40.7,28.5l44.8,252.6c36.7,205.7,44.8,330,46.9,670.2c0,374.8-4.1,433.9-46.9,576.5c-103.9,360.6-287.2,586.7-537.8,666.1c-52.9,16.3-97.8,53-146.7,120.2c-136.5,185.4-325.9,334.1-598.9,470.6c-264.8,132.4-415.6,165-788.4,173.2C4634.4,5012.5,4444.9,5008.4,4391.9,4998.3z"/><path d="M3043.4-901.2c-425.8-291.3-1189.7-643.7-1735.6-802.6c-156.9-44.8-332-105.9-393.2-136.5C607-1989,378.8-2388.3,330-2865l-12.2-132.4l158.9-152.8C1265-3903.9,2340.6-4458,3438.6-4678c509.3-101.9,621.3-112,1263-112c517.4,2,641.7,8.2,886.1,46.8c488.9,77.4,1004.3,218,1432.1,393.2c105.9,42.8,197.6,81.5,201.7,87.6c6.1,4.1-53,71.3-130.4,148.7c-226.1,222-364.6,448.2-464.5,759.8c-73.3,226.1-93.7,637.6-44.8,880c75.4,356.5,248.5,676.3,507.2,935c79.4,79.4,138.5,144.6,136.5,146.7c-4.1,2.1-134.5,67.2-287.2,144.6c-154.8,77.4-372.8,199.6-486.9,270.9c-114.1,71.3-209.8,126.3-209.8,124.2c-2-4-158.9-497-346.3-1095.9c-488.9-1552.3-582.6-1839.5-598.9-1823.2c-8.2,6.1-93.7,238.3-189.5,513.4L4929.7-2757l89.6,138.5c207.8,319.8,299.4,598.9,252.6,770c-55,207.8-270.9,328-588.7,328c-605,0-757.8-387.1-393.2-990c53-89.6,110-179.3,124.3-203.7c26.5-38.7,10.2-97.8-150.7-556.1c-97.8-281.1-187.4-511.3-195.6-511.3c-10.2,0-18.3,4.1-18.3,10.2c0,16.3-914.7,2909-922.8,2915.1C3122.8-852.3,3086.2-872.7,3043.4-901.2z"/><path d="M8022-1530.7c-741.5-201.7-1169.3-992.1-926.9-1711.2c146.7-438,450.2-727.2,906.5-867.8c191.5-59.1,493-63.2,692.6-10.2c220,59.1,440,187.4,600.9,348.3c163,165,254.6,309.6,332,523.5c46.9,130.4,53,179.3,55,413.5c0,224.1-8.1,287.3-46.8,407.4c-132.4,401.3-433.9,711-835.2,861.7c-114.1,42.8-179.3,53-401.3,57.1C8209.5-1502.1,8103.5-1508.2,8022-1530.7z M8492.6-1905.5l59.1-59.1v-338.1v-338.2h334.1c323.9,0,338.1-2,393.2-48.9c44.8-38.7,57-65.2,57-134.5s-12.2-95.8-57-134.4c-55-46.9-69.3-48.9-393.2-48.9h-334.1v-338.2v-338.2l-59.1-59.1c-97.8-95.7-236.3-77.4-297.4,42.8c-22.4,44.8-30.5,132.4-30.5,376.9v315.8h-336.1c-332.1,0-338.1,0-387.1,50.9c-38.7,36.7-50.9,71.3-50.9,132.4s12.2,95.7,50.9,132.4c48.9,50.9,55,50.9,387.1,50.9h336.1v315.7c0,403.3,30.5,476.7,199.6,478.7C8413.2-1846.4,8449.8-1862.7,8492.6-1905.5z"/></g></g>
</svg>

After

Width:  |  Height:  |  Size: 3.1 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 5.4 KiB

View File

@@ -79,9 +79,6 @@ export default {
}) })
} }
} }
if (this[carrier].length !== 0) {
this[carrier] = response.data[0][select[0]]
}
}) })
} else { } else {
requestData(param).then(response => { // 这个方法没什么难度,不注释了 requestData(param).then(response => { // 这个方法没什么难度,不注释了
@@ -139,7 +136,7 @@ export default {
// 3接受值数组一般是['table','total','loading']顺序不能变 // 3接受值数组一般是['table','total','loading']顺序不能变
Vue.prototype.getTable = function(requestData, param, e) { Vue.prototype.getTable = function(requestData, param, e) {
requestData(...param).then(response => { requestData(...param).then(response => {
const data = response.data.rows ? response.data.rows : response.data const data = response.data.rows
this[e[0]] = [] this[e[0]] = []
this[e[1]] = 0 this[e[1]] = 0
if (data && data.length > 0) { if (data && data.length > 0) {
@@ -159,9 +156,7 @@ export default {
// console.log('暂无数据') // console.log('暂无数据')
} }
}).then(() => { }).then(() => {
if (this[e[2]]) {
this[e[2]] = false this[e[2]] = false
}
}) })
} }
// 添加表格数据 // 添加表格数据

View File

@@ -10,7 +10,13 @@ export const name = `OP8888`
export const upload = `http://123.56.95.229:8411/submit/uploadFile.ashx` export const upload = `http://123.56.95.229:8411/submit/uploadFile.ashx`
export const download = `http://123.56.95.229:8411/submit/downloadFile.ashx` export const download = `http://123.56.95.229:8411/submit/downloadFile.ashx`
const service = axios.create({ const service = axios.create({
baseURL: `http://192.168.1.122:8411/submit/MESCommonBase.ashx`,
// 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.149:8411/submit/MESCommonBase.ashx`,git
// baseURL: `http://localhost:8411/submit/MESCommonBase.ashx`,
timeout: 1500000 // 请求超时时间 timeout: 1500000 // 请求超时时间
}) })

View File

@@ -11,7 +11,7 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span>机床编号:</span> <span>机床编号:</span>
<el-select v-model="machineNumberValue" placeholder="机床编号" size="small" clearable> <el-select v-model="machineNumberValue" placeholder="机床编号" size="small" filterable clearable>
<el-option <el-option
v-for="item in machineNumber" v-for="item in machineNumber"
:key="item.value" :key="item.value"
@@ -137,7 +137,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-button style="margin-left: 120px;margin-top: 20px" @click="dialogFormVisible = false">取消</el-button> <el-button style="margin-left: 120px;margin-top: 20px" @click="dialogFormVisible = false">取消</el-button>
<el-button type="primary" style="margin-top: 20px" @click="getName">确认</el-button> <el-button :disabled="staffNum===''" type="primary" style="margin-top: 20px" @click="getName">确认</el-button>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>

View File

@@ -143,6 +143,12 @@ export default {
this.projectValue ? this.check = 1 : this.check = 0 this.projectValue ? this.check = 1 : this.check = 0
this.machineNumberValue ? this.check1 = 1 : this.check1 = 0 this.machineNumberValue ? this.check1 = 1 : this.check1 = 0
searchTable(this.check, this.projectValue, this.check1, this.machineNumberValue, this.check2, this.startEndDate[0], this.startEndDate[1], this.pageCurrent, this.pageSize).then(response => { searchTable(this.check, this.projectValue, this.check1, this.machineNumberValue, this.check2, this.startEndDate[0], this.startEndDate[1], this.pageCurrent, this.pageSize).then(response => {
for (let i = 0; i < response.data.rows.length; i++) {
console.log(response.data.rows[i].项目计划完成时间)
if (response.data.rows[i].项目计划完成时间 !== '') {
response.data.rows[i].项目计划完成时间 = (response.data.rows[i].项目计划完成时间).split(' ')[0]
}
}
this.tableData = response.data.rows this.tableData = response.data.rows
this.total = response.data.total this.total = response.data.total
this.loading = false this.loading = false

View File

@@ -38,7 +38,7 @@
<el-button :disabled="disabled" type="primary" size="small" icon="el-icon-cjn-09" @click="saveApprove">保存</el-button> <el-button :disabled="disabled" type="primary" size="small" icon="el-icon-cjn-09" @click="saveApprove">保存</el-button>
<el-checkbox v-model="checked" :disabled="isShow2" size="small" style="margin:10px">是否核准</el-checkbox> <el-checkbox v-model="checked" :disabled="isShow2" size="small" style="margin:10px">是否核准</el-checkbox>
</el-row> </el-row>
<div v-for="(item, index) in dataAll" :key="index" style="margin-bottom: 30px"> <div v-for="(item, key) in dataAll" :key="key" style="margin-bottom: 30px">
<el-table <el-table
:data="item.table1" :data="item.table1"
border border
@@ -231,7 +231,7 @@
<el-button size="small" @click="processCopy1()">工艺拷贝</el-button> <el-button size="small" @click="processCopy1()">工艺拷贝</el-button>
</el-col> </el-col>
</el-row> </el-row>
<div v-for="(item, index) in dataAll1" :key="index" style="margin-bottom: 30px"> <div v-for="(item, key) in dataAll1" :key="key" style="margin-bottom: 30px">
<el-table <el-table
:data="item.table1" :data="item.table1"
border border
@@ -310,7 +310,7 @@
<el-button size="small" @click="processCopy1()">工艺拷贝</el-button> <el-button size="small" @click="processCopy1()">工艺拷贝</el-button>
</el-col> </el-col>
</el-row> </el-row>
<div v-for="(item, index) in dataAll1" :key="index" style="margin-bottom: 30px"> <div v-for="(item, key) in dataAll1" :key="key" style="margin-bottom: 30px">
<el-table <el-table
:data="item.table1" :data="item.table1"
border border
@@ -433,7 +433,8 @@ export default {
machineType: [], machineType: [],
AssemblyTask: '', AssemblyTask: '',
Group: '', Group: '',
GroupNumberValue: [], GroupNumberValue: '',
GroupNumberValue1: '',
GroupNumber: [], GroupNumber: [],
GroupNum: '', GroupNum: '',
GroupProcessNumber: '', GroupProcessNumber: '',
@@ -448,7 +449,6 @@ export default {
Procedure: '', Procedure: '',
ProcedureNameGroup: [], ProcedureNameGroup: [],
processRequestValue: '', processRequestValue: '',
ProcessContentGroup: [],
QualityTesting: [], QualityTesting: [],
ProcessSequence: [], ProcessSequence: [],
tableData: [], tableData: [],
@@ -527,12 +527,11 @@ export default {
}, },
searchGroup() { searchGroup() {
this.GroupNumber = [] this.GroupNumber = []
this.GroupNumberValue = []
searchGroup(this.machineNumberValue).then(response => { searchGroup(this.machineNumberValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.GroupNumber.push({ this.GroupNumber.push({
label: response.data[i].组号, label: response.data[i].组号,
value: response.data[i].组号 value: response.data[i].件流水
}) })
} }
}) })
@@ -670,37 +669,55 @@ export default {
}, },
handleAdd() { handleAdd() {
if (this.machineNumberValue !== '') { if (this.machineNumberValue !== '') {
// this.title = '增加组件工艺' this.addForm('form2', [this.dialogFormVisible4 = true, this.title = '增加组件工艺', this.Group = '', this.GroupNumberValue1 = ''])
this.addForm('form2', [this.dialogFormVisible4 = true, this.title = '增加组件工艺', this.Group = ''])
} else { } else {
this.$message.warning('请先选择机床编号') this.$message.warning('请先选择机床编号')
} }
}, },
handleEdit(row, formName) { handleEdit(row, formName) {
console.log(this.$refs[formName])
if (this.$refs[formName] !== undefined) { if (this.$refs[formName] !== undefined) {
this.$refs[formName].resetFields() this.$refs[formName].resetFields()
} }
// this.editForm(row, 'form2', [this.title = '编辑组件工艺', this.GroupProcessNumber = row.组件工艺流水号, this.dialogFormVisible4 = true, this.Group = '', this.form2.组件 = []]) this.GroupProcessNumber = row.组件工艺流水号
this.GroupNumberValue1 = ''
this.title = '编辑组件工艺' this.title = '编辑组件工艺'
this.dialogFormVisible4 = true this.dialogFormVisible4 = true
this.form2.序号 = row.序号 this.form2.序号 = row.序号
this.form2.装配任务 = row.装配任务 this.form2.装配任务 = row.装配任务
this.Group = '' this.Group = ''
this.form2.组件 = [] console.log(row, 1111)
this.GroupProcessNumber = row.组件工艺流水号 this.form2.组件 = (row.组件流水号.split(',')).map(Number)
console.log(this.form2.组件)
}, },
submitAdd() { submitAdd() {
for (var i = 0; i < this.form2.组件.length; i++) { this.GroupNumberValue1 = this.form2.组件[0]
for (let h = 1; h < this.form2.组件.length; h++) {
this.GroupNumberValue1 += ',' + this.form2.组件[h]
}
for (let i = 0; i < this.form2.组件.length; i++) {
for (let j = 0; j < this.GroupNumber.length; j++) {
if (this.form2.组件[i] === this.GroupNumber[j].value) {
this.form2.组件[i] = this.GroupNumber[j].label
}
}
this.Group += this.form2.组件[i] + '组 ' this.Group += this.form2.组件[i] + '组 '
} }
this.addTable(submitAdd, [this.machineNumberValue, this.form2.序号, this.Group, this.form2.装配任务], 'form2', function() { this.dialogFormVisible4 = false; this.searchDetail() }) this.addTable(submitAdd, [this.machineNumberValue, this.form2.序号, this.Group, this.form2.装配任务, this.GroupNumberValue1], 'form2', function() { this.dialogFormVisible4 = false; this.searchDetail() })
}, },
submitEdit() { submitEdit() {
for (var i = 0; i < this.form2.组件.length; i++) { this.GroupNumberValue1 = this.form2.组件[0]
for (let h = 1; h < this.form2.组件.length; h++) {
this.GroupNumberValue1 += ',' + this.form2.组件[h]
}
for (let i = 0; i < this.form2.组件.length; i++) {
for (let j = 0; j < this.GroupNumber.length; j++) {
if (this.form2.组件[i] === this.GroupNumber[j].value) {
this.form2.组件[i] = this.GroupNumber[j].label
}
}
this.Group += this.form2.组件[i] + '组 ' this.Group += this.form2.组件[i] + '组 '
} }
this.editTable(submitEdit, [this.GroupProcessNumber, this.form2.序号, this.Group, this.form2.装配任务], 'form2', function() { this.searchDetail(); this.dialogFormVisible4 = false }) this.editTable(submitEdit, [this.GroupProcessNumber, this.form2.序号, this.Group, this.form2.装配任务, this.GroupNumberValue1], 'form2', function() { this.searchDetail(); this.dialogFormVisible4 = false })
}, },
deleteGroup(row) { deleteGroup(row) {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', { this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
@@ -766,6 +783,8 @@ export default {
this.dataAll = [] this.dataAll = []
} else { this.$message.error('保存失败') } } else { this.$message.error('保存失败') }
}) })
} else {
this.$message.warning('请勾选是否核准')
} }
}, },
upOne(row) { upOne(row) {

View File

@@ -99,8 +99,8 @@
<td colspan="6">{{ list.工艺内容及装配具体要求 }}</td> <td colspan="6">{{ list.工艺内容及装配具体要求 }}</td>
<td align="center">{{ list.质检 }}</td> <td align="center">{{ list.质检 }}</td>
<td>{{ list.工时 }}</td> <td>{{ list.工时 }}</td>
<td>{{ list.完成情况 }}</td> <td>{{ list.装配员 }}</td>
<td>{{ list.检验情况 }}</td> <td>{{ list.检验 }}</td>
<td width="100px">{{ list.备注 }}</td> <td width="100px">{{ list.备注 }}</td>
</tr> </tr>
</tbody> </tbody>

View File

@@ -0,0 +1,477 @@
<template>
<div class="app-container">
<el-card style="margin-bottom: 20px">
<span>机床分类:</span>
<el-select v-model="machineTypeValue" placeholder="机床分类" size="small" style="width:150px" @change="SearchMachine">
<el-option
v-for="item in machineType"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>机床编号:</span>
<el-select v-model="machineNumberValue1" placeholder="机床编号" size="small" style="width:150px" @change="searchGroup()">
<el-option
v-for="item in machineNumber2"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-button type="success" icon="el-icon-search" style="margin-left: 10px;" size="small" @click="searchDetail">查询</el-button>
<el-button type="primary" size="small" icon="el-icon-tickets" @click="handleAdd">增加</el-button>
<el-button type="danger" size="small" icon="el-icon-delete" @click="deleteTable">删除</el-button>
</el-card>
<el-card style="background-color: #DCDCDC">
<div v-for="(item, key) in dataAll" :key="key" style="margin-bottom: 30px">
<el-table
:data="item.table1"
border
style="width: 100%;margin-top: 15px">
<el-table-column
label="序号"
width="80"
align="center">
<template slot-scope="scope">
{{ scope.row.序号 }}
</template>
</el-table-column>
<el-table-column
label="组号"
width="240"
align="center">
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column
label="装配任务"
align="center">
<template slot-scope="scope">
{{ scope.row.装配任务 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="300">
<template slot-scope="scope">
<el-button
size="mini"
icon="el-icon-edit"
type="primary"
@click="handleEdit(scope.row, 'form2')">编辑</el-button>
<el-button
size="mini"
icon="el-icon-delete"
type="danger"
@click="deleteGroup(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
<el-table :data="item.table2" size="mini" border style="width: 100%">
<el-table-column label="序号" width="90" align="center">
<template slot-scope="scope">
<el-input v-model="scope.row.序号" size="mini" style="width:60px" @change="update(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="工序名称" width="230" align="center">
<template slot-scope="scope">
<el-input
v-model="scope.row.工序名称"
size="mini"
style="width:200px"
@dblclick.native="tableSearch(scope.row)"
@change="update(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="工艺内容及装配具体要求" align="center">
<template slot-scope="scope">
<el-input
v-model="scope.row.工艺内容及装配具体要求"
:rows="1"
size="mini"
type="textarea"
@change="update(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="质检" align="center" width="120">
<template slot-scope="scope">
<el-input v-model="scope.row.质检" size="mini" align="center" @change="update(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="工艺工时" align="center" width="120">
<template slot-scope="scope">
<el-input v-model="scope.row.工艺工时" size="mini" align="center" @change="update2(scope.row)"/>
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="300">
<template slot-scope="scope">
<el-button
size="mini"
icon="el-icon-arrow-up"
type="primary"
@click="upOne(scope.row)"/>
<el-button
size="mini"
icon="el-icon-arrow-down"
type="primary"
@click="downOne(scope.row)"/>
<el-button
size="mini"
icon="el-icon-circle-plus-outline"
type="primary"
@click="insertOne(scope.row)"/>
<el-button
size="mini"
icon="el-icon-delete"
type="danger"
@click="deleteOne(scope.row)"/>
</template>
</el-table-column>
</el-table>
</div>
</el-card>
<el-dialog :visible.sync="dialogFormVisible2" title="工序名称、工序要求选择" center width="400px">
<el-form ref="form1" :model="form1" label-position="left" label-width="125px" class="demo-ruleForm">
<el-form-item label="工序名称分类">
<el-select v-model="processNameClassValue" placeholder="分类" size="small" @change="cChange()">
<el-option
v-for="item in processNameClass"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="工序名称">
<el-select v-model="processNameValue" placeholder="名称" size="small" @change="nChange()">
<el-option
v-for="item in processName"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="工序要求">
<el-input v-model="processRequestValue" placeholder="要求" size="small"/>
</el-form-item>
<el-form-item>
<el-button size="mini" type="primary" @click="confirmSelect()">确定选择</el-button>
</el-form-item>
</el-form>
</el-dialog>
<el-dialog :title="title" :visible.sync="dialogFormVisible4" center width="400px">
<el-form ref="form2" :model="form2" :rules="rules" label-position="left" label-width="125px" class="demo-ruleForm">
<el-form-item label="序号" prop="序号">
<el-input v-model="form2.序号" placeholder="序号" size="small"/>
</el-form-item>
<el-form-item label="组件" prop="组件">
<el-select v-model="form2.组件" multiple placeholder="组件" size="small">
<el-option
v-for="item in GroupNumber"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="装配任务" prop="装配任务">
<el-input v-model="form2.装配任务" placeholder="装配任务" type="textarea" size="small"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible4=false">取消</el-button>
<el-button v-show="title==='增加组件工艺'" type="primary" @click="submitAdd()">确定</el-button>
<el-button v-show="title==='编辑组件工艺'" type="primary" @click="submitEdit()">确定</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { SearchMachine, searchDetail, searchProcess, update, submitAdd, submitEdit, insertOne, update2, upOne, downOne, deleteOne,
deleteGroup, initmachineType, initprocessNameClass, initProcessName, update1, searchGroup } from '@/api/Assembly/TypicalAssemblyMaintenance'
import '@/icon/iconfont.css'
export default {
data() {
return {
title: '',
radio: 0,
checked: false,
number: '',
machineNumberValue1: '',
machineNumber2: [],
machineTypeValue: '',
machineType: [],
AssemblyTask: '',
Group: '',
GroupNumberValue: [],
GroupNumberValue1: '',
GroupNumber: [],
GroupNum: '',
GroupProcessNumber: '',
SerialNumber: '',
SerialNumberGroup: [],
isShow2: false,
processNameClassValue: '',
processNameClass: [],
processNameValue: '',
Process: '',
processName: [],
Procedure: '',
ProcedureNameGroup: [],
processRequestValue: '',
ProcessContentGroup: [],
QualityTesting: [],
ProcessSequence: [],
tableData: [],
tableData1: [],
tableData2: [],
tableData3: [],
loading: false,
form1: {},
form2: {
序号: '',
组件: [],
装配任务: ''
},
rules: {
序号: [{ required: true, message: '请输入序号', trigger: 'blur' }],
组件: [{ required: true, message: '请选择组件', trigger: 'change' }],
装配任务: [{ required: true, message: '请输入装配任务', trigger: 'blur' }]
},
num1: '',
result: 0,
dialogFormVisible2: false,
dialogFormVisible4: false,
dataAll: []
}
},
created() {
this.fetchData()
},
methods: {
fetchData() {
initprocessNameClass().then(response => { // 初始化工序分类
for (let i = 0; i < response.data.length; i++) {
this.processNameClass.push({
label: response.data[i].工序分类名称,
value: response.data[i].工序分类流水号
})
}
})
initmachineType().then(response => { // 初始化机床分类
for (let i = 0; i < response.data.length; i++) {
this.machineType.push({
label: response.data[i].机床分类名称,
value: response.data[i].机床分类流水号
})
}
})
},
SearchMachine() {
this.machineNumberValue1 = ''
this.machineNumber2 = []
SearchMachine(this.machineTypeValue).then(response => { // 典型机床查询
for (let i = 0; i < response.data.length; i++) {
this.machineNumber2.push({
label: response.data[i].机床图号,
value: response.data[i].机床流水号
})
}
})
},
searchGroup() {
this.GroupNumber = []
this.GroupNumberValue = []
searchGroup(this.machineNumberValue1).then(response => {
for (let i = 0; i < response.data.length; i++) {
this.GroupNumber.push({
label: response.data[i].组号,
value: response.data[i].组号
})
}
})
},
async searchDetail() { // 主表查询
this.dataAll = []
if (this.machineNumberValue1 !== '') {
const response = await searchDetail(this.machineNumberValue1)
const data = response.data
for (let i = 0; i < data.length; i++) {
const response2 = await searchProcess(data[i].组件工艺流水号)
this.dataAll.push({
table1: [data[i]],
table2: response2.data
})
}
} else {
this.$message.warning('请先选择机床编号')
}
},
update(row) {
update(row.装配工序流水号, row.序号, row.工序名称, row.工艺内容及装配具体要求, row.质检).then(response => {
console.log(response.data, '工艺要求修改成功', 505)
})
},
update2(row) {
update2(row.装配工序流水号, row.工艺工时).then(response => {
console.log(response.data, '工艺要求修改成功', 505)
})
},
handleAdd() {
if (this.machineNumberValue1 !== '') {
this.addForm('form2', [this.dialogFormVisible4 = true, this.title = '增加组件工艺', this.Group = '', this.GroupNumberValue1 = ''])
} else {
this.$message.warning('请先选择机床编号')
}
},
handleEdit(row, formName) {
if (this.$refs[formName] !== undefined) {
this.$refs[formName].resetFields()
}
this.GroupProcessNumber = row.组件工艺流水号
this.GroupNumberValue1 = ''
this.title = '编辑组件工艺'
this.dialogFormVisible4 = true
this.form2.序号 = row.序号
this.form2.装配任务 = row.装配任务
this.Group = ''
console.log(row, 1111)
this.form2.组件 = (row.组件流水号.split(',')).map(Number)
console.log(this.form2.组件)
},
submitAdd() {
this.GroupNumberValue1 = this.form2.组件[0]
for (let h = 1; h < this.form2.组件.length; h++) {
this.GroupNumberValue1 += ',' + this.form2.组件[h]
}
for (let i = 0; i < this.form2.组件.length; i++) {
for (let j = 0; j < this.GroupNumber.length; j++) {
if (this.form2.组件[i] === this.GroupNumber[j].value) {
this.form2.组件[i] = this.GroupNumber[j].label
}
}
this.Group += this.form2.组件[i] + '组 '
}
this.addTable(submitAdd, [this.machineNumberValue1, this.form2.序号, this.Group, this.form2.装配任务, this.GroupNumberValue1], 'form2', function() { this.dialogFormVisible4 = false; this.searchDetail() })
},
submitEdit() {
this.GroupNumberValue1 = this.form2.组件[0]
for (let h = 1; h < this.form2.组件.length; h++) {
this.GroupNumberValue1 += ',' + this.form2.组件[h]
}
for (let i = 0; i < this.form2.组件.length; i++) {
for (let j = 0; j < this.GroupNumber.length; j++) {
if (this.form2.组件[i] === this.GroupNumber[j].value) {
this.form2.组件[i] = this.GroupNumber[j].label
}
}
this.Group += this.form2.组件[i] + '组 '
}
this.editTable(submitEdit, [this.GroupProcessNumber, this.form2.序号, this.Group, this.form2.装配任务, this.GroupNumberValue1], 'form2', function() { this.searchDetail(); this.dialogFormVisible4 = false })
},
deleteGroup(row) {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteGroup(row.组件工艺流水号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
this.searchDetail()
} else { this.$message.error('删除失败') }
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
insertOne(row) {
insertOne(row.组件工艺流水号).then(response => {})
this.searchDetail()
},
deleteTable() {
this.$confirm('此操作将永久删除该工艺, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.result = 0
for (var i = 0; i < this.dataAll.length; i++) {
deleteGroup(this.dataAll[i].table1[0].组件工艺流水号).then(response => {
this.result += parseInt(response.data[0].result)
if (this.result === this.dataAll.length) {
this.$message.success('删除成功')
this.searchDetail()
}
})
}
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
upOne(row) {
upOne(row.装配工序流水号, row.组件工艺流水号, row.工序顺序).then(response => {})
this.searchDetail()
},
downOne(row) {
downOne(row.装配工序流水号, row.组件工艺流水号, row.工序顺序).then(response => {})
this.searchDetail()
},
deleteOne(row) {
deleteOne(row.装配工序流水号).then(response => {})
this.searchDetail()
},
cChange() {
this.processName = []
initProcessName(this.processNameClassValue).then(response => { // 初始化工序分类
this.tableData = response.data
for (let i = 0; i < response.data.length; i++) {
this.processName.push({
label: response.data[i].工序名称,
value: response.data[i].工序名称流水号
})
}
})
},
nChange() {
for (let i = 0; i < this.tableData.length; i++) {
if (this.processNameValue === this.tableData[i].工序名称流水号) {
this.Process = this.tableData[i].工序名称
this.processRequestValue = this.tableData[i].工艺内容及装配具体要求
}
}
},
tableSearch(row) {
this.dialogFormVisible2 = true
this.processNameClassValue = ''
this.processNameValue = ''
this.processRequestValue = ''
this.Procedure = row.装配工序流水号
this.number = row.序号
},
confirmSelect() {
update1(this.Procedure, this.number, this.Process, this.processRequestValue).then(response => {
if (response.data[0].result === '1') {
this.dialogFormVisible2 = false
this.$message.success('选择成功')
this.searchDetail()
} else {
this.$message.success('选择失败')
}
})
}
}
}
</script>
<style scoped>
span{
margin: 10px 0px 10px 10px;
}
</style>

View File

@@ -0,0 +1,305 @@
<template>
<div class="app-container">
<el-card>
<span>设备名称</span>
<el-input v-model="equipmentName" clearable size="small" style="width:200px;margin:10px;"/>
<el-button type="success" class="el-icon-search" size="small" @click="pageCurrent=1;pageSize=10;searchTable()">查询</el-button>
<el-button type="primary" class="el-icon-circle-plus-outline" size="small" @click="handleAdd('form');param = 0">新增</el-button>
</el-card>
<el-card>
<el-table v-loading="loading" :data="tableData" height="580" style="width: 100%;" border highlight-current-row>
<el-table-column
label=" "
align="center"
type="index"
width="50"/>
<el-table-column label="设备名称" align="center" width="280px">
<template slot-scope="scope">
{{ scope.row.设备名称 }}
</template>
</el-table-column>
<el-table-column label="设备编号" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.设备编号 }}
</template>
</el-table-column>
<el-table-column label="设备型号" align="center" width="280px">
<template slot-scope="scope">
{{ scope.row.设备型号 }}
</template>
</el-table-column>
<el-table-column label="设备性能指标" align="center" width="120px">
<template slot-scope="scope">
{{ scope.row.设备性能指标 }}
</template>
</el-table-column>
<el-table-column label="设备加工能力" align="center" width="140px">
<template slot-scope="scope">
{{ scope.row.设备加工能力工时 }}
</template>
</el-table-column>
<el-table-column label="设备工时系数" align="center" width="120px">
<template slot-scope="scope">
{{ scope.row.设备工时系数 }}
</template>
</el-table-column>
<el-table-column label="设备加工工艺" align="center" width="230px">
<template slot-scope="scope">
{{ scope.row.工艺属性 }}
</template>
</el-table-column>
<el-table-column label="班次类型" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.班次类型 }}
</template>
</el-table-column>
<el-table-column label="整改工时系数" align="center">
<template slot-scope="scope">
{{ scope.row.整改工时比例 }}
</template>
</el-table-column>
<el-table-column label="预留工时系数" align="center" width="150px">
<template slot-scope="scope">
{{ scope.row.设备预留工时系数 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="200px" fixed="right">
<template slot-scope="scope">
<el-button
size="mini"
type="primary"
class="el-icon-edit"
@click="handleEdit(scope.row);param = 1">编辑</el-button>
<el-button
size="mini"
type="danger"
class="el-icon-delete"
@click="handleDelete(scope.$index, scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
<div class="block">
<el-pagination
v-if="!loading"
:current-page="pageCurrent"
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-card>
<el-dialog :title="title" :visible.sync="dialogFormVisible" center width="800px">
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm" style="margin: auto">
<el-row>
<el-col :span="12">
<el-form-item label="设备名称" prop="设备名称">
<el-input v-model="form.设备名称" placeholder="设备名称" clearable size="small" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="设备型号" prop="设备型号">
<el-input v-model="form.设备型号" placeholder="设备型号" clearable size="small" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="性能指标" prop="设备性能指标">
<el-input v-model="form.设备性能指标" placeholder="性能指标" clearable size="small" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="加工能力" prop="设备加工能力工时">
<el-input v-model="form.设备加工能力工时" placeholder="加工能力" clearable size="small" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="整改工时系数" prop="整改工时比例">
<el-input v-model="form.整改工时比例" placeholder="设备整改工时系数" clearable size="small" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="设备编号" prop="设备编号">
<el-input v-model="form.设备编号" placeholder="设备编号" clearable size="small" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="工艺" prop="工艺属性代码">
<el-select v-model="form.工艺属性代码" filterable size="small" style="width:230px;">
<el-option
v-for="item in Technology"
: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.班次类型" filterable size="small" style="width:230px;">
<el-option
v-for="item in ClassType"
: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="工时系数" clearable size="small" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="预留工时系数" prop="设备预留工时系数">
<el-input v-model="form.设备预留工时系数" placeholder="设备预留工时系数" clearable size="small" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff()">取消</el-button>
<el-button v-show="title==='增加'" type="primary" @click="submitAdd()">确定</el-button>
<el-button v-show="title==='编辑'" type="primary" @click="submitEdit()">确定</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { getTechnology, searchtable, edittype, handlechange, handledelete } from '@/api/BasicData/EquipmentCapabilitySetting'
export default {
data() {
return {
equipmentNum: '',
num1: '',
equipmentName: '',
loading: false,
tableData: [], // 表格数据
pageSize: 10,
pageCurrent: 1,
total: 0,
dialogFormVisible: false,
title: '',
Technology: [],
ClassType: [{
value: 0,
label: 0
}, {
value: 1,
label: 1
}, {
value: 2,
label: 2
}, {
value: 3,
label: 3
}, {
value: 4,
label: 4
}],
form: {
设备名称: '', // 设备名称
设备型号: '', // 设备型号
设备性能指标: '', // 性能指标
设备加工能力工时: '', // 加工能力
整改工时比例: '', // 设备整改工时指数
设备编号: '', // 设备编号
工艺属性代码: '', // 工艺
班次类型: '', // 班次类型
设备工时系数: '', // 工时系数
设备预留工时系数: '' // 设备预留工时系数
},
rules: {
设备名称: [{ required: true, message: '请输入设备名称', trigger: 'blur' }],
设备型号: [{ required: true, message: '请输入设备型号', trigger: 'blur' }],
设备性能指标: [{ required: true, message: '请输入性能指标', trigger: 'blur' }],
设备加工能力工时: [{ required: true, message: '请输入加工能力', trigger: 'blur' }],
整改工时比例: [{ required: true, message: '请输入设备整改工时指数', trigger: 'blur' }],
设备编号: [{ required: true, message: '请输入设备编号', trigger: 'blur' }],
工艺属性代码: [{ required: true, message: '请选择工艺', trigger: 'change' }],
班次类型: [{ required: true, message: '请选择班次类型', trigger: 'change' }],
设备工时系数: [{ required: true, message: '请输入工时系数', trigger: 'blur' }],
设备预留工时系数: [{ required: true, message: '请输入设备预留工时系数', trigger: 'blur' }]
}
}
},
created() {
this.searchTable()
this.fetchData()
},
methods: {
// 初始化获取工艺
fetchData() {
this.getSelect(getTechnology, ['工艺名称', '工艺编号'], 'Technology')
},
// 查询
searchTable() {
this.loading = true
this.equipmentName ? this.num1 = 1 : this.num1 = 0
this.getTable(searchtable, [this.pageCurrent, this.pageSize, this.num1, this.equipmentName], ['tableData', 'total', 'loading'])
},
// 点击增加
handleAdd() {
this.dialogFormVisible = true
this.title = '增加'
this.addForm('form')
},
// 增加确定
submitAdd() {
this.addTable(edittype, [this.form.设备名称, this.form.设备型号, this.form.设备性能指标, this.form.设备工时系数, this.form.工艺属性代码, this.form.班次类型, this.form.设备加工能力工时, this.form.整改工时比例, this.form.设备编号, this.form.设备预留工时系数], 'form', function() { this.searchTable(); this.dialogFormVisible = false })
},
// 编辑打开
handleEdit(row) {
this.dialogFormVisible = true
this.title = '编辑'
this.equipmentNum = row.设备流水号
this.editForm(row, 'form')
},
// 编辑确定
submitEdit() {
this.editTable(handlechange, [this.equipmentNum, this.form.设备名称, this.form.设备型号, this.form.设备性能指标, this.form.设备工时系数, this.form.工艺属性代码, this.form.班次类型, this.form.设备加工能力工时, this.form.整改工时比例, this.form.设备编号, this.form.设备预留工时系数], 'form', function() { this.searchTable(); this.dialogFormVisible = false })
},
// 重置表单
callOff() {
this.dialogFormVisible = false
},
// 删除
handleDelete(index, row) {
this.deleteRow(handledelete, row.设备流水号, function() { this.searchTable() })
},
// 分页
handleSizeChange(val) {
this.pageCurrent = 1
this.pageSize = val
this.searchTable()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.searchTable()
}
}
}
</script>
<style scoped>
.el-card{
margin-bottom: 15px;
}
.el-input{
width: 200px!important;
}
</style>

View File

@@ -0,0 +1,251 @@
<template>
<div class="app-container">
<el-card>
<span>设备名称:</span>
<el-select v-model="equipmentNameValue" placeholder="设备名称" style="width:200px" size="small" clearable filterable>
<el-option
v-for="item in equipmentName"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>操作者:</span>
<el-input v-model="operator" placeholder="操作者" size="small" clearable style="width:200px" @dblclick.native="getOperator();param = 0"/>
<el-button type="success" size="mini" icon="el-icon-search" style="margin-left:10px" @click="getTableData">查询</el-button>
<el-button type="primary" size="mini" icon="el-icon-circle-plus-outline" @click="handleAdd">增加</el-button>
</el-card>
<el-card>
<el-table v-loading="loading" :data="tableData" highlight-current-row border style="height: 500px">
<el-table-column label="设备名称" align="center" >
<template slot-scope="scope">
{{ scope.row.设备名称 }}
</template>
</el-table-column>
<el-table-column label="班次" align="center" >
<template slot-scope="scope">
{{ scope.row.班次 }}
</template>
</el-table-column>
<el-table-column label="操作者" align="center" >
<template slot-scope="scope">
{{ scope.row.操作者 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" >
<template slot-scope="scope">
<el-button type="primary" size="mini" icon="el-icon-edit" style="margin-left:10px" @click="handleEdit(scope.row)">编辑</el-button>
<el-button type="danger" size="mini" icon="el-icon-delete" @click="handleDelete(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent"
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-card>
<el-dialog :visible.sync="dialogFormVisible" title="选择人员" center style="min-height: 300px">
<span>部门名称:</span>
<el-select v-model="departmentValue" placeholder="部门名称" size="small" clearable style="width:180px" @change="getTablePeople">
<el-option
v-for="item in department"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-table
:data="tablePeople"
style="width:100%;max-height: 300px;margin-top: 20px"
height="300"
highlight-current-row
@row-click="currentPeople">
<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>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="dialogFormVisible = false">确定</el-button>
</div>
</el-dialog>
<el-dialog :title="title" :visible.sync="dialogFormVisible_form" center style="min-height: 300px" width="400px">
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">
<el-form-item label="设备名称" prop="设备名称">
<el-select v-model="form.设备流水号" placeholder="设备名称" style="width:200px" size="small" clearable filterable>
<el-option
v-for="item in equipmentName"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="班次" prop="班次" >
<el-select v-model="form.班次" placeholder="班次" style="width:200px" size="small" clearable filterable>
<el-option
v-for="item in staff"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="操作者" prop="操作者" >
<el-input v-model="form.操作者" placeholder="操作者" size="small" style="width:200px" clearable @dblclick.native="getOperator();param = 1"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="cancel">取消</el-button>
<el-button v-show="title === '增加'" type="primary" @click="submitAdd()">确定</el-button>
<el-button v-show="title === '编辑'" type="primary" @click="submitEdit()">确定</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { getEquipment, getDepartment, getTablePeople, getTableData, deleteTable, getStaff, addTable, editTable } from '@/api/BasicData/MaintenanceEquipmentPerson'
import { SectionToChinese } from '@/utils/tool'
export default {
data() {
return {
equipmentNameValue: '',
equipmentNameCheck: null,
equipmentName: [],
operator: '',
operatorNum: '',
operatorCheck: null,
dialogFormVisible: false,
tablePeople: [],
departmentValue: '',
department: [],
tableData: [],
pageCurrent: 1,
pageSize: 10,
total: 0,
loading: false,
title: '',
dialogFormVisible_form: false,
param: null,
form: {
设备名称: '',
设备流水号: null,
班次: '',
班次代码: '',
操作者: '',
操作者编号: null
},
rules: {
设备名称: [{ required: true, message: '请选择设备名称', trigger: 'blur' }],
操作者: [{ required: true, message: '请选择操作者', change: 'blur' }]
},
staff: [],
No: null
}
},
created() {
this.fetchData()
this.getTableData()
},
methods: {
fetchData() {
this.getSelect(getEquipment, ['设备名称', '设备流水号'], 'equipmentName', [0, this.equipmentNameValue]) // 获取设备名称
getStaff().then(res => { // 获取班次
res.data.map(row => {
this.staff.push({
label: `${SectionToChinese(row.班次代码)}`,
value: row.班次代码
})
})
})
},
getOperator() {
this.dialogFormVisible = true
this.getSelect(getDepartment, ['部门', '考核部门编号'], 'department')
},
getTablePeople() {
this.getData(getTablePeople, 'tablePeople', this.departmentValue)
},
currentPeople(row) {
if (this.param === 0) {
this.operator = row.姓名
this.operatorNum = row.人员编号
} else if (this.param === 1) {
this.form.操作者 = row.姓名
this.form.操作者编号 = row.人员编号
} else {
console.log(`err`)
}
},
getTableData() {
console.log(typeof (this.equipmentName))
this.equipmentNameValue ? this.equipmentNameCheck = 1 : this.equipmentNameCheck = 0
this.operator ? this.operatorCheck = 1 : this.operatorCheck = 0
this.loading = true
this.getTable(getTableData, [this.equipmentNameCheck, this.equipmentNameValue, this.operatorCheck, this.operatorNum, this.pageCurrent, this.pageSize], ['tableData', 'total', 'loading'])
},
handleAdd() {
this.addForm('form', [this.dialogFormVisible_form = true, this.title = '增加'])
},
handleEdit(row) {
this.No = row.设备人员关系流水号
this.editForm(row, 'form', [this.dialogFormVisible_form = true, this.title = '编辑'])
},
submitAdd() {
for (let i = 0; i < this.equipmentName.length; i++) {
if (this.form.设备流水号 === this.equipmentName[i].value) {
this.form.设备名称 = this.equipmentName[i].label
break
}
}
this.addTable(addTable, [this.form.设备流水号, this.form.设备名称, this.form.班次, this.form.操作者, this.form.操作者编号], 'form', function() { this.getTableData(); this.dialogFormVisible_form = false })
},
submitEdit() {
this.editTable(editTable, [this.form.设备名称, this.form.设备流水号, this.form.班次代码, this.form.操作者, this.form.操作者编号, this.No], 'form', function() { this.getTableData(); this.dialogFormVisible_form = false })
},
cancel() {
this.dialogFormVisible_form = false
},
handleDelete(row) {
this.deleteRow(deleteTable, row.设备人员关系流水号, function() { this.getTableData() })
},
handleSizeChange(val) {
this.pageSize = val
this.pageCurrent = 1
this.getTableData()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.getTableData()
}
}
}
</script>
<style scoped>
span{
margin: 20px;
}
</style>

View File

@@ -0,0 +1,199 @@
<template>
<div class="app-container">
<el-card>
<span>材料名称:</span>
<el-input v-model="Material" placeholder="请输材料名称" size="small" style="width:200px" clearable/>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 15px" @click="pageCurrent = 1;pageSize = 10;featchMaterial()">查询</el-button>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="add()">增加</el-button>
</el-card>
<el-card>
<el-table
v-loading="listLoading"
:data="tableData"
style="width: 100%"
height="580"
highlight-current-row
border>
<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="200">
<template slot-scope="scope">
<el-button
size="mini"
type="primary"
icon="el-icon-edit"
@click="Edit(scope.row)">编辑</el-button>
<el-button
size="mini"
type="danger"
icon="el-icon-delete"
@click="delMaterial(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px">
<el-pagination
:current-page="pageCurrent"
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-card>
<el-dialog :visible.sync="dialogFormVisible" title="新增材料" center style="min-height: 200px" width="400px">
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px">
<el-form-item label="材料名称" prop="MaterialName" style="display: inline-block">
<el-input v-model="form.MaterialName" clearable size="small" style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button size="small" @click="callOff()">取消</el-button>
<el-button type="primary" size="small" @click="addMaterial('form')">确定</el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible2" title="编辑材料" center style="min-height: 200px" width="400px">
<el-form ref="form2" :model="form2" :rules="rules" label-position="left" label-width="110px">
<el-form-item label="材料名称" prop="MaterialName2" style="display: inline-block">
<el-input v-model="form2.MaterialName2" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button size="small" @click="callOff()">取消</el-button>
<el-button type="primary" size="small" @click="editMaterial('form2')">确定</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { featchMaterial, addMaterial, delMaterial, editMaterial } from '@/api/BasicData/Materialmaintenance'
export default {
data() {
return {
ID: '',
dialogFormVisible: false,
dialogFormVisible2: false,
tableData: [],
Material: '', // 材质名称
listLoading: false,
pageCurrent: 1,
pageSize: 10,
total: null,
form: {
MaterialName: ''
},
form2: {
MaterialName2: ''
},
rules: {
MaterialName: [{ required: true, message: '请输入材料名称', trigger: 'blur' }],
MaterialName2: [{ required: true, message: '请输入材料名称', trigger: 'blur' }]
}
}
},
created() {
this.featchMaterial()
},
methods: {
handleSizeChange(val) {
this.pageSize = val
this.pageCurrent = 1
this.featchMaterial()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.featchMaterial()
},
featchMaterial() {
featchMaterial(this.Material, this.pageCurrent, this.pageSize).then(response => {
this.tableData = response.data.rows
this.total = response.data.total
})
},
callOff() {
this.dialogFormVisible = false
this.dialogFormVisible2 = false
},
add() {
if (this.$refs['form'] !== undefined) {
this.$refs['form'].resetFields()
}
this.form.MaterialName = ''
this.dialogFormVisible = true
},
addMaterial(formName) {
this.$refs[formName].validate((valid) => {
if (valid) {
addMaterial(this.form.MaterialName).then(response => {
if (response.data[0].result === '1') {
this.$message.success('添加成功')
this.dialogFormVisible = false
this.form = {}
this.featchMaterial()
} else {
this.$message.error('添加失败')
this.form = {}
}
})
}
})
},
delMaterial(row) {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delMaterial(row.材料流水号).then(response => {
if (response.data[0].result === '1') {
this.form.MaterialName = ''
this.featchMaterial()
this.$message.success('删除成功')
} else {
this.$message.error('删除失败')
}
})
})
},
Edit(row) {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
this.dialogFormVisible2 = true
this.form2.MaterialName2 = row.材料
this.ID = row.材料流水号
},
editMaterial(form2) {
this.$refs[form2].validate((valid) => {
if (valid) {
this.dialogFormVisible2 = false
editMaterial(this.ID, this.form2.MaterialName2).then(response => {
if (response.data[0].result === '1') {
this.featchMaterial()
this.$message.success('编辑成功')
this.form = {}
} else {
this.$message.error('编辑失败')
this.form = {}
}
})
}
})
}
}
}
</script>
<style scoped>
</style>

View File

@@ -15,7 +15,8 @@
<el-button slot="append" icon="el-icon-search" @click="fetchPeopleForName"/> <el-button slot="append" icon="el-icon-search" @click="fetchPeopleForName"/>
</el-input> </el-input>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="addPeople()">新增</el-button> <el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="addPeople()">新增</el-button>
<!--<el-button v-popover:popover4 type="success" icon="el-icon-sort" size="small" @click="moveGroup">移动</el-button>--> <!--<el-button v-popover:popover4 type="success" icon="el-icon-sort" size="small" @click="moveGroup">移动-->
<!--</el-button>-->
<!--<el-button size="small" @click="postMaintain()">岗位维护</el-button>--> <!--<el-button size="small" @click="postMaintain()">岗位维护</el-button>-->
<!--<el-popover--> <!--<el-popover-->
<!--ref="popover4"--> <!--ref="popover4"-->
@@ -29,7 +30,9 @@
<!--:disabled="true"--> <!--:disabled="true"-->
<!--size="small"--> <!--size="small"-->
<!--placeholder="请选择部门"/>--> <!--placeholder="请选择部门"/>-->
<!--<el-button type="text" size="small" style="margin-left: 60px; margin-top: 15px" @click="moveGroupConfim">确认</el-button>--> <!--<el-button type="text" size="small" style="margin-left: 60px; margin-top: 15px" @click="moveGroupConfim">-->
<!--确认-->
<!--</el-button>-->
<!--<el-dropdown-menu slot="dropdown">--> <!--<el-dropdown-menu slot="dropdown">-->
<!--<el-tree--> <!--<el-tree-->
<!--ref="treeForm"--> <!--ref="treeForm"-->
@@ -176,18 +179,18 @@
</el-row> </el-row>
<!--新增和编辑部门--> <!--新增和编辑部门-->
<!--<el-dialog :title="department_Title" :visible.sync="department_DFV" center style="min-height: 200px" width="400px">--> <el-dialog :title="department_Title" :visible.sync="department_DFV" center style="min-height: 200px" width="400px">
<!--<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">--> <el-form ref="department_Form" :model="department_Form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">
<!--<el-form-item label="部门名称" prop="DepartmentName">--> <el-form-item label="部门名称" prop="DepartmentName">
<!--<el-input v-model="department_Form.DepartmentName" size="small" style="width:200px"/>--> <el-input v-model="department_Form.DepartmentName" size="small" style="width:200px"/>
<!--</el-form-item>--> </el-form-item>
<!--</el-form>--> </el-form>
<!--<div slot="footer" class="dialog-footer">--> <div slot="footer" class="dialog-footer">
<!--<el-button @click="cancel">取消</el-button>--> <el-button @click="cancel">取消</el-button>
<!--<el-button v-if="department_Title==='新增部门'" type="primary" @click="submitAdd">确定</el-button>--> <el-button v-if="department_Title==='新增部门'" type="primary" @click="submitAdd">确定</el-button>
<!--<el-button v-else-if="department_Title==='编辑部门'" type="primary" @click="submitEdit">确定</el-button>--> <el-button v-else-if="department_Title==='编辑部门'" type="primary" @click="submitEdit">确定</el-button>
<!--</div>--> </div>
<!--</el-dialog>--> </el-dialog>
<el-dialog :title="people_title" :visible.sync="people_DFV" center style="min-height: 200px" width="800px"> <el-dialog :title="people_title" :visible.sync="people_DFV" center style="min-height: 200px" width="800px">
<el-form ref="people_form" :rules="rules" :model="people_form" label-position="left" label-width="110px" class="demo-ruleForm"> <el-form ref="people_form" :rules="rules" :model="people_form" label-position="left" label-width="110px" class="demo-ruleForm">

View File

@@ -0,0 +1,218 @@
<template>
<div class="app-container">
<el-card>
<span>角色功能:</span>
<el-input v-model="RoleFunctioning" size="small" clearable style="width:200px"/>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 15px" @click="pageCurrent=1;pageSize = 10;searchData()">查询</el-button>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="handleAdd()">增加</el-button>
</el-card>
<el-card style="margin-top: 15px">
<el-table
v-loading="loading"
:data="tableData"
highlight-current-row
border>
<el-table-column align="center" label="角色编号" width="100">
<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="200">
<template slot-scope="scope">
<el-button
size="mini"
type="primary"
icon="el-icon-edit"
@click="handleEdit(scope.row)">编辑</el-button>
<el-button
size="mini"
type="danger"
icon="el-icon-delete"
@click="handleDelete(scope.row)">删除</el-button>
</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 :visible.sync="dialogFormVisible1" title="新增角色" center style="min-height: 200px" width="400px">
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px">
<el-form-item label="角色名称" prop="角色功能" style="display: inline-block">
<el-input
v-model="form.角色功能"
clearable
size="small"
placeholder="角色功能"
style="width: 200px;"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button size="small" @click="dialogFormVisible1 = false">取消</el-button>
<el-button type="primary" size="small" @click="submitAdd1('form')">确定</el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible2" title="编辑角色" center style="min-height: 200px" width="400px">
<el-form ref="form2" :model="form2" :rules="rules2" label-position="left" label-width="110px">
<el-form-item label="角色名称" prop="角色功能" style="display: inline-block">
<el-input
v-model="form2.角色功能"
clearable
size="small"
placeholder="角色功能"
style="width: 200px;"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button size="small" @click="dialogFormVisible2 = false">取消</el-button>
<el-button type="primary" size="small" @click="submitAdd2('form2')">确定</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { InitRolefunction, deleteData, searchTable, addData, addData2 } from '@/api/BasicData/SystemRrolemaintenance'
export default {
data() {
return {
RoleFunctioning: '',
pageCurrent: 1,
pageSize: 10,
total: null,
loading: false,
tableData: [],
dialogFormVisible1: false,
dialogFormVisible2: false,
name: '',
num: '', // 角色编号
form: {
角色功能: ''
},
form2: {
角色功能: ''
},
rules: {
角色功能: [{ required: true, message: '请输入角色名称', trigger: 'blur' }]
},
rules2: {
角色功能: [{ required: true, message: '请输入角色名称', trigger: 'blur' }]
}
}
},
created() {
this.fetchData()
},
methods: {
fetchData() {
InitRolefunction(this.pageCurrent, this.pageSize).then(response => { // 初始化
this.tableData = response.data.rows
this.total = response.data.total
})
},
searchData() {
this.loading = true
searchTable(this.RoleFunctioning, this.pageCurrent, this.pageSize).then(response => {
this.tableData = response.data.rows
this.total = response.data.total
this.loading = false
console.log(response.data)
})
},
handleSizeChange(val) {
this.pageCurrent = 1
this.pageSize = val
this.fetchData()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.fetchData()
},
handleEdit(row) {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
this.dialogFormVisible2 = true
this.form2.角色功能 = row.角色功能
this.num = row.角色编号
},
submitAdd2(formName) { // 编辑角色功能
this.$refs[formName].validate((valid) => {
if (valid) {
addData2(this.form2.角色功能, this.num).then(response => {
if (response.data[0].result === '1') {
this.$message.success('编辑成功')
this.fetchData()
this.dialogFormVisible2 = false
} else { this.$message.error('编辑失败') }
})
}
})
},
submitAdd1(formName) { // 增加角色功能
this.$refs[formName].validate((valid) => {
if (valid) {
addData(this.form.角色功能).then(response => {
if (response.data[0].result === '1') {
this.$message.success('增加成功')
this.form.角色功能 = ''
this.fetchData()
this.dialogFormVisible1 = false
} else { this.$message.error('增加失败') }
})
}
})
},
handleAdd() {
if (this.$refs['form'] !== undefined) {
this.$refs['form'].resetFields()
}
this.dialogFormVisible1 = true
},
handleDelete(row) { // 删除
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteData(row.角色编号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
} else {
this.$message.error('删除失败')
}
this.fetchData()
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
}
}
}
</script>
<style scoped>
</style>

View File

@@ -0,0 +1,399 @@
<template>
<div class="app-container">
<table style="width: 100%">
<el-card>
<span>员工姓名:</span>
<el-input v-model="staffName" placeholder="员工姓名" size="small" clearable style="width:200px"/>
<span style="margin-left: 15px">角色名称:</span>
<el-select v-model="roleName" placeholder="角色名称" clearable size="small" style="width:200px">
<el-option
v-for="item in roleNames"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 15px" @click="pageCurrent1=1;searchData()">查询</el-button>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="handelAdd">增加</el-button>
</el-card>
<el-card>
<el-table :data="tableData" highlight-current-row>
<el-table-column label="员工姓名">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column disabled label="所属部门" >
<template slot-scope="scope">
{{ scope.row.部门名称 }}
</template>
</el-table-column>
<el-table-column label="岗位名称">
<template slot-scope="scope">
{{ scope.row.岗位名称 }}
</template>
</el-table-column>
<el-table-column label="角色名称">
<template slot-scope="scope">
{{ scope.row.角色功能 }}
</template>
</el-table-column>
<el-table-column label="考勤编号">
<template slot-scope="scope">
{{ scope.row.考勤编号 }}
</template>
</el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button
size="mini"
type="primary"
icon="el-icon-edit"
@click="submitEdit(scope.$index, scope.row)">修改</el-button>
<el-button
size="mini"
type="danger"
icon="el-icon-delete"
@click="handleDelete(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent1"
:page-sizes="[10, 20, 30, 40, 50]"
:page-size="10"
:total="total1"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange1"
@current-change="handleCurrentChange1"/>
</div>
</el-card>
</table>
<el-dialog :visible.sync="dialogFormVisible" title="人员信息" center width="750px">
<div style="height: 500px">
<div style="float: left;margin-top: 10px;margin-left: 20px;overflow-y: scroll;height: 400px">
<el-tree
:data="data2"
node-key="id"
style="width: 150px;float: left"
height="400"
accordion
@node-click="handleNodeClick"
/>
</div>
<el-table :data="List1" highlight-current-row height="400" style="width: 400px;float: left;margin-left: 30px" @row-click="handleCurrentChange">
<el-table-column label="考勤编号" align="center" >
<template slot-scope="scope">
{{ scope.row.考勤编号 }}
</template>
</el-table-column>
<el-table-column label="姓名" align="center" >
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="性别" align="center">
<template slot-scope="scope">
{{ scope.row.性别 }}
</template>
</el-table-column>
<el-table-column label="工作岗位" align="center">
<template slot-scope="scope">
{{ scope.row.岗位名称 }}
</template>
</el-table-column>
</el-table>
</div>
<el-button style="margin-left: 260px" @click="dialogFormVisible = false">取消</el-button>
<el-button type="primary" style="margin-top: 20px" @click="getName">确认</el-button>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible1" title="增加" center style="min-height: 270px" width="800px">
<el-form ref="form1" :model="form1" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">
<el-row>
<el-col :span="12">
<el-form-item label="员工姓名" prop="staffName">
<el-input v-model="form1.staffName" placeholder="请双击选择" size="small" clearable style="width:200px" @dblclick.native="dialogTableVisible()"/>
</el-form-item>
<el-form-item label="角色名称" prop="roleName">
<el-select v-model="form1.roleName" placeholder="角色名称" size="small" clearable style="width:200px">
<el-option
v-for="item in roleNames"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="考勤编号" >
<el-input
v-model="cjscgy"
disabled
size="small"
style="width:200px"/>
</el-form-item>
<el-form-item label="所属部门" >
<el-input v-model="ssks" size="small" style="width:200px"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOFF"> </el-button>
<el-button type="primary" @click="submitAdd1()"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible2" title="编辑" center style="min-height: 270px" width="800px">
<el-form ref="form2" :model="form2" :rules="rules1" label-position="left" label-width="110px" class="demo-ruleForm">
<el-row>
<el-col :span="12">
<el-form-item label="员工姓名" >
<el-input v-model="form2.staffName" disabled size="small" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="角色名称" prop="roleName">
<el-select v-model="form2.roleName" placeholder="角色名称" clearable size="small" style="width:200px">
<el-option
v-for="item in roleNames"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="考勤编号" >
<el-input
v-model="cjscgy"
disabled
size="small"
style="width:200px"/>
</el-form-item>
<el-form-item disabled="true" label="所属部门" >
<el-input v-model="ssks" disabled size="small" style="width:200px"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOFF">取消</el-button>
<el-button type="primary" @click="submitAdd2()">确定</el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { dialogtablevisible, deleteData, getTree, fn, getTable8, initOrderType, addData1, addData2, searchTable } from '@/api/BasicData/WorkshopPersonnelRoleMana'
export default {
data() {
return {
number: '',
form1: {
staffName: '',
roleName: ''
},
form2: {
staffName: '',
roleName: ''
},
rules: {
staffName: [{ required: true, message: '请选择员工姓名', trigger: 'change' }],
roleName: [{ required: true, message: '请选择员工角色', trigger: 'change' }]
},
rules1: {
roleName: [{ required: true, message: '请选择员工角色', trigger: 'change' }]
},
staffName: '',
cjscgy: '',
List1: [],
ssks: '',
data2: [],
dialogFormVisible1: false,
dialogFormVisible2: false,
tableData: [],
check1: '',
check2: '',
name: '', // 中间变量
check3: '',
check4: '',
staffNum: '',
personnelNumber: '',
personnelStream: '',
pageCurrent1: 1,
pageSize1: 10,
total1: null,
roleName: null,
roleNames: [],
rybh: '',
jsbh: '',
dialogFormVisible: false
}
},
created() {
this.fetchData()
},
methods: {
handelAdd(row) {
this.dialogFormVisible1 = true
this.ssks = ''
this.cjscgy = ''
if (this.$refs['form1'] !== undefined) {
this.$refs['form1'].resetFields()
}
},
submitEdit(index, row) {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
this.dialogFormVisible2 = true
this.personnelStream = row.人员角色流水号
this.form2.staffName = row.姓名
this.ssks = row.部门名称
this.personnelNumber = row.人员编号
this.form2.roleName = parseInt(row.角色编号)
this.cjscgy = row.考勤编号
},
callOFF() {
this.dialogFormVisible1 = false
this.dialogFormVisible2 = false
this.ssks = ''
this.cjscgy = ''
},
searchData() {
if (this.staffName !== '' && this.staffName !== null) {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.roleName !== '' && this.roleName !== null) {
this.check2 = 1
} else {
this.check2 = 0
}
searchTable(this.check1, this.staffName, this.check2, this.roleName, this.pageCurrent1, this.pageSize1).then(response => {
this.tableData = response.data.rows
this.total1 = response.data.total
})
},
fetchData() {
getTree().then(response => { // 获取人员信息树
const data = response.data
this.data2 = fn(data, 0)
})
initOrderType().then(response => { // 角色名称
for (let i = 0; i < response.data.length; i++) {
this.roleNames.push({
label: response.data[i].角色功能,
value: response.data[i].角色编号
})
}
})
this.searchData()
},
handleSizeChange1(val) {
this.pageCurrent1 = 1
this.pageSize1 = val
this.searchData()
},
handleCurrentChange1(val) {
this.pageCurrent1 = val
this.searchData()
},
submitAdd1() {
this.$refs['form1'].validate((valid) => {
if (valid) {
addData1(this.personnelNumber, this.form1.roleName).then(response => {
if (response.data[0].result === '1') {
this.$message.success('增加成功')
this.ssks = ''
this.form1.staffName = ''
this.form1.roleName = ''
this.searchData()
this.dialogFormVisible1 = false
} else { this.$message.error('增加失败') }
})
} else {
console.log('error submit!!')
return false
}
})
},
submitAdd2() {
this.$refs['form2'].validate((valid) => {
if (valid) {
addData2(this.personnelStream, this.personnelNumber, this.form2.roleName).then(response => {
if (response.data[0].result === '1') {
this.$message.success('修改成功')
this.ssks = ''
this.searchData()
this.dialogFormVisible2 = false
} else { this.$message.error('修改失败') }
})
} else {
console.log('error submit!!')
return false
}
})
},
handleCurrentChange3(val) {
this.searchgroup()
},
handleNodeClick(data) { // 树节点点击
this.ssks = data.label
getTable8(data.id).then(response => {
this.List1 = response.data
})
},
handleDelete(row) { // 删除
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteData(row.人员角色流水号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
} else { this.$message.error('删除失败') }
this.searchData()
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
dialogTableVisible() {
this.dialogFormVisible = true
dialogtablevisible().then(response => {
})
},
handleCurrentChange(row) { // 获取当前行人员信息
this.ssks = row.节点名称
this.number = row.考勤编号
this.name = row.姓名
this.personnelNumber = row.人员编号
},
getName() { // 提交人员
this.cjscgy = this.number
this.dialogFormVisible = false
this.form1.staffName = this.name
this.form2.staffName = this.name
}
}
}
</script>
<style scoped>
.el-card{
margin-bottom:15px;
margin-left: 15px;
margin-right: 15px;
}
</style>

View File

@@ -0,0 +1,545 @@
<template>
<div class="app-container">
<el-row>
<el-col :span="6">
<el-card>
<span>工艺分类</span>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="addProcessClassification()">新增</el-button>
<el-button size="small" type="warning" icon="el-icon-edit" @click="editProcessClassification()">编辑</el-button>
<el-button size="small" type="danger" icon="el-icon-delete" @click="delProcessClassification()">删除</el-button>
</el-card>
</el-col>
<el-col :span="18">
<el-card>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="addProcess">新增工艺名称</el-button>
</el-card>
</el-col>
</el-row>
<el-row>
<el-col :span="6">
<el-card>
<el-table
v-loading="loading1"
ref="multipleTable"
:data="tableData1"
stripe
tooltip-effect="dark"
style="width: 100%"
height="700"
highlight-current-row
border>
<el-table-column align="center" label="流水号" width="80">
<template slot-scope="scope">
<el-radio :label="scope.row.工艺分类流水号" v-model="radio" @change.native="getCurrentRow(scope.row.工艺分类流水号, scope.row.工艺分类名称)"/>
</template>
</el-table-column>
<el-table-column align="center" label="工艺分类">
<template slot-scope="scope">
{{ scope.row.工艺分类名称 }}
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
<el-col :span="18">
<el-card >
<el-table
:data="tableData2"
:row-key="getRowKeys"
:expand-row-keys="expands"
height="700"
width="100%"
@expand-change="searchTechnologicalRequirementsOfProcessNum">
<el-table-column type="expand">
<template slot-scope="scope">
<el-table :data="tableData3" border>
<el-table-column label="工艺要求">
<template slot-scope="scope">
{{ scope.row.工艺要求 }}
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="200px">
<template slot-scope="scope">
<el-button
size="mini"
type="warning"
icon="el-icon-edit"
@click="editTechnologicalRequirements(scope.row)">编辑</el-button>
<el-button
size="mini"
type="danger"
icon="el-icon-delete"
@click="delTechnologicalRequirements(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
</template>
</el-table-column>
<el-table-column label="工艺名称">
<template slot-scope="scope">
{{ scope.row.工艺名称 }}
</template>
</el-table-column>
<el-table-column>
<template slot-scope="scope">
<el-button
size="mini"
type="warning"
icon="el-icon-edit"
@click="editProcess(scope.row)">编辑工艺</el-button>
<el-button
size="mini"
type="danger"
icon="el-icon-delete"
@click="delProcess(scope.row)">删除工艺</el-button>
<el-button
size="mini"
type="primary"
icon="el-icon-circle-plus-outline"
@click="addTechnologicalRequirements(scope.row)">新增要求</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
</el-row>
<el-dialog :visible.sync="dialogFormVisible1" title="增加工艺分类" center style="min-height: 300px" width="400px">
<el-form ref="form1" :model="form1" :rules="rules1" label-position="left" label-width="110px" >
<el-form-item label="工艺分类" prop="ProcessClassification">
<el-input v-model="form1.ProcessClassification" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="calloff"> </el-button>
<el-button type="primary" @click="submit1('form1')"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible2" title="编辑工艺分类" center style="min-height: 300px" width="400px">
<el-form ref="form1" :model="form1" :rules="rules1" label-position="left" label-width="110px" >
<el-form-item label="工艺分类" prop="ProcessClassification">
<el-input v-model="form1.ProcessClassification" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="calloff"> </el-button>
<el-button type="primary" @click="submit1('form1')"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible3" title="增加工艺" center style="min-height: 300px" width="400px">
<el-form ref="form2" :model="form2" :rules="rules2" label-position="left" label-width="110px" >
<el-form-item label="工艺名称" prop="Process">
<el-input v-model="form2.Process" size="small" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="工艺名称简称" prop="ProcessShort">
<el-input v-model="form2.ProcessShort" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="calloff"> </el-button>
<el-button type="primary" @click="submit1('form2')"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible4" title="编辑工艺" center style="min-height: 300px" width="400px">
<el-form ref="form2" :model="form2" :rules="rules2" label-position="left" label-width="110px" >
<el-form-item label="工艺名称" prop="Process">
<el-input v-model="form2.Process" size="small" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="工艺名称简称" prop="ProcessShort">
<el-input v-model="form2.ProcessShort" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="calloff"> </el-button>
<el-button type="primary" @click="submit1('form2')"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible5" title="新增工艺要求" center style="min-height: 300px" width="400px">
<el-form ref="form3" :model="form3" :rules="rules3" label-position="left" label-width="110px" >
<el-form-item label="工艺要求" prop="Process">
<el-input v-model="form3.TechnologicalRequirements" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="calloff"> </el-button>
<el-button type="primary" @click="submit1('form3')"> </el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible6" title="编辑工艺要求" center style="min-height: 300px" width="400px">
<el-form ref="form3" :model="form3" :rules="rules3" label-position="left" label-width="110px" >
<el-form-item label="工艺要求" prop="TechnologicalRequirements">
<el-input v-model="form3.TechnologicalRequirements" size="small" clearable style="width:200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="calloff"> </el-button>
<el-button type="primary" @click="submit1('form3')"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { searchProcessClassification, searchProcessNameOfProcessClassification, searchTechnologicalRequirementsOfProcessNum, searchProcessClassificationOfProcessClassificationNum, addProcessClassification, editProcessClassification, delProcessClassification, addProcess, delProcess, editProcess, addTechnologicalRequirements, editTechnologicalRequirements, delTechnologicalRequirements } from '@/api/BasicData/WorkshopProcessMaintenance'
export default {
data() {
return {
// 工艺分类所需变量
expands: [],
tableData1: [],
ProcessNum: '',
loading1: false,
loading2: false,
loading3: false,
ProcessClassificationNum: '',
radio: null,
dialogFormVisible1: false,
dialogFormVisible2: false,
dialogFormVisible3: false,
dialogFormVisible4: false,
dialogFormVisible5: false,
dialogFormVisible6: false,
temp: null,
ProcessClassificationNumS: '',
form1: {
ProcessClassification: ''
},
form2: {
Process: '',
ProcessShort: ''
},
form3: {
TechnologicalRequirements: ''
},
rules1: {
ProcessClassification: [{ required: true, message: '请输入工艺分类名称', trigger: 'blur' }]
},
rules2: {
Process: [{ required: true, message: '请输入工艺名称', trigger: 'blur' }],
ProcessShort: [{ required: true, message: '请输入工艺名称简称', trigger: 'blur' }]
},
rules3: {
TechnologicalRequirements: [{ required: true, message: '请输入工艺要求', trigger: 'blur' }]
},
tableData2: [],
tableData3: [],
Num: [],
maxNum: '',
max: [],
code: ''
}
},
created() {
this.searchProcessClassification()
},
methods: {
searchProcessClassification() {
this.loading1 = true
searchProcessClassification(this.ProcessClassification).then(response => {
this.loading1 = false
this.tableData1 = response.data
this.total1 = response.data
return this.tableData1
}).then(data => {
this.Num = data
for (let i = 0; i < this.Num.length; i++) {
this.max.push(this.Num[i].工艺分类流水号)
}
return this.max
}).then(data => {
const a = data
this.maxNum = a[0]
for (let j = 0; j < a.length; j++) {
if (this.maxNum < a[j]) {
this.maxNum = a[j]
}
}
return this.maxNum
}).then(data => {
const b = data
this.radio = b
return this.radio
}).then(data => {
const c = data
this.loading2 = true
searchProcessNameOfProcessClassification(c).then(response => {
this.loading2 = false
this.tableData2 = response.data
})
})
},
addProcessClassification() {
if (this.$refs['form1'] !== undefined) {
this.$refs['form1'].resetFields()
}
this.form1 = {}
this.dialogFormVisible1 = true
this.temp = 1
},
editProcessClassification() {
if (this.radio !== '') {
this.temp = 2
this.dialogFormVisible2 = true
searchProcessClassificationOfProcessClassificationNum(this.radio).then(response => {
this.form1.ProcessClassification = response.data[0].工艺分类名称
})
} else {
this.$message.warning('请选择工艺分类')
}
},
submitProcessClassification() {
editProcessClassification(this.radio, this.form1.ProcessClassification).then(response => {
if (response.data[0].result === '1') {
this.$message.success('信息更新成功')
this.dialogFormVisible2 = false
this.searchProcessClassification()
} else {
this.$message.error('信息更新失败')
}
})
},
submitaddProcessClassification() {
addProcessClassification(this.form1.ProcessClassification).then(response => {
if (response.data[0].result === '1') {
this.$message.success('增加成功')
this.searchProcessClassification()
this.dialogFormVisible1 = false
} else { this.$message.error('增加失败') }
})
},
submit1(formName) {
this.$refs[formName].validate((valid) => {
if (valid) {
if (this.temp === 1) {
this.submitaddProcessClassification()
this.form1 = {}
this.temp = null
} else if (this.temp === 2) {
this.submitProcessClassification()
this.form1 = {}
this.temp = null
} else if (this.temp === 3) {
this.submitaddProcess()
this.form2 = {}
this.temp = null
} else if (this.temp === 4) {
this.submiteditProcess()
this.form2 = {}
this.temp = null
} else if (this.temp === 5) {
this.submitTechnologicalRequirements()
this.form3 = {}
this.temp = null
} else if (this.temp === 6) {
this.submiteditTechnologicalRequirements()
this.form3 = {}
this.temp = null
}
}
})
},
delProcessClassification() {
if (this.radio !== '') {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delProcessClassification(this.radio).then(response => {
if (response.data[0].result === '1') {
this.searchProcessClassification()
this.$message.success('删除成功')
} else {
this.$message.error('删除失败')
}
})
})
} else {
this.$message.warning('请选择工艺分类')
}
},
calloff() {
this.dialogFormVisible1 = false
this.dialogFormVisible2 = false
this.dialogFormVisible3 = false
this.dialogFormVisible4 = false
this.dialogFormVisible5 = false
this.dialogFormVisible6 = false
this.form1 = {}
this.form2 = {}
this.form3 = {}
},
getCurrentRow(row) {
searchProcessClassificationOfProcessClassificationNum(this.radio).then(response => {
this.form1.ProcessClassification = response.data[0].工艺分类名称
})
this.loading2 = true
searchProcessNameOfProcessClassification(row).then(response => {
this.loading2 = false
this.tableData2 = response.data
})
},
searchTechnologicalRequirementsOfProcessNum(row, expandedRows) {
// this.expands = []
// this.expands.push(row.工艺编号)
if (expandedRows.length > 1) {
expandedRows.shift()
}
this.loading3 = true
searchTechnologicalRequirementsOfProcessNum(row.工艺编号).then(response => {
this.loading3 = false
this.tableData3 = response.data
})
},
addProcess() {
if (this.$refs['form2'] !== undefined) {
this.$refs['form2'].resetFields()
}
if (this.radio !== '') {
this.form2.Process = ''
this.form2.ProcessShort = ''
this.dialogFormVisible3 = true
this.temp = 3
} else {
this.$message.warning('请选择一个工艺分类')
}
},
submitaddProcess() {
addProcess(this.radio, this.form2.Process, this.form2.ProcessShort).then(response => {
if (response.data[0].result === '1') {
this.$message.success('增加成功')
this.loading2 = true
searchProcessNameOfProcessClassification(this.radio).then(response => {
this.loading2 = false
this.tableData2 = response.data
})
this.dialogFormVisible3 = false
} else { this.$message.error('增加失败') }
})
},
editProcess(row) {
this.dialogFormVisible4 = true
this.temp = 4
this.form2.Process = row.工艺名称
this.form2.ProcessShort = row.工艺名称简称
this.ProcessNum = row.工艺编号
},
submiteditProcess() {
editProcess(this.ProcessNum, this.form2.Process, this.form2.ProcessShort).then(response => {
if (response.data[0].result === '1') {
this.$message.success('信息更新成功')
this.dialogFormVisible4 = true
searchProcessNameOfProcessClassification(this.radio).then(response => {
this.loading2 = false
this.tableData2 = response.data
})
this.dialogFormVisible4 = false
} else {
this.$message.error('信息更新失败')
}
})
},
getRowKeys(row) {
return row.工艺编号
},
delProcess(row) {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delProcess(row.工艺编号).then(response => {
if (response.data[0].result === '1') {
this.loading2 = true
searchProcessNameOfProcessClassification(this.radio).then(response => {
this.loading2 = false
this.tableData2 = response.data
})
this.$message.success('删除成功')
} else {
this.$message.error('删除失败')
}
})
})
},
addTechnologicalRequirements(row) {
if (this.$refs['form3'] !== undefined) {
this.$refs['form3'].resetFields()
}
this.ProcessNum = row.工艺编号
this.form3.TechnologicalRequirements = ''
this.dialogFormVisible5 = true
this.temp = 5
},
submitTechnologicalRequirements() {
addTechnologicalRequirements(this.ProcessNum, this.form3.TechnologicalRequirements).then(response => {
if (response.data[0].result === '1') {
this.$message.success('增加成功')
this.loading3 = true
searchTechnologicalRequirementsOfProcessNum(this.ProcessNum).then(response => {
this.loading3 = false
this.tableData3 = response.data
})
this.dialogFormVisible5 = false
} else { this.$message.error('增加失败') }
})
},
editTechnologicalRequirements(row) {
this.temp = 6
this.dialogFormVisible6 = true
this.form3.TechnologicalRequirements = row.工艺要求
this.code = row.工艺要求流水号
this.ProcessNum = row.工艺编号
},
submiteditTechnologicalRequirements() {
editTechnologicalRequirements(this.code, this.form3.TechnologicalRequirements).then(response => {
if (response.data[0].result === '1') {
this.$message.success('信息更新成功')
this.loading3 = true
searchTechnologicalRequirementsOfProcessNum(this.ProcessNum).then(response => {
this.loading3 = false
this.tableData3 = response.data
})
this.dialogFormVisible6 = false
} else {
this.$message.error('信息更新失败')
}
})
},
delTechnologicalRequirements(row) {
this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
delTechnologicalRequirements(row.工艺要求流水号).then(response => {
if (response.data[0].result === '1') {
this.loading3 = true
searchTechnologicalRequirementsOfProcessNum(row.工艺编号).then(response => {
this.loading3 = false
this.tableData3 = response.data
})
this.$message.success('删除成功')
} else {
this.$message.error('删除失败')
}
})
})
}
}
}
</script>
<style scoped>
.el-card {
margin-top: 15px;
margin-left: 15px;
}
</style>

View File

@@ -59,12 +59,12 @@
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组件名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="数量" align="center" min-width="80"> <el-table-column label="数量" align="center" min-width="80">
@@ -268,9 +268,8 @@ export default {
this.PeopleNumber = this.id this.PeopleNumber = this.id
}, },
searchMachine() { // 查询机床 searchMachine() { // 查询机床
if (this.ProjectValue === '') { this.Machine = []
this.ProjectValue_check = 0 this.ProjectValue ? this.ProjectValue_check = 1 : this.ProjectValue_check = 0
}
searchmachine(this.ProjectValue_check, this.ProjectValue).then(response => { searchmachine(this.ProjectValue_check, this.ProjectValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.Machine.push({ this.Machine.push({
@@ -281,6 +280,7 @@ export default {
}) })
}, },
searchGroupList() { // 查询组号 searchGroupList() { // 查询组号
this.GroupNum = []
searchTeam(this.MachineValue).then(response => { searchTeam(this.MachineValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.GroupNum.push({ this.GroupNum.push({
@@ -291,16 +291,19 @@ export default {
}) })
}, },
searchPeopleData() { // 查询人员 searchPeopleData() { // 查询人员
this.People = []
searchPeople().then(response => { searchPeople().then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.People.push({ this.People.push({
label: response.data[i].姓名, label: response.data[i].姓名,
value: response.data[i].考勤编号 value: parseInt(response.data[i].考勤编号)
}) })
} }
console.log(this.People)
}) })
}, },
searchContractData() { // 查询合同 searchContractData() { // 查询合同
this.Contract = []
searchContract().then(response => { searchContract().then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.Contract.push({ this.Contract.push({
@@ -312,18 +315,10 @@ export default {
}, },
searchPartinfo() { searchPartinfo() {
this.tableDataPurchase = [] this.tableDataPurchase = []
if (this.ProjectValue === '') { this.ProjectValue ? this.ProjectValue_check = 1 : this.ProjectValue_check = 0
this.ProjectValue_check = 0 this.MachineValue ? this.MachineValue_check = 1 : this.MachineValue_check = 0
} this.GroupNumValue ? this.GroupNumValue_check = 1 : this.GroupNumValue_check = 0
if (this.MachineValue === '') { this.ContractValue ? this.ContractValue_check = 1 : this.ContractValue_check = 0
this.MachineValue_check = 0
}
if (this.GroupNumValue === '') {
this.GroupNumValue_check = 0
}
if (this.ContractValue === '') {
this.ContractValue_check = 0
}
this.listLoading = true this.listLoading = true
searchDirectPart(this.PageCurrent, this.PageSize, this.ProjectValue_check, this.ProjectValue, this.MachineValue_check, this.MachineValue, this.GroupNumValue_check, this.GroupNumValue, this.ContractValue_check, this.ContractValue).then(response => { searchDirectPart(this.PageCurrent, this.PageSize, this.ProjectValue_check, this.ProjectValue, this.MachineValue_check, this.MachineValue, this.GroupNumValue_check, this.GroupNumValue, this.ContractValue_check, this.ContractValue).then(response => {
this.tableDataPurchase = response.data.rows this.tableDataPurchase = response.data.rows
@@ -349,8 +344,7 @@ export default {
// 打开直达件表单 // 打开直达件表单
addDirect(row) { addDirect(row) {
this.PeopleValue = '' this.PeopleValue = ''
this.form = [] this.form = {}
console.log(row)
this.dialogFormVisible = true this.dialogFormVisible = true
this.materialNum = row.物料流水号 this.materialNum = row.物料流水号
this.purchaseContractNumber = row.采购合同明细流水号 this.purchaseContractNumber = row.采购合同明细流水号
@@ -367,7 +361,7 @@ export default {
this.dialogFormVisible1 = true this.dialogFormVisible1 = true
this.directPartNumber = row.直达件流水号 this.directPartNumber = row.直达件流水号
this.form.DirectNumber = row.到货数量 this.form.DirectNumber = row.到货数量
this.PeopleValue = row.领用人员流水号 this.PeopleValue = parseInt(row.领用人员流水号)
this.form.DirectNote = row.备注 this.form.DirectNote = row.备注
}, },
// 修改直达件 // 修改直达件

View File

@@ -46,12 +46,12 @@
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组件名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="物料名称" align="center" min-width="80"> <el-table-column label="物料名称" align="center" min-width="80">
@@ -76,7 +76,6 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
</el-card>
<div class="block" style="margin-top: 10px;"> <div class="block" style="margin-top: 10px;">
<el-pagination <el-pagination
:current-page="PageCurrent" :current-page="PageCurrent"
@@ -87,6 +86,7 @@
@size-change="handleSizeChange" @size-change="handleSizeChange"
@current-change="handleCurrentChange"/> @current-change="handleCurrentChange"/>
</div> </div>
</el-card>
<el-card> <el-card>
<el-row> <el-row>
<el-col :span="11"> <el-col :span="11">
@@ -109,12 +109,12 @@
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组件名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="物料名称" align="center" min-width="80"> <el-table-column label="物料名称" align="center" min-width="80">
@@ -127,7 +127,7 @@
</el-col> </el-col>
<el-col :span="2"> <el-col :span="2">
<div style="margin: 10px 15px"> <div style="margin: 10px 15px">
<el-button size="small" type="primary" icon="el-icon-edit" @click="total = 0;pageSize = 10;pageList = 1;exchange()" >交换</el-button> <el-button size="small" type="primary" icon="el-icon-edit" @click="total = 0;pageSize = 10;pageList = 1;exchange('form')" >交换</el-button>
</div> </div>
</el-col> </el-col>
<el-col :span="11"> <el-col :span="11">
@@ -149,12 +149,12 @@
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组件名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="物料名称" align="center" min-width="80"> <el-table-column label="物料名称" align="center" min-width="80">
@@ -167,24 +167,6 @@
</el-col> </el-col>
</el-row> </el-row>
<!--新增交换件对话框--> <!--新增交换件对话框-->
<el-dialog :title="title" :visible.sync="dialogFormVisible" center width="380px">
<el-form ref="form" :model="form" :rules="rules" label-position="left">
<el-form-item label="交换单编号" prop="ContractNumberValue" label-width="100px" size="small">
<el-input v-model="form.ExchangeNumber" size="small" placeholder="请输入零件交换单编号" style="width: 200px"/>
</el-form-item>
<el-form-item label="交换数量" prop="TotalContractAmount" label-width="100px">
<el-input v-model="form.ExchangeNumberx" size="small" placeholder="请输入交换数量" style="width: 200px"/>
</el-form-item>
<el-form-item label="备注" prop="TotalContractAmount" label-width="100px">
<el-input v-model="form.ExchangeNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button>
<el-button v-show="title==='交换'" type="primary" @click="addListDetailinfor('form')"> </el-button>
<el-button v-show="title==='编辑'" type="primary" @click="submitEdit('form')">确定</el-button>
</div>
</el-dialog>
</el-card> </el-card>
<el-card> <el-card>
<el-table <el-table
@@ -240,12 +222,11 @@
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" min-width="180"> <el-table-column label="操作" align="center" min-width="180">
<template slot-scope="scope" align="center"> <template slot-scope="scope" align="center">
<el-button size="small" type="primary" icon="el-icon-edit" style="margin: 0 0 0 0px" @click="handleEdit(scope.row)">编辑</el-button> <el-button :disabled="scope.row.是否禁用" size="small" type="primary" icon="el-icon-edit" style="margin: 0 0 0 0px" @click="handleEdit(scope.row)">编辑</el-button>
<el-button size="small" type="danger" icon="el-icon-delete" style="margin: 0 0 0 0px" @click="dropListinfor(scope.row)">删除</el-button> <el-button :disabled="scope.row.是否禁用" size="small" type="danger" icon="el-icon-delete" style="margin: 0 0 0 0px" @click="dropListinfor(scope.row)">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
</el-card>
<div class="block" style="margin-top: 10px;"> <div class="block" style="margin-top: 10px;">
<el-pagination <el-pagination
:current-page="PageCurrent1" :current-page="PageCurrent1"
@@ -256,6 +237,25 @@
@size-change="handleSizeChange1" @size-change="handleSizeChange1"
@current-change="handleCurrentChange1"/> @current-change="handleCurrentChange1"/>
</div> </div>
</el-card>
<el-dialog :title="title" :visible.sync="dialogFormVisible" center width="380px">
<el-form ref="form" :model="form" :rules="rules" label-position="left">
<el-form-item label="交换单编号" prop="ExchangeNumber" label-width="100px" size="small">
<el-input v-model="form.ExchangeNumber" size="small" placeholder="请输入零件交换单编号" style="width: 200px"/>
</el-form-item>
<el-form-item label="交换数量" prop="ExchangeNumberx" label-width="100px">
<el-input v-model="form.ExchangeNumberx" size="small" placeholder="请输入交换数量" style="width: 200px"/>
</el-form-item>
<el-form-item label="备注" prop="ExchangeNote" label-width="100px">
<el-input v-model="form.ExchangeNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button>
<el-button v-show="title==='交换'" type="primary" @click="addListDetailinfor('form')"> </el-button>
<el-button v-show="title==='编辑'" type="primary" @click="submitEdit(scope.$index, scope.row, 'form')">确定</el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
@@ -265,9 +265,11 @@ import { mapGetters } from 'vuex'
export default { export default {
data() { data() {
return { return {
count1: 0,
count2: 0, // 清表单验证计数器
ProjectValue: '', ProjectValue: '',
Project: [], Project: [],
ProjectValue_check: 1, ProjectValue_check: 0,
MachineValue: '', MachineValue: '',
Machine: [], Machine: [],
MachineValue_check: 1, MachineValue_check: 1,
@@ -302,7 +304,7 @@ export default {
rules: { // 表单验证规则 rules: { // 表单验证规则
ExchangeNumber: [{ required: true, message: '请输入交换件编号', trigger: 'blur' }], ExchangeNumber: [{ required: true, message: '请输入交换件编号', trigger: 'blur' }],
ExchangeNumberx: [{ required: true, message: '请输入交换件数量', trigger: 'blur' }], ExchangeNumberx: [{ required: true, message: '请输入交换件数量', trigger: 'blur' }],
ExchangeNote: [{ required: true, message: '请输入交换件备注', trigger: 'change' }] ExchangeNote: [{ required: true, message: '请输入交换件备注', trigger: 'blur' }]
}, },
PageCurrent: 1, PageCurrent: 1,
PageSize: 10, PageSize: 10,
@@ -334,12 +336,14 @@ export default {
// 获取人员编号 // 获取人员编号
getpeopleid() { getpeopleid() {
this.picikingPeople = this.id this.picikingPeople = this.id
console.log(this.picikingPeople)
}, },
searchMachine() { // 查询机床 searchMachine() {
if (this.ProjectValue === '') { this.MachineValue = ''
this.ProjectValue_check = 0 this.Machine = []
} this.GroupNumValue = ''
this.GroupNum = []
if (this.ProjectValue !== '') {
this.ProjectValue_check = 1
searchmachine(this.ProjectValue_check, this.ProjectValue).then(response => { searchmachine(this.ProjectValue_check, this.ProjectValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.Machine.push({ this.Machine.push({
@@ -348,12 +352,17 @@ export default {
}) })
} }
}) })
} else {
this.ProjectValue_check = 0
}
}, },
searchGroupList() { // 查询组号 searchGroupList() {
this.GroupNumValue = ''
this.GroupNum = []
searchTeam(this.MachineValue).then(response => { searchTeam(this.MachineValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.GroupNum.push({ this.GroupNum.push({
label: response.data[i].件名称, label: response.data[i].,
value: response.data[i].组件流水号 value: response.data[i].组件流水号
}) })
} }
@@ -374,7 +383,6 @@ export default {
this.listLoading = true this.listLoading = true
searchPurchasePart(this.PageCurrent, this.PageSize, this.ProjectValue_check, this.ProjectValue, this.MachineValue_check, this.MachineValue, this.GroupNumValue_check, this.GroupNumValue).then(response => { searchPurchasePart(this.PageCurrent, this.PageSize, this.ProjectValue_check, this.ProjectValue, this.MachineValue_check, this.MachineValue, this.GroupNumValue_check, this.GroupNumValue).then(response => {
this.tableDataPurchase = response.data.rows this.tableDataPurchase = response.data.rows
console.log(this.tableDataPurchase)
this.total = response.data.total this.total = response.data.total
}) })
this.listLoading = false this.listLoading = false
@@ -392,44 +400,76 @@ export default {
getExchangeTable() { getExchangeTable() {
this.listLoading1 = true this.listLoading1 = true
searchExchangePart(this.PageCurrent1, this.PageSize1).then(response => { searchExchangePart(this.PageCurrent1, this.PageSize1).then(response => {
this.tableDataExchange = response.data.rows const data = response.data.rows
console.log(data)
for (let i = 0; i < data.length; i++) {
data[i].审批通过 === '1' ? data[i].是否禁用 = true : data[i].是否禁用 = false
}
this.tableDataExchange = data
this.total1 = response.data.total this.total1 = response.data.total
this.listLoading1 = false this.listLoading1 = false
}) })
}, },
handleSizeChange1(val) {
this.PageCurrent1 = 1
this.PageSize1 = val
this.getExchangeTable()
},
handleCurrentChange1(val) {
this.PageCurrent1 = val
this.getExchangeTable()
},
// 选择领料单 // 选择领料单
chooseListinfor(row) { chooseListinfor(row) {
this.pickingListNumberx = row.领料单流水号 this.pickingListNumberx = row.领料单流水号
console.log(this.pickingListNumberx)
this.searchListDetailt() this.searchListDetailt()
}, },
// 增加交换件 // 增加交换件
addListDetailinfor() { addListDetailinfor(form) {
this.$refs[form].validate((valid) => {
if (valid) {
addExchangepart(this.form.ExchangeNumber, this.tableData1[0].组件零件流水号, this.tableData1[0].物料流水号, this.tableData1[0].采购合同明细流水号, this.tableData2[0].组件零件流水号, this.tableData1[0].物料名称, this.tableData2[0].物料名称, this.tableData2[0].货位流水号, this.form.ExchangeNumberx, this.picikingPeople, this.form.ExchangeNote).then(response => { addExchangepart(this.form.ExchangeNumber, this.tableData1[0].组件零件流水号, this.tableData1[0].物料流水号, this.tableData1[0].采购合同明细流水号, this.tableData2[0].组件零件流水号, this.tableData1[0].物料名称, this.tableData2[0].物料名称, this.tableData2[0].货位流水号, this.form.ExchangeNumberx, this.picikingPeople, this.form.ExchangeNote).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('增加成功') this.$message.success('增加成功')
} else { this.$message.error('增加失败') } } else { this.$message.error('增加失败') }
}) }).then(() => {
this.dialogFormVisible = false this.dialogFormVisible = false
this.PageCurrent1 = 1
this.getExchangeTable() this.getExchangeTable()
})
}
})
}, },
// 打开交换表单 // 打开交换表单
exchange() { exchange(form) {
if (this.tableData1.length === 0) {
this.$message.error('请选择交换件')
} else if (this.tableData2.length === 0) {
this.$message.error('请选择交换件')
} else {
this.count1 = this.count1 + 1
if (this.count1 !== 1) {
this.$refs[form].resetFields()
}
this.title = '交换' this.title = '交换'
this.form.ExchangeNumber = ''
this.form.ExchangeNumberx = ''
this.form.ExchangeNote = ''
this.dialogFormVisible = true this.dialogFormVisible = true
}
}, },
// 重置表单 // 重置表单
callOff() { callOff(formName) {
this.form.ExchangeNumber = '' this.form.ExchangeNumber = ''
this.form.ExchangeNumberx = '' this.form.ExchangeNumberx = ''
this.form.ExchangeNote = '' this.form.ExchangeNote = ''
this.dialogFormVisible = false this.dialogFormVisible = false
this.$refs[formName].resetFields()
}, },
// 选中零件交换 // 选中零件交换
selecting(row) { selecting(row) {
const arr = new Array(row) const arr = new Array(row)
this.tableData1 = arr this.tableData1 = arr
console.log(this.tableData1)
}, },
// 选中被零件交换 // 选中被零件交换
selected(row) { selected(row) {
@@ -448,8 +488,9 @@ export default {
dropExchangeList(this.exchangeListNumber, this.eTeamPartNumber).then(response => { dropExchangeList(this.exchangeListNumber, this.eTeamPartNumber).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('删除成功') this.$message.success('删除成功')
this.getExchangeTable().then(response => { this.dialogFormVisible = false
}) this.PageCurrent1 = 1
this.getExchangeTable()
} else { } else {
this.$message.error('删除失败') this.$message.error('删除失败')
} }

View File

@@ -90,7 +90,7 @@
</template> </template>
<script> <script>
import { searchTable, insertOne, getinventory, getlocate } from '@/api/Inventory/Inboundscanning' import { searchTable, insertOne, getinventory, getlocate } from '@/api/Inventory/GenneralPart'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
import { wsuri, name } from '@/utils/request' import { wsuri, name } from '@/utils/request'
import print from '@/vendor/print' import print from '@/vendor/print'
@@ -245,7 +245,7 @@ export default {
this.locateName = [] this.locateName = []
this.locateNumber = '' this.locateNumber = ''
if (this.inventoryNumber) { if (this.inventoryNumber) {
this.getSelect(getlocate, ['货位名称'], 'locateName', this.inventoryNumber) this.getSelect(getlocate, ['货位名称', '货位流水号'], 'locateName', this.inventoryNumber)
} }
} }
} }

View File

@@ -76,6 +76,7 @@
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="primary" size="mini" class="el-icon-success" @click="Innumber">入库</el-button> <el-button type="primary" size="mini" class="el-icon-success" @click="Innumber">入库</el-button>
<el-button <el-button
:disabled="scope.row.是否禁用"
size="mini" size="mini"
type="danger" type="danger"
class="el-icon-delete" class="el-icon-delete"
@@ -178,6 +179,8 @@ export default {
if (response.data.length === 0) { if (response.data.length === 0) {
this.listLoading = false this.listLoading = false
this.$message.warning('无此零件') this.$message.warning('无此零件')
} else if (response.data[0].剩余数量 === 0) {
this.$message.warning('该零件已入库完毕')
} else { } else {
for (let i = 0; i < this.tableData.length; i++) { for (let i = 0; i < this.tableData.length; i++) {
if (response.data[0].工艺计划流水号 === this.tableData[i].工艺计划流水号) { if (response.data[0].工艺计划流水号 === this.tableData[i].工艺计划流水号) {
@@ -212,6 +215,9 @@ export default {
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
if (this.locateNumber === '') {
this.$message.error('请选择货位')
} else {
for (let i = 0; i < this.tableData.length; i++) { for (let i = 0; i < this.tableData.length; i++) {
if (this.tableData[i].innumber > this.tableData[i].plannumber) { if (this.tableData[i].innumber > this.tableData[i].plannumber) {
this.tableData[i].innumber = this.tableData[i].plannumber this.tableData[i].innumber = this.tableData[i].plannumber
@@ -225,6 +231,7 @@ export default {
this.Empty() this.Empty()
}) })
} }
}
}).catch(() => { }).catch(() => {
this.$message({ this.$message({
type: 'info', type: 'info',

File diff suppressed because it is too large Load Diff

View File

@@ -45,17 +45,14 @@
{{ scope.row.领用人 }} {{ scope.row.领用人 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" min-width="100" align="center" fixed="right"> <el-table-column label="操作" min-width="100" align="center" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
icon="el-icon-edit" icon="el-icon-edit"
type="primary" type="primary"
@click="handleEdit(scope.row)">修改</el-button> @click="handleEdit(scope.$index, scope.row, 'form')">修改</el-button>
</template>
</el-table-column>
<el-table-column label="操作" min-width="100" align="center" fixed="right">
<template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
type="danger" type="danger"
@@ -100,6 +97,11 @@
{{ scope.row.仓库名称 }} {{ scope.row.仓库名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="追溯码" width="150">
<template slot-scope="scope">
<canvas :id="canvas[scope.$index]"/>
</template>
</el-table-column>
<el-table-column label="操作" min-width="100" align="center" fixed="right"> <el-table-column label="操作" min-width="100" align="center" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@@ -117,14 +119,15 @@
</el-table> </el-table>
</el-card> </el-card>
<!--仓库表单--> <!--仓库表单-->
<el-dialog :visible.sync="dialogFormVisible" title="增加仓库" center style="min-height: 300px" width="400px"> <el-dialog :visible.sync="dialogFormVisible" title="增加仓库" center width="450px">
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm"> <el-form ref="form" :model="form" :rules="rules" label-position="center" label-width="110px" class="demo-ruleForm">
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="仓库编号" prop="WarehouseNumber"> <el-form-item label="仓库编号" prop="WarehouseNumber">
<el-input <el-input
v-model="form.WarehouseNumber" v-model="form.WarehouseNumber"
size="small" size="small"
clearable
style="width:200px"/> style="width:200px"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
@@ -135,6 +138,7 @@
<el-input <el-input
v-model="form.WarehouseName" v-model="form.WarehouseName"
size="small" size="small"
clearable
style="width:200px"/> style="width:200px"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
@@ -145,6 +149,7 @@
<el-input <el-input
v-model="form.WarehouseDescription" v-model="form.WarehouseDescription"
size="small" size="small"
clearable
style="width:200px"/> style="width:200px"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
@@ -154,6 +159,7 @@
<el-form-item label="地址" prop="Address"> <el-form-item label="地址" prop="Address">
<el-input <el-input
v-model="form.Address" v-model="form.Address"
clearable
size="small" size="small"
style="width:200px"/> style="width:200px"/>
</el-form-item> </el-form-item>
@@ -161,10 +167,10 @@
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="领用者" prop="TotalContractAmount" label-width="100px"> <el-form-item label="联系人" prop="ContactpeopleValue">
<el-select v-model="PeopleValue" filterable clearable size="small" placeholder="领用者" style="width: 200px;margin-right:10px" @change="searchGroupList()"> <el-select v-model="form.ContactpeopleValue" clearable filterable size="small" placeholder="领用者" style="width: 200px;margin-right:10px">
<el-option <el-option
v-for="item in People" v-for="item in Contactpeople"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
@@ -177,6 +183,7 @@
<el-form-item label="备注" prop="Note"> <el-form-item label="备注" prop="Note">
<el-input <el-input
v-model="form.Note" v-model="form.Note"
clearable
size="small" size="small"
style="width:200px"/> style="width:200px"/>
</el-form-item> </el-form-item>
@@ -213,7 +220,7 @@
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="永久" prop="永久"> <el-form-item label="是否永久" prop="永久">
<el-input <el-input
v-model="form2.永久" v-model="form2.永久"
size="small" size="small"
@@ -241,9 +248,12 @@
</template> </template>
<script> <script>
import { initWarehouse, addWarehouse, alterWarehouse, deleteWarehouse, searchLocate, addLocate, alterLocate, deleteLocate, searchPeople } from '@/api/Inventory/InventoryManagement' import { initWarehouse, addWarehouse, alterWarehouse, deleteWarehouse, searchLocate, addLocate, alterLocate, deleteLocate, searchPeople } from '@/api/Inventory/InventoryManagement'
import QRCode from 'qrcode'
export default { export default {
data() { data() {
return { return {
Contactpeople: [], // 联系人
count2: 0, // 清表单验证计数器
tableData: [], tableData: [],
tableData2: [], tableData2: [],
wareHouse: '', wareHouse: '',
@@ -254,10 +264,12 @@ export default {
WarehouseName: '', // 仓库名称 WarehouseName: '', // 仓库名称
WarehouseDescription: '', // 仓库描述 WarehouseDescription: '', // 仓库描述
Address: '', // 地址 Address: '', // 地址
ContactpeopleValue: '',
Note: '' // 备注 Note: '' // 备注
}, },
rules: { // 表单验证规则 rules: { // 表单验证规则
WarehouseNumber: [{ required: true, message: '请输入仓库编号', trigger: 'change' }], WarehouseNumber: [{ required: true, message: '请输入仓库编号', trigger: 'blur' }],
ContactpeopleValue: [{ required: true, message: '请选择联系人', trigger: 'change' }],
WarehouseName: [{ required: true, message: '请输入仓库名称', trigger: 'blur' }], WarehouseName: [{ required: true, message: '请输入仓库名称', trigger: 'blur' }],
WarehouseDescription: [{ required: true, message: '请输入仓库描述', trigger: 'blur' }], WarehouseDescription: [{ required: true, message: '请输入仓库描述', trigger: 'blur' }],
Address: [{ required: true, message: '请输入地址', trigger: 'blur' }], Address: [{ required: true, message: '请输入地址', trigger: 'blur' }],
@@ -294,7 +306,6 @@ export default {
this.listLoading = true this.listLoading = true
initWarehouse().then(response => { initWarehouse().then(response => {
this.listLoading = false this.listLoading = false
console.log(response)
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.tableData.push({ this.tableData.push({
仓库流水号: response.data[i].仓库流水号, 仓库流水号: response.data[i].仓库流水号,
@@ -302,8 +313,9 @@ export default {
仓库名称: response.data[i].仓库名称, 仓库名称: response.data[i].仓库名称,
仓库描述: response.data[i].仓库描述, 仓库描述: response.data[i].仓库描述,
地址: response.data[i].地址, 地址: response.data[i].地址,
联系人: response.data[i].联系人, 联系人: response.data[i].姓名,
备注: response.data[i].备注 备注: response.data[i].备注,
人员编号: response.data[i].人员编号
}) })
} }
}) })
@@ -313,11 +325,12 @@ export default {
this.getLocate() this.getLocate()
}, },
searchPeopleData() { // 查询人员 searchPeopleData() { // 查询人员
this.Contactpeople = []
searchPeople().then(response => { searchPeople().then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.People.push({ this.Contactpeople.push({
label: response.data[i].姓名, label: response.data[i].姓名,
value: response.data[i].考勤编号 value: response.data[i].人员编号
}) })
} }
}) })
@@ -334,6 +347,7 @@ export default {
不可用量: response.data[i].不可用量, 不可用量: response.data[i].不可用量,
仓库名称: response.data[i].仓库名称 仓库名称: response.data[i].仓库名称
}) })
this.useqrcode()
} }
}) })
}, },
@@ -355,19 +369,20 @@ export default {
this.form.WarehouseName = '' this.form.WarehouseName = ''
this.form.WarehouseDescription = '' this.form.WarehouseDescription = ''
this.form.Address = '' this.form.Address = ''
this.form.Contactpeople = '' this.form.ContactpeopleValue = ''
this.form.Note = '' this.form.Note = ''
this.temp = null this.temp = ''
} else if (this.temp === 2) { } else if (this.temp === 2) {
this.chaEdit() this.chaEdit()
this.temp = null this.temp = ''
} }
} }
}) })
}, },
// 执行增加仓库 // 执行增加仓库
addTableData() { addTableData() {
addWarehouse(this.form.WarehouseNumber, this.form.WarehouseName, this.form.WarehouseDescription, this.form.Address, this.PeopleValue, this.form.Note).then(response => { addWarehouse(this.form.WarehouseNumber, this.form.WarehouseName, this.form.WarehouseDescription, this.form.Address, this.form.ContactpeopleValue, this.form.Note).then(response => {
console.log(this.form.WarehouseNumber, this.form.WarehouseName, this.form.WarehouseDescription, this.form.Address, this.form.ContactpeopleValue, this.form.Note)
this.dialogFormVisible = false this.dialogFormVisible = false
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('添加成功') this.$message.success('添加成功')
@@ -375,7 +390,7 @@ export default {
this.form.WarehouseName = '' this.form.WarehouseName = ''
this.form.WarehouseDescription = '' this.form.WarehouseDescription = ''
this.form.Address = '' this.form.Address = ''
this.form.Contactpeople = '' this.form.ContactpeopleValue = ''
this.form.Note = '' this.form.Note = ''
} else { } else {
this.$message.error('添加失败') this.$message.error('添加失败')
@@ -384,29 +399,28 @@ export default {
}) })
}, },
// 编辑 // 编辑
handleEdit(row) { handleEdit(index, row, formName) {
console.log(row)
this.count2 = this.count2 + 1
if (this.count2 !== 1) {
this.$refs[formName].resetFields()
}
this.temp = 2 this.temp = 2
this.dialogFormVisible = true this.dialogFormVisible = true
this.form.WarehouseNumber = row.仓库编号 this.form.WarehouseNumber = row.仓库编号
this.form.WarehouseName = row.仓库名称 this.form.WarehouseName = row.仓库名称
this.form.WarehouseDescription = row.仓库描述 this.form.WarehouseDescription = row.仓库描述
this.form.Address = row.地址 this.form.Address = row.地址
this.form.Contactpeople = row.联系 this.form.ContactpeopleValue = row.员编号
this.form.Note = row.备注 this.form.Note = row.备注
this.HouseNumber = row.仓库流水号 this.HouseNumber = row.仓库流水号
}, },
// 执行修改 // 执行修改
chaEdit() { chaEdit() {
alterWarehouse(this.HouseNumber, this.form.WarehouseNumber, this.form.WarehouseName, this.form.WarehouseDescription, this.form.Address, this.form.Contactpeople, this.form.Note).then(response => { alterWarehouse(this.HouseNumber, this.form.WarehouseNumber, this.form.WarehouseName, this.form.WarehouseDescription, this.form.Address, this.form.ContactpeopleValue, this.form.Note).then(response => {
this.dialogFormVisible = false
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('信息更新成功') this.$message.success('信息更新成功')
this.form.WarehouseNumber = '' this.dialogFormVisible = false
this.form.WarehouseName = ''
this.form.WarehouseDescription = ''
this.form.Address = ''
this.form.Contactpeople = ''
this.form.Note = ''
this.getTable() this.getTable()
} else { } else {
this.$message.error('信息更新失败') this.$message.error('信息更新失败')
@@ -432,7 +446,6 @@ export default {
}, },
// 重置表单 // 重置表单
callOff(formName) { callOff(formName) {
console.log(1515)
this.form = {} this.form = {}
this.form2.ContractNumberValue = '' this.form2.ContractNumberValue = ''
this.form2.EntryName = '' this.form2.EntryName = ''
@@ -530,6 +543,15 @@ export default {
}) })
}) })
}, },
useqrcode() {
// 生成的二维码内容,可以添加变量
this.QueryDetail = this.num
var canvas = document.getElementById('canvas')
QRCode.toCanvas(canvas, this.QueryDetail, function(error) {
if (error) console.error(error)
console.log('success!')
})
},
// 重置表单 // 重置表单
callLocateOff(formName) { callLocateOff(formName) {
this.form2 = {} this.form2 = {}

View File

@@ -113,14 +113,14 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床图号" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="物料名称" align="center" min-width="80"> <el-table-column label="物料名称" align="center" min-width="80">
@@ -177,7 +177,8 @@ export default {
PeopleNumber: '', PeopleNumber: '',
tableDataOut: [], tableDataOut: [],
listLoading: '', listLoading: '',
listLoading1: '' listLoading1: '',
partnumber: ''
} }
}, },
computed: { computed: {
@@ -200,7 +201,6 @@ export default {
this.PeopleNumber = this.id this.PeopleNumber = this.id
}, },
searchMachine() { // 查询机床 searchMachine() { // 查询机床
console.log(1351)
if (this.ProjectValue === '') { if (this.ProjectValue === '') {
this.ProjectValue_check = 0 this.ProjectValue_check = 0
} }
@@ -243,6 +243,7 @@ export default {
}, },
// 打开表单 // 打开表单
parOut(row) { parOut(row) {
console.log(row)
this.form = [] this.form = []
this.MachineValue = '' this.MachineValue = ''
this.GroupNumValue = '' this.GroupNumValue = ''
@@ -250,6 +251,8 @@ export default {
this.contractNumber = row.离线合同明细流水号 this.contractNumber = row.离线合同明细流水号
this.locateNumber = row.货位流水号 this.locateNumber = row.货位流水号
this.materialNumber = row.物料流水号 this.materialNumber = row.物料流水号
this.partnumber = row.货位存量
console.log(this.partnumber)
this.searchoutRecord() this.searchoutRecord()
}, },
// 重置表单 // 重置表单
@@ -271,7 +274,9 @@ export default {
}, },
// 离线外购件出库 // 离线外购件出库
addDirectPartm() { addDirectPartm() {
console.log(this.contractNumber, this.PeopleValue, this.form.DirectNumber, this.locateNumber, this.form.DirectNote, this.form.ProjectValue, this.MachineValue, this.GroupNumValue, this.materialNumber, this.PeopleNumber) if (this.partnumber < this.form.DirectNumber) {
this.$message.error('请正确输入数量')
} else {
outlinePartOut(this.contractNumber, this.PeopleValue, this.form.DirectNumber, this.locateNumber, this.form.DirectNote, this.form.ProjectValue, this.MachineValue, this.GroupNumValue, this.materialNumber, this.PeopleNumber).then(response => { outlinePartOut(this.contractNumber, this.PeopleValue, this.form.DirectNumber, this.locateNumber, this.form.DirectNote, this.form.ProjectValue, this.MachineValue, this.GroupNumValue, this.materialNumber, this.PeopleNumber).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$notify({ this.$notify({
@@ -289,6 +294,7 @@ export default {
} }
} }
} }
}
</script> </script>
<style scoped> <style scoped>

View File

@@ -52,14 +52,14 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="130"> <el-table-column label="机床图号" align="center" min-width="130">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="130"> <el-table-column label="组" align="center" min-width="130">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="领用数量" align="center" min-width="130"> <el-table-column label="领用数量" align="center" min-width="130">
@@ -84,7 +84,7 @@
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" min-width="80"> <el-table-column label="操作" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button size="small" type="primary" icon="el-icon-back" style="margin: 0 0 0 0px" @click="partOut(scope.row)">出库</el-button> <el-button :disabled="scope.row.是否出库" size="small" type="primary" icon="el-icon-back" style="margin: 0 0 0 0px" @click="partOut(scope.row)">出库</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -93,7 +93,7 @@
</template> </template>
<script> <script>
import { searchList, searchListDetail, PurchasePart, BasicPart, WorkShopPart } from '@/api/Inventory/PartOut' import { searchList, searchListDetail, PurchasePart, BasicPart, WorkShopPart, ListDetailOut } from '@/api/Inventory/PartOut'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
export default { export default {
data() { data() {
@@ -113,6 +113,7 @@ export default {
tableDataPicking: [], // 领料单明细表格 tableDataPicking: [], // 领料单明细表格
listNumber: '', listNumber: '',
pickingListNumber: null, // 领料单编号 pickingListNumber: null, // 领料单编号
pickingListNumber_check: 1,
pickingListNumberx: '', // 领料单流水号 pickingListNumberx: '', // 领料单流水号
picikingPeople: '', // 领料人流水号 picikingPeople: '', // 领料人流水号
partProjectNumber: '', // 项目流水号 partProjectNumber: '', // 项目流水号
@@ -144,8 +145,14 @@ export default {
}, },
// 查询领料单 // 查询领料单
searchListinfor() { searchListinfor() {
if (this.pickingListNumber === null) {
this.pickingListNumber_check = 0
}
this.listLoading = true this.listLoading = true
searchList(this.pickingListNumber).then(response => { searchList(this.pickingListNumber_check, this.pickingListNumber).then(response => {
for (let i = 0; i < response.data.length; i++) {
response.data[i].领料时间 = response.data[i].领料时间.substring(0, response.data[i].领料时间.length - 8)
}
this.tableData1 = response.data this.tableData1 = response.data
this.listLoading = false this.listLoading = false
}) })
@@ -154,7 +161,11 @@ export default {
searchListDetailt() { searchListDetailt() {
this.listLoading1 = true this.listLoading1 = true
searchListDetail(this.pickingListNumberx).then(response => { searchListDetail(this.pickingListNumberx).then(response => {
this.tableDataPicking = response.data const data = response.data
for (let i = 0; i < data.length; i++) {
data[i].是否出库 === '1' ? data[i].是否禁用 = true : data[i].是否禁用 = false
}
this.tableDataPicking = data
this.listLoading1 = false this.listLoading1 = false
}) })
}, },
@@ -168,15 +179,17 @@ export default {
// 出库 // 出库
partOut(row) { partOut(row) {
console.log(row) console.log(row)
if (row.采购合同明细流水号 !== null) { if (row.车间外购 === 1) {
WorkShopPart(row.采购合同明细流水号, this.getpicikingPeople, row.出库数量, row.货位流水号, row.备注).then(response => { WorkShopPart(row.采购合同明细流水号, this.getpicikingPeople, row.出库数量, row.货位流水号, row.备注).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
ListDetailOut(row.领料单明细流水号)
this.$message.success('出库成功') this.$message.success('出库成功')
} else { this.$message.error('出库失败') } } else { this.$message.error('出库失败') }
}) })
} else if (row.零件类型 === 1 || row.零件类型 === 2) { } else if (row.零件类型 === 1 || row.零件类型 === 2) {
PurchasePart(row.组件零件流水号, this.getpicikingPeople, row.出库数量, row.货位流水号, row.备注).then(response => { PurchasePart(row.组件零件流水号, this.getpicikingPeople, row.出库数量, row.货位流水号, row.备注).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
ListDetailOut(row.领料单明细流水号)
this.$message.success('出库成功') this.$message.success('出库成功')
} else { this.$message.error('出库失败') } } else { this.$message.error('出库失败') }
}) })
@@ -184,9 +197,11 @@ export default {
BasicPart(row.工艺计划流水号, row.出库数量, row.收件信息ID, row.备注).then(response => { BasicPart(row.工艺计划流水号, row.出库数量, row.收件信息ID, row.备注).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('出库成功') this.$message.success('出库成功')
ListDetailOut(row.领料单明细流水号)
} else { this.$message.error('增加失败') } } else { this.$message.error('增加失败') }
}) })
} }
this.searchListDetailt()
} }
} }
} }

View File

@@ -24,7 +24,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="领料时间" align="center" min-width="200" > <el-table-column label="领料时间" align="center" min-width="200" >
<template slot-scope="scope"> <template slot-scope="scope" value-format="yyyy-MM-dd">
{{ scope.row.领料时间 }} {{ scope.row.领料时间 }}
</template> </template>
</el-table-column> </el-table-column>
@@ -81,14 +81,14 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="130"> <el-table-column label="机床图号" align="center" min-width="130">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="130"> <el-table-column label="组" align="center" min-width="130">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="领用数量" align="center" min-width="50"> <el-table-column label="领用数量" align="center" min-width="50">
@@ -153,14 +153,14 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床图号" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="零件名称" align="center" min-width="80"> <el-table-column label="零件名称" align="center" min-width="80">
@@ -168,11 +168,21 @@
{{ scope.row.零件名称 }} {{ scope.row.零件名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.批次数量 }}
</template>
</el-table-column>
<el-table-column label="库存数量" align="center" min-width="80"> <el-table-column label="库存数量" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.可出库数量 }} {{ scope.row.可出库数量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="待出库数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.待出库数量 }}
</template>
</el-table-column>
<el-table-column label="零件图号" align="center" min-width="80"> <el-table-column label="零件图号" align="center" min-width="80">
<template slot-scope="scope" align="center"> <template slot-scope="scope" align="center">
{{ scope.row.零件图号 }} {{ scope.row.零件图号 }}
@@ -230,14 +240,19 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床图号" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template>
</el-table-column>
<el-table-column label="数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.数量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="零件数量" align="center" min-width="80"> <el-table-column label="零件数量" align="center" min-width="80">
@@ -245,6 +260,11 @@
{{ scope.row.货位存量 }} {{ scope.row.货位存量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="待出库数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.待出库数量 }}
</template>
</el-table-column>
<el-table-column label="零件类型" align="center" min-width="80"> <el-table-column label="零件类型" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.类型名称 }} {{ scope.row.类型名称 }}
@@ -297,24 +317,34 @@
{{ scope.row.项目名称 }} {{ scope.row.项目名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床图号" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床图号 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.组号 }} {{ scope.row.组号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.数量 }}
</template>
</el-table-column>
<el-table-column label="零件数量" align="center" min-width="80"> <el-table-column label="零件数量" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.货位存量 }} {{ scope.row.货位存量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="待出库数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.待出库数量 }}
</template>
</el-table-column>
<el-table-column label="零件类型" align="center" min-width="80"> <el-table-column label="零件类型" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.零件类型 }} {{ scope.row.类型名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" min-width="80"> <el-table-column label="操作" align="center" min-width="80">
@@ -336,61 +366,61 @@
</el-card> </el-card>
<!--基本件领料对话框--> <!--基本件领料对话框-->
<el-dialog :visible.sync="dialogFormVisible1" title="基本件通用件领料" center width="380px"> <el-dialog :visible.sync="dialogFormVisible1" title="基本件通用件领料" center width="380px">
<el-form ref="form" :model="form" :rules="rules" label-position="left"> <el-form ref="form" :model="form" :rules="rules" label-position="left" class="demo-ruleForm">
<el-form-item label="出库数量" prop="ContractNumberValue" label-width="100px" size="small"> <el-form-item label="出库数量" prop="OutNumber" label-width="100px" size="small">
<el-input v-model="form.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/> <el-input v-model="form.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/>
</el-form-item> </el-form-item>
<el-form-item label="出库备注" prop="TotalContractAmount" label-width="100px"> <el-form-item label="出库备注" prop="outNote" label-width="100px">
<el-input v-model="form.outNote" size="small" placeholder="请输入备注" style="width: 200px"/> <el-input v-model="form.outNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button> <el-button @click="callOff('form')">取消</el-button>
<el-button type="primary" @click="addBasicListDetail()"> </el-button> <el-button type="primary" @click="addBasicListDetail('form')"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
<!--外购件领料对话框--> <!--外购件领料对话框-->
<el-dialog :visible.sync="dialogFormVisible" title="外购件标准件领料" center width="380px"> <el-dialog :visible.sync="dialogFormVisible" title="外购件标准件领料" center width="380px">
<el-form ref="form" :model="form" :rules="rules" label-position="left"> <el-form ref="form2" :model="form2" :rules="rules2" label-position="left" class="demo-ruleForm">
<el-form-item label="出库数量" prop="ContractNumberValue" label-width="100px" size="small"> <el-form-item label="出库数量" prop="OutNumber" label-width="100px" size="small">
<el-input v-model="form.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/>
</el-form-item>
<el-form-item label="出库备注" prop="TotalContractAmount" label-width="100px">
<el-input v-model="form.outNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button>
<el-button type="primary" @click="execaddListDetail()"> </el-button>
</div>
</el-dialog>
<!--车间采购件领料对话框-->
<el-dialog :visible.sync="dialogFormVisibleWork" title="车间采购件领料" center width="380px">
<el-form ref="form" :model="form" :rules="rules" label-position="left">
<el-form-item label="出库数量" prop="ContractNumberValue" label-width="100px" size="small">
<el-input v-model="form.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/>
</el-form-item>
<el-form-item label="出库备注" prop="TotalContractAmount" label-width="100px">
<el-input v-model="form.outNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button>
<el-button type="primary" @click="addWorkshopListDetail()"> </el-button>
</div>
</el-dialog>
<!--编辑领料明细对话框-->
<el-dialog :visible.sync="dialogFormVisible2" title="领料单明细" center width="380px">
<el-form ref="form2" :model="form2" :rules="rules" label-position="left">
<el-form-item label="出库数量" prop="ContractNumberValue" label-width="100px" size="small">
<el-input v-model="form2.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/> <el-input v-model="form2.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/>
</el-form-item> </el-form-item>
<el-form-item label="出库备注" prop="TotalContractAmount" label-width="100px"> <el-form-item label="出库备注" prop="outNote" label-width="100px">
<el-input v-model="form2.outNote" size="small" placeholder="请输入备注" style="width: 200px"/> <el-input v-model="form2.outNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="callOff('form2')">取消</el-button> <el-button @click="callOff('form')">取消</el-button>
<el-button type="primary" @click="execaddListDetail('form2')"> </el-button>
</div>
</el-dialog>
<!--车间采购件领料对话框-->
<el-dialog :visible.sync="dialogFormVisibleWork" title="车间采购件领料" center width="380px">
<el-form ref="form3" :model="form3" :rules="rules3" label-position="left" class="demo-ruleForm">
<el-form-item label="出库数量" prop="OutNumber" label-width="100px" size="small">
<el-input v-model="form3.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/>
</el-form-item>
<el-form-item label="出库备注" prop="outNote" label-width="100px">
<el-input v-model="form3.outNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button>
<el-button type="primary" @click="addWorkshopListDetail('form3')"> </el-button>
</div>
</el-dialog>
<!--编辑领料明细对话框-->
<el-dialog :visible.sync="dialogFormVisible2" title="领料单明细" center width="380px">
<el-form ref="form4" :model="form4" :rules="rules4" label-position="left" class="demo-ruleForm">
<el-form-item label="出库数量" prop="OutNumber" label-width="100px" size="small">
<el-input v-model="form4.OutNumber" size="small" placeholder="出库数量" style="width: 200px"/>
</el-form-item>
<el-form-item label="出库备注" prop="outNote" label-width="100px">
<el-input v-model="form4.outNote" size="small" placeholder="请输入备注" style="width: 200px"/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="callOff('form4')">取消</el-button>
<el-button type="primary" @click="submitChannge()"> </el-button> <el-button type="primary" @click="submitChannge()"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
@@ -437,11 +467,11 @@ export default {
ProjectValue: '', ProjectValue: '',
Project: [], Project: [],
ProjectValue_check: 1, ProjectValue_check: 1,
MachineValue: ' ', MachineValue: null,
Machine: [], Machine: [],
MachineValue_check: 1, MachineValue_check: 0,
GroupNumValue: ' ', GroupNumValue: null,
GroupNumValue_check: 1, GroupNumValue_check: 0,
GroupNum: [], GroupNum: [],
tableDataBasic: [], tableDataBasic: [],
tableDataPurchase: [], tableDataPurchase: [],
@@ -473,6 +503,22 @@ export default {
OutNumber: [{ required: true, message: '请输入出库数量', trigger: 'blur' }], OutNumber: [{ required: true, message: '请输入出库数量', trigger: 'blur' }],
outNote: [{ required: true, message: '请输入出库备注', trigger: 'blur' }] outNote: [{ required: true, message: '请输入出库备注', trigger: 'blur' }]
}, },
form3: {
OutNumber: '', // 出库数量
outNote: '' // 出库备注
},
rules3: { // 表单验证规则
OutNumber: [{ required: true, message: '请输入出库数量', trigger: 'blur' }],
outNote: [{ required: true, message: '请输入出库备注', trigger: 'blur' }]
},
form4: {
OutNumber: '', // 出库数量
outNote: '' // 出库备注
},
rules4: { // 表单验证规则
OutNumber: [{ required: true, message: '请输入出库数量', trigger: 'blur' }],
outNote: [{ required: true, message: '请输入出库备注', trigger: 'blur' }]
},
partType: '', // 零件类型 partType: '', // 零件类型
craftplannumber: '', // 工艺计划流水号 craftplannumber: '', // 工艺计划流水号
receive: '', // 收件信息ID receive: '', // 收件信息ID
@@ -508,7 +554,11 @@ export default {
tableDataHouse: [], tableDataHouse: [],
listLoadingx: '', listLoadingx: '',
purchaseDetailNum: '', purchaseDetailNum: '',
dialogFormVisibleWork: false dialogFormVisibleWork: false,
time: [],
materialLocate: '',
enableOut: '',
pickingListNumber_check: 1
} }
}, },
computed: { computed: {
@@ -530,8 +580,14 @@ export default {
console.log(this.picikingPeople) console.log(this.picikingPeople)
}, },
searchMachine() { // 查询机床 searchMachine() { // 查询机床
this.MachineValue = ''
this.Machine = []
this.GroupNumValue = ''
this.GroupNum = []
if (this.ProjectValue === '') { if (this.ProjectValue === '') {
this.ProjectValue_check = 0 this.ProjectValue_check = 0
} else {
this.ProjectValue_check = 1
} }
searchmachine(this.ProjectValue_check, this.ProjectValue).then(response => { searchmachine(this.ProjectValue_check, this.ProjectValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
@@ -543,6 +599,8 @@ export default {
}) })
}, },
searchGroupList() { // 查询组号 searchGroupList() { // 查询组号
this.GroupNumValue = ''
this.GroupNum = []
searchTeam(this.MachineValue).then(response => { searchTeam(this.MachineValue).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.GroupNum.push({ this.GroupNum.push({
@@ -555,14 +613,14 @@ export default {
searchPartinfo() { searchPartinfo() {
this.tableDataPurchase = [] this.tableDataPurchase = []
this.tableDataBasic = [] this.tableDataBasic = []
if (this.ProjectValue === ' ') { if (this.ProjectValue !== null && this.ProjectValue !== '') {
this.ProjectValue_check = 0 this.ProjectValue_check = 1
} }
if (this.MachineValue === ' ') { if (this.MachineValue !== null && this.MachineValue !== '') {
this.MachineValue_check = 0 this.MachineValue_check = 1
} }
if (this.GroupNumValue === ' ') { if (this.GroupNumValue !== null && this.GroupNumValue !== '') {
this.GroupNumValue_check = 0 this.GroupNumValue_check = 1
} }
this.listLoading = true this.listLoading = true
this.listLoading1 = true this.listLoading1 = true
@@ -587,23 +645,23 @@ export default {
}) })
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.PageCurrent = 1
this.PageSize = val
this.searchPartinfo()
},
handleCurrentChange(val) {
this.PageCurrent = val
this.searchPartinfo()
},
handleSizeChange1(val) {
this.PageCurrent1 = 1 this.PageCurrent1 = 1
this.PageSize1 = val this.PageSize1 = val
this.searchPartinfo() this.searchPartinfo()
}, },
handleCurrentChange1(val) { handleCurrentChange(val) {
this.PageCurrent1 = val this.PageCurrent1 = val
this.searchPartinfo() this.searchPartinfo()
}, },
handleSizeChange1(val) {
this.PageCurrent = 1
this.PageSize = val
this.searchPartinfo()
},
handleCurrentChange1(val) {
this.PageCurrent = val
this.searchPartinfo()
},
handleSizeChangex(val) { handleSizeChangex(val) {
this.PageCurrentx = 1 this.PageCurrentx = 1
this.PageSizex = val this.PageSizex = val
@@ -615,11 +673,18 @@ export default {
}, },
// 查询领料单 // 查询领料单
searchListinfor() { searchListinfor() {
if (this.pickingListNumber === null) {
this.pickingListNumber_check = 0
}
this.listLoading2 = true this.listLoading2 = true
searchList(this.PageCurrent2, this.PageSize2, this.pickingListNumber).then(response => { searchList(this.PageCurrent2, this.PageSize2, this.pickingListNumber_check, this.pickingListNumber).then(response => {
for (let i = 0; i < response.data.rows.length; i++) {
response.data.rows[i].领料时间 = response.data.rows[i].领料时间.substring(0, response.data.rows[i].领料时间.length - 8)
}
this.tableData1 = response.data.rows this.tableData1 = response.data.rows
this.listLoading2 = false this.listLoading2 = false
this.total2 = response.data.total this.total2 = response.data.total
console.log(response)
}) })
}, },
handleSizeChange2(val) { handleSizeChange2(val) {
@@ -707,9 +772,9 @@ export default {
this.partProjectNumber = row.项目流水号 this.partProjectNumber = row.项目流水号
this.partProjectName = row.项目名称 this.partProjectName = row.项目名称
this.partMachineNumber = row.机床流水号 this.partMachineNumber = row.机床流水号
this.partMachineName = row.机床名称 this.partMachineName = row.机床图号
this.partGroupNumber = row.组件流水号 this.partGroupNumber = row.组件流水号
this.partGroupName = row.件名称 this.partGroupName = row.
this.partType = row.零件类型 this.partType = row.零件类型
this.craftplannumber = row.工艺计划流水号 this.craftplannumber = row.工艺计划流水号
this.receive = row.收件信息id this.receive = row.收件信息id
@@ -721,15 +786,17 @@ export default {
this.materialName = row.零件名称 this.materialName = row.零件名称
this.materialType = row.零件类型名称 this.materialType = row.零件类型名称
this.materialNumber = row.零件图号 this.materialNumber = row.零件图号
console.log(this.receive, 41645) this.enableOut = row.可出库数量
}, },
addBasicListDetail() { addBasicListDetail(formName) {
if (this.pickingListNumberx === '') { if (this.pickingListNumberx === '') {
this.$message.error('请选择领料单') this.$message.error('请选择领料单')
} if (this.form.OutNumber === '') { } else if (this.form.OutNumber === '' || this.form.OutNumber > this.enableOut) {
this.$message.error('请输入领用数量') this.$message.error('请正确输入领用数量')
} } else {
addListDetail(this.pickingListNumberx, this.partProjectNumber, this.partMachineNumber, this.partGroupNumber, this.partProjectName, this.partMachineName, this.partGroupName, this.materialName, this.materialType, this.materialNumber, this.form.OutNumber, this.partType, this.form.outNote, this.craftplannumber, this.receive, this.teamPart, this.locatenumber).then(response => { this.$refs[formName].validate((valid) => {
if (valid) {
addListDetail(this.pickingListNumberx, this.partProjectNumber, this.partMachineNumber, this.partGroupNumber, this.partProjectName, this.partMachineName, this.partGroupName, this.materialName, this.materialType, this.materialNumber, this.form.OutNumber, this.partType, this.form.outNote, this.craftplannumber, this.receive, this.teamPart, this.locatenumber, 0, this.materialLocate).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('增加成功') this.$message.success('增加成功')
} else { } else {
@@ -738,6 +805,9 @@ export default {
}) })
this.dialogFormVisible1 = false this.dialogFormVisible1 = false
this.searchListinfor() this.searchListinfor()
}
})
}
}, },
// 增加外购件领料单明细 // 增加外购件领料单明细
addListDetailinfor(row) { addListDetailinfor(row) {
@@ -745,9 +815,9 @@ export default {
this.partProjectNumber = row.项目流水号 this.partProjectNumber = row.项目流水号
this.partProjectName = row.项目名称 this.partProjectName = row.项目名称
this.partMachineNumber = row.机床流水号 this.partMachineNumber = row.机床流水号
this.partMachineName = row.机床名称 this.partMachineName = row.机床图号
this.partGroupNumber = row.组件流水号 this.partGroupNumber = row.组件流水号
this.partGroupName = row.件名称 this.partGroupName = row.
this.partType = row.零件类型代码 this.partType = row.零件类型代码
this.craftplannumber = row.工艺计划流水号 this.craftplannumber = row.工艺计划流水号
this.receive = row.收件信息ID this.receive = row.收件信息ID
@@ -758,14 +828,18 @@ export default {
this.materialType = row.物料规格 this.materialType = row.物料规格
this.dialogFormVisible = true this.dialogFormVisible = true
this.purchaseDetailNum = row.采购合同明细流水号 this.purchaseDetailNum = row.采购合同明细流水号
this.materialLocate = row.物料与货位对照流水号
this.enableOut = row.货位存量
}, },
execaddListDetail() { execaddListDetail(formName) {
if (this.pickingListNumberx === '') { if (this.pickingListNumberx === '') {
this.$message.error('请选择领料单') this.$message.error('请选择领料单')
} else if (this.OutNumber === '') { } else if (this.form2.OutNumber === '' || this.form2.OutNumber > this.enableOut) {
this.$message.error('请输入领用数量') this.$message.error('请正确输入领用数量')
} else { } else {
addListDetail(this.pickingListNumberx, this.partProjectNumber, this.partMachineNumber, this.partGroupNumber, this.partProjectName, this.partMachineName, this.partGroupName, this.materialName, this.materialType, this.materialNumber, this.form.OutNumber, this.partType, this.form.outNote, this.craftplannumber, this.receive, this.teamPart, this.locatenumber).then(response => { this.$refs[formName].validate((valid) => {
if (valid) {
addListDetail(this.pickingListNumberx, this.partProjectNumber, this.partMachineNumber, this.partGroupNumber, this.partProjectName, this.partMachineName, this.partGroupName, this.materialName, this.materialType, this.materialNumber, this.form2.OutNumber, this.partType, this.form2.outNote, this.craftplannumber, this.receive, this.teamPart, this.purchaseDetailNum, this.locatenumber, 0, this.materialLocate).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('增加成功') this.$message.success('增加成功')
} else { } else {
@@ -773,8 +847,10 @@ export default {
} }
}) })
} }
})
this.dialogFormVisible = false this.dialogFormVisible = false
this.searchListinfor() this.searchListinfor()
}
}, },
// 增加车间采购领料单明细 // 增加车间采购领料单明细
addWorkshopDetailinfor(row) { addWorkshopDetailinfor(row) {
@@ -782,9 +858,9 @@ export default {
this.partProjectNumber = row.项目流水号 this.partProjectNumber = row.项目流水号
this.partProjectName = row.项目名称 this.partProjectName = row.项目名称
this.partMachineNumber = row.机床流水号 this.partMachineNumber = row.机床流水号
this.partMachineName = row.机床名称 this.partMachineName = row.机床图号
this.partGroupNumber = row.组件流水号 this.partGroupNumber = row.组件流水号
this.partGroupName = row.件名称 this.partGroupName = row.
this.partType = row.零件类型 this.partType = row.零件类型
this.receive = row.收件信息ID this.receive = row.收件信息ID
this.locatenumber = row.货位流水号 this.locatenumber = row.货位流水号
@@ -793,14 +869,19 @@ export default {
this.materialType = row.物料规格 this.materialType = row.物料规格
this.dialogFormVisibleWork = true this.dialogFormVisibleWork = true
this.purchaseDetailNum = row.采购合同明细流水号 this.purchaseDetailNum = row.采购合同明细流水号
this.materialLocate = row.物料与货位对照流水号
this.enableOut = row.货位存量
console.log(this.enableOut)
}, },
addWorkshopListDetail() { addWorkshopListDetail(formName) {
this.$refs[formName].validate((valid) => {
if (valid) {
if (this.pickingListNumberx === '') { if (this.pickingListNumberx === '') {
this.$message.error('请选择领料单') this.$message.error('请选择领料单')
} else if (this.OutNumber === '') { } else if (this.form3.OutNumber === '' || this.form3.OutNumber > this.enableOut) {
this.$message.error('请输入领用数量') this.$message.error('请正确输入领用数量')
} else { } else {
addListDetail(this.pickingListNumberx, this.partProjectNumber, this.partMachineNumber, this.partGroupNumber, this.partProjectName, this.partMachineName, this.partGroupName, this.materialName, this.materialType, this.materialNumber, this.form.OutNumber, this.partType, this.form.outNote, this.craftplannumber, this.receive, this.teamPart, this.purchaseDetailNum, this.locatenumber).then(response => { addListDetail(this.pickingListNumberx, this.partProjectNumber, this.partMachineNumber, this.partGroupNumber, this.partProjectName, this.partMachineName, this.partGroupName, this.materialName, this.materialType, this.materialNumber, this.form3.OutNumber, this.partType, this.form3.outNote, this.craftplannumber, this.receive, this.teamPart, this.purchaseDetailNum, this.locatenumber, 1, this.materialLocate).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('增加成功') this.$message.success('增加成功')
} else { } else {
@@ -808,6 +889,8 @@ export default {
} }
}) })
} }
}
})
this.dialogFormVisibleWork = false this.dialogFormVisibleWork = false
this.searchListinfor() this.searchListinfor()
}, },
@@ -817,7 +900,7 @@ export default {
this.pickingListDetail = row.领料单明细流水号 this.pickingListDetail = row.领料单明细流水号
}, },
submitChannge() { submitChannge() {
editListDetail(this.pickingListDetail, this.form2.OutNumber, this.form2.outNote).then(response => { editListDetail(this.pickingListDetail, this.form4.OutNumber, this.form4.outNote).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('修改成功') this.$message.success('修改成功')
} else { } else {

View File

@@ -3,8 +3,8 @@
<el-card> <el-card>
<span style="margin: 5px">替换单编号</span> <span style="margin: 5px">替换单编号</span>
<el-input v-model="substituteNumber" clearable size="small" style="width:200px" /> <el-input v-model="substituteNumber" clearable size="small" style="width:200px" />
<span style="margin: 5px">零件图号</span> <span style="margin: 5px">替换件名称</span>
<el-input v-model="partNumber" clearable size="small" style="width:200px" /> <el-input v-model="subPartName" clearable size="small" style="width:200px" />
<el-button size="small" type="success" icon="el-icon-search" style="margin: 0 0 0 10px" @click="getSubstitutedCard()">查询</el-button> <el-button size="small" type="success" icon="el-icon-search" style="margin: 0 0 0 10px" @click="getSubstitutedCard()">查询</el-button>
</el-card> </el-card>
<el-card> <el-card>
@@ -65,8 +65,10 @@ export default {
data() { data() {
return { return {
tableDataExchange: [], tableDataExchange: [],
substituteNumber: '', check1: 0,
partNumber: '', check2: 0,
substituteNumber: '', // 替换单编号
subPartName: '', // 替换件名称
listLoading: '', listLoading: '',
subList: '', subList: '',
locateNumber: '', locateNumber: '',
@@ -77,7 +79,9 @@ export default {
// 替换单查询 // 替换单查询
getSubstitutedCard() { getSubstitutedCard() {
this.listloading = true this.listloading = true
searchSubstitutedCard().then(response => { this.substituteNumber ? this.check1 = 1 : this.check1 = 0
this.subPartName ? this.check2 = 1 : this.check2 = 0
searchSubstitutedCard(this.check1, this.substituteNumber, this.check2, this.subPartName).then(response => {
this.tableDataExchange = response.data this.tableDataExchange = response.data
this.listloading = false this.listloading = false
}) })

View File

@@ -46,12 +46,12 @@
</el-table-column> </el-table-column>
<el-table-column label="机床名称" align="center" min-width="80"> <el-table-column label="机床名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.机床名称 }} {{ scope.row.机床图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="组件名称" align="center" min-width="80"> <el-table-column label="组件名称" align="center" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.件名称 }} {{ scope.row. }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="物料名称" align="center" min-width="80"> <el-table-column label="物料名称" align="center" min-width="80">

View File

@@ -4,13 +4,11 @@
<span>项目名称:</span> <span>项目名称:</span>
<el-select <el-select
v-model="entryNameValue" v-model="entryNameValue"
:remote-method="remoteMethod"
placeholder="项目名称" placeholder="项目名称"
style="width:200px" style="width:200px"
size="small" size="small"
clearable clearable
filterable filterable
remote
@change="empty"> @change="empty">
<el-option <el-option
v-for="item in entryName" v-for="item in entryName"
@@ -19,9 +17,9 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span>机床号:</span> <span>机床号:</span>
<el-input v-model="machineToolNumber" placeholder="机床号" size="small" clearable style="width:200px" @change="empty1" @dblclick.native="SearchMachine"/> <el-input v-model="machineToolNumber" placeholder="请双击选择" size="small" clearable style="width:200px" @change="empty1" @dblclick.native="SearchMachine"/>
<span>组号:</span> <span>组号:</span>
<el-input v-model="groupNumber" placeholder="组号" size="small" clearable style="width:200px" @dblclick.native="searchGroupList"/> <el-input v-model="groupNumber" placeholder="请双击选择" size="small" clearable style="width:200px" @dblclick.native="searchGroupList"/>
<span>:</span> <span>:</span>
<el-date-picker <el-date-picker
v-model="year" v-model="year"
@@ -54,7 +52,7 @@
v-loading="loading" v-loading="loading"
:data="tableData" :data="tableData"
style="width: 100%;max-height: 600px" style="width: 100%;max-height: 600px"
height="600" height="300"
highlight-current-row highlight-current-row
border> border>
<el-table-column align="center" label="序号" type="index" width="60"/> <el-table-column align="center" label="序号" type="index" width="60"/>
@@ -105,7 +103,140 @@
@current-change="handleCurrentChange"/> @current-change="handleCurrentChange"/>
</div> </div>
</el-card> </el-card>
<el-card>
<el-table
v-loading="listLoading1"
:data="tableDataPurchase"
border
style="width: 100%;"
height="300">
<el-table-column
label="序号"
align="center"
type="index"
width="50"/>
<el-table-column label="物料名称" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.物料名称 }}
</template>
</el-table-column>
<el-table-column label="物料规格" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.物料规格 }}
</template>
</el-table-column>
<el-table-column label="物料型号" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.物料型号 }}
</template>
</el-table-column>
<el-table-column label="项目名称" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.项目名称 }}
</template>
</el-table-column>
<el-table-column label="机床图号" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="组号" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column label="零件数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.货位存量 }}
</template>
</el-table-column>
<el-table-column label="零件类型" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.类型名称 }}
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent4"
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize4"
:total="total4"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange4"
@current-change="handleCurrentChange4"/>
</div>
</el-card>
<el-card>
<el-table
v-loading="listLoading2"
:data="tableData1"
border
style="width: 100%;"
height="300">
<el-table-column
label="序号"
align="center"
type="index"
width="50"/>
<el-table-column label="物料名称" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.物料名称 }}
</template>
</el-table-column>
<el-table-column label="物料规格" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.物料规格 }}
</template>
</el-table-column>
<el-table-column label="物料型号" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.物料型号 }}
</template>
</el-table-column>
<el-table-column label="项目名称" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.项目名称 }}
</template>
</el-table-column>
<el-table-column label="机床图号" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="组号" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column label="零件数量" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.货位存量 }}
</template>
</el-table-column>
<el-table-column label="零件类型" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.类型名称 }}
</template>
</el-table-column>
<el-table-column label="入库时间" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.入库时间 }}
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent5"
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize5"
:total="total5"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange5"
@current-change="handleCurrentChange5"/>
</div>
</el-card>
<el-dialog :visible.sync="dialogFormVisible2" title="选择机床" center style="min-height: 300px"> <el-dialog :visible.sync="dialogFormVisible2" title="选择机床" center style="min-height: 300px">
<el-table <el-table
:data="tableData6" :data="tableData6"
@@ -155,7 +286,9 @@
@size-change="handleSizeChange1" @size-change="handleSizeChange1"
@current-change="handleCurrentChange1"/> @current-change="handleCurrentChange1"/>
</div> </div>
<el-button type="primary" style="margin-left: 350px;margin-top: 20px" @click="submitName">提交</el-button> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitName">提交</el-button>
</div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogFormVisible3" title="选择组号" center style="min-height: 300px"> <el-dialog :visible.sync="dialogFormVisible3" title="选择组号" center style="min-height: 300px">
@@ -202,13 +335,15 @@
@size-change="handleSizeChange3" @size-change="handleSizeChange3"
@current-change="handleCurrentChange3"/> @current-change="handleCurrentChange3"/>
</div> </div>
<el-button type="primary" style="margin-left: 350px;margin-top: 20px" @click="submitGroup">提交</el-button> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitGroup">提交</el-button>
</div>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
<script> <script>
import { initProject, searchTable, searchmachine, searchgroup } from '@/api/ManufacturingCenter/GroupMatching' import { initProject, searchTable, searchmachine, searchgroup, searchPurchaseTable, searchTable1 } from '@/api/ManufacturingCenter/GroupMatching'
export default { export default {
data() { data() {
return { return {
@@ -228,17 +363,25 @@ export default {
pageSize1: 10, pageSize1: 10,
pageCurrent2: 1, pageCurrent2: 1,
pageSize2: 10, pageSize2: 10,
pageCurrent4: 1,
pageSize4: 10,
pageCurrent5: 1,
pageSize5: 10,
tableData7: [], tableData7: [],
tableData6: [], tableData6: [],
tableData: [], tableData: [],
tableData1: [],
state: null, state: null,
total: null, listLoading1: false,
total1: null, listLoading2: false,
total2: null, total: 0,
total1: 0,
total2: 0,
total4: 0,
total5: 0,
title: '', title: '',
dialogFormVisible2: false, dialogFormVisible2: false,
dialogFormVisible3: false, dialogFormVisible3: false,
List: [],
check: null, check: null,
check1: null, check1: null,
check2: null, check2: null,
@@ -285,17 +428,18 @@ export default {
}, { }, {
value: 12, value: 12,
label: '12' label: '12'
}] }],
tableDataPurchase: []
} }
}, },
created() { created() {
},
mounted() {
this.getList() this.getList()
}, },
methods: { methods: {
searchData() { searchData() {
this.loading = true this.loading = true
this.listLoading1 = true
this.listLoading2 = true
if (this.entryNameValue !== null && this.entryNameValue !== '') { if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') { if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1 this.check = 1
@@ -340,36 +484,33 @@ export default {
this.total = parseInt(response.data.total) this.total = parseInt(response.data.total)
this.loading = false this.loading = false
}) })
searchPurchaseTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
console.log(response)
this.tableDataPurchase = response.data.rows
this.listLoading1 = false
this.total4 = parseInt(response.data.total)
})
searchTable1(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
console.log(response)
this.tableData1 = response.data.rows
this.listLoading2 = false
this.total5 = parseInt(response.data.total)
})
} else { } else {
this.loading = false this.loading = false
this.$message.warning('请先选择项目') this.$message.warning('请先选择项目')
} }
}, },
getList() { // 初始化项目名称 getList() { // 初始化项目名称
this.list = []
initProject().then(response => { initProject().then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.list.push({ this.entryName.push({
label: response.data[i].项目名称, label: response.data[i].项目名称,
value: response.data[i].项目流水号 value: response.data[i].项目流水号
}) })
} }
}) })
}, },
remoteMethod(query) {
if (query !== '') {
setTimeout(() => {
this.entryName = this.list.filter(item => {
if (item.label !== null) {
return item.label.toLowerCase()
.indexOf(query.toLowerCase()) > -1
}
})
}, 1000)
} else {
this.entryName = []
}
},
empty() { empty() {
this.machineToolNumber = '' this.machineToolNumber = ''
this.groupNumber = '' this.groupNumber = ''
@@ -427,11 +568,105 @@ export default {
handleSizeChange(val) { handleSizeChange(val) {
this.pageCurrent = 1 this.pageCurrent = 1
this.pageSize = val this.pageSize = val
this.searchData() if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1
} else {
this.check = 0
}
if (this.machineToolNumber !== '') {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.groupNumber !== '') {
this.check2 = 1
} else {
this.check2 = 0
}
if (this.year !== null && this.year !== '') {
this.check3 = 1
} else {
this.check3 = 0
}
if (this.month !== null && this.month !== '') {
this.check4 = 1
} else {
this.check4 = 0
}
if (this.time !== '' && this.time !== null) {
this.check5 = 1
} else {
this.check5 = 0
}
searchTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
for (let i = 0; i < response.data.rows.length; i++) {
if (response.data.rows[i].入库时间 !== null) {
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
}
if (response.data.rows[i].计划完成时间 !== null) {
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
}
}
this.tableData = response.data.rows
this.total = parseInt(response.data.total)
this.loading = false
})
} else {
this.loading = false
this.$message.warning('请先选择项目')
}
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
this.pageCurrent = val this.pageCurrent = val
this.searchData() if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1
} else {
this.check = 0
}
if (this.machineToolNumber !== '') {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.groupNumber !== '') {
this.check2 = 1
} else {
this.check2 = 0
}
if (this.year !== null && this.year !== '') {
this.check3 = 1
} else {
this.check3 = 0
}
if (this.month !== null && this.month !== '') {
this.check4 = 1
} else {
this.check4 = 0
}
if (this.time !== '' && this.time !== null) {
this.check5 = 1
} else {
this.check5 = 0
}
searchTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
for (let i = 0; i < response.data.rows.length; i++) {
if (response.data.rows[i].入库时间 !== null) {
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
}
if (response.data.rows[i].计划完成时间 !== null) {
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
}
}
this.tableData = response.data.rows
this.total = parseInt(response.data.total)
this.loading = false
})
} else {
this.loading = false
this.$message.warning('请先选择项目')
}
}, },
handleSizeChange1(val) { handleSizeChange1(val) {
this.pageCurrent1 = 1 this.pageCurrent1 = 1
@@ -450,6 +685,184 @@ export default {
handleCurrentChange3(val) { handleCurrentChange3(val) {
this.pageCurrent2 = val this.pageCurrent2 = val
this.searchGroupList() this.searchGroupList()
},
handleSizeChange4(val) {
this.pageCurrent4 = 1
this.pageSize4 = val
if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1
} else {
this.check = 0
}
if (this.machineToolNumber !== '') {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.groupNumber !== '') {
this.check2 = 1
} else {
this.check2 = 0
}
if (this.year !== null && this.year !== '') {
this.check3 = 1
} else {
this.check3 = 0
}
if (this.month !== null && this.month !== '') {
this.check4 = 1
} else {
this.check4 = 0
}
if (this.time !== '' && this.time !== null) {
this.check5 = 1
} else {
this.check5 = 0
}
searchPurchaseTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent4, this.pageSize4).then(response => {
console.log(response)
this.tableDataPurchase = response.data.rows
this.listLoading1 = false
this.total4 = parseInt(response.data.total)
})
} else {
this.loading = false
this.$message.warning('请先选择项目')
}
},
handleCurrentChange4(val) {
this.pageCurrent4 = val
if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1
} else {
this.check = 0
}
if (this.machineToolNumber !== '') {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.groupNumber !== '') {
this.check2 = 1
} else {
this.check2 = 0
}
if (this.year !== null && this.year !== '') {
this.check3 = 1
} else {
this.check3 = 0
}
if (this.month !== null && this.month !== '') {
this.check4 = 1
} else {
this.check4 = 0
}
if (this.time !== '' && this.time !== null) {
this.check5 = 1
} else {
this.check5 = 0
}
searchPurchaseTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent4, this.pageSize4).then(response => {
console.log(response)
this.tableDataPurchase = response.data.rows
this.listLoading1 = false
this.total4 = parseInt(response.data.total)
})
} else {
this.loading = false
this.$message.warning('请先选择项目')
}
},
handleSizeChange5(val) {
this.pageCurrent5 = 1
this.pageSize5 = val
if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1
} else {
this.check = 0
}
if (this.machineToolNumber !== '') {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.groupNumber !== '') {
this.check2 = 1
} else {
this.check2 = 0
}
if (this.year !== null && this.year !== '') {
this.check3 = 1
} else {
this.check3 = 0
}
if (this.month !== null && this.month !== '') {
this.check4 = 1
} else {
this.check4 = 0
}
if (this.time !== '' && this.time !== null) {
this.check5 = 1
} else {
this.check5 = 0
}
searchTable1(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent5, this.pageSize5).then(response => {
console.log(response)
this.tableData1 = response.data.rows
this.listLoading2 = false
this.total5 = parseInt(response.data.total)
})
} else {
this.loading = false
this.$message.warning('请先选择项目')
}
},
handleCurrentChange5(val) {
this.pageCurrent5 = val
if (this.entryNameValue !== null && this.entryNameValue !== '') {
if (this.entryNameValue !== null && this.entryNameValue !== '') {
this.check = 1
} else {
this.check = 0
}
if (this.machineToolNumber !== '') {
this.check1 = 1
} else {
this.check1 = 0
}
if (this.groupNumber !== '') {
this.check2 = 1
} else {
this.check2 = 0
}
if (this.year !== null && this.year !== '') {
this.check3 = 1
} else {
this.check3 = 0
}
if (this.month !== null && this.month !== '') {
this.check4 = 1
} else {
this.check4 = 0
}
if (this.time !== '' && this.time !== null) {
this.check5 = 1
} else {
this.check5 = 0
}
searchTable1(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent5, this.pageSize5).then(response => {
console.log(response)
this.tableData1 = response.data.rows
this.listLoading2 = false
this.total5 = parseInt(response.data.total)
})
} else {
this.loading = false
this.$message.warning('请先选择项目')
}
} }
} }
} }

View File

@@ -143,24 +143,24 @@
{{ scope.row.零件类型名称 }} {{ scope.row.零件类型名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="是否外协" align="center" width="90"> <!--<el-table-column label="是否外协" align="center" width="90">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
<el-checkbox v-model="tableData[scope.$index].checked_waixie" @change="gaibianwaixie(scope.$index, scope.row)"/> <!--<el-checkbox v-model="tableData[scope.$index].checked_waixie" @change="gaibianwaixie(scope.$index, scope.row)"/>-->
外协 <!--外协-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column label="是否带料" align="center" width="90"> <!--<el-table-column label="是否带料" align="center" width="90">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
<el-checkbox :disabled="!tableData[scope.$index].checked_waixie" v-model="tableData[scope.$index].checked_dailiao"/> <!--<el-checkbox :disabled="!tableData[scope.$index].checked_waixie" v-model="tableData[scope.$index].checked_dailiao"/>-->
带料 <!--带料-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column label="是否着急" align="center" width="90"> <!--<el-table-column label="是否着急" align="center" width="90">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
<el-checkbox v-model="tableData[scope.$index].checked_zhaoji"/> <!--<el-checkbox v-model="tableData[scope.$index].checked_zhaoji"/>-->
着急 <!--着急-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<!--<el-table-column prop="name" label="打回原因" width="170" align="center">--> <!--<el-table-column prop="name" label="打回原因" width="170" align="center">-->
<!--<template slot-scope="scope">--> <!--<template slot-scope="scope">-->
<!--<el-input v-model="tableData[scope.$index].name" type="textarea" :rows="1" style="width:150px" placeholder="原因">--> <!--<el-input v-model="tableData[scope.$index].name" type="textarea" :rows="1" style="width:150px" placeholder="原因">-->
@@ -176,7 +176,7 @@
<el-button <el-button
size="mini" size="mini"
type="primary" type="primary"
@click="handleDele(scope.$index, scope.row, 'form1')">打回档案</el-button> @click="handleDele(scope.$index, scope.row, 'form1')">打回</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -190,16 +190,10 @@
layout="total, sizes, prev, pager, next, jumper" layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange" @size-change="handleSizeChange"
@current-change="handleCurrentChange"/> @current-change="handleCurrentChange"/>
<el-checkbox v-model="checked_baitu" style="margin-top:0px">是否白图</el-checkbox> <!--<el-checkbox v-model="checked_baitu" style="margin-top:0px">是否白图</el-checkbox>-->
<el-checkbox v-model="checked_gaonandu">是否高难度</el-checkbox> <!--<el-checkbox v-model="checked_gaonandu">是否高难度</el-checkbox>-->
<el-button type="primary" size="small" style="float:right;margin-top:10px" @click="production">投产</el-button> <el-button type="primary" size="small" style="float:right;margin-top:10px" @click="production">投产</el-button>
</div> </div>
<!--<el-row>-->
<!--<el-checkbox v-model="checked_baitu" style="margin-top:20px">是否白图</el-checkbox>-->
<!--<el-checkbox v-model="checked_gaonandu">是否高难度</el-checkbox>-->
<!--<el-button type="primary" size="small" @click="production" style="float:right;margin-top:10px">投产</el-button>-->
<!--</el-row>-->
</div> </div>
</el-card> </el-card>
@@ -236,14 +230,14 @@
label="批次数量"> label="批次数量">
<template slot-scope="scope">{{ scope.row.批次数量 }}</template> <template slot-scope="scope">{{ scope.row.批次数量 }}</template>
</el-table-column> </el-table-column>
<el-table-column <!--<el-table-column-->
label="是否外协"> <!--label="是否外协">-->
<template slot-scope="scope">{{ scope.row.是否外协 }}</template> <!--<template slot-scope="scope">{{ scope.row.是否外协 }}</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column <!--<el-table-column-->
label="是否带料"> <!--label="是否带料">-->
<template slot-scope="scope">{{ scope.row.是否带料 }}</template> <!--<template slot-scope="scope">{{ scope.row.是否带料 }}</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column <el-table-column
label="机加工开始时间"> label="机加工开始时间">
<template slot-scope="scope">{{ scope.row.机加工开始时间 }}</template> <template slot-scope="scope">{{ scope.row.机加工开始时间 }}</template>

View File

@@ -186,8 +186,8 @@
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
placeholder="选择日期"/> placeholder="选择日期"/>
<el-button type="success" size="small" icon="el-icon-star-off" style="margin-top: 15px; margin-left: 15px" @click="purchaseRequisition()">车间请购</el-button> <el-button type="success" size="small" icon="el-icon-star-off" style="margin-top: 15px; margin-left: 15px" @click="purchaseRequisition()">车间请购</el-button>
<el-button type="primary" size="small" icon="el-icon-star-off" style="margin-top: 15px; margin-left: 15px" @click="PurchasingDepartment()">采购部门采购</el-button> <el-button v-show="PartType!=='基本件'" type="primary" size="small" icon="el-icon-star-off" style="margin-top: 15px; margin-left: 15px" @click="PurchasingDepartment()">采购部门采购</el-button>
<el-button type="warning" size="small" icon="el-icon-star-off" style="margin-top: 15px; margin-left: 15px" @click="Production()">车间生产</el-button> <el-button v-show="PartType==='基本件'" type="warning" size="small" icon="el-icon-star-off" style="margin-top: 15px; margin-left: 15px" @click="Production()">车间生产</el-button>
</el-card> </el-card>
<el-card> <el-card>
<el-row> <el-row>
@@ -299,7 +299,7 @@
style="width:200px"/> style="width:200px"/>
</el-form-item> </el-form-item>
<el-form-item label="请购人" prop="请购人"> <el-form-item label="请购人">
<el-input <el-input
v-model="name" v-model="name"
size="small" size="small"
@@ -496,6 +496,12 @@ export default {
this.check4 = 0 this.check4 = 0
} }
searchTable1(this.PurchaseOrder, this.check4).then(response => { searchTable1(this.PurchaseOrder, this.check4).then(response => {
for (let i = 0; i < response.data.length; i++) {
console.log(response.data[i].请购时间)
if (response.data[i].请购时间 !== '') {
response.data[i].请购时间 = (response.data[i].请购时间).split(' ')[0]
}
}
this.tableData4 = response.data this.tableData4 = response.data
}) })
}, },
@@ -576,6 +582,11 @@ export default {
searchDetailed(row) { searchDetailed(row) {
this.RequisitionList = row.请购单流水号 this.RequisitionList = row.请购单流水号
searchDetailed(row.请购单流水号).then(response => { searchDetailed(row.请购单流水号).then(response => {
for (let i = 0; i < response.data.length; i++) {
if (response.data[i].物料计划到货时间 !== '') {
response.data[i].物料计划到货时间 = (response.data[i].物料计划到货时间).split(' ')[0]
}
}
this.tableData5 = response.data this.tableData5 = response.data
}) })
}, },

View File

@@ -0,0 +1,280 @@
<template>
<div class="app-container">
<el-card>
<span>工艺员:</span>
<el-select v-model="craftmenValue" placeholder="工艺员" size="small" style="width:100px" @change="searchParts()">
<el-option
v-for="item in craftmen"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>零件图号:</span>
<el-select v-model="partNumValue" filterable placeholder="零件图号" style="margin-right: 10px" size="small" clearable @clear="returnDate = ''">
<el-option
v-for="item in partNum"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="searchData()">查询</el-button>
<span>打回时间:</span>
<el-date-picker v-model="returnDate" :clearable="false" type="datetime" placeholder="打回时间" size="small" readonly/>
</el-card>
<el-row>
<el-col :span="12">
<el-card>
<div style="display: inline-block;margin-bottom: 20px">改前零件工艺</div>
<el-table id="div1" ref="div1" :data="tableData1" :row-class-name="tableRowClassName1" size="mini" border style="height:350px;overflow-y: auto;" @mouseenter.native="changeScrollBefore">
<el-table-column align="center" label="工序顺序" width="70px">
<template slot-scope="scope">
{{ scope.row.工序顺序 }}
</template>
</el-table-column>
<el-table-column align="center" label="工艺名称" width="120px">
<template slot-scope="scope">
{{ scope.row.工艺名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="难度等级" width="70px">
<template slot-scope="scope">
{{ scope.row.工艺难度等级 }}
</template>
</el-table-column>
<el-table-column header-align="center" label="工艺要求">
<template slot-scope="scope">
{{ scope.row.工艺要求 }}
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
<el-col :span="12">
<el-card style="margin-left:15px">
<div style="display: inline-block;margin-bottom: 20px">改后零件工艺</div>
<el-table id="div2" ref="div2" :data="tableData2" :row-class-name="tableRowClassName2" size="mini" border style="height:350px;overflow-y: scroll;" @mouseenter.native="changeScrollAfter">
<el-table-column align="center" label="工序顺序" width="70px">
<template slot-scope="scope">
{{ scope.row.工序顺序 }}
</template>
</el-table-column>
<el-table-column align="center" label="工艺名称" width="120px">
<template slot-scope="scope">
{{ scope.row.工艺名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="难度等级" width="70px">
<template slot-scope="scope">
{{ scope.row.工艺难度等级 }}
</template>
</el-table-column>
<el-table-column header-align="center" label="工艺要求">
<template slot-scope="scope">
{{ scope.row.工艺要求 }}
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
</el-row>
<el-card>
<div id="myChart" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
</el-card>
</div>
</template>
<script>
import echarts from 'echarts'
import { initCraftmen, searchPart, searchProcessOld, searchProcessNew, searchChart } from '@/api/ManufacturingCenter/ProcessAdjustQuery'
export default {
data() {
return {
returnDate: '',
craftmenValue: '',
craftmen: [],
partNumValue: '', // 工艺计划流水号
partNum: [],
partStatus: '',
tableData1: [],
tableData2: [],
dataX: [],
partsNum: []
}
},
created() {
this.fetchData()
this.searchChart()
},
methods: {
changeScrollBefore() {
const div1 = document.getElementById('div1')
const div2 = document.getElementById('div2')
div2.removeAttribute('onscroll')
div1.setAttribute('onscroll', 'document.getElementById(\'div2\').scrollTop = scrollTop')
},
changeScrollAfter() {
const div1 = document.getElementById('div1')
const div2 = document.getElementById('div2')
div1.removeAttribute('onscroll')
div2.setAttribute('onscroll', 'document.getElementById(\'div1\').scrollTop = scrollTop')
},
searchChart() {
searchChart().then(response => {
console.log(response, 11)
for (let i = 0; i < response.data.length; i++) {
this.dataX.push(response.data[i].姓名)
this.partsNum.push(response.data[i].零件数量)
}
this.drawLine()
})
},
drawLine() {
const myChart = echarts.init(document.getElementById('myChart'))
myChart.clear()
myChart.setOption({
title: {
text: '在制零件工艺调整统计',
left: 'center'
},
tooltip: {
trigger: 'axis',
axisPointer: {
type: 'shadow'
}
},
xAxis: {
type: 'category',
name: '工艺员',
data: this.dataX,
axisLabel: {
interval: 0,
rotate: 0,
margin: 10
}
},
yAxis: {
type: 'value',
name: '工艺被调整零件数',
min: 0,
minInterval: 1
},
series: [
{
name: '工艺调整零件数',
type: 'bar',
data: this.partsNum,
markLine: {
data: [
{ type: 'average', name: '平均值' }
]
}
}
]
})
},
fetchData() {
this.craftmen = []
initCraftmen().then(response => { // 初始化工艺员
for (let i = 0; i < response.data.length; i++) {
this.craftmen.push({
label: response.data[i].姓名,
value: response.data[i].人员编号
})
}
})
},
searchParts() {
this.tableData1 = []
this.tableData2 = []
this.partNum = []
this.partNumValue = ''
this.returnDate = ''
searchPart(this.craftmenValue).then(response => {
for (let i = 0; i < response.data.length; i++) {
this.partNum.push({
label: response.data[i].零件图号_零件工艺计划,
value: response.data[i].工艺计划流水号
})
}
})
},
searchData() {
this.tableData1 = []
this.tableData2 = []
if (this.partNumValue !== '' && this.partNumValue !== null) {
searchProcessOld(this.partNumValue).then(response => {
this.tableData1 = response.data
this.returnDate = response.data[0].操作时间
})
searchProcessNew(this.partNumValue).then(response => {
this.tableData2 = response.data
})
} else {
this.$message.error('请先选择零件')
}
},
tableRowClassName2({ row }) {
for (let i = 0; i < this.tableData1.length; i++) {
row.工艺编号 === null ? row.工艺编号 = 0 : row.工艺编号
if (this.tableData1[i].工序流水号 === row.工序流水号 && this.tableData1[i].工艺编号 !== null) {
if (this.tableData1[i].工艺编号 !== row.工艺编号 || this.tableData1[i].工艺要求 !== row.工艺要求 || this.tableData1[i].工艺难度等级 !== row.工艺难度等级) {
return 'change'
} else {
if (this.tableData1[i].工序顺序 !== row.工序顺序 && (row.工艺要求 || row.工艺难度等级)) {
return 'change'
} else {
return ''
}
}
}
}
},
tableRowClassName1({ row }) {
for (let i = 0; i < this.tableData2.length; i++) {
row.工艺编号 === null ? row.工艺编号 = 0 : row.工艺编号
if (this.tableData2[i].工序流水号 === row.工序流水号 && this.tableData2[i].工艺编号 !== null) {
if (this.tableData2[i].工艺编号 !== row.工艺编号 || this.tableData2[i].工艺要求 !== row.工艺要求 || this.tableData2[i].工艺难度等级 !== row.工艺难度等级) {
return 'change'
} else {
if (this.tableData1[i].工序顺序 !== row.工序顺序 && (row.工艺要求 || row.工艺难度等级)) {
return 'change'
} else {
return ''
}
}
}
}
}
}
}
</script>
<style>
.el-table .change {
background: oldlace;
}
</style>
<style scoped>
.el-card{
margin-bottom: 15px;
}
.el-date-editor{
width:200px
}
.el-select{
width:200px
}
.el-input{
width:200px
}
span{
margin: 10px 0 10px 10px;
}
.searchForm .el-form-item{
margin-bottom: 5px;
}
</style>

View File

@@ -10,11 +10,16 @@
partNumValue = '';typeValue = '';partName = ''; partNumValue = '';typeValue = '';partName = '';
material = '';materialName = '';spec = '';batchNum = ''; material = '';materialName = '';spec = '';batchNum = '';
searchParts()"> searchParts()">
<el-radio :label="1">未编制</el-radio> <el-radio v-model="radio" :label="1">未编制</el-radio>
<el-radio :label="2">已编制</el-radio> <el-radio v-model="radio" :label="2">已编制</el-radio>
</el-radio-group> </el-radio-group>
<span>工艺员:</span> <span>工艺员:</span>
<el-select v-model="CraftmenValue" placeholder="工艺员" size="small" style="width:100px" @change="clearDetail();searchParts()"> <el-select
v-model="CraftmenValue"
placeholder="工艺员"
size="small"
style="width:100px"
@change="clearDetail();searchParts()">
<el-option <el-option
v-for="item in Craftmen" v-for="item in Craftmen"
:key="item.value" :key="item.value"
@@ -22,16 +27,26 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span>零件号:</span> <span>零件号:</span>
<el-select v-model="partNumValue" filterable clearable placeholder="零件号" size="small" @clear="clearDetail" @change="searchParts"> <el-select
v-model="partNumValue"
filterable
clearable
placeholder="零件号"
size="small"
@clear="clearDetail"
@change="searchParts">
<el-option <el-option
v-for="item in partNum" v-for="item in partNum"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<el-button type="success" icon="el-icon-search" style="margin: 10px;" size="small" @click="searchDetail">查询</el-button> <el-button type="success" icon="el-icon-search" style="margin: 10px;" size="small" @click="searchDetail">查询
<el-button v-show="isShow2" type="danger" icon="el-icon-edit" size="small" @click="returnEdit">在制零件工艺调整</el-button> </el-button>
<el-button v-show="!isShow2" plain size="small" style="margin: 10px;float:right" @click="switchEdit()">切换编辑模式</el-button> <el-button v-show="isShow2" type="danger" icon="el-icon-edit" size="small" @click="returnEdit">在制零件工艺调整
</el-button>
<el-button v-show="!isShow2" plain size="small" style="margin: 10px;float:right" @click="switchEdit()">切换编辑模式
</el-button>
<div v-show="isShow"> <div v-show="isShow">
<span>种类:</span> <span>种类:</span>
<el-input v-model="typeValue" placeholder="种类" size="small" readonly style="width:100px"/> <el-input v-model="typeValue" placeholder="种类" size="small" readonly style="width:100px"/>
@@ -66,15 +81,26 @@
<el-input v-model="tolerance" size="small" style="width:150px" placeholder="公差"/> <el-input v-model="tolerance" size="small" style="width:150px" placeholder="公差"/>
<el-button style="margin:10px" type="primary" size="small" @click="calTol()">计算公差</el-button> <el-button style="margin:10px" type="primary" size="small" @click="calTol()">计算公差</el-button>
<el-button-group v-if="isShow1" style="margin: 10px"> <el-button-group v-if="isShow1" style="margin: 10px">
<el-button v-if="isShow1" type="info" size="small" icon="el-icon-tickets" @click="copyAndSave">复制并保存</el-button> <el-button v-if="isShow1" type="info" size="small" icon="el-icon-tickets" @click="copyAndSave">复制并保存
</el-button>
<el-button v-if="isShow1" type="info" size="small" icon="el-icon-document" @click="pasteTable">粘贴</el-button> <el-button v-if="isShow1" type="info" size="small" icon="el-icon-document" @click="pasteTable">粘贴</el-button>
<el-button :disabled="disabled" type="warning" size="small" icon="el-icon-tickets" @click="DYbtn">典艺</el-button> <el-button :disabled="disabled" type="warning" size="small" icon="el-icon-tickets" @click="DYbtn">典艺
<el-button :disabled="disabled" type="warning" size="small" icon="el-icon-tickets" @click="WYbtn">完艺</el-button> </el-button>
<el-button :disabled="disabled" type="danger" size="small" icon="el-icon-delete" @click="deleteTable">删除</el-button> <el-button :disabled="disabled" type="warning" size="small" icon="el-icon-tickets" @click="WYbtn">完艺
<el-button :disabled="disabled" type="primary" size="small" icon="el-icon-cjn-09" @click="saveApprove">保存</el-button> </el-button>
<el-button :disabled="disabled" type="danger" size="small" icon="el-icon-delete" @click="deleteTable">删除
</el-button>
<el-button :disabled="disabled" type="primary" size="small" icon="el-icon-cjn-09" @click="saveApprove">保存
</el-button>
</el-button-group> </el-button-group>
</el-row> </el-row>
<el-table v-loading="loading0" :data="tableData" :row-class-name="tableRowClassName" border style="width: 100%;max-height: 550px;" size="mini" height="550px"> <el-table
v-loading="loading0"
:data="tableData"
border
style="width: 100%;max-height: 550px;"
size="mini"
height="550px">
<el-table-column prop="num" label="序号" width="50" align="center" type="index"/> <el-table-column prop="num" label="序号" width="50" align="center" type="index"/>
<el-table-column prop="name" label="工艺名称" width="230" align="center"> <el-table-column prop="name" label="工艺名称" width="230" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -147,7 +173,13 @@
<el-dialog :visible.sync="dialogMaterial" title="材质选择" center width="400px"> <el-dialog :visible.sync="dialogMaterial" title="材质选择" center width="400px">
<el-input v-model="input" placeholder="材质" size="small" style="width:200px"/> <el-input v-model="input" placeholder="材质" size="small" style="width:200px"/>
<el-button type="success" size="small" icon="el-icon-search" style="margin: 0 0 10px 10px" @click="total=0;pageCurrent=1;pageSize=10;searchMaterial()">查询</el-button> <el-button
type="success"
size="small"
icon="el-icon-search"
style="margin: 0 0 10px 10px"
@click="total=0;pageCurrent=1;pageSize=10;searchMaterial()">查询
</el-button>
<el-table <el-table
:data="tableMaterial" :data="tableMaterial"
size="mini" size="mini"
@@ -217,7 +249,12 @@
<el-row> <el-row>
<el-col :span="10"> <el-col :span="10">
<el-form-item label="典型工艺零件分类"> <el-form-item label="典型工艺零件分类">
<el-select v-model="typicalClassValue" placeholder="分类" size="small" style="width:150px" @change="classChange()"> <el-select
v-model="typicalClassValue"
placeholder="分类"
size="small"
style="width:150px"
@change="classChange()">
<el-option <el-option
v-for="item in typicalClass" v-for="item in typicalClass"
:key="item.value" :key="item.value"
@@ -228,7 +265,13 @@
</el-col> </el-col>
<el-col :span="10"> <el-col :span="10">
<el-form-item label="零件名称"> <el-form-item label="零件名称">
<el-select id="name" v-model="partNameValue1" placeholder="零件名称" size="small" style="width:150px" @change="nameChange()"> <el-select
id="name"
v-model="partNameValue1"
placeholder="零件名称"
size="small"
style="width:150px"
@change="nameChange()">
<el-option <el-option
v-for="item in partName1" v-for="item in partName1"
:key="item.value" :key="item.value"
@@ -244,7 +287,13 @@
<el-row> <el-row>
<el-col :span="10"> <el-col :span="10">
<el-form-item label="典型工艺号"> <el-form-item label="典型工艺号">
<el-select id="num" v-model="processNumValue" placeholder="工艺号" style="width:150px" size="small" @change="numChange()"> <el-select
id="num"
v-model="processNumValue"
placeholder="工艺号"
style="width:150px"
size="small"
@change="numChange()">
<el-option <el-option
v-for="item in partName1" v-for="item in partName1"
:key="item.value" :key="item.value"
@@ -262,7 +311,12 @@
<el-button size="small" @click="processCopy()">工艺拷贝</el-button> <el-button size="small" @click="processCopy()">工艺拷贝</el-button>
</el-col> </el-col>
</el-row> </el-row>
<el-table :data="tableData2" style="width: 97%;max-height: 300px;margin-top:15px" height="300px" border size="mini"> <el-table
:data="tableData2"
style="width: 97%;max-height: 300px;margin-top:15px"
height="300px"
border
size="mini">
<el-table-column align="center" label="工艺序号" width="80"> <el-table-column align="center" label="工艺序号" width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.工艺序号 }} {{ scope.row.工艺序号 }}
@@ -292,7 +346,9 @@
<el-row> <el-row>
<el-col :span="10"> <el-col :span="10">
<el-form-item label="工艺员"> <el-form-item label="工艺员">
<el-input v-model="CraftmanValue" size="small" readonly style="width: 150px;" @focus="dialogFormVisible3=true"/> <el-input v-model="CraftmanValue" clearable size="small" readonly style="width: 150px;">
<el-button slot="append" icon="el-icon-search" @click="dialogFormVisible3=true"/>
</el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="10"> <el-col :span="10">
@@ -300,9 +356,7 @@
<el-input v-model="PN" size="small" placeholder="输入零件号" style="width: 150px" @change="inputChange"/> <el-input v-model="PN" size="small" placeholder="输入零件号" style="width: 150px" @change="inputChange"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4">
<el-button size="small" type="success" icon="el-icon-search" @click="searchProcess1()">查询</el-button>
</el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="10"> <el-col :span="10">
@@ -328,13 +382,18 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4"> <el-col :span="4">
<el-button size="small" @click="processCopy1()">工艺拷贝</el-button> <el-button size="small" type="success" icon="el-icon-search" @click="searchProcess1()">查询</el-button>
</el-col> </el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="10"> <el-col :span="10">
<el-form-item label="零件图号"> <el-form-item label="零件图号">
<el-select v-model="tuhaoValue" placeholder="零件图号" size="small" style="width:150px" @change="numChange1()"> <el-select
v-model="tuhaoValue"
placeholder="零件图号"
size="small"
style="width:150px"
@change="numChange1()">
<el-option <el-option
v-for="item in tuhao" v-for="item in tuhao"
:key="item.value" :key="item.value"
@@ -345,11 +404,19 @@
</el-col> </el-col>
<el-col :span="10"> <el-col :span="10">
<el-form-item label="零件名称"> <el-form-item label="零件名称">
<el-input v-model="remark1" size="small" style="width: 150px;"/> <el-input v-model="remark1" size="small" readonly style="width: 150px;"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4">
<el-button size="small" @click="processCopy1()">工艺拷贝</el-button>
</el-col>
</el-row> </el-row>
<el-table :data="tableData4" style="width: 97%;max-height: 250px;margin-top: 15px" size="mini" border height="250px"> <el-table
:data="tableData4"
style="width: 97%;max-height: 250px;margin-top: 15px"
size="mini"
border
height="250px">
<el-table-column align="center" label="工艺序号" width="80"> <el-table-column align="center" label="工艺序号" width="80">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.工序顺序 }} {{ scope.row.工序顺序 }}
@@ -423,12 +490,46 @@
<script> <script>
import '@/icon/iconfont.css' import '@/icon/iconfont.css'
import { initCraftmen, getPartnames1, getPartnames2, detailInfo, mainTable, getMaterial, searchMaterial, typicalProcess, initTolerance, FcK, import {
searchProcess, searchWYgongyi, gongyiCopy, initPerson, gongyiYQ, hardEdit, requestEdit, processNameClick, processNameSelect, initCraftmen,
processRequestSelect, searchTolerance, insertOne, deleteOne, upOne, downOne, saveMaterial, saveApprove, selectRequest, getPartnames1,
pasteTable, deleteTable, returnEdit, searchRecord } from '@/api/ManufacturingCenter/ProcessPlanning' getPartnames2,
detailInfo,
mainTable,
getMaterial,
searchMaterial,
typicalProcess,
initTolerance,
FcK,
searchProcess,
searchWYgongyi,
gongyiCopy,
initPerson,
gongyiYQ,
hardEdit,
requestEdit,
processNameClick,
processNameSelect,
processRequestSelect,
searchTolerance,
insertOne,
deleteOne,
upOne,
downOne,
saveMaterial,
saveApprove,
selectRequest,
pasteTable,
deleteTable,
returnEdit,
searchRecord
} from '@/api/ManufacturingCenter/ProcessPlanning'
import elInput from 'element-ui/packages/input'
export default { export default {
components: {
elInput
},
data() { data() {
return { return {
total: 0, total: 0,
@@ -445,6 +546,7 @@ export default {
CraftmenValue: '', // 工艺员值 CraftmenValue: '', // 工艺员值
Craftmen: [], // 工艺员 Craftmen: [], // 工艺员
CraftmanValue: '', // 完艺表单工艺员值 CraftmanValue: '', // 完艺表单工艺员值
CraftmanValue2: '', // 完艺表单工艺员值中间变量
Craftman: [], // 完艺表单工艺员 Craftman: [], // 完艺表单工艺员
partName: '', // 零件名称 partName: '', // 零件名称
batchNum: '', // 投产总数量 batchNum: '', // 投产总数量
@@ -501,7 +603,8 @@ export default {
date02: '', // 完艺结束时间 date02: '', // 完艺结束时间
PN: '', // 零件号 PN: '', // 零件号
num: '', // 工艺计划流水号 num: '', // 工艺计划流水号
perNum: [], perNum: '',
perNum2: '',
tuhao: [], tuhao: [],
tuhaoValue: '', tuhaoValue: '',
check1: 0, check1: 0,
@@ -532,15 +635,15 @@ export default {
this.spec = '' this.spec = ''
this.batchNum = '' this.batchNum = ''
}, },
tableRowClassName({ row }) { // tableRowClassName({ row }) {
for (let i = 0; i < this.tableRecord.length; i++) { // for (let i = 0; i < this.tableRecord.length; i++) {
if (this.tableRecord[i].工序流水号 === row.工序流水号 && this.radio === 2 && this.tableRecord[i].工艺编号 !== null) { // && this.tableRecord[i].工艺难度等级 !== null && this.tableRecord[i].工艺要求 !== null // if (this.tableRecord[i].工序流水号 === row.工序流水号 && this.radio === 2 && this.tableRecord[i].工艺编号 !== null) { // && this.tableRecord[i].工艺难度等级 !== null && this.tableRecord[i].工艺要求 !== null
if (this.tableRecord[i].工艺编号 !== row.工艺编号 || this.tableRecord[i].工艺要求 !== row.工艺要求 || this.tableRecord[i].工艺难度等级 !== row.工艺难度等级 || this.tableRecord[i].工序顺序 !== row.工序顺序) { // if (this.tableRecord[i].工艺编号 !== row.工艺编号 || this.tableRecord[i].工艺要求 !== row.工艺要求 || this.tableRecord[i].工艺难度等级 !== row.工艺难度等级 || this.tableRecord[i].工序顺序 !== row.工序顺序) {
return 'change' // return 'change'
} // }
} // }
} // }
}, // },
returnEdit() { // 在制零件工艺修改 returnEdit() { // 在制零件工艺修改
if (this.partNumValue === '' || this.partNumValue === null) { if (this.partNumValue === '' || this.partNumValue === null) {
this.$message.error('请选择零件') this.$message.error('请选择零件')
@@ -555,7 +658,9 @@ export default {
this.$message.success('打回成功') this.$message.success('打回成功')
this.partNumValue = '' this.partNumValue = ''
this.tableData = [] this.tableData = []
} else { this.$message.error('打回失败') } } else {
this.$message.error('打回失败')
}
}) })
}).catch(() => { }).catch(() => {
this.$message({ this.$message({
@@ -677,7 +782,9 @@ export default {
switchEdit() { // 切换编辑模式 switchEdit() { // 切换编辑模式
if (this.radio === 1) { if (this.radio === 1) {
this.isShow = !this.isShow this.isShow = !this.isShow
} else { this.isShow = true } } else {
this.isShow = true
}
}, },
searchDetail() { // 查主表和上面显示的信息 searchDetail() { // 查主表和上面显示的信息
if (this.partNumValue === '' || this.partNumValue === null) { if (this.partNumValue === '' || this.partNumValue === null) {
@@ -726,12 +833,19 @@ export default {
this.tableData2 = null this.tableData2 = null
}, },
WYbtn() { // 完艺按钮 WYbtn() { // 完艺按钮
this.tableData2 = null this.tableData4 = []
this.dialogFormVisible1 = true this.dialogFormVisible1 = true
}, },
selectPerson(row) { // 选择工艺员 selectPerson(row) { // 选择工艺员
this.CraftmanValue = row.姓名 this.CraftmanValue2 = row.姓名
this.perNum = row.人员编号 this.perNum2 = row.人员编号
},
tijiao() { // 提交完艺表单中工艺定额人员的选择
this.dialogFormVisible3 = false
this.CraftmanValue = this.CraftmanValue2
this.perNum = this.perNum2
this.remark1 = ''
this.tuhaoValue = ''
}, },
inputChange() { // 零件号改变 inputChange() { // 零件号改变
this.remark1 = '' this.remark1 = ''
@@ -777,15 +891,21 @@ export default {
searchProcess() { // 典艺工艺查询 searchProcess() { // 典艺工艺查询
if (this.typicalClassValue === '') { if (this.typicalClassValue === '') {
this.serialNumValue1check = false this.serialNumValue1check = false
} else { this.serialNumValue1check = true } } else {
this.serialNumValue1check = true
}
if (this.partNameValue1 === '') { if (this.partNameValue1 === '') {
this.partNameValue1check = false this.partNameValue1check = false
} else { this.partNameValue1check = true } } else {
this.partNameValue1check = true
}
if (this.processNumValue === '') { if (this.processNumValue === '') {
this.processNumValuecheck = false this.processNumValuecheck = false
} else { this.processNumValuecheck = true } } else {
this.processNumValuecheck = true
}
this.tableData2 = [] this.tableData2 = []
searchProcess(this.serialNumValue1check, this.serialNumValue1, this.partNameValue1check, this.serialNumValue2, this.processNumValuecheck, this.serialNumValue2).then(response => { searchProcess(this.serialNumValue1check, this.serialNumValue1, this.partNameValue1check, this.serialNumValue2, this.processNumValuecheck, this.serialNumValue2).then(response => {
this.tableData2 = response.data this.tableData2 = response.data
@@ -816,16 +936,24 @@ export default {
this.tuhao = [] this.tuhao = []
if (this.PN === '') { // 零件号 if (this.PN === '') { // 零件号
this.check1 = 0 this.check1 = 0
} else { this.check1 = 1 } } else {
this.check1 = 1
}
if (this.perNum === '') { // 工艺员编号 if (this.perNum === '') { // 工艺员编号
this.check2 = 0 this.check2 = 0
} else { this.check2 = 1 } } else {
this.check2 = 1
}
if (this.remark1 === '') { // 零件名称 if (this.remark1 === '') { // 零件名称
this.check4 = 0 this.check4 = 0
} else { this.check4 = 1 } } else {
this.check4 = 1
}
if (this.date01 === '' || this.date02 === '' || this.date01 === null || this.date02 === null) { // 日期 if (this.date01 === '' || this.date02 === '' || this.date01 === null || this.date02 === null) { // 日期
this.check3 = 0 this.check3 = 0
} else { this.check3 = 1 } } else {
this.check3 = 1
}
searchWYgongyi(this.check1, this.PN, this.check2, this.perNum, this.check3, this.date01, this.date02, this.check4, this.remark1).then(response => { searchWYgongyi(this.check1, this.PN, this.check2, this.perNum, this.check3, this.date01, this.date02, this.check4, this.remark1).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.tuhao.push({ this.tuhao.push({
@@ -847,11 +975,6 @@ export default {
}) })
} }
}, },
tijiao() { // 提交完艺表单中工艺定额人员的选择
this.dialogFormVisible3 = false
this.remark1 = ''
this.tuhaoValue = ''
},
numChange1() { // 当完成工艺号改变时,零件名称改变,并获取工艺要求 numChange1() { // 当完成工艺号改变时,零件名称改变,并获取工艺要求
this.remark1 = '' this.remark1 = ''
this.tableData4 = null this.tableData4 = null
@@ -953,7 +1076,9 @@ export default {
searchTolerance(this.numVal, this.selParaValue).then(response => { searchTolerance(this.numVal, this.selParaValue).then(response => {
if (response.data.length !== 0) { // 防止超出范围报错 if (response.data.length !== 0) { // 防止超出范围报错
this.tolerance = response.data[0].公差 this.tolerance = response.data[0].公差
} else { this.$message.error('输入的数值不对!') } } else {
this.$message.error('输入的数值不对!')
}
}) })
}, },
copyAndSave() { // 复制并保存 copyAndSave() { // 复制并保存
@@ -980,7 +1105,9 @@ export default {
this.newNum = '' this.newNum = ''
this.$message.success('保存成功') this.$message.success('保存成功')
this.searchParts() this.searchParts()
} else { this.$message.error('请核准后保存') } } else {
this.$message.error('请核准后保存')
}
}, },
insertOne(row) { // 插入行 insertOne(row) { // 插入行
if (this.partNumValue === '') { if (this.partNumValue === '') {
@@ -1040,7 +1167,9 @@ export default {
saveMaterial(this.partNumValue, this.material).then(response => { saveMaterial(this.partNumValue, this.material).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('保存成功') this.$message.success('保存成功')
} else { this.$message.error('保存失败') } } else {
this.$message.error('保存失败')
}
}) })
} }
}, },
@@ -1052,7 +1181,9 @@ export default {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('粘贴成功') this.$message.success('粘贴成功')
this.searchDetail() this.searchDetail()
} else { this.$message.error('粘贴失败') } } else {
this.$message.error('粘贴失败')
}
}) })
} }
}, },
@@ -1074,7 +1205,9 @@ export default {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('删除成功') this.$message.success('删除成功')
this.searchDetail() this.searchDetail()
} else { this.$message.error('删除失败') } } else {
this.$message.error('删除失败')
}
}) })
}).catch(() => { }).catch(() => {
this.$message({ this.$message({
@@ -1092,12 +1225,15 @@ export default {
.doing-row4 { .doing-row4 {
background: #f0f9eb; background: #f0f9eb;
} }
.el-card { .el-card {
margin-bottom: 15px; margin-bottom: 15px;
} }
.el-date-editor { .el-date-editor {
width: 150px width: 150px
} }
span { span {
margin: 10px 0 10px 10px; margin: 10px 0 10px 10px;
} }

View File

@@ -42,6 +42,7 @@
<el-button type="primary" size="small" style="margin-left: 10px" @click="selectAll(tableData)">全选</el-button> <el-button type="primary" size="small" style="margin-left: 10px" @click="selectAll(tableData)">全选</el-button>
<el-button type="primary" size="small" icon="el-icon-cjn-09" style="" @click="save">保存</el-button> <el-button type="primary" size="small" icon="el-icon-cjn-09" style="" @click="save">保存</el-button>
</el-card> </el-card>
<el-card> <el-card>
<el-table <el-table
ref="multipleTable" ref="multipleTable"
@@ -131,7 +132,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="dialogFormVisible=false">提交</el-button> <el-button type="primary" @click="tijiao()">提交</el-button>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>
@@ -143,6 +144,8 @@ import { getProject0, getProject, getGraphNum, getGroupNum, getTable0, getGraphN
export default { export default {
data() { data() {
return { return {
num1: '', // 工艺员中间变量
num2: '', // 工艺员流水号中间变量
loading: false, loading: false,
loading0: false, loading0: false,
projectNameValue: '', projectNameValue: '',
@@ -323,8 +326,13 @@ export default {
this.dialogFormVisible = true this.dialogFormVisible = true
}, },
confirmPerson(row) { // 选择一行 confirmPerson(row) { // 选择一行
this.tableData[this.index].工艺员 = row.姓名 this.num1 = row.姓名
this.tableData[this.index].人员编号 = row.人员编号 this.num2 = row.人员编号
},
tijiao() {
this.tableData[this.index].工艺员 = this.num1
this.tableData[this.index].人员编号 = this.num2
this.dialogFormVisible = false
}, },
selectAll(rows) { selectAll(rows) {
if (this.tableData[0].工艺员 !== '') { if (this.tableData[0].工艺员 !== '') {

View File

@@ -40,11 +40,11 @@
<el-input v-model="number" placeholder="零件号" clearable size="small" style="width: 200px;"/> <el-input v-model="number" placeholder="零件号" clearable size="small" style="width: 200px;"/>
<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="success" class="el-icon-search" size="small" style="margin: 10px 0 0 10px" @click="getTableData();pageCurrent=1;pageSize=10;total = 0">查询</el-button>
<span>进度颜色</span> <span>进度颜色</span>
<el-radio v-model="radioList" label="0" style="background-color: white">全部</el-radio> <!--<span style="background-color: white">全部</span>-->
<el-radio v-model="radioList" label="1" style="background-color: red">拖期</el-radio> <span style="background-color: red">拖期</span>
<el-radio v-model="radioList" label="2" style="background-color: yellow">即将拖期</el-radio> <span style="background-color: yellow">即将拖期</span>
<el-radio v-model="radioList" label="3" style="background-color: lawngreen">如期</el-radio> <span style="background-color: lawngreen">如期</span>
<el-radio v-model="radioList" label="4" style="background-color: deepskyblue">工序外协</el-radio> <span style="background-color: deepskyblue">工序外协</span>
</el-row> </el-row>
</el-card> </el-card>
@@ -396,6 +396,7 @@ export default {
this.Groups = [] this.Groups = []
if (this.project !== '') { if (this.project !== '') {
getMachines(this.project).then(response => { getMachines(this.project).then(response => {
console.log(response.data)
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.Machines.push({ this.Machines.push({
label: response.data[i].机床图号, label: response.data[i].机床图号,
@@ -539,7 +540,7 @@ export default {
background-color: transparent; background-color: transparent;
border: 0px solid white; border: 0px solid white;
} }
.lightgreen{ .green{
background-color: lightgreen; background-color: lightgreen;
border: 1px solid #1f2d3d; border: 1px solid #1f2d3d;
} }

View File

@@ -73,12 +73,12 @@
type="selection" type="selection"
align="center" align="center"
width="35"/> width="35"/>
<el-table-column label="零件图号" align="center" width="200"> <el-table-column label="零件图号" align="center" width="300">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.零件图号 }} {{ scope.row.零件图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="零件名称" align="center" width="130"> <el-table-column label="零件名称" align="center" width="200">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.零件名称 }} {{ scope.row.零件名称 }}
</template> </template>
@@ -103,42 +103,42 @@
{{ scope.row.工序数量 }} {{ scope.row.工序数量 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="是否超负荷" align="center" width="100"> <!--<el-table-column label="是否超负荷" align="center" width="100">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
{{ scope.row.是否超负荷 }} <!--{{ scope.row.是否超负荷 }}-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column label="外协" width="100" align="center"> <!--<el-table-column label="外协" width="100" align="center">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
<el-checkbox v-model="scope.row.是否预计外协" @change="table1Out(scope.row)">外协</el-checkbox> <!--<el-checkbox v-model="scope.row.是否预计外协" @change="table1Out(scope.row)">外协</el-checkbox>-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column label="加工件合格" align="center" width="230"> <!--<el-table-column label="加工件合格" align="center" width="230">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
<el-date-picker <!--<el-date-picker-->
v-model="tableData[scope.$index].加工件合格时间" <!--v-model="tableData[scope.$index].加工件合格时间"-->
size="mini" <!--size="mini"-->
type="date" <!--type="date"-->
value-format="yyyy-MM-dd" <!--value-format="yyyy-MM-dd"-->
placeholder="选择加工件合格时间" <!--placeholder="选择加工件合格时间"-->
@change="timeChange(scope.row)"/> <!--@change="timeChange(scope.row)"/>-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column label="板焊结束" width="150" align="center"> <!--<el-table-column label="板焊结束" width="150" align="center">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
{{ scope.row.板焊 }} <!--{{ scope.row.板焊 }}-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column label="操作" width="200px" align="center" fixed="right"> <!--<el-table-column label="操作" width="200px" align="center" fixed="right">-->
<template slot-scope="scope" align="center"> <!--<template slot-scope="scope" align="center">-->
<el-button <!--<el-button-->
size="mini" <!--size="mini"-->
type="primary" <!--type="primary"-->
class="el-icon-edit" <!--class="el-icon-edit"-->
@click="PlateWelding(scope.$index, scope.row, 'form1')">板焊</el-button> <!--@click="PlateWelding(scope.$index, scope.row, 'form1')">板焊</el-button>-->
<el-button size="mini" type="primary" @click="inBatches">分批</el-button> <!--&lt;!&ndash;<el-button size="mini" type="primary" @click="inBatches">分批</el-button>&ndash;&gt;-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
</el-table> </el-table>
<div v-if="是否扫描 === false" class="block" style="margin-top: 10px;"> <div v-if="是否扫描 === false" class="block" style="margin-top: 10px;">
<el-pagination <el-pagination
@@ -1224,6 +1224,7 @@ export default {
} }
}).then(() => { }).then(() => {
this.tableData1.push(this.result[i]) this.tableData1.push(this.result[i])
console.log(this.tableData1)
selection2(this.工艺计划流水号[this.indexAdjust]).then(response => { // 刷新对话框显示和颜色 selection2(this.工艺计划流水号[this.indexAdjust]).then(response => { // 刷新对话框显示和颜色
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.partType = response.data[i].零件类型 this.partType = response.data[i].零件类型

View File

@@ -5,13 +5,11 @@
<span>项目名称:</span> <span>项目名称:</span>
<el-select <el-select
v-model="entryNameValue" v-model="entryNameValue"
:remote-method="remoteMethod"
placeholder="项目名称" placeholder="项目名称"
style="width:200px" style="width:200px"
size="small" size="small"
clearable clearable
filterable filterable
remote
@change="empty"> @change="empty">
<el-option <el-option
v-for="item in entryName" v-for="item in entryName"
@@ -20,9 +18,13 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span>机床号:</span> <span>机床号:</span>
<el-input v-model="machineToolNumber" placeholder="机床号" size="small" clearable style="width:200px" @dblclick.native="SearchMachine" @change="empty1"/> <el-input v-model="machineToolNumber" placeholder="机床号" size="small" readonly clearable style="width:200px" @change="empty1">
<el-button slot="append" icon="el-icon-search" @click="SearchMachine" />
</el-input>
<span>组号:</span> <span>组号:</span>
<el-input v-model="groupNumber" placeholder="组号" size="small" clearable style="width:200px" @dblclick.native="searchGroupList"/> <el-input v-model="groupNumber" placeholder="组号" size="small" readonly clearable style="width:200px">
<el-button slot="append" icon="el-icon-search" @click="searchGroupList" />
</el-input>
<span>零件号:</span> <span>零件号:</span>
<el-input v-model="partNumber" placeholder="零件号" size="small" clearable style="width:200px"/> <el-input v-model="partNumber" placeholder="零件号" size="small" clearable style="width:200px"/>
<br> <br>
@@ -187,7 +189,9 @@
@size-change="handleSizeChange1" @size-change="handleSizeChange1"
@current-change="handleCurrentChange1"/> @current-change="handleCurrentChange1"/>
</div> </div>
<el-button type="primary" style="margin-left: 350px;margin-top: 20px" @click="submitName">提交</el-button> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitName">提交</el-button>
</div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogFormVisible3" title="选择组号" center style="min-height: 300px"> <el-dialog :visible.sync="dialogFormVisible3" title="选择组号" center style="min-height: 300px">
@@ -234,7 +238,9 @@
@size-change="handleSizeChange3" @size-change="handleSizeChange3"
@current-change="handleCurrentChange3"/> @current-change="handleCurrentChange3"/>
</div> </div>
<el-button type="primary" style="margin-left: 350px;margin-top: 20px" @click="submitGroup">提交</el-button> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitGroup">提交</el-button>
</div>
</el-dialog> </el-dialog>
</div> </div>
@@ -242,7 +248,12 @@
<script> <script>
import { initProject, intPartState, searchTable, searchmachine, searchgroup, editData } from '@/api/ManufacturingCenter/StatusQuery' import { initProject, intPartState, searchTable, searchmachine, searchgroup, editData } from '@/api/ManufacturingCenter/StatusQuery'
import elInput from 'element-ui/packages/input'
export default { export default {
components: {
elInput
},
data() { data() {
return { return {
loading0: false, loading0: false,
@@ -302,8 +313,6 @@ export default {
}, },
created() { created() {
this.fetchData() this.fetchData()
},
mounted() {
this.getList() this.getList()
}, },
methods: { methods: {
@@ -363,28 +372,15 @@ export default {
}) })
}, },
getList() { // 初始化项目名称 getList() { // 初始化项目名称
this.list = []
initProject().then(response => { initProject().then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
this.list.push({ this.entryName.push({
label: response.data[i].项目名称, label: response.data[i].项目名称,
value: response.data[i].项目流水号 value: response.data[i].项目流水号
}) })
} }
}) })
}, },
remoteMethod(query) {
if (query !== '') {
setTimeout(() => {
this.entryName = this.list.filter(item => {
return item.label.toLowerCase()
.indexOf(query.toLowerCase()) > -1
})
}, 1000)
} else {
this.entryName = []
}
},
empty() { empty() {
this.machineToolNumber = '' this.machineToolNumber = ''
this.groupNumber = '' this.groupNumber = ''
@@ -401,6 +397,12 @@ export default {
if (response.data.result[i].机床结束时间 !== '') { if (response.data.result[i].机床结束时间 !== '') {
response.data.result[i].机床结束时间 = response.data.result[i].机床结束时间.substr(0, 10) response.data.result[i].机床结束时间 = response.data.result[i].机床结束时间.substr(0, 10)
} }
if (response.data.result[i].工位属性 === '请选择') {
response.data.result[i].工位属性 = ''
}
if (response.data.result[i].机床主管 === '请选择') {
response.data.result[i].机床主管 = ''
}
} }
this.tableData6 = response.data.result this.tableData6 = response.data.result
this.total1 = parseInt(response.data.output[0].ItemCount) this.total1 = parseInt(response.data.output[0].ItemCount)

View File

@@ -2,8 +2,6 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-card> <el-card>
<div style="margin-top: -10px;">
<el-row>
<span>零件分类:</span> <span>零件分类:</span>
<el-select v-model="partsCategoriesValue" size="small" filterable clearable placeholder="零件分类" @change="getPartsName"> <el-select v-model="partsCategoriesValue" size="small" filterable clearable placeholder="零件分类" @change="getPartsName">
<el-option <el-option
@@ -12,7 +10,6 @@
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span>零件名称:</span> <span>零件名称:</span>
<el-select v-model="partsNameValue" size="small" filterable clearable placeholder="零件名称" @change="getTableData" > <el-select v-model="partsNameValue" size="small" filterable clearable placeholder="零件名称" @change="getTableData" >
<el-option <el-option
@@ -21,19 +18,20 @@
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span>典型工艺号:</span> <span>典型工艺号:</span>
<el-input v-model="typicalNumValue" auto-complete="off" style="width: 200px" size="small" /> <el-input v-model="typicalNumValue" auto-complete="off" style="width: 100px" size="small" readonly/>
<el-button size="small" type="primary" icon="el-icon-search" style="margin: 10px 0 0 10px" @click="getTableData">查询</el-button> <el-button size="small" type="success" icon="el-icon-search" style="margin-left: 10px" @click="total=0;pageCurrent=1;pageSize=20;getTableData()">查询</el-button>
<el-button size="small" type="info" icon="el-icon-circle-plus-outline" style="margin: 10px 0 0 10px" @click="addTableData">增加</el-button> <el-button size="small" type="primary" icon="el-icon-circle-plus-outline" style="margin-left: 10px" @click="addTableData">增加</el-button>
<el-button size="small" type="success" icon="el-icon-cjn-09" style="margin: 10px 0 0 10px" @click="editConfirm">保存</el-button> <el-button size="small" type="warning" icon="el-icon-menu" style="margin-left: 10px" @click="editConfirm">保存</el-button>
</el-row>
</div>
</el-card> </el-card>
<el-card> <el-card>
<el-table v-loading="loading" :data="tableData" border style="width: 100%;max-height: 550px;" size="mini" height="550px"> <el-table v-loading="loading" :data="tableData" border style="width: 100%;max-height: 550px;" size="mini" height="550px">
<el-table-column prop="num" label="序号" width="50" align="center" type="index"/> <el-table-column prop="num" label="序号" width="50" align="center" type="index">
<template slot-scope="scope">
{{ scope.row.工艺序号 }}
</template>
</el-table-column>
<el-table-column prop="name" label="工艺名称" width="230" align="center"> <el-table-column prop="name" label="工艺名称" width="230" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input <el-input
@@ -66,12 +64,12 @@
</el-table-column> </el-table-column>
<el-table-column prop="name" label="单件" align="center"> <el-table-column prop="name" label="单件" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.单件定额工时" style="width:50px" placeholder="单件定额工时"/> <el-input v-model="scope.row.单件定额工时" size="mini" style="width:90px" placeholder="单件定额"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="name" label="准结" align="center"> <el-table-column prop="name" label="准结" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.准结定额工时" style="width:50px" placeholder="准结定额工时"/> <el-input v-model="scope.row.准结定额工时" size="mini" style="width:90px" placeholder="准结定额"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" width="300" align="center" fixed="right"> <el-table-column label="操作" width="300" align="center" fixed="right">
@@ -101,6 +99,16 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent"
:page-sizes="[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-card>
<el-dialog :visible.sync="dialogFormVisible" title="工艺名称、工艺要求选择" center width="400px"> <el-dialog :visible.sync="dialogFormVisible" title="工艺名称、工艺要求选择" center width="400px">
@@ -145,6 +153,9 @@ import { getPartsCategories, getPartsName, getTableData, upMove, downMove, deleR
export default { export default {
data() { data() {
return { return {
pageCurrent: 1,
pageSize: 20,
total: 0,
partsCategories: [], partsCategories: [],
partsCategoriesCheck: null, partsCategoriesCheck: null,
partsCategoriesValue: '', partsCategoriesValue: '',
@@ -181,7 +192,7 @@ export default {
getPartsName(this.partsCategoriesValue).then(res => { getPartsName(this.partsCategoriesValue).then(res => {
const data = res.data const data = res.data
data.length > 0 ? this.partsNameValue = data[0].典型工艺流水号 : this.partsNameValue = '' data.length > 0 ? this.partsNameValue = data[0].典型工艺流水号 : this.partsNameValue = ''
this.typicalNumValue = data[0].典型工艺号 this.typicalNumValue = data.length > 0 ? data[0].典型工艺号 : ''
data.map(item => { data.map(item => {
this.partsName.push({ this.partsName.push({
label: item.典型工艺名称, label: item.典型工艺名称,
@@ -193,11 +204,25 @@ export default {
getTableData() { getTableData() {
this.partsCategoriesValue ? this.partsCategoriesCheck = 1 : this.partsCategoriesCheck = 0 this.partsCategoriesValue ? this.partsCategoriesCheck = 1 : this.partsCategoriesCheck = 0
this.partsNameValue ? this.partsNameCheck = 1 : this.partsNameCheck = 0 this.partsNameValue ? this.partsNameCheck = 1 : this.partsNameCheck = 0
if (this.partsCategoriesCheck === 0 && this.partsNameCheck === 0) {
this.$message.error('请选择查询条件')
} else {
this.loading = true this.loading = true
getTableData(this.partsCategoriesCheck, this.partsCategoriesValue, this.partsNameCheck, this.partsNameValue).then(res => { getTableData(this.pageCurrent, this.pageSize, this.partsCategoriesCheck, this.partsCategoriesValue, this.partsNameCheck, this.partsNameValue).then(res => {
this.loading = false this.loading = false
this.tableData = res.data this.tableData = res.data.rows
this.total = res.data.total
}) })
}
},
handleSizeChange(val) {
this.pageCurrent = 1
this.pageSize = val
this.getTableData()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.getTableData()
}, },
upMove(row) { upMove(row) {
upMove(row.典型工艺流水号, row.典型工艺工序流水号).then(res => { upMove(row.典型工艺流水号, row.典型工艺工序流水号).then(res => {
@@ -234,7 +259,7 @@ export default {
if (res.data[0].result === '1') { if (res.data[0].result === '1') {
index++ index++
} else { } else {
this.$message.error('零件保存失败') this.$message.error('零件工艺保存失败')
} }
if (index === this.tableData.length) { if (index === this.tableData.length) {
this.$message.success('保存修改成功') this.$message.success('保存修改成功')
@@ -302,4 +327,7 @@ export default {
span{ span{
margin: 20px; margin: 20px;
} }
.el-card{
margin-bottom: 15px;
}
</style> </style>

View File

@@ -8,7 +8,7 @@
</el-card> </el-card>
<el-card> <el-card>
<el-table :data="List" highlight-current-row border> <el-table :data="List" style="height: 550px" border size="small">
<el-table-column label="设备名称" align="center" > <el-table-column label="设备名称" align="center" >
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.设备名称 }} {{ scope.row.设备名称 }}
@@ -184,8 +184,7 @@ export default {
{ value: '3', label: 3 }, { value: '3', label: 3 },
{ value: '4', label: 4 }], { value: '4', label: 4 }],
form: { form: {
设备名称: '', 设备名称: '', 设备编号: '',
设备编号: '',
设备型号: '', 设备型号: '',
设备性能指标: '', 设备性能指标: '',
设备加工能力: '', 设备加工能力: '',
@@ -253,6 +252,7 @@ export default {
this.form.设备型号 = row.设备型号 this.form.设备型号 = row.设备型号
this.form.设备性能指标 = row.设备性能指标 this.form.设备性能指标 = row.设备性能指标
this.form.设备加工能力 = row.设备加工能力工时 this.form.设备加工能力 = row.设备加工能力工时
this.form.设备加工工艺 = parseInt(row.工艺属性代码)
this.form.班次类型 = row.班次类型 this.form.班次类型 = row.班次类型
this.form.设备工时系数 = row.设备工时系数 this.form.设备工时系数 = row.设备工时系数
this.form.整改工时系数 = row.整改工时比例 this.form.整改工时系数 = row.整改工时比例

View File

@@ -5,7 +5,7 @@
<el-radio v-model="radio" label="1">未收回</el-radio> <el-radio v-model="radio" label="1">未收回</el-radio>
<el-radio v-model="radio" label="2">已收回</el-radio> <el-radio v-model="radio" label="2">已收回</el-radio>
<span style="margin-left: 20px">保金类型</span> <span style="margin-left: 20px">保金类型</span>
<el-select v-model="TypeOfGoldDepositValue" clearable filterable placeholder="请选择" size="small" style="margin-left: 10px;width: 130px"> <el-select v-model="TypeOfGoldDepositValue" clearable filterable placeholder="请选择" size="small" style="margin-left: 10px;width: 100px">
<el-option <el-option
v-for="item in TypeOfGoldDeposit" v-for="item in TypeOfGoldDeposit"
:key="item.value" :key="item.value"
@@ -120,7 +120,7 @@
icon="el-icon-edit" icon="el-icon-edit"
@click.stop="TakeBack(scope.row);flag1 = 1">收回</el-button> @click.stop="TakeBack(scope.row);flag1 = 1">收回</el-button>
<el-button <el-button
:disabled="disabled" :disabled="scope.row.是否禁用履约"
size="mini" size="mini"
type="info" type="info"
icon="el-icon-edit" icon="el-icon-edit"
@@ -251,7 +251,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="投标人" prop="投标人"> <el-form-item label="投标人" prop="投标人">
<el-input v-model="form2.投标人" size="small" placeholder="请输入投标人" style="width: 200px;" readonly @dblclick.native="dialogFormVisiblePeople = true;flag2 = 2" @clear="clear()"/> <el-input v-model="form2.投标人" size="small" placeholder="请输入投标人" style="width: 200px;" clearable readonly @dblclick.native="dialogFormVisiblePeople = true;flag2 = 2" @clear="clear()"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@@ -301,8 +301,12 @@
</template> </template>
<script> <script>
import elInput from 'element-ui/packages/input'
import { initType, selectBidBond, getTree, tree, getTablePeople, TakeBack, ComplianceGold, addBidBond, editBidBond, delBidBond } from '@/api/MarketingCenter/BidBond' import { initType, selectBidBond, getTree, tree, getTablePeople, TakeBack, ComplianceGold, addBidBond, editBidBond, delBidBond } from '@/api/MarketingCenter/BidBond'
export default { export default {
components: {
elInput
},
data() { data() {
return { return {
disabled: false, disabled: false,
@@ -418,10 +422,16 @@ export default {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].履约金 === '1' ? data[i].是否禁用 = true : data[i].是否禁用 = false data[i].履约金 === '1' ? data[i].是否禁用 = true : data[i].是否禁用 = false
data[i].履约金 === '1' ? data[i].是否禁用履约 = true : data[i].是否禁用履约 = false
data[i].投标日期 = data[i].投标日期.substring(0, data[i].投标日期.length - 8)
data[i].预计收回日期 = data[i].预计收回日期.substring(0, data[i].预计收回日期.length - 8)
} }
if (this.radio === '2') { if (this.radio === '2') {
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].是否禁用 = true data[i].是否禁用 = true
data[i].投标日期 = data[i].投标日期.substring(0, data[i].投标日期.length - 8)
data[i].预计收回日期 = data[i].预计收回日期.substring(0, data[i].预计收回日期.length - 8)
data[i].实际收回日期 = data[i].实际收回日期.substring(0, data[i].实际收回日期.length - 8)
} }
} }
this.tableData1 = data this.tableData1 = data
@@ -507,6 +517,7 @@ export default {
}, },
callOff() { callOff() {
this.dialogFormVisible1 = false this.dialogFormVisible1 = false
this.dialogFormVisible2 = false
}, },
ComplianceGold(row) { ComplianceGold(row) {
this.$confirm('此操作会将此投标保证金转为履约保证金, 是否继续?', '提示', { this.$confirm('此操作会将此投标保证金转为履约保证金, 是否继续?', '提示', {
@@ -517,9 +528,9 @@ export default {
ComplianceGold(row.招标保证金流水号).then(response => { ComplianceGold(row.招标保证金流水号).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.fetchTableData1() this.fetchTableData1()
this.$message.success('删除成功') this.$message.success('操作成功')
} else { } else {
this.$message.error('删除失败') this.$message.error('操作失败')
} }
}) })
}) })
@@ -531,13 +542,13 @@ export default {
}, },
addTableData1() { addTableData1() {
addBidBond(this.form2.招标企业, this.form2.联系人, this.form2.联系电话, this.form2.保证金金额, this.peopleid, this.form2.保证金类型, this.form2.投标日期, this.form2.计划收回日期, this.form2.备注, this.form2.提前X天提醒我).then(response => { addBidBond(this.form2.招标企业, this.form2.联系人, this.form2.联系电话, this.form2.保证金金额, this.peopleid, this.form2.保证金类型, this.form2.投标日期, this.form2.计划收回日期, this.form2.备注, this.form2.提前X天提醒我).then(response => {
this.dialogFormVisible2 = false
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('添加成功') this.$message.success('添加成功')
this.title = '' this.title = ''
this.dialogFormVisible2 = false
this.fetchTableData1() this.fetchTableData1()
} else { } else {
this.$message.error('添加失败') this.$message.error('添加失败,请检查金额于提醒天数是否为数字')
} }
}) })
}, },
@@ -561,13 +572,13 @@ export default {
}, },
editTableData1() { editTableData1() {
editBidBond(this.form2.招标企业, this.form2.联系人, this.form2.联系电话, this.form2.保证金金额, this.peopleid, this.form2.保证金类型, this.form2.投标日期, this.form2.计划收回日期, this.form2.备注, this.form2.提前X天提醒我, this.BidBondCode).then(response => { editBidBond(this.form2.招标企业, this.form2.联系人, this.form2.联系电话, this.form2.保证金金额, this.peopleid, this.form2.保证金类型, this.form2.投标日期, this.form2.计划收回日期, this.form2.备注, this.form2.提前X天提醒我, this.BidBondCode).then(response => {
this.dialogFormVisible2 = false
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('添加成功') this.$message.success('编辑成功')
this.title = '' this.title = ''
this.dialogFormVisible2 = false
this.fetchTableData1() this.fetchTableData1()
} else { } else {
this.$message.error('添加失败') this.$message.error('编辑失败,请检查金额于提醒天数是否为数字')
} }
}) })
}, },

View File

@@ -9,6 +9,18 @@
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<!--<el-input v-model="CustomerName" placeholder="请输入客户名称" size="small"></el-input>-->
<!--<span class="move">销售经理</span>-->
<!--<el-input clearable v-model="MarketingManagerValue" @dblclick.native="dialogFormVisiblePeople = true" size="small" style="width:200px" placeholder="请选择营销经理" clearable></el-input>-->
<!--<span class="move">信誉等级</span>-->
<!--<el-select v-model="CreditRatingValue" placeholder="请选择信誉等级" size="small">-->
<!--<el-option-->
<!--v-for="item in CreditRating"-->
<!--:key="item.value"-->
<!--:label="item.label"-->
<!--:value="item.value">-->
<!--</el-option>-->
<!--</el-select>-->
<el-button type="success" icon="el-icon-search" class="move" size="small" @click="selectCustomerOfName">查询</el-button> <el-button type="success" icon="el-icon-search" class="move" size="small" @click="selectCustomerOfName">查询</el-button>
</el-card> </el-card>
<el-row> <el-row>
@@ -254,7 +266,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="联系地址:" prop="联系地址"> <el-form-item label="联系地址:" prop="联系地址">
<el-input v-model="form2.联系地址" clearable size="small" style="width:200px" placeholder="请输入联系地址" readonly/> <el-input v-model="form2.联系地址" clearable size="small" style="width:200px" placeholder="请输入联系地址"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
@@ -299,8 +311,12 @@
</template> </template>
<script> <script>
import elInput from 'element-ui/packages/input'
import { searchValue, selectAdress, selectCustomer, getTree, tree, getTablePeople, selectMarketingManager, selectCustomerOfName, initCustomer, deleteCustomer, deleteMarketingManager, addMarketingManager, editMarketingManager, addCustomer, selectAdressOfID, editCustomer } from '@/api/MarketingCenter/CRM' import { searchValue, selectAdress, selectCustomer, getTree, tree, getTablePeople, selectMarketingManager, selectCustomerOfName, initCustomer, deleteCustomer, deleteMarketingManager, addMarketingManager, editMarketingManager, addCustomer, selectAdressOfID, editCustomer } from '@/api/MarketingCenter/CRM'
export default { export default {
components: {
elInput
},
data() { data() {
return { return {
a: '', // 营销经理地区流水号 a: '', // 营销经理地区流水号

View File

@@ -10,7 +10,7 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span style="margin-left: 10px">销售经理</span> <span style="margin-left: 10px">销售经理</span>
<el-input v-model="MarketingManagerValue" clearable size="small" style="width:200px" readonly placeholder="请选择营销经理" @dblclick.native="dialogFormVisiblePeople = true" @clear="clear()"/> <el-input v-model="MarketingManagerValue" readonly clearable size="small" style="width:200px" placeholder="请双击选择营销经理" @dblclick.native="dialogFormVisiblePeople = true" @clear="clear()"/>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="pageSize = 10;PageCurrent = 1;tableData2=[];getTableData()">查询收款计划</el-button> <el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="pageSize = 10;PageCurrent = 1;tableData2=[];getTableData()">查询收款计划</el-button>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" style="margin-left: 10px" @click="ADD()">新增收款计划</el-button> <el-button type="primary" icon="el-icon-circle-plus-outline" size="small" style="margin-left: 10px" @click="ADD()">新增收款计划</el-button>
<el-badge :value="value" :max="99" class="item"> <el-badge :value="value" :max="99" class="item">
@@ -42,11 +42,6 @@
{{ scope.row.机床名称 }} {{ scope.row.机床名称 }}
</template> </template>
</el-table-column> </el-table-column>
<!--<el-table-column label="发货状态" align="center">-->
<!--<template slot-scope="scope">-->
<!--{{ scope.row.机床名称 }}-->
<!--</template>-->
<!--</el-table-column>-->
</el-table> </el-table>
</template> </template>
</el-table-column> </el-table-column>
@@ -119,12 +114,6 @@
</el-table-column> </el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="200"> <el-table-column label="操作" fixed="right" align="center" width="200">
<template slot-scope="scope"> <template slot-scope="scope">
<!--<el-button-->
<!--size="mini"-->
<!--type="primary"-->
<!--icon="el-icon-tickets"-->
<!--:disabled="scope.row.是否禁用"-->
<!--@click.stop="handleEdit(scope.row, scope.$index)">付款</el-button>-->
<el-button <el-button
:disabled="scope.row.是否禁用编辑" :disabled="scope.row.是否禁用编辑"
size="mini" size="mini"
@@ -180,11 +169,6 @@
{{ scope.row.本次收款时间 }} {{ scope.row.本次收款时间 }}
</template> </template>
</el-table-column> </el-table-column>
<!--<el-table-column label="是否开票" align="center">-->
<!--<template slot-scope="scope">-->
<!--{{ scope.row.是否开票 }}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column label="操作" fixed="right" align="center" width="250"> <el-table-column label="操作" fixed="right" align="center" width="250">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@@ -246,12 +230,17 @@
</el-table-column> </el-table-column>
<el-table-column align="center" label="状态"> <el-table-column align="center" label="状态">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag type="danger" style="width: 80px">{{ scope.row.状态 }}</el-tag> <el-tag v-if="scope.row.计划付款时间===''||scope.row.计划付款时间===null" size="small">无计划</el-tag>
<el-tag v-else-if="scope.row.计划付款时间!==''&&scope.row.计划付款时间!==null&&parseInt(scope.row.未收金额)===0" type="success" size="small">已完成</el-tag>
<el-tag v-else-if="scope.row.计划付款时间!==''&&scope.row.计划付款时间!==null&&scope.row.状态==='未开始'" type="primary" size="small">未开始</el-tag>
<el-tag v-else-if="scope.row.计划付款时间!==''&&scope.row.计划付款时间!==null&&scope.row.状态==='即将拖期'" type="warning" size="small">即将拖期</el-tag>
<el-tag v-else-if="scope.row.计划付款时间!==''&&scope.row.计划付款时间!==null&&scope.row.状态==='已拖期'" type="danger" size="small">已拖期</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="280"> <el-table-column label="操作" fixed="right" align="center" width="280">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
:disabled="scope.row.是否禁用收款"
size="mini" size="mini"
type="warning" type="warning"
icon="el-icon-edit" icon="el-icon-edit"
@@ -280,9 +269,9 @@
<el-dialog :visible.sync="dialogFormVisible2" title="新增付款计划" center width="380px"> <el-dialog :visible.sync="dialogFormVisible2" title="新增付款计划" center width="380px">
<el-form ref="form2" :model="form2" :rules="rules" label-position="left"> <el-form ref="form2" :model="form2" :rules="rules" label-position="left">
<el-form-item label="项目名称" prop="entryNameValue" label-width="100px"> <el-form-item label="项目名称" prop="entryNameValue" label-width="100px">
<el-select v-model="form2.entryNameValue" placeholder="请输入项目名称" style="margin-left: 2px; width: 200px" size="small" clearable filterable @change="searchProjectName"> <el-select v-model="form2.entryNameValue" clearable filterable placeholder="请输入项目名称" style="margin-left: 2px; width: 200px" size="small" @change="searchProjectName">
<el-option <el-option
v-for="item in entryName" v-for="item in entryName2"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
@@ -304,7 +293,7 @@
<el-dialog :visible.sync="dialogFormVisible4" title="编辑付款计划" center width="400px"> <el-dialog :visible.sync="dialogFormVisible4" title="编辑付款计划" center width="400px">
<el-form ref="form2" :model="form2" :rules="rules" label-position="left"> <el-form ref="form2" :model="form2" :rules="rules" label-position="left">
<el-form-item label="项目名称" prop="entryNameValue" label-width="100px"> <el-form-item label="项目名称" prop="entryNameValue" label-width="100px">
<el-select v-model="form2.entryNameValue" :disabled="true" clearable placeholder="请输入项目名称" style="width: 200px" size="small" filterable @change="searchProjectName"> <el-select v-model="form2.entryNameValue" :disabled="true" clearable filterable placeholder="请输入项目名称" style="width: 200px" size="small" @change="searchProjectName">
<el-option <el-option
v-for="item in entryName" v-for="item in entryName"
:key="item.value" :key="item.value"
@@ -418,7 +407,7 @@
<el-input-number v-model="form4.转移金额" :min="0" :max="max1" :precision="2" :step="1" controls-position="right" size="small" style="width: 200px" placeholder="请输入本次付款金额" @change="changeMoney"/> <el-input-number v-model="form4.转移金额" :min="0" :max="max1" :precision="2" :step="1" controls-position="right" size="small" style="width: 200px" placeholder="请输入本次付款金额" @change="changeMoney"/>
</el-form-item> </el-form-item>
<el-form-item label="计划阶段" prop="计划阶段" label-width="110px"> <el-form-item label="计划阶段" prop="计划阶段" label-width="110px">
<el-select v-model="form4.计划阶段" clearable placeholder="请选择计划转移到某阶段" style="width: 200px" size="small" filterable> <el-select v-model="form4.计划阶段" clearable filterable placeholder="请选择计划转移到某阶段" style="width: 200px" size="small">
<el-option <el-option
v-for="item in Planning" v-for="item in Planning"
:key="item.value" :key="item.value"
@@ -485,7 +474,8 @@
<script> <script>
import elInput from 'element-ui/packages/input' import elInput from 'element-ui/packages/input'
import { SelectContractFunds, AccountsReceivable, editDay, TransPlanning, selectBatch, editList, delMoney, editTime, selectMax, editFukuan, fukuan, selectProvince, SelectMarketingManager, searchTable1, searchTable2, editBatchCapitalChar, deletechar, searchProjectNumber, searchProjectName, addList, PaymentPhase, dellist, selectMachine, selectBatchFundingDetails } from '@/api//MarketingCenter/ContractCapitalManagement' import { searchProjectNumber2, SelectContractFunds, AccountsReceivable, editDay, TransPlanning, selectBatch, editList, delMoney, editTime, selectMax, editFukuan, fukuan, selectProvince, SelectMarketingManager, searchTable1, searchTable2, editBatchCapitalChar, deletechar, searchProjectNumber, searchProjectName, addList, PaymentPhase, dellist, selectMachine, selectBatchFundingDetails } from '@/api//MarketingCenter/ContractCapitalManagement'
export default { export default {
components: { components: {
elInput elInput
@@ -499,7 +489,7 @@ export default {
} }
} }
return { return {
// disabled: false, entryName2: [],
type: '', type: '',
a: 1, a: 1,
b: 1, b: 1,
@@ -611,7 +601,6 @@ export default {
} }
}, },
created() { created() {
// this.fetchData()
this.getTableData() this.getTableData()
this.init() this.init()
}, },
@@ -619,6 +608,7 @@ export default {
init() { init() {
this.getSelect(selectProvince, ['省份', '省份流水号'], 'Province') this.getSelect(selectProvince, ['省份', '省份流水号'], 'Province')
this.getSelect(searchProjectNumber, ['项目名称', '项目流水号'], 'entryName') this.getSelect(searchProjectNumber, ['项目名称', '项目流水号'], 'entryName')
this.getSelect(searchProjectNumber2, ['项目名称', '项目流水号'], 'entryName2')
this.getSelect(PaymentPhase, ['付款阶段', '付款阶段ID'], 'PaymentPhase') this.getSelect(PaymentPhase, ['付款阶段', '付款阶段ID'], 'PaymentPhase')
AccountsReceivable().then(response => { AccountsReceivable().then(response => {
const data = response.data const data = response.data
@@ -654,14 +644,18 @@ export default {
}) })
selectBatchFundingDetails(this.id).then(response => { selectBatchFundingDetails(this.id).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
if (response.data[i].本次收款时间 !== null || response.data[i].本次收款时间 !== '') {
response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9) response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9)
} }
}
this.tableData4 = response.data this.tableData4 = response.data
}) })
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
this.listLoading2 = false this.listLoading2 = false
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -680,7 +674,6 @@ export default {
} }
} }
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
// data[i].已支付 === '0' ? data[i].是否禁用编辑 = false : data[i].是否禁用编辑 = true
} }
this.tableData2 = data this.tableData2 = data
this.total2 = response.data.total this.total2 = response.data.total
@@ -711,6 +704,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -792,8 +787,10 @@ export default {
this.tableData4 = [] this.tableData4 = []
selectBatchFundingDetails(row.批次资金id).then(response => { selectBatchFundingDetails(row.批次资金id).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
if (response.data[i].本次收款时间 !== null || response.data[i].本次收款时间 !== '') {
response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9) response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9)
} }
}
this.tableData4 = response.data this.tableData4 = response.data
}) })
if (this.c === 1) { if (this.c === 1) {
@@ -812,19 +809,6 @@ export default {
} }
} }
}, },
// fetchData() {
// getTree().then(response => { // 获取人员信息树
// const data = response.data
// this.dataPeople = tree(data, 0)
// })
// },
// handleNodeClick(data) { // 树节点点击
// this.getData(getTablePeople, 'ListPeople', data.id)
// },
// handleChange(row) {
// this.peopleid = row.人员编号
// this.peoplename = row.姓名
// },
getName() { getName() {
this.dialogFormVisiblePeople = false this.dialogFormVisiblePeople = false
this.MarketingManagerValue = this.peoplename this.MarketingManagerValue = this.peoplename
@@ -877,6 +861,7 @@ export default {
this.listLoading2 = false this.listLoading2 = false
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
@@ -900,7 +885,6 @@ export default {
this.tableData2 = data this.tableData2 = data
this.total2 = response.data.total this.total2 = response.data.total
}) })
// this.getTable(searchTable2, [this.PageCurrent2, this.PageSize2, this.moneyID], ['tableData2', 'total2', 'listLoading2'])
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.PageCurrent = 1 this.PageCurrent = 1
@@ -945,6 +929,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1007,6 +993,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1088,11 +1076,6 @@ export default {
}, },
handleEdit1(row) { handleEdit1(row) {
this.addForm('form3') this.addForm('form3')
// let sum = 0
// this.tableData2.map(item => {
// sum += parseFloat(item.本次付款)
// })
// this.max1 = this.contractTotal - (sum - row.本次付款)
this.title = '记录阶段收款' this.title = '记录阶段收款'
this.max1 = parseFloat(row.应收金额) - parseFloat(row.已收金额) this.max1 = parseFloat(row.应收金额) - parseFloat(row.已收金额)
this.dialogFormVisible3 = true this.dialogFormVisible3 = true
@@ -1111,6 +1094,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1150,8 +1135,10 @@ export default {
}) })
selectBatchFundingDetails(this.id).then(response => { selectBatchFundingDetails(this.id).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
if (response.data[i].本次收款时间 !== null || response.data[i].本次收款时间 !== '') {
response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9) response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9)
} }
}
this.tableData4 = response.data this.tableData4 = response.data
}) })
this.flag = '' this.flag = ''
@@ -1182,6 +1169,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1207,8 +1196,10 @@ export default {
}) })
selectBatchFundingDetails(this.id).then(response => { selectBatchFundingDetails(this.id).then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
if (response.data[i].本次收款时间 !== null || response.data[i].本次收款时间 !== '') {
response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9) response.data[i].本次收款时间 = response.data[i].本次收款时间.substring(0, response.data[i].本次收款时间.length - 9)
} }
}
this.tableData4 = response.data this.tableData4 = response.data
}) })
this.flag = '' this.flag = ''
@@ -1241,6 +1232,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1313,6 +1306,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1369,6 +1364,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, this.moneyID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {
@@ -1438,6 +1435,8 @@ export default {
searchTable2(this.PageCurrent2, this.PageSize2, row.资金ID).then(response => { searchTable2(this.PageCurrent2, this.PageSize2, row.资金ID).then(response => {
const data = response.data.rows const data = response.data.rows
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
data[i].未收金额 === '0' ? data[i].是否禁用收款 = true : data[i].是否禁用收款 = false
data[i].未收金额 === '0' ? data[i].是否禁用 = true : data[i].是否禁用 = false
if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) { if (data[i].计划付款时间 === '' || data[i].计划付款时间 === null) {
data[i].状态 = '无计划' data[i].状态 = '无计划'
} else { } else {

View File

@@ -10,7 +10,7 @@
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<span style="margin-left: 10px">销售经理</span> <span style="margin-left: 10px">销售经理</span>
<el-input v-model="MarketingManagerValue" clearable size="small" style="width:200px" placeholder="请选择营销经理" readonly @dblclick.native="openName();param = 1" @clear="clear()"/> <el-input v-model="MarketingManagerValue" readonly clearable size="small" style="width:200px" placeholder="请选择营销经理" @dblclick.native="openName();param = 1" @clear="clear()"/>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="pageSize = 10;PageCurrent = 1;fetchTableData1()">查询</el-button> <el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="pageSize = 10;PageCurrent = 1;fetchTableData1()">查询</el-button>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" style="margin-left: 10px" @click="ADD()">增加</el-button> <el-button type="primary" icon="el-icon-circle-plus-outline" size="small" style="margin-left: 10px" @click="ADD()">增加</el-button>
</el-card> </el-card>
@@ -172,7 +172,7 @@
<el-button size="small" type="primary">点击上传</el-button> <el-button size="small" type="primary">点击上传</el-button>
</el-upload> </el-upload>
</div> </div>
<div v-for="file in hadFile" :key="file.id"> <div v-for="(file, key) in hadFile" :key="key">
<div class="wrapper"> <div class="wrapper">
<div class="content"> <div class="content">
<div class="action"> <div class="action">
@@ -200,7 +200,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="已完成进度" prop="executionProgressID"> <el-form-item label="已完成进度" prop="executionProgressID">
<el-select v-model="form.executionProgressID" :disabled="infoDisable" placeholder="请输入目前执行进度" clearable size="small" style="width: 200px"> <el-select v-model="form.executionProgressID" :disabled="infoDisable" placeholder="请输入目前执行进度" size="small" style="width: 200px">
<el-option <el-option
v-for="item in executionProgress" v-for="item in executionProgress"
:key="item.value" :key="item.value"
@@ -211,7 +211,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="销售经理" prop="MarketingManagerValue"> <el-form-item label="销售经理" prop="MarketingManagerValue">
<el-input v-model="form.MarketingManagerValue" clearable size="small" style="width:200px" placeholder="请选择营销经理" readonly @dblclick.native="openName()" @clear="clear()"/> <el-input v-model="form.MarketingManagerValue" readonly clearable size="small" style="width:200px" placeholder="请双击选择营销经理" @dblclick.native="openName()" @clear="clear()"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
@@ -256,12 +256,12 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="客户名称" prop="customerName"> <el-form-item label="客户名称" prop="customerName">
<el-input v-model="form.customerName" size="small" placeholder="请输入客户名称" style="width:200px" readonly @dblclick.native="CustomerChange()"/> <el-input v-model="form.customerName" readonly size="small" placeholder="请双击选择客户" style="width:200px" clearable @dblclick.native="CustomerChange()" @clear="clear1()"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="付款方式" prop="付款方式"> <el-form-item label="付款方式" prop="付款方式">
<el-select v-model="form.付款方式" :disabled="disabled" placeholder="请选择付款方式" clearable size="small" style="width: 200px"> <el-select v-model="form.付款方式" :disabled="disabled" placeholder="请选择付款方式" size="small" style="width: 200px">
<el-option <el-option
v-for="item in money" v-for="item in money"
:key="item.value" :key="item.value"
@@ -417,10 +417,13 @@
</template> </template>
<script> <script>
import elInput from 'element-ui/packages/input'
import { initProject, searchTable1, fetchExecutionProgress, delList, addList, executionProgressID, editchar, getTree, tree, getTablePeople, fetchCustomerData, getFileData, deleteFileData, selectMachine, selectProvince, SelectMarketingManager, submitMachine, editMachine, delMachine, money } from '@/api/MarketingCenter/ContractInformationManagement' import { initProject, searchTable1, fetchExecutionProgress, delList, addList, executionProgressID, editchar, getTree, tree, getTablePeople, fetchCustomerData, getFileData, deleteFileData, selectMachine, selectProvince, SelectMarketingManager, submitMachine, editMachine, delMachine, money } from '@/api/MarketingCenter/ContractInformationManagement'
import { upload, download } from '@/utils/request' import { upload, download } from '@/utils/request'
export default { export default {
components: {
elInput
},
data() { data() {
return { return {
a: 1, a: 1,
@@ -705,6 +708,9 @@ export default {
this.tableData3 = [] this.tableData3 = []
this.ProvinceValue = '' this.ProvinceValue = ''
}, },
clear1() {
this.CustomerCode = ''
},
CustomerChange() { CustomerChange() {
this.dialogCustomerFormVisible = true this.dialogCustomerFormVisible = true
}, },

View File

@@ -0,0 +1,104 @@
<template>
<div style="display: inline-block;width: 100%;height: 100%;margin: 10px 20px 40px 10px">
<input id="excel-upload-input" ref="excel-upload-input" type="file" multiple="multiple" accept=".xlsx, .xls" class="c-hide" @change="handkeFileChange">
<el-button style="margin-left:16px;" size="small" icon="el-icon-search" type="success" @click="handleUpload">浏览清单</el-button>
<!--<div id="drop" @drop="handleDrop" @dragover="handleDragover" @dragenter="handleDragover">-->
<!--将Excel文件拖到这或-->
<!--<el-button style="margin-left:16px;" size="small" icon="el-icon-search" type="success" @click="handleUpload">浏览</el-button>-->
<!--</div>-->
</div>
</template>
<script>
import XLSX from 'xlsx'
export default {
data() {
return {
loading: false,
excelData: {
itemFile: [],
worksheet: []
}
}
},
methods: {
generateDate({ itemFile, worksheet }) {
this.excelData.itemFile.push(itemFile)
this.excelData.worksheet.push(worksheet)
},
handleDrop(e) {
this.excelData.itemFile = []
this.excelData.worksheet = [] // 每次拖拽都清空一次
e.stopPropagation()
e.preventDefault()
const files = e.dataTransfer.files
for (let i = 0; i < files.length; i++) { // 支持多个文件
const itemFile = files[i]
this.readerData(itemFile)
}
this.$emit('on-selected-file', this.excelData)
e.stopPropagation()
e.preventDefault()
},
handleDragover(e) {
e.stopPropagation()
e.preventDefault()
e.dataTransfer.dropEffect = 'copy'
},
handleUpload() {
this.excelData.itemFile = []
this.excelData.worksheet = [] // 每次点击“浏览”都清空一次
document.getElementById('excel-upload-input').click()
},
handkeFileChange(e) {
const files = e.target.files
for (let i = 0; i < files.length; i++) { // 支持多个文件
const itemFile = files[i]
if (!itemFile) return
this.readerData(itemFile)
}
this.$emit('on-selected-file', this.excelData)
this.$refs['excel-upload-input'].value = null // fix can't select the same excel
},
readerData(itemFile) {
const reader = new FileReader()
reader.onload = e => {
const data = e.target.result
const fixedData = this.fixdata(data)
const workbook = XLSX.read(btoa(fixedData), { type: 'base64' })
const firstSheetName = workbook.SheetNames[0] // cjnsheetname
const worksheet = workbook.Sheets[firstSheetName] // 默认firstsheet
this.generateDate({ itemFile, worksheet })
}
reader.readAsArrayBuffer(itemFile)
},
fixdata(data) {
let o = ''
let l = 0
const w = 10240
for (; l < data.byteLength / w; ++l) o += String.fromCharCode.apply(null, new Uint8Array(data.slice(l * w, l * w + w)))
o += String.fromCharCode.apply(null, new Uint8Array(data.slice(l * w)))
return o
}
}
}
</script>
<style scoped>
#excel-upload-input{
display: none;
z-index: -9999;
}
#drop{
border: 2px dashed #bbb;
width: 600px;
line-height: 160px;
margin: 0;
font-size: 24px;
border-radius: 5px;
text-align: center;
color: #bbb;
position: relative;
}
</style>

File diff suppressed because it is too large Load Diff

View File

@@ -365,8 +365,12 @@
</template> </template>
<script> <script>
import elInput from 'element-ui/packages/input'
import { initProject, searchTable1, searchTable2, addSafetyMargin, editSafetyMargin, delSafetyMargin, Withdrawing, delWithdrawing, edtWithdrawing, TakeBack } from '@/api/MarketingCenter/SafetyMargin' import { initProject, searchTable1, searchTable2, addSafetyMargin, editSafetyMargin, delSafetyMargin, Withdrawing, delWithdrawing, edtWithdrawing, TakeBack } from '@/api/MarketingCenter/SafetyMargin'
export default { export default {
components: {
elInput
},
data() { data() {
const validateValue = (rule, value, callback) => { const validateValue = (rule, value, callback) => {
if (value === 0) { if (value === 0) {
@@ -581,6 +585,8 @@ export default {
callOff() { callOff() {
this.dialogFormVisible1 = false this.dialogFormVisible1 = false
this.dialogFormVisible2 = false this.dialogFormVisible2 = false
this.dialogFormVisible3 = false
this.dialogFormVisible4 = false
}, },
delSafetyMargin(row) { delSafetyMargin(row) {
this.deleteRow(delSafetyMargin, row.安全保证金流水号, function() { this.fetchTableData1() }) this.deleteRow(delSafetyMargin, row.安全保证金流水号, function() { this.fetchTableData1() })
@@ -598,7 +604,7 @@ export default {
this.dialogFormVisible2 = true this.dialogFormVisible2 = true
this.code = row.安全保证金流水号 this.code = row.安全保证金流水号
this.projectName = row.项目名称 this.projectName = row.项目名称
this.maxMoney = parseFloat(row.保证金金额) this.maxMoney = parseFloat(row.应收回金额)
this.SurplusAmount = row.应收回金额 this.SurplusAmount = row.应收回金额
this.addForm('form2') this.addForm('form2')
}, },

View File

@@ -52,26 +52,11 @@
{{ scope.row.设备情况 }} {{ scope.row.设备情况 }}
</template> </template>
</el-table-column> </el-table-column>
<!--<el-table-column label="类别" align="center" width="110px">-->
<!--<template slot-scope="scope">-->
<!--{{scope.row.类别}}-->
<!--</template>-->
<!--</el-table-column>-->
<!--<el-table-column label="关注" align="center">-->
<!--<template slot-scope="scope">-->
<!--{{scope.row.关注}}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column label="备注" align="center" width="150px"> <el-table-column label="备注" align="center" width="150px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.备注 }} {{ scope.row.备注 }}
</template> </template>
</el-table-column> </el-table-column>
<!--<el-table-column label="序号" align="center">-->
<!--<template slot-scope="scope">-->
<!--{{scope.row.序号}}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column label="操作" align="center" width="200px" fixed="right"> <el-table-column label="操作" align="center" width="200px" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@@ -138,18 +123,6 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!--<el-row>-->
<!--<el-col :span="12">-->
<!--<el-form-item label="类别" prop="category">-->
<!--<el-input v-model="form.category" placeholder="类别" clearable size="small"></el-input>-->
<!--</el-form-item>-->
<!--</el-col>-->
<!--<el-col :span="12">-->
<!--<el-form-item label="关注" prop="attention">-->
<!--<el-input v-model="form.attention" placeholder="关注" clearable size="small" ></el-input>-->
<!--</el-form-item>-->
<!--</el-col>-->
<!--</el-row>-->
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="设备情况" prop="EquipmentCondition"> <el-form-item label="设备情况" prop="EquipmentCondition">
@@ -162,15 +135,6 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!--<el-row>-->
<!--<el-col :span="12">-->
<!--<el-form-item label="厂家序号" prop="ManufacturerNumber">-->
<!--<el-input v-model="form.ManufacturerNumber" placeholder="厂家序号" clearable size="small"></el-input>-->
<!--</el-form-item>-->
<!--</el-col>-->
<!--<el-col :span="12">-->
<!--</el-col>-->
<!--</el-row>-->
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="callOff('form')">取消</el-button> <el-button @click="callOff('form')">取消</el-button>

View File

@@ -22,6 +22,7 @@
:data="tableData3" :data="tableData3"
border border
stripe stripe
size="small"
tooltip-effect="dark" tooltip-effect="dark"
style="width: 100%;" style="width: 100%;"
height="650"> height="650">
@@ -43,30 +44,31 @@
<template slot-scope="scope">{{ scope.row.工艺名称简称 }}</template> <template slot-scope="scope">{{ scope.row.工艺名称简称 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="计算方式" width="100" align="center">
<template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.外协价格计算标准流水号)===1" type="success" size="small">工时</el-tag>
<el-tag v-if="parseInt(scope.row.外协价格计算标准流水号)===2" type="success" size="small">重量</el-tag>
<el-tag v-if="parseInt(scope.row.外协价格计算标准流水号)===3" type="success" size="small">面积</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="工时价格(元/分)"> <el-table-column align="center" label="工时价格(元/分)">
<template slot-scope="scope"> <template slot-scope="scope">
<div :class="colorCode1[scope.$index]"> {{ scope.row.外协价格1 }}
<h4>{{ scope.row.外协价格1 }}</h4>
</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="重量价格(元/kg)"> <el-table-column align="center" label="重量价格(元/kg)">
<template slot-scope="scope"> <template slot-scope="scope">
<div :class="colorCode2[scope.$index]"> {{ scope.row.重量价格1 }}
<h4>{{ scope.row.重量价格1 }}</h4>
</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="面积价格(元/m2)"> <el-table-column align="center" label="面积价格(元/m2)">
<template slot-scope="scope"> <template slot-scope="scope">
<div :class="colorCode3[scope.$index]"> {{ scope.row.面积价格1 }}
<h4>{{ scope.row.面积价格1 }}</h4>
</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" width="130px" align="center"> <el-table-column label="操作" width="130px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@@ -227,21 +229,6 @@ export default {
getTable(this.Code_Check, this.Code, this.Code_Check1, this.processClassificationValue, this.pageList, this.pageSize).then(response => { getTable(this.Code_Check, this.Code, this.Code_Check1, this.processClassificationValue, this.pageList, this.pageSize).then(response => {
this.total = parseInt(response.data.total) this.total = parseInt(response.data.total)
if (response.data.rows.length !== 0) { if (response.data.rows.length !== 0) {
for (let i = 0; i < response.data.rows.length; i++) {
if (response.data.rows[i].外协价格计算标准流水号 === '1') {
this.colorCode1.push('mianji')
this.colorCode2.push('')
this.colorCode3.push('')
} else if (response.data.rows[i].外协价格计算标准流水号 === '2') {
this.colorCode1.push('')
this.colorCode2.push('mianji')
this.colorCode3.push('')
} else {
this.colorCode1.push('')
this.colorCode2.push('')
this.colorCode3.push('mianji')
}
}
this.tableData3 = response.data.rows this.tableData3 = response.data.rows
} }
}) })

View File

@@ -56,12 +56,18 @@
</el-card> </el-card>
<el-card> <el-card>
<el-table v-loading="loading" :data="tableData" :row-class-name="tableRowClassName" height="580" style="width: 100%;" border element-loading-text="拼命加载中" @row-click="getParts"> <el-table v-loading="loading" :data="tableData" height="580" style="width: 100%;" border element-loading-text="拼命加载中" @row-click="getParts">
<el-table-column <el-table-column
label=" " label=" "
type="index" type="index"
align="center" align="center"
width="50"/> width="50"/>
<el-table-column label="付款状态" width="100" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.实际付款时间!==''" type="success" size="small">已付款</el-tag>
<el-tag v-else type="info" size="small">未付款</el-tag>
</template>
</el-table-column>
<el-table-column label="表单号" align="center" width="280px"> <el-table-column label="表单号" align="center" width="280px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.表单号 }} {{ scope.row.表单号 }}
@@ -425,14 +431,6 @@ export default {
this.dialogFormVisible2 = false this.dialogFormVisible2 = false
this.$refs[formName].resetFields() this.$refs[formName].resetFields()
}, },
// 表格颜色
tableRowClassName({ row }) {
if (row.实际付款时间 !== '') {
return 'fukuan'
} else {
return ''
}
},
// 获取表格2数据 // 获取表格2数据
getParts(row) { getParts(row) {
this.loading2 = true this.loading2 = true

View File

@@ -5,7 +5,9 @@
<span>表单号:</span> <span>表单号:</span>
<el-input v-model="formNumber" size="small" placeholder="表单号" clearable style="width:200px"/> <el-input v-model="formNumber" size="small" placeholder="表单号" clearable style="width:200px"/>
<span>外协厂家:</span> <span>外协厂家:</span>
<el-input v-model="manufacturers" readonly size="small" placeholder="外协厂家" style="width:200px" clearable @dblclick.native="onFocus1();param=0"/> <el-input v-model="manufacturers" readonly size="small" placeholder="外协厂家" style="width:250px" clearable>
<el-button slot="append" icon="el-icon-search" @click="onFocus1();param=0"/>
</el-input>
<span>下达任务日期:</span> <span>下达任务日期:</span>
<el-date-picker <el-date-picker
v-model="time" v-model="time"
@@ -17,7 +19,13 @@
</el-card> </el-card>
<el-card> <el-card>
<el-table v-loading="loading2" :data="List" :row-class-name="tableRowClassName2" highlight-current-row height="350" border @row-click="searchProcess" > <el-table v-loading="loading2" :data="List" highlight-current-row height="350" border @row-click="searchProcess" >
<el-table-column label="单据状态" width="100" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.单据状态==='成交'" type="success" size="small">成交</el-tag>
<el-tag v-else type="info" size="small">未成交</el-tag>
</template>
</el-table-column>
<el-table-column label="表单号" align="center" min-width="200px"> <el-table-column label="表单号" align="center" min-width="200px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.表单号 }} {{ scope.row.表单号 }}
@@ -446,8 +454,12 @@ import { getTable, getData1, getTable1, getprocedure, searchManufactor, sparePar
import { getExplorer, method5, Cleanup } from '@/vendor/exportExcel' import { getExplorer, method5, Cleanup } from '@/vendor/exportExcel'
import { convertCurrency } from '@/vendor/int2Chinese' import { convertCurrency } from '@/vendor/int2Chinese'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
import elInput from 'element-ui/packages/input'
export default { export default {
components: {
elInput
},
data() { data() {
return { return {
bianliang: [], bianliang: [],
@@ -609,7 +621,7 @@ export default {
this.List3 = [] this.List3 = []
getTable(this.num, this.formNumber, this.num1, this.ManufactorNumber, this.num2, this.time1, this.time2, this.id, this.pageList, this.pageSize).then(response => { getTable(this.num, this.formNumber, this.num1, this.ManufactorNumber, this.num2, this.time1, this.time2, this.id, this.pageList, this.pageSize).then(response => {
this.total = parseInt(response.data.total) this.total = parseInt(response.data.total)
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.rows.length; i++) {
if (response.data.rows[i].任务下达日期 !== null) { if (response.data.rows[i].任务下达日期 !== null) {
response.data.rows[i].任务下达日期 = response.data.rows[i].任务下达日期.substr(0, 10) response.data.rows[i].任务下达日期 = response.data.rows[i].任务下达日期.substr(0, 10)
} }
@@ -871,7 +883,7 @@ export default {
sums[4] = '材料费:' sums[4] = '材料费:'
sums[6] = '其他费用:' sums[6] = '其他费用:'
sums[8] = '运费:' sums[8] = '运费:'
sums[9] = this.freight sums[9] = parseInt(this.freight)
sums[10] = '合计:' sums[10] = '合计:'
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
sums[24] += Math.round(parseFloat(data[i].外协预算总价格) * 100) / 100 sums[24] += Math.round(parseFloat(data[i].外协预算总价格) * 100) / 100
@@ -1046,6 +1058,7 @@ export default {
}) })
} }
}, },
// 确定价格
confirmPrice() { confirmPrice() {
this.code1 = 0 this.code1 = 0
for (let i = 0; i < this.List3.length; i++) { for (let i = 0; i < this.List3.length; i++) {
@@ -1168,6 +1181,7 @@ export default {
}) })
} }
}, },
// 成交
Deal() { Deal() {
this.documentStatus = 2 this.documentStatus = 2
this.sign = 1 this.sign = 1
@@ -1227,7 +1241,7 @@ export default {
}, },
// 提交编辑 // 提交编辑
submitEdit() { submitEdit() {
editData(this.Number, this.ManufactorNumber1, this.form.运费, this.documentStatus, this.sign, this.Explain).then(response => { editData(this.Number, this.ManufactorNumber1, this.form.运费, this.documentStatus, 1, this.Explain).then(response => {
if (response.data[0].result === '1') { if (response.data[0].result === '1') {
this.$message.success('编辑成功') this.$message.success('编辑成功')
this.dialogFormVisible = false this.dialogFormVisible = false
@@ -1534,14 +1548,6 @@ export default {
return '' return ''
} }
}, },
// 表格颜色
tableRowClassName2({ row }) {
if (row.单据状态 === '成交') {
return 'chengjiao'
} else {
return ''
}
},
// 分页 // 分页
handleSizeChange(val) { handleSizeChange(val) {
this.pageList = 1 this.pageList = 1

View File

@@ -16,11 +16,9 @@
align="center" align="center"
width="50"/> width="50"/>
<el-table-column label="零件图号" align="center" width="380px"> <el-table-column label="零件图号" align="center" width="380px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.零件图号 }} {{ scope.row.零件图号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="零件名称" align="center" width="320px"> <el-table-column label="零件名称" align="center" width="320px">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -57,19 +55,23 @@
</el-card> </el-card>
<el-card> <el-card>
<el-table v-loading="loading2" :data="tableData2" :row-class-name="tableRowClassName" height="350" style="width: 100%;" border element-loading-text="拼命加载中"> <el-table v-loading="loading2" :data="tableData2" height="350" style="width: 100%;" border element-loading-text="拼命加载中">
<el-table-column <el-table-column
label=" " label=" "
type="index" type="index"
align="center" align="center"
width="50"/> width="50"/>
<el-table-column label="序间外协" width="100" align="center"> <el-table-column label="序间外协" width="100" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-checkbox v-model="checkBox[scope.$index]" @change="edit(scope.$index, scope.row)">选择</el-checkbox> <el-checkbox v-model="checkBox[scope.$index]" @change="edit(scope.$index, scope.row)">选择</el-checkbox>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="外协状态" width="100" align="center">
<template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.工序间是否外协)===2" type="success" size="small">外协</el-tag>
<el-tag v-else size="small">自制</el-tag>
</template>
</el-table-column>
<el-table-column label="工艺名称" align="center" width="220px"> <el-table-column label="工艺名称" align="center" width="220px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.工艺名称 }} {{ scope.row.工艺名称 }}
@@ -252,14 +254,6 @@ export default {
handleCurrentChange1(val) { handleCurrentChange1(val) {
this.pageCurrent1 = val this.pageCurrent1 = val
this.searchTable() this.searchTable()
},
// 表格颜色
tableRowClassName({ row }) {
if (row.工序间是否外协 === 2) {
return 'waixie'
} else {
return ''
}
} }
} }
} }

View File

@@ -14,6 +14,9 @@
</el-select> </el-select>
<span>供应商:</span> <span>供应商:</span>
<el-input v-model="supplierName" placeholder="供应商" size="small" clearable/> <el-input v-model="supplierName" placeholder="供应商" size="small" clearable/>
<span>提前</span>
<el-input-number v-model="warningValue" :min="1" controls-position="right" size="small" style="width: 90px"/>
<span>天预警</span>
<el-button <el-button
type="success" type="success"
size="small" size="small"
@@ -70,7 +73,7 @@
<el-progress <el-progress
:text-inside="true" :text-inside="true"
:stroke-width="18" :stroke-width="18"
:percentage="100*(parseInt(scope.row.合同物料到货总数)/parseInt(scope.row.合同物料采购总数)).toFixed(4)" :percentage="parseFloat((100*scope.row.合同物料到货总数/scope.row.合同物料采购总数).toFixed(2))"
status="success"/> status="success"/>
</template> </template>
</el-table-column> </el-table-column>
@@ -114,7 +117,7 @@
</el-table-column> </el-table-column>
<el-table-column label="已到货数量" align="center" min-width="100"> <el-table-column label="已到货数量" align="center" min-width="100">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.总到货数量 }} {{ scope.row.总到货数量 ? scope.row.总到货数量 : 0 }}
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -130,6 +133,7 @@ export default {
name: '', // 项目总价查询 name: '', // 项目总价查询
data() { data() {
return { return {
warningValue: 3,
check1: 0, check1: 0,
check2: 0, check2: 0,
contractNumValue: '', contractNumValue: '',
@@ -169,6 +173,7 @@ export default {
}) })
}, },
searchTable1() { searchTable1() {
this.warningValue ? this.warningValue : this.warningValue = 1
this.arrival = [] // 规定到货时间数组 this.arrival = [] // 规定到货时间数组
this.now = new Date() this.now = new Date()
this.contractNumValue ? this.check1 = 1 : this.check1 = 0 this.contractNumValue ? this.check1 = 1 : this.check1 = 0
@@ -177,13 +182,13 @@ export default {
for (let i = 0; i < response.data.rows.length; i++) { for (let i = 0; i < response.data.rows.length; i++) {
this.arrival.push(new Date(response.data.rows[i].规定到货时间)) this.arrival.push(new Date(response.data.rows[i].规定到货时间))
if (parseInt(response.data.rows[i].合同物料到货总数) === parseInt(response.data.rows[i].合同物料采购总数)) { if (parseInt(response.data.rows[i].合同物料到货总数) === parseInt(response.data.rows[i].合同物料采购总数)) {
this.judge[i] = 1 this.judge[i] = 1 // 全部到货
} else if (parseInt(response.data.rows[i].合同物料到货总数) !== parseInt(response.data.rows[i].合同物料采购总数) && (this.now - this.arrival[i]) > 0 && (this.now - this.arrival[i]) < 86400000) { } else if (parseInt(response.data.rows[i].合同物料到货总数) !== parseInt(response.data.rows[i].合同物料采购总数) && (this.arrival[i] - this.now) > 0 && (this.arrival[i] - this.now) < (86400000 * this.warningValue)) {
this.judge[i] = 2 this.judge[i] = 2 // 即将拖期
} else if (parseInt(response.data.rows[i].合同物料到货总数) !== parseInt(response.data.rows[i].合同物料采购总数) && (this.now - this.arrival[i]) > 86400000) { } else if (parseInt(response.data.rows[i].合同物料到货总数) !== parseInt(response.data.rows[i].合同物料采购总数) && (this.arrival[i] - this.now) < 0) {
this.judge[i] = 3 this.judge[i] = 3 // 已拖期
} else if (parseInt(response.data.rows[i].合同物料到货总数) !== parseInt(response.data.rows[i].合同物料采购总数) && (this.now - this.arrival[i]) < 0) { } else if (parseInt(response.data.rows[i].合同物料到货总数) !== parseInt(response.data.rows[i].合同物料采购总数) && (this.arrival[i] - this.now) > (86400000 * this.warningValue)) {
this.judge[i] = 4 this.judge[i] = 4 // 进度正常
} }
} }
this.tableData1 = response.data.rows this.tableData1 = response.data.rows

View File

@@ -20,24 +20,20 @@
<span>合同号:</span> <span>合同号:</span>
<el-input v-model="contractNum" placeholder="合同号" size="small" style="width:180px" clearable/> <el-input v-model="contractNum" placeholder="合同号" size="small" style="width:180px" clearable/>
<span>采购员:</span> <span>采购员:</span>
<el-input <el-select v-model="personValue" placeholder="采购员" size="small" style="width: 100px" clearable>
v-model="buyerName" <el-option
placeholder="采购员" v-for="item in person"
size="small" :key="item.value"
readonly :label="item.label"
clearable :value="item.value"/>
style="width:100px" </el-select>
@dblclick.native="initBuyer();dialogVisible2=true;submitDisable=true"/>
<span>供应商:</span> <span>供应商:</span>
<el-input <el-input
v-model="supplierName" v-model="supplierName"
placeholder="供应商" placeholder="供应商"
size="small" size="small"
readonly
clearable clearable
style="width:180px" style="width:180px"/>
@dblclick.native="dialogVisible1=true;submitDisable=true"
@clear="emptySupplierDetail"/>
<el-button <el-button
type="success" type="success"
size="small" size="small"
@@ -47,28 +43,37 @@
</el-card> </el-card>
<el-card> <el-card>
<el-table v-loading="loading1" :data="tableData1" size="mini" border style="width: 100%;"> <el-table :data="tableData1" size="mini" border style="width: 100%">
<el-table-column label="采购合同编号" min-width="150" align="center"> <el-table-column label="请款" min-width="80" align="center">
<template slot-scope="scope">
<el-button
type="primary"
size="mini"
icon=""
@click="requestFund(scope.row)">请款</el-button>
</template>
</el-table-column>
<el-table-column label="采购合同编号" min-width="100" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.采购合同编号 }} {{ scope.row.采购合同编号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="采购合同名称" min-width="150" align="center"> <el-table-column label="采购合同名称" min-width="100" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.采购合同名称 }} {{ scope.row.采购合同名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="规定到货时间" width="100" align="center"> <el-table-column label="规定到货时间" width="100" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.规定到货时间 }} {{ scope.row.规定到货时间.split(' ')[0] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="供应商" min-width="200" align="center"> <el-table-column label="供应商" min-width="150" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.供应商名称 }} {{ scope.row.供应商名称 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="总金额" width="80" align="center"> <el-table-column label="总金额" width="70" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.总金额 }} {{ scope.row.总金额 }}
</template> </template>
@@ -78,7 +83,7 @@
{{ scope.row.付款方式内容 }} {{ scope.row.付款方式内容 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="欠款金额" min-width="100" align="center"> <el-table-column label="欠款金额" min-width="70" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.欠款金额 }} {{ scope.row.欠款金额 }}
</template> </template>
@@ -93,9 +98,18 @@
<el-input v-model="scope.row.本次应请款" size="mini" style="width:70px"/> <el-input v-model="scope.row.本次应请款" size="mini" style="width:70px"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="请款付款情况" width="810" align="center"> <el-table-column label="请款付款情况" width="900" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-table v-show="tableData11[scope.$index].length!==0" :data="tableData11[scope.$index]" size="mini" border style="width: 100%;"> <el-table :id="scope.$index" :data="tableData11[scope.$index]" size="mini" border style="width: 100%;">
<el-table-column label="取消请款" width="100" align="center">
<template slot-scope="scope">
<el-button
:disabled="scope.row.审核情况流水号!==3"
type="danger"
size="mini"
@click="cancelRequestFund(scope.row)">取消请款</el-button>
</template>
</el-table-column>
<el-table-column label="次数" min-width="60" align="center" type="index"/> <el-table-column label="次数" min-width="60" align="center" type="index"/>
<el-table-column label="请款金额" width="70" align="center"> <el-table-column label="请款金额" width="70" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -104,25 +118,25 @@
</el-table-column> </el-table-column>
<el-table-column label="请款时间" width="90" align="center"> <el-table-column label="请款时间" width="90" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.请款时间 }} {{ scope.row.请款时间 ? scope.row.请款时间.split(' ')[0] : '' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="审核情况内容" width="80" align="center"> <el-table-column label="审核情况" width="80" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.审核情况内容 }} {{ scope.row.审核情况内容 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="未通过审核原因" width="80" align="center"> <el-table-column label="未通过审核原因" width="110" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.未通过审核原因 }} {{ scope.row.未通过审核原因 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="审批情况内容" width="80" align="center"> <el-table-column label="审批情况" width="80" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.审批情况内容 }} {{ scope.row.审批情况内容 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="未通过审批原因" width="80" align="center"> <el-table-column label="未通过审批原因" width="110" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.未通过审批原因 }} {{ scope.row.未通过审批原因 }}
</template> </template>
@@ -132,32 +146,14 @@
{{ scope.row.付款情况内容 }} {{ scope.row.付款情况内容 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="未付款原因" width="80" align="center"> <el-table-column label="未付款原因" width="110" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.未付款原因 }} {{ scope.row.未付款原因 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="100" align="center">
<template slot-scope="scope">
<el-button
type="danger"
size="mini"
icon=""
@click="cancelRequestFund(scope.row)">取消请款</el-button>
</template>
</el-table-column>
</el-table> </el-table>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="请款" min-width="80" align="center" fixed="right">
<template slot-scope="scope">
<el-button
type="primary"
size="mini"
icon=""
@click="requestFund(scope.row)">请款</el-button>
</template>
</el-table-column>
</el-table> </el-table>
<div class="block" style="margin-top: 10px;"> <div class="block" style="margin-top: 10px;">
<el-pagination <el-pagination
@@ -173,22 +169,22 @@
</el-card> </el-card>
<el-card> <el-card>
<span>请款开始时间:</span> <span>请款时间区:</span>
<el-date-picker <el-date-picker
v-model="startRequestDate" v-model="startRequestDate"
size="small" size="small"
type="date" type="date"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
format="yyyy-MM-dd" format="yyyy-MM-dd"
placeholder="选择日期"/> placeholder="开始日期"/>
<span>请款结束时间:</span>
<el-date-picker <el-date-picker
v-model="endRequestDate" v-model="endRequestDate"
size="small" size="small"
type="date" type="date"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
format="yyyy-MM-dd" format="yyyy-MM-dd"
placeholder="选择日期"/> placeholder="结束日期"/>
<el-button <el-button
type="success" type="success"
size="small" size="small"
@@ -217,15 +213,10 @@
</el-table-column> </el-table-column>
<el-table-column label="规定到货时间" width="100" align="center"> <el-table-column label="规定到货时间" width="100" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.规定到货时间 }} {{ scope.row.规定到货时间.split(' ')[0] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="实际到货时间" width="100" align="center"> <el-table-column label="供应商" min-width="250" align="center">
<template slot-scope="scope">
{{ scope.row.实际到货时间 }}
</template>
</el-table-column>
<el-table-column label="供应商" min-width="150" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.供应商名称 }} {{ scope.row.供应商名称 }}
</template> </template>
@@ -257,170 +248,23 @@
</el-table-column> </el-table-column>
<el-table-column label="请款时间" width="100" align="center"> <el-table-column label="请款时间" width="100" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.请款时间 }} {{ scope.row.请款时间.split(' ')[0] }}
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
</el-card> </el-card>
<el-dialog :visible.sync="dialogVisible1" title="供应商选择" center style="min-height: 300px">
<el-form ref="form1" :model="form1" label-position="left" label-width="90px" class="searchForm">
<el-row>
<el-col :span="12">
<el-form-item label="供应商名称">
<el-input v-model="supplierName" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="企业性质">
<el-input v-model="enterpriseNature" size="small"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="货期">
<el-input v-model="goodTime" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="注册资本">
<el-input v-model="registeredCapital" size="small"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="税号">
<el-input v-model="taxNum" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="电子邮箱">
<el-input v-model="EMail" size="small"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="地址">
<el-input v-model="address" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="账号">
<el-input v-model="account" size="small"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="开户行">
<el-input v-model="openingBank" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="电话号码">
<el-input v-model="phone" size="small"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="传真">
<el-input v-model="fax" size="small"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-button
type="success"
size="small"
icon="el-icon-search"
@click="searchSupplier">查询</el-button>
<el-button
:disabled="submitDisable"
type="primary"
size="small"
icon="el-icon-check"
@click="submitSelectSupplier">确定</el-button>
<el-button
type="danger"
size="small"
icon="el-icon-delete"
@click="emptySupplierDetail">清空</el-button>
</el-col>
</el-row>
<el-table :data="tableData01" size="mini" style="width: 97%;max-height: 300px;margin-top:15px" height="200px" border @row-click="showSupplierDetail">
<el-table-column align="center" label="供应商名称" width="200">
<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>
</el-form>
</el-dialog>
<el-dialog :visible.sync="dialogVisible2" title="采购员选择" center style="min-height: 300px;" width="40%">
<el-table
:data="tableData02"
size="small"
border
style="width: 100%;min-height:300px"
height="300px"
highlight-current-row
@row-click="clickBuyer">
<el-table-column label="考勤编号" align="center">
<template slot-scope="scope">
{{ scope.row.考勤编号 }}
</template>
</el-table-column>
<el-table-column label="姓名" align="center">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="性别" align="center">
<template slot-scope="scope">
{{ scope.row.性别 }}
</template>
</el-table-column>
<el-table-column label="工作岗位" align="center">
<template slot-scope="scope">
{{ scope.row.岗位名称 }}
</template>
</el-table-column>
</el-table>
<div slot="footer" class="dialog-footer">
<el-button :disabled="submitDisable" type="primary" size="small" icon="el-icon-check" @click="submitSelectBuyer">确定</el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
import { searchSupplier, searchTable1, requestFund, searchCondition, cancelRequestFund, searchRequestTable, initBuyer } from '@/api/PurchasingCenter/BuyerRequestFund' import { searchTable1, requestFund, searchCondition, cancelRequestFund, searchRequestTable, initBuyer } from '@/api/PurchasingCenter/BuyerRequestFund'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
export default { export default {
data() { data() {
return { return {
tableData02: [], personValue: '',
dialogVisible2: false, person: [],
loading2: false, loading2: false,
tableData2: [], tableData2: [],
tableData11: [], tableData11: [],
@@ -430,37 +274,10 @@ export default {
startDate: '', startDate: '',
endDate: '', endDate: '',
contractNum: '', contractNum: '',
buyerName: '',
dialogVisible1: false,
submitDisable: true, submitDisable: true,
form1: {}, form1: {},
supplierValue: '',
supplierName: '', supplierName: '',
enterpriseNature: '',
createDate: '',
registeredCapital: '',
taxNum: '',
EMail: '',
address: '',
account: '',
openingBank: '',
phone: '',
fax: '',
goodTime: '',
supplierCheck1: 0,
supplierCheck2: 0,
supplierCheck3: 0,
supplierCheck4: 0,
supplierCheck5: 0,
supplierCheck6: 0,
supplierCheck7: 0,
supplierCheck8: 0,
supplierCheck9: 0,
supplierCheck10: 0,
supplierCheck11: 0,
supplierCheck12: 0,
tableData01: [], tableData01: [],
loading1: false,
tableData1: [], tableData1: [],
check1: 0, check1: 0,
check2: 0, check2: 0,
@@ -479,100 +296,43 @@ export default {
'id' 'id'
]) ])
}, },
created() {
this.initBuyer()
},
methods: { methods: {
submitSelectBuyer() { // 确定
this.dialogVisible2 = false
},
clickBuyer(row) { // 点击采购员表某一行
this.submitDisable = false
this.buyerName = row.姓名
},
initBuyer() { // 初始化采购人员 initBuyer() { // 初始化采购人员
initBuyer().then(response => { initBuyer().then(response => {
this.tableData02 = response.data for (let i = 0; i < response.data.length; i++) {
this.person.push({
text: response.data[i].姓名,
label: response.data[i].姓名,
value: response.data[i].人员编号
}) })
}, }
searchSupplier() { // 查询创立日期和注册资本大于符合条件的数据
this.supplierName ? this.supplierCheck1 = 1 : (this.supplierCheck1 = 0, this.supplierName = '')
this.enterpriseNature ? this.supplierCheck2 = 1 : (this.supplierCheck2 = 0, this.enterpriseNature = '')
this.createDate ? this.supplierCheck3 = 1 : (this.supplierCheck3 = 0, this.createDate = '')
this.registeredCapital ? this.supplierCheck4 = 1 : (this.supplierCheck4 = 0, this.registeredCapital = '')
this.taxNum ? this.supplierCheck5 = 1 : (this.supplierCheck5 = 0, this.taxNum = '')
this.EMail ? this.supplierCheck6 = 1 : (this.supplierCheck6 = 0, this.EMail = '')
this.address ? this.supplierCheck7 = 1 : (this.supplierCheck7 = 0, this.address = '')
this.account ? this.supplierCheck8 = 1 : (this.supplierCheck8 = 0, this.account = '')
this.openingBank ? this.supplierCheck9 = 1 : (this.supplierCheck9 = 0, this.openingBank = '')
this.phone ? this.supplierCheck10 = 1 : (this.supplierCheck10 = 0, this.phone = '')
this.fax ? this.supplierCheck11 = 1 : (this.supplierCheck11 = 0, this.fax = '')
this.goodTime ? this.supplierCheck12 = 1 : (this.supplierCheck12 = 0, this.goodTime = '')
searchSupplier(this.supplierCheck1, this.supplierName, this.supplierCheck2, this.enterpriseNature, this.supplierCheck3, this.createDate, this.supplierCheck4, this.registeredCapital, this.supplierCheck5, this.taxNum, this.supplierCheck6, this.EMail, this.supplierCheck7, this.address, this.supplierCheck8, this.account, this.supplierCheck9, this.openingBank, this.supplierCheck10, this.phone, this.supplierCheck11, this.fax, this.supplierCheck12, this.goodTime).then(response => {
this.tableData01 = response.data
}) })
}, },
submitSelectSupplier() { // 确定选择供应商
this.dialogVisible1 = false
},
emptySupplierDetail() { // 清空
this.submitDisable = true
this.supplierValue = ''
this.supplierName = ''
this.enterpriseNature = ''
this.createDate = ''
this.registeredCapital = ''
this.taxNum = ''
this.EMail = ''
this.address = ''
this.account = ''
this.openingBank = ''
this.phone = ''
this.fax = ''
this.goodTime = ''
},
showSupplierDetail(row) { // 点击供应商表某一行
this.submitDisable = false
this.supplierValue = row.供应商流水号
this.supplierName = row.供应商名称
this.enterpriseNature = row.企业性质
this.createDate = row.创立日期
this.registeredCapital = row.注册资本
this.taxNum = row.税号
this.EMail = row.电子信箱
this.address = row.地址
this.account = row.帐号
this.openingBank = row.开户行
this.phone = row.电话号码
this.fax = row.传真
this.goodTime = row.货期
},
searchTable1() { searchTable1() {
this.loading1 = true
this.tableData1 = [] this.tableData1 = []
this.startDate && this.endDate ? this.check1 = 1 : this.check1 = 0 this.startDate && this.endDate ? this.check1 = 1 : this.check1 = 0
this.contractNum ? this.check2 = 1 : this.check2 = 0 this.contractNum ? this.check2 = 1 : this.check2 = 0
this.buyerName ? this.check3 = 1 : this.check3 = 0 this.personValue ? this.check3 = 1 : this.check3 = 0
this.supplierName ? this.check4 = 1 : this.check4 = 0 this.supplierName ? this.check4 = 1 : this.check4 = 0
searchTable1(this.pageCurrent1, this.pageSize1, this.check1, this.startDate, this.endDate, this.check2, this.contractNum, this.check3, this.buyerName, this.check4, this.supplierName).then(response => { searchTable1(this.pageCurrent1, this.pageSize1, this.check1, this.startDate, this.endDate, this.check2, this.contractNum, this.check3, this.personValue, this.check4, this.supplierName).then(response => {
for (let j = 0; j < response.data.rows.length; j++) { for (let j = 0; j < response.data.rows.length; j++) {
if (response.data.rows[j].规定到货时间 !== null) {
response.data.rows[j].规定到货时间 = response.data.rows[j].规定到货时间.substring(0, response.data.rows[j].规定到货时间.indexOf(' '))
}
if (response.data.rows[j].实际到货时间 !== null) {
response.data.rows[j].实际到货时间 = response.data.rows[j].实际到货时间.substring(0, response.data.rows[j].实际到货时间.indexOf(' '))
}
this.tableData11[j] = [] this.tableData11[j] = []
searchCondition(response.data.rows[j].采购合同流水号).then(response0 => { searchCondition(response.data.rows[j].采购合同流水号).then(response0 => {
this.tableData1 = response.data.rows if (response0.data.length === 0) {
this.total1 = response.data.total this.tableData11[j].push(response0.data)
document.getElementById(j).setAttribute('style', 'display:none')
} else {
for (let i = 0; i < response0.data.length; i++) { for (let i = 0; i < response0.data.length; i++) {
if (response0.data[i].请款时间 !== null) {
response0.data[i].请款时间 = response0.data[i].请款时间.substring(0, response0.data[i].请款时间.indexOf(' '))
}
this.tableData11[j].push(response0.data[i]) this.tableData11[j].push(response0.data[i])
} }
}
}) })
} }
}).then(() => { this.tableData1 = response.data.rows
this.loading1 = false this.total1 = response.data.total
}) })
}, },
handleSizeChange1(val) { handleSizeChange1(val) {
@@ -598,6 +358,7 @@ export default {
}) })
}, },
cancelRequestFund(row) { // 取消请款 cancelRequestFund(row) { // 取消请款
console.log(row)
this.$confirm('确认取消请款吗?', '提示', { this.$confirm('确认取消请款吗?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
@@ -625,17 +386,17 @@ export default {
}, },
searchRequestTable() { // 查询请款表 searchRequestTable() { // 查询请款表
this.loading2 = true this.loading2 = true
if (this.startRequestDate === '' || this.startRequestDate === null || this.endRequestDate === '' || this.endRequestDate === null) { if ((this.startRequestDate === '' || this.startRequestDate === null) && (this.endRequestDate === '' || this.endRequestDate === null)) {
this.checkRequest = 0 this.checkRequest = 0
} else { this.checkRequest = 1 } } else if (this.startRequestDate !== '' && this.startRequestDate !== null && this.endRequestDate !== '' && this.endRequestDate !== null) {
this.checkRequest = 1
} else {
this.$message.error('请款时间区间有误')
this.loading2 = false
return
}
searchRequestTable(this.checkRequest, this.startRequestDate, this.endRequestDate).then(response => { searchRequestTable(this.checkRequest, this.startRequestDate, this.endRequestDate).then(response => {
for (let j = 0; j < response.data.length; j++) { for (let j = 0; j < response.data.length; j++) {
if (response.data[j].规定到货时间 !== null) {
response.data[j].规定到货时间 = response.data[j].规定到货时间.substring(0, response.data[j].规定到货时间.indexOf(' '))
}
if (response.data[j].实际到货时间 !== null) {
response.data[j].实际到货时间 = response.data[j].实际到货时间.substring(0, response.data[j].实际到货时间.indexOf(' '))
}
if (response.data[j].请款时间 !== null) { if (response.data[j].请款时间 !== null) {
response.data[j].请款时间 = response.data[j].请款时间.substring(0, response.data[j].请款时间.indexOf(' ')) response.data[j].请款时间 = response.data[j].请款时间.substring(0, response.data[j].请款时间.indexOf(' '))
} }

View File

@@ -26,7 +26,7 @@
</el-option> </el-option>
</el-select> </el-select>
<span>采购员:</span> <span>采购员:</span>
<el-select v-model="personValue" placeholder="采购员" size="small" style="width: 100px"> <el-select v-model="personValue" placeholder="采购员" size="small" clearable style="width: 100px">
<el-option <el-option
v-for="item in person" v-for="item in person"
:key="item.value" :key="item.value"
@@ -186,7 +186,7 @@
</el-option> </el-option>
</el-select> </el-select>
<span>采购员:</span> <span>采购员:</span>
<el-select v-model="personValue3" placeholder="采购员" size="small" style="width: 100px"> <el-select v-model="personValue3" placeholder="采购员" size="small" clearable style="width: 100px">
<el-option <el-option
v-for="item in person" v-for="item in person"
:key="item.value" :key="item.value"
@@ -494,6 +494,11 @@ export default {
}, },
contractChange() { contractChange() {
if (this.contractValue) { if (this.contractValue) {
this.$confirm('确定更改该合同?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
contractChange(this.contractValue, this.changeReason).then(response => { contractChange(this.contractValue, this.changeReason).then(response => {
this.contractValue = '' this.contractValue = ''
this.changeReason = '' this.changeReason = ''
@@ -505,6 +510,12 @@ export default {
this.fetchData() this.fetchData()
} else { this.$message.error('变更失败') } } else { this.$message.error('变更失败') }
}) })
}).catch(() => {
this.$message({
type: 'info',
message: '已取消操作'
})
})
} else { } else {
this.$message.error('请先选择合同') this.$message.error('请先选择合同')
} }

View File

@@ -51,7 +51,7 @@
<el-row> <el-row>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="第1次付款时间"> <el-form-item label="第1次付款时间">
<el-select v-model="payTime1Value" placeholder="请选择" size="small" clearable> <el-select v-model="payTime1Value" placeholder="请选择" size="small">
<el-option <el-option
v-for="item in payTime" v-for="item in payTime"
:key="item.value" :key="item.value"
@@ -62,7 +62,7 @@
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="第2次付款时间"> <el-form-item label="第2次付款时间">
<el-select v-model="payTime2Value" :disabled="disable2" placeholder="请选择" size="small" clearable> <el-select v-model="payTime2Value" :disabled="disable2" placeholder="请选择" size="small">
<el-option <el-option
v-for="item in payTime" v-for="item in payTime"
:key="item.value" :key="item.value"
@@ -73,7 +73,7 @@
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="第3次付款时间"> <el-form-item label="第3次付款时间">
<el-select v-model="payTime3Value" :disabled="disable3" placeholder="请选择" size="small" clearable> <el-select v-model="payTime3Value" :disabled="disable3" placeholder="请选择" size="small">
<el-option <el-option
v-for="item in payTime" v-for="item in payTime"
:key="item.value" :key="item.value"
@@ -84,7 +84,7 @@
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="第4次付款时间"> <el-form-item label="第4次付款时间">
<el-select v-model="payTime4Value" :disabled="disable4" placeholder="请选择" size="small" clearable> <el-select v-model="payTime4Value" :disabled="disable4" placeholder="请选择" size="small">
<el-option <el-option
v-for="item in payTime" v-for="item in payTime"
:key="item.value" :key="item.value"
@@ -97,7 +97,7 @@
<el-row> <el-row>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="第5次付款时间"> <el-form-item label="第5次付款时间">
<el-select v-model="payTime5Value" :disabled="disable5" placeholder="请选择" size="small" clearable> <el-select v-model="payTime5Value" :disabled="disable5" placeholder="请选择" size="small">
<el-option <el-option
v-for="item in payTime" v-for="item in payTime"
:key="item.value" :key="item.value"
@@ -118,7 +118,7 @@
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="币种"> <el-form-item label="币种">
<el-select v-model="currencyValue" placeholder="币种" size="small" clearable> <el-select v-model="currencyValue" placeholder="币种" size="small">
<el-option <el-option
v-for="item in currency" v-for="item in currency"
:key="item.value" :key="item.value"
@@ -186,7 +186,7 @@
style="margin-top:10px" style="margin-top:10px"
@click="calculateContractSum">计算合同总额</el-button> @click="calculateContractSum">计算合同总额</el-button>
<span>合同总额:</span> <span>合同总额:</span>
<el-input v-model="contractSum" size="small"/> <el-input v-model="contractSum" size="small" readonly/>
</el-card> </el-card>
<el-card> <el-card>
@@ -237,10 +237,10 @@ export default {
searchView: '', searchView: '',
fileList: [], fileList: [],
minDate: null, minDate: null,
endDateOpt: { // 为了让规定到货时间早于物料计划到货时间 endDateOpt: { // 禁用大于规定到货日期和小于当前日期
disabledDate: (time) => { disabledDate: (time) => {
if (this.minDate) { if (this.minDate) {
return time.getTime() > this.minDate return time.getTime() > this.minDate || time.getTime() < new Date()
} }
} }
}, },
@@ -251,19 +251,19 @@ export default {
contractName: '产品购销合同', // 合同名称 contractName: '产品购销合同', // 合同名称
supplierName: '', // 供应商名称 supplierName: '', // 供应商名称
stipulateArrivalTime: '', // 规定到货时间 stipulateArrivalTime: '', // 规定到货时间
payMethodValue: '', // 付款方式流水号 payMethodValue: 1, // 付款方式流水号
payMethodName: '', // 付款方式名称 payMethodName: '', // 付款方式名称
payMethod: [], payMethod: [],
payTime: [], payTime: [],
payTime1Value: '', // 付款时间 payTime1Value: 1, // 付款时间
payTime2Value: '', // 付款时间 payTime2Value: 1, // 付款时间
payTime3Value: '', // 付款时间 payTime3Value: 1, // 付款时间
payTime4Value: '', // 付款时间 payTime4Value: 1, // 付款时间
payTime5Value: '', // 付款时间 payTime5Value: 1, // 付款时间
payTime6Value: '', // 付款时间 payTime6Value: 1, // 付款时间
freight: '', // 运费 freight: 0, // 运费
taxRate: '', // 税率 taxRate: '0.17', // 税率
currencyValue: '', // 币种 currencyValue: 1, // 币种
currency: [ currency: [
{ {
label: '人民币', label: '人民币',
@@ -380,11 +380,13 @@ export default {
}) })
initPayTimeNode().then(response => { initPayTimeNode().then(response => {
for (let i = 0; i < response.data.length; i++) { for (let i = 0; i < response.data.length; i++) {
if (parseInt(response.data[i].付款时间节点流水号) !== 0) {
this.payTime.push({ this.payTime.push({
label: response.data[i].付款时间节点名称, label: response.data[i].付款时间节点名称,
value: response.data[i].付款时间节点流水号 value: response.data[i].付款时间节点流水号
}) })
} }
}
}) })
}, },
payMethodChange() { // 付款方式改变 payMethodChange() { // 付款方式改变

View File

@@ -318,23 +318,20 @@
<el-input v-model="form2.inquirySheetNum" size="small"/> <el-input v-model="form2.inquirySheetNum" size="small"/>
</el-form-item> </el-form-item>
<el-form-item label="供应商" prop="supplierName"> <el-form-item label="供应商" prop="supplierName">
<el-input v-model="form2.supplierName" size="small" readonly> <el-input v-model="form2.supplierName" size="small" readonly @focus="dialogVisible1=true"/>
<el-button slot="append" icon="el-icon-search" @click="dialogVisible1=true"/>
</el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button size="small" @click="dialogVisible2=false">取消</el-button>
<el-button <el-button
v-show="title2==='创建询价单'" v-show="title2==='创建询价单'"
type="primary" type="primary"
size="small" size="small"
icon="el-icon-check"
@click="submitCreateInquirySheet">确定</el-button> @click="submitCreateInquirySheet">确定</el-button>
<el-button <el-button
v-show="title2==='编辑询价单'" v-show="title2==='编辑询价单'"
type="primary" type="primary"
size="small" size="small"
icon="el-icon-check"
@click="submitEditInquirySheet">确定</el-button> @click="submitEditInquirySheet">确定</el-button>
</div> </div>
</el-dialog> </el-dialog>
@@ -342,7 +339,7 @@
<el-dialog :visible.sync="dialogVisible3" title="物料变更选择" center style="min-height: 300px;" width="780px"> <el-dialog :visible.sync="dialogVisible3" title="物料变更选择" center style="min-height: 300px;" width="780px">
<span>物料名称:</span> <span>物料名称:</span>
<el-input v-model="materialName0" placeholder="物料名称" size="small" clearable/> <el-input v-model="materialName0" placeholder="物料名称" size="small" clearable/>
<el-button type="success" size="small" icon="el-icon-search" @click="pageCurrent02=1;pageSize02=10;total02=0;searchMaterial()">查询</el-button> <el-button type="success" size="small" icon="el-icon-search" style="margin-left:10px" @click="pageCurrent02=1;pageSize02=10;total02=0;searchMaterial()">查询</el-button>
<el-table :data="tableData02" size="mini" style="width: 97%;max-height: 300px;margin-top:15px" height="400px" border highlight-current-row @row-click="selectNewMaterial"> <el-table :data="tableData02" size="mini" style="width: 97%;max-height: 300px;margin-top:15px" height="400px" border highlight-current-row @row-click="selectNewMaterial">
<el-table-column align="center" label="物料名称" min-width="150"> <el-table-column align="center" label="物料名称" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
@@ -374,7 +371,8 @@
<span style="font-size: large;color: red">将原物料替换为: {{ materialNew }}</span> <span style="font-size: large;color: red">将原物料替换为: {{ materialNew }}</span>
<!--<el-input v-model="materialNew" size="small" readonly style="margin: 10px 10px 0 10px"></el-input>--> <!--<el-input v-model="materialNew" size="small" readonly style="margin: 10px 10px 0 10px"></el-input>-->
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" size="small" icon="el-icon-check" @click="submitMaterialChange">确定</el-button> <el-button size="small" @click="dialogVisible3=false">取消</el-button>
<el-button type="primary" size="small" @click="submitMaterialChange">确定</el-button>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>

View File

@@ -51,7 +51,7 @@
</el-table-column> </el-table-column>
<el-table-column align="center" label="到票情况" min-width="200px"> <el-table-column align="center" label="到票情况" min-width="200px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-progress :text-inside="true" :stroke-width="18" :percentage="parseFloat((100*(scope.row.到票总金额/scope.row.合同总金额)).toFixed(2))" status="success"/> <el-progress :status="Number(scope.row.到票总金额)>Number(scope.row.合同总金额)?'exception':'success'" :text-inside="true" :stroke-width="18" :percentage="Number(scope.row.到票总金额)>Number(scope.row.合同总金额)?100:parseFloat((100*(scope.row.到票总金额/scope.row.合同总金额)).toFixed(2))"/>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

View File

@@ -0,0 +1,763 @@
<template>
<div class="app-container">
<el-card>
<el-row>
<!--<span>部门名称:</span>-->
<!--<el-select v-model="DepartmentValue" style="width:200px" placeholder="请选择" size="small" clearable @change="searchMaterialCategory">-->
<!--<el-option-->
<!--v-for="item in Department"-->
<!--:key="item.value"-->
<!--:label="item.label"-->
<!--:value="item.value">-->
<!--</el-option>-->
<!--</el-select>-->
<span>物料类别:</span>
<el-select
v-model="MaterialCategoryValue"
style="width:200px"
placeholder="请选择"
size="small"
clearable
@change="searchMaterialVariety">
<el-option
v-for="item in MaterialCategory"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>物料品种:</span>
<el-select
v-model="MaterialVarietyValue"
style="width:200px"
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-button
type="warning"
icon="el-icon-refresh"
size="small"
style="margin-left: 15px"
@click="CategoryMaintenance">维护物料类别
</el-button>
</el-row>
<el-row>
<span>物料名称:</span>
<el-input v-model="MaterialName" placeholder="物料名称" size="small" clearable style="margin-top: 15px;width:200px"/>
<span>物料全称:</span>
<el-input
v-model="FullNameOfMaterial"
placeholder="物料全称"
size="small"
clearable
style="margin-top: 15px;width:200px"/>
<span>物料规格:</span>
<el-input
v-model="MaterialSpecification"
placeholder="物料规格"
size="small"
clearable
style="margin-top: 15px;width:200px"/>
<span>物料型号:</span>
<el-input
v-model="MaterialModel"
placeholder="物料型号"
size="small"
clearable
style="margin-top: 15px;width:200px"/>
</el-row>
<el-row>
<span>计算单位:</span>
<el-select
v-model="MeasurementUnitValue"
style="margin-top: 15px;width:200px"
placeholder="请选择"
size="small"
clearable>
<el-option
v-for="item in MeasurementUnit"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>物料来源:</span>
<el-select
v-model="MaterialSourceValue"
style="margin-top: 15px;width:200px"
placeholder="请选择"
size="small"
clearable>
<el-option
v-for="item in MaterialSource"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span style="margin-left: 25px">供货商:</span>
<el-input
v-model="supplier"
placeholder="供货商"
size="small"
clearable
style="margin-top: 15px;width:200px"
@dblclick.native="param=0;openSupplier()"/>
<el-button
type="success"
icon="el-icon-search"
size="small"
style="margin-top: 15px;margin-left: 15px"
@click="pageCurrent=1;searchMaterial()">查询
</el-button>
<el-button type="primary" icon="el-icon-circle-plus-outline" size="small" @click="handleAdd()">增加</el-button>
</el-row>
</el-card>
<el-card style="margin-top: 15px">
<el-table
:data="tableData"
style="width: 100%"
height="440"
size="mini"
highlight-current-row
border>
<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">
{{ scope.row.参考价格 }}
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="200">
<template slot-scope="scope">
<el-button
size="mini"
type="primary"
icon="el-icon-edit"
@click="handleEdit(scope.row)">编辑
</el-button>
<el-button
size="mini"
type="danger"
icon="el-icon-delete"
@click="handleDelete(scope.row)">删除
</el-button>
</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 :visible.sync="dialogFormVisible" title="选择供货商" center width="400px">
<el-input v-model="supplier1" placeholder="供货商" size="small" clearable style="width:200px"/>
<el-button
type="success"
icon="el-icon-search"
size="small"
style="margin-left: 15px; margin-bottom: 10px"
@click="pageCurrent1=1;searchSupplier()">查询
</el-button>
<el-table
:data="tableData1"
size="mini"
highlight-current-row
border
@row-click="selectSupplier">
<el-table-column align="center" label="供货商">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent1"
:page-sizes="[10, 20, 30]"
:page-size="pageSize1"
:total="total1"
small
layout="sizes, prev, pager, next"
@size-change="handleSizeChange1"
@current-change="handleCurrentChange1"/>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitSupplier">提交</el-button>
</div>
</el-dialog>
<el-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="供货商">
<el-input
v-model="form.供货商"
placeholder="供货商"
size="small"
clearable
style="width:200px"
@click.native="param=1;openSupplier()"/>
</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>
<el-button v-show="title==='编辑'" type="primary" @click="submitEdit('form')">确定</el-button>
</div>
</el-dialog>
<el-dialog :visible.sync="dialogFormVisible2" title="物料类别维护" center width="1200px">
<div style="width: 47%;display: inline-block">
<el-card>
<span>物料类别:</span>
<el-input v-model="MaterialCategory2" placeholder="物料类别" size="mini" clearable style="width:100px"/>
<span>类别编号:</span>
<el-input v-model="CategoryNumber" placeholder="类别编号" size="mini" clearable style="width:100px"/>
<el-button type="primary" size="mini" style="margin-left: 10px" @click="handleAdd1">增加</el-button>
<el-button type="warning" size="mini" @click="handleEdit1">编辑</el-button>
<br>
</el-card>
<el-card>
<el-table
:data="tableData2"
size="mini"
height="328"
highlight-current-row
border
@row-click="selectMaterialCategory">
<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="ID">
<template slot-scope="scope">
{{ scope.row.物料类别ID }}
</template>
</el-table-column>
<el-table-column label="操作" align="center">
<template slot-scope="scope">
<el-button
size="mini"
type="danger"
@click="handleDelete1(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
</div>
<div style="width: 49%;display: inline-block;margin-left: 20px">
<el-card>
<span>品种编号:</span>
<el-input v-model="VarietyNumber" placeholder="品种编号" size="mini" clearable style="width:100px"/>
<span>物料品种:</span>
<el-input v-model="MaterialVariety2" placeholder="物料品种" size="mini" clearable style="width:100px"/>
<span>规格1:</span>
<el-input v-model="Specifications1" placeholder="规格1" size="mini" clearable style="width:100px"/>
<br>
<span style="margin-left: 30px">规格2:</span>
<el-input v-model="Specifications2" placeholder="规格2" size="mini" clearable style="width:100px"/>
<el-button type="primary" size="mini" style="margin-left: 10px" @click="handleAdd2">增加</el-button>
<el-button type="warning" size="mini" @click="handleEdit2">编辑</el-button>
</el-card>
<el-card>
<el-table
:data="tableData3"
size="mini"
height="300"
highlight-current-row
border
@row-click="selectMaterialVariety">
<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="规格1">
<template slot-scope="scope">
{{ scope.row.规格1 }}
</template>
</el-table-column>
<el-table-column align="center" label="规格2">
<template slot-scope="scope">
{{ scope.row.规格2 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center">
<template slot-scope="scope">
<el-button
size="mini"
type="danger"
@click="handleDelete2(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
</div>
</el-dialog>
</div>
</template>
<script>
import {
initDepartmentName,
initMaterialCategory,
initMaterialVariety,
initMeasurementUnit,
initMaterialSource,
searchmaterial,
getSupplier,
addData,
editData,
deleteData,
searchCategory,
searchVarieties,
editCategory,
addCategory,
deleteCategory,
editVariety,
addVariety,
deleteVariety
} from '@/api/PurchasingCenter/MaterialManagement'
export default {
data() {
return {
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: 10,
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: {
物料流水号: '',
物料类别流水号: '',
物料品种流水号: '',
物料名称: '',
物料全名: '',
物料规格: '',
物料型号: '',
计量单位流水号: '',
物料来源流水号: '',
供货商: ''
},
rules: {
物料名称: [{ required: true, message: '请输入物料名称', trigger: 'blur' }],
供货商: [{ 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' }]
}
}
},
created() {
this.fetchData()
this.searchMaterialCategory()
},
methods: {
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.supplier !== '' ? 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.supplierValue).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.supplierValue1], '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>
span {
margin: 10px 0px 10px 10px;
}
</style>

View File

@@ -29,6 +29,7 @@
<el-card> <el-card>
<el-table <el-table
v-loading="loading1"
:data="tableData1" :data="tableData1"
border border
style="width: 100%;max-height: 300px;" style="width: 100%;max-height: 300px;"
@@ -69,7 +70,22 @@
</el-table-column> </el-table-column>
<el-table-column label="安全库存量" min-width="200" align="center"> <el-table-column label="安全库存量" min-width="200" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.安全库存量 }} <template v-if="scope.row.changeSafeValue">
<el-input v-model="scope.row.安全库存量" class="edit-input" size="mini"/>
<el-button class="cancel-btn" size="mini" icon="el-icon-refresh" type="warning" @click="cancelEdit(scope.row)">取消</el-button>
</template>
<span v-else>{{ scope.row.安全库存量 }}</span>
</template>
</el-table-column>
<el-table-column label="设置" min-width="100" align="center">
<template slot-scope="scope">
<el-button v-if="scope.row.changeSafeValue" type="mini" size="mini" icon="el-icon-circle-check-outline" @click="confirmEdit(scope.row)">确定</el-button>
<el-button
v-else
type="primary"
size="mini"
icon="el-icon-edit"
@click="scope.row.changeSafeValue=!scope.row.changeSafeValue">设置</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -228,12 +244,12 @@
</el-table-column> </el-table-column>
<el-table-column label="合计" align="center" min-width="100" prop="合计"> <el-table-column label="合计" align="center" min-width="100" prop="合计">
<template slot-scope="scope"> <template slot-scope="scope">
{{ parseFloat(scope.row.单价) * parseInt(scope.row.数量) }} {{ parseFloat(scope.row.单价||0) * parseInt(scope.row.数量||0) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" min-width="100"> <el-table-column label="操作" align="center" min-width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="danger" size="mini" icon="el-icon-delete" @click="deleteMateriel(scope.row)">移除</el-button> <el-button :disabled="disable" type="danger" size="mini" icon="el-icon-delete" @click="deleteMateriel(scope.row)">移除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -243,7 +259,7 @@
<el-table <el-table
:data="tableData4" :data="tableData4"
:show-header="false" :show-header="false"
highlight-current-row :highlight-current-row="!disable"
border border
height="280px" height="280px"
style="width: 250px;display:inline-block;max-height: 280px;" style="width: 250px;display:inline-block;max-height: 280px;"
@@ -256,7 +272,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-input :rows="20" v-model="textArea" :readonly="disable" type="textarea" style="width:calc(99% - 250px);float:right;margin-bottom: 20px" resize="none"/> <el-input :rows="20" v-model="textArea" :readonly="disable" type="textarea" style="width:calc(99% - 250px);float:right;margin-bottom: 20px" resize="none"/>
<el-button type="success" size="mini" icon="el-icon-circle-check-outline" @click="doneOfflineContact">生成离线合同</el-button> <el-button :disabled="disable" type="success" size="mini" icon="el-icon-circle-check-outline" @click="doneOfflineContact">生成离线合同</el-button>
</el-card> </el-card>
<el-dialog :visible.sync="dialogVisible1" title="供应商选择" center style="min-height: 300px"> <el-dialog :visible.sync="dialogVisible1" title="供应商选择" center style="min-height: 300px">
@@ -491,13 +507,14 @@
<script> <script>
import { searchInventoryNum, searchOfflineContract, searchOfflineContract2, searchSupplier, initPayMethod, initPayTimeNode, addOfflineContract, editOfflineContract, deleteOfflineContract, searchMateriel, import { searchInventoryNum, searchOfflineContract, searchOfflineContract2, searchSupplier, initPayMethod, initPayTimeNode, addOfflineContract, editOfflineContract, deleteOfflineContract, searchMateriel,
addMateriel, deleteMateriel, doneOfflineContact, searchContractDemo } from '@/api/PurchasingCenter/OfflineContract' addMateriel, deleteMateriel, doneOfflineContact, searchContractDemo, setSafeValue } from '@/api/PurchasingCenter/OfflineContract'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
export default { export default {
name: '', // 离线合同 name: '', // 离线合同
data() { data() {
return { return {
loading1: false,
title2: '', title2: '',
purchaseStateValue: 2, // 采购状态 全部 purchaseStateValue: 2, // 采购状态 全部
purchaseState: [ purchaseState: [
@@ -603,7 +620,7 @@ export default {
disable2: true, disable2: true,
disable3: true, disable3: true,
disable4: true, disable4: true,
disable: false // 其他的禁用 disable: true // 其他的禁用
} }
}, },
computed: { computed: {
@@ -640,12 +657,18 @@ export default {
}) })
}, },
searchTable1() { // 查询物料库物料 searchTable1() { // 查询物料库物料
this.loading1 = true
this.materialName ? this.check1 = 1 : this.check1 = 0 this.materialName ? this.check1 = 1 : this.check1 = 0
this.inventoryStateValue ? this.check2 = 1 : this.check2 = 0 this.inventoryStateValue ? this.check2 = 1 : this.check2 = 0
searchInventoryNum(this.pageCurrent1, this.pageSize1, this.check1, this.materialName, this.check2, this.inventoryStateValue, this.purchaseStateValue).then(response => { searchInventoryNum(this.pageCurrent1, this.pageSize1, this.check1, this.materialName, this.check2, this.inventoryStateValue, this.purchaseStateValue).then(response => {
console.log(response.data.rows)
this.tableData1 = response.data.rows this.tableData1 = response.data.rows
this.tableData1.map(v => {
this.$set(v, 'changeSafeValue', false)
v.原安全库存量 = v.安全库存量
return v
})
this.total1 = response.data.total this.total1 = response.data.total
this.loading1 = false
}) })
}, },
handleSizeChange1(val) { handleSizeChange1(val) {
@@ -663,6 +686,23 @@ export default {
this.materielGroup.push(val[i].物料流水号) this.materielGroup.push(val[i].物料流水号)
} }
}, },
cancelEdit(row) { // 取消设置
row.安全库存量 = row.原安全库存量
row.changeSafeValue = false
this.$message('取消修改')
},
confirmEdit(row) { // 确认设置
Number(row.安全库存量) ? row.安全库存量 = Number(row.安全库存量) : row.安全库存量 = 0
setSafeValue(row.物料流水号, parseInt(row.安全库存量)).then(response => {
if (response.data[0].result === '1') {
row.changeSafeValue = false
this.$message.success('设置成功')
this.searchTable1()
} else {
this.$message.error('设置失败')
}
})
},
searchTable2() { // 查询离线合同列表 searchTable2() { // 查询离线合同列表
this.offlineContract ? this.check3 = 1 : this.check3 = 0 this.offlineContract ? this.check3 = 1 : this.check3 = 0
this.supplierName0 ? this.check4 = 1 : this.check4 = 0 this.supplierName0 ? this.check4 = 1 : this.check4 = 0
@@ -963,9 +1003,11 @@ export default {
} }
} }
this.paramRow = row this.paramRow = row
if (!this.disable) {
searchContractDemo(this.paramRow.合同模板流水号).then(response => { searchContractDemo(this.paramRow.合同模板流水号).then(response => {
this.textArea = response.data[0].合同模板内容.replace('stipulateArrivalTime', this.stipulateArrivalTime).replace('payMethodName', this.payMethodName) this.textArea = response.data[0].合同模板内容.replace('stipulateArrivalTime', this.stipulateArrivalTime).replace('payMethodName', this.payMethodName)
}) })
}
}, },
payMethodChange() { // 付款方式改变 payMethodChange() { // 付款方式改变
for (let i = 0; i < this.payMethod.length; i++) { for (let i = 0; i < this.payMethod.length; i++) {
@@ -1023,4 +1065,12 @@ export default {
.searchForm .el-form-item{ .searchForm .el-form-item{
margin-bottom: 5px; margin-bottom: 5px;
} }
.edit-input {
padding-right: 100px;
}
.cancel-btn {
position: absolute;
right: 15px;
top: 5px;
}
</style> </style>

View File

@@ -95,7 +95,7 @@
</el-table> </el-table>
<el-button slot="reference" type="success" size="mini" icon="el-icon-search" style="margin-left: 10px" @click="searchTable02(scope.row)">查看详情</el-button> <el-button slot="reference" type="success" size="mini" icon="el-icon-search" style="margin-left: 10px" @click="searchTable02(scope.row)">查看详情</el-button>
</el-popover> </el-popover>
<el-button type="danger" size="mini" icon="el-icon-delete" style="margin-left: 10px" @click="cancelRequestFund(scope.row)">取消请款</el-button> <el-button :disabled="parseInt(scope.row.审核情况流水号)!==3&&parseInt(scope.row.审批情况流水号)!==3&&parseInt(scope.row.付款情况流水号)!==3" type="danger" size="mini" icon="el-icon-delete" style="margin-left: 10px" @click="cancelRequestFund(scope.row)">取消请款</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

View File

@@ -43,7 +43,7 @@
</el-table-column> </el-table-column>
<el-table-column label="预付款时间" align="center" min-width="100"> <el-table-column label="预付款时间" align="center" min-width="100">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.预付时间 }} {{ scope.row.预付时间.split(' ')[0] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="付款比例" align="center" min-width="100"> <el-table-column label="付款比例" align="center" min-width="100">
@@ -175,7 +175,7 @@
</el-table-column> </el-table-column>
<el-table-column label="付款时间" align="center" min-width="100"> <el-table-column label="付款时间" align="center" min-width="100">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.预付时间 }} {{ scope.row.预付时间 ? scope.row.预付时间.split(' ')[0] : '参考时间节点未设置' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="付款比例" align="center" min-width="100"> <el-table-column label="付款比例" align="center" min-width="100">

View File

@@ -165,6 +165,7 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button size="small" @click="dialogVisible3=false">取消</el-button>
<el-button type="primary" size="small" @click="submitApproval('form2')">确定</el-button> <el-button type="primary" size="small" @click="submitApproval('form2')">确定</el-button>
</div> </div>
</el-dialog> </el-dialog>
@@ -214,7 +215,7 @@ export default {
], ],
disabled: true, disabled: true,
form2: { form2: {
审批是否通过: '', 审批是否通过: 1,
未通过原因: '' 未通过原因: ''
}, },
rules2: {}, rules2: {},

Some files were not shown because too many files have changed in this diff Show More