Files
wysite/output/sourcemaps/hc-etms.sqygj.cn/static/js/chunk-4896995a.047e156a.js

142 lines
12 KiB
JavaScript

(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["chunk-4896995a"], { "1e45": function(t, e, a) {
"use strict";
a.r(e);
var n = function() {
var t2 = this, e2 = t2.$createElement, a2 = t2._self._c || e2;
return a2("div", { staticClass: "headStys" }, [t2.infoList ? a2("div", {}, [a2("div", { staticClass: "formContent" }, [a2("el-form", { ref: "query", staticClass: "demo-form-inline", attrs: { inline: true, model: t2.query } }, [a2("el-form-item", { attrs: { prop: "name", label: "" } }, [a2("el-input", { attrs: { clearable: "", placeholder: "请输入名称", maxlength: "64" }, model: { value: t2.query.name, callback: function(e3) {
t2.$set(t2.query, "name", e3);
}, expression: "query.name" } })], 1), t2._v(" "), a2("el-form-item", { attrs: { prop: "corporateCreditCode", label: "" } }, [a2("el-input", { attrs: { clearable: "", placeholder: "请输入企业统一社会信息代码", maxlength: "64" }, model: { value: t2.query.corporateCreditCode, callback: function(e3) {
t2.$set(t2.query, "corporateCreditCode", e3);
}, expression: "query.corporateCreditCode" } })], 1), t2._v(" "), a2("el-form-item", { attrs: { prop: "contactName", label: "" } }, [a2("el-input", { attrs: { clearable: "", placeholder: "请输入负责人姓名", maxlength: "64" }, model: { value: t2.query.contactName, callback: function(e3) {
t2.$set(t2.query, "contactName", e3);
}, expression: "query.contactName" } })], 1), t2._v(" "), a2("el-form-item", [a2("el-button", { directives: [{ name: "points", rawName: "v-points", value: 500, expression: "500" }], on: { click: function(e3) {
return t2.resetForm("query");
} } }, [t2._v("重置")])], 1), t2._v(" "), a2("el-form-item", [a2("el-button", { directives: [{ name: "points", rawName: "v-points", value: 500, expression: "500" }], attrs: { type: "primary" }, on: { click: t2.onSearch } }, [t2._v("查询")])], 1)], 1)], 1), t2._v(" "), a2("div", { staticClass: "contentStys" }, [a2("div", { staticClass: "planLst" }, [a2("span", [t2._v("分公司列表")]), t2._v(" "), a2("span", { staticClass: "addPlan" }, [a2("el-button", { directives: [{ name: "points", rawName: "v-points", value: 500, expression: "500" }], staticClass: "cololr", attrs: { type: "primary" }, on: { click: function(e3) {
return t2.addSupplier(2);
} } }, [t2._v("添加分公司")])], 1)]), t2._v(" "), a2("el-table", { directives: [{ name: "loading", rawName: "v-loading", value: t2.listLoading, expression: "listLoading" }], staticStyle: { width: "96%", "margin-left": "2%" }, attrs: { border: "", data: t2.listTable, "header-cell-style": t2.headClass, "tooltip-effect": "dark" } }, [a2("el-table-column", { attrs: { label: "#", align: "center", width: "50" }, scopedSlots: t2._u([{ key: "default", fn: function(e3) {
return [a2("span", [t2._v(t2._s(e3.$index + (t2.query.pageNumber - 1) * t2.query.pageSize + 1) + "\n ")])];
} }], null, false, 3311124033) }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "name", "min-width": "200", label: "分公司名称", "show-overflow-tooltip": "" } }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "corporateCreditCode", "min-width": "150", label: "企业统一社会信用代码", "show-overflow-tooltip": "" } }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "address", "min-width": "160", label: "注册地址", "show-overflow-tooltip": "" }, scopedSlots: t2._u([{ key: "default", fn: function(e3) {
return [t2._v("\n " + t2._s(e3.row.province) + t2._s(e3.row.city) + t2._s(e3.row.area) + t2._s(e3.row.address) + "\n ")];
} }], null, false, 1972213831) }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "contactName", "min-width": "80", label: "负责人" } }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "contactMobile", "min-width": "120", label: "联系电话" } }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "bankName", "min-width": "120", label: "开户行", "show-overflow-tooltip": "" } }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "bankAccount", "min-width": "120", label: "银行账号", "show-overflow-tooltip": "" } }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", prop: "invoiceStatus", "min-width": "100", label: "发票资质状态", "show-overflow-tooltip": "" }, scopedSlots: t2._u([{ key: "default", fn: function(e3) {
return [a2("span", { style: { color: 1 == e3.row.invoiceStatus ? "green" : "red" } }, [t2._v("\n " + t2._s(t2._f("getItemType")(e3.row.invoiceStatus, t2.invoiceStatusArr)) + "\n ")])];
} }], null, false, 1758299767) }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", "min-width": "80", label: "状态" }, scopedSlots: t2._u([{ key: "default", fn: function(e3) {
return [1 == e3.row.status ? a2("el-tag", { attrs: { type: "success" } }, [t2._v("启用")]) : t2._e(), t2._v(" "), 0 == e3.row.status ? a2("el-tag", { attrs: { type: "info" } }, [t2._v("禁用")]) : t2._e()];
} }], null, false, 3822344242) }), t2._v(" "), a2("el-table-column", { attrs: { align: "center", "min-width": "290", label: "操作" }, scopedSlots: t2._u([{ key: "default", fn: function(e3) {
return [a2("el-button", { class: 0 === e3.row.invoiceStatus ? "status-warning" : "status-danger", attrs: { type: "text" }, on: { click: function(a3) {
return t2.updataInvoiceStatus(e3.row);
} } }, [t2._v(t2._s(0 === e3.row.invoiceStatus ? "发票状态启用" : "发票状态禁用"))]), t2._v(" "), a2("el-button", { class: 0 === e3.row.status ? "status-warning" : "status-danger", attrs: { type: "text" }, on: { click: function(a3) {
return t2.updataStatus(e3.row);
} } }, [t2._v(t2._s(1 === e3.row.status ? "禁用" : "启用"))]), t2._v(" "), a2("el-button", { attrs: { type: "text" }, on: { click: function(a3) {
return t2.viewSupplier(e3.row);
} } }, [t2._v("查看")]), t2._v(" "), a2("el-button", { attrs: { type: "text" }, on: { click: function(a3) {
return t2.editSupplier(e3.row);
} } }, [t2._v("编辑")]), t2._v(" "), a2("el-button", { attrs: { type: "text" }, on: { click: function(a3) {
return t2.deleteSupplier(e3.row);
} } }, [t2._v("删除")])];
} }], null, false, 1112909680) })], 1), t2._v(" "), a2("div", { staticClass: "pagination" }, [a2("el-pagination", { attrs: { background: "", "current-page": t2.query.pageNumber, "page-sizes": [10, 20, 30, 100], "page-size": t2.query.pageSize, layout: "total, sizes, prev, pager, next, jumper", total: t2.pageTotal }, on: { "update:currentPage": function(e3) {
return t2.$set(t2.query, "pageNumber", e3);
}, "update:current-page": function(e3) {
return t2.$set(t2.query, "pageNumber", e3);
}, "size-change": t2.handleSizeChange, "current-change": t2.handleCurrentChange } })], 1)], 1)]) : t2._e(), t2._v(" "), t2.viewInfo ? a2("div", { staticClass: "viewDetails" }, [a2("addSupplier", { ref: "addSupplier", attrs: { type: t2.type, classify: t2.classify }, on: { goBack: t2.goBack } })], 1) : t2._e()]);
}, i = [], r = (a("ac67"), a("1bc7"), a("32ea"), a("5821")), s = a("333d"), o = a("c889"), l = a("a6b9"), c = a("b54d");
function u(t2, e2) {
var a2 = Object.keys(t2);
if (Object.getOwnPropertySymbols) {
var n2 = Object.getOwnPropertySymbols(t2);
e2 && (n2 = n2.filter((function(e3) {
return Object.getOwnPropertyDescriptor(t2, e3).enumerable;
}))), a2.push.apply(a2, n2);
}
return a2;
}
function p(t2) {
for (var e2 = 1; e2 < arguments.length; e2++) {
var a2 = null != arguments[e2] ? arguments[e2] : {};
e2 % 2 ? u(Object(a2), true).forEach((function(e3) {
Object(r["a"])(t2, e3, a2[e3]);
})) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t2, Object.getOwnPropertyDescriptors(a2)) : u(Object(a2)).forEach((function(e3) {
Object.defineProperty(t2, e3, Object.getOwnPropertyDescriptor(a2, e3));
}));
}
return t2;
}
var d = { components: { Pagination: s["a"], supplierInfo: o["a"], addSupplier: c["a"] }, data: function() {
return { pageTotal: 0, listLoading: false, listTable: [], query: { name: "", corporateCreditCode: "", contactName: "", pageSize: 10, pageNumber: 1, type: 2 }, infoList: true, viewInfo: false, type: "", classify: "", invoiceStatusArr: [{ value: 0, label: "已禁用" }, { value: 1, label: "已启用" }] };
}, created: function() {
this.headClass();
}, mounted: function() {
this.getlistData();
}, beforeRouteLeave: function(t2, e2, a2) {
this.viewInfo = false, this.infoList = true, a2();
}, methods: { getlistData: function() {
var t2 = this;
this.listLoading = true, this.query.companyId = JSON.parse(window.localStorage.getItem("companyInfo")).osId, Object(l["c"])(this.query).then((function(e2) {
t2.listTable = e2.data.records, t2.pageTotal = e2.data.rowsCount, t2.listLoading = false;
}));
}, addSupplier: function(t2) {
var e2 = this;
this.type = "add", this.classify = t2, this.viewInfo = true, this.infoList = false, this.$nextTick((function() {
e2.$refs.addSupplier.getInfoLst();
}));
}, editSupplier: function(t2) {
var e2 = this;
this.viewInfo = true, this.infoList = false, this.classify = t2.type, this.type = "edit", this.$nextTick((function() {
e2.$refs.addSupplier.getInfoLst(JSON.parse(JSON.stringify(t2)));
}));
}, viewSupplier: function(t2) {
var e2 = this;
this.viewInfo = true, this.infoList = false, this.classify = t2.type, this.type = "view", this.$nextTick((function() {
e2.$refs.addSupplier.getInfoLst(JSON.parse(JSON.stringify(t2)));
}));
}, updataStatus: function(t2) {
var e2 = this;
this.$confirm("确定修改数据状态吗?", "提示", { confirmButtonText: "确定", cancelButtonText: "取消", type: "warning", center: true }).then((function() {
var a2 = p(p({}, t2), {}, { status: 1 === t2.status ? 0 : 1 });
Object(l["d"])(a2).then((function(t3) {
0 === t3.code ? e2.$message({ message: "修改数据状态成功", type: "success" }) : e2.$message({ message: "修改数据状态失败", type: "error" }), e2.getlistData();
})).catch((function(t3) {
e2.$message({ message: "修改数据状态失败", type: "error" });
}));
}));
}, updataInvoiceStatus: function(t2) {
var e2 = this;
this.$confirm("确定修改发票状态吗?", "提示", { confirmButtonText: "确定", cancelButtonText: "取消", type: "warning", center: true }).then((function() {
var a2 = { id: t2.id, invoiceStatus: 0 === t2.invoiceStatus ? 1 : 0 };
Object(l["e"])(a2).then((function(t3) {
0 === t3.code ? (e2.$message({ message: "修改发票状态成功", type: "success" }), 2 === a2.status && e2.updataStatisicRes()) : e2.$message({ message: "修改发票状态失败", type: "error" }), e2.getlistData();
})).catch((function(t3) {
e2.$message({ message: "修改发票状态失败", type: "error" });
}));
}));
}, deleteSupplier: function(t2) {
var e2 = this;
this.$confirm("确定删除该数据吗?", "提示", { confirmButtonText: "确定", cancelButtonText: "取消", type: "info", center: true }).then((function() {
Object(l["b"])({ id: t2.id }).then((function(t3) {
0 === t3.code && (e2.getlistData(), e2.$message({ type: "success", message: "删除成功" }));
}));
})).catch((function() {
}));
}, openDialog: function() {
this.showDialog = true;
}, closeDialog: function() {
this.showDialog = false;
}, onSearch: function() {
this.query.pageNumber = 1, this.getlistData();
}, resetForm: function() {
this.query.name = "", this.query.corporateCreditCode = "", this.query.contactName = "", this.query.pageNumber = 1, this.getlistData();
}, handleSizeChange: function(t2) {
this.query.pageSize = t2, this.query.pageNumber = 1, this.getlistData();
}, handleCurrentChange: function(t2) {
this.query.pageNumber = t2, this.getlistData();
}, headClass: function() {
return "text-align:center;background:#FAFAFA;";
}, goBack: function() {
this.viewInfo = false, this.infoList = true, this.getlistData();
} } }, f = d, g = (a("6fa9"), a("829d")), m = Object(g["a"])(f, n, i, false, null, "697176e6", null);
e["default"] = m.exports;
}, "6fa9": function(t, e, a) {
"use strict";
a("9e13");
}, "9e13": function(t, e, a) {
} }]);