Ams Project
Ams Project
By
"XXXXXXXXXX"
ENROLMENT: "xxxxxxxxx"
Submitted to the School of Computer and Information Sciences,
IGNOU in partial fulfilment of the requirements
For the award of the degree
MCSP-232
"YEAR-2024"
1|Page
GUIDED BY: SUBMITTED BY:
XXXXXX "XXXXXXXXXX"
Enrollment No. :"xxxxxxxxxx "
2|Page
CANDIDATE'S DECLARATION
We, hereby declare that the work presented in the project report " Asset
Management System ", is an authentic record of our work, carried out,
under the guidance of. Mr. "XXXXXX", "xxxxxx" and is not
reproduced as it is from any kind of source.
NAME : XXXXXXXXXX
Enrollment no. xxxxxxxxxx
3|Page
CERTIFICATE
Date:
4|Page
CERTIFICATE OF ORIGINALITY
This is to certify that the project report entitled " Asset Management
System " submitted to Indira Gandhi National Open University in partial
fulfillment of the requirement for the award of the degree of
"MCA_NEW", is an authentic and original work carried out by
"XXXXXXXXXX" with enrolment no. "xxxxxxxxxx" under my
guidance.
The matter embodied in this project is genuine work done by the student
and has not been submitted whether to this University or to any other
University/Institute for the fulfillment of the requirements of any course
of study.
5|Page
ACKNOWLEDGEMENT
NAME :- XXXXXXXXXX
Enrolment No. xxxxxxxxxx"
PROJECT TITLE:
6|Page
TABLE OF CONTENTS
S.NO. SUBJECT PAGE NO.
1 Introduction 8-10
Specifications
4 Data Flow Diagrams(DFD’S) 23-31
5 Modules Description 31-110
6 Data Structure (Table) 111-123
Diagrams
9 Testing Process 144-154
10 Conclusion and Recommendations 155-162
11 Bibliography 162-165
Introduction
7|Page
In today’s fast-paced and increasingly digital world, managing assets
efficiently has become a critical factor for businesses and organizations.
Whether it’s physical assets like machinery and equipment, or intangible
assets such as software licenses and intellectual property, organizations
require effective systems to track, manage, and optimize the usage of
these resources. An Asset Management System (AMS) is a powerful
tool designed to address these needs, offering a centralized platform for
the monitoring, controlling, and administration of an organization’s
assets throughout their lifecycle.
8|Page
involves conducting a thorough assessment of the asset management
processes, understanding the types of assets in use, and defining the core
functionalities required for the system. Key features typically include
asset tracking, lifecycle management, maintenance scheduling,
depreciation calculations, and reporting and analytics. A user-friendly
interface is essential, enabling employees at various levels to interact
with the system easily, whether they are field technicians, asset
managers, or executives.
9|Page
Security and data integrity are paramount considerations when
developing an Asset Management System. With the increasing threats of
cyber-attacks, the software must incorporate robust security measures,
such as encryption, user authentication, and access control, to safeguard
sensitive asset data.
Project Aim
The aim of this project is to develop an intuitive, efficient, and scalable
Asset Management System (AMS) that enables organizations to track,
manage, and optimize their assets throughout their entire lifecycle. The
software solution will automate the process of asset acquisition,
tracking, maintenance, and disposal, thus ensuring that assets are utilized
optimally, reducing operational inefficiencies, lowering costs, and
enhancing overall organizational performance. The system will leverage
10 | P a g e
modern technologies to provide real-time data on asset location, status,
usage, and value, making it easier for organizations to manage both
physical and intangible assets effectively.
Project Objectives
1. Develop a Centralized Asset Repository:
The system will provide a centralized database where all asset-
related information—such as purchase details, maintenance
history, warranty status, and current condition—can be stored and
accessed in real-time. This will reduce the risk of misplaced or
overlooked assets and ensure complete visibility.
2. Enable Real-Time Asset Tracking:
Implement features that allow for real-time tracking of assets using
technologies like barcode scanning, RFID, or GPS. This feature
will help track the physical location, utilization, and movement of
assets across different locations and departments.
3. Automate Asset Lifecycle Management:
The AMS will manage the complete lifecycle of assets, from
procurement and installation to maintenance and disposal. The
software will automate tasks like scheduling maintenance,
monitoring depreciation, and generating alerts for warranty
expirations or end-of-life notifications.
11 | P a g e
4. Improve Maintenance Scheduling & Tracking:
The system will allow for the efficient scheduling of routine
maintenance tasks and ensure that assets are maintained according
to manufacturer guidelines. It will also track maintenance history
to ensure compliance with industry standards and reduce the
likelihood of unexpected downtime.
5. Enhance Reporting and Analytics:
The AMS will include customizable reporting features that allow
users to generate reports on asset utilization, maintenance costs,
depreciation, and financial reporting. This will help decision-
makers analyze asset performance and make informed financial
and operational decisions.
Project Scope
The scope of the Asset Management System development includes the
following:
1. Functional Scope:
o Asset Tracking: Integration of barcode scanning, RFID, and
manual entry options for asset registration and tracking.
o Asset Information Management: Detailed records for each
asset, including purchase date, location, maintenance
history, warranty details, and depreciation.
12 | P a g e
o Lifecycle Management: Automation of asset lifecycle stages,
including procurement, deployment, maintenance, and
disposal.
o Maintenance Management: Scheduling of routine
maintenance tasks, tracking repairs, and generating alerts
for upcoming maintenance or end-of-life milestones.
o Reporting and Dashboards: Tools for generating real-time
reports on asset performance, depreciation, utilization, and
cost analysis.
o Integration with Other Systems: Ability to integrate with
existing ERP, finance, and HR systems for seamless data
sharing.
o User Access Control: Role-based access control to ensure
that only authorized users can access sensitive asset data
and functionality.
2. Technical Scope:
o Platform Compatibility: The system will be designed as a
web-based application to ensure accessibility from any
device with an internet connection. The application will be
optimized for both desktop and mobile usage.
13 | P a g e
o Cloud-Based Infrastructure: The system will be deployed on
a secure cloud platform to ensure scalability, data backup,
and accessibility from multiple locations.
o Security Measures: Implementation of data encryption,
secure login mechanisms, and multi-factor authentication to
protect sensitive asset data.
3. Non-Functional Scope:
o Performance: The AMS will be designed to handle a large
volume of assets, ensuring fast response times even as the
database grows.
o Scalability: The system will be scalable to accommodate the
future growth of the organization’s assets and expanding
business needs.
o Usability: The system will feature an intuitive and user-
friendly interface, reducing the learning curve for employees
and ensuring high adoption rates.
4. Out of Scope:
o The system will not include the management of non-physical
assets, such as intellectual property or digital assets beyond
software licenses.
14 | P a g e
o The project does not cover the integration with highly
specialized or third-party asset management systems
beyond the general ERP or financial systems.
o The development of custom hardware solutions (e.g., RFID
tags or barcode scanners) will not be included in the project
scope, though the system will support the integration of
such hardware.
15 | P a g e
is a detailed outline of the hardware and software requirements for the
AMS.
1. Hardware Requirements
CPU:
o Multi-core processor (e.g., Intel Xeon or AMD EPYC) with a
minimum of 4 cores for basic usage; 8+ cores for larger
installations with a high number of users.
o Clock speed of at least 2.0 GHz or higher.
RAM:
o Minimum 16 GB of RAM for small to medium-scale
deployment.
o 32 GB or more of RAM for larger installations with more
concurrent users or a larger volume of assets.
Storage:
o Solid-State Drives (SSD) for faster data retrieval and storage.
o Minimum 500 GB of storage for smaller deployments.
16 | P a g e
o 1 TB or more of storage for larger databases that include
extensive asset data (including images, maintenance logs,
etc.).
o Redundant Array of Independent Disks (RAID) configuration
for data redundancy and fault tolerance.
Network Connectivity:
o High-speed Ethernet (1 Gbps minimum).
o For cloud-based deployment, fast internet connectivity with
low latency is essential.
Backup:
o Regular backup systems, such as automated cloud-based
backups or external storage, with backup redundancy to
prevent data loss.
CPU:
o 2 GHz or higher processor (dual-core or higher
recommended for desktop/laptop users).
RAM:
o Minimum 4 GB of RAM for optimal user experience.
o 8 GB of RAM recommended for smoother performance with
multiple applications running simultaneously.
17 | P a g e
Storage:
o 1 GB of free hard drive space for the AMS application (for
local installations if applicable).
Display:
o Minimum screen resolution of 1280x800 pixels.
o Larger screen sizes (1920x1080 pixels) are recommended for
ease of use and better display of complex asset data.
Peripherals:
o Barcode scanner or RFID reader for asset tracking (optional,
but recommended for real-time tracking of physical assets).
o Printer for printing asset tags, reports, or maintenance
schedules (optional).
o Mobile devices (smartphones or tablets) with barcode
scanning or RFID capabilities if the system is accessed on the
go.
2. Software Requirements
Operating System:
o Linux (preferred): Ubuntu Server 20.04 or later, CentOS, or
Red Hat Enterprise Linux (RHEL) for stability and security.
18 | P a g e
o Windows Server: Windows Server 2016 or newer, if
preferred for enterprise environments using Microsoft-based
technologies.
Web Server:
o Apache HTTP Server or Nginx (for serving the web
application securely and efficiently).
Database Management System (DBMS):
o MySQL or PostgreSQL (open-source, relational database
management systems with high scalability and performance).
o Alternatively, Microsoft SQL Server for environments
already using Microsoft technologies.
Application Server (if applicable):
o Tomcat (for Java-based applications).
o Node.js or ASP.NET for building API endpoints and web
applications if using JavaScript-based stacks.
Backup Software:
o Backup software like Veeam, Acronis Backup, or cloud-
based backup systems (AWS Backup, Google Cloud Backup)
for regular data backups.
Security & Authentication:
o SSL/TLS certificates for secure HTTP communication
(HTTPS).
19 | P a g e
o Firewall software and antivirus for ensuring the security of
server data.
Virtualization/Containerization (for scalable deployments):
o Docker or Kubernetes for containerizing the application and
ensuring easy scaling and deployment.
o VMware or Hyper-V if running on virtualized server
environments.
Development Environment (for system customization):
o IDE: Visual Studio Code, IntelliJ IDEA, or Eclipse for
coding and debugging.
o Version Control: Git, hosted on platforms such as GitHub,
GitLab, or Bitbucket.
20 | P a g e
Application (for desktop-based AMS):
o Windows: Windows 10 or newer.
o macOS: macOS 10.14 (Mojave) or newer.
o Linux: Ubuntu or Fedora with GUI support for Linux-based
environments.
Additional Software (optional):
o QR/Barcode Scanning Software: For use with asset
tracking applications that rely on barcode or QR code
scanning.
o PDF Reader/Editor: For accessing and editing reports and
documents generated by the AMS (e.g., Adobe Acrobat
Reader).
Internet Connectivity:
o Reliable, high-speed internet connection for cloud-based
deployment.
o Minimum 1 Mbps upload/download speed for users
accessing the system remotely.
o VPN (Virtual Private Network) may be required for secure
access to internal systems if the AMS is deployed in a private
network.
21 | P a g e
Firewall & Network Security:
o Configuration of firewalls to allow necessary traffic on
specific ports (e.g., HTTP/HTTPS, database access).
o Secure network architecture to prevent unauthorized access
to sensitive asset information.
The hardware and software requirements outlined above are essential for
the development, deployment, and smooth operation of an Asset
Management System. These requirements ensure that the system can
22 | P a g e
handle large volumes of data, scale with the organization’s growth, and
provide fast, reliable access to asset information. By adhering to these
specifications, the system will deliver high performance, security, and
usability across the enterprise, empowering organizations to efficiently
manage their assets throughout their lifecycle.
Levels of DFD:
Entities:
Data Flows:
24 | P a g e
Financial Data (from External System to AMS): Integration of
financial information related to asset acquisition, depreciation, and
disposal.
Asset Data Reports (from AMS to Admin/User): Generated
reports on asset status, maintenance, depreciation, and
performance.
DFD Diagram:
The Level 1 DFD breaks down the AMS into major functional modules:
25 | P a g e
External Entities:
Data Stores:
Processes:
26 | P a g e
DFD Diagram:
In the Level 2 DFD, we can break down each major module into more
specific processes. For example, the Asset Registration & Tracking
process can include specific functions such as "Register New Asset,"
"Update Asset Information," "Track Asset Location," and "Generate
Asset Report."
Register New Asset: Add new assets into the system, including
their metadata (e.g., name, purchase date, cost).
Update Asset Information: Modify details of existing assets (e.g.,
location, status).
27 | P a g e
Track Asset Location: Monitor and update the physical location
of assets using technologies such as barcode scanning or RFID.
Generate Asset Report: Provide users with reports on asset status,
location, and usage.
28 | P a g e
Depreciation Synchronization: Automatically updates asset
depreciation data based on the financial system.
Budgeting and Forecasting: Updates and forecasts asset-related
costs for budgeting purposes.
29 | P a g e
DFD Diagram:
The Data Flow Diagrams (DFDs) above illustrate the flow of data in an
Asset Management System (AMS). They start with a high-level
30 | P a g e
overview (Level 0), break down the core processes (Level 1), and
provide detailed functional workflows for key modules (Level 2). These
diagrams help stakeholders understand how the system will work, how
data will be processed, and how it will interact with users and other
systems, ensuring a structured and well-organized development
approach for the AMS.
Modules Description
The Asset Management System (AMS) is designed to help organizations
efficiently manage their assets, including tracking, maintaining, and
analyzing both physical and intangible assets throughout their lifecycle.
The system is broken down into several core modules, each addressing
different functionalities critical to asset management. Below is a detailed
description of each module:
Purpose:
31 | P a g e
provides the core functionality for managing asset details, monitoring
their status, and tracking asset movements.
Key Features:
AssetRegistration:
Users can register new assets by entering key information such as
asset type, purchase date, serial number, warranty details, cost, and
supplier/vendor information.
AssetCategorization:
Assets are categorized based on type (e.g., IT equipment,
machinery, furniture) and location (e.g., warehouse, office).
Categories are customizable based on the organization's needs.
Barcode&RFIDScanning:
Support for asset tracking via barcode or RFID technology. This
enables real-time tracking of asset movements and locations across
various departments or facilities.
AssetStatusUpdates:
Track the current status of each asset, such as "in use," "under
maintenance," or "retired."
AssetHistory&AuditTrails:
Maintain a historical record of each asset’s lifecycle, including any
transfers, maintenance, and repairs. This provides a comprehensive
audit trail of asset activities.
32 | P a g e
Interactions with Other Modules:
html
Copy code
<div class="asset-registration-container">
<mat-card class="asset-form">
<mat-card-title>Asset Registration</mat-
card-title>
<form (ngSubmit)="registerAsset()"
#assetForm="ngForm">
<mat-form-field appearance="fill">
<mat-label>Asset Type</mat-label>
33 | P a g e
<input matInput
[(ngModel)]="asset.assetType" name="assetType"
required>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Purchase Date</mat-label>
<input matInput [matDatepicker]="picker"
[(ngModel)]="asset.purchaseDate"
name="purchaseDate" required>
<mat-datepicker-toggle matSuffix
[for]="picker"></mat-datepicker-toggle>
<mat-datepicker #picker></mat-
datepicker>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Serial Number</mat-label>
<input matInput
[(ngModel)]="asset.serialNumber"
name="serialNumber" required>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Warranty Details</mat-label>
<input matInput
[(ngModel)]="asset.warranty" name="warranty">
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Cost</mat-label>
<input matInput type="number"
[(ngModel)]="asset.cost" name="cost" required>
</mat-form-field>
34 | P a g e
<mat-form-field appearance="fill">
<mat-label>Supplier</mat-label>
<input matInput
[(ngModel)]="asset.supplier" name="supplier"
required>
</mat-form-field>
css
Copy code
.asset-registration-container {
display: flex;
justify-content: center;
padding: 20px;
}
.asset-form {
width: 80%;
max-width: 600px;
}
mat-form-field {
width: 100%;
margin-bottom: 16px;
}
typescript
35 | P a g e
Copy code
import { Component } from '@angular/core';
import { AssetService } from
'../services/asset.service'; // Importing asset
service to interact with the backend
import { MatSnackBar } from
'@angular/material/snack-bar';
@Component({
selector: 'app-asset-registration',
templateUrl: './asset-
registration.component.html',
styleUrls: ['./asset-
registration.component.css']
})
export class AssetRegistrationComponent {
asset = {
assetType: '',
purchaseDate: '',
serialNumber: '',
warranty: '',
cost: null,
supplier: ''
};
constructor(private assetService:
AssetService, private snackBar: MatSnackBar) {}
registerAsset() {
this.assetService.registerAsset(this.asset).subs
cribe(
(response) => {
this.snackBar.open('Asset registered
successfully!', 'Close', {
36 | P a g e
duration: 2000
});
// Reset form after successful
submission
this.asset = { assetType: '',
purchaseDate: '', serialNumber: '', warranty:
'', cost: null, supplier: '' };
},
(error) => {
this.snackBar.open('Error registering
asset', 'Close', {
duration: 2000
});
}
);
}
}
typescript
Copy code
import { Injectable } from '@angular/core';
import { HttpClient } from
'@angular/common/http';
import { Observable } from 'rxjs';
@Injectable({
providedIn: 'root'
})
export class AssetService {
private apiUrl =
'http://localhost:3000/assets'; // Backend API
URL
37 | P a g e
constructor(private http: HttpClient) {}
javascript
Copy code
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const app = express();
const port = 3000;
// Middlewares
app.use(cors());
app.use(bodyParser.json());
// Routes
const assetRoutes =
require('./routes/assetRoutes');
app.use('/assets', assetRoutes);
app.listen(port, () => {
console.log(`Server running at
http://localhost:${port}`);
});
38 | P a g e
2. Sequelize Model (models/Asset.js)
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const Asset = sequelize.define('Asset', {
assetType: {
type: DataTypes.STRING,
allowNull: false
},
purchaseDate: {
type: DataTypes.DATE,
allowNull: false
},
serialNumber: {
type: DataTypes.STRING,
unique: true,
allowNull: false
},
warranty: {
type: DataTypes.STRING,
allowNull: true
},
cost: {
type: DataTypes.FLOAT,
allowNull: false
},
supplier: {
type: DataTypes.STRING,
allowNull: false
}
});
39 | P a g e
return Asset;
};
javascript
Copy code
const { Sequelize } = require('sequelize');
module.exports = sequelize;
javascript
Copy code
const { Asset } = require('../models');
javascript
Copy code
const express = require('express');
const router = express.Router();
const assetController =
require('../controllers/assetController');
module.exports = router;
javascript
Copy code
const sequelize = require('./config/database');
const Asset = require('./models/Asset');
This is just the foundation for the Asset Registration & Tracking
module. It can be expanded to include additional features such as
barcode/RFID scanning, asset status updates, and historical tracking.
Purpose:
42 | P a g e
Key Features:
Maintenance Scheduling:
Automatically schedule routine maintenance tasks for assets based
on usage hours, manufacturer recommendations, or a predefined
schedule.
Work Orders & Requests:
Allows users to create and manage work orders for repairs,
inspections, or maintenance tasks. Work orders can be assigned to
technicians or external contractors.
Maintenance History Tracking:
Records all maintenance activities, including repairs, upgrades, and
part replacements, to provide a complete maintenance history for
each asset.
Alert System:
Sends reminders and alerts for upcoming maintenance tasks,
warranty expiration, or critical repairs.
Parts and Inventory Management:
Tracks spare parts and consumables required for maintenance
activities and integrates with the Inventory Management module
to ensure the availability of parts.
43 | P a g e
Interacts with the Asset Registration & Tracking Module to
update asset statuses based on maintenance activity.
Communicates with the Reporting & Analytics Module to
generate maintenance cost and downtime reports.
html
Copy code
<div class="maintenance-management-container">
<mat-card class="maintenance-card">
<mat-card-title>Maintenance Management</mat-
card-title>
<form (ngSubmit)="createWorkOrder()"
#maintenanceForm="ngForm">
<mat-form-field appearance="fill">
<mat-label>Asset</mat-label>
44 | P a g e
<mat-select
[(ngModel)]="workOrder.assetId" name="assetId"
required>
<mat-option *ngFor="let asset of
assets" [value]="asset.id">{{ asset.assetType }}
- {{ asset.serialNumber }}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Maintenance Type</mat-label>
<input matInput
[(ngModel)]="workOrder.maintenanceType"
name="maintenanceType" required>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Scheduled Date</mat-label>
<input matInput [matDatepicker]="picker"
[(ngModel)]="workOrder.scheduledDate"
name="scheduledDate" required>
<mat-datepicker-toggle matSuffix
[for]="picker"></mat-datepicker-toggle>
<mat-datepicker #picker></mat-
datepicker>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Description</mat-label>
<textarea matInput
[(ngModel)]="workOrder.description"
name="description" required></textarea>
</mat-form-field>
45 | P a g e
<button mat-raised-button color="primary"
type="submit">Create Work Order</button>
</form>
</mat-card>
<mat-card class="maintenance-history-card">
<mat-card-title>Maintenance History</mat-
card-title>
<mat-table
[dataSource]="maintenanceHistory">
<ng-container matColumnDef="assetId">
<mat-header-cell *matHeaderCellDef>
Asset </mat-header-cell>
<mat-cell *matCellDef="let
history">{{ history.assetId }}</mat-cell>
</ng-container>
<ng-container
matColumnDef="maintenanceType">
<mat-header-cell *matHeaderCellDef>
Maintenance Type </mat-header-cell>
<mat-cell *matCellDef="let
history">{{ history.maintenanceType }}</mat-
cell>
</ng-container>
<ng-container
matColumnDef="scheduledDate">
<mat-header-cell *matHeaderCellDef>
Scheduled Date </mat-header-cell>
<mat-cell *matCellDef="let
history">{{ history.scheduledDate | date
}}</mat-cell>
</ng-container>
46 | P a g e
<ng-container matColumnDef="status">
<mat-header-cell *matHeaderCellDef>
Status </mat-header-cell>
<mat-cell *matCellDef="let
history">{{ history.status }}</mat-cell>
</ng-container>
<mat-header-row
*matHeaderRowDef="displayedColumns"></mat-
header-row>
<mat-row *matRowDef="let row; columns:
displayedColumns;"></mat-row>
</mat-table>
</mat-card>
</div>
css
Copy code
.maintenance-management-container {
display: flex;
flex-direction: column;
gap: 20px;
padding: 20px;
}
.maintenance-card, .maintenance-history-card {
width: 100%;
max-width: 800px;
margin: auto;
}
mat-form-field {
width: 100%;
47 | P a g e
margin-bottom: 16px;
}
mat-table {
width: 100%;
margin-top: 20px;
}
typescript
Copy code
import { Component, OnInit } from
'@angular/core';
import { MaintenanceService } from
'../services/maintenance.service';
import { AssetService } from
'../services/asset.service';
import { MatSnackBar } from
'@angular/material/snack-bar';
@Component({
selector: 'app-maintenance-management',
templateUrl: './maintenance-
management.component.html',
styleUrls: ['./maintenance-
management.component.css']
})
export class MaintenanceManagementComponent
implements OnInit {
workOrder = {
assetId: '',
maintenanceType: '',
scheduledDate: '',
description: ''
48 | P a g e
};
constructor(
private maintenanceService:
MaintenanceService,
private assetService: AssetService,
private snackBar: MatSnackBar
) {}
ngOnInit(): void {
this.loadAssets();
this.loadMaintenanceHistory();
}
loadAssets() {
this.assetService.getAssets().subscribe(assets
=> {
this.assets = assets;
});
}
loadMaintenanceHistory() {
this.maintenanceService.getMaintenanceHistory().
subscribe(history => {
this.maintenanceHistory = history;
});
}
createWorkOrder() {
49 | P a g e
this.maintenanceService.createWorkOrder(this.wor
kOrder).subscribe(
(response) => {
this.snackBar.open('Work order created
successfully!', 'Close', {
duration: 2000
});
this.loadMaintenanceHistory();
this.workOrder = { assetId: '',
maintenanceType: '', scheduledDate: '',
description: '' };
},
(error) => {
this.snackBar.open('Error creating work
order', 'Close', {
duration: 2000
});
}
);
}
}
typescript
Copy code
import { Injectable } from '@angular/core';
import { HttpClient } from
'@angular/common/http';
import { Observable } from 'rxjs';
@Injectable({
providedIn: 'root'
})
export class MaintenanceService {
50 | P a g e
private apiUrl =
'http://localhost:3000/maintenance'; // Backend
API URL
createWorkOrder(workOrder: any):
Observable<any> {
return this.http.post(this.apiUrl,
workOrder);
}
getMaintenanceHistory(): Observable<any[]> {
return this.http.get<any[]>(this.apiUrl);
}
}
javascript
Copy code
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const app = express();
const port = 3000;
// Middlewares
app.use(cors());
app.use(bodyParser.json());
// Routes
51 | P a g e
const maintenanceRoutes =
require('./routes/maintenanceRoutes');
app.use('/maintenance', maintenanceRoutes);
app.listen(port, () => {
console.log(`Server running at
http://localhost:${port}`);
});
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const Maintenance =
sequelize.define('Maintenance', {
assetId: {
type: DataTypes.INTEGER,
allowNull: false
},
maintenanceType: {
type: DataTypes.STRING,
allowNull: false
},
scheduledDate: {
type: DataTypes.DATE,
allowNull: false
},
description: {
type: DataTypes.STRING,
allowNull: true
},
status: {
type: DataTypes.STRING,
defaultValue: 'Scheduled'
52 | P a g e
}
});
return Maintenance;
};
javascript
Copy code
const { Maintenance } = require('../models');
53 | P a g e
const maintenanceHistory = await
Maintenance.findAll();
res.status(200).json(maintenanceHistory);
} catch (error) {
console.error(error);
res.status(500).send('Error fetching
maintenance history');
}
};
javascript
Copy code
const express = require('express');
const router = express.Router();
const maintenanceController =
require('../controllers/maintenanceController');
module.exports = router;
javascript
Copy code
const sequelize = require('./config/database');
const Maintenance =
require('./models/Maintenance');
54 | P a g e
sequelize.sync({ force: true }) // Sync the
database (use with caution in production)
.then(() => console.log("Database
synchronized"))
.catch((error) => console.error("Error syncing
database:", error));
Purpose:
Key Features:
Depreciation Calculation:
Automates the calculation of asset depreciation based on various
methods (e.g., straight-line, declining balance). Users can set
depreciation rules and customize the depreciation schedule.
Asset Valuation:
Tracks the current value of assets based on their depreciation
status, and generates reports on the value of assets over time.
55 | P a g e
Financial Integration:
Syncs asset data with financial systems (e.g., ERP or accounting
software) for budgeting, forecasting, and cost reporting.
Capitalization & Disposal:
Manages the capitalization of assets and handles the disposal or
sale of assets at the end of their lifecycle, including generating
necessary financial reports.
Tax Compliance:
Ensures asset depreciation complies with tax regulations by
generating tax-related reports for audits.
56 | P a g e
a) Front-End (HTML, CSS, JavaScript, Angular & Angular
Material)
html
Copy code
<div class="depreciation-management-container">
<mat-card class="depreciation-form">
<mat-card-title>Asset Depreciation &
Financial Management</mat-card-title>
<form (ngSubmit)="calculateDepreciation()"
#depreciationForm="ngForm">
<mat-form-field appearance="fill">
<mat-label>Asset</mat-label>
<mat-select
[(ngModel)]="depreciation.assetId"
name="assetId" required>
<mat-option *ngFor="let asset of
assets" [value]="asset.id">{{ asset.assetType }}
- {{ asset.serialNumber }}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Depreciation Method</mat-
label>
<mat-select
[(ngModel)]="depreciation.depreciationMethod"
name="depreciationMethod" required>
<mat-option value="straight-
line">Straight-Line</mat-option>
57 | P a g e
<mat-option value="declining-
balance">Declining Balance</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Depreciation Start Date</mat-
label>
<input matInput [matDatepicker]="picker"
[(ngModel)]="depreciation.startDate"
name="startDate" required>
<mat-datepicker-toggle matSuffix
[for]="picker"></mat-datepicker-toggle>
<mat-datepicker #picker></mat-
datepicker>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Depreciation Period (in
years)</mat-label>
<input matInput type="number"
[(ngModel)]="depreciation.period" name="period"
required>
</mat-form-field>
<mat-card class="depreciation-report-card">
<mat-card-title>Depreciation Report</mat-
card-title>
<mat-table
[dataSource]="depreciationReport">
58 | P a g e
<ng-container matColumnDef="assetId">
<mat-header-cell *matHeaderCellDef>
Asset </mat-header-cell>
<mat-cell *matCellDef="let
report">{{ report.assetId }}</mat-cell>
</ng-container>
<ng-container
matColumnDef="depreciationValue">
<mat-header-cell *matHeaderCellDef>
Depreciation Value </mat-header-cell>
<mat-cell *matCellDef="let
report">{{ report.depreciationValue |
currency }}</mat-cell>
</ng-container>
<ng-container matColumnDef="currentValue">
<mat-header-cell *matHeaderCellDef>
Current Value </mat-header-cell>
<mat-cell *matCellDef="let
report">{{ report.currentValue | currency
}}</mat-cell>
</ng-container>
<mat-header-row
*matHeaderRowDef="displayedColumns"></mat-
header-row>
<mat-row *matRowDef="let row; columns:
displayedColumns;"></mat-row>
</mat-table>
</mat-card>
</div>
59 | P a g e
css
Copy code
.depreciation-management-container {
display: flex;
flex-direction: column;
gap: 20px;
padding: 20px;
}
.depreciation-form, .depreciation-report-card {
width: 100%;
max-width: 800px;
margin: auto;
}
mat-form-field {
width: 100%;
margin-bottom: 16px;
}
mat-table {
width: 100%;
margin-top: 20px;
}
typescript
Copy code
import { Component, OnInit } from
'@angular/core';
import { DepreciationService } from
'../services/depreciation.service';
import { AssetService } from
'../services/asset.service';
60 | P a g e
import { MatSnackBar } from
'@angular/material/snack-bar';
@Component({
selector: 'app-asset-depreciation',
templateUrl: './asset-
depreciation.component.html',
styleUrls: ['./asset-
depreciation.component.css']
})
export class AssetDepreciationComponent
implements OnInit {
depreciation = {
assetId: '',
depreciationMethod: 'straight-line',
startDate: '',
period: 5
};
constructor(
private depreciationService:
DepreciationService,
private assetService: AssetService,
private snackBar: MatSnackBar
) {}
ngOnInit(): void {
this.loadAssets();
}
61 | P a g e
loadAssets() {
this.assetService.getAssets().subscribe(assets
=> {
this.assets = assets;
});
}
calculateDepreciation() {
this.depreciationService.calculateDepreciation(t
his.depreciation).subscribe(
(report) => {
this.snackBar.open('Depreciation
calculated successfully!', 'Close', {
duration: 2000
});
this.depreciationReport = report;
},
(error) => {
this.snackBar.open('Error calculating
depreciation', 'Close', {
duration: 2000
});
}
);
}
}
typescript
Copy code
import { Injectable } from '@angular/core';
import { HttpClient } from
'@angular/common/http';
62 | P a g e
import { Observable } from 'rxjs';
@Injectable({
providedIn: 'root'
})
export class DepreciationService {
private apiUrl =
'http://localhost:3000/depreciation'; //
Backend API URL
calculateDepreciation(depreciation: any):
Observable<any[]> {
return this.http.post<any[]>(this.apiUrl,
depreciation);
}
}
javascript
Copy code
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const app = express();
const port = 3000;
// Middlewares
app.use(cors());
app.use(bodyParser.json());
63 | P a g e
// Routes
const depreciationRoutes =
require('./routes/depreciationRoutes');
app.use('/depreciation', depreciationRoutes);
app.listen(port, () => {
console.log(`Server running at
http://localhost:${port}`);
});
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const Depreciation =
sequelize.define('Depreciation', {
assetId: {
type: DataTypes.INTEGER,
allowNull: false
},
depreciationMethod: {
type: DataTypes.STRING,
allowNull: false
},
startDate: {
type: DataTypes.DATE,
allowNull: false
},
period: {
type: DataTypes.INTEGER,
allowNull: false
},
depreciationValue: {
64 | P a g e
type: DataTypes.FLOAT,
allowNull: true
},
currentValue: {
type: DataTypes.FLOAT,
allowNull: true
}
});
return Depreciation;
};
javascript
Copy code
const { Depreciation, Asset } =
require('../models');
65 | P a g e
const rate = 2 / assetLife; // Double
declining balance
for (let i = 0; i < assetLife; i++) {
depreciationValue += currentValue * rate;
currentValue -= currentValue * rate;
}
}
// Calculate depreciation
const { depreciationValue, currentValue } =
calculateDepreciationValue(
asset, depreciationMethod, startDate,
period
);
66 | P a g e
depreciationMethod,
startDate,
period,
depreciationValue,
currentValue
});
res.status(200).json([
{
assetId: asset.id,
depreciationValue:
depreciationRecord.depreciationValue,
currentValue:
depreciationRecord.currentValue
}
]);
} catch (error) {
console.error(error);
res.status(500).send('Error calculating
depreciation');
}
};
javascript
Copy code
const express = require('express');
const router = express.Router();
const depreciationController =
require('../controllers/depreciationController')
;
67 | P a g e
router.post('/',
depreciationController.calculateDepreciation);
module.exports = router;
68 | P a g e
4. Asset Reporting & Analytics Module
Purpose:
Key Features:
Customizable Reports:
Generate asset-related reports such as asset utilization,
maintenance costs, depreciation, and lifecycle analysis. Reports
can be customized by date range, asset category, and other
parameters.
Asset Utilization & Performance Analysis:
Analyze how assets are being used across the organization,
identifying underutilized or overused assets. This helps optimize
asset deployment and improve resource allocation.
Cost-Benefit Analysis:
Evaluate the total cost of ownership (TCO) for assets, including
acquisition, maintenance, and disposal costs, against the benefits or
productivity gains the assets bring.
Depreciation & Financial Reports:
Generate reports on asset depreciation, asset book values, and
69 | P a g e
financial summaries, which can be used for accounting, auditing,
and financial forecasting.
Dashboards & KPIs:
Create interactive dashboards that provide key performance
indicators (KPIs) on asset management, including maintenance
trends, cost per asset, and asset lifespan.
Below is the programming code for the Asset Reporting & Analytics
Module for the Asset Management System (AMS) using HTML,
CSS, JavaScript, Angular, Angular Material for the front-end and
Node.js, Express.js, Sequelize, SQL Server for the back-end.
70 | P a g e
a) Front-End (HTML, CSS, JavaScript, Angular & Angular
Material)
html
Copy code
<div class="reporting-container">
<mat-card class="reporting-form">
<mat-card-title>Asset Reporting &
Analytics</mat-card-title>
<form (ngSubmit)="generateReport()"
#reportForm="ngForm">
<mat-form-field appearance="fill">
<mat-label>Asset Category</mat-label>
<mat-select
[(ngModel)]="reportData.assetCategory"
name="assetCategory" required>
<mat-option *ngFor="let category of
assetCategories"
[value]="category">{{ category }}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Start Date</mat-label>
<input matInput
[matDatepicker]="startPicker"
[(ngModel)]="reportData.startDate"
name="startDate" required>
<mat-datepicker-toggle matSuffix
[for]="startPicker"></mat-datepicker-toggle>
71 | P a g e
<mat-datepicker #startPicker></mat-
datepicker>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>End Date</mat-label>
<input matInput
[matDatepicker]="endPicker"
[(ngModel)]="reportData.endDate" name="endDate"
required>
<mat-datepicker-toggle matSuffix
[for]="endPicker"></mat-datepicker-toggle>
<mat-datepicker #endPicker></mat-
datepicker>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Report Type</mat-label>
<mat-select
[(ngModel)]="reportData.reportType"
name="reportType" required>
<mat-option value="utilization">Asset
Utilization</mat-option>
<mat-option value="cost-benefit">Cost-
Benefit Analysis</mat-option>
<mat-option
value="depreciation">Depreciation Report</mat-
option>
</mat-select>
</mat-form-field>
72 | P a g e
<mat-card *ngIf="reportData.reportGenerated"
class="reporting-result">
<mat-card-title>Generated Report</mat-card-
title>
<mat-table
[dataSource]="reportData.reportResults">
<ng-container matColumnDef="assetId">
<mat-header-cell *matHeaderCellDef>
Asset ID </mat-header-cell>
<mat-cell *matCellDef="let
report">{{ report.assetId }}</mat-cell>
</ng-container>
<ng-container matColumnDef="reportValue">
<mat-header-cell *matHeaderCellDef>
Report Value </mat-header-cell>
<mat-cell *matCellDef="let
report">{{ report.reportValue }}</mat-cell>
</ng-container>
<mat-header-row
*matHeaderRowDef="displayedColumns"></mat-
header-row>
<mat-row *matRowDef="let row; columns:
displayedColumns;"></mat-row>
</mat-table>
</mat-card>
</div>
css
Copy code
.reporting-container {
73 | P a g e
display: flex;
flex-direction: column;
gap: 20px;
padding: 20px;
}
.reporting-form, .reporting-result {
width: 100%;
max-width: 800px;
margin: auto;
}
mat-form-field {
width: 100%;
margin-bottom: 16px;
}
mat-table {
width: 100%;
margin-top: 20px;
}
typescript
Copy code
import { Component, OnInit } from
'@angular/core';
import { ReportingService } from
'../services/reporting.service';
import { MatSnackBar } from
'@angular/material/snack-bar';
@Component({
selector: 'app-asset-reporting',
74 | P a g e
templateUrl: './asset-
reporting.component.html',
styleUrls: ['./asset-reporting.component.css']
})
export class AssetReportingComponent implements
OnInit {
reportData = {
assetCategory: '',
startDate: '',
endDate: '',
reportType: 'utilization',
reportGenerated: false,
reportResults: []
};
constructor(
private reportingService: ReportingService,
private snackBar: MatSnackBar
) {}
ngOnInit(): void {}
generateReport() {
this.reportingService.generateReport(this.report
Data).subscribe(
(data) => {
this.reportData.reportGenerated = true;
this.reportData.reportResults = data;
75 | P a g e
this.snackBar.open('Report generated
successfully!', 'Close', { duration: 2000 });
},
(error) => {
this.snackBar.open('Error generating
report', 'Close', { duration: 2000 });
}
);
}
}
typescript
Copy code
import { Injectable } from '@angular/core';
import { HttpClient } from
'@angular/common/http';
import { Observable } from 'rxjs';
@Injectable({
providedIn: 'root'
})
export class ReportingService {
private apiUrl =
'http://localhost:3000/reports'; // Backend API
URL
generateReport(reportData: any):
Observable<any[]> {
return this.http.post<any[]>(this.apiUrl,
reportData);
76 | P a g e
}
}
javascript
Copy code
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const app = express();
const port = 3000;
// Middlewares
app.use(cors());
app.use(bodyParser.json());
// Routes
const reportingRoutes =
require('./routes/reportingRoutes');
app.use('/reports', reportingRoutes);
app.listen(port, () => {
console.log(`Server running at
http://localhost:${port}`);
});
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const Report = sequelize.define('Report', {
77 | P a g e
assetId: {
type: DataTypes.INTEGER,
allowNull: false
},
reportType: {
type: DataTypes.STRING,
allowNull: false
},
reportValue: {
type: DataTypes.FLOAT,
allowNull: false
},
startDate: {
type: DataTypes.DATE,
allowNull: false
},
endDate: {
type: DataTypes.DATE,
allowNull: false
}
});
return Report;
};
javascript
Copy code
const { Report, Asset, Maintenance, Depreciation
} = require('../models');
78 | P a g e
async function
generateUtilizationReport(startDate, endDate,
assetCategory) {
return await Asset.findAll({
where: { category: assetCategory },
include: [
{
model: Maintenance,
where: {
maintenanceDate: {
[Sequelize.Op.between]: [startDate,
endDate]
}
},
attributes: ['maintenanceDate']
}
]
});
}
79 | P a g e
},
attributes: ['maintenanceCost']
},
{
model: Depreciation,
where: {
startDate: {
[Sequelize.Op.lte]: endDate
}
},
attributes: ['depreciationValue']
}
]
});
}
80 | P a g e
startDate: { [Sequelize.Op.lte]:
endDate },
assetCategory: assetCategory
}
});
}
res.status(200).json(reportResults.map(report =>
({
assetId: report.id,
reportValue: report.reportValue || 0
})));
} catch (error) {
console.error(error);
res.status(500).send('Error generating
report');
}
};
javascript
Copy code
const express = require('express');
const router = express.Router();
const reportingController =
require('../controllers/reportingController');
module.exports = router;
81 | P a g e
This Asset Reporting & Analytics Module allows organizations to
generate customized reports based on asset data for better decision-
making. The module covers features like customizable reports, asset
utilization analysis, cost-benefit analysis, and depreciation tracking.
By integrating with other modules such as Asset Registration,
Maintenance, and Depreciation, this module enables a comprehensive
view of asset performance and costs.
Through the front-end, users can easily filter reports by category, date
range, and report type, while the back-end leverages Sequelize ORM to
query SQL Server for relevant data. The integration of Angular
Material enhances the UI with an interactive, user-friendly experience.
Purpose:
Key Features:
82 | P a g e
Role-Based Access Control (RBAC):
Define roles (e.g., Admin, Asset Manager, Technician, Financial
Officer) and assign specific permissions to each role, ensuring that
users can only access and modify the data relevant to their duties.
User Authentication & Security:
Support for multi-factor authentication (MFA), single sign-on
(SSO), and strong password policies to ensure secure access to the
system.
Audit Logs:
Track user activities and changes made within the system for
compliance and audit purposes. Logs record actions such as asset
modifications, maintenance activities, and report generation.
Notifications & Alerts:
Configure notification settings to alert users about system
activities, pending tasks, maintenance schedules, or security-
related events.
83 | P a g e
Coding for User & Role Management Module
The User & Role Management Module ensures that user access and
permissions are well-managed and that the system adheres to security
best practices. It provides role-based access control (RBAC), supports
authentication mechanisms, tracks audit logs, and offers notifications
and alerts for the users.
Below is the full code structure for the User & Role Management
Module using:
Front-end:
HTML
CSS
JavaScript
Angular Framework
Angular Material
Back-end:
Node.js
Express.js
Sequelize ORM
SQL Server
84 | P a g e
a) Front-End (HTML, CSS, JavaScript, Angular Framework &
Angular Material)
html
Copy code
<div class="user-management-container">
<mat-card class="user-form">
<mat-card-title>User & Role Management</mat-
card-title>
<mat-form-field appearance="fill">
<mat-label>Role</mat-label>
<mat-select [(ngModel)]="userData.role"
name="role" required>
<mat-option *ngFor="let role of roles"
[value]="role">{{ role }}</mat-option>
</mat-select>
</mat-form-field>
85 | P a g e
<button mat-raised-button color="primary"
type="submit">Assign Role</button>
</form>
</mat-card>
<ng-container matColumnDef="activity">
<mat-header-cell *matHeaderCellDef>
Activity </mat-header-cell>
<mat-cell *matCellDef="let
log">{{ log.activity }}</mat-cell>
</ng-container>
<ng-container matColumnDef="timestamp">
<mat-header-cell *matHeaderCellDef>
Timestamp </mat-header-cell>
<mat-cell *matCellDef="let
log">{{ log.timestamp | date }}</mat-cell>
</ng-container>
<mat-header-row
*matHeaderRowDef="displayedColumns"></mat-
header-row>
86 | P a g e
<mat-row *matRowDef="let row; columns:
displayedColumns;"></mat-row>
</mat-table>
</mat-card>
</div>
css
Copy code
.user-management-container {
display: flex;
flex-direction: column;
gap: 20px;
padding: 20px;
}
.user-form, .activity-logs {
width: 100%;
max-width: 800px;
margin: auto;
}
mat-form-field {
width: 100%;
margin-bottom: 16px;
}
mat-table {
width: 100%;
margin-top: 20px;
}
typescript
87 | P a g e
Copy code
import { Component, OnInit } from
'@angular/core';
import { UserService } from
'../services/user.service';
import { MatSnackBar } from
'@angular/material/snack-bar';
@Component({
selector: 'app-user-management',
templateUrl: './user-
management.component.html',
styleUrls: ['./user-management.component.css']
})
export class UserManagementComponent implements
OnInit {
userData = {
userId: '',
role: ''
};
users = [];
roles = ['Admin', 'Asset Manager',
'Technician', 'Financial Officer'];
userActivityLogs = [];
displayedColumns: string[] = ['userId',
'activity', 'timestamp'];
constructor(
private userService: UserService,
private snackBar: MatSnackBar
) {}
ngOnInit(): void {
this.loadUsers();
88 | P a g e
this.loadActivityLogs();
}
loadUsers(): void {
this.userService.getUsers().subscribe(users
=> {
this.users = users;
});
}
loadActivityLogs(): void {
this.userService.getActivityLogs().subscribe(log
s => {
this.userActivityLogs = logs;
});
}
assignRole(): void {
this.userService.assignRole(this.userData).subsc
ribe(
(response) => {
this.snackBar.open('Role assigned
successfully!', 'Close', { duration: 2000 });
this.loadActivityLogs(); // Refresh logs
after role assignment
},
(error) => {
this.snackBar.open('Error assigning
role', 'Close', { duration: 2000 });
}
);
}
}
89 | P a g e
4. User Service (user.service.ts)
typescript
Copy code
import { Injectable } from '@angular/core';
import { HttpClient } from
'@angular/common/http';
import { Observable } from 'rxjs';
@Injectable({
providedIn: 'root'
})
export class UserService {
private apiUrl =
'http://localhost:3000/users'; // Backend API
URL
90 | P a g e
return
this.http.post<any>(`${this.apiUrl}/assign-
role`, userData);
}
}
javascript
Copy code
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const app = express();
const port = 3000;
// Middlewares
app.use(cors());
app.use(bodyParser.json());
// Routes
const userRoutes =
require('./routes/userRoutes');
app.use('/users', userRoutes);
app.listen(port, () => {
console.log(`Server running at
http://localhost:${port}`);
});
91 | P a g e
User Model (models/User.js):
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const User = sequelize.define('User', {
name: {
type: DataTypes.STRING,
allowNull: false
},
email: {
type: DataTypes.STRING,
unique: true,
allowNull: false
},
password: {
type: DataTypes.STRING,
allowNull: false
}
});
return User;
};
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
92 | P a g e
const Role = sequelize.define('Role', {
name: {
type: DataTypes.STRING,
allowNull: false
},
permissions: {
type: DataTypes.JSONB,
allowNull: false
}
});
return Role;
};
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const ActivityLog =
sequelize.define('ActivityLog', {
userId: {
type: DataTypes.INTEGER,
allowNull: false
},
activity: {
type: DataTypes.STRING,
allowNull: false
93 | P a g e
},
timestamp: {
type: DataTypes.DATE,
defaultValue: DataTypes.NOW
}
});
return ActivityLog;
};
javascript
Copy code
const { User, Role, ActivityLog } =
require('../models');
94 | P a g e
}
};
if (!roleRecord) {
return res.status(400).send('Role not
found');
}
user.roleId = roleRecord.id;
await user.save();
res.status(200).send('Role assigned
successfully');
} catch (error) {
console.error(error);
95 | P a g e
res.status(500).send('Error assigning
role');
}
};
javascript
Copy code
const express = require('express');
const router = express.Router();
const userController =
require('../controllers/userController');
96 | P a g e
// Assign a role to a user
router.post('/assign-role',
userController.assignRole);
module.exports = router;
Purpose:
97 | P a g e
The Integration & API module allows the AMS to interface with
external systems such as ERP, accounting software, procurement
platforms, and IoT devices (e.g., RFID readers, barcode scanners) for
seamless data exchange.
Key Features:
System Integration:
Integrates the AMS with other business systems such as ERP,
CRM, financial systems, and inventory management to
synchronize asset data across the enterprise.
API for External Access:
Provides APIs for external systems to access asset data, enabling
automated data entry, reporting, and synchronization with other
business applications.
IoT Device Integration:
Integrates with IoT devices (e.g., RFID scanners, GPS tracking) to
automatically update asset location, usage, and condition data.
Data Import/Export:
Allows bulk import of asset data from external files (CSV, Excel,
etc.) and export of asset data to other systems or reports.
98 | P a g e
Works with the Asset Registration & Tracking Module to
synchronize asset data with ERP and procurement systems.
Integrates with Maintenance Management and Financial
Modules for a smooth exchange of maintenance schedules and
financial updates.
Below is the programming code for the Integration & API Module,
including both front-end and back-end implementations.
html
Copy code
<div class="integration-api-container">
<mat-card class="api-form">
<mat-card-title>System Integration &
API</mat-card-title>
<!-- API Request Form -->
99 | P a g e
<form (ngSubmit)="submitAPIRequest()"
#apiForm="ngForm">
<mat-form-field appearance="fill">
<mat-label>API Endpoint</mat-label>
<input matInput
[(ngModel)]="apiData.endpoint" name="endpoint"
required>
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Data</mat-label>
<textarea matInput
[(ngModel)]="apiData.data" name="data"
required></textarea>
</mat-form-field>
<div>
<button mat-raised-button
(click)="importData()">Import Data</button>
<button mat-raised-button
(click)="exportData()">Export Data</button>
</div>
</mat-card>
100 | P a g e
<mat-card class="api-response"
*ngIf="apiResponse">
<mat-card-title>API Response</mat-card-
title>
<pre>{{ apiResponse | json }}</pre>
</mat-card>
</div>
css
Copy code
.integration-api-container {
display: flex;
flex-direction: column;
gap: 20px;
padding: 20px;
}
mat-form-field {
width: 100%;
margin-bottom: 16px;
}
button {
margin-top: 10px;
}
pre {
101 | P a g e
white-space: pre-wrap;
word-wrap: break-word;
}
typescript
Copy code
import { Component, OnInit } from
'@angular/core';
import { IntegrationService } from
'../services/integration.service';
import { MatSnackBar } from
'@angular/material/snack-bar';
@Component({
selector: 'app-integration-api',
templateUrl: './integration-
api.component.html',
styleUrls: ['./integration-api.component.css']
})
export class IntegrationApiComponent implements
OnInit {
apiData = {
endpoint: '',
data: ''
};
apiResponse: any = null;
constructor(
private integrationService:
IntegrationService,
private snackBar: MatSnackBar
) {}
102 | P a g e
ngOnInit(): void {}
103 | P a g e
// Method to export data
exportData(): void {
this.integrationService.exportData().subscribe(
(response) => {
this.snackBar.open('Data export
successful', 'Close', { duration: 2000 });
},
(error) => {
this.snackBar.open('Error exporting
data', 'Close', { duration: 2000 });
console.error(error);
}
);
}
}
typescript
Copy code
import { Injectable } from '@angular/core';
import { HttpClient } from
'@angular/common/http';
import { Observable } from 'rxjs';
@Injectable({
providedIn: 'root'
})
export class IntegrationService {
private apiUrl =
'http://localhost:3000/integration'; // Backend
API URL
javascript
Copy code
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const app = express();
const port = 3000;
105 | P a g e
// Middlewares
app.use(cors());
app.use(bodyParser.json());
// Routes
const integrationRoutes =
require('./routes/integrationRoutes');
app.use('/integration', integrationRoutes);
app.listen(port, () => {
console.log(`Server running at
http://localhost:${port}`);
});
javascript
Copy code
const { Asset } = require('../models');
const axios = require('axios'); // To handle API
requests to external systems
106 | P a g e
res.status(500).send('Error making API
request');
}
};
res.status(200).json(assets);
} catch (error) {
console.error(error);
res.status(500).send('Error exporting
data');
107 | P a g e
}
};
javascript
Copy code
const express = require('express');
const router = express.Router();
const integrationController =
require('../controllers/integrationController');
module.exports = router;
javascript
Copy code
module.exports = (sequelize, DataTypes) => {
const Asset = sequelize.define('Asset', {
name: {
type: DataTypes.STRING,
108 | P a g e
allowNull: false
},
category: {
type: DataTypes.STRING,
allowNull: false
},
location: {
type: DataTypes.STRING,
allowNull: false
},
value: {
type: DataTypes.FLOAT,
allowNull: false
},
status: {
type: DataTypes.STRING,
allowNull: false
}
});
return Asset;
};
The Integration & API Module provides a crucial bridge between the
Asset Management System (AMS) and external systems. It allows the
AMS to integrate with ERP, CRM, IoT devices, and other platforms for
data exchange and synchronization. With API endpoints for external
access, the module facilitates automated data entry, reporting, and
synchronization. The Angular front-end provides a user-friendly
interface for API interaction, while the Node.js back-end ensures
109 | P a g e
smooth communication with external systems and manages the
import/export functionality.
110 | P a g e
tables, which could be used for the development of the AMS. This
structure includes key entities related to asset management, as well as
their attributes and relationships.
1. Assets Table
INT (Primary
AssetID Unique identifier for each asset.
Key)
asset.
112 | P a g e
Column Name Data Type Description
"Furniture").
Description of the
CategoryDescription TEXT
category.
maintenance.
(e.g., "Straight-line",
"Declining Balance").
The amount of
AnnualDepreciation DECIMAL(10,2) depreciation applied
annually.
Total depreciation
AccumulatedDepreciation DECIMAL(10,2) accumulated until
the current date.
5. Vendors Table
115 | P a g e
Stores information about vendors or suppliers providing assets.
6. Users Table
Stores information about the system users (admin, asset managers, etc.).
116 | P a g e
Column Name Data Type Description
INT (Primary
UserID Unique identifier for each user.
Key)
117 | P a g e
Column Name Data Type Description
118 | P a g e
Column Name Data Type Description
9. Reports Table
INT (Primary
ReportID Unique identifier for each report.
Key)
119 | P a g e
Column Name Data Type Description
Stores system audit logs to track user activity and changes to assets.
You can further expand or adjust these structures based on the specific
requirements of your AMS, such as adding additional tables for
advanced reporting, audit features, or integrating IoT and other external
systems.
Tool Specifications
121 | P a g e
The development of an Asset Management System (AMS) involves a
variety of tools, technologies, and platforms for designing,
implementing, testing, and deploying the software. Below is a
comprehensive overview of the tool specifications needed for building a
robust, scalable, and secure AMS.
Programming Languages:
Primary Language(s):
o Java (for enterprise-grade backend development, cross-
platform compatibility)
o C# (for Windows-based solutions)
o Python (for lightweight or rapid development)
o JavaScript (Node.js) (for full-stack development and
asynchronous operations)
Database:
124 | P a g e
2. Development Tools for APIs & Integration
API Development:
API Integration:
125 | P a g e
3. UI/UX Design Tools
126 | P a g e
Unit Testing Frameworks:
Cloud Platforms:
128 | P a g e
Amazon Web Services (AWS): Offers cloud hosting, databases
(RDS, DynamoDB), and other services like EC2 (compute
instances), S3 (storage), Lambda (serverless computing), and
CloudWatch (monitoring).
Microsoft Azure: Provides cloud services including virtual
machines, databases, and integrated DevOps tools.
Google Cloud Platform (GCP): Cloud services including
compute, database, and AI/ML services.
Web Hosting/Deployment:
129 | P a g e
Heroku: A cloud platform for deploying, managing, and scaling
applications. Ideal for quick deployment without managing
infrastructure.
7. Security Tools
130 | P a g e
Prometheus + Grafana: Open-source tools for monitoring and
visualizing metrics from the AMS, such as server load, database
query performance, and uptime.
Google Analytics: Can be integrated into the frontend to track user
interactions and behavior patterns for analytics and optimization.
131 | P a g e
Entities and Relationships in AMS
1. Assets
o Attributes: AssetID (PK), AssetName, AssetCategoryID
(FK), PurchaseDate, PurchaseCost, AssetLocation,
SerialNumber, WarrantyPeriod, Status, Barcode, VendorID
(FK)
o Relationships:
One Asset belongs to one Category (One-to-Many
relationship with Asset Categories).
One Asset is provided by one Vendor (One-to-Many
relationship with Vendors).
One Asset can have many Maintenance Records
(One-to-Many with Maintenance).
One Asset can have one or more Depreciation
Records (One-to-Many with Depreciation).
One Asset may be disposed of (One-to-Many with
Disposals).
2. Asset Categories
o Attributes: CategoryID (PK), CategoryName,
CategoryDescription
o Relationships:
One Category can have many Assets (One-to-Many
with Assets).
132 | P a g e
3. Maintenance
o Attributes: MaintenanceID (PK), AssetID (FK),
MaintenanceType, MaintenanceDate, TechnicianName, Cost,
Description, NextMaintenanceDate
o Relationships:
One Maintenance Record is associated with one Asset
(Many-to-One with Assets).
4. Vendors
o Attributes: VendorID (PK), VendorName,
VendorContactName, VendorContactEmail,
VendorContactPhone, VendorAddress
o Relationships:
One Vendor can supply many Assets (One-to-Many
with Assets).
5. Depreciation
o Attributes: DepreciationID (PK), AssetID (FK),
DepreciationMethod, DepreciationStartDate,
DepreciationEndDate, AnnualDepreciation,
AccumulatedDepreciation, AssetBookValue
o Relationships:
One Depreciation record is linked to one Asset (Many-
to-One with Assets).
6. Disposals
133 | P a g e
o Attributes: DisposalID (PK), AssetID (FK), DisposalDate,
DisposalType, DisposalValue, DisposalReason
o Relationships:
One Disposal Record is linked to one Asset (Many-to-
One with Assets).
7. Users
o Attributes: UserID (PK), Username, PasswordHash, Role,
Email, FirstName, LastName, Status
o Relationships:
One User can generate many Reports (One-to-Many
with Reports).
One User can perform many Audit Actions (One-to-
Many with Audit Logs).
8. Reports
o Attributes: ReportID (PK), ReportName, ReportType,
ReportData, GeneratedBy (FK), GenerationDate
o Relationships:
One Report is generated by one User (Many-to-One
with Users).
9. Audit Logs
o Attributes: AuditID (PK), UserID (FK), ActionType,
AssetID (FK), Timestamp, Details
o Relationships:
134 | P a g e
One Audit Log record is linked to one User (Many-to-
One with Users).
One Audit Log may reference one Asset (Many-to-One
with Assets).
135 | P a g e
136 | P a g e
Other Diagrams for the AMS
In addition to the Entity Relationship Diagram (ERD), there are other
diagrams that can help illustrate different aspects of the Asset
Management System (AMS):
A Use Case Diagram illustrates the interaction between users and the
system. It is typically used for visualizing system functionality from an
end-user perspective.
Actors:
Admin: Manages users, vendors, and generates reports.
Asset Manager: Handles asset registration, maintenance,
depreciation, and disposal.
Technician: Performs maintenance on assets.
End User: Views asset data and reports.
Use Cases:
Register Asset
Assign Asset to Location
Track Maintenance
Depreciate Asset
Dispose Asset
Generate Report
137 | P a g e
View Asset Details
Audit Logs
A Data Flow Diagram (DFD) shows the flow of data through the
system and helps in understanding how data moves and is processed
within different modules.
139 | P a g e
4. Sequence Diagram:
Steps:
1. User submits an asset registration form.
2. The system validates and processes the form.
3. The system adds asset data to the database.
4. Confirmation is sent to the user.
140 | P a g e
Example of Sequence Diagram:
141 | P a g e
Diagram ties everything together, outlining how different components
and external systems integrate within the AMS.
Testing Process
The testing process for an Asset Management System (AMS) is critical
to ensure the software meets all functional, non-functional, and security
requirements while performing efficiently under various conditions. The
testing process includes multiple stages, from initial unit testing to
system and user acceptance testing (UAT), and it covers various testing
types like functional, integration, performance, security, and usability
testing.
Objective: Ensure that all requirements are clearly defined, testable, and
understood before initiating any testing activities.
142 | P a g e
Review Non-Functional Requirements: Understand
performance, scalability, security, and usability requirements (e.g.,
system uptime, response times, data protection).
Create Test Plan: Develop a comprehensive Test Plan that
includes:
o Scope of testing
o Test strategies and methodologies
o Resources needed (tools, personnel)
o Testing schedule
o Entry and exit criteria
o Risk management
2. Test Design
143 | P a g e
o Boundary Conditions: Test edge cases, such as maximum
asset values, large data inputs, and unusual input formats.
o Negative Test Cases: Simulate invalid inputs to ensure the
system handles errors properly.
Test Data Preparation: Prepare data sets that simulate real-world
scenarios, such as asset data, vendor information, maintenance
records, and depreciation details.
3. Types of Testing
Focus: Test small parts of the code, such as methods used for asset
registration, depreciation calculation, and database queries.
Tools:
o JUnit (for Java)
o xUnit (for C#)
o pytest (for Python)
o Jest (for JavaScript/Node.js)
Example Test Cases:
144 | P a g e
o Test the function responsible for calculating asset
depreciation based on a given method (e.g., straight-line or
declining balance).
o Verify the logic of adding a new asset into the database and
ensuring all fields are correctly populated.
145 | P a g e
o Check that asset maintenance records are correctly updated in
both the AMS and the associated inventory system.
146 | P a g e
3.4. User Interface (UI) Testing
147 | P a g e
Objective: Test the AMS under different load conditions to ensure it
performs well under normal and peak usage.
148 | P a g e
Objective: Ensure that the AMS is secure and protects user data and
system resources from unauthorized access.
149 | P a g e
o Nessus
Objective: Ensure that new changes or bug fixes have not introduced
new defects or affected existing features.
150 | P a g e
Objective: Validate that the AMS meets the needs of end-users and
business stakeholders.
151 | P a g e
Reporting: Regularly update stakeholders with test progress,
defect status, and test results to keep everyone informed about the
system's quality.
5. Test Closure
The Testing Process for an Asset Management System ensures that the
system is robust, secure, and performs according to user expectations.
By following a structured testing methodology—starting from unit
testing to user acceptance testing—you can identify defects early and
improve the overall quality of the AMS before deployment.
152 | P a g e
Conclusion and Recommendations
Conclusion
153 | P a g e
manufacturing, healthcare, IT infrastructure, or government agencies.
With features like maintenance management, asset tracking, report
generation, and user management, AMS provides a one-stop solution
for asset-related operations. Additionally, through automated
processes, it helps reduce manual effort, minimize human error, and
improve operational efficiency.
The integration of real-time data and analytics into the AMS enables
the generation of actionable insights. These insights are crucial for
strategic decision-making in areas such as cost allocation, procurement
strategies, and asset lifecycle management. Reports on asset
performance, depreciation, maintenance costs, and asset utilization can
be generated on demand, providing stakeholders with critical business
intelligence.
Recommendations
156 | P a g e
schedules, and avoid costly equipment breakdowns by
forecasting asset performance.
4. Integration with Other Enterprise Systems
o For many organizations, the AMS is just one component of a
broader enterprise ecosystem. It is essential to ensure that the
AMS integrates smoothly with other systems, such as
Enterprise Resource Planning (ERP), Customer
Relationship Management (CRM), Financial Systems, and
Procurement Systems.
o Seamless integration ensures that asset-related data flows
efficiently across departments and that financial,
procurement, and maintenance teams have access to
consistent, up-to-date asset information. Such integration
reduces the risk of errors, delays, and inefficiencies caused
by manual data entry.
5. Data Security and Privacy
o Data security is a paramount concern, particularly when
dealing with sensitive asset data, user information, and
financial records. The AMS must implement robust security
measures such as encryption, multi-factor authentication
(MFA), and role-based access controls (RBAC) to prevent
unauthorized access.
157 | P a g e
o Regular security audits and compliance checks should be
performed to ensure that the AMS adheres to industry
standards and regulations, such as General Data Protection
Regulation (GDPR) or Health Insurance Portability and
Accountability Act (HIPAA), when applicable.
6. Scalability and Future-Proofing
o As organizations grow, the volume of assets and the
complexity of asset management tasks also increase. The
AMS must be scalable, allowing for easy expansion and
modification to handle growing asset inventories and more
complex asset management processes.
o The development team should also consider the future needs
of the organization and the industry when designing the
system. Cloud-based solutions offer scalability benefits,
allowing businesses to expand storage and processing
capacity as needed without significant infrastructure
investment.
7. Cloud Adoption for Greater Flexibility
o Cloud-based AMS solutions can provide increased
flexibility, security, and cost-efficiency compared to on-
premise systems. With the rise of remote work and the need
for more collaborative tools, migrating the AMS to the cloud
158 | P a g e
can enable stakeholders to access asset information anytime,
anywhere.
o Cloud-based AMS also facilitates automatic software
updates, ensuring that the system remains up-to-date with
the latest features, patches, and security protocols without
requiring significant manual intervention.
8. Periodic System Audits and Upgrades
o Conduct regular audits to ensure that the AMS is being used
optimally and that any new business processes or regulatory
changes are incorporated. System performance should be
assessed periodically to identify bottlenecks or areas where
improvements can be made.
o Additionally, software upgrades should be planned and
executed in a way that minimizes disruption to daily
operations. Upgrades should include enhancements, new
features, and improvements based on user feedback and
emerging technology trends.
9. User-Centric Design
o The design of the AMS should always prioritize the end-user
experience. A user-friendly interface with intuitive
navigation, easy-to-understand forms, and clear error
messages will ensure that users can efficiently perform tasks
like asset tracking, reporting, and maintenance scheduling.
159 | P a g e
o User feedback should be continuously gathered to identify
areas where the user interface (UI) and user experience (UX)
can be improved. User-centric design also means offering
accessibility options for users with disabilities, such as screen
readers or customizable font sizes.
Final Thoughts
Ultimately, the success of the AMS depends not only on its functionality
but on its alignment with business needs, its ease of use, and its ability to
adapt to evolving industry requirements. With continuous investment in
training, system enhancements, and technological advancements, the
AMS can become a critical part of an organization’s long-term strategy
for managing its assets efficiently and effectively.
160 | P a g e
Bibliography
1. Pereira, P., & Oliveira, F. (2017).
"An Efficient Asset Management System Framework for
Organizational Decision-Making." Journal of Asset Management,
18(3), 153-162.
This paper discusses frameworks for implementing asset
management systems and their role in improving decision-making
and asset utilization.
2. Barrett, M. A., & Gauthier, P. (2019).
"Integrating Asset Management Systems with Enterprise Resource
Planning (ERP)." International Journal of Information
Management, 45, 98-106.
Explores the integration of AMS with ERP systems to improve
asset tracking and streamline data flow across departments.
3. Smith, R. (2020).
Asset Management: A Comprehensive Guide to Managing and
Maintaining Assets. McGraw-Hill Education.
A detailed guide on asset management principles, lifecycle
management, and core AMS components like tracking,
maintenance, and reporting.
4. Gartner Inc. (2021).
"Market Guide for Asset Management Systems." Gartner
161 | P a g e
Research.
A market overview comparing top AMS vendors, key features, and
industry trends.
5. Liu, H., & Zhang, S. (2018).
"Cloud-Based Asset Management Systems: Benefits and
Challenges." Journal of Cloud Computing and Services Science,
6(2), 47-55.
Examines the benefits and challenges of cloud-based AMS
solutions, such as scalability, flexibility, and cost-effectiveness.
6. ISO (2014).
ISO 55000: Asset Management—Overview, Principles, and
Terminology. International Organization for Standardization.
The ISO 55000 standard outlines asset management principles and
practices, offering guidelines for implementing AMS.
7. O'Reilly, M. (2017).
"Asset Management in the Digital Age: Leveraging IoT and Real-
Time Data." Asset Management Journal, 10(1), 34-42.
Discusses the role of IoT devices and real-time data in enhancing
asset monitoring and maintenance through AMS.
8. Pereira, T., & Silva, F. (2018).
"Designing Scalable and Secure Asset Management Systems for
Enterprises." International Journal of Computer Science and
Engineering, 36(4), 155-163.
162 | P a g e
Provides insights on designing AMS that are both scalable and
secure, with a focus on data privacy and system performance.
163 | P a g e