Commit 3f38a3c1 authored by zhengyi's avatar zhengyi

Merge branch 'pre-release'

# Conflicts:
#	.env.staging
parents 59bfdf4b c888ac85
...@@ -6,10 +6,10 @@ VUE_APP_TITLE = 捷道管理系统-测试站 ...@@ -6,10 +6,10 @@ VUE_APP_TITLE = 捷道管理系统-测试站
# 捷道管理系统/开发环境 # 捷道管理系统/开发环境
# VUE_APP_BASE_API = 'https://apitest.groupage.cn' VUE_APP_BASE_API = 'https://devapi.jd.qipx.top'
# VUE_APP_BASE_API = 'http://110.41.143.128:48080' # VUE_APP_BASE_API = 'http://110.41.143.128:48080'
VUE_APP_BASE_API = 'http://127.0.0.1:48080' # VUE_APP_BASE_API = 'http://127.0.0.1:48080'
# 路由懒加载 # 路由懒加载
......
zall-sdk-javascript-master/
\ No newline at end of file
{
"printWidth": 800,
"semi": false,
"psingleQuote": true,
"trailingComma": "none"
}
\ No newline at end of file
...@@ -127,7 +127,7 @@ export function getCostList(params) { ...@@ -127,7 +127,7 @@ export function getCostList(params) {
}); });
} }
// 收款单表 SELECT * from ecw_payment // 收款单表 SELECT * from ecw_payment
// 应付款表 SELECT * from ecw_payable // 应付款表 SELECT * from ecw_payable
// 根据明细获取主表ID // 根据明细获取主表ID
export function getPaymentId(id) { export function getPaymentId(id) {
return request({ return request({
...@@ -214,6 +214,13 @@ export function deleteBillService(id) { ...@@ -214,6 +214,13 @@ export function deleteBillService(id) {
method: "delete", method: "delete",
}); });
} }
// 检查提单状态是否已制作提单
export function checkBillOfLadingService(orderId) {
return request({
url: "/shipment/make-bill-of-lading/check/billOfLading/" + orderId,
method: "post",
});
}
// 获得制作提货单 // 获得制作提货单
export function getBillService(params) { export function getBillService(params) {
......
import request from "@/utils/request"; import request from "@/utils/request"
// 创建出货 // 创建出货
export function createbox(data) { export function createbox(data) {
return request({ return request({
url: "/shipment/box/createAir", url: "/shipment/box/createAir",
method: "post", method: "post",
data: data, data: data
}); })
} }
// 更新出货 // 更新出货
...@@ -14,8 +14,8 @@ export function updatebox(data) { ...@@ -14,8 +14,8 @@ export function updatebox(data) {
return request({ return request({
url: "/shipment/box/update", url: "/shipment/box/update",
method: "put", method: "put",
data: data, data: data
}); })
} }
/** /**
...@@ -30,15 +30,15 @@ export function booking(data) { ...@@ -30,15 +30,15 @@ export function booking(data) {
return request({ return request({
url: "/shipment/box-book-air/update", url: "/shipment/box-book-air/update",
method: "put", method: "put",
data, data
}); })
} }
return request({ return request({
url: "/shipment/box-book-air/create", url: "/shipment/box-book-air/create",
method: "post", method: "post",
data, data
}); })
} }
/** /**
...@@ -52,8 +52,8 @@ export function preloadPage(data) { ...@@ -52,8 +52,8 @@ export function preloadPage(data) {
return request({ return request({
url: "/ecw/box-preload-goods/preloadPageAir", url: "/ecw/box-preload-goods/preloadPageAir",
method: "post", method: "post",
data, data
}); })
} }
/** /**
...@@ -67,8 +67,8 @@ export function createGoods(data) { ...@@ -67,8 +67,8 @@ export function createGoods(data) {
return request({ return request({
url: "/ecw/box-preload-goods/createAir", url: "/ecw/box-preload-goods/createAir",
method: "post", method: "post",
data, data
}); })
} }
/***************************** 合包 start **********************************/ /***************************** 合包 start **********************************/
...@@ -84,8 +84,8 @@ export function getMergePkgList(params) { ...@@ -84,8 +84,8 @@ export function getMergePkgList(params) {
return request({ return request({
url: "/ecw/box-merge-pkg/page", url: "/ecw/box-merge-pkg/page",
method: "get", method: "get",
params, params
}); })
} }
/** /**
...@@ -99,8 +99,8 @@ export function createMergePkg(data) { ...@@ -99,8 +99,8 @@ export function createMergePkg(data) {
return request({ return request({
url: "/ecw/box-merge-pkg/create", url: "/ecw/box-merge-pkg/create",
method: "post", method: "post",
data, data
}); })
} }
/** /**
...@@ -114,8 +114,8 @@ export function updateMergePkg(data) { ...@@ -114,8 +114,8 @@ export function updateMergePkg(data) {
return request({ return request({
url: "/ecw/box-merge-pkg/update", url: "/ecw/box-merge-pkg/update",
method: "put", method: "put",
data, data
}); })
} }
/** /**
...@@ -127,9 +127,9 @@ export function updateMergePkg(data) { ...@@ -127,9 +127,9 @@ export function updateMergePkg(data) {
*/ */
export function deleteMergePkg(id) { export function deleteMergePkg(id) {
return request({ return request({
url: `/ecw/box-merge-pkg/delete?id=`+id, url: `/ecw/box-merge-pkg/delete?id=` + id,
method: "delete", method: "delete"
}); })
} }
/** /**
...@@ -143,8 +143,8 @@ export function getUnPkgPage(params) { ...@@ -143,8 +143,8 @@ export function getUnPkgPage(params) {
return request({ return request({
url: "/ecw/box-merge-pkg/getUnPkgPage", url: "/ecw/box-merge-pkg/getUnPkgPage",
method: "get", method: "get",
params, params
}); })
} }
/** /**
...@@ -158,8 +158,8 @@ export function getPkgPageByPkgId(params) { ...@@ -158,8 +158,8 @@ export function getPkgPageByPkgId(params) {
return request({ return request({
url: "/ecw/box-merge-pkg/getPkgPageByPkgId", url: "/ecw/box-merge-pkg/getPkgPageByPkgId",
method: "get", method: "get",
params, params
}); })
} }
/** /**
...@@ -173,8 +173,8 @@ export function createPkgOrder(data) { ...@@ -173,8 +173,8 @@ export function createPkgOrder(data) {
return request({ return request({
url: "/ecw/box-pkg-order/create", url: "/ecw/box-pkg-order/create",
method: "post", method: "post",
data, data
}); })
} }
/** /**
...@@ -188,8 +188,8 @@ export function createBatchPkgOrder(data) { ...@@ -188,8 +188,8 @@ export function createBatchPkgOrder(data) {
return request({ return request({
url: "/ecw/box-pkg-order/createBatch", url: "/ecw/box-pkg-order/createBatch",
method: "post", method: "post",
data, data
}); })
} }
/** /**
...@@ -203,11 +203,11 @@ export function deleteRelate(pkgId, orderId) { ...@@ -203,11 +203,11 @@ export function deleteRelate(pkgId, orderId) {
return request({ return request({
url: `/ecw/box-pkg-order/deleteRelate`, url: `/ecw/box-pkg-order/deleteRelate`,
method: "delete", method: "delete",
headers:{ headers: {
'Content-type': 'application/x-www-form-urlencoded' "Content-type": "application/x-www-form-urlencoded"
}, },
data: 'pkgId='+pkgId+'&orderId='+orderId data: "pkgId=" + pkgId + "&orderId=" + orderId
}); })
} }
/** /**
...@@ -222,7 +222,7 @@ export function deleteBatchRelate(data) { ...@@ -222,7 +222,7 @@ export function deleteBatchRelate(data) {
url: `/ecw/box-pkg-order/deleteBatchRelate`, url: `/ecw/box-pkg-order/deleteBatchRelate`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -234,9 +234,9 @@ export function deleteBatchRelate(data) { ...@@ -234,9 +234,9 @@ export function deleteBatchRelate(data) {
*/ */
export function getMergePkgInfoById(id) { export function getMergePkgInfoById(id) {
return request({ return request({
url: "/ecw/box-merge-pkg/getMergePkgInfoById?id="+id, url: "/ecw/box-merge-pkg/getMergePkgInfoById?id=" + id,
method: "get" method: "get"
}); })
} }
/** /**
...@@ -248,9 +248,9 @@ export function getMergePkgInfoById(id) { ...@@ -248,9 +248,9 @@ export function getMergePkgInfoById(id) {
*/ */
export function getMergeTagById(id) { export function getMergeTagById(id) {
return request({ return request({
url: "/ecw/box-merge-pkg/getMergeTagById?id="+id, url: "/ecw/box-merge-pkg/getMergeTagById?id=" + id,
method: "get" method: "get"
}); })
} }
/** /**
...@@ -262,29 +262,27 @@ export function getMergeTagById(id) { ...@@ -262,29 +262,27 @@ export function getMergeTagById(id) {
*/ */
export function finishMergePkg(shipmentId) { export function finishMergePkg(shipmentId) {
return request({ return request({
url: "/ecw/box-merge-pkg/finishMergePkg?shipmentId="+shipmentId, url: "/ecw/box-merge-pkg/finishMergePkg?shipmentId=" + shipmentId,
method: "get" method: "get"
}); })
} }
/***************************** 合包 end **********************************/ /***************************** 合包 end **********************************/
/***************************** 起运 start *******************************/ /***************************** 起运 start *******************************/
export function takeoffCreate(data) { export function takeoffCreate(data) {
if (data.id) { if (data.id) {
return request({ return request({
url: "/ecw/box-air-fly/update", url: "/ecw/box-air-fly/update",
method: "put", method: "put",
data, data
}); })
} }
return request({ return request({
url: "/ecw/box-air-fly/create", url: "/ecw/box-air-fly/create",
method: "post", method: "post",
data, data
}); })
} }
/***************************** 起运 end *******************************/ /***************************** 起运 end *******************************/
...@@ -297,9 +295,9 @@ export function takeoffCreate(data) { ...@@ -297,9 +295,9 @@ export function takeoffCreate(data) {
*/ */
export function shipmentOrderList(shipmentId) { export function shipmentOrderList(shipmentId) {
return request({ return request({
url: "/shipment/box/shipmentOrderList?shipmentId="+shipmentId, url: "/shipment/box/shipmentOrderList?shipmentId=" + shipmentId,
method: "get" method: "get"
}); })
} }
/** /**
...@@ -314,7 +312,7 @@ export function updateOrderArrival(data) { ...@@ -314,7 +312,7 @@ export function updateOrderArrival(data) {
url: `/ecw/box-arrival-air/updateOrderArrival`, url: `/ecw/box-arrival-air/updateOrderArrival`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -329,7 +327,7 @@ export function createOrderArrival(data) { ...@@ -329,7 +327,7 @@ export function createOrderArrival(data) {
url: `/ecw/box-arrival-air/create`, url: `/ecw/box-arrival-air/create`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -344,7 +342,7 @@ export function updateAllOrderArrival(data) { ...@@ -344,7 +342,7 @@ export function updateAllOrderArrival(data) {
url: `/ecw/box-arrival-air/updateAllOrderArrival`, url: `/ecw/box-arrival-air/updateAllOrderArrival`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -359,7 +357,7 @@ export function updateOrderClearance(data) { ...@@ -359,7 +357,7 @@ export function updateOrderClearance(data) {
url: `/ecw/box-clearance/updateOrderClearance`, url: `/ecw/box-clearance/updateOrderClearance`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -374,7 +372,7 @@ export function updateAllOrderClearance(data) { ...@@ -374,7 +372,7 @@ export function updateAllOrderClearance(data) {
url: `/ecw/box-clearance/updateAllOrderClearance`, url: `/ecw/box-clearance/updateAllOrderClearance`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -389,7 +387,7 @@ export function getLineInfo(params) { ...@@ -389,7 +387,7 @@ export function getLineInfo(params) {
url: `/ecw/warehouse/getLineInfo`, url: `/ecw/warehouse/getLineInfo`,
method: "get", method: "get",
params params
}); })
} }
/** /**
...@@ -400,7 +398,7 @@ export function downloadLoadGoods(params) { ...@@ -400,7 +398,7 @@ export function downloadLoadGoods(params) {
url: "/ecw/box-preload-goods/downloadAirLoadGoodsList", url: "/ecw/box-preload-goods/downloadAirLoadGoodsList",
method: "get", method: "get",
timeout: 120000, timeout: 120000,
params, params
}) })
} }
...@@ -416,7 +414,7 @@ export function checkInfoSingleCreate(data) { ...@@ -416,7 +414,7 @@ export function checkInfoSingleCreate(data) {
url: `/ecw/box-order-check-info/singleCreate`, url: `/ecw/box-order-check-info/singleCreate`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -431,7 +429,7 @@ export function checkInfoBatchCreate(data) { ...@@ -431,7 +429,7 @@ export function checkInfoBatchCreate(data) {
url: `/ecw/box-order-check-info/batchCreate`, url: `/ecw/box-order-check-info/batchCreate`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -446,7 +444,7 @@ export function checkInfoSingleDelete(data) { ...@@ -446,7 +444,7 @@ export function checkInfoSingleDelete(data) {
url: `/ecw/box-order-check-info/singleDelete`, url: `/ecw/box-order-check-info/singleDelete`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -461,7 +459,7 @@ export function checkInfoBatchDelete(data) { ...@@ -461,7 +459,7 @@ export function checkInfoBatchDelete(data) {
url: `/ecw/box-order-check-info/batchDelete`, url: `/ecw/box-order-check-info/batchDelete`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -476,7 +474,7 @@ export function getOrderTagList(params) { ...@@ -476,7 +474,7 @@ export function getOrderTagList(params) {
url: `/ecw/box-order-check-info/orderTagList`, url: `/ecw/box-order-check-info/orderTagList`,
method: "get", method: "get",
params params
}); })
} }
/** /**
...@@ -491,7 +489,7 @@ export function searchLoadOrderByBoxNo(data) { ...@@ -491,7 +489,7 @@ export function searchLoadOrderByBoxNo(data) {
url: `/ecw/box-order-check-info/searchLoadOrderByBoxNo`, url: `/ecw/box-order-check-info/searchLoadOrderByBoxNo`,
method: "post", method: "post",
data: data data: data
}); })
} }
/** /**
...@@ -506,7 +504,7 @@ export function confirmAirCheckout(params) { ...@@ -506,7 +504,7 @@ export function confirmAirCheckout(params) {
url: `/ecw/box-air-checkout/confirmAirCheckout`, url: `/ecw/box-air-checkout/confirmAirCheckout`,
method: "get", method: "get",
params params
}); })
} }
/** /**
...@@ -520,8 +518,8 @@ export function singleAirCreate(data) { ...@@ -520,8 +518,8 @@ export function singleAirCreate(data) {
return request({ return request({
url: "/ecw/box-load-info/singleAirCreate", url: "/ecw/box-load-info/singleAirCreate",
method: "post", method: "post",
data, data
}); })
} }
/** /**
* 批量装柜 * 批量装柜
...@@ -534,6 +532,6 @@ export function batchAirCreate(data) { ...@@ -534,6 +532,6 @@ export function batchAirCreate(data) {
return request({ return request({
url: "/ecw/box-load-info/batchAirCreate", url: "/ecw/box-load-info/batchAirCreate",
method: "post", method: "post",
data, data
}); })
} }
...@@ -291,6 +291,14 @@ export function infoListOrderPage(params){ ...@@ -291,6 +291,14 @@ export function infoListOrderPage(params){
params params
}) })
} }
//客户详情订单统计
export function infoListStatisticsOrder(params){
return request({
url:'/ecw/order/customer-statistics-order',
method:'get',
params
})
}
//客户详情 --- 报价 //客户详情 --- 报价
export function infoListOfferPage(params){ export function infoListOfferPage(params){
return request({ return request({
...@@ -503,3 +511,68 @@ export function updatecustomerToOld(params){ ...@@ -503,3 +511,68 @@ export function updatecustomerToOld(params){
params params
}) })
} }
export function changeCustomerDefaultPay(data){
return request({
url:'ecw/customer/change-customer-default-pay',
method:'put',
data
})
}
export function changeCustomerNoConsignee(data){
return request({
url:'ecw/customer/change-customer-no-consignee',
method:'put',
data
})
}
export function changeCustomerDefaultBilling(data){
return request({
url:'ecw/customer/change-customer-default-billing',
method:'put',
data
})
}
export function customerSettingButton(data){
return request({
url:'ecw/customer/update-customer-setup',
method:'put',
data
})
}
export function addCompetitor(data){
return request({
url:'customer/competitor/create',
method:'post',
data
})
}
// 获得客户
export function getCompetitor(id) {
return request({
url: '/customer/competitor/get?id=' + id,
method: 'get'
})
}
export function competitorListAll(params){
return request({
url:'customer/competitor/listAll',
method:'get',
params
})
}
export function customerMergeCus(params){
return request({
url:'ecw/customer/mergeCus',
method:'get',
params
})
}
import request from '@/utils/request' import request from "@/utils/request"
// 创建跟进 // 创建跟进
export function createCustomerFollow(data) { export function createCustomerFollow(data) {
return request({ return request({
url: '/ecw/customer-follow/create', url: "/ecw/customer-follow/create",
method: 'post', method: "post",
data: data data: data
}) })
} }
...@@ -12,8 +12,8 @@ export function createCustomerFollow(data) { ...@@ -12,8 +12,8 @@ export function createCustomerFollow(data) {
// 更新跟进 // 更新跟进
export function updateCustomerFollow(data) { export function updateCustomerFollow(data) {
return request({ return request({
url: '/ecw/customer-follow/update', url: "/ecw/customer-follow/update",
method: 'put', method: "put",
data: data data: data
}) })
} }
...@@ -21,31 +21,31 @@ export function updateCustomerFollow(data) { ...@@ -21,31 +21,31 @@ export function updateCustomerFollow(data) {
// 删除跟进 // 删除跟进
export function deleteCustomerFollow(id) { export function deleteCustomerFollow(id) {
return request({ return request({
url: '/ecw/customer-follow/delete?id=' + id, url: "/ecw/customer-follow/delete?id=" + id,
method: 'delete' method: "delete"
}) })
} }
// 获得跟进 // 获得跟进
export function getCustomerFollow(id) { export function getCustomerFollow(id) {
return request({ return request({
url: '/ecw/customer-follow/get?id=' + id, url: "/ecw/customer-follow/get?id=" + id,
method: 'get' method: "get"
}) })
} }
// 获得跟进分页 // 获得跟进分页
export function getCustomerFollowPage(query) { export function getCustomerFollowPage(query) {
return request({ return request({
url: '/customer/detail/infoList/followPage', url: "/customer/detail/infoList/followPage",
method: 'get', method: "get",
params: query params: query
}) })
} }
export function getCustomerFollowPage2(query) { export function getCustomerFollowPage2(query) {
return request({ return request({
url: '/ecw/customer-follow/page', url: "/ecw/customer-follow/page",
method: 'get', method: "get",
params: query params: query
}) })
} }
...@@ -53,9 +53,82 @@ export function getCustomerFollowPage2(query) { ...@@ -53,9 +53,82 @@ export function getCustomerFollowPage2(query) {
// 导出跟进 Excel // 导出跟进 Excel
export function exportCustomerFollowExcel(query) { export function exportCustomerFollowExcel(query) {
return request({ return request({
url: '/ecw/customer-follow/export-excel', url: "/ecw/customer-follow/export-excel",
method: 'get', method: "get",
params: query, params: query,
responseType: 'blob' responseType: "blob"
})
}
// 跟进分页列表
export function getCustomerFollowupList(params) {
return request({
url: "/customer/followup/page",
method: "get",
params
})
}
// 数据权限跟进分页列表
export function getDataSpaceCustomerFollowupList(params) {
return request({
url: "/customer/followup/data/space/page",
method: "get",
params
})
}
export function getCustomerFollowDetail(params) {
return request({
url: "/customer/followup/get",
method: "get",
params
})
}
export function addCustomerFollow(data) {
return request({
url: "/customer/followup/create",
method: "post",
data
})
}
export function editCustomerFollow(data) {
return request({
url: "/customer/followup/update",
method: "put",
data
})
}
export function updateCustomerFollowupStatus(data) {
return request({
url: "/customer/followup/update-status",
method: "put",
data
})
}
export function exportCustomerFollowup(params) {
return request({
url: "/customer/followup/export-excel",
method: "get",
params
})
}
// 数据权限导出跟进 Excel
export function exportDataSpaceCustomerFollowup(query) {
return request({
url: "/customer/followup/data/space/export-excel",
method: "get",
params: query,
responseType: "blob"
})
}
export function getFollowupNewNumber() {
return request({
url: "/customer/followup/getFollowupNewNumber",
method: "get"
}) })
} }
import request from "@/utils/request";
//获取网点列表
export function getNodeList(query) {
return request({
url: "/ecw/node/list-all-simple",
method: "get",
params: query,
});
}
//获取积分列表
export function getGiftList(data) {
return request({
url: "/ecw/reward/page",
method: "post",
params: {
page: data.page,
rows: data.rows,
},
data: data,
});
}
//新增礼品
export function addRewards(data) {
return request({
url: "/ecw/reward/create",
method: "post",
data: data,
});
}
//删除礼品
export function deleteRewards(data) {
return request({
url: "/ecw/reward/delete?id=" + data.id,
method: "delete",
});
}
//礼品延期
export function delayRewards(data) {
return request({
url: "/ecw/reward/delay",
method: "post",
data: data,
});
}
//编辑礼品
export function editRewards(data) {
return request({
url: "/ecw/reward/update",
method: "post",
data: data,
});
}
//礼品状态变更
export function changeRewardsStatus(data) {
return request({
url: "/ecw/reward/status",
method: "post",
data: data,
});
}
//复制礼品
export function copyRewardsAPI(id) {
return request({
url: "/ecw/reward/copy/" + id,
method: "post",
});
}
//获取单个礼品详情
export function getRewardsDetails(data) {
return request({
url: "/ecw/reward/get",
method: "get",
params: data,
});
}
//获取国家列表
export function getTradeCountryList() {
return request({
url: "/ecw/region/getTradeCountryList",
method: "get",
});
}
//获取城市列表
export function getCityList(query) {
return request({
url: "/ecw/region/getCityListByParent",
method: "get",
params: query,
});
}
//获取会员积分列表
export function getMemberList(data) {
return request({
url: "/member/user-score/page",
method: "post",
data,
});
}
//批量兑换礼品
export function bulkConversion(data) {
return request({
url: "/reward/redeem/batch",
method: "post",
data,
});
}
//获取仓库列表下拉框
export function getWarehouseList(data) {
return request({
url: "/ecw/warehouse/list-all-simple",
method: "post",
data,
});
}
import request from "@/utils/request";
// 操作积分
export function operateMemberScore(data) {
return request({
url: "/member/user-score/operate",
method: "post",
data: data,
});
}
// 积分记录分页
export function queryMemberScoreRecord(data) {
return request({
url: "/member/user-score-log/page",
method: "post",
data: data,
});
}
// 兑换记录分页
export function queryMemberExchangeRecord(data) {
return request({
url: "/reward/redeem/record/page",
method: "post",
data: data,
});
}
// 批量核销按钮
export function batchVerifyAPI(data) {
return request({
url: "/reward/redeem/record/batch/verify",
method: "post",
data: data,
});
}
// 兑换记录导出
export function batchRecordExport(data) {
return request({
url: "/reward/redeem/record/export",
method: "post",
data: data,
});
}
// 兑换记录导入
export function batchRecordImport(data) {
return request({
url: "/reward/redeem/record/import",
method: "post",
data: data,
});
}
// 兑换记录导入模板下载
export function batchRecordImportTemplate() {
return request({
url: "/reward/redeem/record/import/template",
method: "post",
responseType: "blob",
});
}
// 撤销 操作
export function rewardCancelQuery(data) {
return request({
url: "/reward/redeem/record/cancel",
method: "post",
data: data,
});
}
// 获取记录详情
export function getRewardDetailQuery(data) {
return request({
url: "/reward/redeem/record/detail",
method: "post",
data: data,
});
}
// 更新兑换记录
export function updatedRewardsDetails(data) {
return request({
url: "/reward/redeem/record/update",
method: "post",
data: data,
});
}
// 核销回退
export function verifyRollback(data) {
return request({
url: "/reward/redeem/record/verify-back",
method: "post",
data: data,
});
}
// 核销 操作
export function verifyRedeem(data) {
return request({
url: "/reward/redeem/record/verify",
method: "post",
data: data,
});
}
// 获取积分规则记录
export function getScoreRecordList(data) {
return request({
url: "/member/score-rule/page",
method: "post",
params: {
page: data.page,
rows: data.rows,
},
data,
});
}
// 会员积分等级列表
export function getMemberLevelList(data) {
return request({
url: "/member/user-level/page",
method: "post",
data,
});
}
// 新增会员等级设置
export function addNewMemberLevel(data) {
return request({
url: "/member/user-level/add",
method: "post",
data,
});
}
// 删除会员等级
export function delMemberLevel(data) {
return request({
url: "/member/user-level/delete",
method: "post",
data,
});
}
// edit member level
export function editMemberLevel(data) {
return request({
url: "/member/user-level/update",
method: "post",
data,
});
}
// 获得目的国、目的城市、目的仓列表
export function getRegionTreeList() {
return request({
url: "/member/score-rule/warehouse-tree-region-list",
method: "get",
});
}
// 获取渠道列表
export function getChannelList() {
return request({
url: "/ecw/channel/list-all-simple",
method: "get",
});
}
// 积分规则创建
export function createIntegralRule(data) {
return request({
url: "/member/score-rule/create",
method: "post",
data,
});
}
// 启用关闭 积分规则
export function integralRuleStatus(data) {
return request({
url: "/member/score-rule/status",
method: "post",
data,
});
}
// 复制积分规则
export function integralRuleCopy(data) {
return request({
url: "/member/score-rule/copy",
method: "post",
data,
});
}
// 延期积分规则
export function integralRuleDelay(data) {
return request({
url: "/member/score-rule/delay",
method: "post",
data,
});
}
// 删除积分规则
export function integralRuleDelete(data) {
return request({
url: "/member/score-rule/delete",
method: "post",
data,
});
}
// 获取积分规则详情
export function integralRuleDetails(data) {
return request({
url: "/member/score-rule/get",
method: "post",
data,
});
}
// 编辑积分规则
export function integralRuleUpdated(data) {
return request({
url: "/member/score-rule/update",
method: "post",
data,
});
}
// 获取会员功能开关
export function switchRuleGet() {
return request({
url: "/member/score-rule/switch/get",
method: "get",
});
}
// 设置会员工能开关
export function switchRuleSet(data) {
return request({
url: "/member/score-rule/switch/set",
method: "post",
data,
});
}
//分享记录分页
export function getShareRecordList(data) {
return request({
url: "/member/score-rule/share-record/page",
method: "post",
data,
});
}
//获取分享记录详情
export function getShareRecordDetails(data) {
return request({
url: "/member/score-rule/share-record/detail",
method: "post",
data,
});
}
import request from '@/utils/request' import request from "@/utils/request"
// 创建报价单管理 // 创建报价单管理
export function createOffer(data) { export function createOffer(data) {
return request({ return request({
url: '/ecw/offer/create', url: "/ecw/offer/create",
method: 'post', method: "post",
data: data data: data
}) })
} }
...@@ -12,8 +12,8 @@ export function createOffer(data) { ...@@ -12,8 +12,8 @@ export function createOffer(data) {
// 更新报价单管理 // 更新报价单管理
export function updateOffer(data) { export function updateOffer(data) {
return request({ return request({
url: '/ecw/offer/update', url: "/ecw/offer/update",
method: 'put', method: "put",
data: data data: data
}) })
} }
...@@ -21,24 +21,24 @@ export function updateOffer(data) { ...@@ -21,24 +21,24 @@ export function updateOffer(data) {
// 删除报价单管理 // 删除报价单管理
export function deleteOffer(id) { export function deleteOffer(id) {
return request({ return request({
url: '/ecw/offer/delete?id=' + id, url: "/ecw/offer/delete?id=" + id,
method: 'delete' method: "delete"
}) })
} }
// 获得报价单管理 // 获得报价单管理
export function getOffer(id) { export function getOffer(id) {
return request({ return request({
url: '/ecw/offer/get?offerId=' + id, url: "/ecw/offer/get?offerId=" + id,
method: 'get' method: "get"
}) })
} }
// 获得报价单管理分页 // 获得报价单管理分页
export function getOfferPage(query) { export function getOfferPage(query) {
return request({ return request({
url: '/ecw/offer/page', url: "/ecw/offer/page",
method: 'get', method: "get",
params: query params: query
}) })
} }
...@@ -46,36 +46,36 @@ export function getOfferPage(query) { ...@@ -46,36 +46,36 @@ export function getOfferPage(query) {
// 导出报价单管理 Excel // 导出报价单管理 Excel
export function exportOfferExcel(query) { export function exportOfferExcel(query) {
return request({ return request({
url: '/ecw/offer/export-excel', url: "/ecw/offer/export-excel",
method: 'get', method: "get",
params: query, params: query,
responseType: 'blob' responseType: "blob"
}) })
} }
// 更新报价单结果 // 更新报价单结果
export function updateOfferResult(data) { export function updateOfferResult(data) {
return request({ return request({
url: '/ecw/offer/update/result', url: "/ecw/offer/update/result",
method: 'put', method: "put",
data: data data: data
}) })
} }
// 获取费用清单列表 // 获取费用清单列表
export function getProductFeeList(prodCreateReqVO){ export function getProductFeeList(prodCreateReqVO) {
return request({ return request({
url: '/ecw/offer/calculation/prod-fee-List', url: "/ecw/offer/calculation/prod-fee-List",
method: 'post', method: "post",
data: prodCreateReqVO data: prodCreateReqVO
}) })
} }
// 获取费用清单 // 获取费用清单
export function getProductFee(calculationFeeParamVO){ export function getProductFee(calculationFeeParamVO) {
return request({ return request({
url: '/ecw/offer/calculation/fee-List', url: "/ecw/offer/calculation/fee-List",
method: 'post', method: "post",
data: calculationFeeParamVO data: calculationFeeParamVO
}) })
} }
...@@ -83,8 +83,8 @@ export function getProductFee(calculationFeeParamVO){ ...@@ -83,8 +83,8 @@ export function getProductFee(calculationFeeParamVO){
// 特价申请 // 特价申请
export function createOfferSpecial(data) { export function createOfferSpecial(data) {
return request({ return request({
url: '/ecw/offer/special/apply', url: "/ecw/offer/special/apply",
method: 'put', method: "put",
data: data data: data
}) })
} }
...@@ -92,8 +92,8 @@ export function createOfferSpecial(data) { ...@@ -92,8 +92,8 @@ export function createOfferSpecial(data) {
// 特价详情 // 特价详情
export function getOfferSpecial(offerProdId, params) { export function getOfferSpecial(offerProdId, params) {
return request({ return request({
url: '/ecw/offer/special/info/' + offerProdId, url: "/ecw/offer/special/info/" + offerProdId,
method: 'get', method: "get",
params params
}) })
} }
...@@ -101,35 +101,34 @@ export function getOfferSpecial(offerProdId, params) { ...@@ -101,35 +101,34 @@ export function getOfferSpecial(offerProdId, params) {
// 特价详情 // 特价详情
export function getOfferSpecialByApproveId(approveId) { export function getOfferSpecialByApproveId(approveId) {
return request({ return request({
url: '/ecw/offer/special/info?approveId=' + approveId, url: "/ecw/offer/special/info?approveId=" + approveId,
method: 'get' method: "get"
}) })
} }
// 取消报价管理 // 取消报价管理
export function cancel(id) { export function cancel(id) {
return request({ return request({
url: '/ecw/offer/cancel', url: "/ecw/offer/cancel",
method: 'delete', method: "delete",
params: {id} params: { id }
}) })
} }
// 恢复取消的报价管理 // 恢复取消的报价管理
export function recovery(id) { export function recovery(id) {
return request({ return request({
url: '/ecw/offer/recovery', url: "/ecw/offer/recovery",
method: 'delete', method: "delete",
params: {id} params: { id }
}) })
} }
// 获取部门报价单列表 // 获取部门报价单列表
export function offerDeptPage(params) { export function offerDeptPage(params) {
return request({ return request({
url: '/ecw/offer/dept/page', url: "/ecw/offer/dept/page",
method: 'get', method: "get",
params params
}) })
} }
...@@ -137,25 +136,33 @@ export function offerDeptPage(params) { ...@@ -137,25 +136,33 @@ export function offerDeptPage(params) {
// 导出部分报价单 exportDeptOfferExcel // 导出部分报价单 exportDeptOfferExcel
export function exportDeptOfferExcel(query) { export function exportDeptOfferExcel(query) {
return request({ return request({
url: '/ecw/offer/dept/export-excel', url: "/ecw/offer/dept/export-excel",
method: 'get', method: "get",
params: query, params: query,
responseType: 'blob' responseType: "blob"
}) })
} }
// 报价单 // 报价单
export function getOfferSelect(params) { export function getOfferSelect(params) {
return request({ return request({
url: '/ecw/offer/select', url: "/ecw/offer/select",
method: 'get', method: "get",
params params
}) })
} }
// 报价单 // 报价单
export function getOfferCheck(params) { export function getOfferCheck(params) {
return request({ return request({
url: '/ecw/offer/check', url: "/ecw/offer/check",
method: 'get', method: "get",
params params
}) })
} }
\ No newline at end of file
// 特价详情
export function getOfferNumber(offerId) {
return request({
url: "/ecw/offer/getNumber/" + offerId,
method: "get"
})
}
This diff is collapsed.
import request from '@/utils/request' import request from "@/utils/request"
// 获得控货分页 // 获得控货分页
export function getCargoControlOrderPage(params){ export function getCargoControlOrderPage(params) {
return request({ return request({
url:'ecw/order-cargo-control/cargo/control/order', url: "ecw/order-cargo-control/cargo/control/order",
method:'get', method: "get",
params params
}) })
}
export function getWarningCargoControlOrderPage(params) {
return request({
url: "ecw/order-cargo-control/warning/cargo/control/order",
method: "get",
params
})
} }
// 发送手机验证码 // 发送手机验证码
export function sendSmsCode(data){ export function sendSmsCode(data) {
return request({ return request({
url: '/ecw/order-cargo-control/send-sms-code', url: "/ecw/order-cargo-control/send-sms-code",
method: 'post', method: "post",
data data
}) })
} }
// 创建订单控货人信息 // 创建订单控货人信息
export function create(data){ export function create(data) {
return request({ return request({
url: '/ecw/order-cargo-control/create', url: "/ecw/order-cargo-control/create",
method: 'post', method: "post",
data data
}) })
} }
// 创建订单控货人放货记录 // 创建订单控货人放货记录
export function createPick(data){ export function createPick(data) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/create', url: "/ecw/order-cargo-control-pick/create",
method: 'post', method: "post",
data data
}) })
} }
//获得控货订单放货编辑详情 //获得控货订单放货编辑详情
export function getReleaseInfo(orderId){ export function getReleaseInfo(orderId) {
return request({ return request({
url:'/ecw/order-cargo-control/release/info/' + orderId, url: "/ecw/order-cargo-control/release/info/" + orderId,
method:'get' method: "get"
}) })
} }
// 获得控货订单放货详情 // 获得控货订单放货详情
export function getPickRleaseInfo(orderId){ export function getPickRleaseInfo(orderId) {
return request({ return request({
url:'/ecw/order-cargo-control-pick/release/info/' + orderId, url: "/ecw/order-cargo-control-pick/release/info/" + orderId,
method:'get' method: "get"
}) })
} }
// 放货修改与反复核申请 // 放货修改与反复核申请
export function updateApply(data){ export function updateApply(data) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/update/apply', url: "/ecw/order-cargo-control-pick/update/apply",
method: 'put', method: "put",
data data
}) })
} }
// 复核(放货复核) // 复核(放货复核)
export function review(id){ export function review(id) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/review/' + id, url: "/ecw/order-cargo-control-pick/review/" + id,
method: 'put' method: "put"
}) })
} }
// 取消放货 // 取消放货
export function cancel(id){ export function cancel(id) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/cancel/' + id, url: "/ecw/order-cargo-control-pick/cancel/" + id,
method: 'put' method: "put"
}) })
} }
// 取消审批 // 取消审批
export function cancelApproval(approvalId, params){ export function cancelApproval(approvalId, params) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/cancel/approval/' + approvalId, url: "/ecw/order-cargo-control-pick/cancel/approval/" + approvalId,
method: 'get', method: "get",
params params
}) })
} }
// 订单复核 // 订单复核
export function orderReview(orderId){ export function orderReview(orderId) {
return request({ return request({
url: '/ecw/order-cargo-control/review/' + orderId, url: "/ecw/order-cargo-control/review/" + orderId,
method: 'put' method: "put"
}) })
} }
// 根据订单id批量复合订单控货人放货 // 根据订单id批量复合订单控货人放货
export function batchReview(data){ export function batchReview(data) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/review/', url: "/ecw/order-cargo-control-pick/review/",
method: 'put', method: "put",
headers: { headers: {
'Content-Type': 'application/x-www-form-urlencoded' "Content-Type": "application/x-www-form-urlencoded"
}, },
data data
}) })
} }
// 获得可调货的控货订单列表 // 获得可调货的控货订单列表
export function seasoningCondimentsSelect(params){ export function seasoningCondimentsSelect(params) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/seasoning-condiments/cargo-control/order/select', url: "/ecw/order-cargo-control-pick/seasoning-condiments/cargo-control/order/select",
method: 'get', method: "get",
params params
}) })
} }
// 根据放货ID查询控货订单放货修改审核详情 // 根据放货ID查询控货订单放货修改审核详情
export function getPickUpdateInfo(id){ export function getPickUpdateInfo(id) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/update/info/' + id, url: "/ecw/order-cargo-control-pick/update/info/" + id,
method: 'get' method: "get"
}) })
} }
// 获得控货订单放货修改申请详情 {approveId: 1} // 获得控货订单放货修改申请详情 {approveId: 1}
export function getPickUpdateApproveInfo(params){ export function getPickUpdateApproveInfo(params) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/update/info', url: "/ecw/order-cargo-control-pick/update/info",
method: 'get', method: "get",
params params
}) })
} }
export function getCondimentsIno(cargoControlPickId){ export function getCondimentsIno(cargoControlPickId) {
return request({ return request({
url: '/ecw/order-cargo-control-pick/seasoning/condiments/info/' + cargoControlPickId, url: "/ecw/order-cargo-control-pick/seasoning/condiments/info/" + cargoControlPickId,
method: 'get' method: "get"
}) })
} }
// 参数搜索导出控货订单列表 // 参数搜索导出控货订单列表
export function exportCargoControl(params){ export function exportCargoControl(params) {
return request({ return request({
url: '/ecw/order/export/cargo/control/search', url: "/ecw/order/export/cargo/control/search",
method: 'get', method: "get",
responseType: 'arraybuffer', responseType: "arraybuffer",
params params
}) })
} }
// 控货日志 // 控货日志
export function getControlLogList(orderId){ export function getControlLogList(orderId) {
return request({
url: "/order/order-control-log/list/" + orderId,
method: "get"
})
}
// 控货业务审批申请
export function applyCargoControlApproval(data) {
return request({
url: "ecw/order-cargo-control/update/apply",
method: "put",
data
})
}
//根据订单ID查询控货订单放货限制修改审核详情
export function getLimitUpdateInfo(orderId) {
return request({
url: "/ecw/order-cargo-control/limit-update/info/" + orderId,
method: "get"
})
}
//根据订单ID查询海外仓模式修改审核详情
export function getReleaseTypeUpdateInfo(orderId) {
return request({ return request({
url: '/order/order-control-log/list/' + orderId, url: "/ecw/order-cargo-control/overseas-warehouse-update/info/" + orderId,
method: 'get' method: "get"
}) })
} }
...@@ -115,3 +115,12 @@ export function listByIds(params){ ...@@ -115,3 +115,12 @@ export function listByIds(params){
params params
}) })
} }
// 检查国家区域是否与手机号国家区号一致
export function checkCountryCode(params){
return request({
url: 'ecw/region/check/dest-currency/area-code/',
method: 'get',
params
})
}
...@@ -141,3 +141,30 @@ export function quantityRequired(lineId) { ...@@ -141,3 +141,30 @@ export function quantityRequired(lineId) {
method: 'get' method: 'get'
}) })
} }
// 获取仓库区域并行国家、城市、仓库列表
export function getGuojiaAndShiAndWarehouseList(params = {}) {
return request({
url: '/ecw/warehouse/getGuojiaAndShiAndWarehouseList',
method: 'get',
params
})
}
// 出货阶段-追加申请
export function appendApplyWhenShipment(data) {
return request({
url: '/order/order-warehouse-in/append-apply-when-shipment',
method: 'post',
data
})
}
// 出货阶段-入仓修改申请
export function updateApplyWhenShipment(data) {
return request({
url: '/order/order-warehouse-in/update-apply-when-shipment',
method: 'put',
data
})
}
...@@ -42,6 +42,13 @@ export function listSimpleDepts() { ...@@ -42,6 +42,13 @@ export function listSimpleDepts() {
}) })
} }
export function listMySimpleDepts() {
return request({
url: '/system/dept/list-my-and-under-simple',
method: 'get'
})
}
// 新增部门 // 新增部门
export function addDept(data) { export function addDept(data) {
return request({ return request({
......
<template>
<el-select
v-model="valueSync"
filterable
:clearable="clearable"
:multiple="multiple"
remote
reserve-keyword
:placeholder="$t('请输入关键词')"
@change="(val) => $emit('change', val)"
:remote-method="remoteMethod"
@focus="onFocus"
@clear="onClear"
:loading="loading">
<el-option
v-for="(item, index) in list"
:key="item.id"
:label="`${item.name}`"
:value="index">
</el-option>
</el-select>
</template>
<script>
import {competitorListAll, getCompetitor} from '@/api/ecw/customer'
export default {
props: {
value: [String, Number, Array, Boolean],
multiple: Boolean,
clearable: Boolean,
placeholder: String,
},
data() {
return {
list: [],
loading: false,
valueSync: this.value
}
},
watch: {
index(val) {
let id = null
if (val){
let data = this.list[val]
console.log('选中的竞争对手', data)
id = data.id
}
// let id = val !== '' && val !== null ? this.list[val].id : null
this.$emit('input', id)
},
value(val) {
// console.log('初始化内容', val)
this.init()
},
},
created() {
this.init()
},
methods: {
init() {
if (!this.value) {
this.index = null
return
}
let index = this.list.findIndex(item => item.id == this.value)
if (index < 0) {
getCompetitor(this.value).then(res => {
this.list.unshift(res.data)
this.$nextTick(() => {
this.index = 0
})
})
} else this.index = index
},
onFocus() {
this.$emit('focus')
if (!this.list.length) {
this.remoteMethod()
}
},
onClear() {
this.list = []
},
remoteMethod(keyword) {
let params = {}
params.searchKey = keyword
this.loading = true
competitorListAll(params)
.then(res => {
console.log('初始化内容', res),
this.list = res.data
})
.finally(() => this.loading = false)
}
}
}
</script>
<template> <template>
<div class="dict-selector"> <div class="dict-selector">
<el-select v-if="formType == 'select'" v-model="valueSync" :placeholder="placeholder || $t('请选择')" :clearable="clearable" :multiple="multiple" :disabled="disabled" @change="val => $emit('change', val)"> <el-select
<el-option v-for="dict in formattedList" v-if="formType == 'select'"
:key="dict.value" :label="$l(dict, 'label')" :value="dict.value"/> v-model="valueSync"
</el-select> :placeholder="placeholder || $t('请选择')"
<el-radio-group v-if="formType == 'radio'" v-model="valueSync" :disabled="disabled"> :clearable="clearable"
<el-radio v-for="dict in formattedList" :label="dict.value" :checked="valueSync === dict.value" :key="dict.value">{{$l(dict, 'label')}}</el-radio> :multiple="multiple"
</el-radio-group> :disabled="disabled"
<el-checkbox-group v-if="formType == 'checkbox'" v-model="valueSync" :disabled="disabled"> @change="(val) => $emit('change', val)"
<el-checkbox v-for="dict in formattedList" :label="dict.value" :key="dict.value">{{$l(dict, 'label')}}</el-checkbox> >
</el-checkbox-group> <el-option
</div> v-for="dict in formattedList"
:key="dict.value"
:label="$l(dict, 'label')"
:value="dict.value"
/>
</el-select>
<el-radio-group
v-if="formType == 'radio'"
v-model="valueSync"
:disabled="disabled"
>
<el-radio
v-for="dict in formattedList"
:label="dict.value"
:checked="valueSync === dict.value"
:key="dict.value"
>{{ $l(dict, "label") }}</el-radio
>
</el-radio-group>
<el-checkbox-group
v-if="formType == 'checkbox'"
v-model="valueSync"
:disabled="disabled"
>
<el-checkbox
v-for="dict in formattedList"
:label="dict.value"
:key="dict.value"
>{{ $l(dict, "label") }}</el-checkbox
>
</el-checkbox-group>
</div>
</template> </template>
<script> <script>
const FORMATTERS = { const FORMATTERS = {
"string": String, string: String,
"bool": function(val){ bool: function (val) {
return [false, 'false', 0, "0"].indexOf(val) < 0 return [false, "false", 0, "0"].indexOf(val) < 0;
}, },
'number': Number, number: Number,
'array': function(val){ array: function (val) {
return typeof val == 'string' ? val.split(',').filter(item => item && item !== '') : val return typeof val == "string"
} ? val.split(",").filter((item) => item && item !== "")
} : val;
},
};
export default { export default {
props:{ props: {
placeholder: { placeholder: {
type: String, type: String,
default: null default: null,
},
type: String,
value: [String, Number, Array, Boolean],
multiple: Boolean,
formType:{
type: String,
default: 'select'
},
formatter: {
type: [Function, String],
default: String
},
defaultable: Boolean, // 是否默认选择第一个
disabled: Boolean,
/**
* 过滤字典项,用于只使用部分字典项的场景
*/
filter: {
type: Function,
default: () => true
},
clearable: Boolean
}, },
data(){ type: String,
return { value: [String, Number, Array, Boolean],
valueSync: this.multiple ? [] : null multiple: Boolean,
} formType: {
type: String,
default: "select",
}, },
computed:{ formatter: {
dicts(){ type: [Function, String],
return this.getList(this.type) default: String,
},
dictList(){
return this.dicts.filter(this.filter)
},
formattedList(){
let arr = []
this.dictList.forEach(item => {
arr.push({
label: item.label,
labelEn: item.labelEn,
value: this.format(item.value),
cssClass: item.cssClass,
colorType: item.colorType
})
})
return arr
}
}, },
watch:{ defaultable: Boolean, // 是否默认选择第一个
valueSync(val){ disabled: Boolean,
this.$emit('input', val) /**
}, * 过滤字典项,用于只使用部分字典项的场景
value(val){ */
if(val != this.valueSync)this.setValueSync() filter: {
}, type: Function,
dictList(){ default: () => true,
this.setDefault() },
} clearable: Boolean,
},
data() {
return {
valueSync: this.multiple ? [] : null,
};
},
computed: {
dicts() {
return this.getList(this.type);
},
dictList() {
return this.dicts.filter(this.filter);
},
formattedList() {
let arr = [];
this.dictList.forEach((item) => {
arr.push({
label: item.label,
labelEn: item.labelEn,
value: this.format(item.value),
cssClass: item.cssClass,
colorType: item.colorType,
});
});
return arr;
}, },
created(){ },
this.setValueSync() watch: {
this.setDefault() valueSync(val) {
this.$emit("input", val);
}, },
methods:{ value(val) {
format(val){ if (val != this.valueSync) this.setValueSync();
if(val === null || val == undefined || val == '') return val },
let formatter = typeof this.formatter == 'function' ? this.formatter : FORMATTERS[this.formatter] dictList() {
if(!formatter){ this.setDefault();
console.warn('格式器无效', this.formatter) },
return val },
} created() {
return formatter(val) this.setValueSync();
}, this.setDefault();
changeValue(val){ },
this.valueSync = val methods: {
}, format(val) {
setValueSync(){ if (val === null || val == undefined || val == "") return val;
if(this.value === null || this.value === undefined || this.value === ''){
return this.valueSync = this.multiple ? [] : this.value let formatter =
} typeof this.formatter == "function"
if(this.multiple){ ? this.formatter
let value = this.value || [] : FORMATTERS[this.formatter];
if(typeof this.value == 'string'){
value = this.value.split(',').filter(item => item && item != '') if (!formatter) {
} console.warn("格式器无效", this.formatter);
this.valueSync = value.map(item => this.format(item)) return val;
}else{ }
this.valueSync = this.format(this.value)
} return formatter(val);
}, },
getList(){ changeValue(val) {
return this.getDictDatas(this.type) this.valueSync = val;
}, },
setDefault(){ setValueSync() {
if(!this.defaultable) return if (
if(this.dictList.length && (this.valueSync === null || this.valueSync == undefined || this.valueSync == '')){ this.value === null ||
this.valueSync = this.multiple ? [] : this.formattedList[0].value this.value === undefined ||
} this.value === ""
) {
return (this.valueSync = this.multiple ? [] : this.value);
}
if (this.multiple) {
let value = this.value || [];
if (typeof this.value == "string") {
value = this.value.split(",").filter((item) => item && item != "");
} }
} this.valueSync = value.map((item) => this.format(item));
} } else {
this.valueSync = this.format(this.value);
}
},
getList() {
return this.getDictDatas(this.type);
},
setDefault() {
if (!this.defaultable) return;
if (
this.dictList.length &&
(this.valueSync === null ||
this.valueSync == undefined ||
this.valueSync == "")
) {
this.valueSync = this.multiple ? [] : this.formattedList[0].value;
}
},
},
};
</script> </script>
<style scoped> <style scoped>
.dict-selector{ .dict-selector {
display: inline-block; display: inline-block;
} }
</style> </style>
<template>
<div class="upload-file">
<el-upload multiple :action="uploadFileUrl" :before-upload="handleBeforeUpload" :file-list="fileList" :limit="limit" :disabled="disabled" :on-error="handleUploadError" :on-exceed="handleExceed" :on-success="handleUploadSuccess" :show-file-list="false" :headers="headers" class="upload-file-uploader" ref="upload">
<!-- 上传按钮 -->
<el-button size="mini" type="primary" :disabled="disabled">{{ $t("选取文件") }}</el-button>
<!-- 上传提示 -->
<div class="el-upload__tip" slot="tip" v-if="showTip">
请上传
<template v-if="fileSize">
大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b>
</template>
<template v-if="fileType">
格式为 <b style="color: #f56c6c">{{ fileType.join("/") }}</b>
</template>
的文件
</div>
</el-upload>
<!-- 文件列表 -->
<transition-group class="upload-file-list el-upload-list el-upload-list--text" name="el-fade-in-linear" tag="ul">
<li :key="index" v-for="(file, index) in fileList">
<div class="imgItem" v-if="checkFileIsImage(file.url)">
<el-image style="width: 200px; height: 100px" :src="file.url" :preview-src-list="[file.url]"> </el-image>
<div class="ele-upload-list__item-content-action">
<el-button size="mini" type="danger" :disabled="disabled" @click="handleDelete(index)">删除</el-button>
</div>
</div>
<div class="el-upload-list__item ele-upload-list__item-content" v-else>
<el-link :href="`${file.url}`" :underline="false" target="_blank">
<span class="el-icon-document"> {{ getFileName(file.name) }} </span>
</el-link>
<div class="ele-upload-list__item-content-action">
<el-button size="mini" type="danger" :disabled="disabled" @click="handleDelete(index)">删除</el-button>
</div>
</div>
</li>
</transition-group>
</div>
</template>
<script>
import { getToken } from "@/utils/auth"
export default {
name: "FileUpload",
props: {
// 值
value: [String, Object, Array],
// 数量限制
limit: {
type: Number,
default: 5
},
// 大小限制(MB)
fileSize: {
type: Number,
default: 5
},
// 文件类型, 例如['png', 'jpg', 'jpeg']
fileType: {
type: Array,
default: () => ["doc", "xls", "ppt", "txt", "pdf"]
},
disabled: {
type: Boolean,
default: false
},
// 是否显示提示
isShowTip: {
type: Boolean,
default: true
}
},
data() {
return {
number: 0,
uploadList: [],
baseUrl: process.env.VUE_APP_BASE_API,
uploadFileUrl: process.env.VUE_APP_BASE_API + "/admin-api/infra/file/upload", // 上传的文件服务器地址
headers: {
Authorization: "Bearer " + getToken()
},
fileList: []
}
},
watch: {
value: {
handler(val) {
if (val) {
let temp = 1
// 首先将值转为数组
const list = Array.isArray(val) ? val : this.value.split(",")
// 然后将数组转为对象数组
this.fileList = list.map((item) => {
if (typeof item === "string") {
item = { name: item, url: item }
}
item.uid = item.uid || new Date().getTime() + temp++
return item
})
} else {
this.fileList = []
return []
}
},
deep: true,
immediate: true
}
},
computed: {
// 是否显示提示
showTip() {
return this.isShowTip && (this.fileType || this.fileSize)
}
},
methods: {
// 上传前校检格式和大小
handleBeforeUpload(file) {
// 校检文件类型
if (this.fileType) {
let fileExtension = ""
if (file.name.lastIndexOf(".") > -1) {
fileExtension = file.name.slice(file.name.lastIndexOf(".") + 1).toLowerCase()
}
const isTypeOk = this.fileType.some((type) => {
if (file.type.indexOf(type) > -1) return true
if (fileExtension && fileExtension.indexOf(type) > -1) return true
return false
})
if (!isTypeOk) {
this.$modal.msgError(`文件格式不正确, 请上传${this.fileType.join("/")}格式文件!`)
return false
}
}
// 校检文件大小
if (this.fileSize) {
const isLt = file.size / 1024 / 1024 < this.fileSize
if (!isLt) {
this.$modal.msgError(`上传文件大小不能超过 ${this.fileSize} MB!`)
return false
}
}
this.$modal.loading("正在上传文件,请稍候...")
this.number++
return true
},
// 文件个数超出
handleExceed() {
this.$modal.msgError(`上传文件数量不能超过 ${this.limit} 个!`)
},
// 上传失败
handleUploadError(err) {
this.$modal.msgError("上传文件失败,请重试")
this.$modal.closeLoading()
},
// 上传成功回调
handleUploadSuccess(res) {
// todo 接口返回值没有文件名
this.uploadList.push({ name: res.data, url: res.data })
if (this.uploadList.length === this.number) {
this.fileList = this.fileList.concat(this.uploadList)
this.uploadList = []
this.number = 0
this.$emit("input", this.listToString(this.fileList))
this.$modal.closeLoading()
}
},
// 删除文件
handleDelete(index) {
this.fileList.splice(index, 1)
this.$emit("input", this.listToString(this.fileList))
},
// 获取文件名称
getFileName(name) {
if (name.lastIndexOf("/") > -1) {
return name.slice(name.lastIndexOf("/") + 1)
} else {
return ""
}
},
// 对象转成指定字符串分隔
listToString(list, separator) {
let strs = ""
separator = separator || ","
for (let i in list) {
strs += list[i].url + separator
}
return strs != "" ? strs.substr(0, strs.length - 1) : ""
},
checkFileIsImage(filePath) {
const fileExtension = filePath.slice(filePath.lastIndexOf(".") + 1).toLowerCase()
const fileTypes = ["png", "jpg", "jpeg", "gif"]
if (fileTypes.includes(fileExtension)) {
return true
}
return false
}
}
}
</script>
<style scoped lang="scss">
.upload-file-uploader {
margin-bottom: 5px;
}
.upload-file-list .el-upload-list__item {
border: 1px solid #e4e7ed;
line-height: 2;
margin-bottom: 10px;
position: relative;
}
.upload-file-list .ele-upload-list__item-content {
display: flex;
justify-content: space-between;
align-items: center;
color: inherit;
}
.ele-upload-list__item-content-action .el-link {
margin-right: 10px;
}
.imgItem {
display: flex;
align-items: center;
}
</style>
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
:before-upload="handleBeforeUpload" :before-upload="handleBeforeUpload"
:file-list="fileList" :file-list="fileList"
:limit="limit" :limit="limit"
:disabled="disabled"
:on-error="handleUploadError" :on-error="handleUploadError"
:on-exceed="handleExceed" :on-exceed="handleExceed"
:on-success="handleUploadSuccess" :on-success="handleUploadSuccess"
...@@ -15,24 +16,40 @@ ...@@ -15,24 +16,40 @@
ref="upload" ref="upload"
> >
<!-- 上传按钮 --> <!-- 上传按钮 -->
<el-button size="mini" type="primary">{{$t('选取文件')}}</el-button> <el-button size="mini" type="primary" :disabled="disabled">{{
$t("选取文件")
}}</el-button>
<!-- 上传提示 --> <!-- 上传提示 -->
<div class="el-upload__tip" slot="tip" v-if="showTip"> <div class="el-upload__tip" slot="tip" v-if="showTip">
请上传 请上传
<template v-if="fileSize"> 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b> </template> <template v-if="fileSize">
<template v-if="fileType"> 格式为 <b style="color: #f56c6c">{{ fileType.join("/") }}</b> </template> 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b>
</template>
<template v-if="fileType">
格式为 <b style="color: #f56c6c">{{ fileType.join("/") }}</b>
</template>
的文件 的文件
</div> </div>
</el-upload> </el-upload>
<!-- 文件列表 --> <!-- 文件列表 -->
<transition-group class="upload-file-list el-upload-list el-upload-list--text" name="el-fade-in-linear" tag="ul"> <transition-group
<li :key="file.url" class="el-upload-list__item ele-upload-list__item-content" v-for="(file, index) in fileList"> class="upload-file-list el-upload-list el-upload-list--text"
name="el-fade-in-linear"
tag="ul"
>
<li
:key="file.url"
class="el-upload-list__item ele-upload-list__item-content"
v-for="(file, index) in fileList"
>
<el-link :href="`${file.url}`" :underline="false" target="_blank"> <el-link :href="`${file.url}`" :underline="false" target="_blank">
<span class="el-icon-document"> {{ getFileName(file.name) }} </span> <span class="el-icon-document"> {{ getFileName(file.name) }} </span>
</el-link> </el-link>
<div class="ele-upload-list__item-content-action"> <div class="ele-upload-list__item-content-action">
<el-link :underline="false" @click="handleDelete(index)" type="danger">删除</el-link> <el-link :underline="false" @click="handleDelete(index)" type="danger"
>删除</el-link
>
</div> </div>
</li> </li>
</transition-group> </transition-group>
...@@ -62,18 +79,22 @@ export default { ...@@ -62,18 +79,22 @@ export default {
type: Array, type: Array,
default: () => ["doc", "xls", "ppt", "txt", "pdf"], default: () => ["doc", "xls", "ppt", "txt", "pdf"],
}, },
disabled: {
type: Boolean,
default: false,
},
// 是否显示提示 // 是否显示提示
isShowTip: { isShowTip: {
type: Boolean, type: Boolean,
default: true default: true,
} },
}, },
data() { data() {
return { return {
number: 0, number: 0,
uploadList: [], uploadList: [],
baseUrl: process.env.VUE_APP_BASE_API, baseUrl: process.env.VUE_APP_BASE_API,
uploadFileUrl: process.env.VUE_APP_BASE_API + "/admin-api/infra/file/org-name/up", // 上传的文件服务器地址 uploadFileUrl: process.env.VUE_APP_BASE_API + "/admin-api/infra/file/upload", // 上传的文件服务器地址
headers: { headers: {
Authorization: "Bearer " + getToken(), Authorization: "Bearer " + getToken(),
}, },
...@@ -86,9 +107,9 @@ export default { ...@@ -86,9 +107,9 @@ export default {
if (val) { if (val) {
let temp = 1; let temp = 1;
// 首先将值转为数组 // 首先将值转为数组
const list = Array.isArray(val) ? val : this.value.split(','); const list = Array.isArray(val) ? val : this.value.split(",");
// 然后将数组转为对象数组 // 然后将数组转为对象数组
this.fileList = list.map(item => { this.fileList = list.map((item) => {
if (typeof item === "string") { if (typeof item === "string") {
item = { name: item, url: item }; item = { name: item, url: item };
} }
...@@ -101,8 +122,8 @@ export default { ...@@ -101,8 +122,8 @@ export default {
} }
}, },
deep: true, deep: true,
immediate: true immediate: true,
} },
}, },
computed: { computed: {
// 是否显示提示 // 是否显示提示
...@@ -117,7 +138,9 @@ export default { ...@@ -117,7 +138,9 @@ export default {
if (this.fileType) { if (this.fileType) {
let fileExtension = ""; let fileExtension = "";
if (file.name.lastIndexOf(".") > -1) { if (file.name.lastIndexOf(".") > -1) {
fileExtension = file.name.slice(file.name.lastIndexOf(".") + 1).toLowerCase(); fileExtension = file.name
.slice(file.name.lastIndexOf(".") + 1)
.toLowerCase();
} }
const isTypeOk = this.fileType.some((type) => { const isTypeOk = this.fileType.some((type) => {
if (file.type.indexOf(type) > -1) return true; if (file.type.indexOf(type) > -1) return true;
...@@ -125,7 +148,9 @@ export default { ...@@ -125,7 +148,9 @@ export default {
return false; return false;
}); });
if (!isTypeOk) { if (!isTypeOk) {
this.$modal.msgError(`文件格式不正确, 请上传${this.fileType.join("/")}格式文件!`); this.$modal.msgError(
`文件格式不正确, 请上传${this.fileType.join("/")}格式文件!`
);
return false; return false;
} }
} }
...@@ -148,7 +173,7 @@ export default { ...@@ -148,7 +173,7 @@ export default {
// 上传失败 // 上传失败
handleUploadError(err) { handleUploadError(err) {
this.$modal.msgError("上传图片失败,请重试"); this.$modal.msgError("上传图片失败,请重试");
this.$modal.closeLoading() this.$modal.closeLoading();
}, },
// 上传成功回调 // 上传成功回调
handleUploadSuccess(res) { handleUploadSuccess(res) {
...@@ -182,9 +207,9 @@ export default { ...@@ -182,9 +207,9 @@ export default {
for (let i in list) { for (let i in list) {
strs += list[i].url + separator; strs += list[i].url + separator;
} }
return strs != '' ? strs.substr(0, strs.length - 1) : ''; return strs != "" ? strs.substr(0, strs.length - 1) : "";
} },
} },
}; };
</script> </script>
......
This diff is collapsed.
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<el-select v-model="queryParams.attrId" :placeholder="$t('选择属性')" style="width:120px" clearable @change="getList" :disabled="loading"> <el-select v-model="queryParams.attrId" :placeholder="$t('选择属性')" style="width:120px" clearable @change="getList" :disabled="loading">
<el-option v-for="item in attrList" :key="item.id" :label="item.attrName" :value="item.id" /> <el-option v-for="item in attrList" :key="item.id" :label="item.attrName" :value="item.id" />
</el-select> </el-select>
<el-input v-model="queryParams.titleZh" :placeholder="$t('产品关键字')" style="width:120px" clearable :disabled="loading"/> <el-input v-model="queryParams.titleZh" :placeholder="$t('产品关键字')" style="width:120px" clearable onkeyup="this.value=this.value.replace(/\s+/g, '')" :disabled="loading"/>
<el-button type="primary" @click="reLoad" :loading="loading">{{$t('搜索')}}</el-button> <el-button type="primary" @click="reLoad" :loading="loading">{{$t('搜索')}}</el-button>
<div style="height: 36px; display: flex; align-items: center"> <div style="height: 36px; display: flex; align-items: center">
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
<el-select v-model="selectedFilterParams.attrId" :placeholder="$t('选择属性')" style="width:120px" clearable :disabled="loading"> <el-select v-model="selectedFilterParams.attrId" :placeholder="$t('选择属性')" style="width:120px" clearable :disabled="loading">
<el-option v-for="item in attrList" :key="item.id" :label="item.attrName" :value="item.id" /> <el-option v-for="item in attrList" :key="item.id" :label="item.attrName" :value="item.id" />
</el-select> </el-select>
<el-input v-model="selectedFilterParams.titleZh" :placeholder="$t('产品关键字')" style="width:120px" clearable :disabled="loading"/> <el-input v-model="selectedFilterParams.titleZh" :placeholder="$t('产品关键字')" style="width:120px" clearable onkeyup="this.value=this.value.replace(/\s+/g, '')" :disabled="loading"/>
<!--<el-button type="primary" @click="reLoad" :loading="loading">{{$t('搜索')}}</el-button>--> <!--<el-button type="primary" @click="reLoad" :loading="loading">{{$t('搜索')}}</el-button>-->
<div class="flex"> <div class="flex">
......
...@@ -60,6 +60,7 @@ ...@@ -60,6 +60,7 @@
<script> <script>
import {createCustomer} from '@/api/ecw/customer' import {createCustomer} from '@/api/ecw/customer'
import {DICT_TYPE} from "@/utils/dict";
import {listServiceUser} from "@/api/system/user" import {listServiceUser} from "@/api/system/user"
import { getCountryListAll } from '@/api/ecw/country' import { getCountryListAll } from '@/api/ecw/country'
import {getCustomerContactsSelect} from '@/api/ecw/customerContacts' import {getCustomerContactsSelect} from '@/api/ecw/customerContacts'
...@@ -74,7 +75,7 @@ export default { ...@@ -74,7 +75,7 @@ export default {
data(){ data(){
return { return {
show: true, show: true,
DICT_TYPE,
// 表单参数 // 表单参数
form: { form: {
customerContacts:[{isDefault: 1}] customerContacts:[{isDefault: 1}]
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div class="top-right-btn"> <div class="top-right-btn">
<el-row> <el-row>
<el-tooltip class="item" effect="dark" :content="showSearch ? $t('隐藏搜索') : $t('显示搜索')" placement="top"> <el-tooltip class="item" effect="dark" :content="showSearch ? $t('隐藏搜索') : $t('显示搜索')" placement="top">
<el-button size="mini" circle icon="el-icon-search" @click="toggleSearch()" /> <el-button type="text" size="mini" circle icon="el-icon-search" @click="toggleSearch()" >{{showSearch ? $t('隐藏搜索') : $t('显示搜索')}}</el-button>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" effect="dark" :content="$t('刷新')" placement="top"> <el-tooltip class="item" effect="dark" :content="$t('刷新')" placement="top">
<el-button size="mini" circle icon="el-icon-refresh" @click="refresh()" /> <el-button size="mini" circle icon="el-icon-refresh" @click="refresh()" />
......
This diff is collapsed.
...@@ -12,7 +12,7 @@ export default { ...@@ -12,7 +12,7 @@ export default {
}, },
props:{ props:{
options: Array, options: Array,
value: [String, Number, Boolean, Object], value: [String, Number, Array, Boolean, Object],
labelField: { labelField: {
type: [String, Function], type: [String, Function],
default: 'label' default: 'label'
......
...@@ -3,9 +3,11 @@ ...@@ -3,9 +3,11 @@
v-model="valueSync" v-model="valueSync"
filterable filterable
:clearable="clearable" :clearable="clearable"
:multiple="multiple"
remote remote
reserve-keyword reserve-keyword
:placeholder="placeholder ? placeholder : $t('请选择')" :placeholder="placeholder ? placeholder : $t('请选择')"
@change="(val) => $emit('change', val)"
:loading="loading"> :loading="loading">
<el-option <el-option
v-if="prepend" v-if="prepend"
...@@ -25,7 +27,8 @@ import {getCustomerContactsSelect, getCustomerContacts} from '@/api/ecw/customer ...@@ -25,7 +27,8 @@ import {getCustomerContactsSelect, getCustomerContacts} from '@/api/ecw/customer
import {listServiceUser, listSimpleUsers} from '@/api/system/user' import {listServiceUser, listSimpleUsers} from '@/api/system/user'
export default { export default {
props:{ props:{
value: [String, Number], value: [String, Number, Array, Boolean],
multiple: Boolean,
clearable: Boolean, clearable: Boolean,
placeholder: String, placeholder: String,
manage:{ manage:{
......
...@@ -4,6 +4,7 @@ import dialogDrag from './dialog/drag' ...@@ -4,6 +4,7 @@ import dialogDrag from './dialog/drag'
import dialogDragWidth from './dialog/dragWidth' import dialogDragWidth from './dialog/dragWidth'
import dialogDragHeight from './dialog/dragHeight' import dialogDragHeight from './dialog/dragHeight'
import clipboard from './module/clipboard' import clipboard from './module/clipboard'
import trim from "./trim/trim";
const install = function(Vue) { const install = function(Vue) {
Vue.directive('hasRole', hasRole) Vue.directive('hasRole', hasRole)
...@@ -12,6 +13,7 @@ const install = function(Vue) { ...@@ -12,6 +13,7 @@ const install = function(Vue) {
Vue.directive('dialogDrag', dialogDrag) Vue.directive('dialogDrag', dialogDrag)
Vue.directive('dialogDragWidth', dialogDragWidth) Vue.directive('dialogDragWidth', dialogDragWidth)
Vue.directive('dialogDragHeight', dialogDragHeight) Vue.directive('dialogDragHeight', dialogDragHeight)
Vue.directive("trim", trim)
} }
if (window.Vue) { if (window.Vue) {
......
// 获取元素
function getInput(el) {
let inputEle;
if (el.tagName !== "INPUT") {
// 若 el-input 中 type 为 textarea
if (el._prevClass.includes("el-textarea")) {
inputEle = el.querySelector("textarea");
} else {
inputEle = el.querySelector("input");
}
} else {
inputEle = el;
}
return inputEle;
}
function dispatchEvent(el, type) {
const evt = new Event(type);
el.dispatchEvent(evt);
}
const Trim = {
inserted: (el) => {
let inputEle = getInput(el);
const handler = function (event) {
const newVal = event.target.value.trim();
if (event.target.value !== newVal) {
event.target.value = newVal;
dispatchEvent(inputEle, "input");
}
};
el.inputEle = inputEle;
el._blurHandler = handler;
inputEle.addEventListener("blur", handler);
},
unbind(el) {
const { inputEle } = el;
inputEle.removeEventListener("blur", el._blurHandler);
},
};
export default Trim;
This diff is collapsed.
...@@ -292,5 +292,37 @@ ...@@ -292,5 +292,37 @@
"立方数(CBM)": "立方数(CBM)", "立方数(CBM)": "立方数(CBM)",
"选取文件": "选取文件", "选取文件": "选取文件",
"查看提单 {selfNo} 柜号:{cubNo} 柜型:{cabinetLabel}": "查看提单 {selfNo} 柜号:{cubNo} 柜型:{cabinetLabel}", "查看提单 {selfNo} 柜号:{cubNo} 柜型:{cabinetLabel}": "查看提单 {selfNo} 柜号:{cubNo} 柜型:{cabinetLabel}",
"退仓/已混箱品名":"退仓/已混箱品名" "退仓/已混箱品名":"退仓/已混箱品名",
"基本":"基本",
"发货信息": "发货信息",
"设置": "设置",
"财务": "财务",
"开票信息": "开票信息",
"国籍":"国籍",
"首次成交时间": "首次成交时间",
"掉入公海时间": "掉入公海时间",
"获取方式": "获取方式",
"创建入口": "创建入口",
"捞取时间": "捞取时间",
"归属时间": "归属时间",
"业务国家": "业务国家",
"年度发货量": "年度发货量",
"年度发货次数": "年度发货次数",
"主要竞争对手": "主要竞争对手",
"控货无收货人": "控货无收货人",
"默认付款": "默认付款",
"默认开票": "默认开票",
"请选择业务国家": "请选择业务国家",
"请选择主要竞争对手": "请选择主要竞争对手",
"请重新选择主要竞争对手": "请重新选择主要竞争对手",
"装柜/出仓时间": "装柜/出仓时间",
"卸柜/到仓时间": "卸柜/到仓时间",
"提货率": "提货率",
"业绩归属客户方": "业绩归属客户方",
"发货评估": "发货评估",
"财务资料": "财务资料",
"特殊设置": "特殊设置",
"已卸柜/已到仓时间": "已卸柜/已到仓时间",
"动态": "动态",
"增值服务": "增值服务"
} }
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
<script> <script>
export default { export default {
name: 'AppMain', name: "AppMain",
computed: { computed: {
cachedViews() { cachedViews() {
return this.$store.state.tagsView.cachedViews return this.$store.state.tagsView.cachedViews
...@@ -31,7 +31,7 @@ export default { ...@@ -31,7 +31,7 @@ export default {
overflow: hidden; overflow: hidden;
} }
.fixed-header+.app-main { .fixed-header + .app-main {
padding-top: 50px; padding-top: 50px;
} }
...@@ -41,7 +41,7 @@ export default { ...@@ -41,7 +41,7 @@ export default {
min-height: calc(100vh - 84px); min-height: calc(100vh - 84px);
} }
.fixed-header+.app-main { .fixed-header + .app-main {
padding-top: 84px; padding-top: 84px;
} }
} }
......
<template> <template>
<div id="tags-view-container" class="tags-view-container"> <div id="tags-view-container" class="tags-view-container">
<scroll-pane ref="scrollPane" class="tags-view-wrapper" @scroll="handleScroll"> <scroll-pane ref="scrollPane" class="tags-view-wrapper" @scroll="handleScroll">
<router-link <router-link v-for="tag in visitedViews" ref="tag" :key="tag.path" :class="isActive(tag) ? 'active' : ''" :to="{ path: tag.path, query: tag.query, fullPath: tag.fullPath }" tag="span" class="tags-view-item" :style="activeStyle(tag)" @click.middle.native="!isAffix(tag) ? closeSelectedTag(tag) : ''" @contextmenu.prevent.native="openMenu(tag, $event)">
v-for="tag in visitedViews" {{ $l(tag.meta, "title") }}
ref="tag"
:key="tag.path"
:class="isActive(tag)?'active':''"
:to="{ path: tag.path, query: tag.query, fullPath: tag.fullPath }"
tag="span"
class="tags-view-item"
:style="activeStyle(tag)"
@click.middle.native="!isAffix(tag)?closeSelectedTag(tag):''"
@contextmenu.prevent.native="openMenu(tag,$event)"
>
{{ $l(tag.meta, 'title') }}
<span v-if="!isAffix(tag)" class="el-icon-close" @click.prevent.stop="closeSelectedTag(tag)" /> <span v-if="!isAffix(tag)" class="el-icon-close" @click.prevent.stop="closeSelectedTag(tag)" />
</router-link> </router-link>
</scroll-pane> </scroll-pane>
<ul v-show="visible" :style="{left:left+'px',top:top+'px'}" class="contextmenu"> <ul v-show="visible" :style="{ left: left + 'px', top: top + 'px' }" class="contextmenu">
<li @click="refreshSelectedTag(selectedTag)"><i class="el-icon-refresh-right"></i> 刷新页面</li> <li @click="refreshSelectedTag(selectedTag)"><i class="el-icon-refresh-right"></i> 刷新页面</li>
<li v-if="!isAffix(selectedTag)" @click="closeSelectedTag(selectedTag)"><i class="el-icon-close"></i> 关闭当前</li> <li v-if="!isAffix(selectedTag)" @click="closeSelectedTag(selectedTag)"><i class="el-icon-close"></i> 关闭当前</li>
<li @click="closeOthersTags"><i class="el-icon-circle-close"></i> 关闭其他</li> <li @click="closeOthersTags"><i class="el-icon-circle-close"></i> 关闭其他</li>
...@@ -29,8 +18,8 @@ ...@@ -29,8 +18,8 @@
</template> </template>
<script> <script>
import ScrollPane from './ScrollPane' import ScrollPane from "./ScrollPane"
import path from 'path' import path from "path"
export default { export default {
components: { ScrollPane }, components: { ScrollPane },
...@@ -51,7 +40,7 @@ export default { ...@@ -51,7 +40,7 @@ export default {
return this.$store.state.permission.routes return this.$store.state.permission.routes
}, },
theme() { theme() {
return this.$store.state.settings.theme; return this.$store.state.settings.theme
} }
}, },
watch: { watch: {
...@@ -62,9 +51,9 @@ export default { ...@@ -62,9 +51,9 @@ export default {
}, },
visible(value) { visible(value) {
if (value) { if (value) {
document.body.addEventListener('click', this.closeMenu) document.body.addEventListener("click", this.closeMenu)
} else { } else {
document.body.removeEventListener('click', this.closeMenu) document.body.removeEventListener("click", this.closeMenu)
} }
} }
}, },
...@@ -77,18 +66,18 @@ export default { ...@@ -77,18 +66,18 @@ export default {
return route.path === this.$route.path return route.path === this.$route.path
}, },
activeStyle(tag) { activeStyle(tag) {
if (!this.isActive(tag)) return {}; if (!this.isActive(tag)) return {}
return { return {
"background-color": this.theme, "background-color": this.theme,
"border-color": this.theme "border-color": this.theme
}; }
}, },
isAffix(tag) { isAffix(tag) {
return tag.meta && tag.meta.affix return tag.meta && tag.meta.affix
}, },
isFirstView() { isFirstView() {
try { try {
return this.selectedTag.fullPath === this.visitedViews[1].fullPath || this.selectedTag.fullPath === '/index' return this.selectedTag.fullPath === this.visitedViews[1].fullPath || this.selectedTag.fullPath === "/index"
} catch (err) { } catch (err) {
return false return false
} }
...@@ -100,9 +89,9 @@ export default { ...@@ -100,9 +89,9 @@ export default {
return false return false
} }
}, },
filterAffixTags(routes, basePath = '/') { filterAffixTags(routes, basePath = "/") {
let tags = [] let tags = []
routes.forEach(route => { routes.forEach((route) => {
if (route.meta && route.meta.affix) { if (route.meta && route.meta.affix) {
const tagPath = path.resolve(basePath, route.path) const tagPath = path.resolve(basePath, route.path)
tags.push({ tags.push({
...@@ -122,18 +111,18 @@ export default { ...@@ -122,18 +111,18 @@ export default {
return tags return tags
}, },
initTags() { initTags() {
const affixTags = this.affixTags = this.filterAffixTags(this.routes) const affixTags = (this.affixTags = this.filterAffixTags(this.routes))
for (const tag of affixTags) { for (const tag of affixTags) {
// Must have tag name // Must have tag name
if (tag.name) { if (tag.name) {
this.$store.dispatch('tagsView/addVisitedView', tag) this.$store.dispatch("tagsView/addVisitedView", tag)
} }
} }
}, },
addTags() { addTags() {
const { name } = this.$route const { name } = this.$route
if (name) { if (name) {
this.$store.dispatch('tagsView/addView', this.$route) this.$store.dispatch("tagsView/addView", this.$route)
} }
return false return false
}, },
...@@ -145,7 +134,7 @@ export default { ...@@ -145,7 +134,7 @@ export default {
this.$refs.scrollPane.moveToTarget(tag) this.$refs.scrollPane.moveToTarget(tag)
// when query is different then update // when query is different then update
if (tag.to.fullPath !== this.$route.fullPath) { if (tag.to.fullPath !== this.$route.fullPath) {
this.$store.dispatch('tagsView/updateVisitedView', this.$route) this.$store.dispatch("tagsView/updateVisitedView", this.$route)
} }
break break
} }
...@@ -153,45 +142,45 @@ export default { ...@@ -153,45 +142,45 @@ export default {
}) })
}, },
refreshSelectedTag(view) { refreshSelectedTag(view) {
this.$store.dispatch('tagsView/delCachedView', view).then(() => { this.$store.dispatch("tagsView/delCachedView", view).then(() => {
const { fullPath } = view const { fullPath } = view
this.$nextTick(() => { this.$nextTick(() => {
this.$router.replace({ this.$router.replace({
path: '/redirect' + fullPath path: "/redirect" + fullPath
}) })
}) })
}) })
}, },
closeSelectedTag(view) { closeSelectedTag(view) {
this.$store.dispatch('tagsView/delView', view).then(({ visitedViews }) => { this.$store.dispatch("tagsView/delView", view).then(({ visitedViews }) => {
if (this.isActive(view)) { if (this.isActive(view)) {
this.toLastView(visitedViews, view) this.toLastView(visitedViews, view)
} }
}) })
}, },
closeRightTags() { closeRightTags() {
this.$store.dispatch('tagsView/delRightTags', this.selectedTag).then(visitedViews => { this.$store.dispatch("tagsView/delRightTags", this.selectedTag).then((visitedViews) => {
if (!visitedViews.find(i => i.fullPath === this.$route.fullPath)) { if (!visitedViews.find((i) => i.fullPath === this.$route.fullPath)) {
this.toLastView(visitedViews) this.toLastView(visitedViews)
} }
}) })
}, },
closeLeftTags() { closeLeftTags() {
this.$store.dispatch('tagsView/delLeftTags', this.selectedTag).then(visitedViews => { this.$store.dispatch("tagsView/delLeftTags", this.selectedTag).then((visitedViews) => {
if (!visitedViews.find(i => i.fullPath === this.$route.fullPath)) { if (!visitedViews.find((i) => i.fullPath === this.$route.fullPath)) {
this.toLastView(visitedViews) this.toLastView(visitedViews)
} }
}) })
}, },
closeOthersTags() { closeOthersTags() {
this.$router.push(this.selectedTag).catch(()=>{}); this.$router.push(this.selectedTag).catch(() => {})
this.$store.dispatch('tagsView/delOthersViews', this.selectedTag).then(() => { this.$store.dispatch("tagsView/delOthersViews", this.selectedTag).then(() => {
this.moveToCurrentTag() this.moveToCurrentTag()
}) })
}, },
closeAllTags(view) { closeAllTags(view) {
this.$store.dispatch('tagsView/delAllViews').then(({ visitedViews }) => { this.$store.dispatch("tagsView/delAllViews").then(({ visitedViews }) => {
if (this.affixTags.some(tag => tag.path === this.$route.path)) { if (this.affixTags.some((tag) => tag.path === this.$route.path)) {
return return
} }
this.toLastView(visitedViews, view) this.toLastView(visitedViews, view)
...@@ -204,11 +193,11 @@ export default { ...@@ -204,11 +193,11 @@ export default {
} else { } else {
// now the default is to redirect to the home page if there is no tags-view, // now the default is to redirect to the home page if there is no tags-view,
// you can adjust it according to your needs. // you can adjust it according to your needs.
if (view.name === 'Dashboard') { if (view.name === "Dashboard") {
// to reload home page // to reload home page
this.$router.replace({ path: '/redirect' + view.fullPath }) this.$router.replace({ path: "/redirect" + view.fullPath })
} else { } else {
this.$router.push('/') this.$router.push("/")
} }
} }
}, },
...@@ -245,7 +234,7 @@ export default { ...@@ -245,7 +234,7 @@ export default {
width: 100%; width: 100%;
background: #fff; background: #fff;
border-bottom: 1px solid #d8dce5; border-bottom: 1px solid #d8dce5;
box-shadow: 0 1px 3px 0 rgba(0, 0, 0, .12), 0 0 3px 0 rgba(0, 0, 0, .04); box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 0 3px 0 rgba(0, 0, 0, 0.04);
.tags-view-wrapper { .tags-view-wrapper {
.tags-view-item { .tags-view-item {
display: inline-block; display: inline-block;
...@@ -271,7 +260,7 @@ export default { ...@@ -271,7 +260,7 @@ export default {
color: #fff; color: #fff;
border-color: #42b983; border-color: #42b983;
&::before { &::before {
content: ''; content: "";
background: #fff; background: #fff;
display: inline-block; display: inline-block;
width: 8px; width: 8px;
...@@ -294,7 +283,7 @@ export default { ...@@ -294,7 +283,7 @@ export default {
font-size: 12px; font-size: 12px;
font-weight: 400; font-weight: 400;
color: #333; color: #333;
box-shadow: 2px 2px 3px 0 rgba(0, 0, 0, .3); box-shadow: 2px 2px 3px 0 rgba(0, 0, 0, 0.3);
li { li {
margin: 0; margin: 0;
padding: 7px 16px; padding: 7px 16px;
...@@ -317,10 +306,10 @@ export default { ...@@ -317,10 +306,10 @@ export default {
vertical-align: 2px; vertical-align: 2px;
border-radius: 50%; border-radius: 50%;
text-align: center; text-align: center;
transition: all .3s cubic-bezier(.645, .045, .355, 1); transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
transform-origin: 100% 50%; transform-origin: 100% 50%;
&:before { &:before {
transform: scale(.6); transform: scale(0.6);
display: inline-block; display: inline-block;
vertical-align: -3px; vertical-align: -3px;
} }
......
...@@ -15,7 +15,7 @@ import './permission' // permission control ...@@ -15,7 +15,7 @@ import './permission' // permission control
import './tongji' // 百度统计 import './tongji' // 百度统计
import { getDicts } from "@/api/system/dict/data"; import { getDicts } from "@/api/system/dict/data";
import { getConfigKey } from "@/api/infra/config"; import { getConfigKey } from "@/api/infra/config";
import { parseTime, resetForm, addDateRange, addBeginAndEndTime, handleTree} from "@/utils/ruoyi"; import { parseTime, resetForm, addDateRange, addBeginAndEndTime, addBeginAndEndTimeNew, handleTree} from "@/utils/ruoyi";
import Pagination from "@/components/Pagination"; import Pagination from "@/components/Pagination";
// 自定义表格工具扩展 // 自定义表格工具扩展
import RightToolbar from "@/components/RightToolbar" import RightToolbar from "@/components/RightToolbar"
...@@ -33,6 +33,7 @@ Vue.prototype.parseTime = parseTime ...@@ -33,6 +33,7 @@ Vue.prototype.parseTime = parseTime
Vue.prototype.resetForm = resetForm Vue.prototype.resetForm = resetForm
Vue.prototype.addDateRange = addDateRange Vue.prototype.addDateRange = addDateRange
Vue.prototype.addBeginAndEndTime = addBeginAndEndTime Vue.prototype.addBeginAndEndTime = addBeginAndEndTime
Vue.prototype.addBeginAndEndTimeNew = addBeginAndEndTimeNew
Vue.prototype.getDictDatas = getDictDatas Vue.prototype.getDictDatas = getDictDatas
Vue.prototype.getDictDatas2 = getDictDatas2 Vue.prototype.getDictDatas2 = getDictDatas2
Vue.prototype.getDictDataLabel = getDictDataLabel Vue.prototype.getDictDataLabel = getDictDataLabel
...@@ -95,6 +96,7 @@ import '@/icons' ...@@ -95,6 +96,7 @@ import '@/icons'
import axios from 'axios' import axios from 'axios'
Vue.prototype.$axios = axios Vue.prototype.$axios = axios
import '@/styles/index.scss' import '@/styles/index.scss'
import '@/styles/custom.scss'
/** /**
* If you don't want to use mock-server * If you don't want to use mock-server
...@@ -123,7 +125,7 @@ Vue.prototype.$showFormValidateErrors = (errors) => { ...@@ -123,7 +125,7 @@ Vue.prototype.$showFormValidateErrors = (errors) => {
let createElement = vm.$createElement let createElement = vm.$createElement
let fieldList = Object.values(errors) let fieldList = Object.values(errors)
Element.Notification({ Element.Notification({
title: this.$t('表单错误'), title: i18n.$t('表单错误'),
type: 'warning', type: 'warning',
duration: 3000, duration: 3000,
message: createElement('div', fieldList.map(function (errorList) { message: createElement('div', fieldList.map(function (errorList) {
......
import router from './router' import router from "./router";
import store from './store' import store from "./store";
import { Message } from 'element-ui' import { Message } from "element-ui";
import NProgress from 'nprogress' import NProgress from "nprogress";
import 'nprogress/nprogress.css' import "nprogress/nprogress.css";
import { getToken } from '@/utils/auth' import { getToken } from "@/utils/auth";
import { isRelogin } from '@/utils/request' import { isRelogin } from "@/utils/request";
NProgress.configure({ showSpinner: false }) NProgress.configure({ showSpinner: false });
// 增加三方登陆 update by 芋艿 // 增加三方登陆 update by 芋艿
const whiteList = ['/login', '/social-login', '/auth-redirect', '/bind', '/register', '/oauthLogin/gitee'] const whiteList = [
"/login",
"/social-login",
"/auth-redirect",
"/bind",
"/register",
"/oauthLogin/gitee",
];
router.beforeEach((to, from, next) => { router.beforeEach((to, from, next) => {
NProgress.start() NProgress.start();
if (to.matched && to.matched.length > 2) {
to.matched.splice(1, to.matched.length - 2);
}
if (getToken()) { if (getToken()) {
to.meta.title && store.dispatch('settings/setTitle', to.meta.title) to.meta.title && store.dispatch("settings/setTitle", to.meta.title);
/* has token*/ /* has token*/
if (to.path === '/login') { if (to.path === "/login") {
next({ path: '/' }) next({ path: "/" });
NProgress.done() NProgress.done();
} else { } else {
if (store.getters.roles.length === 0) { if (store.getters.roles.length === 0) {
isRelogin.show = true isRelogin.show = true;
// 获取字典数据 add by 芋艿 // 获取字典数据 add by 芋艿
store.dispatch('dict/loadDictDatas') store.dispatch("dict/loadDictDatas");
// 判断当前用户是否已拉取完user_info信息 // 判断当前用户是否已拉取完user_info信息
store.dispatch('GetInfo').then(() => { store
isRelogin.show = false .dispatch("GetInfo")
store.dispatch('GenerateRoutes').then(accessRoutes => { .then(() => {
// 根据roles权限生成可访问的路由表 isRelogin.show = false;
router.addRoutes(accessRoutes) // 动态添加可访问路由表 store.dispatch("GenerateRoutes").then((accessRoutes) => {
next({ ...to, replace: true }) // hack方法 确保addRoutes已完成 // 根据roles权限生成可访问的路由表
}) router.addRoutes(accessRoutes); // 动态添加可访问路由表
}).catch(err => { next({ ...to, replace: true }); // hack方法 确保addRoutes已完成
store.dispatch('LogOut').then(() => { });
Message.error(err)
next({ path: '/' })
}) })
}) .catch((err) => {
store.dispatch("LogOut").then(() => {
Message.error(err);
next({ path: "/" });
});
});
} else { } else {
next() next();
} }
} }
} else { } else {
// 没有token // 没有token
if (whiteList.indexOf(to.path) !== -1) { if (whiteList.indexOf(to.path) !== -1) {
// 在免登录白名单,直接进入 // 在免登录白名单,直接进入
next() next();
} else { } else {
next(`/login?redirect=${to.fullPath}`) // 否则全部重定向到登录页 next(`/login?redirect=${to.fullPath}`); // 否则全部重定向到登录页
NProgress.done() NProgress.done();
} }
} }
}) });
router.afterEach(() => { router.afterEach(() => {
NProgress.done() NProgress.done();
}) });
...@@ -39,6 +39,7 @@ const actions = { ...@@ -39,6 +39,7 @@ const actions = {
cssClass: dictData.cssClass, cssClass: dictData.cssClass,
}) })
}) })
console.log(dictDataMap)
// 存储到 Store 中 // 存储到 Store 中
commit('SET_DICT_DATAS', dictDataMap) commit('SET_DICT_DATAS', dictDataMap)
}) })
......
This diff is collapsed.
.search-z {
.el-form-item--small.el-form-item {
width: 360px;
}
}
.search-time {
.el-form-item--small.el-form-item {
width: 520px;
}
}
.flex-c-c {
display: flex;
justify-content: center;
align-items: center;
}
.custom-form-1 {
padding-right: 40px;
.el-textarea,
.dict-selector,
.el-select {
width: 100%;
}
}
$editorTabsborderColor: #121315; $editorTabsborderColor: #121315;
body, html{
body,
html {
margin: 0; margin: 0;
padding: 0; padding: 0;
background: #fff; background: #fff;
-moz-osx-font-smoothing: grayscale; -moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
text-rendering: optimizeLegibility; text-rendering: optimizeLegibility;
font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji; font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji;
} }
input, textarea{ input,
font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji; textarea {
font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji;
} }
.editor-tabs{ .editor-tabs {
background: $editorTabsborderColor; background: $editorTabsborderColor;
.el-tabs__header{
.el-tabs__header {
margin: 0; margin: 0;
border-bottom-color: $editorTabsborderColor; border-bottom-color: $editorTabsborderColor;
.el-tabs__nav{
.el-tabs__nav {
border-color: $editorTabsborderColor; border-color: $editorTabsborderColor;
} }
} }
.el-tabs__item{
.el-tabs__item {
height: 32px; height: 32px;
line-height: 32px; line-height: 32px;
color: #888a8e; color: #888a8e;
border-left: 1px solid $editorTabsborderColor!important; border-left: 1px solid $editorTabsborderColor !important;
background: #363636; background: #363636;
margin-right: 5px; margin-right: 5px;
user-select: none; user-select: none;
} }
.el-tabs__item.is-active{
.el-tabs__item.is-active {
background: #1e1e1e; background: #1e1e1e;
border-bottom-color: #1e1e1e!important; border-bottom-color: #1e1e1e !important;
color: #fff; color: #fff;
} }
.el-icon-edit{
.el-icon-edit {
color: #f1fa8c; color: #f1fa8c;
} }
.el-icon-document{
.el-icon-document {
color: #a95812; color: #a95812;
} }
:focus.is-active.is-focus:not(:active) { :focus.is-active.is-focus:not(:active) {
box-shadow: none; box-shadow: none;
border-radius: 0; border-radius: 0;
...@@ -54,29 +64,35 @@ input, textarea{ ...@@ -54,29 +64,35 @@ input, textarea{
padding: 12px 18px 15px 15px; padding: 12px 18px 15px 15px;
} }
} }
.el-scrollbar__wrap { .el-scrollbar__wrap {
box-sizing: border-box; box-sizing: border-box;
overflow-x: hidden !important; overflow-x: hidden !important;
margin-bottom: 0 !important; margin-bottom: 0 !important;
} }
.center-tabs{
.el-tabs__header{ .center-tabs {
margin-bottom: 0!important; .el-tabs__header {
margin-bottom: 0 !important;
} }
.el-tabs__item{
.el-tabs__item {
width: 50%; width: 50%;
text-align: center; text-align: center;
} }
.el-tabs__nav{
.el-tabs__nav {
width: 100%; width: 100%;
} }
} }
.reg-item{
.reg-item {
padding: 12px 6px; padding: 12px 6px;
background: #f8f8f8; background: #f8f8f8;
position: relative; position: relative;
border-radius: 4px; border-radius: 4px;
.close-btn{
.close-btn {
position: absolute; position: absolute;
right: -6px; right: -6px;
top: -6px; top: -6px;
...@@ -91,18 +107,22 @@ input, textarea{ ...@@ -91,18 +107,22 @@ input, textarea{
z-index: 1; z-index: 1;
cursor: pointer; cursor: pointer;
font-size: 12px; font-size: 12px;
&:hover{
background: rgba(210, 23, 23, 0.5) &:hover {
background: rgba(210, 23, 23, 0.5);
} }
} }
& + .reg-item{
&+.reg-item {
margin-top: 18px; margin-top: 18px;
} }
} }
.action-bar{
.action-bar {
& .el-button+.el-button { & .el-button+.el-button {
margin-left: 15px; margin-left: 15px;
} }
& i { & i {
font-size: 20px; font-size: 20px;
vertical-align: middle; vertical-align: middle;
...@@ -111,31 +131,32 @@ input, textarea{ ...@@ -111,31 +131,32 @@ input, textarea{
} }
} }
.custom-tree-node{ .custom-tree-node {
width: 100%; width: 100%;
font-size: 14px; font-size: 14px;
.node-operation{
.node-operation {
float: right; float: right;
} }
i[class*="el-icon"] + i[class*="el-icon"]{
i[class*="el-icon"]+i[class*="el-icon"] {
margin-left: 6px; margin-left: 6px;
} }
.el-icon-plus{
color: #409EFF; .el-icon-plus {
color: #409eff;
} }
.el-icon-delete{
.el-icon-delete {
color: #157a0c; color: #157a0c;
} }
} }
.el-scrollbar__view{ .el-rate {
/*overflow-x: hidden;*/
}
.el-rate{
display: inline-block; display: inline-block;
vertical-align: text-top; vertical-align: text-top;
} }
.el-upload__tip{
.el-upload__tip {
line-height: 1.2; line-height: 1.2;
} }
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
...@@ -105,6 +105,31 @@ export function addBeginAndEndTime(params, dateRange, propName,isTime = true) { ...@@ -105,6 +105,31 @@ export function addBeginAndEndTime(params, dateRange, propName,isTime = true) {
return params; return params;
} }
export function addBeginAndEndTimeNew(params, dateRange, prefixName, propName, isTime = true) {
// 必须传入参数
if (!dateRange) {
return params;
}
// 如果未传递 propName 属性,默认为 time
if (!propName) {
propName = 'Time';
} else {
propName = propName.charAt(0).toUpperCase() + propName.slice(1);
}
if (!prefixName) {
prefixName = ''
}
console.log('dateRange', dateRange)
// 设置参数
if (dateRange[0]) {
params[prefixName + 'Begin' + propName] = dateRange[0] + (isTime ? ' 00:00:00':'');
}
if (dateRange[1]) {
params[prefixName + 'End' + propName] = dateRange[1] + (isTime ? ' 23:59:59' : '');
}
return params;
}
// 字符串格式化(%s ) // 字符串格式化(%s )
export function sprintf(str) { export function sprintf(str) {
var args = arguments, flag = true, i = 1; var args = arguments, flag = true, i = 1;
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -323,7 +323,7 @@ ...@@ -323,7 +323,7 @@
>{{ $t("撤销清关申请") }}</el-button >{{ $t("撤销清关申请") }}</el-button
> >
<!-- <el-button type="danger" style="margin-top: 5px;" size="small" @click="openError(scope.row)">{{$t('异常')}}</el-button> --> <el-button type="danger" style="margin-top: 5px;" size="small" @click="openError(scope.row)">{{$t('异常')}}</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<el-form ref="agentForm" :model="agentObj" :rules="rules" label-width="120px"> <el-form ref="agentForm" :model="agentObj" :rules="rules" label-width="120px">
<el-form-item :label="$t('代理商Agent')" prop="agentId"> <el-form-item :label="$t('代理商Agent')" prop="agentId">
<supplierOutSelect v-model="agentObj.agentId" :companyType="'1'" :areaType="1" :placeholder="$t('请选择代理商')" :allSupplier="this.$attrs.allSupplier" /> <supplierOutSelect v-model="agentObj.agentId" :companyType="'1'" :areaType="1" :placeholder="$t('请选择代理商')" :allSupplier="this.$attrs.allSupplier" />
<el-button v-hasPermi="['ecw:supplier:query']" type="text" style="font-size: 13px; margin-left: 240px;" @click="SupplierDetail">{{$t('查看代理商详情')}}</el-button> <el-button v-if="agentObj.agentId" v-hasPermi="['ecw:supplier:query']" type="text" style="font-size: 13px; margin-left: 240px;" @click="SupplierDetail">{{$t('查看代理商详情')}}</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row class="operate-button"> <el-row class="operate-button">
......
...@@ -74,6 +74,24 @@ ...@@ -74,6 +74,24 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('品牌')" align="center">
<template v-if="scope.row.brandName && scope.row.brandName!=='无' && scope.row.brandName!=='无牌'" slot-scope="scope">
<template v-if="scope.row.brandName">{{scope.row.brandName}}</template>
<dict-tag v-else :type="DICT_TYPE.ECW_IS_BRAND" :value="scope.row.brand" />
</template>
</el-table-column>
<el-table-column :label="$t('包装类型')" align="center" prop="">
<template slot-scope="scope">
<span v-for="(unit,index) in scope.row.units.split(',')" :key="index">
<dict-tag :type="DICT_TYPE.ECW_PACKAGING_TYPE" :value="unit" /><span v-if="index<scope.row.units.split(',').length-1">, </span>
</span>
</template>
</el-table-column>
<el-table-column :label="$t('特性')" align="center" prop="warehouseInAttrNameList" width="120">
<template slot-scope="scope">
{{scope.row.warehouseInAttrNameList?scope.row.warehouseInAttrNameList.toString():""}}
</template>
</el-table-column>
<el-table-column :label="$t('计划/已理')" align="center" prop="warehouseInInfo.cartonsNum"> <el-table-column :label="$t('计划/已理')" align="center" prop="warehouseInInfo.cartonsNum">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" @click.native="orderClick(scope.row)"> <el-link type="primary" @click.native="orderClick(scope.row)">
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<el-form ref="agentForm" :model="agentObj" :rules="rules" label-width="120px"> <el-form ref="agentForm" :model="agentObj" :rules="rules" label-width="120px">
<el-form-item :label="$t('代理商Agent')" prop="agentId"> <el-form-item :label="$t('代理商Agent')" prop="agentId">
<supplierOutSelect v-model="agentObj.agentId" :companyType="'1'" :areaType="1" :placeholder="$t('请选择代理商')" :allSupplier="this.$attrs.allSupplier" /> <supplierOutSelect v-model="agentObj.agentId" :companyType="'1'" :areaType="1" :placeholder="$t('请选择代理商')" :allSupplier="this.$attrs.allSupplier" />
<el-button v-hasPermi="['ecw:supplier:query']" type="text" style="font-size: 13px; margin-left: 240px;" @click="SupplierDetail">{{$t('查看代理商详情')}}</el-button> <el-button v-hasPermi="['ecw:supplier:query']" v-if="agentObj.agentId" type="text" style="font-size: 13px; margin-left: 240px;" @click="SupplierDetail">{{$t('查看代理商详情')}}</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row class="operate-button"> <el-row class="operate-button">
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<template>
<div class="app-container">
<el-card style="margin-bottom: 10px"> </el-card>
<el-card style="margin-bottom: 10px"> </el-card>
</div>
</template>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment