Commit graph

56 commits

Author SHA1 Message Date
Sérgio Salgado
fded22f39a feat: add user management screen
feat: login screen

fix: login routing and layout

feat: add users migration

feat: passport login strategy

fix: users migration

feat: simple authentication

fix: request body

feat: JWT authorization

feat: 2fa step on login

feat: 2fa flow

feat: add rememberme to req body

fix: hide 2fa secret from jwt

fix: block login access to logged in user

fix: rerouting to wizard

refactor: login screen

feat: setup 2fa state on login

feat: 2fa secret qr code

fix: remove jwt from 2fa secret

fix: wizard redirect after login

fix: 2fa setup flow

fix: user id to uuid

feat: user roles

feat: user sessions and db persistence

feat: session saving on DB and cookie

refactor: unused code

feat: cookie auto renew on request

feat: get user data endpoint

fix: repeated requests

feat: react routing

fix: private routes

refactor: auth

feat: sessions aware of ua and ip

feat: sessions on gql

feat: session management screen

feat: replace user_tokens usage for users

feat: user deletion also deletes active sessions

feat: remember me alters session cookie accordingly

feat: last session by all users

fix: login feedback

fix: page loading UX

feat: routes based on user role

feat: header aware of roles

feat: reset password

fix: reset password endpoint

feat: handle password change

feat: reset 2FA

feat: user role on management screen

feat: change user role

fix: user last session query

fix: context

fix: destroy own session

feat: reset password now resets sessions

feat: reset 2fa now resets sessions

refactor: user data

refactor: user management screen

feat: user enable

feat: schema directives

fix: remove schema directive temp

feat: create new users

feat: register endpoint

feat: modals for reset links

fix: directive Date errors

feat: superuser directive

feat: create user url modal

fix: user management layout

feat: confirmation modals

fix: info text

feat: 2fa input component

feat: code input on 2fa state

feat: add button styling

feat: confirmation modal on superuser action

feat: rework 2fa setup screen

feat: rework reset 2fa screen

fix: session management screen

fix: user management screen

fix: blacklist roles

chore: migrate old customer values to new columns

fix: value migration

fix: value migration

refactor: remove old code
2021-05-03 23:00:41 +01:00
Taranto
7b3b2fb72d Merge remote-tracking branch 'upstream/release-7.5.0' into merge-release-7.5.0-into-dev 2021-04-21 17:43:13 +01:00
Taranto
fcd66edf11 chore: remove config migration dev tools 2021-03-23 18:05:49 +00:00
Sérgio Salgado
dd0abc8a8b refactor: AppContext and App entrypoints 2021-03-18 11:06:35 +00:00
csrapr
fca38a5636 Feat: new profit change icons 2021-02-16 11:29:24 +00:00
Cesar
c0106592eb Feat: link from alert to some page 2021-02-05 18:59:11 +00:00
Cesar
cc14f37b6d Feat: enable transition animation for dashboard 2021-02-05 18:59:11 +00:00
Cesar
6b6d52d7b0 Fix: make percentage chart work properly
Fix: code review
2021-02-05 18:59:11 +00:00
Cesar
bd2d657e2c Feat: make footer expand on hover
chore: rename status variable from showExpandBtn to canExpand

Chore: disable notific. card, redirect to dashboard on logo click

This commit also fixes eslint warnings about anonymous exports
On the header, the Dashboard link is removed, in favour of adding
a redirect on click on the Lamassu Admin text. "Machines" header
link is removed as well, and a machine profile can be accessed
through the dashboard -> System Status card
2021-02-05 18:59:11 +00:00
Cesar
c21cdb13e1 Feat: make dashboard and machine profile page 2021-02-05 18:59:11 +00:00
Sérgio Salgado
59cb33570b fix: change coupons to promo codes 2021-02-04 13:20:49 +00:00
Cesar
ae7eaca10c Fix: make percentage chart work properly
Fix: code review

