Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Fedex
/
imac-vue
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Elements-SY
2023-09-01 10:51:54 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
511f6d80eeb3bf76fdc59799566a4595303a486c
511f6d80
1 parent
6131799d
英文品名黑名单联调
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
40 additions
and
51 deletions
src/api/et86ShipmentDesc.js
src/views/et86Config/et86HsCodeBlack/index.vue
src/views/et86Config/et86ShipmentDesc/formConfig.js
src/views/et86Config/et86ShipmentDesc/index.vue
src/views/et86Config/et86ShipmentDesc/tableConfig.js
src/api/et86ShipmentDesc.js
View file @
511f6d8
import
request
from
"@/utils/request"
;
// HScode英文品名黑名单查询
export
function
findShipmentDescList
(
data
)
{
return
request
({
url
:
"/etes/findShipmentDescList"
,
method
:
"post"
,
data
:
data
,
});
}
// HScode英文品名黑名单导入
export
function
uploadShipmentDesc
(
data
)
{
return
request
({
url
:
"/etes/uploadShipmentDesc"
,
method
:
"post"
,
data
:
data
,
});
}
// HScode黑名单/英文品名删除
export
function
delBlackList
(
data
)
{
return
request
({
url
:
"/etes/delBlackList"
,
url
:
"/etes/delBlackList
"
,
method
:
"post"
,
data
:
data
,
});
}
...
...
src/views/et86Config/et86HsCodeBlack/index.vue
View file @
511f6d8
...
...
@@ -191,9 +191,9 @@ export default {
const { code, data, msg } = res;
if (code == 200) {
this.searchBtn();
this.msgSuccess(msg || "
增加
成功!");
this.msgSuccess(msg || "
导入
成功!");
} else {
this.$message.error(msg || "
增加
失败");
this.$message.error(msg || "
导入
失败");
this.$router.push({
path: "/errorInfo",
query: {
...
...
src/views/et86Config/et86ShipmentDesc/formConfig.js
View file @
511f6d8
...
...
@@ -2,8 +2,8 @@ export const formConfig = [
{
label
:
"ShipmentDesc"
,
type
:
"Input"
,
name
:
"
ShipmentDesc
"
,
prop
:
"
ShipmentDesc
"
,
name
:
"
searchValue
"
,
prop
:
"
searchValue
"
,
placeholder
:
"根据ShipmentDesc查询"
,
span
:
7
,
trigger
:
"blur"
,
// 事件名
...
...
src/views/et86Config/et86ShipmentDesc/index.vue
View file @
511f6d8
...
...
@@ -20,7 +20,6 @@
:tableData="tableData"
:pageConfig="pageConfig"
@search="searchBtn"
@download="downloadTemplate"
@upload="toUpload"
@rmfile="onRemoveUpload"
@export="exportTemplate"
...
...
@@ -90,14 +89,13 @@ import { formConfig } from "./formConfig";
import { tableAttr, columnHeader } from "./tableConfig";
import { restTableHeight } from "@/utils";
import {
findHsCodeList, // HScode黑名单查询
delBlackList, // HScode黑名单删除
downLoadTemplate, // HScode黑名单下载模板
uploadHsCode, // HScode黑名单导入
} from "@/api/et86HsCodeBlack";
findShipmentDescList, // HScode英文品名黑名单查询
uploadShipmentDesc, // HScode英文品名黑名单导入
delBlackList, // HScode黑名单/英文品名删除
} from "@/api/et86ShipmentDesc";
import { downLoadXlsx } from "@/utils/zipdownload";
export default {
name: "
Et86HsCodeBlack
",
name: "
et86ShipmentDesc
",
components: {
YlForm,
YlTable,
...
...
@@ -147,7 +145,7 @@ export default {
},
methods: {
// HScode黑名单查询
queryFind
HsCode
List() {
queryFind
ShipmentDesc
List() {
const { page, size } = this.pageConfig.pageData;
let params = {
limitStart: (page - 1) * size,
...
...
@@ -155,7 +153,7 @@ export default {
...this.queryForm,
};
this.tableAttr.loadingTable = true;
find
HsCode
List(params)
find
ShipmentDesc
List(params)
.then((res) => {
this.tableAttr.loadingTable = false;
const { code, data } = res;
...
...
@@ -186,14 +184,14 @@ export default {
toUpload({ file }) {
const formData = new FormData();
formData.append("file", file);
upload
HsCode
(formData)
upload
ShipmentDesc
(formData)
.then((res) => {
const { code, data, msg } = res;
if (code == 200) {
this.searchBtn();
this.msgSuccess(msg || "
增加
成功!");
this.msgSuccess(msg || "
导入
成功!");
} else {
this.$message.error(msg || "
增加
失败");
this.$message.error(msg || "
导入
失败");
this.$router.push({
path: "/errorInfo",
query: {
...
...
@@ -215,31 +213,11 @@ export default {
this.pageConfig.pageData.page = 1;
this.pageConfig.pageData.size = 10;
this.$refs.ruleForm.handleSearch("ruleForm", (val) => {
this.queryFind
HsCode
List();
this.queryFind
ShipmentDesc
List();
});
},
// 确认对话框
dialogConfirm() {},
// 下载【HScode黑名单下载模板】
downloadTemplate() {
downLoadTemplate("hsCode")
.then((res) => {
if (res) {
const blob = new Blob([res]);
const link = document.createElement("a"); //创建a标签
link.download = "HSCODE黑名单表.xlsx"; //a标签添加属性
link.style.display = "none";
link.href = URL.createObjectURL(blob);
document.body.appendChild(link);
link.click(); //执行下载
URL.revokeObjectURL(link.href); //释放url
document.body.removeChild(link); //释放标签
} else {
this.$message.error("下载失败");
}
})
.catch(() => {});
},
// 上传
upLoadTemplate() {
// console.log(this.$refs.modleViewRef);
...
...
@@ -247,7 +225,7 @@ export default {
// 导出
exportTemplate(row, i) {
this.tableAttr.btnCofig.btnGroup[i].loading = true;
downLoadXlsx("/etes/export
HsCodeList", this.queryForm, "HSCODE
黑名单表")
downLoadXlsx("/etes/export
ShipmentDescList", this.queryForm, "HSCODE英文品名
黑名单表")
.then(() => {
this.tableAttr.btnCofig.btnGroup[i].loading = false;
})
...
...
@@ -280,12 +258,12 @@ export default {
handleSizeChange(e) {
this.pageConfig.pageData.size = e;
this.pageConfig.pageData.page = 1;
this.queryFind
HsCode
List();
this.queryFind
ShipmentDesc
List();
},
//页码变化
handleCurrentChange(e) {
this.pageConfig.pageData.page = e;
this.queryFind
HsCode
List();
this.queryFind
ShipmentDesc
List();
},
// table勾选
tableSelectionChange(val) {
...
...
src/views/et86Config/et86ShipmentDesc/tableConfig.js
View file @
511f6d8
...
...
@@ -17,15 +17,6 @@ export const tableAttr = {
},
{
type
:
"primary"
,
icon
:
"el-icon-download"
,
btnName
:
"下载模板"
,
size
:
"mini"
,
round
:
false
,
loading
:
false
,
event
:
"download"
,
},
{
type
:
"primary"
,
icon
:
"el-icon-upload"
,
btnName
:
"导入"
,
size
:
"mini"
,
...
...
@@ -74,7 +65,7 @@ export const columnHeader = (deleteRow) => [
},
{
label
:
"ShipmentDesc"
,
prop
:
"
ShipmentDesc
"
,
prop
:
"
blackValue
"
,
align
:
"center"
,
minWidth
:
100
,
},
...
...
Please
register
or
login
to post a comment