fix: 逻辑补全
This commit is contained in:
@@ -24,12 +24,12 @@ function isFull(counts) {
|
|||||||
} = counts;
|
} = counts;
|
||||||
|
|
||||||
if (
|
if (
|
||||||
max_players === current_players &&
|
current_players >= max_players &&
|
||||||
is_substitute_supported === IsSubstituteSupported.NOTSUPPORT
|
is_substitute_supported === IsSubstituteSupported.NOTSUPPORT
|
||||||
) {
|
) {
|
||||||
return true;
|
return true;
|
||||||
} else if (
|
} else if (
|
||||||
max_players === current_players &&
|
current_players >= max_players &&
|
||||||
is_substitute_supported === IsSubstituteSupported.SUPPORT
|
is_substitute_supported === IsSubstituteSupported.SUPPORT
|
||||||
) {
|
) {
|
||||||
return max_substitute_players === current_substitute_count;
|
return max_substitute_players === current_substitute_count;
|
||||||
@@ -45,7 +45,7 @@ function RmbIcon() {
|
|||||||
function matchNtrpRequestment(
|
function matchNtrpRequestment(
|
||||||
target?: string,
|
target?: string,
|
||||||
min?: string,
|
min?: string,
|
||||||
max?: string
|
max?: string,
|
||||||
): boolean {
|
): boolean {
|
||||||
// 目标值为空或 undefined
|
// 目标值为空或 undefined
|
||||||
if (!target?.trim()) return true;
|
if (!target?.trim()) return true;
|
||||||
@@ -123,7 +123,7 @@ export default function StickyButton(props) {
|
|||||||
|
|
||||||
Taro.navigateTo({
|
Taro.navigateTo({
|
||||||
url: `/login_pages/index/index?redirect=${encodeURIComponent(
|
url: `/login_pages/index/index?redirect=${encodeURIComponent(
|
||||||
fullPath
|
fullPath,
|
||||||
)}`,
|
)}`,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -138,7 +138,7 @@ export default function StickyButton(props) {
|
|||||||
const matchNtrpReq = matchNtrpRequestment(
|
const matchNtrpReq = matchNtrpRequestment(
|
||||||
ntrp_level,
|
ntrp_level,
|
||||||
skill_level_min,
|
skill_level_min,
|
||||||
skill_level_max
|
skill_level_max,
|
||||||
);
|
);
|
||||||
|
|
||||||
const gameManageRef = useRef();
|
const gameManageRef = useRef();
|
||||||
@@ -173,7 +173,7 @@ export default function StickyButton(props) {
|
|||||||
}, [getCommentCount]);
|
}, [getCommentCount]);
|
||||||
|
|
||||||
function generateTextAndAction(
|
function generateTextAndAction(
|
||||||
user_action_status: null | { [key: string]: boolean }
|
user_action_status: null | { [key: string]: boolean },
|
||||||
):
|
):
|
||||||
| undefined
|
| undefined
|
||||||
| { text: string | React.FC; action?: () => void; available?: boolean } {
|
| { text: string | React.FC; action?: () => void; available?: boolean } {
|
||||||
@@ -271,7 +271,7 @@ export default function StickyButton(props) {
|
|||||||
const res = await OrderService.getUnpaidOrder(id);
|
const res = await OrderService.getUnpaidOrder(id);
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
navto(
|
navto(
|
||||||
`/order_pages/orderDetail/index?id=${res.data.order_info.order_id}`
|
`/order_pages/orderDetail/index?id=${res.data.order_info.order_id}`,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
@@ -387,7 +387,7 @@ export default function StickyButton(props) {
|
|||||||
<View
|
<View
|
||||||
className={classnames(
|
className={classnames(
|
||||||
styles["detail-main-action"],
|
styles["detail-main-action"],
|
||||||
available ? "" : styles.disabled
|
available ? "" : styles.disabled,
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
<View
|
<View
|
||||||
|
|||||||
Reference in New Issue
Block a user