Fix: rework components according to PR requested changes

Fix: fix repeated code buildRatesNoCommission

Also renames id to deviceId in transactions quer

Fix: pr requested changes

Chore: move inline styles to classes

Chore: remove comment

Fix: bad equality !process.env.NODE_ENV === 'production'
2021-02-02 17:02:24 +00:00
Cesar
5572fb0eb1 Feat: make footer expand on hover
chore: rename status variable from showExpandBtn to canExpand

Chore: disable notific. card, redirect to dashboard on logo click

This commit also fixes eslint warnings about anonymous exports
On the header, the Dashboard link is removed, in favour of adding
a redirect on click on the Lamassu Admin text. "Machines" header
link is removed as well, and a machine profile can be accessed
through the dashboard -> System Status card
2021-02-02 17:02:24 +00:00
Cesar
19cd086436 Feat: make dashboard and machine profile page 2021-02-02 17:02:24 +00:00
Sérgio Salgado
7fe8799edc feat: add loyalty panel screen and structure
feat: add coupons table

feat: add coupons to schema

fix: coupon schema

feat: coupon table

feat: add coupon top button

feat: add first coupon button

feat: delete coupon

feat: coupon modal

fix: clear discount on modal close

fix: modal input formatting

feat: add new coupons

fix: button positioning

fix: remove loyalty panel sidebar

fix: coupon screen matching specs

fix: coupon modal

feat: send coupon data to machine on poll

fix: available coupons bool

feat: coupon endpoint

feat: transaction discount migration

feat: post-discount rates

refactor: bills

feat: version string

fix: bill saving on db

feat: coupon soft-delete

fix: coupon soft delete

fix: bill receiving

feat: remove cryptoAtoms update during tx

fix: tx trading

fix: bills

feat: start trades rework

fix: remove code

fix: code review
2021-01-18 19:42:03 +00:00
Taranto
9ed3bc50e4 Merge remote-tracking branch 'upstream/release-7.5.0' into dev 2021-01-05 10:54:56 +00:00
Liordino Neto
df8a1804a3 feat: changed old server ports so it can coexists with the new server
feat: removed deleted references from old server

feat: created reset and migrate mutations on gql server and
correspondent functions on new settings loader

feat: created front end for the config migration with reset and migrate
functionalities

style: add spacing between buttons
Signed-off-by: Liordino Neto <liordinoneto@gmail.com>
2020-12-24 20:20:05 +00:00
Taranto
0ad1ba2f77 fix: small fixes and release prep 2020-12-24 20:05:45 +00:00
Jose Sousa
15e953788e chore: updated after third level routing 2020-12-23 19:41:54 +00:00
Jose Sousa
78ba6bad8b refactor: removed action variable(only used once) 2020-12-23 19:41:54 +00:00
Jose Sousa
de4a767b21 feat: transitions animations direction 2020-12-23 19:41:54 +00:00
Jose Sousa
68050fd4ba feat: transitions animations without direction 2020-12-23 19:41:54 +00:00
Jose Sousa
7b1564c569 fix: redirect to third level 2020-12-11 19:16:07 +00:00
Jose Sousa
3e1e2b4831 chore: title and sidebar moved to app.js 2020-12-11 19:16:07 +00:00
Cesar
fd6f1a2fe0 feat: create blacklist page 2020-11-18 21:45:31 +00:00
Sérgio Salgado
4b44e1ef97 feat: token management screen 2020-11-12 22:03:26 +00:00
Liordino Neto
b4898a92dc fix: fixed the expanded component not closing when redirecting from 'Add machine'
fix: use useEffect to correctly fix the not closing expanded row

fix: pass added machine id to machine status via History props instead
of url

fix: avoid page reloading on confirmed actions
2020-10-26 16:02:38 +00:00
Taranto
a710a1b33a fix: typos and small ui improvements 2020-10-25 20:24:31 +00:00
Taranto
97ffb7bdf1 fix: wizard loading order and zeroConf 2020-10-21 11:31:17 +02:00
Liordino Neto
20370fcd1d fix: when finished pairing a machine open the machine status page with
this machine expanded

