Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Awaiting Payment May 16th] [Wave Collect] [Xero] Put Xero display logic under a specific beta #41394

Closed
lakchote opened this issue May 1, 2024 · 5 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Daily KSv2 Engineering

Comments

@lakchote
Copy link
Contributor

lakchote commented May 1, 2024

We need to put Xero under a specific beta since QBO will be released sooner and they share the same accounting menu.

@lakchote lakchote self-assigned this May 1, 2024
@lakchote lakchote added the Daily KSv2 label May 1, 2024
@ShridharGoel
Copy link
Contributor

ShridharGoel commented May 1, 2024

Proposal

Please re-state the problem that we are trying to solve in this issue.

Put Xero in beta.

What is the root cause of that problem?

New change.

What changes do you think we should make in order to solve the problem?

Add the below logic in PolicyAccountingPage:

const {canUseXeroIntegration} = usePermissions();

const accountingIntegrations = Object.values(CONST.POLICY.CONNECTIONS.NAME).filter((name) => {
    if (name === CONST.POLICY.CONNECTIONS.NAME.XERO) {
        if (!canUseXeroIntegration) {
            if (!!policy?.connections?.xero || connectionSyncProgress?.connectionName === CONST.POLICY.CONNECTIONS.NAME.XERO) {
                return true
            }
            return false
        }
    }

    return true
});

This will ensure that Xero will not show only if it's not already connected.

In Permissions.ts:

function canUseXeroIntegration(betas: OnyxEntry<Beta[]>): boolean {
    return !!betas?.includes(CONST.BETAS.XERO_INTEGRATION) || canUseAllBetas(betas);
}

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels May 1, 2024
@lakchote
Copy link
Contributor Author

lakchote commented May 1, 2024

@ShridharGoel since I've assigned myself already, no need to submit proposals. Thank you.

@trjExpensify
Copy link
Contributor

Deployed to prod 9 hours ago. Assigning Rushat for the PR review.

@trjExpensify trjExpensify changed the title [Wave Collect] [Xero] Put Xero display logic under a specific beta [Awaiting Payment May 16th] [Wave Collect] [Xero] Put Xero display logic under a specific beta May 9, 2024
@trjExpensify trjExpensify added Awaiting Payment Auto-added when associated PR is deployed to production and removed Reviewing Has a PR in review labels May 9, 2024
@trjExpensify
Copy link
Contributor

Payment summary as follows:

$250 to @rushatgabhane for the C+ review of the PR

@trjExpensify trjExpensify self-assigned this May 9, 2024
@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels May 15, 2024
@trjExpensify
Copy link
Contributor

Payment will be handled centrally when we wrap the project, we can close this as the regression period is over.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Daily KSv2 Engineering
Projects
No open projects
Archived in project
Development

No branches or pull requests

4 participants