自制件出库
This commit is contained in:
@@ -5,8 +5,8 @@ export function search1() {
|
|||||||
url: '',
|
url: '',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data: {
|
data: {
|
||||||
type: '1',
|
type: '3',
|
||||||
name: '合同信息管理_项目名称_总_查询'
|
name: `select SUM(开票金额) as 开票金额,replace(convert(varchar(5), 操作时间, 121),'-','') as 开票时间 from 合同信息管理_开票记录_视图 group by replace(convert(varchar(5), 操作时间, 121),'-','')`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -26,7 +26,7 @@ export function search3() {
|
|||||||
method: 'post',
|
method: 'post',
|
||||||
data: {
|
data: {
|
||||||
type: '3',
|
type: '3',
|
||||||
name: 'SELECT count(客户名称) as 客户数量,[省份] FROM [客户关系管理系统_客户_查询数据_MESWOR_视图]where [客户名称是否启用] = 1 group by [省份]'
|
name: `select 项目名称,CONVERT(nvarchar(50),sum(已收金额)) as 已收金额,CONVERT(nvarchar(50),sum(应收金额)) as 应收金额,CONVERT(nvarchar(50),(sum(应收金额)-sum(已收金额))) as 待收金额 from 视图_分批资金查询 where 是否启用= 1 group by 项目流水号,项目名称`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,16 +17,16 @@ export const uploadInvoiceScan1 = `http://192.168.1.231:8411/submit/uploadInvoic
|
|||||||
export const download = `http://192.168.1.231:8411/submit/downloadFile.ashx` // ContractInformationManagement
|
export const download = `http://192.168.1.231:8411/submit/downloadFile.ashx` // ContractInformationManagement
|
||||||
export const uploadPerson = `http://192.168.1.231:8411/submit/uploadPerson.ashx`
|
export const uploadPerson = `http://192.168.1.231:8411/submit/uploadPerson.ashx`
|
||||||
export const uploadOP = `http://192.168.1.231:8411/submit/uploadOP.ashx`
|
export const uploadOP = `http://192.168.1.231:8411/submit/uploadOP.ashx`
|
||||||
export const url = `http://192.168.0.104:8079/submit/MESCommonBase.ashx` // 采购件入库、离线件入库
|
export const url = `http://192.168.1.231:8411/submit/MESCommonBase.ashx` // 采购件入库、离线件入库
|
||||||
export const ExcelDownLoad = 'http://192.168.0.104:8079/submit/downloadFile.ashx' // 导出excel
|
export const ExcelDownLoad = 'http://192.168.1.231:8411/submit/downloadFile.ashx' // 导出excel
|
||||||
// 技术中心程序发布时要更改下面所有的IP到0段
|
// 技术中心程序发布时要更改下面所有的IP到0段
|
||||||
export const ServerIP = `http://192.168.1.231:8411/webpage/file/`
|
export const ServerIP = `http://192.168.1.231:8411/webpage/file/`
|
||||||
export const uploadFileMachine = `http://192.168.1.231:8411/submit/uploadFileMachine.ashx` // 机床总图 发布时改成0.231
|
export const uploadFileMachine = `http://192.168.1.231:8411/submit/uploadFileMachine.ashx` // 机床总图 发布时改成0.231
|
||||||
export const downloadFileMachine = `http://192.168.1.231:8411/submit/downloadFileMachine.ashx` // 机床总图 发布时改成0.231
|
export const downloadFileMachine = `http://192.168.1.231:8411/submit/downloadFileMachine.ashx` // 机床总图 发布时改成0.231
|
||||||
export const MESUploadFile = `http://192.168.0.110:8002/submit/MESUploadFile.ashx`
|
export const MESUploadFile = `http://192.168.1.231:8411/submit/MESUploadFile.ashx`
|
||||||
export const MESDownloadFile = `http://192.168.0.110:8002/submit/MESDownloadFile.ashx`
|
export const MESDownloadFile = `http://192.168.1.231:8411/submit/MESDownloadFile.ashx`
|
||||||
const service = axios.create({
|
const service = axios.create({
|
||||||
baseURL: `http://192.168.0.104:8079/submit/MESCommonBase.ashx`,
|
baseURL: `http://192.168.1.231:8411/submit/MESCommonBase.ashx`,
|
||||||
timeout: 1500000 // 请求超时时间
|
timeout: 1500000 // 请求超时时间
|
||||||
})
|
})
|
||||||
export default service
|
export default service
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-card v-loading="loading1" style="height: 450px">
|
<el-card v-loading="loading1" style="height: 450px">
|
||||||
<span>项目完成进度查询</span>
|
<span>年营销金额图表</span>
|
||||||
<el-button size="small" type="success" icon="el-icon-search" @click="search1()">查询</el-button>
|
<el-button size="small" type="success" icon="el-icon-search" @click="search1()">查询</el-button>
|
||||||
<div id="myChart1" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
|
<div id="myChart1" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
|
||||||
</el-card>
|
</el-card>
|
||||||
@@ -19,18 +19,11 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-card v-loading="loading3" style="height: 450px">
|
<el-card v-loading="loading3" style="height: 450px">
|
||||||
<span>年营销金额图表</span>
|
<span>在执行项目金额及回款</span>
|
||||||
<el-button size="small" type="success" icon="el-icon-search" @click="search3()">查询</el-button>
|
<el-button size="small" type="success" icon="el-icon-search" @click="search3()">查询</el-button>
|
||||||
<div id="myChart3" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
|
<div id="myChart3" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
|
||||||
</el-card>
|
</el-card>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
|
||||||
<el-card v-loading="loading4" style="height: 450px">
|
|
||||||
<span>在执行项目金额及回款</span>
|
|
||||||
<el-button size="small" type="success" icon="el-icon-search" @click="search4()">查询</el-button>
|
|
||||||
<div id="myChart4" :style="{width: '100%', height: '400px', margin: 'auto'}"/>
|
|
||||||
</el-card>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -63,8 +56,8 @@ export default {
|
|||||||
var dataX = []
|
var dataX = []
|
||||||
var lineData = []
|
var lineData = []
|
||||||
for (let i = 0; i < data.length; i++) {
|
for (let i = 0; i < data.length; i++) {
|
||||||
dataX.push(data[i].项目名称)
|
dataX.push(data[i].开票时间)
|
||||||
lineData.push((Math.random() * 100).toFixed(2))
|
lineData.push(data[i].开票金额)
|
||||||
}
|
}
|
||||||
var myChart1 = echarts.init(document.getElementById('myChart1'))
|
var myChart1 = echarts.init(document.getElementById('myChart1'))
|
||||||
myChart1.clear()
|
myChart1.clear()
|
||||||
@@ -75,26 +68,29 @@ export default {
|
|||||||
},
|
},
|
||||||
grid: {
|
grid: {
|
||||||
left: '3%',
|
left: '3%',
|
||||||
right: '4%',
|
right: '8%',
|
||||||
bottom: '3%',
|
bottom: '3%',
|
||||||
containLabel: true
|
containLabel: true
|
||||||
},
|
},
|
||||||
tooltip: {
|
tooltip: {
|
||||||
trigger: 'axis'
|
trigger: 'axis',
|
||||||
|
axisPointer: {
|
||||||
|
type: 'shadow'
|
||||||
|
}
|
||||||
},
|
},
|
||||||
xAxis: {
|
xAxis: {
|
||||||
type: 'category',
|
type: 'category',
|
||||||
name: '项目名称',
|
name: '年份',
|
||||||
axisLabel: {
|
// axisLabel: {
|
||||||
interval: 0,
|
// interval: 0,
|
||||||
rotate: 40,
|
// rotate: 40,
|
||||||
margin: 10
|
// margin: 10
|
||||||
},
|
// },
|
||||||
data: dataX
|
data: dataX
|
||||||
},
|
},
|
||||||
yAxis: {
|
yAxis: {
|
||||||
type: 'value',
|
type: 'value',
|
||||||
name: '完成进度(%)',
|
name: '金额',
|
||||||
min: 0,
|
min: 0,
|
||||||
scale: 'true'
|
scale: 'true'
|
||||||
},
|
},
|
||||||
@@ -180,69 +176,23 @@ export default {
|
|||||||
drawLine3(data) {
|
drawLine3(data) {
|
||||||
var dataX = []
|
var dataX = []
|
||||||
var lineData = []
|
var lineData = []
|
||||||
|
var lineData2 = []
|
||||||
for (let i = 0; i < data.length; i++) {
|
for (let i = 0; i < data.length; i++) {
|
||||||
dataX.push({
|
dataX.push(data[i].项目名称)
|
||||||
value: parseInt(data[i].客户数量),
|
lineData.push(data[i].已收金额)
|
||||||
name: data[i].省份
|
lineData2.push(data[i].待收金额)
|
||||||
})
|
|
||||||
lineData.push(data[i].省份)
|
|
||||||
}
|
}
|
||||||
var myChart3 = echarts.init(document.getElementById('myChart3'))
|
var myChart3 = echarts.init(document.getElementById('myChart3'))
|
||||||
myChart3.clear()
|
myChart3.clear()
|
||||||
myChart3.setOption({
|
myChart3.setOption({
|
||||||
title: {
|
|
||||||
text: '客户分布图',
|
|
||||||
x: 'center'
|
|
||||||
},
|
|
||||||
tooltip: {
|
tooltip: {
|
||||||
trigger: 'item',
|
trigger: 'axis',
|
||||||
formatter: '{a} <br/>{b} : {c} ({d}%)'
|
axisPointer: {
|
||||||
|
type: 'shadow'
|
||||||
|
}
|
||||||
},
|
},
|
||||||
legend: {
|
legend: {
|
||||||
orient: 'vertical',
|
data: ['已收金额', '待收金额']
|
||||||
left: 'left',
|
|
||||||
data: lineData
|
|
||||||
},
|
|
||||||
series: [
|
|
||||||
{
|
|
||||||
name: '省份',
|
|
||||||
type: 'pie',
|
|
||||||
radius: '55%',
|
|
||||||
center: ['50%', '60%'],
|
|
||||||
data: dataX,
|
|
||||||
itemStyle: {
|
|
||||||
emphasis: {
|
|
||||||
shadowBlur: 10,
|
|
||||||
shadowOffsetX: 0,
|
|
||||||
shadowColor: 'rgba(0, 0, 0, 0.5)'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
})
|
|
||||||
},
|
|
||||||
search4() {
|
|
||||||
this.loading1 = true
|
|
||||||
var myChart1 = echarts.init(document.getElementById('myChart1'))
|
|
||||||
myChart1.clear()
|
|
||||||
search1().then(response => {
|
|
||||||
this.loading1 = false
|
|
||||||
this.drawLine1(response.data)
|
|
||||||
})
|
|
||||||
},
|
|
||||||
drawLine4(data) {
|
|
||||||
var dataX = []
|
|
||||||
var lineData = []
|
|
||||||
for (let i = 0; i < data.length; i++) {
|
|
||||||
dataX.push(data[i].项目名称)
|
|
||||||
lineData.push((Math.random() * 100).toFixed(2))
|
|
||||||
}
|
|
||||||
var myChart1 = echarts.init(document.getElementById('myChart1'))
|
|
||||||
myChart1.clear()
|
|
||||||
myChart1.setOption({
|
|
||||||
title: {
|
|
||||||
left: 'center',
|
|
||||||
text: '直方图'
|
|
||||||
},
|
},
|
||||||
grid: {
|
grid: {
|
||||||
left: '3%',
|
left: '3%',
|
||||||
@@ -250,36 +200,44 @@ export default {
|
|||||||
bottom: '3%',
|
bottom: '3%',
|
||||||
containLabel: true
|
containLabel: true
|
||||||
},
|
},
|
||||||
tooltip: {
|
|
||||||
trigger: 'axis'
|
|
||||||
},
|
|
||||||
xAxis: {
|
xAxis: {
|
||||||
type: 'category',
|
type: 'category',
|
||||||
name: '项目名称',
|
data: dataX,
|
||||||
axisLabel: {
|
axisLabel: {
|
||||||
interval: 0,
|
interval: 0,
|
||||||
rotate: 40,
|
rotate: 40,
|
||||||
margin: 10
|
margin: 10
|
||||||
},
|
}
|
||||||
data: dataX
|
|
||||||
},
|
},
|
||||||
yAxis: {
|
yAxis: {
|
||||||
type: 'value',
|
type: 'value'
|
||||||
name: '完成进度(%)',
|
|
||||||
min: 0,
|
|
||||||
scale: 'true'
|
|
||||||
},
|
},
|
||||||
series: [
|
series: [
|
||||||
{
|
{
|
||||||
name: '测量值',
|
name: '已收金额',
|
||||||
type: 'bar',
|
type: 'bar',
|
||||||
data: lineData,
|
stack: '总量',
|
||||||
|
color: '#67C23A',
|
||||||
|
label: {
|
||||||
|
normal: {
|
||||||
|
show: true,
|
||||||
|
position: 'inside'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data: lineData
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: '待收金额',
|
||||||
|
type: 'bar',
|
||||||
|
stack: '总量',
|
||||||
|
color: 'rgb(213,58,53)',
|
||||||
label: {
|
label: {
|
||||||
normal: {
|
normal: {
|
||||||
show: true,
|
show: true,
|
||||||
position: 'top'
|
position: 'top'
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
data: lineData2
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -101,10 +101,10 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="数量" width="100">
|
<el-table-column align="center" label="数量" width="100">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<template v-if="disabledPick === false">
|
<!--<template v-if="disabledPick === false">-->
|
||||||
<el-input-number v-model="scope.row.数量" :min="1" label="描述文字" size="mini" controls-position="right" style="width:100px" @change="handleChange"/>
|
<!--<el-input-number v-model="scope.row.数量" :min="1" label="描述文字" size="mini" controls-position="right" style="width:100px" @change="handleChange"/>-->
|
||||||
</template>
|
<!--</template>-->
|
||||||
<template v-else>
|
<template slot-scope="scope">
|
||||||
{{ scope.row.数量 }}
|
{{ scope.row.数量 }}
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -68,18 +68,18 @@
|
|||||||
<el-tooltip :open-delay="1000" effect="dark" content="开启物料变更" placement="top">
|
<el-tooltip :open-delay="1000" effect="dark" content="开启物料变更" placement="top">
|
||||||
<el-switch v-model="switchValue" active-color="#13ce66" inactive-color="#ff4949" style="margin-left: 30px"/>
|
<el-switch v-model="switchValue" active-color="#13ce66" inactive-color="#ff4949" style="margin-left: 30px"/>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
<el-date-picker
|
<!--<el-date-picker-->
|
||||||
v-model="startTime"
|
<!--v-model="startTime"-->
|
||||||
size="small"
|
<!--size="small"-->
|
||||||
type="daterange"
|
<!--type="daterange"-->
|
||||||
align="center"
|
<!--align="center"-->
|
||||||
value-format="yyyy-MM-dd"
|
<!--value-format="yyyy-MM-dd"-->
|
||||||
format="yyyy-MM-dd"
|
<!--format="yyyy-MM-dd"-->
|
||||||
range-separator="~"
|
<!--range-separator="~"-->
|
||||||
style="width:250px"
|
<!--style="width:250px"-->
|
||||||
start-placeholder="开始日期"
|
<!--start-placeholder="开始日期"-->
|
||||||
end-placeholder="结束日期"
|
<!--end-placeholder="结束日期"-->
|
||||||
@change="timeChange1()"/>
|
<!--@change="timeChange1()"/>-->
|
||||||
<el-popover v-model="visible1" placement="top" width="140">
|
<el-popover v-model="visible1" placement="top" width="140">
|
||||||
<div style="text-align: right; margin: 0">
|
<div style="text-align: right; margin: 0">
|
||||||
<el-select v-model="PersonValue" style="width:100px" placeholder="人员" size="small" filterable clearable>
|
<el-select v-model="PersonValue" style="width:100px" placeholder="人员" size="small" filterable clearable>
|
||||||
@@ -280,18 +280,18 @@
|
|||||||
<!--<el-cascader :options="materialStatus" :props="{ checkStrictly: true }" v-model="materialStatusValue" style="width: 100px" size="small"/>-->
|
<!--<el-cascader :options="materialStatus" :props="{ checkStrictly: true }" v-model="materialStatusValue" style="width: 100px" size="small"/>-->
|
||||||
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="searchTable12()">查询</el-button>
|
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="searchTable12()">查询</el-button>
|
||||||
<el-button type="warning" size="small" icon="el-icon-download" style="margin-left: 10px" @click="exportUninquirySheet">导出未询价单</el-button>
|
<el-button type="warning" size="small" icon="el-icon-download" style="margin-left: 10px" @click="exportUninquirySheet">导出未询价单</el-button>
|
||||||
<el-date-picker
|
<!--<el-date-picker-->
|
||||||
v-model="endTime"
|
<!--v-model="endTime"-->
|
||||||
size="small"
|
<!--size="small"-->
|
||||||
type="daterange"
|
<!--type="daterange"-->
|
||||||
align="center"
|
<!--align="center"-->
|
||||||
value-format="yyyy-MM-dd"
|
<!--value-format="yyyy-MM-dd"-->
|
||||||
format="yyyy-MM-dd"
|
<!--format="yyyy-MM-dd"-->
|
||||||
range-separator="~"
|
<!--range-separator="~"-->
|
||||||
style="width:250px"
|
<!--style="width:250px"-->
|
||||||
start-placeholder="开始日期"
|
<!--start-placeholder="开始日期"-->
|
||||||
end-placeholder="结束日期"
|
<!--end-placeholder="结束日期"-->
|
||||||
@change="timeChange2()"/>
|
<!--@change="timeChange2()"/>-->
|
||||||
<el-button type="success" size="small" style="float: right" @click="visible2 = false;tiaozheng2()">调整采购任务</el-button>
|
<el-button type="success" size="small" style="float: right" @click="visible2 = false;tiaozheng2()">调整采购任务</el-button>
|
||||||
<el-select v-model="PersonValue" style="width:100px;float: right" placeholder="人员" size="small" filterable clearable>
|
<el-select v-model="PersonValue" style="width:100px;float: right" placeholder="人员" size="small" filterable clearable>
|
||||||
<el-option
|
<el-option
|
||||||
@@ -1754,7 +1754,7 @@ export default {
|
|||||||
this.projectValue ? check4 = 1 : check4 = 0
|
this.projectValue ? check4 = 1 : check4 = 0
|
||||||
this.machineValue ? check5 = 1 : check5 = 0
|
this.machineValue ? check5 = 1 : check5 = 0
|
||||||
this.groupValue ? check6 = 1 : check6 = 0
|
this.groupValue ? check6 = 1 : check6 = 0
|
||||||
this.startTime ? check7 = 1 : (check7 = 0, this.startTime = '')
|
this.startTime ? check7 = 0 : (check7 = 0, this.startTime = '')
|
||||||
searchMaterial(this.pageCurrent11, this.pageSize11, 3, check1, this.materialName, check2, this.materialSpec, check3, this.materialModel, this.id, check4, this.projectValue, check5, this.machineValue, check6, this.groupValue, check7, this.startTime[0], this.startTime[1]).then(response => {
|
searchMaterial(this.pageCurrent11, this.pageSize11, 3, check1, this.materialName, check2, this.materialSpec, check3, this.materialModel, this.id, check4, this.projectValue, check5, this.machineValue, check6, this.groupValue, check7, this.startTime[0], this.startTime[1]).then(response => {
|
||||||
this.tableData11 = response.data.rows
|
this.tableData11 = response.data.rows
|
||||||
this.total11 = response.data.total
|
this.total11 = response.data.total
|
||||||
@@ -1793,7 +1793,7 @@ export default {
|
|||||||
this.projectValue ? check4 = 1 : check4 = 0
|
this.projectValue ? check4 = 1 : check4 = 0
|
||||||
this.machineValue ? check5 = 1 : check5 = 0
|
this.machineValue ? check5 = 1 : check5 = 0
|
||||||
this.groupValue ? check6 = 1 : check6 = 0
|
this.groupValue ? check6 = 1 : check6 = 0
|
||||||
this.endTime ? check7 = 1 : (check7 = 0, this.endTime = '')
|
this.endTime ? check7 = 0 : (check7 = 0, this.endTime = '')
|
||||||
searchPart(this.pageCurrent12, this.pageSize12, 3, check1, this.partNum, check2, this.partName, check3, this.partSpec, this.id, check4, this.projectValue, check5, this.machineValue, check6, this.groupValue, check7, this.endTime[0], this.endTime[1]).then(response => {
|
searchPart(this.pageCurrent12, this.pageSize12, 3, check1, this.partNum, check2, this.partName, check3, this.partSpec, this.id, check4, this.projectValue, check5, this.machineValue, check6, this.groupValue, check7, this.endTime[0], this.endTime[1]).then(response => {
|
||||||
this.tableData12 = response.data.rows
|
this.tableData12 = response.data.rows
|
||||||
this.total12 = response.data.total
|
this.total12 = response.data.total
|
||||||
|
|||||||
@@ -48,84 +48,56 @@
|
|||||||
</el-upload>
|
</el-upload>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-card>
|
<el-card>
|
||||||
<el-table
|
<el-table v-loading="loading" :data="tableData" border size="mini" style="width: 100%;max-height: 520px" height="520">
|
||||||
v-loading="loading"
|
<el-table-column label="序号" align="center" type="index" width="50"/>
|
||||||
:data="tableData"
|
<el-table-column label="机床图号" align="center" min-width="100px">
|
||||||
highlight-current-row
|
<template slot-scope="scope">
|
||||||
border
|
{{ scope.row.机床图号 }}
|
||||||
size="mini"
|
</template>
|
||||||
style="width: 100%;max-height: 520px"
|
|
||||||
height="520">
|
|
||||||
<el-table-column
|
|
||||||
label="序号"
|
|
||||||
align="center"
|
|
||||||
type="index"
|
|
||||||
width="50"/>
|
|
||||||
<el-table-column
|
|
||||||
label="机床图号"
|
|
||||||
align="center"
|
|
||||||
min-width="100px">
|
|
||||||
<template slot-scope="scope">{{ scope.row.机床图号 }}</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="零件图号" align="center" min-width="100px">
|
||||||
label="零件图号"
|
<template slot-scope="scope">
|
||||||
align="center"
|
{{ scope.row.零件图号 }}
|
||||||
min-width="100px">
|
</template>
|
||||||
<template slot-scope="scope">{{ scope.row.零件图号 }}</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="零件名称" align="center" min-width="100px">
|
||||||
label="零件名称"
|
<template slot-scope="scope">
|
||||||
align="center"
|
{{ scope.row.零件名称 }}
|
||||||
min-width="100px">
|
</template>
|
||||||
<template slot-scope="scope">{{ scope.row.零件名称 }}</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="组号" align="center" min-width="100px">
|
||||||
label="组号"
|
<template slot-scope="scope">
|
||||||
align="center"
|
{{ scope.row.组号 }}
|
||||||
min-width="100px">
|
</template>
|
||||||
<template slot-scope="scope">{{ scope.row.组号 }}</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="材料" align="center">
|
||||||
label="材料"
|
<template slot-scope="scope">
|
||||||
align="center">
|
{{ scope.row.材料 }}
|
||||||
<template slot-scope="scope">{{ scope.row.材料 }}</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="备注" align="center">
|
||||||
label="备注"
|
<template slot-scope="scope">
|
||||||
align="center">
|
{{ scope.row.零件备注 }}
|
||||||
<template slot-scope="scope">{{ scope.row.零件备注 }}</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="零件类型" align="center">
|
||||||
label="零件类型"
|
<template slot-scope="scope">
|
||||||
align="center">
|
{{ scope.row.零件类型名称 }}
|
||||||
<template slot-scope="scope">{{ scope.row.零件类型名称 }}</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column label="是否导入" align="center">
|
||||||
label="是否导入"
|
|
||||||
align="center">
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="Number(scope.row.是否导入)===1" type="success">已导入</el-tag>
|
<el-tag v-if="Number(scope.row.是否导入)===1" type="success">已导入</el-tag>
|
||||||
<el-tag v-else type="danger">未导入</el-tag>
|
<el-tag v-else type="danger">未导入</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column min-width="50px" label="零件图纸" align="center">
|
||||||
min-width="50px"
|
|
||||||
label="零件图纸"
|
|
||||||
align="center">
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
|
|
||||||
<el-button circle icon="el-icon-search" size="small" @click="getNum(scope.row)"/>
|
<el-button circle icon="el-icon-search" size="small" @click="getNum(scope.row)"/>
|
||||||
<!--<el-button slot="reference" type="success" icon="el-icon-search" circle size="mini"></el-button>-->
|
|
||||||
<!--<el-button type="success" icon="el-icon-search" circle size="mini"></el-button>-->
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column min-width="80px" label="操作" align="center">
|
||||||
<el-table-column
|
|
||||||
min-width="80px"
|
|
||||||
label="操作"
|
|
||||||
align="center">
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<!--<FileUpload ref="FileUpload" :num="scope.row.基本件流水号" table-name="机加工MES_零件图PDF表" @listenMsg ="listenMsgFromChid"/>-->
|
|
||||||
<el-upload
|
<el-upload
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:action="action"
|
:action="action"
|
||||||
@@ -150,7 +122,6 @@
|
|||||||
@size-change="handleSizeChanges"
|
@size-change="handleSizeChanges"
|
||||||
@current-change="handleCurrentChanges"/>
|
@current-change="handleCurrentChanges"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-dialog
|
<el-dialog
|
||||||
:show-close="close"
|
:show-close="close"
|
||||||
@@ -198,7 +169,7 @@ export default {
|
|||||||
loading: false,
|
loading: false,
|
||||||
tableData: [],
|
tableData: [],
|
||||||
fileList: [],
|
fileList: [],
|
||||||
showFileList: true,
|
showFileList: false,
|
||||||
action: '',
|
action: '',
|
||||||
disabled: false,
|
disabled: false,
|
||||||
tableName: '机加工MES_零件图PDF表',
|
tableName: '机加工MES_零件图PDF表',
|
||||||
@@ -275,11 +246,11 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getAction(row) {
|
getAction(row) {
|
||||||
this.num = row.基本件流水号
|
this.num = row.零件图号
|
||||||
this.action = `${MESUploadFile}?&num=${this.num}&tableName=${this.tableName}`
|
this.action = `${MESUploadFile}?&num=${this.num}&tableName=${this.tableName}&type=2`
|
||||||
},
|
},
|
||||||
batchImportOfDrawings() {
|
batchImportOfDrawings() {
|
||||||
this.action = `${MESUploadFile}?&num=${this.num1}&tableName=${this.tableName}`
|
this.action = `${MESUploadFile}?&num=${this.num1}&tableName=${this.tableName}&type=1`
|
||||||
},
|
},
|
||||||
getNum(row) {
|
getNum(row) {
|
||||||
this.row1 = row
|
this.row1 = row
|
||||||
@@ -288,27 +259,38 @@ export default {
|
|||||||
this.getFileList(row.零件图号)
|
this.getFileList(row.零件图号)
|
||||||
},
|
},
|
||||||
uploadSuccess(res, file, fileList) {
|
uploadSuccess(res, file, fileList) {
|
||||||
console.log(res[0].result, 12345)
|
this.getTableData()
|
||||||
if (res[0].result === '1') {
|
if (res[0].result === '1') {
|
||||||
const index = fileList.indexOf(file)
|
const index = fileList.indexOf(file)
|
||||||
fileList.splice(index, 1)
|
fileList.splice(index, 1)
|
||||||
} else {
|
} else {
|
||||||
this.str = res[0].result
|
this.str = res[0].result
|
||||||
this.arr = this.str.split('|')
|
this.arr = this.str.split('|')
|
||||||
console.log(this.arr[0], 0)
|
|
||||||
console.log(this.arr[1], 1)
|
|
||||||
if (this.arr[1] === '无该零件') {
|
if (this.arr[1] === '无该零件') {
|
||||||
this.$notify.error(`${this.arr[0]}该零件不存在,请检查上传文件名称是否正确!`)
|
this.$notify.error({
|
||||||
|
title: '提示',
|
||||||
|
message: `${this.arr[0]}该零件不存在,请检查上传文件名称是否正确!`,
|
||||||
|
duration: 0
|
||||||
|
})
|
||||||
}
|
}
|
||||||
if (this.arr[1] === '重复') {
|
if (this.arr[1] === '重复') {
|
||||||
this.$notify.error(`${this.arr[0]}请勿重复上传!`)
|
this.$notify.error({
|
||||||
|
title: '提示',
|
||||||
|
message: `${this.arr[0]}请勿重复上传!`,
|
||||||
|
duration: 0
|
||||||
|
})
|
||||||
|
}
|
||||||
|
if (this.arr[1] === '零件图号不正确') {
|
||||||
|
this.$notify.error({
|
||||||
|
title: '提示',
|
||||||
|
message: `${this.arr[0]}和所选图号不符!`,
|
||||||
|
duration: 0
|
||||||
|
})
|
||||||
}
|
}
|
||||||
// this.$message.error(`${file.name}该零件不存在,请检查上传文件名称是否正确!`)
|
|
||||||
}
|
}
|
||||||
if (fileList.length === 0) {
|
if (fileList.length === 0) {
|
||||||
this.$message.success('文件上传成功')
|
this.$message.success('文件上传成功')
|
||||||
// this.$refs.FileDown.getFileList(this.num)
|
// this.getTableData()
|
||||||
this.getTableData()
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
uploadFailure(a, file, fileList) {
|
uploadFailure(a, file, fileList) {
|
||||||
@@ -347,12 +329,9 @@ export default {
|
|||||||
this.getTableData()
|
this.getTableData()
|
||||||
},
|
},
|
||||||
async getFileList(value) {
|
async getFileList(value) {
|
||||||
// console.log(this.row1.零件图号, 11111)
|
|
||||||
// console.log(value, 121212)
|
|
||||||
this.hadFile = []
|
this.hadFile = []
|
||||||
this.deleteShow === '1' ? this.isDeleteShow = true : this.isDeleteShow = false
|
this.deleteShow === '1' ? this.isDeleteShow = true : this.isDeleteShow = false
|
||||||
if (value) {
|
if (value) {
|
||||||
// if (value === 1) {
|
|
||||||
await request({
|
await request({
|
||||||
url: '',
|
url: '',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
@@ -362,7 +341,6 @@ export default {
|
|||||||
}
|
}
|
||||||
}).then(data => {
|
}).then(data => {
|
||||||
this.suffix = data.data
|
this.suffix = data.data
|
||||||
console.log(this.suffix, 11111)
|
|
||||||
if (data.data.length > 0) {
|
if (data.data.length > 0) {
|
||||||
if (this.operationType === '1') {
|
if (this.operationType === '1') {
|
||||||
data.data.map(item => {
|
data.data.map(item => {
|
||||||
@@ -386,40 +364,6 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
// } else {
|
|
||||||
// await request({
|
|
||||||
// url: '',
|
|
||||||
// method: 'post',
|
|
||||||
// data: {
|
|
||||||
// type: '3',
|
|
||||||
// name: `select * from ${this.tableName} where 是否启用 = 1 and num = ${value}`
|
|
||||||
// }
|
|
||||||
// }).then(data => {
|
|
||||||
// this.suffix = data.data
|
|
||||||
// if (data.data.length > 0) {
|
|
||||||
// if (this.operationType === '1') {
|
|
||||||
// data.data.map(item => {
|
|
||||||
// this.hadFile.push({
|
|
||||||
// url: `${MESDownloadFile}?id=${item.uid}.${item.suffix}&name=${item.name}.${item.suffix}`,
|
|
||||||
// name: `${item.name}.${item.suffix}`,
|
|
||||||
// suffix: item.suffix,
|
|
||||||
// id: item.uid
|
|
||||||
// })
|
|
||||||
// })
|
|
||||||
// } else if (this.operationType === '0') {
|
|
||||||
// const server = `${MESDownloadFile}`.split('/')
|
|
||||||
// data.data.map(item => {
|
|
||||||
// this.hadFile.push({
|
|
||||||
// url: `http://${server[2]}/webpage/part/${item.uid}.${item.suffix}`,
|
|
||||||
// name: `${item.name}.${item.suffix}`,
|
|
||||||
// suffix: item.suffix,
|
|
||||||
// id: item.uid
|
|
||||||
// })
|
|
||||||
// })
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
async deleteFileData(id) {
|
async deleteFileData(id) {
|
||||||
@@ -439,9 +383,11 @@ export default {
|
|||||||
this.getTableData()
|
this.getTableData()
|
||||||
if (response.data.length === 0) {
|
if (response.data.length === 0) {
|
||||||
this.$message.success('删除成功')
|
this.$message.success('删除成功')
|
||||||
|
this.dialogVisible = false
|
||||||
this.getFileList(this.num)
|
this.getFileList(this.num)
|
||||||
} else {
|
} else {
|
||||||
this.$message.error('删除失败')
|
this.$message.error('删除失败')
|
||||||
|
this.dialogVisible = false
|
||||||
this.getFileList(this.num)
|
this.getFileList(this.num)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user