refactor: simplify add machine page
2020-10-20 21:10:26 +02:00
Mauricio Navarro Miranda
1f5b84340e feat: Admin Wizard
feat: Wallet admin wizard
feat: Notifications admin wizard
feat: Twillio admin wizard
feat: Commissions admin wizard
feat: OperatorInfor admin wizard
feat: Locales admin wizard
feat: wizard admin route
fix: better margin for admin wizard sidebar
feat: allow FormRenderer to receive a field xs size
feat: add a few flags on notifications, to reuse component parts as desired
fix: wrong gql
fix: missnig prop
fix: eslint
fix: radio styles
feat: configure bitgo wallet for single cryptocurrency on wizard
fix: eslint
feat: set up infura wallet on wizard
feat: exchange account config on wizard
fix: choose wallet choose exchange DRY
fix: layout
fix: rebase wizard to use commissions new changes
fix: typo
fix: eslint
fix: horizontal radios
feat: radio interacts with mailgun enabled/disabled state
fix: use yup to validate wizard steps
fix: eslint
feat: add xl size for button
feat: admin wizard splash
feat: use fullsize modal for wizard
fix: eslint
feat: Footer styles
feat: wizard footer styles
fix: wallet step styles
fix: zeplin spec
fix: zeplin styles
feat: blockcypher link
fix: xs can only be used on item
feat: minimize wizard footer on click away
feat: read blockcypher config
fix: all set title styles do not match
fix: no need to wrap the wrapper
feat: allow to override Setup table width for wizard
fix: wrapper class for wizard steps
fix: layout elements for mailgun step
feat: use yup to validate wizard steps
style: eslint
feat: operator info components open by default on wizard
fix: all set table is too wide
feat: full example modal
feat: check if wallet has valid config
feat: check if twilio has valid config
2020-10-15 21:32:46 +02:00
Taranto
5dd8501a17 fix: pre release screen fixes 2020-07-06 14:17:44 +01:00
Taranto
bf8f1d991c chore: integrate new admin with l-s 2020-05-27 22:43:00 +01:00
Rafael Taranto
d23067f679 Merge pull request #389 from mautematico/feat-add-cash-out-screen
feat: add cash out screen
2020-05-09 19:57:59 +01:00
Rafael Taranto
d7ff61d83f Merge pull request #373 from mautematico/feat-add-cashboxes-screen
feat: add cashboxes screen
2020-05-09 19:57:41 +01:00
Liordino Neto
c808ca3be9 feat: added the compliance/customers route
feat: added customers list page

feat: created the Customer type on the gql server and consume it

Currently only with the 'name' property

feat: added query on gql to get the customers list with the needed props

feat: added the currently available props to the front end table

fix: consider only sent txs for the aggregations on the customers list

fix: replace ExpTable with a non-expandable one

fix: remove unused properties from gql and front-end

fix: fixed the customers list columns width

fix: the last active table column was reading the wrong property

chore: remove debug logging

fix: use the correct table columns to check for txs that should be
considered on the customers list page

fix: use the international format for phone numbers

feat: added the search box

fix: remove ordering from the gql customers list query and moved it to
the front-end)

fix: removed the search box

chore: refactor the customers list table into a new component

chore: cleanup code

fix: fixed styles from customer list page header

feat: created customer profile page and started a transition feature
from the customer list

refactor: make components out of customers list table and profile page

feat: selecting a customer now transitions to its profile page

feat: added the customer transactions list table

fix: fix tx class button margins

fix: fix tx class icon margins on the customer list

fix: fixed crypto value

style: fixed the table column widths

feat: added the requirements column (no data yet, though)

feat: added the header with the customer details (no image yet, though)

feat: created the skeleton for the properties cards

