Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-mall
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
前端-甘科
jinfa-mall
Commits
4f843a40
Commit
4f843a40
authored
May 07, 2022
by
前端-许佳敏
Browse files
Options
Browse Files
Download
Plain Diff
merge: 合并0518版本
parents
735ad1e9
e9e4ed37
Hide whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
155 additions
and
83 deletions
+155
-83
index.tsx
apps/srm/web/page/InquiryDetail/index.tsx
+1
-0
index.tsx
...srm/web/page/biddingDetail/components/ShopTitle/index.tsx
+36
-38
index.tsx
apps/srm/web/page/biddingDetail/index.tsx
+1
-0
index.tsx
apps/srm/web/page/competeDetail/index.tsx
+1
-0
index.tsx
apps/srm/web/page/index/components/InquiryCard/index.tsx
+19
-11
InquiryCardModular.tsx
...e/index/components/PurchaseModular/InquiryCardModular.tsx
+7
-6
index.tsx
...m/web/page/purchaseBidding/components/OfferCard/index.tsx
+16
-5
index.tsx
apps/srm/web/page/purchaseBidding/index.tsx
+1
-0
index.tsx
...m/web/page/purchaseCompete/components/OfferCard/index.tsx
+15
-3
index.tsx
apps/srm/web/page/purchaseCompete/index.tsx
+1
-0
index.tsx
...m/web/page/purchaseInquiry/components/OfferCard/index.tsx
+14
-3
index.tsx
apps/srm/web/page/purchaseInquiry/index.tsx
+6
-5
index.tsx
apps/srm/web/page/shopIndex/components/InquiryCard/index.tsx
+16
-9
ShopInquiryCardModular.tsx
...dex/components/PurchaseModular/ShopInquiryCardModular.tsx
+2
-1
index.tsx
...m/web/page/shopIndex/components/PurchaseModular/index.tsx
+1
-0
env.js
env.js
+13
-2
en-US.js
locales/srm/en-US.js
+1
-0
ko-KR.js
locales/srm/ko-KR.js
+2
-0
zh-CN.js
locales/srm/zh-CN.js
+1
-0
package.json
package.json
+1
-0
No files found.
apps/srm/web/page/InquiryDetail/index.tsx
View file @
4f843a40
...
...
@@ -172,6 +172,7 @@ function InquiryDetail(props: any) {
purchaseInquiryNo=
{
infoMessage
.
purchaseInquiryNo
}
userInfo=
{
userInfo
}
canRegister=
{
!!
infoMessage
.
canRegister
}
isSubMember=
{
infoMessage
.
isSubMember
}
></
ShopTitle
>
</
li
>
<
li
className=
{
styles
[
'demand-warp'
]
}
>
...
...
apps/srm/web/page/biddingDetail/components/ShopTitle/index.tsx
View file @
4f843a40
...
...
@@ -2,7 +2,7 @@ import React, { useState, useEffect } from 'react'
import
styles
from
'./index.less'
import
{
MEMBER_CENTER_URL
,
LOGIN_DOMAIN
}
from
'@/constants'
import
{
useMessageIntl
}
from
'@linkseeks/lingxi-utils'
import
{
Button
}
from
'antd'
;
import
{
Button
,
Modal
}
from
'antd'
;
import
useCountdown
from
'@/hooks/useCountdown'
interface
Props
{
...
...
@@ -19,16 +19,9 @@ interface Props {
canRegister
?:
boolean
,
// 当前用户能否报价
isSignUp
?:
number
,
// 是否已报名,
isMePublish
?:
number
,
// 是否是自己发布的竞价单 1:是; 0:否;
isSubMember
?:
boolean
,
// 是否下级会员
}
const
PAGENAME
=
{
/** 采购询价单 */
INQUIRY_ORDER
:
'采购询价单'
,
/** 采购招标单 */
TENDER_ORDER
:
'采购招标单'
,
/** 采购竞价单 */
BIDDING_ORDER
:
'采购竞价单'
}
function
ShopTitle
(
props
:
Props
)
{
const
{
...
...
@@ -45,24 +38,21 @@ function ShopTitle(props: Props) {
canRegister
=
true
,
isSignUp
,
isMePublish
,
isSubMember
}
=
props
const
{
getMessage
}
=
useMessageIntl
()
const
[
userMessage
,
setUserMessage
]
=
useState
<
any
>
({})
const
{
count
,
setTime
}
=
useCountdown
()
/**
* 获取订单状态
*/
// const fnIsOverdue = () => {
// if (days == '0' && hours == '0' && minutes == '0') { // 时间
// return false;
// } else if (isRegister && isRegister > 0) { // 已经报名
// return false
// }
// return true;
// }
const
PAGENAME
=
{
/** 采购询价单 */
INQUIRY_ORDER
:
getMessage
(
'locales.caigouxunjiadan'
,
'采购询价单'
),
/** 采购招标单 */
TENDER_ORDER
:
getMessage
(
'locales.caigouzhaobiaodan'
,
'采购招标单'
),
/** 采购竞价单 */
BIDDING_ORDER
:
getMessage
(
'locales.caigoujingjiadan'
,
'采购竞价单'
)
}
/**
* 获取订单状态
...
...
@@ -106,6 +96,17 @@ function ShopTitle(props: Props) {
return
link
}
/** 未成为下级会员提示 */
const
handleIsSubMember
=
(
linkseeks
?:
string
)
=>
{
if
(
!
isSubMember
)
{
Modal
.
warning
({
content
:
getMessage
(
'locales.warning'
,
'您还未申请成为入库供应商,请先申请后再{data}!'
,
{
data
:
projectType
===
PAGENAME
.
INQUIRY_ORDER
?
getMessage
(
'locales.baojia'
,
'报价'
)
:
getMessage
(
'locales.baoming'
,
'报名'
)
})
})
return
}
window
.
open
(
linkseeks
)
}
return
(
<
div
className=
{
styles
[
'shop-title-warp'
]
}
>
<
div
className=
{
styles
[
'shop-title-left'
]
}
>
...
...
@@ -127,24 +128,23 @@ function ShopTitle(props: Props) {
type=
'primary'
style=
{
{
marginBottom
:
'16px'
}
}
disabled=
{
!
canRegister
||
!
fnIsOverdue
(
projectType
)
}
target=
'_blank'
href=
{
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/offter/quote?id=${id}&number=${purchaseInquiryNo}`
}
onClick=
{
()
=>
handleIsSubMember
(
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/offter/quote?id=${id}&number=${purchaseInquiryNo}`
)
}
>
{
fnIsOverdue
(
projectType
)
?
'立即报价'
:
(
isRegister
&&
isRegister
>
0
?
'已经报价'
:
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
))
fnIsOverdue
(
projectType
)
?
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
:
(
isRegister
&&
isRegister
>
0
?
getMessage
(
'locales.yijingbaojia'
,
'已经报价'
)
:
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
))
}
</
Button
>
)
:
(
<
Button
type=
'primary'
style=
{
{
marginBottom
:
'16px'
}
}
href=
{
LOGIN_DOMAIN
}
>
{
fnIsOverdue
(
projectType
)
?
'立即报价'
:
(
isRegister
&&
isRegister
>
0
?
'已经报价'
:
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
))
}
</
Button
>
)
<
Button
type=
'primary'
style=
{
{
marginBottom
:
'16px'
}
}
href=
{
LOGIN_DOMAIN
}
>
{
fnIsOverdue
(
projectType
)
?
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
:
(
isRegister
&&
isRegister
>
0
?
getMessage
(
'locales.yijingbaojia'
,
'已经报价'
)
:
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
))
}
</
Button
>
)
}
</>
)
}
...
...
@@ -161,8 +161,7 @@ function ShopTitle(props: Props) {
type=
'primary'
style=
{
{
marginBottom
:
'16px'
}
}
disabled=
{
(
!!
isSignUp
||
!
fnIsOverdue
(
projectType
))
}
target=
'_blank'
href=
{
handleLink
(
projectType
)
}
onClick=
{
()
=>
handleIsSubMember
(
handleLink
(
projectType
))
}
>
{
fnIsOverdue
(
projectType
)
?
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
:
(
isSignUp
&&
isSignUp
>
0
?
getMessage
(
'locales.yijingbaoming'
,
'已经报名'
)
:
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
))
...
...
@@ -194,8 +193,7 @@ function ShopTitle(props: Props) {
type=
'primary'
style=
{
{
marginBottom
:
'16px'
}
}
disabled=
{
!
canRegister
||
!
fnIsOverdue
(
projectType
)
}
target=
'_blank'
href=
{
handleLink
(
projectType
)
}
onClick=
{
()
=>
handleIsSubMember
(
handleLink
(
projectType
))
}
>
{
fnIsOverdue
(
projectType
)
?
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
:
(
isRegister
&&
isRegister
>
0
?
getMessage
(
'locales.yijingbaoming'
,
'已经报名'
)
:
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
))
...
...
apps/srm/web/page/biddingDetail/index.tsx
View file @
4f843a40
...
...
@@ -168,6 +168,7 @@ function InquiryDetail(props: any) {
purchaseInquiryNo=
{
infoMessage
.
purchaseInquiryNo
}
userInfo=
{
userInfo
}
canRegister=
{
!!
infoMessage
.
canRegister
}
isSubMember=
{
infoMessage
.
isSubMember
}
></
ShopTitle
>
</
li
>
<
li
className=
{
styles
[
'demand-warp'
]
}
>
...
...
apps/srm/web/page/competeDetail/index.tsx
View file @
4f843a40
...
...
@@ -180,6 +180,7 @@ function InquiryDetail(props: any) {
isSignUp=
{
infoMessage
.
isSignUp
}
canRegister=
{
!!
infoMessage
.
canRegister
}
isMePublish=
{
infoMessage
.
isMePublish
}
isSubMember=
{
infoMessage
.
isSubMember
}
></
ShopTitle
>
</
li
>
<
li
className=
{
styles
[
'demand-warp'
]
}
>
...
...
apps/srm/web/page/index/components/InquiryCard/index.tsx
View file @
4f843a40
...
...
@@ -5,7 +5,7 @@ import React from 'react'
import
styles
from
'./index.less'
import
{
integrationTime
}
from
'@/utils/commonlyFn'
import
{
Button
}
from
'antd'
import
{
Button
,
Modal
}
from
'antd'
import
{
MEMBER_CENTER_URL
,
LOGIN_DOMAIN
}
from
'@/constants'
import
{
ShoppingCartOutlined
,
HistoryOutlined
}
from
'@ant-design/icons'
import
{
useMessageIntl
}
from
'@linkseeks/lingxi-utils'
...
...
@@ -43,6 +43,7 @@ interface Props {
isSignUp
?:
number
,
// 是否已报名
isType
?:
PAGETYPES
.
BIDDING_ORDER
|
PAGETYPES
.
INQUIRY_ORDER
|
PAGETYPES
.
TENDER_ORDER
,
isMePublish
?:
number
,
// 是否是自己发布的竞价单 1:是; 0:否;
isSubMember
?:
boolean
,
// 是否下级会员
}
/**
* @cardTitle 卡片标题
...
...
@@ -73,7 +74,8 @@ function InquiryCard(props: Props) {
shopId
,
isSignUp
,
isType
,
isMePublish
isMePublish
,
isSubMember
}
=
props
/**
...
...
@@ -90,6 +92,12 @@ function InquiryCard(props: Props) {
return
''
}
/** 未成为下级会员提示 */
const
handleIsSubMember
=
()
=>
{
Modal
.
warning
({
content
:
getMessage
(
'locales.warning'
,
'您还未申请成为入库供应商,请先申请后再{data}!'
,
{
data
:
jumpUrl
===
'InquiryDetail'
?
getMessage
(
'locales.baojia'
,
'报价'
)
:
getMessage
(
'locales.baoming'
,
'报名'
)
})
})
}
return
(
<
ul
className=
{
styles
[
'inquiry-main'
]
}
style=
{
{
width
:
props
.
cardWidth
,
borderColor
:
topBorderColor
?
topBorderColor
:
'#ffffff'
}
}
>
...
...
@@ -157,15 +165,15 @@ function InquiryCard(props: Props) {
{
(
isType
===
PAGETYPES
.
INQUIRY_ORDER
&&
!!
canRegister
)
&&
(
<
li
className=
{
`${styles['sign-btn-warp']}`
}
style=
{
{
left
:
cardWidth
===
470
?
'25%'
:
''
}
}
>
<>
<
Button
className=
{
`${styles['sign-btn']} ${((btnText ===
'立即报价' || btnText === '立即报名'
) && !!canRegister) ? '' : styles['sign-btn-grey']}`
}
block
>
<
Button
className=
{
`${styles['sign-btn']} ${((btnText ===
getMessage('locales.lijibaojia', '立即报价') || btnText === getMessage('locales.lijibaoming', '立即报名')
) && !!canRegister) ? '' : styles['sign-btn-grey']}`
}
block
>
{
btnText
}
</
Button
>
{
((
btnText
===
'立即报价'
||
btnText
===
'立即报名'
)
&&
!!
canRegister
)
&&
((
btnText
===
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
||
btnText
===
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
)
&&
!!
canRegister
)
&&
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
@@ -177,15 +185,15 @@ function InquiryCard(props: Props) {
{
(
isType
===
PAGETYPES
.
TENDER_ORDER
&&
!!
canRegister
)
&&
(
<
li
className=
{
`${styles['sign-btn-warp']}`
}
style=
{
{
left
:
cardWidth
===
470
?
'25%'
:
''
}
}
>
<>
<
Button
className=
{
`${styles['sign-btn']} ${((btnText ===
'立即报价' || btnText === '立即报名'
) && !!canRegister) ? '' : styles['sign-btn-grey']}`
}
block
>
<
Button
className=
{
`${styles['sign-btn']} ${((btnText ===
getMessage('locales.lijibaojia', '立即报价') || btnText === getMessage('locales.lijibaoming', '立即报名')
) && !!canRegister) ? '' : styles['sign-btn-grey']}`
}
block
>
{
btnText
}
</
Button
>
{
((
btnText
===
'立即报价'
||
btnText
===
'立即报名'
)
&&
!!
canRegister
)
&&
((
btnText
===
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
||
btnText
===
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
)
&&
!!
canRegister
)
&&
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
@@ -197,15 +205,15 @@ function InquiryCard(props: Props) {
{
(
isType
===
PAGETYPES
.
BIDDING_ORDER
&&
!!!
isMePublish
)
&&
(
<
li
className=
{
`${styles['sign-btn-warp']}`
}
style=
{
{
left
:
cardWidth
===
470
?
'25%'
:
''
}
}
>
<>
<
Button
className=
{
`${styles['sign-btn']} ${((btnText ===
'立即报价' || btnText === '立即报名'
) && !!!isSignUp) ? '' : styles['sign-btn-grey']}`
}
block
>
<
Button
className=
{
`${styles['sign-btn']} ${((btnText ===
getMessage('locales.lijibaojia', '立即报价') || btnText === getMessage('locales.lijibaoming', '立即报名')
) && !!!isSignUp) ? '' : styles['sign-btn-grey']}`
}
block
>
{
btnText
}
</
Button
>
{
((
btnText
===
'立即报价'
||
btnText
===
'立即报名'
)
&&
!!!
isSignUp
)
&&
((
btnText
===
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
||
btnText
===
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
)
&&
!!!
isSignUp
)
&&
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
apps/srm/web/page/index/components/PurchaseModular/InquiryCardModular.tsx
View file @
4f843a40
...
...
@@ -56,11 +56,11 @@ function InquiryCardModular(props: Props) {
*/
const
fnGetBtnText
=
(
already
:
boolean
,
days
:
number
,
hours
:
number
,
minutes
:
number
,
modular
:
string
)
=>
{
if
(
already
)
{
return
modular
===
'采购竞价'
?
getMessage
(
'locales.yijingbaoming'
,
'已经报名'
)
:
getMessage
(
'locales.yijingbaojia'
,
'已经报价'
)
return
modular
===
getMessage
(
"locales.caigoujingjia"
,
"采购竞价"
)
?
getMessage
(
'locales.yijingbaoming'
,
'已经报名'
)
:
getMessage
(
'locales.yijingbaojia'
,
'已经报价'
)
}
else
if
(
days
===
0
&&
hours
===
0
&&
minutes
===
0
)
{
return
getMessage
(
'locales.yijingjiezhi'
,
'已经截止'
)
}
return
modular
===
'采购竞价'
?
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
:
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
return
modular
===
getMessage
(
"locales.caigoujingjia"
,
"采购竞价"
)
?
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
:
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
}
/**
...
...
@@ -90,7 +90,7 @@ function InquiryCardModular(props: Props) {
{
getMessage
(
'locales.zhakangengduo'
,
'查看更多'
)
}
<
RightOutlined
translate=
{
undefined
}
className=
{
styles
[
'see-more-icon'
]
}
/>
{
modularText
==
'采购询价'
?
modularText
==
getMessage
(
'locales.caigouxunjia'
,
'采购询价'
)
?
<
a
href=
{
`${shopId ? `
/
$
{
shopId
}
` : ''}/purchaseInquiry?priceTypeList=1`
}
className=
'all-jump'
></
a
>
:
<
a
href=
{
`${shopId ? `
/
$
{
shopId
}
` : ''}/purchaseCompete?priceTypeList=3`
}
className=
'all-jump'
></
a
>
}
...
...
@@ -118,15 +118,16 @@ function InquiryCardModular(props: Props) {
id=
{
item
.
id
}
purchaseInquiryNo=
{
item
.
purchaseInquiryNo
}
createTime=
{
item
.
createTime
}
jumpUrl=
{
modularText
==
'采购询价'
?
`InquiryDetail`
:
`competeDetail`
}
jumpUrl=
{
modularText
==
getMessage
(
'locales.caigouxunjia'
,
'采购询价'
)
?
`InquiryDetail`
:
`competeDetail`
}
topBorderColor=
{
topBorderColor
}
cardTitleType=
{
modularText
==
'采购询价'
?
getMessage
(
'locales.caigouxunjia'
,
'采购询价'
)
:
getMessage
(
'locales.caigoujingjia'
,
'采购竞价'
)
}
btnText=
{
fnGetBtnText
((
modularText
===
'采购竞价'
?
item
.
isSignUp
:
item
.
isRegister
>
0
),
item
.
days
,
item
.
hours
,
item
.
minutes
,
modularText
)
}
cardTitleType=
{
modularText
==
getMessage
(
'locales.caigouxunjia'
,
'采购询价'
)
?
getMessage
(
'locales.caigouxunjia'
,
'采购询价'
)
:
getMessage
(
'locales.caigoujingjia'
,
getMessage
(
"locales.caigoujingjia"
,
"采购竞价"
)
)
}
btnText=
{
fnGetBtnText
((
modularText
===
getMessage
(
"locales.caigoujingjia"
,
"采购竞价"
)
?
item
.
isSignUp
:
item
.
isRegister
>
0
),
item
.
days
,
item
.
hours
,
item
.
minutes
,
modularText
)
}
isSign=
{
isSign
}
shopId=
{
shopId
}
isSignUp=
{
item
.
isSignUp
}
isType=
{
pageType
}
isMePublish=
{
item
.
isMePublish
}
isSubMember=
{
item
.
isSubMember
}
></
InquiryCard
>
</
li
>
})
...
...
apps/srm/web/page/purchaseBidding/components/OfferCard/index.tsx
View file @
4f843a40
...
...
@@ -8,6 +8,7 @@ import { integrationTime } from '@/utils/commonlyFn';
import
{
MEMBER_CENTER_URL
,
LOGIN_DOMAIN
}
from
'@/constants'
;
import
{
ShoppingCartOutlined
,
HistoryOutlined
}
from
'@ant-design/icons'
;
import
{
findRouterShopId
}
from
'@/utils'
;
import
{
Modal
}
from
'antd'
;
interface
Props
{
cardTitle
?:
string
,
// 标题
...
...
@@ -23,7 +24,8 @@ interface Props {
btnText
?:
string
,
// 按钮的文字
isSign
?:
boolean
,
// 是否登录了
canRegister
?:
boolean
,
// 是否可以报价/报名
mallId
?:
number
// 链接上带的商城id
mallId
?:
number
,
// 链接上带的商城id
isSubMember
?:
boolean
,
// 是否下级会员
}
function
OfferCard
(
props
:
Props
)
{
...
...
@@ -41,7 +43,8 @@ function OfferCard(props: Props) {
btnText
=
'-'
,
isSign
=
false
,
canRegister
=
true
,
mallId
mallId
,
isSubMember
}
=
props
const
{
getMessage
}
=
useMessageIntl
()
const
{
search
}
=
location
||
{}
...
...
@@ -55,6 +58,13 @@ function OfferCard(props: Props) {
}
},
[])
/** 未成为下级会员提示 */
const
handleIsSubMember
=
()
=>
{
Modal
.
warning
({
content
:
getMessage
(
'locales.warning'
,
'您还未申请成为入库供应商,请先申请后再{data}!'
,
{
data
:
getMessage
(
'locales.baoming'
,
'报名'
)
})
})
}
return
(
<
ul
className=
{
styles
[
'offer-main'
]
}
>
<
li
className=
{
styles
[
'card-title'
]
}
>
...
...
@@ -99,14 +109,15 @@ function OfferCard(props: Props) {
</
li
>
{
canRegister
&&
(
<
li
className=
{
styles
[
'offer-btn'
]
}
>
<
div
className=
{
`${(btnText ===
'立即报名'
&& canRegister) ? '' : styles['offer-btn-grey']}`
}
>
<
div
className=
{
`${(btnText ===
getMessage('locales.lijibaoming', '立即报名')
&& canRegister) ? '' : styles['offer-btn-grey']}`
}
>
{
btnText
}
{
(
btnText
===
'立即报名'
&&
canRegister
)
&&
(
btnText
===
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
&&
canRegister
)
&&
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/tender/readyBidRegister/add?id=${id}`
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/tender/readyBidRegister/add?id=${id}`
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
apps/srm/web/page/purchaseBidding/index.tsx
View file @
4f843a40
...
...
@@ -289,6 +289,7 @@ const PurchaseInquiry: SFC<PurchaseInquiryPropsType> = (props) => {
isSign=
{
(
userInfo
&&
userInfo
.
userId
)
?
true
:
false
}
canRegister=
{
!!
item
.
canRegister
}
mallId=
{
shopIds
}
isSubMember=
{
item
.
isSubMember
}
></
OfferCard
>
</
li
>
...
...
apps/srm/web/page/purchaseCompete/components/OfferCard/index.tsx
View file @
4f843a40
...
...
@@ -8,7 +8,7 @@ import { integrationTime } from '@/utils/commonlyFn';
import
cx
from
'classnames'
import
{
ShoppingCartOutlined
,
HistoryOutlined
}
from
'@ant-design/icons'
;
import
{
findRouterShopId
}
from
'@/utils'
;
import
{
Button
,
message
}
from
'antd'
;
import
{
Button
,
message
,
Modal
}
from
'antd'
;
import
{
LOGIN_DOMAIN
,
MEMBER_CENTER_URL
}
from
'@/constants'
;
interface
Props
{
...
...
@@ -28,6 +28,7 @@ interface Props {
canRegister
?:
boolean
,
// 是否可以报价/报名
isSignUp
?:
number
,
// 是否已报名
isMePublish
?:
number
,
// 是否是自己发布的竞价单 1:是; 0:否;
isSubMember
?:
boolean
,
// 是否下级会员
}
function
OfferCard
(
props
:
Props
)
{
...
...
@@ -48,11 +49,23 @@ function OfferCard(props: Props) {
canRegister
=
true
,
isSignUp
,
isMePublish
,
isSubMember
,
}
=
props
;
const
shopId
=
findRouterShopId
();
const
{
getMessage
}
=
useMessageIntl
();
/** 未成为下级会员提示 */
const
handleIsSubMember
=
(
linkseeks
:
string
)
=>
{
if
(
!
isSubMember
)
{
Modal
.
warning
({
content
:
getMessage
(
'locales.warning'
,
'您还未申请成为入库供应商,请先申请后再{data}!'
,
{
data
:
getMessage
(
'locales.baoming'
,
'报名'
)
})
})
return
}
window
.
open
(
linkseeks
)
}
return
(
<
ul
className=
{
styles
[
'offer-main'
]
}
>
<
li
className=
{
styles
[
'card-title'
]
}
>
...
...
@@ -108,8 +121,7 @@ function OfferCard(props: Props) {
type=
'primary'
block
disabled=
{
(
lostDay
===
0
||
isSignUp
===
1
)
}
target=
'_blank'
href=
{
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/onlineBid/readySignUp/signUp?id=${id}&number=${purchaseInquiryNo}`
}
onClick=
{
()
=>
handleIsSubMember
(
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/onlineBid/readySignUp/signUp?id=${id}&number=${purchaseInquiryNo}`
)
}
>
{
btnText
}
</
Button
>
...
...
apps/srm/web/page/purchaseCompete/index.tsx
View file @
4f843a40
...
...
@@ -272,6 +272,7 @@ const PurchaseInquiry: SFC<PurchaseInquiryPropsType> = (props) => {
isSign=
{
(
userInfo
&&
userInfo
.
userId
)
?
true
:
false
}
canRegister=
{
item
.
canRegister
}
isMePublish=
{
item
.
isMePublish
}
isSubMember=
{
item
.
isSubMember
}
></
OfferCard
>
</
li
>
...
...
apps/srm/web/page/purchaseInquiry/components/OfferCard/index.tsx
View file @
4f843a40
...
...
@@ -7,6 +7,7 @@ import { getQueryString, useMessageIntl } from '@linkseeks/lingxi-utils';
import
{
integrationTime
}
from
'@/utils/commonlyFn'
;
import
{
MEMBER_CENTER_URL
,
LOGIN_DOMAIN
}
from
'@/constants'
;
import
{
ShoppingCartOutlined
,
HistoryOutlined
}
from
'@ant-design/icons'
;
import
{
Modal
}
from
'antd'
;
interface
Props
{
cardTitle
?:
string
,
// 标题
...
...
@@ -23,7 +24,8 @@ interface Props {
purchaseInquiryNo
?:
string
// 编号
isSign
?:
boolean
,
// 是否登录状态
canRegister
?:
boolean
,
// 是否可以报价/报名
mallId
?:
number
// 链接上带的商城id
mallId
?:
number
,
// 链接上带的商城id
isSubMember
?:
boolean
,
// 是否下级会员
}
function
OfferCard
(
props
:
Props
)
{
...
...
@@ -42,7 +44,8 @@ function OfferCard(props: Props) {
purchaseInquiryNo
,
isSign
=
false
,
canRegister
=
true
,
mallId
mallId
,
isSubMember
}
=
props
const
{
getMessage
}
=
useMessageIntl
()
...
...
@@ -56,6 +59,14 @@ function OfferCard(props: Props) {
}
}
},
[])
/** 未成为下级会员提示 */
const
handleIsSubMember
=
()
=>
{
Modal
.
warning
({
content
:
getMessage
(
'locales.warning'
,
'您还未申请成为入库供应商,请先申请后再{data}!'
,
{
data
:
getMessage
(
'locales.baojia'
,
'报价'
)
})
})
}
return
(
<
ul
className=
{
styles
[
'offer-main'
]
}
>
<
li
className=
{
styles
[
'card-title'
]
}
>
...
...
@@ -109,7 +120,7 @@ function OfferCard(props: Props) {
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/offter/quote?id=${id}&number=${purchaseInquiryNo}`
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
`${MEMBER_CENTER_URL}/memberCenter/procurementAbility/offter/quote?id=${id}&number=${purchaseInquiryNo}`
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
apps/srm/web/page/purchaseInquiry/index.tsx
View file @
4f843a40
...
...
@@ -112,22 +112,22 @@ const PurchaseInquiry: SFC<PurchaseInquiryPropsType> = (props) => {
}
getManageMemberAdvertFindAllByColumnType
(
data
).
then
((
res
)
=>
{
setAdvertFindList
(
res
.
data
)
})
})
}
else
{
getManageContentAdvertFindAllByColumnType
(
data
).
then
((
res
:
any
)
=>
{
setAdvertFindList
(
res
.
data
)
})
}
}
const
{
shopId
:
shopIds
}
=
props
.
match
?.
params
||
{}
useEffect
(()
=>
{
const
SrmDataSource
:
any
=
getCookie
(
'SrmDataSource'
)
let
param
=
{}
let
shopId
=
0
;
if
(
mallInfo
)
{
...
...
@@ -286,6 +286,7 @@ const PurchaseInquiry: SFC<PurchaseInquiryPropsType> = (props) => {
btnText=
{
fnGetBtnText
(
item
.
isRegister
>
0
,
item
.
days
,
item
.
hours
,
item
.
minutes
)
}
isSign=
{
(
userInfo
&&
userInfo
.
userId
)
?
true
:
false
}
canRegister=
{
item
.
canRegister
}
isSubMember=
{
item
.
isSubMember
}
></
OfferCard
>
</
li
>
})
...
...
apps/srm/web/page/shopIndex/components/InquiryCard/index.tsx
View file @
4f843a40
...
...
@@ -5,7 +5,7 @@ import React from 'react'
import
styles
from
'./index.less'
import
{
integrationTime
}
from
'@/utils/commonlyFn'
import
{
Button
}
from
'antd'
import
{
Button
,
Modal
}
from
'antd'
import
{
MEMBER_CENTER_URL
,
LOGIN_DOMAIN
}
from
'@/constants'
import
{
ShoppingCartOutlined
,
HistoryOutlined
}
from
'@ant-design/icons'
import
{
useMessageIntl
}
from
'@linkseeks/lingxi-utils'
...
...
@@ -42,6 +42,7 @@ interface Props {
isType
?:
PAGETYPES
.
BIDDING_ORDER
|
PAGETYPES
.
INQUIRY_ORDER
|
PAGETYPES
.
TENDER_ORDER
,
shopId
?:
string
,
isMePublish
?:
number
,
// 是否是自己发布的竞价单 1:是; 0:否;
isSubMember
?:
boolean
,
// 是否下级会员
}
/**
* @cardTitle 卡片标题
...
...
@@ -71,6 +72,7 @@ function InquiryCard(props: Props) {
isType
,
shopId
,
isMePublish
,
isSubMember
}
=
props
/**
...
...
@@ -87,7 +89,12 @@ function InquiryCard(props: Props) {
return
''
}
console
.
log
(
isType
,
'isType'
)
/** 未成为下级会员提示 */
const
handleIsSubMember
=
()
=>
{
Modal
.
warning
({
content
:
getMessage
(
'locales.warning'
,
'您还未申请成为入库供应商,请先申请后再{data}!'
,
{
data
:
jumpUrl
===
'InquiryDetail'
?
getMessage
(
'locales.baojia'
,
'报价'
)
:
getMessage
(
'locales.baoming'
,
'报名'
)
})
})
}
return
(
<
ul
className=
{
styles
[
'inquiry-main'
]
}
style=
{
{
width
:
props
.
cardWidth
,
borderColor
:
topBorderColor
?
topBorderColor
:
'#ffffff'
}
}
>
...
...
@@ -159,7 +166,7 @@ function InquiryCard(props: Props) {
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
@@ -171,15 +178,15 @@ function InquiryCard(props: Props) {
{
(
isType
===
PAGETYPES
.
TENDER_ORDER
&&
canRegister
)
&&
(
<
li
className=
{
styles
[
'sign-btn-warp'
]
}
>
<>
<
Button
className=
{
`${styles['sign-btn']} ${((btnTitle ===
'立即报价' || btnTitle === '立即报名'
) && canRegister) ? '' : styles['sign-btn-gery']}`
}
block
>
<
Button
className=
{
`${styles['sign-btn']} ${((btnTitle ===
getMessage('locales.lijibaojia', '立即报价') || btnTitle === getMessage('locales.lijibaoming', '立即报名')
) && canRegister) ? '' : styles['sign-btn-gery']}`
}
block
>
{
btnTitle
}
</
Button
>
{
((
btnTitle
===
'立即报价'
||
btnTitle
===
'立即报名'
)
&&
canRegister
)
&&
((
btnTitle
===
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
||
btnTitle
===
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
)
&&
canRegister
)
&&
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
@@ -191,15 +198,15 @@ function InquiryCard(props: Props) {
{
(
isType
===
PAGETYPES
.
BIDDING_ORDER
&&
!!!!!
isMePublish
)
&&
(
<
li
className=
{
styles
[
'sign-btn-warp'
]
}
>
<>
<
Button
className=
{
`${styles['sign-btn']} ${((btnTitle ===
'立即报价' || btnTitle === '立即报名'
) && !!!isSignUp) ? '' : styles['sign-btn-gery']}`
}
block
>
<
Button
className=
{
`${styles['sign-btn']} ${((btnTitle ===
getMessage('locales.lijibaojia', '立即报价') || btnTitle === getMessage('locales.lijibaoming', '立即报名')
) && !!!isSignUp) ? '' : styles['sign-btn-gery']}`
}
block
>
{
btnTitle
}
</
Button
>
{
((
btnTitle
===
'立即报价'
||
btnTitle
===
'立即报名'
)
&&
!!!
isSignUp
)
&&
((
btnTitle
===
getMessage
(
'locales.lijibaojia'
,
'立即报价'
)
||
btnTitle
===
getMessage
(
'locales.lijibaoming'
,
'立即报名'
)
)
&&
!!!
isSignUp
)
&&
<>
{
isSign
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
(
isSubMember
?
<
a
className=
'all-jump'
href=
{
fnGetsignUpUrl
()
}
></
a
>
:
<
div
className=
'all-jump'
onClick=
{
()
=>
handleIsSubMember
()
}
/>)
:
<
a
className=
'all-jump'
href=
{
LOGIN_DOMAIN
}
></
a
>
}
...
...
apps/srm/web/page/shopIndex/components/PurchaseModular/ShopInquiryCardModular.tsx
View file @
4f843a40
...
...
@@ -77,7 +77,7 @@ function ShopInquiryCardModular(props: Props) {
}
const
shopId
=
findRouterShopId
()
return
(
// 企业采购-首页卡片
<
div
>
...
...
@@ -118,6 +118,7 @@ function ShopInquiryCardModular(props: Props) {
isSignUp=
{
item
.
isSignUp
}
isType=
{
pageType
}
isMePublish=
{
item
.
isMePublish
}
isSubMember=
{
item
.
isSubMember
}
></
InquiryCard
>
</
li
>
})
...
...
apps/srm/web/page/shopIndex/components/PurchaseModular/index.tsx
View file @
4f843a40
...
...
@@ -108,6 +108,7 @@ function PurchaseModular(props: Props) {
id=
{
item
.
id
}
shopId=
{
shopId
}
isType=
{
pageType
}
isSubMember=
{
item
.
isSubMember
}
></
InquiryCard
>
</
li
>
})
...
...
env.js
View file @
4f843a40
...
...
@@ -55,9 +55,20 @@ module.exports = {
SINGLE_SRM
:
undefined
,
},
// 0418 版本
v20418
:
{
"v20418-1"
:
{
SITE_ID
:
'1'
,
BACK_GATEWAY
:
'http://10.0.1.146:8100'
,
BACK_GATEWAY
:
'http://10.0.0.27:8100'
,
USE_ROUTE_CONFIG
:
true
,
SOCKET_URL
:
'ws://10.0.0.27:9880'
,
MEMBER_URL
:
'lx-member'
,
IM_URL
:
'lx-im'
,
H5_LINK
:
''
,
SINGLE_SRM
:
undefined
,
},
// 0518 版本
v20518
:
{
SITE_ID
:
'1'
,
BACK_GATEWAY
:
'http://10.0.1.156:8100'
,
USE_ROUTE_CONFIG
:
true
,
SOCKET_URL
:
'ws://10.0.1.146:9880'
,
MEMBER_URL
:
'jinfa-platform-test'
,
...
...
locales/srm/en-US.js
View file @
4f843a40
...
...
@@ -269,4 +269,5 @@ module.exports = {
'locales.baoming'
:
'Registration'
,
'locales.baomingjieshu'
:
'Registration End'
,
'locales.moneySign'
:
'$'
,
'locales.warning'
:
`You haven 't applied to be a supplier. Please apply first and then{data}`
};
locales/srm/ko-KR.js
View file @
4f843a40
...
...
@@ -263,4 +263,5 @@ module.exports = {
'locales.baoming'
:
'등록'
,
'locales.baomingjieshu'
:
'등록이 끝나다'
,
'locales.moneySign'
:
'₩'
,
'locales.warning'
:
'입고 공급자가 되기 위해 아직 요청하지 않았으므로 먼저 신청한 후{data}'
}
\ No newline at end of file
locales/srm/zh-CN.js
View file @
4f843a40
...
...
@@ -263,4 +263,5 @@ module.exports = {
'locales.baoming'
:
'报名'
,
'locales.baomingjieshu'
:
'报名结束'
,
'locales.moneySign'
:
'¥'
,
'locales.warning'
:
'您还未申请成为入库供应商,请先申请后再{data}'
}
package.json
View file @
4f843a40
...
...
@@ -58,6 +58,7 @@
"getconfig:v2"
:
"cross-env PRO_ENV=v2 yarn scripts:build"
,
"getconfig:v2-0318"
:
"cross-env PRO_ENV=v2-0318 yarn scripts:build"
,
"getconfig:v20418"
:
"cross-env PRO_ENV=v20418 yarn scripts:build"
,
"getconfig:v20518"
:
"cross-env PRO_ENV=v20518 yarn scripts:build"
,
"getconfig:v2scm"
:
"cross-env PRO_ENV=v2scm yarn scripts:build"
,
"getconfig:study"
:
"cross-env PRO_ENV=study yarn scripts:build"
,
"getconfig:v2-demo"
:
"cross-env PRO_ENV=v2-demo yarn scripts:build"
,
...
...
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