Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
XieZhiXiong
jinfa-platform
Commits
fe14bcac
Commit
fe14bcac
authored
Dec 24, 2021
by
前端-钟卫鹏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 代客下单查询支付方式添加采购会员/角色id字段,处理没有配置按钮权限的更多操作报错问题
parent
5d7abf4e
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
22 additions
and
16 deletions
+22
-16
index.tsx
src/components/TableOperation/index.tsx
+3
-3
order.ts
src/locales/en-US/order.ts
+2
-1
order.ts
src/locales/ko-KR/order.ts
+2
-1
order.ts
src/locales/zh-CN/order.ts
+2
-1
productAttributeForm.tsx
...mmodity/products/addProductsItem/productAttributeForm.tsx
+2
-2
index.tsx
src/pages/commodity/products/index.tsx
+1
-0
index.tsx
...leOrder/agentOrder/components/productModalTable/index.tsx
+2
-0
usePaymentInfo.tsx
...transaction/saleOrder/agentOrder/model/usePaymentInfo.tsx
+2
-2
useProductTable.tsx
...ransaction/saleOrder/agentOrder/model/useProductTable.tsx
+3
-2
index.tsx
src/pages/transaction/saleOrder/index.tsx
+3
-4
No files found.
src/components/TableOperation/index.tsx
View file @
fe14bcac
...
...
@@ -36,7 +36,7 @@ const TableOperation: React.FC<TableOperationProps> = (props) => {
Object
.
values
(
buttonTextFieldMap
).
filter
(
Boolean
).
length
>
2
?
<>
<
AuthButton
btnCode=
{
buttonPermissionsMap
[
keyNames
[
0
]]
}
menuCode=
{
menuCode
}
>
<
AuthButton
btnCode=
{
buttonPermissionsMap
?
buttonPermissionsMap
[
keyNames
[
0
]]
:
'DevTest'
}
menuCode=
{
menuCode
}
>
<
Button
type=
'link'
onClick=
{
operationHandler
[
keyNames
[
0
]]
}
>
{
keyNames
[
0
]
}
</
Button
>
</
AuthButton
>
...
...
@@ -45,7 +45,7 @@ const TableOperation: React.FC<TableOperationProps> = (props) => {
{
keyNames
.
slice
(
1
,
keyNames
.
length
).
map
((
item
,
i
)
=>
buttonTextFieldMap
[
item
]
?
(
<
Menu
.
Item
key=
{
`menuItem${i}`
}
>
<
AuthButton
btnCode=
{
buttonPermissionsMap
[
item
]
}
menuCode=
{
menuCode
}
>
<
AuthButton
btnCode=
{
buttonPermissionsMap
?
buttonPermissionsMap
[
item
]
:
'DevTest'
}
menuCode=
{
menuCode
}
>
<
Button
type=
'link'
onClick=
{
operationHandler
[
item
]
}
>
{
item
}
</
Button
>
</
AuthButton
>
</
Menu
.
Item
>
...
...
@@ -59,7 +59,7 @@ const TableOperation: React.FC<TableOperationProps> = (props) => {
</
Dropdown
>
</>
:
keyNames
.
map
((
item
,
i
)
=>
(
buttonTextFieldMap
[
item
]
?
<
AuthButton
btnCode=
{
buttonPermissionsMap
[
item
]
}
menuCode=
{
menuCode
}
><
Button
key=
{
`btnItem${i}`
}
type=
'link'
onClick=
{
operationHandler
[
item
]
}
>
{
item
}
</
Button
></
AuthButton
>
:
null
))
keyNames
.
map
((
item
,
i
)
=>
(
buttonTextFieldMap
[
item
]
?
<
AuthButton
btnCode=
{
buttonPermissionsMap
?
buttonPermissionsMap
[
item
]
:
'DevTest'
}
menuCode=
{
menuCode
}
><
Button
key=
{
`btnItem${i}`
}
type=
'link'
onClick=
{
operationHandler
[
item
]
}
>
{
item
}
</
Button
></
AuthButton
>
:
null
))
}
</>)
}
...
...
src/locales/en-US/order.ts
View file @
fe14bcac
...
...
@@ -123,7 +123,7 @@ export default {
'purchaseOrder.orderCollect.schema.buyerMemberMajorId'
:
'Purchase Member'
,
'purchaseOrder.orderCollect.schema.buyerMemberMajorIdPh'
:
'Please enter the search purchasing member'
,
'purchaseOrder.orderCollect.memberSchema.placeholder'
:
'Please enter the name of the member'
,
'purchaseOrder.orderCollect.model.message'
:
'Please select
a supply member
first'
,
'purchaseOrder.orderCollect.model.message'
:
'Please select
supply member and adapt mall
first'
,
'purchaseOrder.orderCollect.model.message1'
:
'Please select purchase inquiry contract first'
,
'purchaseOrder.orderCollect.model.message2'
:
'Please select a purchasing member first'
,
'purchaseOrder.orderCollect.model.button1'
:
'Select order item'
,
...
...
@@ -335,6 +335,7 @@ export default {
'purchaseOrder.shifouquerenshen'
:
'Whether to confirm the review of the warehouse receipt number is'
,
'purchaseOrder.decaigouruku'
:
'Purchase receipt order?'
,
'saleOrder.daochuerweima'
:
'Export qr Code'
,
'saleOrder.tijiaoshenhe'
:
'Submit for review'
,
'saleOrder.qinggouxuanyaoshen'
:
'Please check the order to be reviewed'
,
'saleOrder.piliangtijiaoshen'
:
'Batch submission for review'
,
...
...
src/locales/ko-KR/order.ts
View file @
fe14bcac
...
...
@@ -123,7 +123,7 @@ export default {
'purchaseOrder.orderCollect.schema.buyerMemberMajorId'
:
'구매 회원'
,
'purchaseOrder.orderCollect.schema.buyerMemberMajorIdPh'
:
'구매 회원 검색 입력'
,
'purchaseOrder.orderCollect.memberSchema.placeholder'
:
'회원 이름 입력'
,
'purchaseOrder.orderCollect.model.message'
:
'
우선 공급 회원을 선택하세요
'
,
'purchaseOrder.orderCollect.model.message'
:
'
공급회원제와 쇼핑몰에 적합한 상품을 먼저 선택하십시오
'
,
'purchaseOrder.orderCollect.model.message1'
:
'먼저 구매 문의 계약을 선택하세요'
,
'purchaseOrder.orderCollect.model.message2'
:
'먼저 구매 회원을 선택하세요'
,
'purchaseOrder.orderCollect.model.button1'
:
'주문 품목 선택'
,
...
...
@@ -335,6 +335,7 @@ export default {
'purchaseOrder.shifouquerenshen'
:
'감사 입고 양식 번호가'
,
'purchaseOrder.decaigouruku'
:
'의 구매 입고서?'
,
'saleOrder.daochuerweima'
:
'qr 코드를 내보내다'
,
'saleOrder.tijiaoshenhe'
:
'제출 심사'
,
'saleOrder.qinggouxuanyaoshen'
:
'검토할 주문을 선택하십시오.'
,
'saleOrder.piliangtijiaoshen'
:
'대량 제출 심사'
,
...
...
src/locales/zh-CN/order.ts
View file @
fe14bcac
...
...
@@ -123,7 +123,7 @@ export default {
'purchaseOrder.orderCollect.schema.buyerMemberMajorId'
:
'采购会员'
,
'purchaseOrder.orderCollect.schema.buyerMemberMajorIdPh'
:
'请输入搜索采购会员'
,
'purchaseOrder.orderCollect.memberSchema.placeholder'
:
'请输入会员名称'
,
'purchaseOrder.orderCollect.model.message'
:
'请先选择供应会员'
,
'purchaseOrder.orderCollect.model.message'
:
'请先选择供应会员
和适应商城
'
,
'purchaseOrder.orderCollect.model.message1'
:
'请先选择采购询价合同'
,
'purchaseOrder.orderCollect.model.message2'
:
'请先选择采购会员'
,
'purchaseOrder.orderCollect.model.button1'
:
'选择订单商品'
,
...
...
@@ -335,6 +335,7 @@ export default {
'purchaseOrder.shifouquerenshen'
:
'是否确认审核入库单号为'
,
'purchaseOrder.decaigouruku'
:
'的采购入库单?'
,
'saleOrder.daochuerweima'
:
'导出二维码'
,
'saleOrder.tijiaoshenhe'
:
'提交审核'
,
'saleOrder.qinggouxuanyaoshen'
:
'请勾选要审核的订单'
,
'saleOrder.piliangtijiaoshen'
:
'批量提交审核'
,
...
...
src/pages/commodity/products/addProductsItem/productAttributeForm.tsx
View file @
fe14bcac
...
...
@@ -124,8 +124,8 @@ const ProductAttributeForm: React.FC<Iprops> = (props) => {
},
{}))
// 遍历 排空
let
resultParams
=
_resultParams
.
filter
((
_item
:
any
)
=>
_item
.
customerAttributeValueList
.
length
!=
0
)
let
resultParams
=
_resultParams
.
filter
((
_item
:
any
)
=>
(
_item
.
customerAttributeValueList
.
length
!=
0
&&
_item
.
customerAttributeValueList
[
0
][
'value'
]
!==
''
)
)
console
.
log
(
resultParams
,
'resultParams'
)
setProductSelectAttribute
(
resultParams
)
}
...
...
src/pages/commodity/products/index.tsx
View file @
fe14bcac
...
...
@@ -36,6 +36,7 @@ import PutawayGuide from './components/putawayGuide'
import
{
useRowSelectionTable
,
useRowSelectionTableCtl
}
from
'@/hooks/useRowSelectionTable'
import
AuthButton
from
'@/components/AuthButton'
import
{
AuthUrl
}
from
'@/components/AuthButton/AuthUrl'
import
allRouters
from
'../../../../config/router.config.json'
const
{
confirm
}
=
Modal
;
...
...
src/pages/transaction/saleOrder/agentOrder/components/productModalTable/index.tsx
View file @
fe14bcac
...
...
@@ -130,6 +130,8 @@ const ProductModalTable:React.FC<ProductModalTableProps> = (props) => {
const
newData
=
rowSelectionCtl
.
selectRow
.
map
(
v
=>
{
v
.
orderMode
=
schemaAction
.
getFieldValue
(
'orderMode'
)
v
.
shopId
=
schemaAction
.
getFieldValue
(
'shopId'
)
v
.
buyerMemberId
=
schemaAction
.
getFieldValue
(
'buyerMemberId'
)
v
.
buyerRoleId
=
schemaAction
.
getFieldValue
(
'buyerRoleId'
)
return
v
})
schemaAction
.
setFieldValue
(
'products'
,
await
filterProductDataById
([],
newData
))
...
...
src/pages/transaction/saleOrder/agentOrder/model/usePaymentInfo.tsx
View file @
fe14bcac
...
...
@@ -19,14 +19,14 @@ export const usePaymentInfo = (ctx: ISchemaFormActions | ISchemaFormAsyncActions
useEffect
(()
=>
{
// 商品有传入时 调用支付方式api
if
(
products
.
length
&&
markRef
.
current
)
{
getPayLists
(
products
[
0
].
memberId
,
products
[
0
].
memb
erRoleId
)
getPayLists
(
products
[
0
].
buyerMemberId
,
products
[
0
].
buy
erRoleId
)
markRef
.
current
=
false
}
},
[
products
])
const
initPayWayList
=
(
memberId
,
memberRoleId
)
=>
{
let
result
=
[]
getOrderVendorCreateAgentPayTypes
({
vendorMemberId
:
memberId
,
vendo
rRoleId
:
memberRoleId
}).
then
(
res
=>
{
getOrderVendorCreateAgentPayTypes
({
buyerMemberId
:
memberId
,
buye
rRoleId
:
memberRoleId
}).
then
(
res
=>
{
const
{
data
=
[],
code
}
=
res
for
(
let
item
of
data
)
{
result
.
push
({
...
...
src/pages/transaction/saleOrder/agentOrder/model/useProductTable.tsx
View file @
fe14bcac
...
...
@@ -115,8 +115,9 @@ export const useProductTable = (ctx: ISchemaFormActions | ISchemaFormAsyncAction
return
productInfoColumns
})
const
handleShowProduct
=
()
=>
{
const
supplyMembersId
=
ctx
.
getFieldValue
(
'vendorMemberName'
)
if
(
supplyMembersId
)
{
const
buyerMemberId
=
ctx
.
getFieldValue
(
'buyerMemberId'
)
const
shopId
=
ctx
.
getFieldValue
(
'shopId'
)
if
(
buyerMemberId
&&
shopId
)
{
productRef
.
current
.
setVisible
(
true
)
}
else
{
message
.
error
(
intl
.
formatMessage
({
id
:
'purchaseOrder.orderCollect.model.message'
}))
...
...
src/pages/transaction/saleOrder/index.tsx
View file @
fe14bcac
...
...
@@ -18,7 +18,7 @@ import { getAuth } from '@/utils/auth'
import
styles
from
'./index.less'
import
QRCode
from
'qrcode'
import
{
MEMBER_ROLE_TYPE_SERVICE_CONSUMER
}
from
'@/constants/member'
import
{
getOrderVendorGeneratePayLink
,
GetOrderVendorGeneratePayLinkResponse
,
getOrderVendorMiniAppCode
,
getOrderVendorPage
,
postOrderVendorCancel
,
postOrderVendorTerminate
,
postOrderVendorTransfer
,
postOrderVendorTransferPreview
}
from
'@/services/OrderNewV2Api'
import
{
getOrderVendorGeneratePayLink
,
getOrderVendorMiniAppCode
,
getOrderVendorPage
,
postOrderVendorCancel
,
postOrderVendorTerminate
,
postOrderVendorTransfer
,
postOrderVendorTransferPreview
}
from
'@/services/OrderNewV2Api'
import
appImg
from
'@/assets/icons/app.png'
import
miniappImg
from
'@/assets/icons/miniapp.png'
import
scanImg
from
'@/assets/icons/scan.png'
...
...
@@ -136,21 +136,20 @@ const SaleOrder: React.FC<SaleOrderProps> = () => {
const
onSave
=
()
=>
{
const
img
:
any
=
document
.
getElementById
(
'qrcodeElement'
);
const
canvas
=
document
.
createElement
(
'canvas'
);
// console.log(img)
canvas
.
width
=
img
.
width
;
canvas
.
height
=
img
.
height
;
canvas
.
getContext
(
'2d'
).
drawImage
(
img
,
0
,
0
,
img
.
width
,
img
.
height
);
const
url
=
canvas
.
toDataURL
(
'image/png'
);
var
downloadLink
=
document
.
getElementById
(
'downloadLink'
);
downloadLink
.
setAttribute
(
'href'
,
url
);
downloadLink
.
setAttribute
(
'download'
,
'二维码.png'
);
downloadLink
.
setAttribute
(
'download'
,
`
${
intl
.
formatMessage
({
id
:
'saleOrder.daochuerweima'
,
defaultMessage
:
'导出二维码'
})}
.png`
);
downloadLink
.
click
();
}
const
generatePayChart
=
(
record
)
=>
{
getOrderVendorGeneratePayLink
({
orderId
:
record
.
orderId
}).
then
(({
data
})
=>
{
currentPayRef
.
current
=
data
// setPayModel(ORDER_SHOP_ORIGIN_MAP[data['shopEnvironment']])
setPayChartVisible
(
true
)
})
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment