|
@ -390,27 +390,6 @@ |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
</el-row> |
|
|
</el-row> |
|
|
|
|
|
|
|
|
<!-- <el-row> |
|
|
|
|
|
<el-col :md="4" :xs="24"> |
|
|
|
|
|
<el-form-item label="CP5时间:" /> |
|
|
|
|
|
</el-col> |
|
|
|
|
|
<el-col :md="20" :xs="24" style="margin-left: -80px"> |
|
|
|
|
|
<el-form-item> |
|
|
|
|
|
<el-date-picker |
|
|
|
|
|
v-model="datetime5" |
|
|
|
|
|
type="datetimerange" |
|
|
|
|
|
:picker-options="pickerOptionsCp5" |
|
|
|
|
|
range-separator="至" |
|
|
|
|
|
start-placeholder="开始日期" |
|
|
|
|
|
end-placeholder="结束日期" |
|
|
|
|
|
value-format="yyyy-MM-dd HH:mm:ss" |
|
|
|
|
|
:default-time="['00:00:00', '23:59:59']" |
|
|
|
|
|
> |
|
|
|
|
|
</el-date-picker> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-col> |
|
|
|
|
|
</el-row> --> |
|
|
|
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :md="4" :xs="24"> |
|
|
<el-col :md="4" :xs="24"> |
|
|
<el-form-item label="CP5时间:" /> |
|
|
<el-form-item label="CP5时间:" /> |
|
@ -480,17 +459,30 @@ |
|
|
<el-col :md="4" :xs="24"> |
|
|
<el-col :md="4" :xs="24"> |
|
|
<el-form-item label="KEEN号" /> |
|
|
<el-form-item label="KEEN号" /> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :md="20" :xs="24" style="margin-left: -80px"> |
|
|
<el-col :md="18" :xs="24" style="margin-left: -80px"> |
|
|
<el-form-item prop="kennCode"> |
|
|
<el-form-item prop="kennCode"> |
|
|
<el-input |
|
|
<el-input |
|
|
type="textarea" |
|
|
type="textarea" |
|
|
v-model="formCount.kennCode" |
|
|
v-model="formCount.kennCode" |
|
|
style="width: 450px" |
|
|
style="width: 380px" |
|
|
placeholder="请输入内容" |
|
|
placeholder="KEEN号用逗号分隔!" |
|
|
@paste.native="pasteExcelToKennCode" |
|
|
|
|
|
/> |
|
|
/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
|
|
|
<el-col :md="2" :xs="24"> |
|
|
|
|
|
<el-tooltip |
|
|
|
|
|
content="一键复制粘贴" |
|
|
|
|
|
placement="bottom" |
|
|
|
|
|
effect="light" |
|
|
|
|
|
> |
|
|
|
|
|
<el-button |
|
|
|
|
|
type="primary" |
|
|
|
|
|
icon="el-icon-edit" |
|
|
|
|
|
circle |
|
|
|
|
|
@click="showModal = true" |
|
|
|
|
|
></el-button> |
|
|
|
|
|
</el-tooltip> |
|
|
|
|
|
</el-col> |
|
|
</el-row> |
|
|
</el-row> |
|
|
|
|
|
|
|
|
<el-row> |
|
|
<el-row> |
|
@ -503,7 +495,7 @@ |
|
|
v-model="formCount.chassisNumber" |
|
|
v-model="formCount.chassisNumber" |
|
|
style="width: 450px" |
|
|
style="width: 450px" |
|
|
type="textarea" |
|
|
type="textarea" |
|
|
placeholder="请输入内容" |
|
|
placeholder="只支持粘贴,不支持手输!" |
|
|
@paste.native="pasteExcelTochassisNumber" |
|
|
@paste.native="pasteExcelTochassisNumber" |
|
|
/> |
|
|
/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
@ -520,7 +512,7 @@ |
|
|
v-model="formCount.materialCode" |
|
|
v-model="formCount.materialCode" |
|
|
style="width: 450px" |
|
|
style="width: 450px" |
|
|
type="textarea" |
|
|
type="textarea" |
|
|
placeholder="请输入内容" |
|
|
placeholder="只支持粘贴,不支持手输!" |
|
|
@paste.native="pasteExcelTomaterialCode" |
|
|
@paste.native="pasteExcelTomaterialCode" |
|
|
/> |
|
|
/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
@ -536,7 +528,7 @@ |
|
|
v-model="formCount.sapCode" |
|
|
v-model="formCount.sapCode" |
|
|
style="width: 450px" |
|
|
style="width: 450px" |
|
|
type="textarea" |
|
|
type="textarea" |
|
|
placeholder="请输入内容" |
|
|
placeholder="只支持粘贴,不支持手输!" |
|
|
@paste.native="pasteExcelTosapCode" |
|
|
@paste.native="pasteExcelTosapCode" |
|
|
/> |
|
|
/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
@ -553,6 +545,36 @@ |
|
|
> |
|
|
> |
|
|
</div> |
|
|
</div> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
|
|
|
<el-dialog |
|
|
|
|
|
title="批量录入KEEN号" |
|
|
|
|
|
:visible.sync="showModal" |
|
|
|
|
|
width="400px" |
|
|
|
|
|
height="500px" |
|
|
|
|
|
append-to-body |
|
|
|
|
|
> |
|
|
|
|
|
<flexbox class="content"> |
|
|
|
|
|
<div> |
|
|
|
|
|
<el-input |
|
|
|
|
|
type="textarea" |
|
|
|
|
|
v-model="paster" |
|
|
|
|
|
@paste.native="pasteMe" |
|
|
|
|
|
:rows="6" |
|
|
|
|
|
/> |
|
|
|
|
|
<el-table :data="tableData" max-height="400"> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
prop="name" |
|
|
|
|
|
label="说明:只支持从Excel上粘贴复制,不支持手输!" |
|
|
|
|
|
width="300" |
|
|
|
|
|
> |
|
|
|
|
|
</el-table-column> |
|
|
|
|
|
</el-table> |
|
|
|
|
|
</div> |
|
|
|
|
|
</flexbox> |
|
|
|
|
|
<div slot="footer" class="dialog-footer"> |
|
|
|
|
|
<el-button type="primary" @click="submiteBillNo">确定录入</el-button> |
|
|
|
|
|
</div> |
|
|
|
|
|
</el-dialog> |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
|
|
|
|
|
@ -562,20 +584,29 @@ import permission from "@/directive/permission/index.js"; |
|
|
import { downloadFile } from "@/utils/crmindex.js"; |
|
|
import { downloadFile } from "@/utils/crmindex.js"; |
|
|
import CRMTableHead from "../../components/CRMTableHead"; |
|
|
import CRMTableHead from "../../components/CRMTableHead"; |
|
|
import moment from "moment"; |
|
|
import moment from "moment"; |
|
|
|
|
|
import PasteExcel from "@/components/PasteExcel/index.vue"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: "InvoiceSettledDetailDiff", |
|
|
name: "InvoiceSettledDetailDiff", |
|
|
components: { Pagination, CRMTableHead }, |
|
|
components: { Pagination, CRMTableHead, PasteExcel }, |
|
|
directives: { permission }, |
|
|
directives: { permission }, |
|
|
|
|
|
|
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
crmType: "backJob", |
|
|
crmType: "backJob", |
|
|
|
|
|
tableData: [ |
|
|
|
|
|
{ |
|
|
|
|
|
name: "KEEN号", |
|
|
|
|
|
}, |
|
|
|
|
|
], |
|
|
|
|
|
paster: "", |
|
|
|
|
|
pasterValue: "", |
|
|
rules: { |
|
|
rules: { |
|
|
versionValue: [ |
|
|
versionValue: [ |
|
|
{ required: true, message: "必须输入!", trigger: "change" }, |
|
|
{ required: true, message: "必须输入!", trigger: "change" }, |
|
|
], |
|
|
], |
|
|
}, |
|
|
}, |
|
|
|
|
|
showModal: false, |
|
|
pickerOptionsCp5: { |
|
|
pickerOptionsCp5: { |
|
|
disabledDate: (time) => { |
|
|
disabledDate: (time) => { |
|
|
let now = new Date(); |
|
|
let now = new Date(); |
|
@ -780,13 +811,36 @@ export default { |
|
|
}, |
|
|
}, |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
valueChange(data) { |
|
|
submiteBillNo() { |
|
|
this.getmaterialGroupValue = ""; |
|
|
var getkeenCodeNo = this.pasterValue.substring( |
|
|
this.getmaterialGroupValue += data + ","; |
|
|
|
|
|
this.getmaterialGroupValue = this.getmaterialGroupValue.substring( |
|
|
|
|
|
0, |
|
|
0, |
|
|
this.getmaterialGroupValue.length - 1 |
|
|
this.pasterValue.length - 1 |
|
|
); |
|
|
); |
|
|
|
|
|
this.dataKenCode = getkeenCodeNo; |
|
|
|
|
|
this.formCount.kennCode=this.dataKenCode; |
|
|
|
|
|
this.showModal=false; |
|
|
|
|
|
}, |
|
|
|
|
|
pasteMe(e) { |
|
|
|
|
|
let source = e.clipboardData.getData("Text"); |
|
|
|
|
|
// 首先对源头进行解析 |
|
|
|
|
|
let rows = source.split("\r\n"); // 拆成很多行 |
|
|
|
|
|
this.pasterValue = ""; |
|
|
|
|
|
for (let i = 0; i < rows.length; i++) { |
|
|
|
|
|
if (rows[i] != "") { |
|
|
|
|
|
// 如果某一行不是空,再按列拆分 |
|
|
|
|
|
let columns = rows[i].split("\t"); // 已经按列划分 |
|
|
|
|
|
let dataone = {}; // 声明一行数组 |
|
|
|
|
|
for (let j = 0; j < columns.length; j++) { |
|
|
|
|
|
// 读取tableData里的第j对应的key值 |
|
|
|
|
|
let keys = Object.keys(this.tableData[j]); // key的名 |
|
|
|
|
|
dataone[keys[j]] = columns[j]; |
|
|
|
|
|
this.pasterValue += columns[j] + ","; |
|
|
|
|
|
} |
|
|
|
|
|
this.tableData.push(dataone); |
|
|
|
|
|
console.log(this.tableData); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
alert(JSON.stringify(this.pasterValue)); |
|
|
}, |
|
|
}, |
|
|
//如果是要获得粘贴excel的内容,需要把粘贴的内容转换成二维数组 |
|
|
//如果是要获得粘贴excel的内容,需要把粘贴的内容转换成二维数组 |
|
|
pasteExcelToKennCode(e) { |
|
|
pasteExcelToKennCode(e) { |
|
@ -806,6 +860,15 @@ export default { |
|
|
} |
|
|
} |
|
|
//alert(this.dataKenCode.trimEnd(",")); |
|
|
//alert(this.dataKenCode.trimEnd(",")); |
|
|
}, |
|
|
}, |
|
|
|
|
|
valueChange(data) { |
|
|
|
|
|
this.getmaterialGroupValue = ""; |
|
|
|
|
|
this.getmaterialGroupValue += data + ","; |
|
|
|
|
|
this.getmaterialGroupValue = this.getmaterialGroupValue.substring( |
|
|
|
|
|
0, |
|
|
|
|
|
this.getmaterialGroupValue.length - 1 |
|
|
|
|
|
); |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
pasteExcelTochassisNumber(e) { |
|
|
pasteExcelTochassisNumber(e) { |
|
|
let source = e.clipboardData.getData("Text"); |
|
|
let source = e.clipboardData.getData("Text"); |
|
|
// 首先对源头进行解析 |
|
|
// 首先对源头进行解析 |
|
@ -959,11 +1022,7 @@ export default { |
|
|
this.listExportQuery.sapCode = getsapCode; //厂内物料号 |
|
|
this.listExportQuery.sapCode = getsapCode; //厂内物料号 |
|
|
} |
|
|
} |
|
|
if (this.formCount.kennCode != "") { |
|
|
if (this.formCount.kennCode != "") { |
|
|
var getgroupValue = this.dataKenCode.substring( |
|
|
this.listExportQuery.kenncode = this.formCount.kennCode; //KEEN号 |
|
|
0, |
|
|
|
|
|
this.dataKenCode.length - 1 |
|
|
|
|
|
); |
|
|
|
|
|
this.listExportQuery.kenncode = getgroupValue; //KEEN号 |
|
|
|
|
|
} |
|
|
} |
|
|
this.listExportQuery.begin = this.cp5startTime |
|
|
this.listExportQuery.begin = this.cp5startTime |
|
|
? this.cp5startTime |
|
|
? this.cp5startTime |
|
@ -994,31 +1053,31 @@ export default { |
|
|
"大众发票与结算核对明细表-导出条件:" + |
|
|
"大众发票与结算核对明细表-导出条件:" + |
|
|
JSON.stringify(this.listExportQuery) |
|
|
JSON.stringify(this.listExportQuery) |
|
|
); |
|
|
); |
|
|
this.formLoading = false; |
|
|
|
|
|
this.dialogFormVisible = false; |
|
|
|
|
|
// this.$axios |
|
|
|
|
|
// .gets( |
|
|
|
|
|
// "/api/settleaccount/ReportMakeService/InvoiceSettledDetailDiff-Make", |
|
|
|
|
|
// this.listExportQuery |
|
|
|
|
|
// ) |
|
|
|
|
|
// .then((res) => { |
|
|
|
|
|
// let taskid = res; |
|
|
|
|
|
// if (Number.isInteger(taskid)) { |
|
|
|
|
|
// this.$notify({ |
|
|
|
|
|
// title: "成功", |
|
|
|
|
|
// message: "任务生成成功!任务号:" + taskid, |
|
|
|
|
|
// type: "success", |
|
|
|
|
|
// duration: 2000, |
|
|
|
|
|
// }); |
|
|
|
|
|
// } |
|
|
|
|
|
// this.getList(); |
|
|
|
|
|
// this.formLoading = false; |
|
|
|
|
|
// this.dialogFormVisible = false; |
|
|
|
|
|
// }) |
|
|
|
|
|
// .catch(() => { |
|
|
|
|
|
// this.formLoading = false; |
|
|
// this.formLoading = false; |
|
|
// this.dialogFormVisible = false; |
|
|
// this.dialogFormVisible = false; |
|
|
// }); |
|
|
this.$axios |
|
|
|
|
|
.gets( |
|
|
|
|
|
"/api/settleaccount/ReportMakeService/InvoiceSettledDetailDiff-Make", |
|
|
|
|
|
this.listExportQuery |
|
|
|
|
|
) |
|
|
|
|
|
.then((res) => { |
|
|
|
|
|
let taskid = res; |
|
|
|
|
|
if (Number.isInteger(taskid)) { |
|
|
|
|
|
this.$notify({ |
|
|
|
|
|
title: "成功", |
|
|
|
|
|
message: "任务生成成功!任务号:" + taskid, |
|
|
|
|
|
type: "success", |
|
|
|
|
|
duration: 2000, |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
this.getList(); |
|
|
|
|
|
this.formLoading = false; |
|
|
|
|
|
this.dialogFormVisible = false; |
|
|
|
|
|
}) |
|
|
|
|
|
.catch(() => { |
|
|
|
|
|
this.formLoading = false; |
|
|
|
|
|
this.dialogFormVisible = false; |
|
|
|
|
|
}); |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|