|
@@ -364,21 +364,15 @@ const ActivityBtnComponent: React.FC<IActivityBtnComponent> = props => {
|
|
|
return { title: title[type] }
|
|
|
}
|
|
|
// 权限判断
|
|
|
- const handleCheckPower = (
|
|
|
- HasPermission: INewPermissionType,
|
|
|
- isResearch: boolean,
|
|
|
- isResearchSpecial: boolean,
|
|
|
- activityPay = true
|
|
|
- ) => {
|
|
|
+ const handleCheckPower = (HasPermission: INewPermissionType, isResearch: boolean, isResearchSpecial: boolean) => {
|
|
|
// 如果接口没返回权限则跳过
|
|
|
if (!HasPermission) return true
|
|
|
|
|
|
// 1.先判断权限,无权限则弹框
|
|
|
if (HasPermission !== INewPermissionType.OK) {
|
|
|
// 列表的按钮点击,无权限时,需要进入详情页
|
|
|
- console.log(activityPay)
|
|
|
|
|
|
- if (btnGrous !== 'detail' && activityPay) {
|
|
|
+ if (btnGrous !== 'detail' && login2p.userInfo?.IsShowWxPaySet) {
|
|
|
isSpecial
|
|
|
? window.open(`/activity/info/${(item as IActivitySpecialListItem).ActivityId}`)
|
|
|
: window.open(`/activity/detail/${(item as IActivityTypeListItem).ActivityId}`)
|
|
@@ -425,8 +419,7 @@ const ActivityBtnComponent: React.FC<IActivityBtnComponent> = props => {
|
|
|
const powerCheck = handleCheckPower(
|
|
|
item?.AuthInfo?.HasPermission,
|
|
|
item?.IsResearch,
|
|
|
- (item as IActivityTypeListItem)?.IsResearchSpecial,
|
|
|
- (item as IActivityTypeListItem)?.IsShowWxPay
|
|
|
+ (item as IActivityTypeListItem)?.IsResearchSpecial
|
|
|
)
|
|
|
|
|
|
if (!powerCheck) return
|
|
@@ -716,7 +709,7 @@ const ActivityBtnComponent: React.FC<IActivityBtnComponent> = props => {
|
|
|
const handleReturnGoOn = (res: IActivityCheckRes) => {
|
|
|
// 1.权限
|
|
|
if (!res.CheckPermission) {
|
|
|
- handleCheckPower(res.HasPermission, res.IsResearch, res?.IsResearchSpecial, res.IsShowWxPaySet)
|
|
|
+ handleCheckPower(res.HasPermission, res.IsResearch, res?.IsResearchSpecial)
|
|
|
return
|
|
|
}
|
|
|
// 1.1.人数
|