Browse Source

新开发模块提交

branch_ccpg_220107
44673626 3 years ago
parent
commit
e27d92f44d
  1. 4
      vue/src/components/ImportExcel-base/index.vue
  2. 4
      vue/src/router/modules/vw_menu.js
  3. 10
      vue/src/router/modules/wms_out_order.js
  4. 839
      vue/src/views/ux/billManage/UnSettledSum/index.vue
  5. 73
      vue/src/views/ux/billManage/WMSOutputDetailDiffReport/index.vue
  6. 686
      vue/src/views/ux/billManage/kanbanOutOrder/detail_old.vue
  7. 847
      vue/src/views/ux/billManage/kanbanWithOutOrder/detail_old.vue
  8. 116
      vue/src/views/ux/billManage/sparePart/index.vue
  9. 170
      vue/src/views/ux/billManage/sparepartOutOrder/detail.vue
  10. 2
      vue/src/views/ux/billManage/sparepartOutOrder/index.vue
  11. 162
      vue/src/views/ux/billManage/sparepartOutOrder90/detail.vue
  12. 2
      vue/src/views/ux/billManage/sparepartOutOrder90/index.vue
  13. 122
      vue/src/views/ux/billManage/vwOutOrder/detail.vue
  14. 764
      vue/src/views/ux/vw/dataInput/OnetimeSale/detail_old.vue
  15. 223
      vue/src/views/ux/vw/dataInput/hq_f_outorder/detail.vue
  16. 115
      vue/src/views/ux/vw/dataInput/hq_f_outorder_chickout/detail.vue
  17. 186
      vue/src/views/ux/vw/dataInput/hq_h_checkout/detail.vue
  18. 175
      vue/src/views/ux/vw/dataInput/hq_h_outorder/detail.vue
  19. 76
      vue/src/views/ux/vw/dataInput/hq_unsettle_factory/index.vue
  20. 143
      vue/src/views/ux/vw/dataInput/hq_y_outorder/detail.vue
  21. 18
      vue/static/tableFieldForSearch.json

4
vue/src/components/ImportExcel-base/index.vue

@ -309,8 +309,8 @@ export default {
hqFPlatform: "红旗F平台", //F
hqYPlatform: "一汽轿车", //轿
vwoutorder: "准时化出库单",
sparepartoutorder: "大众备件出库单",
sparepartoutorder90: "大众备件调整出库单",
sparepartoutorder: "大众备件无单号出库单",
sparepartoutorder90: "大众备件有单号出库单",
kanbanoutorder: "大众看板出库单",
HQ_H_OUTORDER: "红旗批量出库单",
HQ_M_OUTORDER: "红旗M平台出库单",

4
vue/src/router/modules/vw_menu.js

@ -202,7 +202,7 @@ const vwMenudataRouter = {
component: () => import('@/views/ux/billManage/sparePart'),
name: 'SparePartReport',//命名路由
meta: {
title: '大众备件手工汇总',
title: '大众备件数据输出',
roles: ['SettleAccount.Reports'],//控制页面角色(可以设置多个角色)
icon: '供货'
}
@ -212,7 +212,7 @@ const vwMenudataRouter = {
component: () => import('@/views/ux/billManage/sparePart90'),
name: 'SparePart90Report',//命名路由
meta: {
title: '大众备件明细输出',
title: '大众备件调整输出',
roles: ['SettleAccount.Reports'],//控制页面角色(可以设置多个角色)
icon: '工厂'
}

10
vue/src/router/modules/wms_out_order.js

@ -69,6 +69,16 @@ const vwsOutOrderDataRouter = {
icon: '零件'
}
},
{
path: '/wms-unSettledSum',
component: () => import('@/views/ux/billManage/UnSettledSum'),
name: 'UnSettledSum',//命名路由
meta: {
title: '结算未结寄售核对表',
roles: ['SettleAccount.WMSJIT'],//控制页面角色(可以设置多个角色)
icon: '零件'
}
},

839
vue/src/views/ux/billManage/UnSettledSum/index.vue

@ -0,0 +1,839 @@
<!--大众备件结算核对-->
<template>
<div class="cr-body-content">
<!--功能栏-->
<div style="float: left">
<flexbox class="content-header">
<JobSelectVerson
:options="JobVersionList"
style="width: 150px; margin-left: -10px"
class="search-container"
@value-change="JobVersionValue"
></JobSelectVerson>
<el-button
class="filter-item"
size="mini"
type="primary"
icon="el-icon-plus"
@click="handleCreate"
>统计
</el-button>
<el-button
class="filter-item"
type="danger"
icon="el-icon-delete"
size="mini"
@click="handleDelete()"
>删除(支持批量)</el-button
>
</flexbox>
</div>
<!-- 刷新 -->
<div style="float: right">
<flexbox class="content-header">
<el-tooltip
class="item"
effect="dark"
content="手动刷新"
placement="top"
>
<el-button
size="mini"
circle
icon="el-icon-refresh"
@click="refresh()"
/>
</el-tooltip>
<span style="margin-left: 10px; color: #ff5640; float: right"
>说明每间隔3分钟进行自动刷新</span
>
</flexbox>
</div>
<!--主页面表格渲染-->
<el-table
ref="multipleTable"
v-loading="listLoading"
element-loading-text="拼命加载中..."
element-loading-spinner="el-icon-loading"
class="cr-table"
:data="list"
:height="tableHeight"
:cell-style="cellStyle"
size="small"
stripe
border
highlight-current-row
style="width: 100%"
@row-click="handleRowClick"
@selection-change="handleSelectionChange"
@filter-change="filterChange"
@cell-dblclick="dblhandleCurrentChange"
>
<el-table-column type="selection" width="44px"></el-table-column>
<el-table-column
v-for="(item, index) in getDefaultField"
:key="index"
:prop="item.prop"
:label="item.label"
:min-width="item.width"
:formatter="fieldFormatter"
sortable
show-overflow-tooltip
:gutter="0"
>
<template slot="header" slot-scope="scope">
{{ scope.column.label }}
</template>
</el-table-column>
<!-- 在线编辑说明字段 -->
<el-table-column label="说明" width="400" align="center">
<template slot-scope="scope">
<el-input
ref="inputRef"
v-if="scope.row.isEditCell"
v-model="scope.row.remark"
class="el-input"
v-focus
@blur="cellBlur(scope.row, scope.column)"
/>
<span v-else>{{ scope.row.remark }}</span>
<el-button
style="margin-left: 5px"
v-if="scope.row.isEditCell"
type="success"
icon="el-icon-check"
size="small"
circle
@click="submitName(scope.row)"
></el-button>
<el-button
v-show="scope.row.isEditCell"
class="cancel-btn"
size="mini"
icon="el-icon-refresh"
type="warning"
@click.native.prevent="handleCancel(scope.row)"
>
cancel
</el-button>
</template>
</el-table-column>
<!-- 状态 -->
<el-table-column
prop="stateName"
label="状态(单击箭头过滤)"
width="165"
column-key="stateName"
align="center"
:filters="[
{ text: '执行完成(任务成功)', value: 'Succeeded' },
{ text: '执行完成(任务失败)', value: 'Failed' },
{ text: '执行中', value: 'Processing' },
{ text: '等待执行', value: 'Scheduled' },
]"
filter-placement="bottom-end"
:filter-method="filterHandler"
>
<template slot-scope="scope">
<el-tag
v-for="(item, index) in stateNameCateMap"
v-show="scope.row.stateName == item.value"
:key="index"
:type="item.cssName"
>
{{ item.label }}
</el-tag>
</template>
</el-table-column>
<!-- 操作 -->
<el-table-column label="操作" align="center" width="250">
<template slot-scope="scope">
<div align="center">
<el-button
v-if="
scope.row.actionName == '导出' &&
scope.row.stateName == 'Succeeded' &&
scope.row.downFileName != ''
"
size="mini"
type="text"
@click="handleDownload(scope.row)"
icon="el-icon-edit"
>下载</el-button
>
<el-button
v-if="
scope.row.actionName == '导出' &&
scope.row.error != '' &&
scope.row.stateName == 'Succeeded'
"
size="mini"
type="text"
@click="handleDownload(scope.row)"
icon="el-icon-edit"
>检验失败下载</el-button
>
</div>
</template>
</el-table-column>
</el-table>
<!-- 分页控件 style="margin-top: -25px;margin-bottom:-25px;float:right;"-->
<div class="table-footer">
<pagination
v-show="totalCount > 0"
:total="totalCount"
:page.sync="page"
:limit.sync="listQuery.MaxResultCount"
@pagination="getList"
/>
</div>
<!--统计功能表单渲染-->
<el-dialog
:visible.sync="dialogFormVisible"
:close-on-click-modal="false"
:title="formTitle"
append-to-body
width="680px"
>
<el-form
ref="formCount"
:inline="true"
:rules="rules"
:model="formCount"
size="mini"
>
<el-row>
<el-col :md="4" :xs="24">
<el-form-item label="选择版本" required />
</el-col>
<el-col :md="20" :xs="24" style="margin-left: -80px">
<el-form-item prop="versionValue">
<el-select
v-model="formCount.versionValue"
size="medium"
clearable
style="width: 188px; margin-right: 15px"
placeholder="请选择"
>
<el-option
v-for="item in versionList"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<!-- <el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
> -->
<el-button @click="resetForm('formCount')">重置</el-button>
<el-button v-loading="formLoading" type="primary" @click="save"
>确认</el-button
>
</div>
</el-dialog>
</div>
</template>
<script>
import Pagination from "@/components/Pagination"; // secondary package based on el-pagination
import permission from "@/directive/permission/index.js";
import { downloadFile } from "@/utils/crmindex.js";
import CRMTableHead from "../../components/CRMTableHead";
import moment from "moment";
import JobSelectVerson from "@/components/CreateCom/Job-Select.vue";
export default {
name: "BomDiffPrice",
components: { Pagination, CRMTableHead, JobSelectVerson },
directives: { permission },
data() {
return {
crmType: "backJob",
rules: {
versionValue: [
{ required: true, message: "必须输入!", trigger: "change" },
],
},
datetime5: [],
JobVersionList: [],
datetime7: [],
checkedCities: [0],
selectValue: "",
selectNameValue: "",
radio: "0", //0 1
versionList: [],
materialGroupList: [],
getmaterialGroupValue: "",
//
openView: false,
versionValue: "",
materialGroupValue: "",
formTitle: "",
timer: null, //
//
activeIndex: 1,
//
activeName: "first",
//
stepList: [
{
title: "等待执行",
icon: "el-icon-sort",
},
{
title: "执行中",
icon: "el-icon-refresh",
},
{
title: "执行完成",
icon: "el-icon-check",
},
],
customerInfos: "",
searchContent: "", //
form: {},
formNoBill: {},
formCount: {
// name: "",
// settledate: "",
// materialCode: "",
// sapMaterialCode: "",
// chassisNumber: "",
// kennCode: "",
version: undefined,
},
list: null,
totalCount: 0,
listLoading: true,
formLoading: false,
formNoBillLoading: false,
//
filterObj: {
type: Object,
default: () => {
return {};
},
},
listExportQuery: {
version: "",
begin: undefined,
end: undefined,
},
listNoBillExportQuery: {
version: "",
},
listQuery: {
taskId: "",
name: "",
},
listBillQuery: {
version: "",
guids: [],
},
page: 1,
dialogFormVisible: false,
dialogFormNoBillVisible: false,
multipleSelection: [],
tableHeight: document.documentElement.clientHeight - 260,
isEdit: false,
menuCateMap: [
{ label: "导出", value: "导出", cssName: "warning" },
{ label: "消息", value: "消息", cssName: "info" },
],
stateNameCateMap: [
{ label: "执行完成(任务成功)", value: "Succeeded", cssName: "success" },
{ label: "执行中...", value: "Processing", cssName: "primary" },
{ label: "执行完成(任务失败)", value: "Failed", cssName: "danger" },
{ label: "等待执行", value: "Scheduled", cssName: "primary" },
],
};
},
mounted() {
var self = this;
window.onresize = function () {
var offsetHei = document.documentElement.clientHeight;
self.tableHeight = offsetHei - 190;
};
this.timer = setInterval(() => {
this.listQuery.taskId = "";
this.listQuery.stateName = "";
setTimeout(this.getList, 0);
}, 1000 * 180); //30
// $oncebeforeDestroy
this.$once("hook:beforeDestroy", () => {
clearInterval(timer);
});
//this.disabledDateCp5();
},
created() {
this.getAllVersionList();
this.getList();
this.getJobVersionInfo();
},
beforeDestroy() {
clearInterval(this.timer);
this.timer = null;
},
computed: {
/* 主表头 */
getDefaultField() {
var tempsTabs = [];
tempsTabs.push({
label: "版本号",
prop: "type",
width: 120,
});
tempsTabs.push({
label: "单据流水号",
prop: "taskId",
width: 140,
});
// tempsTabs.push({
// label: "",
// prop: "name",
// width: 170,
// });
tempsTabs.push({
label: "创建人",
prop: "email",
width: 110,
});
tempsTabs.push({
label: "创建时间",
prop: "createdAt",
width: 150,
});
tempsTabs.push({
label: "审批状态",
prop: "fileName",
width: 350,
});
return tempsTabs;
},
},
methods: {
dblhandleCurrentChange(row, column, cell, event) {
if (column.label === "说明") {
row.isEditCell = true;
this.$set(row, "isEditCell", true);
this.$nextTick(() => {
// elementautofocus
//this.$refs.inputRef.focus();
this.$refs["inputRef"].focus();
});
}
this.list = this.list.filter((item) => {
return item;
});
},
//
cellBlur(row, column) {
row.isEditCell = false;
this.$set(row, "isEditCell", false);
},
// 线
submitName(row) {
let getguid = row.id;
let getremark = row.remark;
this.$axios
.gets("/api/settleaccount/Job/updateRemark", {
p_id: getguid,
remark: getremark,
})
.then((response) => {
if (response == true) {
this.$notify({
title: "成功",
message: "更新成功",
type: "success",
duration: 2000,
});
this.getList();
}
})
.catch(() => {
this.listLoading = false;
});
},
//
handleCancel(row) {
row.isEditCell = false;
//row.stockQty = row.originalstockQty;
this.$set(row, "isEditCell", false);
// this.$message({
// message: "",
// type: "warning",
// });
this.getList();
},
getdateValCp5(val) {
this.cp5endTime = val;
},
handleSelectionChange(val) {
this.multipleSelection = val;
},
//
handleDelete(row) {
this.isEdit = false;
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
} else {
var getbillNum = "";
//
this.multipleSelection.forEach((element) => {
let state = element.fileName;
if (state != "" && state != "已确认") {
this.isEdit = true;
getbillNum += state + ",";
}
});
}
if (this.isEdit == true) {
this.$message({
message:
"已经生成出库单的不能删除!单号:" +
getbillNum.substr(0, getbillNum.length - 1),
type: "warning",
});
return;
} else {
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.$confirm("是否删除" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts("/api/settleaccount/Job/delete", params)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "删除成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
}
},
//
JobVersionValue(params) {
//
this.JobversionValue = params.value;
this.getList();
},
getJobVersionInfo() {
//
//this.listLoading = true;
this.listQuery.SkipCount = (this.page - 1) * 1000;
this.$axios
.posts("/api/settleaccount/Job/versionlist", this.listQuery)
.then((response) => {
let res = response.reverse(); //
this.JobVersionList = [];
res.forEach((element, index) => {
let options = {};
options.value = element;
options.label = element;
this.JobVersionList.push(options);
});
if (JSON.stringify(this.JobVersionList) != "[]") {
//
this.JobversionValue = this.JobVersionList[0].value;
this.JobversionValueVerson = this.JobVersionList[0].label;
this.getList();
}
})
.catch(() => {
//this.listLoading = false;
});
},
handleCheckedCitiesChange(value) {
alert(value);
},
getAllVersionList() {
this.$axios
.posts("/api/settleaccount/CentralizedControl/openlist")
.then((response) => {
this.versionList = [];
response.forEach((element) => {
let options = {};
options.value = element.version;
options.label = element.version;
this.versionList.push(options);
});
})
.catch(() => {
this.listLoading = false;
});
},
/* 重置 */
resetForm(formName) {
this.formCount = {};
this.datetime5 = [];
},
resetNoBillForm(formName) {
this.formNoBill = {};
},
save() {
this.$refs.formCount.validate((valid) => {
if (valid) {
this.formLoading = true;
this.listExportQuery.version = this.formCount.versionValue; //
console.log(
"结算未结寄售核对表-导出条件:" + JSON.stringify(this.listExportQuery)
);
this.$axios
.gets(
"/api/settleaccount/ReportMakeService/UnSettledSum-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;
});
}
});
},
handleCreate() {
if (this.$refs["formCount"] !== undefined) {
this.$refs["formCount"].resetFields();
}
this.formTitle = "报表统计";
this.isEdit = false;
this.formCount = {};
this.datetime5 = [];
this.startTime = "";
this.endTime = "";
this.cp5startTime = "";
this.cp5endTime = "";
this.dialogFormVisible = true;
},
filterHandler(value, row, column) {
const property = column["property"];
return row[property] === value;
},
/* 任务详细信息 */
handleView(row) {
this.listQuery.taskId = row.taskId;
this.$axios
.posts("/api/settleaccount/Job/list", this.listQuery)
.then((response) => {
this.form = response[0];
switch (response[0].stateName) {
case "Succeeded":
case "Failed":
this.activeIndex = 3;
break;
case "Processing":
this.activeIndex = 2;
break;
case "Enqueued":
this.activeIndex = 1;
break;
}
this.openView = true;
});
},
/* 刷新 */
refresh() {
this.list = [];
this.listQuery.taskId = "";
this.listQuery.name = "";
this.getList();
},
//
filterChange(filterObj) {
console.log(filterObj.actionName);
if (filterObj.actionName.length > 0) {
console.log("点击筛选");
} else {
console.log("点击重置");
}
},
/* 导出类型的文件 */
downloadErrData(param) {
this.listLoading = true;
let fileNameOfProject = param;
this.$axios
.BolbGets(
"/api/settleaccount/getblobfile/download/" + fileNameOfProject
)
.then((response) => {
if (fileNameOfProject.indexOf("_") != -1) {
let downName =
fileNameOfProject.slice(0, fileNameOfProject.lastIndexOf("_")) +
fileNameOfProject.slice(fileNameOfProject.lastIndexOf("."));
downloadFile(response, downName);
this.$notify({
title: "成功",
message: "数据-导出中...",
type: "success",
duration: 2000,
});
} else {
downloadFile(response, fileNameOfProject);
this.$notify({
title: "成功",
message: "数据-导出中...",
type: "success",
duration: 2000,
});
}
this.listLoading = false;
})
.catch((error) => {
this.listLoading = false;
});
},
/* 刷新列表 */
handleHandle(data) {
if (data.type !== "edit") {
this.getList();
}
},
/* 格式化字段 */
fieldFormatter(row, column) {
if (column.property === "stateName") {
return {
Succeeded: "执行完成(成功)",
Processing: "执行中...",
Failed: "执行完成(失败)",
Enqueued: "等待执行",
}[row[column.property]];
}
if (column.property == "createdAt") {
var date = row[column.property];
if (date == undefined) {
return "";
}
return moment(date).format("YYYY-MM-DD HH:mm:ss");
}
return row[column.property] || "--";
},
handleDownload(row) {
if (row.stateName == "Succeeded") {
this.downloadErrData(row.downFileName);
} else if (row.stateName == "Failed") {
this.downloadErrData(row.error);
}
},
getList() {
this.listLoading = true;
//
this.listQuery.name = "结算未结寄售核对表";
this.listQuery.type = this.JobversionValue;
this.$axios
.posts("/api/settleaccount/Job/list", this.listQuery)
.then((response) => {
this.list = response;
//
this.list.forEach((element) => {
element["isEditCell"] = false;
});
setTimeout(() => {
//
this.listLoading = false;
}, 500);
})
.catch(() => {
this.listLoading = false;
});
},
resetQuery() {},
/** 通过回调控制style */
cellStyle({ row, column, rowIndex, columnIndex }) {
var item = this.list[rowIndex];
if (column.property === "fileName") {
if (item.fileName === "已确认") {
return { color: "#13CE66", cursor: "pointer", fontWeight: 700 };
} else {
return { color: "#FFBA00", cursor: "pointer", fontWeight: 800 };
}
}
return { textAlign: "left" };
//}
},
headerRowStyle({ row, column, rowIndex, columnIndex }) {
if (column.property === "stateName") {
return { textAlign: "center" };
}
return { textAlign: "center" };
},
handleRowClick(row, column, event) {
this.$refs.multipleTable.clearSelection();
this.$refs.multipleTable.toggleRowSelection(row);
},
},
};
</script>
<style lang="scss" scoped>
@import "../../styles/crmtable.scss";
@import "../../styles/steps.scss";
/deep/ .el-checkbox input:focus {
outline: none !important;
border-color: gray;
border: 0px;
box-shadow: none !important;
}
</style>

