logo

Crowdly

Add the specified function that executes the registration. It m...

✅ Перевірена відповідь на це питання доступна нижче. Наші рішення, перевірені спільнотою, допомагають краще зрозуміти матеріал.

Add the specified function that

executes the

registration.

It must  

  • add a registrationDate

    to the good

    thing registration object

  • register the good thing object in

    the database,

  • compute and return the response

    object, that in addition to the registered object, includes a field storing the

    goodthingsCount of good things now registered at the registration date.

Hint:

There is a helper function to check whether

two dates are the same date.  You need to filter the database for matching username and date pairs.

Hint:

A new date can be created

using the constructor function

Date (see[DF 11.4] )

Remark: For this exercise, use the Date object as per your text book, but remark that Javascript has since been updated with a new ”Temporal” object that should replace Date in future real applications.

Більше питань подібних до цього

Хочете миттєвий доступ до всіх перевірених відповідей на www.moodle.aau.dk?

Отримайте необмежений доступ до відповідей на екзаменаційні питання - встановіть розширення Crowdly зараз!