一、项目介绍
基于SSM实现的固定资产管理系统,该固定资产管理系统共包含三种角色,分别是:管理员、普通员工、部门管理人员,其功能如下:
1.管理员
系统登陆、管理员管理、部门管理、资产类型管理、员工信息管理、采购申请管理、资产采购管理、资产发放管理、固定资产管理、设备维修管理、资产报废管理、设备借用归还管理、盘点信息管理、盘盈信息统计、盘亏信息统计等功能。
2.普通员工
个人信息管理、修改密码、资产类型信息、采购申请信息、资产接收信息、固定资产信息、设备借用归还信息、盘点信息等功能。
3.部门管理人员
工作人员管理、基础信息管理、采购申请管理、资产发放管理、固定资产管理、设备借用归还管理、盘点管理等功能。
二、项目技术
编程语言:Java
项目架构:B/S架构
数据库:MySQL
前端技术:JSP、jQuery 、ECharts
后端技术:Spring、SpringMVC、MyBatis
三、运行环境
JDK版本:1.8及以上都可以
数据库:MySQL
操作系统:Windows、MacOS
开发工具:IDEA、Ecplise都可以
数据库: MySQL5.5/5.7/8.0版本都可以
Tomcat:7.0及以上版本都可以
四、运行截图
五、主要功能代码实现
1. 资产登记
用户可以登记新资产,记录资产的基本信息,如名称、编号和购买日期。
代码:
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;
public class AssetRegistry {
private Map<String, Asset> assets = new HashMap<>();
public void registerAsset(String id, String name, String purchaseDate) {
if (assets.containsKey(id)) {
System.out.println("Asset already registered.");
} else {
assets.put(id, new Asset(id, name, purchaseDate));
System.out.println("Asset registered successfully.");
}
}
public void viewAsset(String id) {
Asset asset = assets.get(id);
if (asset != null) {
System.out.println("ID: " + asset.getId() + ", Name: " + asset.getName() + ", Purchase Date: " + asset.getPurchaseDate());
} else {
System.out.println("No asset found with the given ID.");
}
}
private class Asset {
private String id;
private String name;
private String purchaseDate;
public Asset(String id, String name, String purchaseDate) {
this.id = id;
this.name = name;
this.purchaseDate = purchaseDate;
}
public String getId() {
return id;
}
public String getName() {
return name;
}
public String getPurchaseDate() {
return purchaseDate;
}
}
public static void main(String[] args) {
AssetRegistry registry = new AssetRegistry();
Scanner scanner = new Scanner(System.in);
System.out.println("Register New Asset:");
System.out.print("ID: ");
String id = scanner.nextLine();
System.out.print("Name: ");
String name = scanner.nextLine();
System.out.print("Purchase Date: ");
String date = scanner.nextLine();
registry.registerAsset(id, name, date);
System.out.println("View Asset:");
System.out.print("ID: ");
String viewId = scanner.nextLine();
registry.viewAsset(viewId);
}
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
- 25.
- 26.
- 27.
- 28.
- 29.
- 30.
- 31.
- 32.
- 33.
- 34.
- 35.
- 36.
- 37.
- 38.
- 39.
- 40.
- 41.
- 42.
- 43.
- 44.
- 45.
- 46.
- 47.
- 48.
- 49.
- 50.
- 51.
- 52.
- 53.
- 54.
- 55.
- 56.
- 57.
- 58.
- 59.
- 60.
- 61.
- 62.
- 63.
- 64.
- 65.
- 66.
- 67.
- 68.
2. 资产维护
用户可以记录资产的维护情况,包括维护日期和描述。
代码:
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;
public class AssetMaintenance {
private Map<String, String> maintenanceRecords = new HashMap<>();
public void recordMaintenance(String assetId, String maintenanceDate, String description) {
String record = "Date: " + maintenanceDate + ", Description: " + description;
maintenanceRecords.put(assetId, record);
System.out.println("Maintenance record added.");
}
public void viewMaintenance(String assetId) {
String record = maintenanceRecords.get(assetId);
if (record != null) {
System.out.println("Maintenance Record: " + record);
} else {
System.out.println("No maintenance record found for the given asset ID.");
}
}
public static void main(String[] args) {
AssetMaintenance maintenance = new AssetMaintenance();
Scanner scanner = new Scanner(System.in);
System.out.println("Record Maintenance:");
System.out.print("Asset ID: ");
String assetId = scanner.nextLine();
System.out.print("Maintenance Date: ");
String date = scanner.nextLine();
System.out.print("Description: ");
String description = scanner.nextLine();
maintenance.recordMaintenance(assetId, date, description);
System.out.println("View Maintenance Record:");
System.out.print("Asset ID: ");
String viewId = scanner.nextLine();
maintenance.viewMaintenance(viewId);
}
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
- 25.
- 26.
- 27.
- 28.
- 29.
- 30.
- 31.
- 32.
- 33.
- 34.
- 35.
- 36.
- 37.
- 38.
- 39.
- 40.
- 41.
3. 资产转移
用户可以记录资产的转移情况,包括新位置和转移日期。
代码:
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;
public class AssetTransfer {
private Map<String, String> transferRecords = new HashMap<>();
public void recordTransfer(String assetId, String newLocation, String transferDate) {
String record = "New Location: " + newLocation + ", Transfer Date: " + transferDate;
transferRecords.put(assetId, record);
System.out.println("Transfer record added.");
}
public void viewTransfer(String assetId) {
String record = transferRecords.get(assetId);
if (record != null) {
System.out.println("Transfer Record: " + record);
} else {
System.out.println("No transfer record found for the given asset ID.");
}
}
public static void main(String[] args) {
AssetTransfer transfer = new AssetTransfer();
Scanner scanner = new Scanner(System.in);
System.out.println("Record Asset Transfer:");
System.out.print("Asset ID: ");
String assetId = scanner.nextLine();
System.out.print("New Location: ");
String location = scanner.nextLine();
System.out.print("Transfer Date: ");
String date = scanner.nextLine();
transfer.recordTransfer(assetId, location, date);
System.out.println("View Transfer Record:");
System.out.print("Asset ID: ");
String viewId = scanner.nextLine();
transfer.viewTransfer(viewId);
}
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
- 25.
- 26.
- 27.
- 28.
- 29.
- 30.
- 31.
- 32.
- 33.
- 34.
- 35.
- 36.
- 37.
- 38.
- 39.
- 40.
- 41.
4. 资产报废
用户可以记录资产的报废情况,包括报废日期和报废原因。
代码:
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;
public class AssetDisposal {
private Map<String, String> disposalRecords = new HashMap<>();
public void recordDisposal(String assetId, String disposalDate, String reason) {
String record = "Disposal Date: " + disposalDate + ", Reason: " + reason;
disposalRecords.put(assetId, record);
System.out.println("Disposal record added.");
}
public void viewDisposal(String assetId) {
String record = disposalRecords.get(assetId);
if (record != null) {
System.out.println("Disposal Record: " + record);
} else {
System.out.println("No disposal record found for the given asset ID.");
}
}
public static void main(String[] args) {
AssetDisposal disposal = new AssetDisposal();
Scanner scanner = new Scanner(System.in);
System.out.println("Record Asset Disposal:");
System.out.print("Asset ID: ");
String assetId = scanner.nextLine();
System.out.print("Disposal Date: ");
String date = scanner.nextLine();
System.out.print("Reason: ");
String reason = scanner.nextLine();
disposal.recordDisposal(assetId, date, reason);
System.out.println("View Disposal Record:");
System.out.print("Asset ID: ");
String viewId = scanner.nextLine();
disposal.viewDisposal(viewId);
}
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
- 25.
- 26.
- 27.
- 28.
- 29.
- 30.
- 31.
- 32.
- 33.
- 34.
- 35.
- 36.
- 37.
- 38.
- 39.
- 40.
- 41.