73
vue/src/views/ux/billManage/WMSOutputDetailDiffReport/index.vue

@ -83,14 +83,15 @@
@click="handleFilter"
>搜索
</el-button>
<!-- <el-button
<el-button
class="filter-item"
size="mini"
type="warning"
icon="el-icon-upload2"
@click="handleImportSap()"
>同步到SAP
</el-button> -->
v-loading="formLoading1"
@click="handleContinueIssue()"
>继续出库
</el-button>
<!--表格头组件filter查询-->
<c-r-m-table-head
ref="crmTableHead"
@ -207,7 +208,6 @@
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="dialogFormVisible = false"
@ -283,6 +283,7 @@ export default {
totalCount: 0,
listLoading: true,
formLoading: false,
formLoading1: false,
formCount: {
version: undefined,
accountDate: undefined,
@ -529,16 +530,60 @@ export default {
this.form = {};
this.dialogFormVisible = true;
},
//
handleContinueIssue() {
this.formLoading1 = true;
var params = [];
let alert = "";
if (this.multipleSelection.length === 0) {
this.$message({
message: "至少选择一项!",
type: "warning",
});
return;
}
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
alert = "选中项";
handleImportSap() {
// this.$nextTick(() => {
// this.$refs["formCount"].resetFields();
// });
this.dataValue = "";
this.formTitle = "同步";
this.isEdit = false;
this.form = {};
this.dialogAccounDateVisible = true;
this.$confirm("是否确认继续出库" + alert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WMSOutputDetailDiffReport/ModifyTaskState",
params
)
.then((res) => {
if (res == true) {
this.$notify({
title: "成功",
message: "出库成功",
type: "success",
duration: 2000,
});
} else {
this.$message({
type: "warning",
message: "执行失败!",
});
}
this.formLoading1 = false;
this.getList();
});
})
.catch(() => {
this.formLoading1 = false;
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
save() {

686
vue/src/views/ux/billManage/kanbanOutOrder/detail_old.vue

@ -0,0 +1,686 @@
<!--FIS发运数据对比输出表-明细数据-->
<template>
<div class="cr-body-content">
<flexbox class="content-header">
<JobSelectVerson
:options="JobVersionList"
style="width: 150px; margin-left: -10px"
class="search-container"
@value-change="JobVersionValue"
></JobSelectVerson>
<el-button
class="filter-item"
type="success"
icon="el-icon-check"
size="mini"
@click="print()"
>确认出库单</el-button
>
<el-button
class="filter-item"
size="mini"
type="warning"
icon="el-icon-download"
@click="handleCancelBills()"
>取消出库(支持批量)
</el-button>
<el-button
class="filter-item"
size="mini"
type="danger"
icon="el-icon-download"
@click="handleDelete()"
>删除出库单(支持批量)
</el-button>
<el-input
v-model="searchContent"
clearable
size="small"
placeholder="按照零件号搜索..."
style="width: 230px"
class="search-container"
@keyup.enter.native="handleFilter"
/>
<el-button
size="mini"
type="success"
icon="el-icon-search"
@click="handleFilter"
>搜索
</el-button>
<el-button
class="filter-item"
size="mini"
type="info"
icon="el-icon-download"
@click="handleDownload()"
>全部导出
</el-button>
<!--表格头组件filter查询-->
<c-r-m-table-head
ref="crmTableHead"
:crm-type="crmType"
@handle="handleHandle"
@filter="handleFilters"
>
</c-r-m-table-head>
</flexbox>
<!--表格渲染-->
<el-table
ref="multipleTable"
v-loading="listLoading"
element-loading-text="拼命加载中..."
element-loading-spinner="el-icon-loading"
class="cr-table"
:data="list"
:height="tableHeight"
:cell-style="cellStyle"
:header-cell-style="headerRowStyle"
size="small"
stripe
border
highlight-current-row
style="width: 100%"
@sort-change="sortChange"
@selection-change="handleSelectionChange"
@row-click="handleRowClick"
>
<el-table-column type="selection" width="44px"></el-table-column>
<el-table-column
v-for="(item, index) in getDefaultField"
:key="index"
:prop="item.prop"
:label="item.label"
:min-width="item.width"
:formatter="fieldFormatter"
sortable="custom"
show-overflow-tooltip
:gutter="0"
>
<template slot="header" slot-scope="scope">
{{ scope.column.label }}
</template>
</el-table-column>
</el-table>
<div class="table-footer">
<!-- 分页控件 style="margin-top: -25px;margin-bottom:-25px;float:right;"-->
<pagination
v-show="totalCount > 0"
:total="totalCount"
:page.sync="page"
:limit.sync="listQuery.MaxResultCount"
@pagination="getList"
/>
</div>
<div>
<el-dialog
:append-to-body="true"
:visible.sync="dialogFormVisible"
:title="formTitle"
width="700px"
>
<el-form
ref="accountDatelist"
:inline="true"
:model="accountDatelist"
:rules="rules"
size="small"
label-width="120px"
>
<el-form-item label="日期" prop="accountDate">
<el-date-picker
v-model="accountDatelist.accountDate"
type="date"
clearable
placeholder="选择日期"
>
</el-date-picker>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
>确认</el-button
>
</div>
</el-dialog>
</div>
</div>
</template>
<script>
import Pagination from "@/components/Pagination"; // secondary package based on el-pagination
import permission from "@/directive/permission/index.js";
import CRMTableHead from "../../components/CRMTableHead";
import { downloadFile } from "@/utils/crmindex.js";
import JobSelectVerson from "@/components/CreateCom/Job-Select.vue";
export default {
name: "sendUnsettledDiffReport",
components: { Pagination, CRMTableHead, CRMTableHead, JobSelectVerson },
directives: { permission },
props: {
customerInfos: {
type: Array,
default: () => {
return [];
},
},
},
data() {
return {
crmType: "kanbanOutOrder",
rules: {
//
erpMaterialCode: [
{ required: true, message: "必须输入!", trigger: "blur" },
],
accountDate: [
{ required: true, message: "日期必须输入!", trigger: "blur" },
],
},
searchContent: "", //
customerInfo: {
parentId: "",
version: "",
},
form: {
dicDetailID: "",
customerId: "",
projectId: "",
},
list: null,
totalCount: 0,
listLoading: true,
formLoading: false,
JobVersionList: [
{ value: "0", label: "未处理" },
{ value: "1", label: "申请出库" },
{ value: "2", label: "确认出库" },
{ value: "3", label: "不能出库" },
{ value: "4", label: "取消出库" },
],
//
filterObj: {
type: Object,
default: () => {
return {};
},
},
listQuery: {
Filters: [
{
logic: 0,
column: "state",
action: 0,
value: "0",
}, //
],
SkipCount: 0,
MaxResultCount: 15,
billNum: "",
},
listOutPutQuery: {
accountDate: "",
version: "",
guids: "",
billNum: "",
},
listDeleteQuery: {
billNum: "",
},
accountDatelist: {
accountDate: "",
},
page: 1,
JobversionValue: "",
JobversionValueVerson: "",
dialogFormVisible: false,
multipleSelection: [],
formTitle: "",
drawer: false,
showExcelImport: false,
tableHeight: document.documentElement.clientHeight - 230,
isEdit: false,
};
},
mounted() {
var self = this;
window.onresize = function () {
var offsetHei = document.documentElement.clientHeight;
self.tableHeight = offsetHei - 190;
};
},
created() {
this.getList();
},
watch: {
customerInfos: {
handler(newVal) {
if (newVal == "" || newVal == "undefined") {
//TODO
} else {
newVal.forEach((element) => {
this.customerInfo.parentId = element.ParentId;
this.customerInfo.version = element.Version;
});
if (this.customerInfo.parentId != "") {
this.getList();
}
}
},
immediate: true,
},
},
computed: {
/** 列表字段 */
getDefaultField() {
var tempsTabs = [];
tempsTabs.push({
label: "版本",
prop: "version",
width: 110,
});
tempsTabs.push({
label: "零件号",
prop: "materialCode",
width: 150,
});
tempsTabs.push({ label: "零件描述", prop: "materialDesc", width: 250 });
tempsTabs.push({ label: "物料组", prop: "materialGroup", width: 220 });
tempsTabs.push({ label: "交货单号", prop: "wmsBillNum", width: 100 });
tempsTabs.push({ label: "数量", prop: "qty", width: 100 });
tempsTabs.push({ label: "开票单价", prop: "price", width: 100 });
tempsTabs.push({ label: "开票金额", prop: "amt", width: 100 });
tempsTabs.push({ label: "状态", prop: "state", width: 100 });
return tempsTabs;
},
},
methods: {
//
handleDownload(command) {
this.listLoading = true;
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log(
"大众备件出库单导出:" + JSON.stringify(this.listOutPutQuery)
);
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutput/Export",
this.listOutPutQuery
)
.then((res) => {
let fileNameOfProject = res;
this.$axios
.BolbGets(
"/api/settleaccount/getblobfile/download/" + fileNameOfProject
)
.then((response) => {
if (fileNameOfProject.indexOf("_") != -1) {
let downName =
fileNameOfProject.slice(
0,
fileNameOfProject.lastIndexOf("_")
) +
fileNameOfProject.slice(fileNameOfProject.lastIndexOf("."));
downloadFile(response, downName);
this.$notify({
title: "成功",
message: "数据-导出成功!",
type: "success",
duration: 2000,
});
} else {
downloadFile(response, fileNameOfProject);
this.$notify({
title: "成功",
message: "数据-导出成功!",
type: "success",
duration: 2000,
});
}
this.listLoading = false;
});
});
},
//
JobVersionValue(params) {
//
this.listQuery.Filters = [];
var column = "state";
let filter = {
logic: 0,
column: column,
action: 0,
value: params.value,
};
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutput/WmsKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
print() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listLoading = true;
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
this.getList();
return;
//this.getList();
} else {
if (this.accountDatelist != "") {
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
}
//this.listOutPutQuery.accountDate = this.accountDatelist;
console.log(
"未选择时全部确认出库条件:" + JSON.stringify(this.listOutPutQuery)
);
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutput/WmsKanbanOutPut-Pass",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "生成成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.listLoading = false;
})
.catch(() => {
this.listLoading = false;
});
}
},
//
handleDelete(row) {
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listDeleteQuery.billNum = this.listQuery.billNum;
console.log("单据号:" + JSON.stringify(this.listDeleteQuery));
this.$confirm("是否删除" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutput/WmsOutPutDelete",
this.listDeleteQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "删除成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
/** 刷新列表 */
handleHandle(data) {
if (data.type !== "edit") {
this.getList();
}
},
/** 格式化字段 */
fieldFormatter(row, column) {
if (column.property == "state") {
return {
0: "未处理",
1: "申请出库",
2: "确认出库",
3: "不能出库",
4: "取消出库",
}[row[column.property]];
}
return row[column.property] || "--";
},
importExcelData() {
//
this.showExcelImport = false;
this.getList();
},
getList(data) {
this.listLoading = true;
if (data != undefined) {
this.listQuery.SkipCount = (this.page - 1) * data.limit;
} else {
this.listQuery.SkipCount = (this.page - 1) * 15;
}
this.listQuery.billNum = this.customerInfo.parentId;
console.log("查询条件:" + JSON.stringify(this.listQuery));
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutput/WmsKanbanDetailList",
this.listQuery
)
.then((response) => {
this.list = response.items;
//alert(JSON.stringify(response.Items))
this.totalCount = response.totalCount;
setTimeout(() => {
//
this.listLoading = false;
}, 500);
})
.catch(() => {
this.listLoading = false;
});
},
/** 筛选操作 */
handleFilter() {
this.page = 1;
this.getList();
this.listQuery.Filters = [];
if (this.searchContent != "") {
var column = "materialCode";
let filter = {
logic: 0,
column: column,
action: 6,
value: this.searchContent,
};
this.listQuery.Filters.push(filter);
}
this.getList();
},
/** 多项筛选操作 */
/** 筛选操作 */
handleFilters(data) {
if (data === null) {
this.listQuery.Filters = [];
this.getList(); //
} else {
this.filterObj = data;
console.log("筛选" + JSON.stringify(data));
var offsetHei = document.documentElement.clientHeight;
var removeHeight = Object.keys(this.filterObj).length > 0 ? 310 : 240;
this.tableHeight = offsetHei - removeHeight;
this.currentPage = 1;
let Filter = [];
data.forEach((item) => {
let filter = {};
if (item.formType === "datetime" || item.formType === "datetime") {
// (datetime >= a and datetime <=b)
filter["Column"] = item.fieldName;
filter["Logic"] = 0;
filter["Value"] = item.value[0];
filter["Action"] = item.action;
Filter.push(filter);
if (item.value[1] != null) {
filter["Value"] = item.value[1];
filter["Action"] = 5;
Filter.push(filter);
}
} else {
filter["Column"] = item.fieldName;
filter["Value"] = item.value;
filter["Logic"] = 0;
filter["Action"] = item.action;
Filter.push(filter);
}
});
console.log("筛选条件" + JSON.stringify(Filter));
this.listQuery.Filters = Filter;
this.getList();
}
},
resetQuery() {},
sortChange(data) {
const { prop, order } = data;
if (!prop || !order) {
this.handleFilter();
return;
}
this.listQuery.Sorting = prop + " " + order;
this.handleFilter();
},
handleSelectionChange(val) {
this.multipleSelection = val;
},
/** 通过回调控制style */
cellStyle({ row, column, rowIndex, columnIndex }) {
if (
column.property === "fisQty" ||
column.property === "diffQty" ||
column.property === "stockQty"
) {
return { textAlign: "right" };
} else {
return { textAlign: "left" };
}
},
/** 通过回调控制表头style */
headerRowStyle({ row, column, rowIndex, columnIndex }) {
if (
column.property === "fisQty" ||
column.property === "diffQty" ||
column.property === "stockQty"
) {
return { textAlign: "right", background: "#FAFAFA" };
} else {
return { textAlign: "left", background: "#FAFAFA" };
}
},
handleRowClick(row, column, event) {
this.$refs.multipleTable.clearSelection();
this.$refs.multipleTable.toggleRowSelection(row);
},
},
};
</script>
<style lang="scss" scoped>
@import "../../styles/crmtable.scss";
</style>

847
vue/src/views/ux/billManage/kanbanWithOutOrder/detail_old.vue

@ -0,0 +1,847 @@
<!--大众无条码看板-明细数据-->
<template>
<div class="cr-body-content">
<flexbox class="content-header">
<JobSelectVerson
:options="JobVersionList"
style="width: 150px; margin-left: -10px"
class="search-container"
@value-change="JobVersionValue"
></JobSelectVerson>
<!-- <el-select
v-model="PurchaseDateValue"
clearable
style="width: 188px; margin-left: -10px; margin-right: 5px"
placeholder="请选择采购日期"
>
<el-option
v-for="item in PurchaseDateList"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select> -->
<el-button
class="filter-item"
type="success"
icon="el-icon-check"
size="mini"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
class="filter-item"
size="mini"
type="warning"
icon="el-icon-download"
@click="print()"
>取消出库(支持批量)
</el-button>
<el-button
class="filter-item"
size="mini"
type="danger"
icon="el-icon-download"
@click="handleDelete()"
>删除出库单(支持批量)
</el-button>
<el-input
v-model="searchContent"
clearable
size="small"
placeholder="按照物料号搜索..."
style="width: 230px"
class="search-container"
@keyup.enter.native="handleFilter"
/>
<el-button
size="mini"
type="success"
icon="el-icon-search"
@click="handleFilter"
>搜索
</el-button>
<el-button
class="filter-item"
size="mini"
type="info"
icon="el-icon-download"
@click="handleDownload()"
>全部导出
</el-button>
<!--表格头组件filter查询-->
<!-- <c-r-m-table-head
ref="crmTableHead"
:crm-type="crmType"
@handle="handleHandle"
@filter="handleFilters"
>
</c-r-m-table-head> -->
<div v-if="this.resultData && this.resultData.errSize > 0">
<el-card shadow="always">
<!-- <i class="el-icon-error" /> -->
<p>
<span style="color: red"
>{{ this.resultData.successMessage }}
</span>
<el-button type="text" @click="downloadErrData"
>下载错误数据</el-button
>
</p>
</el-card>
</div>
<div v-else-if="this.resultData.errSize === 0">
<p>
<span>{{ this.resultData.successMessage }} </span>
</p>
</div>
</flexbox>
<!--表格渲染-->
<el-table
ref="multipleTable"
v-loading="listLoading"
element-loading-text="拼命加载中..."
element-loading-spinner="el-icon-loading"
class="cr-table"
:data="list"
:height="tableHeight"
:cell-style="cellStyle"
:header-cell-style="headerRowStyle"
size="small"
stripe
border
highlight-current-row
style="width: 100%"
@sort-change="sortChange"
@selection-change="handleSelectionChange"
@row-click="handleRowClick"
>
<el-table-column type="selection" width="44px"></el-table-column>
<el-table-column
v-for="(item, index) in getDefaultField"
:key="index"
:prop="item.prop"
:label="item.label"
:min-width="item.width"
:formatter="fieldFormatter"
sortable="custom"
show-overflow-tooltip
:gutter="0"
>
<template slot="header" slot-scope="scope">
{{ scope.column.label }}
</template>
</el-table-column>
<el-table-column
prop="outputQty"
label="出库数量"
v-model="outPutQtylist.outputQty"
width="100"
>
<template slot-scope="list">
<el-input
size="small"
v-model="list.row.outputQty"
@change="handleEdit(list.$index, list.row)"
></el-input>
</template>
</el-table-column>
<el-table-column label="操作" align="center">
<template slot-scope="list">
<el-button
type="primary"
v-if="(list.$index = 1)"
@click="handle(list.row)"
>确定</el-button
>
</template>
</el-table-column>
</el-table>
<div class="table-footer">
<!-- 分页控件 style="margin-top: -25px;margin-bottom:-25px;float:right;"-->
<pagination
v-show="totalCount > 0"
:total="totalCount"
:page.sync="page"
:limit.sync="listQuery.MaxResultCount"
@pagination="getList"
/>
</div>
<div>
<el-dialog
:append-to-body="true"
:visible.sync="dialogFormVisible"
:title="formTitle"
width="700px"
>
<el-form
ref="accountDatelist"
:inline="true"
:model="accountDatelist"
:rules="rules"
size="small"
label-width="120px"
>
<el-form-item label="日期" prop="accountDate">
<el-date-picker
v-model="accountDatelist.accountDate"
type="date"
clearable
placeholder="选择日期"
>
</el-date-picker>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button v-loading="formLoading" type="primary" @click="save()"
>确认</el-button
>
</div>
</el-dialog>
</div>
</div>
</template>
<script>
import Pagination from "@/components/Pagination"; // secondary package based on el-pagination
import permission from "@/directive/permission/index.js";
import CRMTableHead from "../../components/CRMTableHead";
import { downloadFile } from "@/utils/crmindex.js";
import JobSelectVerson from "@/components/CreateCom/Job-Select.vue";
export default {
name: "sendUnsettledDiffReport",
components: { Pagination, CRMTableHead, CRMTableHead, JobSelectVerson },
directives: { permission },
props: {
customerInfos: {
type: Array,
default: () => {
return [];
},
},
},
data() {
return {
crmType: "sparepartOutOrder",
rules: {
//
erpMaterialCode: [
{ required: true, message: "必须输入!", trigger: "blur" },
],
accountDate: [
{ required: true, message: "日期必须输入!", trigger: "blur" },
],
},
searchContent: "", //
customerInfo: {
parentId: "",
version: "",
},
form: {
dicDetailID: "",
customerId: "",
projectId: "",
},
list: null,
totalCount: 0,
listLoading: true,
formLoading: false,
JobVersionList: [
{ value: "0", label: "未处理" },
{ value: "1", label: "申请出库" },
{ value: "2", label: "确认出库" },
{ value: "3", label: "不能出库" },
{ value: "4", label: "取消出库" },
],
PurchaseDateList: [],
//
filterObj: {
type: Object,
default: () => {
return {};
},
},
resultData: {
totalSize: 0,
errSize: 0,
errTemplate: "",
errMessage: "",
successMessage: "",
},
listQuery: {
Filters: [
{
logic: 0,
column: "state",
action: 0,
value: "0",
}, //
],
SkipCount: 0,
MaxResultCount: 15,
billNum: "",
version: "",
},
listOutPutQuery: {
version: "",
guids: "",
billNum: "",
accountDate: "",
},
listDeleteQuery: {
billNum: "",
},
page: 1,
JobversionValue: "",
PurchaseDateValue: "",
JobversionValueVerson: "",
dialogFormVisible: false,
multipleSelection: [],
outPutQtylist: {
outputQty: "",
taskId: "",
},
formTitle: "",
drawer: false,
showExcelImport: false,
tableHeight: document.documentElement.clientHeight - 230,
isEdit: false,
accountDatelist: {
accountDate: "",
},
};
},
mounted() {
var self = this;
window.onresize = function () {
var offsetHei = document.documentElement.clientHeight;
self.tableHeight = offsetHei - 190;
};
},
created() {
this.getList();
},
watch: {
customerInfos: {
handler(newVal) {
if (newVal == "" || newVal == "undefined") {
//TODO
} else {
newVal.forEach((element) => {
this.customerInfo.parentId = element.ParentId;
this.customerInfo.version = element.Version;
});
if (this.customerInfo.parentId != "") {
this.getList();
}
}
},
immediate: true,
},
},
computed: {
/** 列表字段 */
getDefaultField() {
var tempsTabs = [];
tempsTabs.push({
label: "版本",
prop: "version",
width: 110,
});
tempsTabs.push({ label: "单据号", prop: "billNum", width: 100 });
tempsTabs.push({ label: "物料号", prop: "sapMaterialCode", width: 100 });
tempsTabs.push({
label: "物料描述",
prop: "materialDesc",
width: 250,
});
tempsTabs.push({ label: "结算数量", prop: "qty", width: 100 });
tempsTabs.push({ label: "寄售库存数量", prop: "sockQty", width: 120 });
tempsTabs.push({ label: "实际数量", prop: "realityNumber", width: 100 });
tempsTabs.push({ label: "状态", prop: "state", width: 100 });
return tempsTabs;
},
},
methods: {
/**
* 下载错误模板
*/
downloadErrData() {
let fileNameOfProject = this.resultData.errTemplate;
this.$axios
.BolbGets(
"/api/settleaccount/getblobfile/download/" + fileNameOfProject
)
.then((response) => {
if (fileNameOfProject.indexOf("_") != -1) {
let downName =
fileNameOfProject.slice(0, fileNameOfProject.lastIndexOf("_")) +
fileNameOfProject.slice(fileNameOfProject.lastIndexOf("."));
downloadFile(response, downName);
this.$notify({
title: "成功",
message: "错误数据-导出成功!",
type: "success",
duration: 2000,
});
} else {
downloadFile(response, fileNameOfProject);
this.$notify({
title: "成功",
message: "错误数据-导出成功!",
type: "success",
duration: 2000,
});
}
this.listLoading = false;
})
.catch((error) => {
this.listLoading = false;
});
},
//
handleEdit(index, row) {
console.log(index, row);
},
//
JobVersionValue(params) {
//
this.listQuery.Filters = [];
var column = "state";
let filter = {
logic: 0,
column: column,
action: 0,
value: params.value,
};
this.listQuery.Filters.push(filter);
this.getList();
},
handle(row) {
this.multipleSelection.forEach((element) => {
let outPutQty = element.outPutQty;
});
if (row.outPutQty > row.sockQty) {
this.$message({
message: "出库数量大于寄售库存,不允许出库!",
type: "warning",
});
} else {
if (row.branchId != "") {
this.listOutPutQuery.branchId = row.id;
}
if (row.outPutQty != "") {
this.listOutPutQuery.outputQty = row.outputQty;
}
console.log(
"大众备件调整结算数量按钮:" + JSON.stringify(this.listOutPutQuery)
);
//"taskId": "3fa85f64-5717-4562-b3fc-2c963f66afa6","outPutQty": 0
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutputextend/WmsSharePartOutPutModify",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
})
.catch(() => {
this.listLoading = false;
});
}
},
//
handleCancelBills(row) {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutputextend/WmsKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
print() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.resultData = {};
},
//
save(row) {
this.dialogFormVisible = true;
this.resultData.errSize == 0; //
//this.formLoading = true;
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
this.getList();
return;
//this.getList();
} else {
if (this.accountDatelist != "") {
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
}
//this.listOutPutQuery.accountDate = this.accountDatelist;
console.log(
"无条码看板-全部确认出库条件:" + JSON.stringify(this.listOutPutQuery)
);
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutputextend/WmsKanbanOutPut-Pass",
this.listOutPutQuery
)
.then((res) => {
const index = this.list.indexOf(row);
if (res === "Success") {
this.$notify({
title: "成功",
message: "确认成功!",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.resultData.errSize = 0;
this.dialogFormVisible = false;
this.resultData.successMessage = "出库成功!";
this.getList();
} else {
this.dialogFormVisible = false;
this.resultData.errTemplate = res; //
this.resultData.errSize = 1; //0
this.resultData.successMessage = "有错误检验信息!";
alert(JSON.stringify(this.resultData));
}
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
});
}
},
//
handleDelete(row) {
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listDeleteQuery.billNum = this.listQuery.billNum;
console.log("单据号:" + JSON.stringify(this.listDeleteQuery));
this.$confirm("是否删除" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutputextend/WmsOutPutDelete",
this.listDeleteQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "删除成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
/** 刷新列表 */
handleHandle(data) {
if (data.type !== "edit") {
this.getList();
}
},
/** 格式化字段 */
fieldFormatter(row, column) {
if (column.property == "state") {
return {
0: "未处理",
1: "申请出库",
2: "确认出库",
3: "不能出库",
4: "取消出库",
}[row[column.property]];
}
return row[column.property] || "--";
},
importExcelData() {
//
this.showExcelImport = false;
this.getList();
},
//
handleDownload(command) {
this.listLoading = true;
this.listQuery.version = this.customerInfo.version;
this.listQuery.billNum = this.customerInfo.parentId;
console.log(
"大众无条码看板出库单-导出:" + JSON.stringify(this.listQuery)
);
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutputextend/Export",
this.listQuery
)
.then((res) => {
let fileNameOfProject = res;
this.$axios
.BolbGets(
"/api/settleaccount/getblobfile/download/" + fileNameOfProject
)
.then((response) => {
if (fileNameOfProject.indexOf("_") != -1) {
let downName =
fileNameOfProject.slice(
0,
fileNameOfProject.lastIndexOf("_")
) +
fileNameOfProject.slice(fileNameOfProject.lastIndexOf("."));
downloadFile(response, downName);
this.$notify({
title: "成功",
message: "数据-导出成功!",
type: "success",
duration: 2000,
});
} else {
downloadFile(response, fileNameOfProject);
this.$notify({
title: "成功",
message: "数据-导出成功!",
type: "success",
duration: 2000,
});
}
this.listLoading = false;
});
});
},
getList(data) {
this.listLoading = true;
if (data != undefined) {
this.listQuery.SkipCount = (this.page - 1) * data.limit;
} else {
this.listQuery.SkipCount = (this.page - 1) * 15;
}
this.listQuery.billNum = this.customerInfo.parentId;
console.log("查询条件:" + JSON.stringify(this.listQuery));
this.$axios
.posts(
"/api/settleaccount/wmskanbanoutputextend/WmsKanbanDetailList",
this.listQuery
)
.then((response) => {
this.list = response.items;
//alert(JSON.stringify(response.Items))
this.totalCount = response.totalCount;
setTimeout(() => {
//
this.listLoading = false;
}, 500);
})
.catch(() => {
this.listLoading = false;
});
},
/** 筛选操作 */
handleFilter() {
this.page = 1;
this.getList();
this.listQuery.Filters = [];
if (this.searchContent != "") {
var column = "sapMaterialCode";
let filter = {
logic: 0,
column: column,
action: 6,
value: this.searchContent,
};
this.listQuery.Filters.push(filter);
}
this.getList();
},
/** 多项筛选操作 */
/** 筛选操作 */
handleFilters(data) {
if (data === null) {
this.listQuery.Filters = [];
this.getList(); //
} else {
this.filterObj = data;
console.log("筛选" + JSON.stringify(data));
var offsetHei = document.documentElement.clientHeight;
var removeHeight = Object.keys(this.filterObj).length > 0 ? 310 : 240;
this.tableHeight = offsetHei - removeHeight;
this.currentPage = 1;
let Filter = [];
data.forEach((item) => {
let filter = {};
if (item.formType === "datetime" || item.formType === "datetime") {
// (datetime >= a and datetime <=b)
filter["Column"] = item.fieldName;
filter["Logic"] = 0;
filter["Value"] = item.value[0];
filter["Action"] = item.action;
Filter.push(filter);
if (item.value[1] != null) {
filter["Value"] = item.value[1];
filter["Action"] = 5;
Filter.push(filter);
}
} else {
filter["Column"] = item.fieldName;
filter["Value"] = item.value;
filter["Logic"] = 0;
filter["Action"] = item.action;
Filter.push(filter);
}
});
console.log("筛选条件" + JSON.stringify(Filter));
this.listQuery.Filters = Filter;
this.getList();
}
},
resetQuery() {},
sortChange(data) {
const { prop, order } = data;
if (!prop || !order) {
this.handleFilter();
return;
}
this.listQuery.Sorting = prop + " " + order;
this.handleFilter();
},
handleSelectionChange(val) {
this.multipleSelection = val;
},
/** 通过回调控制style */
cellStyle({ row, column, rowIndex, columnIndex }) {
if (
column.property === "fisQty" ||
column.property === "diffQty" ||
column.property === "sockQty"
) {
return { textAlign: "right" };
} else {
return { textAlign: "left" };
}
},
/** 通过回调控制表头style */
headerRowStyle({ row, column, rowIndex, columnIndex }) {
if (
column.property === "fisQty" ||
column.property === "diffQty" ||
column.property === "sockQty"
) {
return { textAlign: "right", background: "#FAFAFA" };
} else {
return { textAlign: "left", background: "#FAFAFA" };
}
},
handleRowClick(row, column, event) {
this.$refs.multipleTable.clearSelection();
this.$refs.multipleTable.toggleRowSelection(row);
},
},
};
</script>
<style lang="scss" scoped>
@import "../../styles/crmtable.scss";
</style>

116
vue/src/views/ux/billManage/sparePart/index.vue

@ -1202,54 +1202,54 @@ export default {
});
},
//
saveNoBill() {
this.$refs.formNoBill.validate((valid) => {
if (valid) {
this.formNoBillLoading = true;
this.listNoBillExportQuery.version = this.formNoBill.versionValue; //
// if (this.formCount.materialCode != "") {
// this.listExportQuery.materialCode = this.formCount.materialCode; //
// }
if (this.formNoBill.sapCode != "") {
this.listNoBillExportQuery.sapCode = this.formNoBill.sapCode; //
}
this.listNoBillExportQuery.begin = this.startTimeNoBill
? this.startTimeNoBill
: undefined;
this.listNoBillExportQuery.end = this.endTimeNoBill
? this.endTimeNoBill
: undefined;
// saveNoBill() {
// this.$refs.formNoBill.validate((valid) => {
// if (valid) {
// this.formNoBillLoading = true;
// this.listNoBillExportQuery.version = this.formNoBill.versionValue; //
// // if (this.formCount.materialCode != "") {
// // this.listExportQuery.materialCode = this.formCount.materialCode; //
// // }
// if (this.formNoBill.sapCode != "") {
// this.listNoBillExportQuery.sapCode = this.formNoBill.sapCode; //
// }
// this.listNoBillExportQuery.begin = this.startTimeNoBill
// ? this.startTimeNoBill
// : undefined;
// this.listNoBillExportQuery.end = this.endTimeNoBill
// ? this.endTimeNoBill
// : undefined;
console.log(
"大众备件未结明细-导出条件:" +
JSON.stringify(this.listNoBillExportQuery)
);
this.$axios
.gets(
"/api/settleaccount/ReportMakeService/SharePartUnSettledExport",
this.listExportQuery
)
.then((res) => {
let taskid = res;
if (Number.isInteger(taskid)) {
this.$notify({
title: "成功",
message: "任务生成成功!任务号:" + taskid,
type: "success",
duration: 2000,
});
}
this.getList();
this.formNoBillLoading = false;
this.dialogFormNoBillVisible = false;
})
.catch(() => {
this.formNoBillLoading = false;
this.dialogFormNoBillVisible = false;
});
}
});
},
// console.log(
// "-" +
// JSON.stringify(this.listNoBillExportQuery)
// );
// this.$axios
// .gets(
// "/api/settleaccount/ReportMakeService/SharePartUnSettledExport",
// this.listExportQuery
// )
// .then((res) => {
// let taskid = res;
// if (Number.isInteger(taskid)) {
// this.$notify({
// title: "",
// message: ":" + taskid,
// type: "success",
// duration: 2000,
// });
// }
// this.getList();
// this.formNoBillLoading = false;
// this.dialogFormNoBillVisible = false;
// })
// .catch(() => {
// this.formNoBillLoading = false;
// this.dialogFormNoBillVisible = false;
// });
// }
// });
// },
handleCreate() {
// this.$nextTick(() => {
// this.$refs["formCount"].resetFields();
@ -1268,17 +1268,17 @@ export default {
this.dialogFormVisible = true;
},
//
handleCreateNoBill() {
if (this.$refs["formNoBill"] !== undefined) {
this.$refs["formNoBill"].resetFields();
}
this.formTitle = "备件明细报表统计";
this.isEdit = false;
this.formNoBill = {};
this.startTimeNoBill = "";
this.endTimeNoBill = "";
this.dialogFormNoBillVisible = true;
},
// handleCreateNoBill() {
// if (this.$refs["formNoBill"] !== undefined) {
// this.$refs["formNoBill"].resetFields();
// }
// this.formTitle = "";
// this.isEdit = false;
// this.formNoBill = {};
// this.startTimeNoBill = "";
// this.endTimeNoBill = "";
// this.dialogFormNoBillVisible = true;
// },
filterHandler(value, row, column) {
const property = column["property"];
return row[property] === value;

170
vue/src/views/ux/billManage/sparepartOutOrder/detail.vue

@ -30,7 +30,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="print()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -178,7 +178,7 @@
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
@click="save()"
>确认</el-button
>
</div>
@ -259,7 +259,7 @@ export default {
SkipCount: 0,
MaxResultCount: 15,
billNum: "",
version: "",
version: "",
},
listOutPutQuery: {
version: "",
@ -358,14 +358,9 @@ export default {
this.listQuery.version = this.customerInfo.version;
this.listQuery.billNum = this.customerInfo.parentId;
console.log(
"大众备件出库单导出:" + JSON.stringify(this.listQuery)
);
console.log("大众备件出库单导出:" + JSON.stringify(this.listQuery));
this.$axios
.posts(
"/api/settleaccount/wmsSharePartoutput/Export",
this.listQuery
)
.posts("/api/settleaccount/wmsSharePartoutput/Export", this.listQuery)
.then((res) => {
let fileNameOfProject = res;
this.$axios
@ -465,73 +460,25 @@ export default {
});
}
},
//
handleCancelBills(row) {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmsSharePartoutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
print() {
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "创建出库单";
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
//this.formLoading = true;
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
@ -540,7 +487,6 @@ export default {
message: "请选择日期!",
type: "warning",
});
this.getList();
return;
//this.getList();
} else {
@ -549,7 +495,7 @@ export default {
}
//this.listOutPutQuery.accountDate = this.accountDatelist;
console.log(
"未选择时全部确认出库条件:" + JSON.stringify(this.listOutPutQuery)
"全部确认出库条件:" + JSON.stringify(this.listOutPutQuery)
);
this.$axios
@ -575,6 +521,88 @@ export default {
});
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
if (row) {
//
params.push(row.id);
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$axios
.posts(
"/api/settleaccount/wmsSharePartoutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "调用服务出错!",
});
});
},
//
handleDelete(row) {
var params = [];

2
vue/src/views/ux/billManage/sparepartOutOrder/index.vue

@ -1,4 +1,4 @@
<!--大众备件出库单-->
<!--大众备件无单号出库单-->
<template>
<div class="cr-body-content">
<flexbox class="content-header">

162
vue/src/views/ux/billManage/sparepartOutOrder90/detail.vue

@ -29,7 +29,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="print()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -150,10 +150,7 @@
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
<el-button v-loading="formLoading" type="primary" @click="save()"
>确认</el-button
>
</div>
@ -372,73 +369,25 @@ export default {
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmsSharePart90output/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
print() {
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "创建出库单";
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listLoading = true;
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
@ -447,7 +396,6 @@ export default {
message: "请选择日期!",
type: "warning",
});
this.getList();
return;
//this.getList();
} else {
@ -482,6 +430,90 @@ export default {
});
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
if (row) {
//
params.push(row.id);
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$axios
.posts(
"/api/settleaccount/wmsSharePart90output/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "调用服务出错!",
});
});
},
//
handleDelete(row) {
var params = [];

2
vue/src/views/ux/billManage/sparepartOutOrder90/index.vue

@ -1,4 +1,4 @@
<!--大众备件出库单-->
<!--大众备件有单号出库单-->
<template>
<div class="cr-body-content">
<flexbox class="content-header">

122
vue/src/views/ux/billManage/vwOutOrder/detail.vue

@ -13,7 +13,7 @@
type="success"
icon="el-icon-check"
size="mini"
@click="print()"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
@ -21,7 +21,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="handleCancelBills()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -57,13 +57,13 @@
>全部导出
</el-button>
<!--表格头组件filter查询-->
<c-r-m-table-head
<!-- <c-r-m-table-head
ref="crmTableHead"
:crm-type="crmType"
@handle="handleHandle"
@filter="handleFilters"
>
</c-r-m-table-head>
</c-r-m-table-head> -->
</flexbox>
<!--表格渲染-->
<el-table
@ -142,10 +142,7 @@
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
<el-button v-loading="formLoading" type="primary" @click="save()"
>确认</el-button
>
</div>
@ -225,6 +222,7 @@ export default {
SkipCount: 0,
MaxResultCount: 15,
billNum: "",
state:"",
},
listOutPutQuery: {
version: "",
@ -323,8 +321,17 @@ export default {
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
@ -332,58 +339,90 @@ export default {
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmsjitoutput/WmsJitOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
this.$axios
.posts(
"/api/settleaccount/wmsjitoutput/WmsJitOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "已取消操作",
message: "调用服务出错!",
});
});
},
//
handleCreateBills(row) {
//
handleCreateBills() {
this.dialogFormVisible = true;
this.formLoading = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "创建出库单";
},
//
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
@ -392,9 +431,8 @@ export default {
message: "请选择日期!",
type: "warning",
});
this.getList();
return;
//this.getList();
return;
} else {
if (this.accountDatelist != "") {
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
@ -598,7 +636,9 @@ export default {
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log("大众准时化出库单导出:" + JSON.stringify(this.listOutPutQuery));
console.log(
"大众准时化出库单导出:" + JSON.stringify(this.listOutPutQuery)
);
this.$axios
.posts("/api/settleaccount/wmsjitoutput/Export", this.listOutPutQuery)
.then((res) => {

764
vue/src/views/ux/vw/dataInput/OnetimeSale/detail_old.vue

@ -0,0 +1,764 @@
<!---明细数据-->
<template>
<div class="cr-body-content">
<flexbox class="content-header">
<JobSelectVerson
:options="JobVersionList"
style="width: 150px; margin-left: -10px"
class="search-container"
@value-change="JobVersionValue"
></JobSelectVerson>
<el-button
class="filter-item"
type="success"
icon="el-icon-check"
size="mini"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
class="filter-item"
size="mini"
type="warning"
icon="el-icon-download"
@click="print()"
>取消出库(支持批量)
</el-button>
<el-button
class="filter-item"
size="mini"
type="danger"
icon="el-icon-download"
@click="handleDelete()"
>删除出库单(支持批量)
</el-button>
<el-input
v-model="searchContent"
clearable
size="small"
placeholder="按照SAP号搜索..."
style="width: 230px"
class="search-container"
@keyup.enter.native="handleFilter"
/>
<el-button
size="mini"
type="success"
icon="el-icon-search"
@click="handleFilter"
>搜索
</el-button>
<el-button
class="filter-item"
size="mini"
type="info"
icon="el-icon-download"
@click="handleDownload()"
>全部导出
</el-button>
<!--表格头组件filter查询-->
<!-- <c-r-m-table-head
ref="crmTableHead"
:crm-type="crmType"
@handle="handleHandle"
@filter="handleFilters"
>
</c-r-m-table-head> -->
</flexbox>
<!--表格渲染-->
<el-table
ref="multipleTable"
v-loading="listLoading"
element-loading-text="拼命加载中..."
element-loading-spinner="el-icon-loading"
class="cr-table"
:data="list"
:height="tableHeight"
:cell-style="cellStyle"
:header-cell-style="headerRowStyle"
size="small"
stripe
border
highlight-current-row
style="width: 100%"
@sort-change="sortChange"
@selection-change="handleSelectionChange"
@row-click="handleRowClick"
>
<el-table-column type="selection" width="44px"></el-table-column>
<el-table-column
v-for="(item, index) in getDefaultField"
:key="index"
:prop="item.prop"
:label="item.label"
:min-width="item.width"
:formatter="fieldFormatter"
sortable="custom"
show-overflow-tooltip
:gutter="0"
>
<template slot="header" slot-scope="scope">
{{ scope.column.label }}
</template>
</el-table-column>
<el-table-column
prop="outputQty"
label="出库数量"
v-model="outPutQtylist.outputQty"
width="100"
>
<template slot-scope="list">
<el-input
size="small"
v-model="list.row.outputQty"
@change="handleEdit(list.$index, list.row)"
></el-input>
</template>
</el-table-column>
<el-table-column label="操作" align="center">
<template slot-scope="list">
<el-button
type="primary"
v-if="(list.$index = 1)"
@click="handle(list.row)"
>确定</el-button
>
</template>
</el-table-column>
</el-table>
<div class="table-footer">
<!-- 分页控件 style="margin-top: -25px;margin-bottom:-25px;float:right;"-->
<pagination
v-show="totalCount > 0"
:total="totalCount"
:page.sync="page"
:limit.sync="listQuery.MaxResultCount"
@pagination="getList"
/>
</div>
<div>
<el-dialog
:append-to-body="true"
:visible.sync="dialogFormVisible"
:title="formTitle"
width="700px"
>
<el-form
ref="accountDatelist"
:inline="true"
:model="accountDatelist"
:rules="rules"
size="small"
label-width="120px"
>
<el-form-item label="日期" prop="accountDate">
<el-date-picker
v-model="accountDatelist.accountDate"
type="date"
clearable
placeholder="选择日期"
>
</el-date-picker>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
>确认</el-button
>
</div>
</el-dialog>
</div>
</div>
</template>
<script>
import Pagination from "@/components/Pagination"; // secondary package based on el-pagination
import permission from "@/directive/permission/index.js";
import CRMTableHead from "../../../components/CRMTableHead";
import { downloadFile } from "@/utils/crmindex.js";
import JobSelectVerson from "@/components/CreateCom/Job-Select.vue";
export default {
name: "sendUnsettledDiffReport",
components: { Pagination, CRMTableHead, CRMTableHead, JobSelectVerson },
directives: { permission },
props: {
customerInfos: {
type: Array,
default: () => {
return [];
},
},
},
data() {
return {
crmType: "sparepartOutOrder",
rules: {
//
erpMaterialCode: [
{ required: true, message: "必须输入!", trigger: "blur" },
],
accountDate: [
{ required: true, message: "日期必须输入!", trigger: "blur" },
],
},
searchContent: "", //
customerInfo: {
parentId: "",
version: "",
},
form: {
dicDetailID: "",
customerId: "",
projectId: "",
},
list: null,
totalCount: 0,
listLoading: true,
formLoading: false,
JobVersionList: [
{ value: "0", label: "未处理" },
{ value: "1", label: "申请出库" },
{ value: "2", label: "确认出库" },
{ value: "3", label: "不能出库" },
{ value: "4", label: "取消出库" },
],
PurchaseDateList: [],
//
filterObj: {
type: Object,
default: () => {
return {};
},
},
listQuery: {
Filters: [
{
logic: 0,
column: "state",
action: 0,
value: "0",
}, //
],
SkipCount: 0,
MaxResultCount: 15,
billNum: "",
version: "",
},
listOutPutQuery: {
version: "",
guids: "",
billNum: "",
accountDate: "",
},
listDeleteQuery: {
billNum: "",
},
page: 1,
JobversionValue: "",
PurchaseDateValue: "",
JobversionValueVerson: "",
dialogFormVisible: false,
multipleSelection: [],
outPutQtylist: {
outputQty: "",
taskId: "",
},
formTitle: "",
drawer: false,
showExcelImport: false,
tableHeight: document.documentElement.clientHeight - 230,
isEdit: false,
accountDatelist: {
accountDate: "",
},
};
},
mounted() {
var self = this;
window.onresize = function () {
var offsetHei = document.documentElement.clientHeight;
self.tableHeight = offsetHei - 190;
};
},
created() {
this.getList();
},
watch: {
customerInfos: {
handler(newVal) {
if (newVal == "" || newVal == "undefined") {
//TODO
} else {
newVal.forEach((element) => {
this.customerInfo.parentId = element.ParentId;
this.customerInfo.version = element.Version;
});
if (this.customerInfo.parentId != "") {
this.getList();
}
}
},
immediate: true,
},
},
computed: {
/** 列表字段 */
getDefaultField() {
var tempsTabs = [];
tempsTabs.push({
label: "版本",
prop: "version",
width: 110,
});
tempsTabs.push({ label: "SAP编码", prop: "sapMaterialCode", width: 150 });
// tempsTabs.push({
// label: "",
// prop: "materialGroup",
// width: 220,
// });
tempsTabs.push({
label: "物料组描述",
prop: "materialDesc",
width: 220,
});
tempsTabs.push({ label: "寄售库存", prop: "sockQty", width: 100 });
tempsTabs.push({ label: "结算数量", prop: "qty", width: 100 });
tempsTabs.push({ label: "状态", prop: "state", width: 100 });
return tempsTabs;
},
},
methods: {
//
handleDownload(command) {
this.listLoading = true;
this.listQuery.version = this.customerInfo.version;
this.listQuery.billNum = this.customerInfo.parentId;
console.log(
"一次性寄售销售出库单导出:" + JSON.stringify(this.listQuery)
);
this.$axios
.posts("/api/settleaccount/WmsOneTimeSaleOutput/Export", this.listQuery)
.then((res) => {
let fileNameOfProject = res;
this.$axios
.BolbGets(
"/api/settleaccount/getblobfile/download/" + fileNameOfProject
)
.then((response) => {
if (fileNameOfProject.indexOf("_") != -1) {
let downName =
fileNameOfProject.slice(
0,
fileNameOfProject.lastIndexOf("_")
) +
fileNameOfProject.slice(fileNameOfProject.lastIndexOf("."));
downloadFile(response, downName);
this.$notify({
title: "成功",
message: "数据-导出成功!",
type: "success",
duration: 2000,
});
} else {
downloadFile(response, fileNameOfProject);
this.$notify({
title: "成功",
message: "数据-导出成功!",
type: "success",
duration: 2000,
});
}
this.listLoading = false;
});
});
},
//
handleEdit(index, row) {
console.log(index, row);
},
//
JobVersionValue(params) {
//
this.listQuery.Filters = [];
var column = "state";
let filter = {
logic: 0,
column: column,
action: 0,
value: params.value,
};
this.listQuery.Filters.push(filter);
this.getList();
},
handle(row) {
this.multipleSelection.forEach((element) => {
let outPutQty = element.outputQty;
});
if (row.sapMaterialCode === null) {
this.$message({
message: "SAP编码为空,不允许出库!",
type: "warning",
});
return;
}
if (row.outputQty > row.stockQty) {
this.$message({
message: "出库数量大于寄售库存,不允许出库!",
type: "warning",
});
} else {
if (row.branchId != "") {
this.listOutPutQuery.branchId = row.id;
}
if (row.outputQty != "") {
this.listOutPutQuery.outputQty = row.outputQty;
}
console.log(
"一汽轿车-数量按钮:" + JSON.stringify(this.listOutPutQuery)
);
this.$axios
.posts(
"/api/settleaccount/WmsOneTimeSaleOutput/WmsSharePartOutPutModify",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
})
.catch(() => {
this.listLoading = false;
});
}
},
//
handleCancelBills(row) {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WmsOneTimeSaleOutput/WmsKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
print() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
this.getList();
return;
//this.getList();
} else {
if (this.accountDatelist != "") {
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
}
//this.listOutPutQuery.accountDate = this.accountDatelist;
console.log(
"红旗数据调整-全部确认出库条件:" +
JSON.stringify(this.listOutPutQuery)
);
this.$axios
.posts(
"/api/settleaccount/WmsOneTimeSaleOutput/WmsKanbanOutPut-Pass",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "生成成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
});
}
},
//
handleDelete(row) {
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listDeleteQuery.billNum = this.listQuery.billNum;
console.log("单据号:" + JSON.stringify(this.listDeleteQuery));
this.$confirm("是否删除" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WmsOneTimeSaleOutput/WmsOutPutDelete",
this.listDeleteQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "删除成功",
type: "success",
duration: 2000,
});
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
/** 刷新列表 */
handleHandle(data) {
if (data.type !== "edit") {
this.getList();
}
},
/** 格式化字段 */
fieldFormatter(row, column) {
if (column.property == "state") {
return {
0: "未处理",
1: "申请出库",
2: "确认出库",
3: "不能出库",
4: "取消出库",
}[row[column.property]];
}
return row[column.property] || "--";
},
importExcelData() {
//
this.showExcelImport = false;
this.getList();
},
getList(data) {
this.listLoading = true;
if (data != undefined) {
this.listQuery.SkipCount = (this.page - 1) * data.limit;
} else {
this.listQuery.SkipCount = (this.page - 1) * 15;
}
this.listQuery.billNum = this.customerInfo.parentId;
console.log("查询条件:" + JSON.stringify(this.listQuery));
this.$axios
.posts(
"/api/settleaccount/WmsOneTimeSaleOutput/WmsKanbanDetailList",
this.listQuery
)
.then((response) => {
this.list = response.items;
//alert(JSON.stringify(response.Items))
this.totalCount = response.totalCount;
setTimeout(() => {
//
this.listLoading = false;
}, 500);
})
.catch(() => {
this.listLoading = false;
});
},
/** 筛选操作 */
handleFilter() {
this.page = 1;
this.getList();
this.listQuery.Filters = [];
if (this.searchContent != "") {
var column = "materialCode";
let filter = {
logic: 0,
column: column,
action: 6,
value: this.searchContent,
};
this.listQuery.Filters.push(filter);
}
this.getList();
},
/** 多项筛选操作 */
/** 筛选操作 */
handleFilters(data) {
if (data === null) {
this.listQuery.Filters = [];
this.getList(); //
} else {
this.filterObj = data;
console.log("筛选" + JSON.stringify(data));
var offsetHei = document.documentElement.clientHeight;
var removeHeight = Object.keys(this.filterObj).length > 0 ? 310 : 240;
this.tableHeight = offsetHei - removeHeight;
this.currentPage = 1;
let Filter = [];
data.forEach((item) => {
let filter = {};
if (item.formType === "datetime" || item.formType === "datetime") {
// (datetime >= a and datetime <=b)
filter["Column"] = item.fieldName;
filter["Logic"] = 0;
filter["Value"] = item.value[0];
filter["Action"] = item.action;
Filter.push(filter);
if (item.value[1] != null) {
filter["Value"] = item.value[1];
filter["Action"] = 5;
Filter.push(filter);
}
} else {
filter["Column"] = item.fieldName;
filter["Value"] = item.value;
filter["Logic"] = 0;
filter["Action"] = item.action;
Filter.push(filter);
}
});
console.log("筛选条件" + JSON.stringify(Filter));
this.listQuery.Filters = Filter;
this.getList();
}
},
resetQuery() {},
sortChange(data) {
const { prop, order } = data;
if (!prop || !order) {
this.handleFilter();
return;
}
this.listQuery.Sorting = prop + " " + order;
this.handleFilter();
},
handleSelectionChange(val) {
this.multipleSelection = val;
},
/** 通过回调控制style */
cellStyle({ row, column, rowIndex, columnIndex }) {
if (column.property === "qty" || column.property === "stockQty") {
return { textAlign: "right" };
} else {
return { textAlign: "left" };
}
},
/** 通过回调控制表头style */
headerRowStyle({ row, column, rowIndex, columnIndex }) {
if (
column.property === "fisQty" ||
column.property === "diffQty" ||
column.property === "stockQty"
) {
return { textAlign: "right", background: "#FAFAFA" };
} else {
return { textAlign: "left", background: "#FAFAFA" };
}
},
handleRowClick(row, column, event) {
this.$refs.multipleTable.clearSelection();
this.$refs.multipleTable.toggleRowSelection(row);
},
},
};
</script>
<style lang="scss" scoped>
@import "../../../styles/crmtable.scss";
</style>

223
vue/src/views/ux/vw/dataInput/hq_f_outorder/detail.vue

@ -2,7 +2,6 @@
<template>
<div class="cr-body-content">
<flexbox class="content-header">
<JobSelectVerson
:options="JobVersionList"
style="width: 150px; margin-left: -10px"
@ -14,7 +13,7 @@
type="success"
icon="el-icon-check"
size="mini"
@click="print()"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
@ -22,7 +21,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="handleCancelBills()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -49,7 +48,7 @@
@click="handleFilter"
>搜索
</el-button>
<el-button
<el-button
class="filter-item"
size="mini"
type="info"
@ -120,7 +119,7 @@
:title="formTitle"
width="700px"
>
<el-form
<el-form
ref="accountDatelist"
:inline="true"
:model="accountDatelist"
@ -143,12 +142,7 @@
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
<el-button v-loading="formLoading" type="primary" @click="save()"
>确认</el-button
>
</div>
@ -184,7 +178,7 @@ export default {
erpMaterialCode: [
{ required: true, message: "必须输入!", trigger: "blur" },
],
accountDate: [
accountDate: [
{ required: true, message: "日期必须输入!", trigger: "blur" },
],
},
@ -233,9 +227,9 @@ export default {
version: "",
guids: "",
billNum: "",
accountDate:""
accountDate: "",
},
listDeleteQuery: {
listDeleteQuery: {
billNum: "",
},
page: 1,
@ -244,14 +238,14 @@ export default {
dialogFormVisible: false,
multipleSelection: [],
formTitle: "",
stockQty: "",
stockQty: "",
drawer: false,
showExcelImport: false,
tableHeight: document.documentElement.clientHeight - 230,
isEdit: false,
accountDatelist:{
accountDate:""
}
accountDatelist: {
accountDate: "",
},
};
},
mounted() {
@ -313,7 +307,7 @@ export default {
},
},
methods: {
//
//
handleDownload(command) {
this.listLoading = true;
this.listOutPutQuery.version = this.customerInfo.version;
@ -375,8 +369,17 @@ export default {
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
@ -384,68 +387,93 @@ export default {
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WMSHQFKanbanoutput/WmsHQFKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
this.$axios
.posts(
"/api/settleaccount/WMSHQFKanbanoutput/WmsHQFKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "已取消操作",
message: "调用服务出错!",
});
});
},
print() {
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "创建出库单";
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listLoading = true;
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
if (this.accountDatelist.accountDate == "") {
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
@ -455,12 +483,10 @@ export default {
//this.getList();
} else {
if (this.accountDatelist != "") {
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
}
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
}
//this.listOutPutQuery.accountDate = this.accountDatelist;
console.log(
"未选择时全部确认出库条件:" + JSON.stringify(this.listOutPutQuery)
);
console.log("确认出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$axios
.posts(
@ -487,48 +513,51 @@ export default {
}
},
//
handleDelete(row){
handleDelete(row) {
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listDeleteQuery.billNum = this.listQuery.billNum ;
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listDeleteQuery.billNum = this.listQuery.billNum;
console.log("单据号:" + JSON.stringify(this.listDeleteQuery));
this.$confirm("是否删除" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts("/api/settleaccount/WMSHQFKanbanoutput/WmsOutPutDelete", this.listDeleteQuery)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "删除成功",
type: "success",
duration: 2000,
});
this.getList();
this.$confirm("是否删除" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WMSHQFKanbanoutput/WmsOutPutDelete",
this.listDeleteQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "删除成功",
type: "success",
duration: 2000,
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
this.getList();
});
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
/** 刷新列表 */
handleHandle(data) {

115
vue/src/views/ux/vw/dataInput/hq_f_outorder_chickout/detail.vue

@ -13,7 +13,7 @@
type="success"
icon="el-icon-check"
size="mini"
@click="print()"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
@ -21,7 +21,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="handleCancelBills()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -174,10 +174,7 @@
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
<el-button v-loading="formLoading" type="primary" @click="save()"
>确认</el-button
>
</div>
@ -453,8 +450,17 @@ export default {
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
@ -462,68 +468,95 @@ export default {
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/wmsHQFSharePartoutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
this.$axios
.posts(
"/api/settleaccount/wmsHQFSharePartoutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "已取消操作",
message: "调用服务出错!",
});
});
},
print() {
handleCreateBillsEnd(row) {
this.dialogFormVisible = false;
this.getList();
},
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "创建出库单";
},
handleCreateBillsEnd(row) {
this.dialogFormVisible = false;
this.getList();
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listLoading = true;
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;

186
vue/src/views/ux/vw/dataInput/hq_h_checkout/detail.vue

@ -2,7 +2,6 @@
<template>
<div class="cr-body-content">
<flexbox class="content-header">
<JobSelectVerson
:options="JobVersionList"
style="width: 150px; margin-left: -10px"
@ -14,7 +13,7 @@
type="success"
icon="el-icon-check"
size="mini"
@click="print()"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
@ -22,7 +21,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="handleCancelBills()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -49,7 +48,7 @@
@click="handleFilter"
>搜索
</el-button>
<el-button
<el-button
class="filter-item"
size="mini"
type="info"
@ -176,10 +175,7 @@
<el-button type="text" @click="dialogFormVisible = false"
>取消</el-button
>
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
<el-button v-loading="formLoading" type="primary" @click="save()"
>确认</el-button
>
</div>
@ -475,8 +471,17 @@ export default {
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
@ -484,77 +489,159 @@ export default {
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
let date = new Date();
let min = date.getMinutes();
date.setMinutes(min + 1); //1
let nowDate = moment(date).format("HH:mm:ss");
this.listOutPutQuery.accountDate = date;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WmsHQHSharePartoutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
this.$axios
.posts(
"/api/settleaccount/WmsHQHSharePartoutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "已取消操作",
message: "调用服务出错!",
});
});
},
print() {
//
// handleCancelBills(row) {
// if (this.multipleSelection.length == 0) {
// this.$message({
// message: "",
// type: "warning",
// });
// return;
// }
// var params = [];
// let myalert = ""; //使
// if (row) {
// //
// params.push(row.id);
// myalert = row.name;
// } else {
// //
// this.multipleSelection.forEach((element) => {
// let id = element.id;
// params.push(id);
// });
// myalert = "";
// }
// this.listOutPutQuery.version = this.customerInfo.version;
// this.listOutPutQuery.guids = params;
// this.listOutPutQuery.billNum = this.customerInfo.parentId;
// let date = new Date();
// let min = date.getMinutes();
// date.setMinutes(min + 1); //1
// let nowDate = moment(date).format("HH:mm:ss");
// this.listOutPutQuery.accountDate = date;
// console.log("" + JSON.stringify(this.listOutPutQuery));
// this.$confirm("" + myalert + "?", "", {
// confirmButtonText: "",
// cancelButtonText: "",
// type: "warning",
// })
// .then(() => {
// this.$axios
// .posts(
// "/api/settleaccount/WmsHQHSharePartoutput/WmsSharePartOutPut-Cancel",
// this.listOutPutQuery
// )
// .then((response) => {
// const index = this.list.indexOf(row);
// this.$notify({
// title: "",
// message: "",
// type: "success",
// duration: 2000,
// });
// this.getList();
// });
// })
// .catch(() => {
// this.$message({
// type: "info",
// message: "",
// });
// });
// },
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
//this.getList();
this.formTitle = "创建出库单";
},
handleCreateBillsEnd(row) {
this.dialogFormVisible = false;
this.getList();
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listLoading = true;
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
@ -572,9 +659,7 @@ export default {
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
}
//this.listOutPutQuery.accountDate = this.accountDatelist;
console.log(
"未选择时全部确认出库条件:" + JSON.stringify(this.listOutPutQuery)
);
console.log("确认出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$axios
.posts(
@ -599,6 +684,7 @@ export default {
});
}
},
//
handleDelete(row) {
var params = [];

175
vue/src/views/ux/vw/dataInput/hq_h_outorder/detail.vue

@ -13,7 +13,7 @@
type="success"
icon="el-icon-check"
size="mini"
@click="print()"
@click="handleCreateBills()"
>确认出库单</el-button
>
<el-button
@ -21,7 +21,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="handleCancelBills()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -145,7 +145,7 @@
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
@click="save()"
>确认</el-button
>
</div>
@ -376,8 +376,17 @@ export default {
this.listQuery.Filters.push(filter);
this.getList();
},
//
handleCancelBills(row) {
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
@ -385,84 +394,150 @@ export default {
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
type: "info",
message: "已取消操作",
});
});
},
//
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WmsHQHKanbanoutput/WmsHQHKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
this.$axios
.posts(
"/api/settleaccount/WmsHQHKanbanoutput/WmsHQHKanbanOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "已取消操作",
message: "调用服务出错!",
});
});
},
print() {
//
// handleCancelBills(row) {
// if (this.multipleSelection.length == 0) {
// this.$message({
// message: "",
// type: "warning",
// });
// return;
// }
// var params = [];
// let myalert = ""; //使
// if (row) {
// //
// params.push(row.id);
// myalert = row.name;
// } else {
// //
// this.multipleSelection.forEach((element) => {
// let id = element.id;
// params.push(id);
// });
// myalert = "";
// }
// this.listOutPutQuery.version = this.customerInfo.version;
// this.listOutPutQuery.guids = params;
// this.listOutPutQuery.billNum = this.customerInfo.parentId;
// console.log("" + JSON.stringify(this.listOutPutQuery));
// this.$confirm("" + myalert + "?", "", {
// confirmButtonText: "",
// cancelButtonText: "",
// type: "warning",
// })
// .then(() => {
// this.$axios
// .posts(
// "/api/settleaccount/WmsHQHKanbanoutput/WmsHQHKanbanOutPut-Cancel",
// this.listOutPutQuery
// )
// .then((response) => {
// const index = this.list.indexOf(row);
// this.$notify({
// title: "",
// message: "",
// type: "success",
// duration: 2000,
// });
// this.getList();
// });
// })
// .catch(() => {
// this.$message({
// type: "info",
// message: "",
// });
// });
// },
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
// this.$axios
// .posts(
// "/api/settleaccount/WmsHQHKanbanoutput/WmsHQHKanbanOutPut-Pass",
// this.listOutPutQuery
// )
// .then((response) => {
// const index = this.list.indexOf(row);
// this.$notify({
// title: "",
// message: "",
// type: "success",
// duration: 2000,
// });
// this.getList();
// this.listLoading = false;
// })
this.formTitle = "创建出库单";
},
handleCreateBillsEnd(row) {
this.dialogFormVisible = false;
this.getList();
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
this.listLoading = true;
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;

76
vue/src/views/ux/vw/dataInput/hq_unsettle_factory/index.vue

@ -217,6 +217,34 @@
size="mini"
>
<el-row>
<el-col :md="4" :xs="24">
<el-form-item label="当期版本" required />
</el-col>
<el-col :md="16" :xs="24" style="margin-left: -80px">
<el-form-item prop="versionValue">
<el-select
v-model="formCount.versionValue"
size="medium"
clearable
style="width: 188px; margin-right: 15px"
placeholder="请选择"
>
<el-option
v-for="item in versionList"
:key="item.value"
:label="item.label"
:value="item.value"
></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :md="4" :xs="24">
<el-checkbox style="margin-left: -120px" v-model="checked"
>是否过滤掉当期结算数据</el-checkbox
>
</el-col>
</el-row>
<!-- <el-row>
<el-col :md="4" :xs="24">
<el-form-item label="选择版本" required />
</el-col>
@ -238,10 +266,11 @@
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-row> -->
<el-row>
<el-col :md="4" :xs="24">
<el-form-item label="交货日期" />
<el-form-item label="交货日期" />
</el-col>
<el-col :md="10" :xs="24" style="margin-left: -80px">
<el-form-item prop="startTime">
@ -249,7 +278,6 @@
v-model="formCount.startTime"
type="datetime"
size="small"
@change="getdateValue"
value-format="yyyy-MM-dd HH:mm:ss"
default-time="00:00:00"
@ -262,7 +290,6 @@
<el-date-picker
v-model="formCount.endTime"
type="datetime"
size="small"
@change="getdateVal"
value-format="yyyy-MM-dd HH:mm:ss"
@ -282,39 +309,6 @@
></i>
</template>
<!-- <el-row>
<el-col :md="4" :xs="24">
<el-form-item label="物料组(车型)" />
</el-col>
<el-col :md="20" :xs="24" style="margin-left: -80px">
<el-form-item prop="materialGroupValue">
<el-select
v-model="formCount.materialGroupValue"
size="medium"
multiple
filterable
clearable
style="width: 380px; margin-right: 15px"
@change="valueChange"
placeholder="请选择"
>
<el-option
v-for="item in materialGroupList"
:key="item.value"
:label="item.value"
:value="item.value"
>
<span style="float: left">{{ item.label }}</span>
<span
style="float: right; color: #8492a6; font-size: 13px"
>{{ item.value }}</span
>
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row> -->
<el-row>
<el-col :md="4" :xs="24">
<el-form-item label="客户物料号" />
@ -396,6 +390,7 @@ export default {
],
},
showModal: false,
checked: true,
pickerOptionsCp5: {
disabledDate: (time) => {
let now = new Date();
@ -492,6 +487,7 @@ export default {
warehouseDesc: undefined,
acceptNo: undefined,
kanban: undefined,
isContainVersion: undefined,
},
dataKenCode: "",
datachassisNumber: "",
@ -954,6 +950,12 @@ export default {
this.listExportQuery.sapCode = this.formCount.sapCode; //3
}
if (this.checked == true) {
this.listExportQuery.isContainVersion = "0";
} else {
this.listExportQuery.isContainVersion = "1";
}
this.listExportQuery.begin = this.startTime
? this.startTime
: undefined;

143
vue/src/views/ux/vw/dataInput/hq_y_outorder/detail.vue

@ -22,7 +22,7 @@
size="mini"
type="warning"
icon="el-icon-download"
@click="print()"
@click="HandleOutPutCancel()"
>取消出库(支持批量)
</el-button>
<el-button
@ -171,7 +171,7 @@
<el-button
v-loading="formLoading"
type="primary"
@click="handleCreateBills()"
@click="save()"
>确认</el-button
>
</div>
@ -447,55 +447,144 @@ export default {
});
}
},
save(row) {
if (this.formTitle == "撤销出库") {
this.CancelBills(row);
} else if (this.formTitle == "创建出库单") {
this.saveBills(row);
}
},
//
handleCancelBills(row) {
if (this.multipleSelection.length == 0) {
CancelBills(row) {
if (this.accountDatelist.accountDate == "") {
this.$message({
message: "至少选择一行!",
message: "请选择日期!",
type: "warning",
});
return;
}
var params = [];
let myalert = ""; //使
if (row) {
//
params.push(row.id);
myalert = row.name;
} else {
//
this.multipleSelection.forEach((element) => {
let id = element.id;
params.push(id);
});
myalert = "选中项";
}
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.guids = params;
this.listOutPutQuery.billNum = this.customerInfo.parentId;
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate;
console.log("取消出库条件:" + JSON.stringify(this.listOutPutQuery));
this.$axios
.posts(
"/api/settleaccount/WmsHQCaroutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.accountDatelist.accountDate = "";
this.dialogFormVisible = false;
this.getList();
this.formLoading = false;
})
.catch(() => {
this.formLoading = false;
this.$message({
type: "info",
message: "调用服务出错!",
});
});
},
//
// handleCancelBills(row) {
// if (this.multipleSelection.length == 0) {
// this.$message({
// message: "",
// type: "warning",
// });
// return;
// }
// var params = [];
// let myalert = ""; //使
// if (row) {
// //
// params.push(row.id);
// myalert = row.name;
// } else {
// //
// this.multipleSelection.forEach((element) => {
// let id = element.id;
// params.push(id);
// });
// myalert = "";
// }
// this.listOutPutQuery.version = this.customerInfo.version;
// this.listOutPutQuery.guids = params;
// this.listOutPutQuery.billNum = this.customerInfo.parentId;
// console.log("" + JSON.stringify(this.listOutPutQuery));
// this.$confirm("" + myalert + "?", "", {
// confirmButtonText: "",
// cancelButtonText: "",
// type: "warning",
// })
// .then(() => {
// this.$axios
// .posts(
// "/api/settleaccount/WmsHQCaroutput/WmsSharePartOutPut-Cancel",
// this.listOutPutQuery
// )
// .then((response) => {
// const index = this.list.indexOf(row);
// this.$notify({
// title: "",
// message: "",
// type: "success",
// duration: 2000,
// });
// this.getList();
// });
// })
// .catch(() => {
// this.$message({
// type: "info",
// message: "",
// });
// });
// },
//
HandleOutPutCancel() {
if (this.multipleSelection.length == 0) {
this.$message({
message: "至少选择一行!",
type: "warning",
});
return;
}
let myalert = "选中项"; //使
this.$confirm("是否确认取消出库" + myalert + "?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$axios
.posts(
"/api/settleaccount/WmsHQCaroutput/WmsSharePartOutPut-Cancel",
this.listOutPutQuery
)
.then((response) => {
const index = this.list.indexOf(row);
this.$notify({
title: "成功",
message: "操作成功",
type: "success",
duration: 2000,
});
this.getList();
});
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "撤销出库";
})
.catch(() => {
this.$message({
@ -504,15 +593,17 @@ export default {
});
});
},
print() {
//
handleCreateBills() {
this.dialogFormVisible = true;
if (this.$refs["accountDatelist"] !== undefined) {
this.$refs["accountDatelist"].resetFields();
}
this.formTitle = "创建出库单";
},
//
handleCreateBills(row) {
this.dialogFormVisible = true;
saveBills(row) {
this.listOutPutQuery.guids = [];
this.listOutPutQuery.version = this.customerInfo.version;
this.listOutPutQuery.billNum = this.customerInfo.parentId;

18
vue/static/tableFieldForSearch.json

@ -3156,24 +3156,6 @@
"fieldType": 1,
"fieldName": "materialGroup",
"setting": []
},
{
"fieldId": 2,
"formType": "select",
"isNull": 0,
"name": "状态",
"options": "",
"type": 3,
"value": "",
"fieldType": 0,
"fieldName": "state",
"setting": [
"未处理,0",
"申请出库,1",
"确认出库,2",
"不能出库,3",
"取消出库,4"
]
}
]
},

Loading…
Cancel
Save