CS计算机代考程序代写 COMP S381F Mini-project

COMP S381F Mini-project

Introduction

You are going to develop and implement a cloud-based application for an inventory management

system. You will work in groups (groups of 1, 2 or 3) to complete this project.

Submission Deadline

December 13, 2021 (Monday)

Project Deliverables

1. An express server that provides basic CRUD services for the inventory collection. The server must be

running in the cloud (IBM Cloud, AWS, Heroku or Microsoft Azure).

2. Submit source code to the tutor Mr. YUEN by email ( .edu.hk).

2. Complete the google form https://forms.gle/ezs74s2PvJbbfSf57 . Submit the source code when

filling the google form.

Note:

One submission per group.

mailto: .edu.hk
https://forms.gle/ezs74s2PvJbbfSf57

Functional Requirements

1. Login/logout

 Each user account has a userid and password.

 Upon successful login, userid should be stored in a session

2. Create new inventory documents

 Inventory documents may contain the following attributes:

I. inventory_ID

II. name

III. type

IV. quantity

V. photo

VI. photo mimetype

VII. inventory_address

a. street

b. building

c. country

d. zipcode

e. coord

VIII. manager

 name and manager are mandatory; other attributes are optional

3. Update inventory documents

 An inventory document can only be updated by its manager (the one who created the document)

4. Display inventory documents

 Show photo if it is available

 Show a link to Leaflet if coord is available

5. Delete inventory documents

 The document can only be deleted by its manager

6. Search for the inventory

 by name

7. Provide the following RESTful services.

Request Parameters Response

GET /api/inventory/ /name/xxx

/type/yyy

[

{ inventory doc1},

{ inventory doc2},

]

OR

{}

Remarks Read inventory documents with criteria:

xxx – name of inventory

yyy – type of inventory

Non-Functional Requirements

 Use EJS to render all UI

 Use MongoDB driver

 Display project member information after the login page (name and student id)

Assessment Criteria

1. Your server is required to pass different test cases. Here is a sample test case.

Precondition:

o An empty inventory collection

Steps:

o Login as demo (no password is required)

o Create an inventory document with name = Pen, manager = demo

o Submit GET /api/inventory/name/Pen

Expected outcome:

o The Pen document in JSON format.

2. Marks are deducted (up to 50%) in case of incomplete source code.