* UI: Additional improvements to the User Invitation flow
Closes#6224.
* Clear invitation token only after the user can sign in
Fixes "404 Error on Follow-Up Visits" of #6236.
* Minor spacing fix
* Update accordion button
* Add updated image upload support on Crowdfund plugin
* Refactor crowdfund image upload fix
* update crowdfund url for greenfield api
* Resolve integration test assertion
* Remove superfluous and unused command argument
* Fix missing validation error
* Minor API controller update
* Property and usage fixes
* Fix test after merge
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
Gives the new methods a new name and re-adds the old ones in order to not break plugins. Simple enough backwartds compatible change, makred the old methods as obsolete to make plugin developers aware that new methods are available.
Validates missing and duplicate IDs on the edit actions and when creating/updating apps via the API.
Fails gracefully by excluding existing items without ID or with duplicate ID for the rest of the cases.
Fixes#6227.
* Wallet: Generate receive address automatically
This circumvents landing on a blank page with only the "generate address" button and automatically generates a new address, unless the Unreserve action was used.
* Fix close button leading to same page
* Fix tests
* Remove unreserve feature
---------
Co-authored-by: Nicolas Dorier <nicolas.dorier@gmail.com>
* Handle password reset when SMTP isn't configured or the configuration cannot be validated
* include rel in external a tag
* Simplify it
* Test fix
* Simplify a bit
* selenium test to manage users
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
Co-authored-by: Nicolas Dorier <nicolas.dorier@gmail.com>
* Store Branding: Apply brand color to backend as well
Closes#5990.
* Add adjustments for different theme scenarios
* Add description text
* Make it optional to apply the brand color to the backend
* Toggle color fixes
* POS: Fix accounting for manually entered keypad amounts
For keypad orders where there are products AND manual amount entries, we didn't account for the latter.
Fixes#6168.
* Adjust wording: "Manual entry" becomes "Custom Amount"
* Fix divisibility in invoice details of lightning amounts
This PR will show 11 decimal in the invoice details for BTC amount
of lightning payment methods.
It also hacks around the fact that some
lightning clients don't create the requested amount of sats, which
resulted in over or under payments. (Blink not supporting msats, and
strike)
Now, In that case, a payment method fee (which can be negative) called tweak fee
will be added to the prompt.
We are also hiding this tweak fee from the user in the checkout page in
order to not disturb the UI with inconsequential fee of 0.000000001 sats.
* Only show 8 digits in checkout, even if amount is 11 digits
* Server: Make sending email optional when adding user
Closes#6158.
* Generate custom invite token and store it in user blob
Closes btcpayserver/app/#46.
* QR code for user invite
Closes#6157.
* Text fix
* Resolve Additional Information from posData
* code formatting
* Minor adjustments
* Update ChromeDriver
* Revert and improve PosData partial
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
Co-authored-by: Nicolas Dorier <nicolas.dorier@gmail.com>
This is for the checkout page to properly redirect paid invoices with no payment methods (e.g. free invoices with zero amount) to either the receipt page or redirect URL. Only fall back to 404 if there is neither.
Fixes#6123.
* Include hover to display total sales per day
* Add label to top items as well
* Bring in recent Chart modifications from app
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
* Cleanups
* Add text entries for dictionary pages
* Wording: Keep Clone title consistent with Payment Request cloning
* Dictionaries: List used one first; badge for marking In use
* Greenfield: Add file endpoints and upload
- Endpoints for server files
- File upload using `multipart/form-data`
Closes#6074.
Can also be tested using cURL:
- `curl --location 'https://localhost:14142/api/v1/files' --header 'Authorization: token MY_API_TOKEN' --form 'file=@"LOCAL_FILEPATH"'`
- `curl --location 'https://localhost:14142/api/v1/users/me/picture' --header 'Authorization: token MY_API_TOKEN' --form 'file=@"LOCAL_FILEPATH"'`
* Revert UnresolvedUri changes
* Add upload for store logo
This is mostly for the POS, where either an individual item title might be the description, or in case of the cart and keypad, the name of the app will be displayed. The description is omitted if it matches the store name, to avoid duplicate titles.
Closes#5023.
On mobile, the description content was lacking horizontal padding. This adjusts it while also unifying the cards to work like the tiles on checkout: Below 400px width, we pull the to the edges of the screen, which makes it looks nicer and display better than as if they'd also have an outer margin.
Adjustments take effect on all POS view variants.
* Rename filter to storeid for consistency with other filters
* Greenfield: Add storeId to notification
* Cleanups
* Greenfield: Allow filtering notifications by store id
* Handle LNURL payouts better when amount is not allowee
* docker-compose: Add missing restart for merchant CLN container
* show sats not msats
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
* Greenfield: Refactor app endpoints
- Do not change unset data
- Clean up difference between request (template) and data (items/perks)
- Add missing properties (form id and custom tip percentage)
- Update docs
* Revert ToSettings changes in GreenfieldAppsController
* User: Add name and image URL
More personalization options, prerequisite for btcpayserver/app#3.
Additionally:
- Remove ambigious and read-only username from manage view.
- Improve email verification conditions and display.
- Greenfield: Update current user. Prerequisite for btcpayserver/app#13.
* Refactor UpdateCurrentUser
* Replace new columns by UserBlob
* Update email check and add test case for mailbox addresses
---------
Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
* Allow overrides on all methods
* Add non-returning SendHttpRequest methods
* Use SendHttpRequest consistently
* Use file-scoped namespace
* Rates: Set default null value for currencyPair
* Ensure it works with instances which have BTCPAY_ROOTPATH set
* UI: Move section navigation to sidebar
* Scroll active nav link into view
* Move CTAs to top right
* Server Settings: Make Policies first page
* Responsive table fixes
* Spacing fixes
* Add breadcrumb samples
* store settings fixes
* payment request fixes
* updates pull payment title
* adds invoice detail fix
* updates server settings breadcrumbs + copy fix
* Don't open Server Settings on Plugins page
* Add breadcrumbs to pull payment views
* adds breadcrumbs to account
* server and store breadcrumb fixes
* fixes access tokens
* Fix payment processor breadcrumbs
* fixes webhook 404
* Final touches
* Fix test
* Add breadcrumb for email rules page
* Design system updates
---------
Co-authored-by: dstrukt <gfxdsign@gmail.com>
* Search: Display text filters in search input
This changes the search text input to also display the filters, which don't have a special UI (e.g. dropdown). Those filters (e.g. orderid) were not displayed before and hence could not be reset.
Fixes#5984.
* Add and fix test
Adjust the LNURL settings so that minimum price items aren't capped and can be overpaid.
Also fixes the missing LNURL response for free items to return a proper LNURL error instead of just 404.
Fixes#5995.
* Design system updates
* Icon fix
* Add new icons, replace show/hide
* Icon replacements
* Test fix
* Icon replacements in Vault
* More icon replacements
* Final icon replacements, remove Font Awesome
* allow admin update default rate provider and default currency for stores
* Updated PR on allowing server admin to update currency
* update server settings to select default currency
* revert standard default currency
* clean up
* Minor rewording
---------
Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
* Remove deprecated CSS options
Closes#5945.
* Greenfield: Add brandColor to store APIs
Closes#5946.
* Migrate file IDs to URLs
Closes#5953.
* Greenfield: Add CSS and logo URL to store settings API
Closes#5945.
* Add migration test
* Store and Server branding can reference file's via fileid:ID
* Add PaymentSoundUrl to Store API
---------
Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
- Unify single/multiple inputs display
- Destination: Move labels above amount
- Coin Selection: Add sorting by amount and confirmations, add page size. Closes#5850
- Move PSBT and BIP21 buttons up to input related button group
- Turn checkboxes in Advanced Settings into toggles
- Improve spacings and button groups
* Support pluginable rate providers
This PR allows plugins to provide custom rate providers, that can be contextual to a store. For example, if you use the upcoming fiat offramp plugin, or the Blink plugin, you'll probably want to configure the fetch the rates from them since they are determining the actual fiat rrate to you. However, they require API keys. This PR enables these scenarios, even much more advanced ones, but for example:
* Install fiat offramp plugin
* Configure it
* You can now use the fiat offramp rate provider (no additional config steps beyond selecting the rate source from the select, or maybe the plugin would automatically set it for you once configured)
* Apply suggestions from code review
* Simplify
* Do not use BackgroundFetcherRateProvider for contextual rate prov
---------
Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
* Guard against running current master
With a longer release cycle for v2, we need to guard people from running master and corrupting their data. This adds a new requirement in that a special config must be set when running master. We will remove when v2 rc is ready.
* add envs
* Show Lightning node availability in navigation
Instead of simply communicating the setup state of the store's LN node, this now also checks its availability.
Closes #5940.
* Cleanups
* Add Selenium test for public node page and status in nav
* Cache the available lightning node result
---------
Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
Once more an improvement for the receipt, which also fixes#5882:
- Unify data displayed on the web and print version
- Split cart and additional data and ensure additional data is displayed
- Do not display extra subtotal row if there are no tips or discounts
- Make PosData partial more universal and backwards-compatible by using case insensitive key lookups
Fixes#5917, which is a regression introduced in #5776. The Tor-check must happen to prevent redirecting, but we must still return true if we already resolved an `appId`.
* Adding Tether as BTCPay Server Foundation Supporter
* Adding Tether to _BTCPaySupporters partial as well
* Modfying supporter_strike.svg to have white backgroundf or dark mode
* Modifying supporter_tether.svg to fit in the 150x100 box
* Centering Tether shape
* Specify mailto: prefix for emails in Server Settings
* resolve test failure
* Update wording
* Apply mailto-prefix on setting change
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
* Onboarding: Invite new users
- Separates the user self-registration and invite cases
- Adds invitation email for users created by the admin
- Adds invitation tokens to verify user was invited
- Adds handler action for invite links
- Refactors `UserEventHostedService`
- Fixes#5726.
* Add permissioned form tag helper
* Better way of changing a user's role
* Test fixes
* Providing additional parameter for info message
* Refactoring code to remove parameter and only set status message in LoadFromBIP21 if not present
* Update BTCPayServer/Controllers/UIWalletsController.cs
---------
Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>
* Add admin option to show item list for keypad view
* Refactor common POS Vue mixin
* Add item list to POS keypad
* Add recent transactions to cart
* Keypad: Pass tip and discount as cart does
* Keypad and cart tests
* Improve offcanvas button
---------
Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>
* If pull payment opened in mobile, use deeplink to setup card
* Allow passing LNURLW to register boltcard
* debug
* debug
* debug
* Only show setup/reset when the page is fully loaded
* Apply suggestions from code review
---------
Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>
* (bug) treat xmr wallet directory as required
The wallet directory configuration setting is required
because the `UIMoneroLikeStoreController`'s
`GetMoneroLikePaymentMethodViewModel` method checks if the wallet file
exists, and to do that in needs the directory.
* (feat) xmr settlement thresholds
Adds the ability to select zero, 1, 10, or a custom number of
confirmations as the payment settlement threshold.
* (review) fix validation message not showing
---------
Co-authored-by: Henry Hollingworth <henry.hollingworth@alcoa.com>
* PoS app to show POS view for easy setup
* update selenium test
* Updates
* Add QR code icon
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
* Apps: Make app name the default title
Successor of #5762 with a way simpler approach. Allows the user-facing title to be set, but defaults it to the app name instead of "Tea shop".
* Test fixes
As discussed on #5718, there is no need for the store logo to be provided in square dimension. As it populates its own row on the public page layouts, we can remove that restriction and make it adaptable by providing only maximum height and width.
* Server Users: More precise message when inviting users
This lets the admin who invited a new user know whether or not an email has been sent. If the SMTP server hasn't been set up, they need to share the invite link with the user.
* Onboarding: Invite new users
- Separates the user self-registration and invite cases
- Adds invitation email for users created by the admin
- Adds invitation tokens to verify user was invited
- Adds handler action for invite links
- Refactors `UserEventHostedService`
* Remove duplicate status message from views that use the wizard layout
* Auto-approve users created by an admin
* Notify admins via email if a new account requires approval
* Update wording
* Fix update user error
* Fix redirect to email confirmation in invite action
* Fix precondition checks after signup
* Improve admin notification
Send notification only if the user does not require email confirmation or when they confirmed their email address. Rationale: We want to inform admins only about qualified users and not annoy them with bot registrations.
* Allow approval alongside resending confirm email
* Use user email in log messages instead of ID
* Prevent unnecessary notification after email confirmation
* Use ApplicationUser type explicitly
* Fix after rebase
* Refactoring: Do not subclass UserRegisteredEvent
* Reposition the camera scan icon in the wallet > send functionality
* refactored changes
* Minor adjustments
---------
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
* UI: Deprecate the custom CSS options
As discussed with @pavlenex we are deprecating the custom CSS options for particular entities (payemnt request, pull payment, POS, crowdfund) in favor of the store branding approach.
This displays the custom CSS section only if these values are set already.
* Add IDs to html element
This will allow styling of individual entities.
* Admin overview of the stores on the instance
POC/Draft for #5674.
* Enable admin to access foreign stores
* Remove stores list link
* UI updates
* Grant admins guest access to foreign stores
* Optimize cookie auth handler
* Test fix
* Revert changes related to StoreRepository.FindStore with isAdmin
* webhook tests
* fixes and add docs
* Do not update FormResponse and StoreId in update/create PullPayment
---------
Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
* Server Settings: Customize instance name and add contact URL
- The custom instance name would improve #5563
- Added contact URL closes#4806
* Fix custom logo display
* Crowfund : Add Buyer information / Additional information(forms) like POS
* PR 5659 - changes
* Cleanups
* fix perk
* Crowdfund form tests
* Add Selenium test for Crowfund
* Selenium update
* update Selenium
* selenium update
* update selenium
* Test fixes and view improvements
* Cleanups
* do not use hacky form element for form detection
---------
Co-authored-by: nisaba <infos@nisaba.solutions>
Co-authored-by: Dennis Reimann <mail@dennisreimann.de>
Co-authored-by: Kukks <evilkukka@gmail.com>
Closes#5773.
- Adds seconds to the displayed date and time
- Adds a tooltip that displays the full date and time including milliseconds
- Reintroduced the colored text in case of unusual events/states (this didn't work before)