博主介紹:?從事軟件開發(fā)10年之余,專注于Java技術(shù)領(lǐng)域、Python人工智能及數(shù)據(jù)挖掘、小程序項(xiàng)目開發(fā)和Android項(xiàng)目開發(fā)等。CSDN、掘金、華為云、InfoQ、阿里云等平臺(tái)優(yōu)質(zhì)作者?
??文末獲取源碼聯(lián)系??
???? 精彩專欄推薦訂閱???? 不然下次找不到喲
————————————————
計(jì)算機(jī)畢業(yè)設(shè)計(jì)《1000套》?
目錄
1、項(xiàng)目介紹及開發(fā)技術(shù)
1.1 項(xiàng)目介紹
1.2 開發(fā)技術(shù)
2、系統(tǒng)功能設(shè)計(jì)結(jié)構(gòu)圖
3、功能截圖
4、數(shù)據(jù)庫(kù)表結(jié)構(gòu)設(shè)計(jì)
5、關(guān)鍵代碼
5.1 物資管理Controller模塊?
5.2 物資管理Service模塊?
5.3 物資管理ServiceImpl模塊
5.4 物資管理Dao模塊
6、論文目錄結(jié)構(gòu)
7、源碼獲取
1、項(xiàng)目介紹及開發(fā)技術(shù)
1.1 項(xiàng)目介紹
如今社會(huì)上各行各業(yè),都喜歡用自己行業(yè)的專屬軟件工作,互聯(lián)網(wǎng)發(fā)展到這個(gè)時(shí)候,人們已經(jīng)發(fā)現(xiàn)離不開了互聯(lián)網(wǎng)。新技術(shù)的產(chǎn)生,往往能解決一些老技術(shù)的弊端問題。因?yàn)閭鹘y(tǒng)物資綜合管理系統(tǒng)信息管理難度大,容錯(cuò)率低,管理人員處理數(shù)據(jù)費(fèi)工費(fèi)時(shí),所以專門為解決這個(gè)難題開發(fā)了一個(gè)物資綜合管理系統(tǒng)管理系統(tǒng),可以解決許多問題。物資綜合管理系統(tǒng)管理系統(tǒng)可以提高物資綜合管理系統(tǒng)信息管理問題的解決效率,優(yōu)化物資綜合管理系統(tǒng)信息處理流程,保證物資綜合管理系統(tǒng)信息數(shù)據(jù)的安全,它是一個(gè)非常可靠,非常安全的應(yīng)用程序。
1.2 開發(fā)技術(shù)
Java開發(fā)語(yǔ)言、SpringBoot、MyBatisPlus、MySQL數(shù)據(jù)庫(kù)、Maven、IDEA開發(fā)工具、JDK1.8+、Vue、HTML、CSS、JS。
2、系統(tǒng)功能設(shè)計(jì)結(jié)構(gòu)圖
3、功能截圖
物資管理:管理員在物資管理界面中可以對(duì)界面中顯示,可以對(duì)物資信息的物資狀態(tài)進(jìn)行查看,可以添加新的物資信息等。
物資申報(bào)管理:?管理員在物資申報(bào)管理界面中查看物資申報(bào)種類信息,物資申報(bào)描述信息,新增物資申報(bào)信息等。
?公告管理:管理員在公告管理界面中新增公告,可以刪除公告。
公告類型管理:?管理員在公告類型管理界面查看公告的工作狀態(tài),可以對(duì)公告的數(shù)據(jù)進(jìn)行導(dǎo)出,可以添加新公告的信息,可以編輯公告信息,刪除公告信息。
4、數(shù)據(jù)庫(kù)表結(jié)構(gòu)設(shè)計(jì)
CREATE DATABASE /*!32312 IF NOT EXISTS*/`wuzizongheguanlixitong` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `wuzizongheguanlixitong`;
/*Table structure for table `caozuorizhi` */
DROP TABLE IF EXISTS `caozuorizhi`;
CREATE TABLE `caozuorizhi` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵 ',
`caozuorizhi_this_biao` varchar(200) DEFAULT NULL COMMENT '操作人所在表 Search111 ',
`caozuorizhi_caozuobiao` varchar(200) DEFAULT NULL COMMENT '操作表 Search111 ',
`caozuorizhi_caozuozhanghu` varchar(200) DEFAULT NULL COMMENT '操作賬戶 Search111 ',
`caozuorizhi_caozuoleixing` varchar(200) DEFAULT NULL COMMENT '操作類型 Search111 ',
`caozuorizhi_text` mediumtext COMMENT '操作內(nèi)容 Search111 ',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '操作時(shí)間 Search111 ',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4530 DEFAULT CHARSET=utf8 COMMENT='操作日志';
/*Data for the table `caozuorizhi` */
/*Table structure for table `config` */
DROP TABLE IF EXISTS `config`;
CREATE TABLE `config` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`name` varchar(100) NOT NULL COMMENT '配置參數(shù)名稱',
`value` varchar(100) DEFAULT NULL COMMENT '配置參數(shù)值',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='配置文件';
/*Data for the table `config` */
/*Table structure for table `dictionary` */
DROP TABLE IF EXISTS `dictionary`;
CREATE TABLE `dictionary` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`dic_code` varchar(200) DEFAULT NULL COMMENT '字段',
`dic_name` varchar(200) DEFAULT NULL COMMENT '字段名',
`code_index` int(11) DEFAULT NULL COMMENT '編碼',
`index_name` varchar(200) DEFAULT NULL COMMENT '編碼名字 Search111 ',
`super_id` int(11) DEFAULT NULL COMMENT '父字段id',
`beizhu` varchar(200) DEFAULT NULL COMMENT '備注',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=16 DEFAULT CHARSET=utf8 COMMENT='字典';
/*Data for the table `dictionary` */
insert into `dictionary`(`id`,`dic_code`,`dic_name`,`code_index`,`index_name`,`super_id`,`beizhu`,`create_time`) values (1,'sex_types','性別類型',1,'男',NULL,NULL,'2023-04-10 09:38:14'),(2,'sex_types','性別類型',2,'女',NULL,NULL,'2023-04-10 09:38:14'),(3,'gonggao_types','公告類型',1,'公告類型1',NULL,NULL,'2023-04-10 09:38:14'),(4,'gonggao_types','公告類型',2,'公告類型2',NULL,NULL,'2023-04-10 09:38:14'),(5,'wuzi_types','物資類型',1,'物資類型1',NULL,NULL,'2023-04-10 09:38:14'),(6,'wuzi_types','物資類型',2,'物資類型2',NULL,NULL,'2023-04-10 09:38:14'),(7,'wuzi_types','物資類型',3,'物資類型3',NULL,NULL,'2023-04-10 09:38:14'),(8,'wuzi_types','物資類型',4,'物資類型4',NULL,NULL,'2023-04-10 09:38:14'),(9,'wuzi_churu_inout_types','出入庫(kù)類型',1,'出庫(kù)',NULL,NULL,'2023-04-10 09:38:14'),(10,'wuzi_churu_inout_types','出入庫(kù)類型',2,'入庫(kù)',NULL,NULL,'2023-04-10 09:38:14'),(11,'wuzi_yuyue_yesno_types','報(bào)名狀態(tài)',1,'待審核',NULL,NULL,'2023-04-10 09:38:14'),(12,'wuzi_yuyue_yesno_types','報(bào)名狀態(tài)',2,'同意',NULL,NULL,'2023-04-10 09:38:14'),(13,'wuzi_yuyue_yesno_types','報(bào)名狀態(tài)',3,'拒絕',NULL,NULL,'2023-04-10 09:38:14'),(14,'yuedu_types','月度用料類型',1,'已使用',NULL,NULL,'2023-04-10 09:38:14'),(15,'yuedu_types','月度用料類型',2,'未使用',NULL,NULL,'2023-04-10 09:38:14');
/*Table structure for table `gonggao` */
DROP TABLE IF EXISTS `gonggao`;
CREATE TABLE `gonggao` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵 ',
`gonggao_name` varchar(200) DEFAULT NULL COMMENT '公告名稱 Search111 ',
`gonggao_photo` varchar(200) DEFAULT NULL COMMENT '公告圖片 ',
`gonggao_types` int(11) NOT NULL COMMENT '公告類型 Search111 ',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '發(fā)布時(shí)間',
`gonggao_content` longtext COMMENT '公告詳情 ',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間 show1 show2 nameShow',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=15 DEFAULT CHARSET=utf8 COMMENT='公告';
/*Data for the table `gonggao` */
insert into `gonggao`(`id`,`gonggao_name`,`gonggao_photo`,`gonggao_types`,`insert_time`,`gonggao_content`,`create_time`) values (1,'公告名稱1','upload/gonggao1.jpg',2,'2023-04-10 09:38:25','公告詳情1','2023-04-10 09:38:25'),(2,'公告名稱2','upload/gonggao2.jpg',1,'2023-04-10 09:38:25','公告詳情2','2023-04-10 09:38:25'),(3,'公告名稱3','upload/gonggao3.jpg',2,'2023-04-10 09:38:25','公告詳情3','2023-04-10 09:38:25'),(4,'公告名稱4','upload/gonggao4.jpg',2,'2023-04-10 09:38:25','公告詳情4','2023-04-10 09:38:25'),(5,'公告名稱5','upload/gonggao5.jpg',2,'2023-04-10 09:38:25','公告詳情5','2023-04-10 09:38:25'),(6,'公告名稱6','upload/gonggao6.jpg',1,'2023-04-10 09:38:25','公告詳情6','2023-04-10 09:38:25'),(7,'公告名稱7','upload/gonggao7.jpg',1,'2023-04-10 09:38:25','公告詳情7','2023-04-10 09:38:25'),(8,'公告名稱8','upload/gonggao8.jpg',1,'2023-04-10 09:38:25','公告詳情8','2023-04-10 09:38:25'),(9,'公告名稱9','upload/gonggao9.jpg',2,'2023-04-10 09:38:25','公告詳情9','2023-04-10 09:38:25'),(10,'公告名稱10','upload/gonggao10.jpg',2,'2023-04-10 09:38:25','公告詳情10','2023-04-10 09:38:25'),(11,'公告名稱11','upload/gonggao11.jpg',1,'2023-04-10 09:38:25','公告詳情11','2023-04-10 09:38:25'),(12,'公告名稱12','upload/gonggao12.jpg',2,'2023-04-10 09:38:25','公告詳情12','2023-04-10 09:38:25'),(13,'公告名稱13','upload/gonggao13.jpg',1,'2023-04-10 09:38:25','公告詳情13','2023-04-10 09:38:25'),(14,'公告名稱14','upload/gonggao14.jpg',2,'2023-04-10 09:38:25','公告詳情14','2023-04-10 09:38:25');
/*Table structure for table `token` */
DROP TABLE IF EXISTS `token`;
CREATE TABLE `token` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`userid` bigint(20) NOT NULL COMMENT '兒童id',
`username` varchar(100) NOT NULL COMMENT '兒童名',
`tablename` varchar(100) DEFAULT NULL COMMENT '表名',
`role` varchar(100) DEFAULT NULL COMMENT '角色',
`token` varchar(200) NOT NULL COMMENT '密碼',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '新增時(shí)間',
`expiratedtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '過期時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='token表';
/*Data for the table `token` */
insert into `token`(`id`,`userid`,`username`,`tablename`,`role`,`token`,`addtime`,`expiratedtime`) values (1,1,'admin','users','管理員','4duqvmxvvw3nikn1xr6ohahnjs512vmm','2023-04-10 09:47:09','2023-04-10 11:30:14'),(2,1,'a1','yonghu','用戶','fum7awtiulay4sszkgoqail9d7lyi5bm','2023-04-10 09:47:24','2023-04-10 11:25:34');
/*Table structure for table `users` */
DROP TABLE IF EXISTS `users`;
CREATE TABLE `users` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`username` varchar(100) NOT NULL COMMENT '兒童名',
`password` varchar(100) NOT NULL COMMENT '密碼',
`role` varchar(100) DEFAULT '管理員' COMMENT '角色',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '新增時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COMMENT='管理員';
/*Data for the table `users` */
insert into `users`(`id`,`username`,`password`,`role`,`addtime`) values (1,'admin','admin','管理員','2023-04-10 09:38:14');
/*Table structure for table `wuzi` */
DROP TABLE IF EXISTS `wuzi`;
CREATE TABLE `wuzi` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵 ',
`wuzi_name` varchar(200) DEFAULT NULL COMMENT '物資名稱 Search111 ',
`wuzi_uuid_number` varchar(200) DEFAULT NULL COMMENT '物資編號(hào)',
`wuzi_photo` varchar(200) DEFAULT NULL COMMENT '物資照片',
`wuzi_types` int(11) DEFAULT NULL COMMENT '物資類型 Search111',
`wuzi_kucun_number` int(11) DEFAULT NULL COMMENT '物資庫(kù)存',
`wuzi_content` longtext COMMENT '物資介紹 ',
`wuzi_delete` int(11) DEFAULT NULL COMMENT '邏輯刪除',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '錄入時(shí)間',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間 show1 show2 photoShow',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=15 DEFAULT CHARSET=utf8 COMMENT='物資';
/*Data for the table `wuzi` */
insert into `wuzi`(`id`,`wuzi_name`,`wuzi_uuid_number`,`wuzi_photo`,`wuzi_types`,`wuzi_kucun_number`,`wuzi_content`,`wuzi_delete`,`insert_time`,`create_time`) values (1,'物資名稱1','1681090705272','upload/wuzi1.jpg',3,101,'物資介紹1',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(2,'物資名稱2','1681090705328','upload/wuzi2.jpg',4,102,'物資介紹2',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(3,'物資名稱3','1681090705363','upload/wuzi3.jpg',3,103,'物資介紹3',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(4,'物資名稱4','1681090705295','upload/wuzi4.jpg',4,104,'物資介紹4',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(5,'物資名稱5','1681090705284','upload/wuzi5.jpg',2,105,'物資介紹5',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(6,'物資名稱6','1681090705359','upload/wuzi6.jpg',1,106,'物資介紹6',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(7,'物資名稱7','1681090705356','upload/wuzi7.jpg',3,107,'物資介紹7',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(8,'物資名稱8','1681090705323','upload/wuzi8.jpg',1,108,'物資介紹8',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(9,'物資名稱9','1681090705279','upload/wuzi9.jpg',4,109,'物資介紹9',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(10,'物資名稱10','1681090705304','upload/wuzi10.jpg',4,1010,'物資介紹10',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(11,'物資名稱11','1681090705351','upload/wuzi11.jpg',4,1011,'物資介紹11',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(12,'物資名稱12','1681090705343','upload/wuzi12.jpg',4,1012,'物資介紹12',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(13,'物資名稱13','1681090705349','upload/wuzi13.jpg',4,1113,'物資介紹13',1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(14,'物資名稱14','1681090705283','upload/wuzi14.jpg',3,964,'物資介紹14',1,'2023-04-10 09:38:25','2023-04-10 09:38:25');
/*Table structure for table `wuzi_churu_inout` */
DROP TABLE IF EXISTS `wuzi_churu_inout`;
CREATE TABLE `wuzi_churu_inout` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`wuzi_churu_inout_uuid_number` varchar(200) DEFAULT NULL COMMENT '出入庫(kù)流水號(hào)',
`wuzi_churu_inout_name` varchar(200) DEFAULT NULL COMMENT '出入庫(kù)名稱 Search111 ',
`wuzi_churu_inout_types` int(11) DEFAULT NULL COMMENT '出入庫(kù)類型 Search111 ',
`wuzi_churu_inout_content` longtext COMMENT '備注',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '添加時(shí)間',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=17 DEFAULT CHARSET=utf8 COMMENT='出入庫(kù)';
/*Data for the table `wuzi_churu_inout` */
insert into `wuzi_churu_inout`(`id`,`wuzi_churu_inout_uuid_number`,`wuzi_churu_inout_name`,`wuzi_churu_inout_types`,`wuzi_churu_inout_content`,`insert_time`,`create_time`) values (1,'1681090705286','出入庫(kù)名稱1',2,'備注1','2023-04-10 09:38:25','2023-04-10 09:38:25'),(2,'1681090705311','出入庫(kù)名稱2',1,'備注2','2023-04-10 09:38:25','2023-04-10 09:38:25'),(3,'1681090705272','出入庫(kù)名稱3',2,'備注3','2023-04-10 09:38:25','2023-04-10 09:38:25'),(4,'1681090705317','出入庫(kù)名稱4',1,'備注4','2023-04-10 09:38:25','2023-04-10 09:38:25'),(5,'1681090705358','出入庫(kù)名稱5',1,'備注5','2023-04-10 09:38:25','2023-04-10 09:38:25'),(6,'1681090705359','出入庫(kù)名稱6',1,'備注6','2023-04-10 09:38:25','2023-04-10 09:38:25'),(7,'1681090705348','出入庫(kù)名稱7',1,'備注7','2023-04-10 09:38:25','2023-04-10 09:38:25'),(8,'1681090705303','出入庫(kù)名稱8',2,'備注8','2023-04-10 09:38:25','2023-04-10 09:38:25'),(9,'1681090705361','出入庫(kù)名稱9',2,'備注9','2023-04-10 09:38:25','2023-04-10 09:38:25'),(10,'1681090705346','出入庫(kù)名稱10',2,'備注10','2023-04-10 09:38:25','2023-04-10 09:38:25'),(11,'1681090705272','出入庫(kù)名稱11',1,'備注11','2023-04-10 09:38:25','2023-04-10 09:38:25'),(12,'1681090705359','出入庫(kù)名稱12',2,'備注12','2023-04-10 09:38:25','2023-04-10 09:38:25'),(13,'1681090705336','出入庫(kù)名稱13',1,'備注13','2023-04-10 09:38:25','2023-04-10 09:38:25'),(14,'1681090705341','出入庫(kù)名稱14',1,'備注14','2023-04-10 09:38:25','2023-04-10 09:38:25'),(15,'1681093550841','111',2,'','2023-04-10 10:25:51','2023-04-10 10:25:51'),(16,'1681093562375','2222',1,'','2023-04-10 10:26:02','2023-04-10 10:26:02');
/*Table structure for table `wuzi_churu_inout_list` */
DROP TABLE IF EXISTS `wuzi_churu_inout_list`;
CREATE TABLE `wuzi_churu_inout_list` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`wuzi_churu_inout_id` int(11) DEFAULT NULL COMMENT '出入庫(kù)',
`wuzi_id` int(11) DEFAULT NULL COMMENT '物資',
`wuzi_churu_inout_list_number` int(11) DEFAULT NULL COMMENT '操作數(shù)量',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '操作時(shí)間',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=17 DEFAULT CHARSET=utf8 COMMENT='出入庫(kù)詳情';
/*Data for the table `wuzi_churu_inout_list` */
insert into `wuzi_churu_inout_list`(`id`,`wuzi_churu_inout_id`,`wuzi_id`,`wuzi_churu_inout_list_number`,`insert_time`,`create_time`) values (1,1,1,230,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(2,2,2,357,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(3,3,3,495,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(4,4,4,313,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(5,5,5,294,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(6,6,6,192,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(7,7,7,452,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(8,8,8,227,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(9,9,9,243,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(10,10,10,71,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(11,11,11,291,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(12,12,12,12,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(13,13,13,374,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(14,14,14,191,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(15,15,13,100,'2023-04-10 10:25:51','2023-04-10 10:25:51'),(16,16,14,50,'2023-04-10 10:26:02','2023-04-10 10:26:02');
/*Table structure for table `wuzi_yuyue` */
DROP TABLE IF EXISTS `wuzi_yuyue`;
CREATE TABLE `wuzi_yuyue` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`wuzi_yuyue_uuid_number` varchar(200) DEFAULT NULL COMMENT '報(bào)名編號(hào) Search111 ',
`wuzi_id` int(11) DEFAULT NULL COMMENT '物資',
`yonghu_id` int(11) DEFAULT NULL COMMENT '用戶',
`wuzi_yuyue_text` longtext COMMENT '申報(bào)理由',
`wuzi_yuyue_yesno_types` int(11) DEFAULT NULL COMMENT '報(bào)名狀態(tài) Search111 ',
`wuzi_yuyue_yesno_text` longtext COMMENT '審核回復(fù)',
`wuzi_yuyue_shenhe_time` timestamp NULL DEFAULT NULL COMMENT '審核時(shí)間',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '物資申報(bào)時(shí)間',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間 show3 listShow',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=18 DEFAULT CHARSET=utf8 COMMENT='物資申報(bào)';
/*Data for the table `wuzi_yuyue` */
insert into `wuzi_yuyue`(`id`,`wuzi_yuyue_uuid_number`,`wuzi_id`,`yonghu_id`,`wuzi_yuyue_text`,`wuzi_yuyue_yesno_types`,`wuzi_yuyue_yesno_text`,`wuzi_yuyue_shenhe_time`,`insert_time`,`create_time`) values (1,'1681090705289',1,1,'申報(bào)理由1',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(2,'1681090705282',2,2,'申報(bào)理由2',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(3,'1681090705337',3,1,'申報(bào)理由3',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(4,'1681090705358',4,2,'申報(bào)理由4',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(5,'1681090705375',5,3,'申報(bào)理由5',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(6,'1681090705376',6,3,'申報(bào)理由6',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(7,'1681090705281',7,1,'申報(bào)理由7',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(8,'1681090705367',8,3,'申報(bào)理由8',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(9,'1681090705279',9,1,'申報(bào)理由9',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(10,'1681090705345',10,3,'申報(bào)理由10',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(11,'1681090705282',11,3,'申報(bào)理由11',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(12,'1681090705353',12,1,'申報(bào)理由12',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(13,'1681090705343',13,3,'申報(bào)理由13',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(14,'1681090705320',14,2,'申報(bào)理由14',1,NULL,NULL,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(15,'1681093380940',1,1,'手打',1,'',NULL,'2023-04-10 10:23:05','2023-04-10 10:23:05'),(16,'1681093441892',14,1,'出庫(kù)50個(gè)',2,'同意','2023-04-10 10:25:13','2023-04-10 10:24:11','2023-04-10 10:24:11'),(17,'1681093455004',13,1,'入庫(kù)100',2,'同意','2023-04-10 10:25:05','2023-04-10 10:24:22','2023-04-10 10:24:22');
/*Table structure for table `yonghu` */
DROP TABLE IF EXISTS `yonghu`;
CREATE TABLE `yonghu` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵',
`username` varchar(200) DEFAULT NULL COMMENT '賬戶',
`password` varchar(200) DEFAULT NULL COMMENT '密碼',
`yonghu_name` varchar(200) DEFAULT NULL COMMENT '用戶姓名 Search111 ',
`yonghu_phone` varchar(200) DEFAULT NULL COMMENT '用戶手機(jī)號(hào)',
`yonghu_id_number` varchar(200) DEFAULT NULL COMMENT '用戶身份證號(hào)',
`yonghu_photo` varchar(200) DEFAULT NULL COMMENT '用戶頭像',
`sex_types` int(11) DEFAULT NULL COMMENT '性別',
`yonghu_email` varchar(200) DEFAULT NULL COMMENT '用戶郵箱',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COMMENT='用戶';
/*Data for the table `yonghu` */
insert into `yonghu`(`id`,`username`,`password`,`yonghu_name`,`yonghu_phone`,`yonghu_id_number`,`yonghu_photo`,`sex_types`,`yonghu_email`,`create_time`) values (1,'a1','123456','用戶姓名1','17703786901','410224199010102001','upload/yonghu1.jpg',2,'1@qq.com','2023-04-10 09:38:25'),(2,'a2','123456','用戶姓名2','17703786902','410224199010102002','upload/yonghu2.jpg',1,'2@qq.com','2023-04-10 09:38:25'),(3,'a3','123456','用戶姓名3','17703786903','410224199010102003','upload/yonghu3.jpg',2,'3@qq.com','2023-04-10 09:38:25');
/*Table structure for table `yuedu` */
DROP TABLE IF EXISTS `yuedu`;
CREATE TABLE `yuedu` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '主鍵 ',
`wuzi_id` int(11) DEFAULT NULL COMMENT '物資',
`yuedu_shuliang` int(11) DEFAULT NULL COMMENT '月度用料數(shù)量',
`yuedu_content` longtext COMMENT '月度用料介紹 ',
`yuedu_delete` int(11) DEFAULT NULL COMMENT '邏輯刪除',
`yuedu_types` int(11) DEFAULT NULL COMMENT '月度用料類型 Search111 ',
`insert_time` timestamp NULL DEFAULT NULL COMMENT '錄入時(shí)間',
`create_time` timestamp NULL DEFAULT NULL COMMENT '創(chuàng)建時(shí)間 show1 show2 photoShow',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=15 DEFAULT CHARSET=utf8 COMMENT='月度用料';
/*Data for the table `yuedu` */
insert into `yuedu`(`id`,`wuzi_id`,`yuedu_shuliang`,`yuedu_content`,`yuedu_delete`,`yuedu_types`,`insert_time`,`create_time`) values (1,1,413,'月度用料介紹1',1,1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(2,2,30,'月度用料介紹2',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(3,3,387,'月度用料介紹3',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(4,4,213,'月度用料介紹4',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(5,5,354,'月度用料介紹5',1,1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(6,6,102,'月度用料介紹6',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(7,7,138,'月度用料介紹7',1,1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(8,8,254,'月度用料介紹8',1,1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(9,9,28,'月度用料介紹9',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(10,10,317,'月度用料介紹10',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(11,11,345,'月度用料介紹11',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(12,12,149,'月度用料介紹12',1,2,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(13,13,345,'月度用料介紹13',1,1,'2023-04-10 09:38:25','2023-04-10 09:38:25'),(14,14,161,'月度用料介紹14',1,1,'2023-04-10 09:38:25','2023-04-10 09:38:25');
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
5、關(guān)鍵代碼
5.1 物資管理Controller模塊?
/**
* 物資
* 后端接口
* @author 學(xué)長(zhǎng)編程
* @email
* WeChat jsjbysj88
*/
@RestController
@Controller
@RequestMapping("/wuzi")
public class WuziController {
private static final Logger logger = LoggerFactory.getLogger(WuziController.class);
private static final String TABLE_NAME = "wuzi";
@Autowired
private WuziService wuziService;
@Autowired
private TokenService tokenService;
@Autowired
private CaozuorizhiService caozuorizhiService;//操作日志
@Autowired
private DictionaryService dictionaryService;//字典
@Autowired
private GonggaoService gonggaoService;//公告
@Autowired
private WuziChuruInoutService wuziChuruInoutService;//出入庫(kù)
@Autowired
private WuziChuruInoutListService wuziChuruInoutListService;//出入庫(kù)詳情
@Autowired
private WuziYuyueService wuziYuyueService;//物資申報(bào)
@Autowired
private YonghuService yonghuService;//用戶
@Autowired
private YueduService yueduService;//月度用料
@Autowired
private UsersService usersService;//管理員
/**
* 后端列表
*/
@RequestMapping("/page")
public R page(@RequestParam Map<String, Object> params, HttpServletRequest request){
logger.debug("page方法:,,Controller:{},,params:{}",this.getClass().getName(),JSONObject.toJSONString(params));
String role = String.valueOf(request.getSession().getAttribute("role"));
if(false)
return R.error(511,"永不會(huì)進(jìn)入");
else if("用戶".equals(role))
params.put("yonghuId",request.getSession().getAttribute("userId"));
params.put("wuziDeleteStart",1);params.put("wuziDeleteEnd",1);
CommonUtil.checkMap(params);
PageUtils page = wuziService.queryPage(params);
//字典表數(shù)據(jù)轉(zhuǎn)換
List<WuziView> list =(List<WuziView>)page.getList();
for(WuziView c:list){
//修改對(duì)應(yīng)字典表字段
dictionaryService.dictionaryConvert(c, request);
}
caozuorizhiService.insertCaozuorizhi(String.valueOf(request.getSession().getAttribute("role")),TABLE_NAME,String.valueOf(request.getSession().getAttribute("username")),"列表查詢",list.toString());
return R.ok().put("data", page);
}
/**
* 后端詳情
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") Long id, HttpServletRequest request){
logger.debug("info方法:,,Controller:{},,id:{}",this.getClass().getName(),id);
WuziEntity wuzi = wuziService.selectById(id);
if(wuzi !=null){
//entity轉(zhuǎn)view
WuziView view = new WuziView();
BeanUtils.copyProperties( wuzi , view );//把實(shí)體數(shù)據(jù)重構(gòu)到view中
//修改對(duì)應(yīng)字典表字段
dictionaryService.dictionaryConvert(view, request);
caozuorizhiService.insertCaozuorizhi(String.valueOf(request.getSession().getAttribute("role")),TABLE_NAME,String.valueOf(request.getSession().getAttribute("username")),"單條數(shù)據(jù)查看",view.toString());
return R.ok().put("data", view);
}else {
return R.error(511,"查不到數(shù)據(jù)");
}
}
/**
* 后端保存
*/
@RequestMapping("/save")
public R save(@RequestBody WuziEntity wuzi, HttpServletRequest request){
logger.debug("save方法:,,Controller:{},,wuzi:{}",this.getClass().getName(),wuzi.toString());
String role = String.valueOf(request.getSession().getAttribute("role"));
if(false)
return R.error(511,"永遠(yuǎn)不會(huì)進(jìn)入");
Wrapper<WuziEntity> queryWrapper = new EntityWrapper<WuziEntity>()
.eq("wuzi_name", wuzi.getWuziName())
.eq("wuzi_types", wuzi.getWuziTypes())
.eq("wuzi_kucun_number", wuzi.getWuziKucunNumber())
.eq("wuzi_delete", 1)
;
logger.info("sql語(yǔ)句:"+queryWrapper.getSqlSegment());
WuziEntity wuziEntity = wuziService.selectOne(queryWrapper);
if(wuziEntity==null){
wuzi.setWuziDelete(1);
wuzi.setInsertTime(new Date());
wuzi.setCreateTime(new Date());
wuziService.insert(wuzi);
caozuorizhiService.insertCaozuorizhi(String.valueOf(request.getSession().getAttribute("role")),TABLE_NAME,String.valueOf(request.getSession().getAttribute("username")),"新增",wuzi.toString());
return R.ok();
}else {
return R.error(511,"表中有相同數(shù)據(jù)");
}
}
/**
* 后端修改
*/
@RequestMapping("/update")
public R update(@RequestBody WuziEntity wuzi, HttpServletRequest request) throws NoSuchFieldException, ClassNotFoundException, IllegalAccessException, InstantiationException {
logger.debug("update方法:,,Controller:{},,wuzi:{}",this.getClass().getName(),wuzi.toString());
WuziEntity oldWuziEntity = wuziService.selectById(wuzi.getId());//查詢?cè)葦?shù)據(jù)
String role = String.valueOf(request.getSession().getAttribute("role"));
// if(false)
// return R.error(511,"永遠(yuǎn)不會(huì)進(jìn)入");
if("".equals(wuzi.getWuziPhoto()) || "null".equals(wuzi.getWuziPhoto())){
wuzi.setWuziPhoto(null);
}
wuziService.updateById(wuzi);//根據(jù)id更新
List<String> strings = caozuorizhiService.clazzDiff(wuzi, oldWuziEntity, request,new String[]{"updateTime"});
caozuorizhiService.insertCaozuorizhi(String.valueOf(request.getSession().getAttribute("role")),TABLE_NAME,String.valueOf(request.getSession().getAttribute("username")),"修改",strings.toString());
return R.ok();
}
/**
* 刪除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Integer[] ids, HttpServletRequest request){
logger.debug("delete:,,Controller:{},,ids:{}",this.getClass().getName(),ids.toString());
List<WuziEntity> oldWuziList =wuziService.selectBatchIds(Arrays.asList(ids));//要?jiǎng)h除的數(shù)據(jù)
ArrayList<WuziEntity> list = new ArrayList<>();
for(Integer id:ids){
WuziEntity wuziEntity = new WuziEntity();
wuziEntity.setId(id);
wuziEntity.setWuziDelete(2);
list.add(wuziEntity);
}
if(list != null && list.size() >0){
wuziService.updateBatchById(list);
}
caozuorizhiService.insertCaozuorizhi(String.valueOf(request.getSession().getAttribute("role")),TABLE_NAME,String.valueOf(request.getSession().getAttribute("username")),"刪除",oldWuziList.toString());
return R.ok();
}
/**
* 批量上傳
*/
@RequestMapping("/batchInsert")
public R save( String fileName, HttpServletRequest request){
logger.debug("batchInsert方法:,,Controller:{},,fileName:{}",this.getClass().getName(),fileName);
Integer yonghuId = Integer.valueOf(String.valueOf(request.getSession().getAttribute("userId")));
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
//.eq("time", new SimpleDateFormat("yyyy-MM-dd").format(new Date()))
try {
List<WuziEntity> wuziList = new ArrayList<>();//上傳的東西
Map<String, List<String>> seachFields= new HashMap<>();//要查詢的字段
Date date = new Date();
int lastIndexOf = fileName.lastIndexOf(".");
if(lastIndexOf == -1){
return R.error(511,"該文件沒有后綴");
}else{
String suffix = fileName.substring(lastIndexOf);
if(!".xls".equals(suffix)){
return R.error(511,"只支持后綴為xls的excel文件");
}else{
URL resource = this.getClass().getClassLoader().getResource("static/upload/" + fileName);//獲取文件路徑
File file = new File(resource.getFile());
if(!file.exists()){
return R.error(511,"找不到上傳文件,請(qǐng)聯(lián)系管理員");
}else{
List<List<String>> dataList = PoiUtil.poiImport(file.getPath());//讀取xls文件
dataList.remove(0);//刪除第一行,因?yàn)榈谝恍惺翘崾? for(List<String> data:dataList){
//循環(huán)
WuziEntity wuziEntity = new WuziEntity();
// wuziEntity.setWuziName(data.get(0)); //物資名稱 要改的
// wuziEntity.setWuziUuidNumber(data.get(0)); //物資編號(hào) 要改的
// wuziEntity.setWuziPhoto("");//詳情和圖片
// wuziEntity.setWuziTypes(Integer.valueOf(data.get(0))); //物資類型 要改的
// wuziEntity.setWuziKucunNumber(Integer.valueOf(data.get(0))); //物資庫(kù)存 要改的
// wuziEntity.setWuziContent("");//詳情和圖片
// wuziEntity.setWuziDelete(1);//邏輯刪除字段
// wuziEntity.setInsertTime(date);//時(shí)間
// wuziEntity.setCreateTime(date);//時(shí)間
wuziList.add(wuziEntity);
//把要查詢是否重復(fù)的字段放入map中
//物資編號(hào)
if(seachFields.containsKey("wuziUuidNumber")){
List<String> wuziUuidNumber = seachFields.get("wuziUuidNumber");
wuziUuidNumber.add(data.get(0));//要改的
}else{
List<String> wuziUuidNumber = new ArrayList<>();
wuziUuidNumber.add(data.get(0));//要改的
seachFields.put("wuziUuidNumber",wuziUuidNumber);
}
}
//查詢是否重復(fù)
//物資編號(hào)
List<WuziEntity> wuziEntities_wuziUuidNumber = wuziService.selectList(new EntityWrapper<WuziEntity>().in("wuzi_uuid_number", seachFields.get("wuziUuidNumber")).eq("wuzi_delete", 1));
if(wuziEntities_wuziUuidNumber.size() >0 ){
ArrayList<String> repeatFields = new ArrayList<>();
for(WuziEntity s:wuziEntities_wuziUuidNumber){
repeatFields.add(s.getWuziUuidNumber());
}
return R.error(511,"數(shù)據(jù)庫(kù)的該表中的 [物資編號(hào)] 字段已經(jīng)存在 存在數(shù)據(jù)為:"+repeatFields.toString());
}
wuziService.insertBatch(wuziList);
caozuorizhiService.insertCaozuorizhi(String.valueOf(request.getSession().getAttribute("role")),TABLE_NAME,String.valueOf(request.getSession().getAttribute("username")),"批量新增",wuziList.toString());
return R.ok();
}
}
}
}catch (Exception e){
e.printStackTrace();
return R.error(511,"批量插入數(shù)據(jù)異常,請(qǐng)聯(lián)系管理員");
}
}
}
5.2 物資管理Service模塊?
package com.service;
import com.baomidou.mybatisplus.service.IService;
import com.utils.PageUtils;
import com.entity.WuziEntity;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import org.springframework.lang.Nullable;
import java.util.List;
/**
* 物資 服務(wù)類
*/
public interface WuziService extends IService<WuziEntity> {
/**
* @param params 查詢參數(shù)
* @return 帶分頁(yè)的查詢出來的數(shù)據(jù)
*/
PageUtils queryPage(Map<String, Object> params);
}
5.3 物資管理ServiceImpl模塊
package com.service.impl;
import com.utils.StringUtil;
import com.service.DictionaryService;
import com.utils.ClazzDiff;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.lang.reflect.Field;
import java.util.*;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.transaction.annotation.Transactional;
import com.utils.PageUtils;
import com.utils.Query;
import org.springframework.web.context.ContextLoader;
import javax.servlet.ServletContext;
import javax.servlet.http.HttpServletRequest;
import org.springframework.lang.Nullable;
import org.springframework.util.Assert;
import com.dao.WuziDao;
import com.entity.WuziEntity;
import com.service.WuziService;
import com.entity.view.WuziView;
/**
* 物資 服務(wù)實(shí)現(xiàn)類
*/
@Service("wuziService")
@Transactional
public class WuziServiceImpl extends ServiceImpl<WuziDao, WuziEntity> implements WuziService {
@Override
public PageUtils queryPage(Map<String,Object> params) {
Page<WuziView> page =new Query<WuziView>(params).getPage();
page.setRecords(baseMapper.selectListView(page,params));
return new PageUtils(page);
}
}
5.4 物資管理Dao模塊
package com.dao;
import com.entity.WuziEntity;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import java.util.List;
import java.util.Map;
import com.baomidou.mybatisplus.plugins.pagination.Pagination;
import org.apache.ibatis.annotations.Param;
import com.entity.view.WuziView;
/**
* 物資 Dao 接口
*
* @author 學(xué)長(zhǎng)編程
*WeChat jsjbysj88
*/
public interface WuziDao extends BaseMapper<WuziEntity> {
List<WuziView> selectListView(Pagination page,@Param("params")Map<String,Object> params);
}
6、論文目錄結(jié)構(gòu)
7、源碼獲取
感謝大家的閱讀,如有不懂的問題可以評(píng)論區(qū)交流或私聊!
喜歡文章可以點(diǎn)贊、收藏、關(guān)注、評(píng)論啦文章來源:http://www.zghlxwxcb.cn/news/detail-790046.html
→獲取源碼請(qǐng)私信←文章來源地址http://www.zghlxwxcb.cn/news/detail-790046.html
到了這里,關(guān)于計(jì)算機(jī)畢業(yè)設(shè)計(jì) 基于SpringBoot的物資綜合管理系統(tǒng)的設(shè)計(jì)與實(shí)現(xiàn) Java實(shí)戰(zhàn)項(xiàng)目 附源碼+文檔+視頻講解的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!