-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Wrong validation message when sending invoice #51545
Wrong validation message when sending invoice #51545
Conversation
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
@ahmedGaber93 Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
src/CONST.ts
Outdated
@@ -353,6 +353,7 @@ const CONST = { | |||
OLD_DOT_ANDROID: 'https://play.google.com/store/apps/details?id=org.me.mobiexpensifyg&hl=en_US&pli=1', | |||
OLD_DOT_IOS: 'https://apps.apple.com/us/app/expensify-expense-tracker/id471713959', | |||
}, | |||
URL_DEFAULT_SCHEME: 'http', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it will be more clean if we rename it to COMPANY_WEBSITE_DEFAULT_SCHEME
because it is the default for company website only, not all URLs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Krishna2323 bump!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the bump. Will finish this one today.
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
85d59af
to
eba8073
Compare
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
@ahmedGaber93, should we remove the prefix from bank account step? The prefix comes from App/src/libs/BankAccountUtils.ts Lines 5 to 7 in 1351038
|
@Krishna2323 Yes, remove it, I think all business website inputs should be consistent. |
@@ -49,7 +49,7 @@ function IOURequestStepCompanyInfo({route, report, transaction}: IOURequestStepC | |||
const errors = ValidationUtils.getFieldRequiredErrors(values, [INPUT_IDS.COMPANY_NAME, INPUT_IDS.COMPANY_WEBSITE]); | |||
|
|||
if (values.companyWebsite) { | |||
if (!ValidationUtils.isValidWebsite(values.companyWebsite)) { | |||
if (!ValidationUtils.isValidWebsite(Str.sanitizeURL(values.companyWebsite, CONST.COMPANY_WEBSITE_DEFAULT_SCHEME))) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
src/libs/actions/Policy/Policy.ts
Outdated
companyWebsite, | ||
companyWebsite: Str.sanitizeURL(companyWebsite, CONST.COMPANY_WEBSITE_DEFAULT_SCHEME), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need this, we can pass the sanitized companyWebsite
value as I explained it here
Yes, I think all business website inputs should be consistent. Also, we can add default value |
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
Signed-off-by: krishna2323 <belivethatkg@gmail.com>
@ahmedGaber93, please review it once more when you have a chance. Thanks! |
@Krishna2323 changes looks good, just for consistent add |
…InvoicingDetailsWebsite. Signed-off-by: krishna2323 <belivethatkg@gmail.com>
Reviewer Checklist
Screenshots/VideosAndroid: Nativea.mp4Android: mWeb Chromeaw.mp4iOS: Nativei.mp4iOS: mWeb Safariiw.mp4MacOS: Chrome / Safari20241104175829534.mp4w.mp4MacOS: Desktop20241104180230959.mp4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/marcaaron in version: 9.0.58-0 🚀
|
🚀 Deployed to production by https://github.com/Julesssss in version: 9.0.58-2 🚀
|
Details
Fixed Issues
$ #49286
PROPOSAL: #49286 (comment)
Tests
Offline tests
QA Steps
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
android_native.mp4
Android: mWeb Chrome
android_chrome.mp4
iOS: Native
ios_native.mp4
iOS: mWeb Safari
ios_safari.mp4
MacOS: Chrome / Safari
web_chrome.mp4
MacOS: Desktop
desktop_app.mp4