Si tratta di un test di logica per l'impostazione di un sistema di loyalty utente.
Il sistema è composto da 3 componenti:
- un server Node.js
- un database MongoDB
- un client web
Non ci interessa che venga sviluppato il client o completato il server, ma solo la logica di loyalty. Il file da cui partire è Loyalty.js, dove è già presente la class Loyalty che dovrà essere implementata.
Nel file User.js è presente la class User che rappresenta un utente del sistema e richiama la class Loyalty in fase di registrazione.
Le indicazioni speicifiche sono presenti nel file Loyalty.js.
Piena libertà di creazione di nuovi file e di scrittura di nuove tabelle o dati nel database. Possibilmente non utilizzare librerie esterne.
This is a logic test for setting up a user loyalty system.
The system consists of 3 components:
- a Node.js server
- a MongoDB database
- a web client
We are not interested in developing the client or completing the server, but only the logic of loyalty. The file to start from is Loyalty.js, where the Loyalty class that will have to be implemented is already present.
The User.js file contains the User class that represents a user of the system and calls the Loyalty class when registering.
The specific indications are present in the Loyalty.js file.
Full freedom to create new files and write new tables or data in the database. Possibly do not use external libraries.