feat: create the breadcrumb on the customer profile page (no link yet)

feat: added the children container in the property card

feat: added block customer action button

feat: added action buttons to the property cards

feat: added a children prop to the property card component

feat: added extra properties to the customer gql query

feat: added override fields to the customers gql query

style: added conditional styles to the property card component

feat: added children to the customer property cards

feat: create the edit button function on the property card

feat: add error properties to the txs (from gql)

style: fix action left editing action button and right property card
margins

feat: created a mutation to update a customer

feat: added the customer auth override state to the gql query

feat: fix the routing to the individual customer profile pages

feat: made the 'Customers' label on the breadcrumb work as a link

style: fixed the breadcrumb separator

style: fixed the customer name style

feat: made the action to block and authorize a customer as a toggle

feat: removed the 'Super user' switch (left for v2)

style: added the crossed camera icon on the photo

style: fixed the rejected icons

refactor: refactored some styles that were repetitive

refactor: created constants for the override possible states

feat: created functions for the authorization and blocking of overrides

refactor: renamed setOverride to updateCustomer

fix: remove current unused features

feat: make the property cards fields read-only

feat: setup id card photo and front camera photo image servers

feat: add id card photo on the corresponding property card

feat: add front camera photo on the customer profile header

feat: added gql cache to update the front-end after any mutation

style: added the crossed camera icon when there's no id card photo

refactor: extracted the PropertyCard component to another file

fix: deactivated the cache for the transactions (no need for it)

refactor: removed unused styles

fix: fixed front-camera-photo img path

fix: changed gql local data updates from cache to query refetch

refactor: move override status constants to the property card class

refactor: make the image servers URI a const dependent on the build

fix: remove requirements column from customer tx table (left for future
version)

fix: add aliases to gql query to correctly show errors on tx table

style: fix the transaction errors styles

feat: add terms and conditions page

feat: add modal preview

feat: remove preview

fix: increase space between switch and fields

feat: added the compliance/customers route

feat: added customers list page

feat: created the Customer type on the gql server and consume it

Currently only with the 'name' property

feat: added query on gql to get the customers list with the needed props

feat: added the currently available props to the front end table

fix: consider only sent txs for the aggregations on the customers list

fix: replace ExpTable with a non-expandable one

fix: remove unused properties from gql and front-end

fix: fixed the customers list columns width

fix: the last active table column was reading the wrong property

chore: remove debug logging

fix: use the correct table columns to check for txs that should be
considered on the customers list page

fix: use the international format for phone numbers

feat: added the search box

fix: remove ordering from the gql customers list query and moved it to
the front-end)

fix: removed the search box

chore: refactor the customers list table into a new component

chore: cleanup code

fix: fixed styles from customer list page header

fix: removed unused code

refactor: move transactions to a custom resolver in the customer's query

refactor: break the CustomerProfile component into several smaller ones

style: changed the table row error color from red to no change and the
error text from tomato to comet

fix: removed repeated function (wrong merge)

fix: make the updateCustomer function updates only what's explicitly
told so

style: return with the table row error style

refactor: create a function to test if a value is null prior to passing
it through another function

fix: make t&c changes backwards compatible

chore: bump eslint import library to activate rule

fix: stop showing object on empty column

fix: get machine logs page up-to-date

fix: small admin fixes

feat: add terms and conditions page

feat: add modal preview

feat: remove preview

fix: increase space between switch and fields

feat: added the compliance/customers route

feat: added customers list page

feat: created the Customer type on the gql server and consume it

Currently only with the 'name' property

feat: added query on gql to get the customers list with the needed props

feat: added the currently available props to the front end table

fix: consider only sent txs for the aggregations on the customers list

fix: replace ExpTable with a non-expandable one

fix: remove unused properties from gql and front-end

fix: fixed the customers list columns width

fix: the last active table column was reading the wrong property

chore: remove debug logging

fix: use the correct table columns to check for txs that should be
considered on the customers list page

