This is a full-stack web application designed to manage materials, rooms, reservations, and files within an organization or facility. It provides a user-friendly interface for tracking assets, booking resources, and managing associated documentation.
- User authentication (login, logout, registration)
- Role-based access control (though roles are not explicitly implemented, the foundation for authenticated access is there)
- View, add, update, and delete material instances.
- Filter and search materials by type, availability, and location.
- Track material history (creation, updates, moves, reservations).
- Prevent deletion or movement of reserved materials.
- View, add, update, and delete rooms.
- Track materials located in each room.
- Prevent deletion of rooms containing materials.
- View room history (creation, updates, material movements).
- Create, view, cancel, and end reservations for materials.
- Reserve specific material instances or quantities of a material type from a specific room.
- Automatic ending of expired reservations.
- Add/remove materials from existing active reservations.
- Upload, view, and download files.
- Delete files and their metadata.
- Search files by title or ID.
For a detailed user guide, refer to the User Guide.
Frontend:
- Angular (TypeScript)
- Bootstrap (for styling)
Backend:
- Node.js with Express.js
- JSON Web Tokens (JWT) for authentication
- bcrypt for password hashing
- Multer for handling file uploads
fsmodule for file system operations- Custom file-locking mechanism for data consistency
To get this project up and running on your local machine, follow these steps:
git clone <repository_url>
cd <repository_name>Navigate to the backend directory:
cd backendInstall the Node.js dependencies:
npm installImportant: The application uses JSON files for data storage. Initial user data is in backend/data/users.json. Passwords are hashed using bcrypt. If you need to add new users directly to users.json, ensure their passwords are hashed. You can use a tool or a small script to generate hashed passwords.
Start the backend server:
node server.jsThe backend server will typically run on http://localhost:3000.
Open a new terminal and navigate to the frontend directory:
cd frontendInstall the Angular dependencies:
npm installStart the Angular development server:
ng serveif you don't have Angular, install it with and then retry the recent command:
npm install -g @angular/cliThe frontend application will typically be accessible at http://localhost:4200.
- Access the Application: Open your web browser and go to
http://localhost:4200. - Login: Use the login page to authenticate.
- Navigate: Use the header navigation to access different sections like Home, Reservations, Files, Material Management, and Room Management.
- Manage Data: Interact with the forms and tables to add, view, update, and delete materials, rooms, reservations, and files.
Enjoy using the application!