Skip to content

Commit 48a4cb8

Browse files
committed
Merge branch 'main' into fix/68141
2 parents 7b2d628 + 6ec3d55 commit 48a4cb8

56 files changed

Lines changed: 609 additions & 186 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Mobile-Expensify

android/app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,8 @@ android {
114114
minSdkVersion rootProject.ext.minSdkVersion
115115
targetSdkVersion rootProject.ext.targetSdkVersion
116116
multiDexEnabled rootProject.ext.multiDexEnabled
117-
versionCode 1009019702
118-
versionName "9.1.97-2"
117+
versionCode 1009019703
118+
versionName "9.1.97-3"
119119
// Supported language variants must be declared here to avoid from being removed during the compilation.
120120
// This also helps us to not include unnecessary language variants in the APK.
121121
resConfigs "en", "es"

ios/NewExpensify/Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
</dict>
4545
</array>
4646
<key>CFBundleVersion</key>
47-
<string>9.1.97.2</string>
47+
<string>9.1.97.3</string>
4848
<key>FullStory</key>
4949
<dict>
5050
<key>OrgId</key>

ios/NotificationServiceExtension/Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<key>CFBundleShortVersionString</key>
1414
<string>9.1.97</string>
1515
<key>CFBundleVersion</key>
16-
<string>9.1.97.2</string>
16+
<string>9.1.97.3</string>
1717
<key>NSExtension</key>
1818
<dict>
1919
<key>NSExtensionPointIdentifier</key>

ios/ShareViewController/Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<key>CFBundleShortVersionString</key>
1414
<string>9.1.97</string>
1515
<key>CFBundleVersion</key>
16-
<string>9.1.97.2</string>
16+
<string>9.1.97.3</string>
1717
<key>NSExtension</key>
1818
<dict>
1919
<key>NSExtensionAttributes</key>

package-lock.json

Lines changed: 6 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "new.expensify",
3-
"version": "9.1.97-2",
3+
"version": "9.1.97-3",
44
"author": "Expensify, Inc.",
55
"homepage": "https://new.expensify.com",
66
"description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.",
@@ -192,7 +192,7 @@
192192
"react-native-release-profiler": "^0.2.1",
193193
"react-native-render-html": "6.3.1",
194194
"react-native-safe-area-context": "5.4.0",
195-
"react-native-screens": "4.11.1",
195+
"react-native-screens": "4.12.0",
196196
"react-native-share": "11.0.2",
197197
"react-native-sound": "^0.11.2",
198198
"react-native-svg": "15.9.0",

src/CONST/index.ts

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1135,6 +1135,7 @@ const CONST = {
11351135
ACTIONABLE_ADD_PAYMENT_CARD: 'ACTIONABLEADDPAYMENTCARD',
11361136
ACTIONABLE_JOIN_REQUEST: 'ACTIONABLEJOINREQUEST',
11371137
ACTIONABLE_MENTION_WHISPER: 'ACTIONABLEMENTIONWHISPER',
1138+
ACTIONABLE_MENTION_INVITE_TO_SUBMIT_EXPENSE_CONFIRM_WHISPER: 'ACTIONABLEMENTIONINVITETOSUBMITEXPENSECONFIRMWHISPER',
11381139
ACTIONABLE_REPORT_MENTION_WHISPER: 'ACTIONABLEREPORTMENTIONWHISPER',
11391140
ACTIONABLE_TRACK_EXPENSE_WHISPER: 'ACTIONABLETRACKEXPENSEWHISPER',
11401141
POLICY_EXPENSE_CHAT_WELCOME_WHISPER: 'POLICYEXPENSECHATWELCOMEWHISPER',
@@ -1318,8 +1319,12 @@ const CONST = {
13181319
},
13191320
ACTIONABLE_MENTION_WHISPER_RESOLUTION: {
13201321
INVITE: 'invited',
1322+
INVITE_TO_SUBMIT_EXPENSE: 'inviteToSubmitExpense',
13211323
NOTHING: 'nothing',
13221324
},
1325+
ACTIONABLE_MENTION_INVITE_TO_SUBMIT_EXPENSE_CONFIRM_WHISPER: {
1326+
DONE: 'done',
1327+
},
13231328
ACTIONABLE_TRACK_EXPENSE_WHISPER_RESOLUTION: {
13241329
NOTHING: 'nothing',
13251330
},
@@ -5320,6 +5325,35 @@ const CONST = {
53205325
USAA: 'usaa',
53215326
},
53225327

5328+
/**
5329+
* Bank account names (user friendly)
5330+
*/
5331+
get BANK_NAMES_USER_FRIENDLY() {
5332+
return {
5333+
[this.BANK_NAMES.EXPENSIFY]: 'Expensify',
5334+
[this.BANK_NAMES.AMERICAN_EXPRESS]: 'American Express',
5335+
[this.BANK_NAMES.BANK_OF_AMERICA]: 'Bank of America',
5336+
[this.BANK_NAMES.BB_T]: 'Truist',
5337+
[this.BANK_NAMES.CAPITAL_ONE]: 'Capital One',
5338+
[this.BANK_NAMES.CHASE]: 'Chase',
5339+
[this.BANK_NAMES.CHARLES_SCHWAB]: 'Charles Schwab',
5340+
[this.BANK_NAMES.CITIBANK]: 'Citibank',
5341+
[this.BANK_NAMES.CITIZENS_BANK]: 'Citizens',
5342+
[this.BANK_NAMES.DISCOVER]: 'Discover',
5343+
[this.BANK_NAMES.FIDELITY]: 'Fidelity',
5344+
[this.BANK_NAMES.GENERIC_BANK]: 'Bank',
5345+
[this.BANK_NAMES.HUNTINGTON_BANK]: 'Huntington',
5346+
[this.BANK_NAMES.HUNTINGTON_NATIONAL]: 'Huntington National',
5347+
[this.BANK_NAMES.NAVY_FEDERAL_CREDIT_UNION]: 'Navy Federal Credit Union',
5348+
[this.BANK_NAMES.PNC]: 'PNC',
5349+
[this.BANK_NAMES.REGIONS_BANK]: 'Regions',
5350+
[this.BANK_NAMES.SUNTRUST]: 'SunTrust',
5351+
[this.BANK_NAMES.TD_BANK]: 'TD Bank',
5352+
[this.BANK_NAMES.US_BANK]: 'U.S. Bank',
5353+
[this.BANK_NAMES.USAA]: 'USAA',
5354+
};
5355+
},
5356+
53235357
/**
53245358
* Constants for maxToRenderPerBatch parameter that is used for FlatList or SectionList. This controls the amount of items rendered per batch, which is the next chunk of items
53255359
* rendered on every scroll.
@@ -6397,6 +6431,7 @@ const CONST = {
63976431
ASSIGNEE: 'assignee',
63986432
IN: 'in',
63996433
CARD: 'card',
6434+
WITHDRAWAL_ID: 'withdrawalID',
64006435
},
64016436
SYNTAX_OPERATORS: {
64026437
AND: 'and',

src/components/Attachments/AttachmentCarousel/extractAttachments.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,20 @@ function extractAttachments(
2121
parentReportAction,
2222
reportActions,
2323
report,
24-
}: {privateNotes?: Record<number, Note>; accountID?: number; parentReportAction?: OnyxEntry<ReportAction>; reportActions?: OnyxEntry<ReportActions>; report: OnyxEntry<Report>},
24+
isReportArchived,
25+
}: {
26+
privateNotes?: Record<number, Note>;
27+
accountID?: number;
28+
parentReportAction?: OnyxEntry<ReportAction>;
29+
reportActions?: OnyxEntry<ReportActions>;
30+
report: OnyxEntry<Report>;
31+
isReportArchived?: boolean;
32+
},
2533
) {
2634
const targetNote = privateNotes?.[Number(accountID)]?.note ?? '';
2735
const description = report?.description ?? '';
2836
const attachments: Attachment[] = [];
29-
const canUserPerformAction = canUserPerformWriteAction(report);
37+
const canUserPerformAction = canUserPerformWriteAction(report, isReportArchived);
3038
let currentLink = '';
3139

3240
const htmlParser = new HtmlParser({

src/components/Attachments/AttachmentCarousel/index.tsx

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import {View} from 'react-native';
44
import type {Attachment} from '@components/Attachments/types';
55
import FullScreenLoadingIndicator from '@components/FullscreenLoadingIndicator';
66
import useOnyx from '@hooks/useOnyx';
7+
import useReportIsArchived from '@hooks/useReportIsArchived';
78
import useThemeStyles from '@hooks/useThemeStyles';
89
import {canUseTouchScreen as canUseTouchScreenUtil} from '@libs/DeviceCapabilities';
910
import Navigation from '@libs/Navigation/Navigation';
@@ -19,6 +20,7 @@ function AttachmentCarousel({report, attachmentID, source, onNavigate, setDownlo
1920
const [reportActions] = useOnyx(`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${report.reportID}`, {canEvict: false, canBeMissing: true});
2021
const canUseTouchScreen = canUseTouchScreenUtil();
2122
const styles = useThemeStyles();
23+
const isReportArchived = useReportIsArchived(report.reportID);
2224

2325
const [page, setPage] = useState<number>();
2426
const [attachments, setAttachments] = useState<Attachment[]>([]);
@@ -41,11 +43,11 @@ function AttachmentCarousel({report, attachmentID, source, onNavigate, setDownlo
4143
const parentReportAction = report.parentReportActionID && parentReportActions ? parentReportActions[report.parentReportActionID] : undefined;
4244
let newAttachments: Attachment[] = [];
4345
if (type === CONST.ATTACHMENT_TYPE.NOTE && accountID) {
44-
newAttachments = extractAttachments(CONST.ATTACHMENT_TYPE.NOTE, {privateNotes: report.privateNotes, accountID, report});
46+
newAttachments = extractAttachments(CONST.ATTACHMENT_TYPE.NOTE, {privateNotes: report.privateNotes, accountID, report, isReportArchived});
4547
} else if (type === CONST.ATTACHMENT_TYPE.ONBOARDING) {
46-
newAttachments = extractAttachments(CONST.ATTACHMENT_TYPE.ONBOARDING, {parentReportAction, reportActions: reportActions ?? undefined, report});
48+
newAttachments = extractAttachments(CONST.ATTACHMENT_TYPE.ONBOARDING, {parentReportAction, reportActions: reportActions ?? undefined, report, isReportArchived});
4749
} else {
48-
newAttachments = extractAttachments(CONST.ATTACHMENT_TYPE.REPORT, {parentReportAction, reportActions: reportActions ?? undefined, report});
50+
newAttachments = extractAttachments(CONST.ATTACHMENT_TYPE.REPORT, {parentReportAction, reportActions: reportActions ?? undefined, report, isReportArchived});
4951
}
5052

5153
if (deepEqual(attachments, newAttachments)) {
@@ -84,7 +86,7 @@ function AttachmentCarousel({report, attachmentID, source, onNavigate, setDownlo
8486
onNavigate(attachment);
8587
}
8688
}
87-
}, [reportActions, parentReportActions, compareImage, attachments, setDownloadButtonVisibility, onNavigate, accountID, type, report]);
89+
}, [reportActions, parentReportActions, compareImage, attachments, setDownloadButtonVisibility, onNavigate, accountID, type, report, isReportArchived]);
8890

8991
if (page == null) {
9092
return (

0 commit comments

Comments
 (0)