fix: use the international format for phone numbers

feat: added the search box

fix: remove ordering from the gql customers list query and moved it to
the front-end)

fix: removed the search box

chore: refactor the customers list table into a new component

chore: cleanup code

fix: fixed styles from customer list page header

fix: make t&c changes backwards compatible

fix: stop showing object on empty column

fix: get machine logs page up-to-date

feat: add terms and conditions page

feat: add modal preview

feat: remove preview

fix: increase space between switch and fields

feat: added the compliance/customers route

feat: added customers list page

feat: created the Customer type on the gql server and consume it

Currently only with the 'name' property

feat: added query on gql to get the customers list with the needed props

feat: added the currently available props to the front end table

fix: consider only sent txs for the aggregations on the customers list

fix: replace ExpTable with a non-expandable one

fix: remove unused properties from gql and front-end

fix: fixed the customers list columns width

fix: the last active table column was reading the wrong property

chore: remove debug logging

fix: use the correct table columns to check for txs that should be
considered on the customers list page

fix: use the international format for phone numbers

feat: added the search box

fix: remove ordering from the gql customers list query and moved it to
the front-end)

fix: removed the search box

chore: refactor the customers list table into a new component

chore: cleanup code

fix: fixed styles from customer list page header

fix: make t&c changes backwards compatible

fix: stop showing object on empty column

fix: get machine logs page up-to-date

fix: small admin fixes

feat: create add machine page

feat: add terms and conditions page

feat: add modal preview

feat: remove preview

fix: increase space between switch and fields

feat: added the compliance/customers route

feat: added customers list page

feat: created the Customer type on the gql server and consume it

Currently only with the 'name' property

feat: added query on gql to get the customers list with the needed props

feat: added the currently available props to the front end table

fix: consider only sent txs for the aggregations on the customers list

fix: replace ExpTable with a non-expandable one

fix: remove unused properties from gql and front-end

fix: fixed the customers list columns width

fix: the last active table column was reading the wrong property

chore: remove debug logging

fix: use the correct table columns to check for txs that should be
considered on the customers list page

fix: use the international format for phone numbers

feat: added the search box

fix: remove ordering from the gql customers list query and moved it to
the front-end)

fix: removed the search box

chore: refactor the customers list table into a new component

chore: cleanup code

fix: fixed styles from customer list page header

fix: make t&c changes backwards compatible

fix: stop showing object on empty column

fix: get machine logs page up-to-date

feat: create add machine page

fix: fixed wrong merging

fix: more fixes from last merge

fix: export needed functions that wasn't exported from the customers
module

fix: removed the customer profile route from the header

fix: replaced old dataTable with new component

feat: added onClick event to new DataTable
2020-05-09 18:19:20 +01:00
Mauricio Navarro Miranda
1cf4168294 feat: use Namespaced table and wizard on Cashout 2020-05-05 23:14:32 -05:00
Mauricio Navarro Miranda
af95a366c6 feat: add cash-out screen
feat: add cash-out route

feat: add cash-out table component

feat: add cash-out page

feat: add wizard splash for enable cashout

feat: wizard component for enable cash-out

feat: use wizard to enable cash-out

fix: denominations are numbers

feat: update cashout denominations config on gql

feat: refetch cashout infos after config save

fix: use default table for cashout table

fix: move cashout table closer to parent
2020-05-05 03:44:04 -05:00
Mauricio Navarro Miranda
8f4ee4da0a feat: add cashboxes screen
feat: add cashboxes route
feat: add non-editable cashbox component
feat: cashboxes action required icon
feat: add cashOut denomination to cashboxes
feat: edit cashboxes values
feat: new server empty cashIn and reset cashOut actions
feat: reset cashboxes from UI
fix: cashbox border, cashbox font
fix: move cashbox styles to its own file
fix: use default table for cashboxes-table
fix: better import
fix: TODO: find a better way to display cashbox reset errors
fix: TODO for cashout
fix: move cashboxestable closer to parent
fix: WIP use EditableTable instead of fakatable
wip: move to editabletable
fix: WIP split cashbox into view + input components that can be used with formik
feat: rewrite cashbox component into view + fromik
feat: WIP use editableTable instead of hand made table
feat: WIP cashboxes editable table
feat: split cashbox
feat: Yup validation schema for cashboxes editable table
feat: split cashbox into view+formik
feat: WIP use editableTable instead of faketable
feat: use editableTable instead of fakeTable
fix: custom CashboxesTable not needed anymore
2020-05-05 02:30:28 -05:00
Liordino dos Santos Rocha Neto
7885d56211 fix: rebase fixes 2020-05-04 12:55:48 +02:00
Liordino Neto
79c26b1c50 feat: created the base skeleton for the compliance triggers page 2020-05-04 12:55:48 +02:00
Taranto
21f3ee59ea fix: PR fixes 2020-04-23 18:38:29 +02:00
Taranto
1f6d272aa0 fix: rework wallet screen 2020-04-23 18:38:29 +02:00
Luis Félix
1f7ae74b42 feat: add wallet settings page 2020-04-23 18:38:29 +02:00
Taranto
ffa8713ee4 feat: notifications rework 2020-04-23 18:38:29 +02:00
Luis Félix
b6e7d98b72 feat: notifications page 2020-04-23 18:38:29 +02:00
Taranto
b1b8b82260 fix: small admin fixes 2020-03-20 17:28:23 +01:00
Taranto
82a1aa6b99 chore: bump eslint import library to activate rule 2020-03-20 17:28:23 +01:00
Liordino Neto
507027cdee feat: added the compliance/customers route
feat: added customers list page

feat: created the Customer type on the gql server and consume it

Currently only with the 'name' property

feat: added query on gql to get the customers list with the needed props

feat: added the currently available props to the front end table

fix: consider only sent txs for the aggregations on the customers list

fix: replace ExpTable with a non-expandable one

fix: remove unused properties from gql and front-end

fix: fixed the customers list columns width

fix: the last active table column was reading the wrong property

chore: remove debug logging

fix: use the correct table columns to check for txs that should be
considered on the customers list page

fix: use the international format for phone numbers

feat: added the search box

fix: remove ordering from the gql customers list query and moved it to
the front-end)

fix: removed the search box

chore: refactor the customers list table into a new component

chore: cleanup code

fix: fixed styles from customer list page header
2020-02-17 22:47:39 +01:00
Mauricio Navarro Miranda
fdf18b60ad feat: add machine status page (#344)
* feat: add confirm-dialog component

* feat: add MachineStatus to router

* feat: add machine details to api endpoints

* feat: add machine-status expandabletable

* fix: add missing property to TextInput on story

* style: minor style fixes

* feat: useAxios to unpair and reboot specific machinees

* fix: style fixes
use shutdown instead of reboot
use named colors

* fix: use new ExpTable

* fix: class instead of sttyles, use named colors

* feat: use ConfirmDialog to confirm unpair action

* chore: eslint fix

* refactor: use gql, new ExpTable and ramda on machine-status

* fix: 'fallback' status instead of the 'all good' one

* fix: makeStyles instead of withStyles

* refactor: simplify StatusChip

* fix: css spacing instead of nbsp

* fix: move makeStyles outside component

* refactor: makeStyles instead of withStyles

* refactor: adapting based props for Status

* refactor: moar simple Status chip

* feat: use graphql mutation instead of rest for machine action
feat: use graphql instead of rest on MachineDetailsCard

* fix: Dialog close must be handled outside

* fix: just pass down onDissmissed and onConfirmed to the component
https://github.com/lamassu/lamassu-server/pull/344#discussion_r370136028

* refactor: machineAction on separate file and 404 handling

* feat: basic handling of graphql exceptions on machineAction
2020-02-04 21:12:44 +01:00