├── EERDiagram_Bank.PNG
├── MySql_Bank.txt
├── README.md
├── bank.sql
├── build.xml
├── build
├── built-jar.properties
└── classes
│ ├── DB
│ ├── DBConnection.class
│ ├── DeleteDatabase.class
│ ├── DisplayDatabase$1.class
│ ├── DisplayDatabase.class
│ └── QueryDatabase.class
│ └── bankmanagement
│ ├── AccountHolderScene.fxml
│ ├── AccountHolderSceneController.class
│ ├── BankMain.fxml
│ ├── BankMainController.class
│ ├── BankManagement.class
│ ├── BranchEmployeeScene.fxml
│ ├── BranchEmployeeSceneController.class
│ ├── ServiceScene.fxml
│ ├── ServiceSceneController.class
│ ├── TransactoinScene.fxml
│ ├── TransactoinSceneController.class
│ └── style.css
├── dist
├── BankManagement.html
├── BankManagement.jar
├── BankManagement.jnlp
├── lib
│ ├── controlsfx-8.20.8.jar
│ └── mysql-connector-java-5.1.23-bin.jar
└── web-files
│ ├── dtjava.js
│ ├── error.png
│ ├── get_java.png
│ ├── get_javafx.png
│ ├── javafx-chrome.png
│ ├── javafx-loading-100x100.gif
│ ├── javafx-loading-25x25.gif
│ ├── upgrade_java.png
│ └── upgrade_javafx.png
├── lib
├── controlsfx-8.20.8.jar
└── mysql-connector-java-6.0.4-bin.jar
├── manifest.mf
├── nbproject
├── build-impl.xml
├── configs
│ ├── Run_as_WebStart.properties
│ └── Run_in_Browser.properties
├── genfiles.properties
├── jfx-impl.xml
├── private
│ ├── configs
│ │ ├── Run_as_WebStart.properties
│ │ └── Run_in_Browser.properties
│ ├── private.properties
│ └── private.xml
├── project.properties
└── project.xml
└── src
├── DB
├── DBConnection.java
├── DeleteDatabase.java
├── DisplayDatabase.java
└── QueryDatabase.java
└── bankmanagement
├── AccountHolderScene.fxml
├── AccountHolderSceneController.java
├── BankMain.fxml
├── BankMainController.java
├── BankManagement.java
├── BranchEmployeeScene.fxml
├── BranchEmployeeSceneController.java
├── ServiceScene.fxml
├── ServiceSceneController.java
├── TransactoinScene.fxml
├── TransactoinSceneController.java
└── style.css
/EERDiagram_Bank.PNG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/EERDiagram_Bank.PNG
--------------------------------------------------------------------------------
/MySql_Bank.txt:
--------------------------------------------------------------------------------
1 | Create database bank
2 |
3 |
4 | CREATE TABLE `BranchTable` (
5 |
6 | `Id` INT NOT NULL AUTO_INCREMENT,
7 |
8 | `Name` VARCHAR(120) NOT NULL,
9 | `BCode` VARCHAR(15) NOT NULL,
10 |
11 | `Address` VARCHAR(200) NOT NULL,
12 |
13 | PRIMARY KEY (`Id`));
14 |
15 |
16 | CREATE TABLE `EmployeeTable` (
17 |
18 | `Id` INT NOT NULL AUTO_INCREMENT,
19 |
20 | `Name` VARCHAR(50) NOT NULL,
21 |
22 | `Branch` VARCHAR(50) NOT NULL,
23 |
24 | PRIMARY KEY (`Id`)) ;
25 |
26 |
27 | CREATE TABLE `AccountTable` (
28 |
29 | `Id` INT NOT NULL AUTO_INCREMENT,
30 |
31 | `Account_Number` VARCHAR(15) NOT NULL,
32 | `Account_Type` VARCHAR(15) NOT NULL,
33 | `BCode` VARCHAR(15) NOT NULL,
34 | `Name` VARCHAR(50) NOT NULL,
35 |
36 | `Gender` VARCHAR(10) NOT NULL,
37 | `DOB` Date,
38 |
39 | `Address` VARCHAR(50) NOT NULL,
40 |
41 | `Aadhar` VARCHAR(12) NOT NULL,
42 |
43 | `Balance` double NOT NULL,
44 |
45 | PRIMARY KEY (`Id`)) ;
46 |
47 |
48 | CREATE TABLE TransactionTable(
49 | `Id` INT NOT NULL AUTO_INCREMENT,
50 |
51 | `Date` Date NOT NULL,
52 | `Account_Num` Varchar(15),
53 | `Transaction_Type` Varchar(15),
54 | `Amount` double,
55 | PRIMARY KEY (`Id`)) ;
56 |
57 |
58 | CREATE TABLE ServiceTable(
59 | `Date` Date NOT NULL,
60 | `Account_Num` Varchar(15),
61 | `ServiceName` Varchar(100),
62 | `Description` Varchar(200),
63 | `Amount` double,
64 | `TransactionId` INT NOT NULL,
65 | INDEX par_ind (TransactionId),
66 | CONSTRAINT fk_tranTable FOREIGN KEY (TransactionId)
67 | REFERENCES TransactionTable (Id)
68 | ON DELETE CASCADE
69 | ON UPDATE CASCADE
70 | ) ENGINE=INNODB;
71 |
72 |
73 | // truncate table which has foreign key contraints.
74 |
75 | SET FOREIGN_KEY_CHECKS = 0;
76 | truncate tableName;
77 | SET FOREIGN_KEY_CHECKS = 1;
78 |
79 | // done.
80 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Bank-Management-System
2 |
3 | This is a Bank Management System Database Project.
4 |
5 |
6 |
7 | Abstract: The main aim of Bank Management Mini DBMS project is to keep record of customer transactions in the bank.
8 |
9 | We aim to demonstrate the use of create, read, update and delete MySQL operations through this project.
10 |
11 | Firstly, employee registration is done in the concern bank branch.
12 |
13 | Branch employee creates customer account in the bank, then customer can credit amount, debit amount and check balance.
14 |
15 | Customer can even use different services like insurance, loan, bill payments etc.
16 |
17 |
18 |
19 |
20 | Modules:
21 |
22 |
23 | Bank Management Mini DBMS Project contains 4 modules:
24 |
25 |
26 |
27 | 1. Account Holder: As the name suggests, a record of customer details.
28 |
29 | 2. Transaction: Transactions to be made by the customer (credit amount, debit etc).
30 |
31 | 3. Services: Additional services that customer may want like (insurance, loan etc.).
32 |
33 | 4. Branch/Employee : Manager/Employee details of the concern bank.
34 |
35 |
36 |
37 |
38 | SOFTWARE REQUIREMENTS:
39 |
40 |
41 |
42 | • Operating system : Windows XP/7/10.
43 |
44 | • Language : Java ( Install JDK 8 version)
45 |
46 | • IDE : Netbeans 8.2 / Eclipse
47 |
48 | • Database : MYSQL (Install XAMPP)
49 |
50 |
51 |
52 |
53 |
54 |
55 | Technologies used:
56 |
57 |
58 |
59 | • JavaFX
60 |
61 | • Mysql
62 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/bank.sql:
--------------------------------------------------------------------------------
1 | -- phpMyAdmin SQL Dump
2 | -- version 4.8.1
3 | -- https://www.phpmyadmin.net/
4 | --
5 | -- Host: 127.0.0.1
6 | -- Generation Time: Sep 06, 2018 at 08:58 AM
7 | -- Server version: 10.1.33-MariaDB
8 | -- PHP Version: 7.2.6
9 |
10 | SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
11 | SET AUTOCOMMIT = 0;
12 | START TRANSACTION;
13 | SET time_zone = "+00:00";
14 |
15 |
16 | /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
17 | /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
18 | /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
19 | /*!40101 SET NAMES utf8mb4 */;
20 |
21 | --
22 | -- Database: `bank`
23 | --
24 |
25 | -- --------------------------------------------------------
26 |
27 | --
28 | -- Table structure for table `accounttable`
29 | --
30 |
31 | CREATE TABLE `accounttable` (
32 | `Id` int(11) NOT NULL,
33 | `Account_Number` varchar(15) NOT NULL,
34 | `Account_Type` varchar(15) NOT NULL,
35 | `BCode` varchar(15) NOT NULL,
36 | `Name` varchar(50) NOT NULL,
37 | `Gender` varchar(10) NOT NULL,
38 | `DOB` date DEFAULT NULL,
39 | `Address` varchar(50) NOT NULL,
40 | `Aadhar` varchar(12) NOT NULL,
41 | `Balance` double NOT NULL
42 | ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
43 |
44 | --
45 | -- Dumping data for table `accounttable`
46 | --
47 |
48 | INSERT INTO `accounttable` (`Id`, `Account_Number`, `Account_Type`, `BCode`, `Name`, `Gender`, `DOB`, `Address`, `Aadhar`, `Balance`) VALUES
49 | (1, 'SBI23432310001', 'Savings', 'SBI234323', 'chandan', 'M', '2018-09-06', 'xyz xyz', '234432234', 20500);
50 |
51 | -- --------------------------------------------------------
52 |
53 | --
54 | -- Table structure for table `branchtable`
55 | --
56 |
57 | CREATE TABLE `branchtable` (
58 | `Id` int(11) NOT NULL,
59 | `Name` varchar(120) NOT NULL,
60 | `BCode` varchar(15) NOT NULL,
61 | `Address` varchar(200) NOT NULL
62 | ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
63 |
64 | --
65 | -- Dumping data for table `branchtable`
66 | --
67 |
68 | INSERT INTO `branchtable` (`Id`, `Name`, `BCode`, `Address`) VALUES
69 | (1, 'newjersy', 'SBI234323', 'xyz');
70 |
71 | -- --------------------------------------------------------
72 |
73 | --
74 | -- Table structure for table `employeetable`
75 | --
76 |
77 | CREATE TABLE `employeetable` (
78 | `Id` int(11) NOT NULL,
79 | `Name` varchar(50) NOT NULL,
80 | `Branch` varchar(50) NOT NULL
81 | ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
82 |
83 | --
84 | -- Dumping data for table `employeetable`
85 | --
86 |
87 | INSERT INTO `employeetable` (`Id`, `Name`, `Branch`) VALUES
88 | (1, 'arun', 'SBI234323');
89 |
90 | -- --------------------------------------------------------
91 |
92 | --
93 | -- Table structure for table `servicetable`
94 | --
95 |
96 | CREATE TABLE `servicetable` (
97 | `Date` date NOT NULL,
98 | `Account_Num` varchar(15) DEFAULT NULL,
99 | `ServiceName` varchar(100) DEFAULT NULL,
100 | `Description` varchar(200) DEFAULT NULL,
101 | `Amount` double DEFAULT NULL,
102 | `TransactionId` int(11) NOT NULL
103 | ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
104 |
105 | --
106 | -- Dumping data for table `servicetable`
107 | --
108 |
109 | INSERT INTO `servicetable` (`Date`, `Account_Num`, `ServiceName`, `Description`, `Amount`, `TransactionId`) VALUES
110 | ('2018-09-06', 'SBI23432310001', 'online banking', 'done', 500, 2);
111 |
112 | -- --------------------------------------------------------
113 |
114 | --
115 | -- Table structure for table `transactiontable`
116 | --
117 |
118 | CREATE TABLE `transactiontable` (
119 | `Id` int(11) NOT NULL,
120 | `Date` date NOT NULL,
121 | `Account_Num` varchar(15) DEFAULT NULL,
122 | `Transaction_Type` varchar(15) DEFAULT NULL,
123 | `Amount` double DEFAULT NULL
124 | ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
125 |
126 | --
127 | -- Dumping data for table `transactiontable`
128 | --
129 |
130 | INSERT INTO `transactiontable` (`Id`, `Date`, `Account_Num`, `Transaction_Type`, `Amount`) VALUES
131 | (1, '2018-09-06', 'SBI23432310001', 'Credit', 21000),
132 | (2, '2018-09-06', 'SBI23432310001', 'Debit', 500);
133 |
134 | --
135 | -- Indexes for dumped tables
136 | --
137 |
138 | --
139 | -- Indexes for table `accounttable`
140 | --
141 | ALTER TABLE `accounttable`
142 | ADD PRIMARY KEY (`Id`);
143 |
144 | --
145 | -- Indexes for table `branchtable`
146 | --
147 | ALTER TABLE `branchtable`
148 | ADD PRIMARY KEY (`Id`);
149 |
150 | --
151 | -- Indexes for table `employeetable`
152 | --
153 | ALTER TABLE `employeetable`
154 | ADD PRIMARY KEY (`Id`);
155 |
156 | --
157 | -- Indexes for table `servicetable`
158 | --
159 | ALTER TABLE `servicetable`
160 | ADD KEY `par_ind` (`TransactionId`);
161 |
162 | --
163 | -- Indexes for table `transactiontable`
164 | --
165 | ALTER TABLE `transactiontable`
166 | ADD PRIMARY KEY (`Id`);
167 |
168 | --
169 | -- AUTO_INCREMENT for dumped tables
170 | --
171 |
172 | --
173 | -- AUTO_INCREMENT for table `accounttable`
174 | --
175 | ALTER TABLE `accounttable`
176 | MODIFY `Id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
177 |
178 | --
179 | -- AUTO_INCREMENT for table `branchtable`
180 | --
181 | ALTER TABLE `branchtable`
182 | MODIFY `Id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
183 |
184 | --
185 | -- AUTO_INCREMENT for table `employeetable`
186 | --
187 | ALTER TABLE `employeetable`
188 | MODIFY `Id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
189 |
190 | --
191 | -- AUTO_INCREMENT for table `transactiontable`
192 | --
193 | ALTER TABLE `transactiontable`
194 | MODIFY `Id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
195 |
196 | --
197 | -- Constraints for dumped tables
198 | --
199 |
200 | --
201 | -- Constraints for table `servicetable`
202 | --
203 | ALTER TABLE `servicetable`
204 | ADD CONSTRAINT `fk_tranTable` FOREIGN KEY (`TransactionId`) REFERENCES `transactiontable` (`Id`) ON DELETE CASCADE ON UPDATE CASCADE;
205 | COMMIT;
206 |
207 | /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
208 | /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
209 | /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
210 |
--------------------------------------------------------------------------------
/build.xml:
--------------------------------------------------------------------------------
1 |
2 | Builds, tests, and runs the project BankManagement.
3 |
4 |
53 |
54 |
--------------------------------------------------------------------------------
/build/built-jar.properties:
--------------------------------------------------------------------------------
1 | #Sat, 25 Jan 2020 20:06:02 +0530
2 |
3 |
4 | C\:\\Users\\CHANDAN\ DAS\\Desktop\\chandan\ bank=
5 |
--------------------------------------------------------------------------------
/build/classes/DB/DBConnection.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/DB/DBConnection.class
--------------------------------------------------------------------------------
/build/classes/DB/DeleteDatabase.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/DB/DeleteDatabase.class
--------------------------------------------------------------------------------
/build/classes/DB/DisplayDatabase$1.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/DB/DisplayDatabase$1.class
--------------------------------------------------------------------------------
/build/classes/DB/DisplayDatabase.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/DB/DisplayDatabase.class
--------------------------------------------------------------------------------
/build/classes/DB/QueryDatabase.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/DB/QueryDatabase.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/AccountHolderScene.fxml:
--------------------------------------------------------------------------------
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 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
--------------------------------------------------------------------------------
/build/classes/bankmanagement/AccountHolderSceneController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/bankmanagement/AccountHolderSceneController.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/BankMain.fxml:
--------------------------------------------------------------------------------
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 |
49 |
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/build/classes/bankmanagement/BankMainController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/bankmanagement/BankMainController.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/BankManagement.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/bankmanagement/BankManagement.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/BranchEmployeeScene.fxml:
--------------------------------------------------------------------------------
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 |
45 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/build/classes/bankmanagement/BranchEmployeeSceneController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/bankmanagement/BranchEmployeeSceneController.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/ServiceScene.fxml:
--------------------------------------------------------------------------------
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 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
--------------------------------------------------------------------------------
/build/classes/bankmanagement/ServiceSceneController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/bankmanagement/ServiceSceneController.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/TransactoinScene.fxml:
--------------------------------------------------------------------------------
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 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
--------------------------------------------------------------------------------
/build/classes/bankmanagement/TransactoinSceneController.class:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/build/classes/bankmanagement/TransactoinSceneController.class
--------------------------------------------------------------------------------
/build/classes/bankmanagement/style.css:
--------------------------------------------------------------------------------
1 | /*
2 | To change this license header, choose License Headers in Project Properties.
3 | To change this template file, choose Tools | Templates
4 | and open the template in the editor.
5 | */
6 | /*
7 |
8 | Author : Chandan Das
9 | */
10 |
11 | .toggle-button {
12 | -fx-color: #003333;
13 | }
14 |
15 | .toggle-button:selected {
16 | -fx-color: #918c8f;
17 | -fx-background-color:
18 | -fx-shadow-highlight-color,
19 | linear-gradient(to bottom, derive(-fx-color,-22%) 0%, derive(-fx-color,-15%) 100%),
20 | linear-gradient(to bottom, derive(-fx-color,-15%) 0%, derive(-fx-color,-10%) 50%, derive(-fx-color,-8%) 98%, derive(-fx-color,-12%) 100%);
21 | }
22 |
23 | .toggle-button:selected:focused {
24 | -fx-color: #918c8f;
25 | -fx-background-color:
26 | -fx-focus-color,
27 | linear-gradient(to bottom, derive(-fx-color,-22%) 0%, derive(-fx-color,-15%) 100%),
28 | linear-gradient(to bottom, derive(-fx-color,-15%) 0%, derive(-fx-color,-10%) 50%, derive(-fx-color,-8%) 98%, derive(-fx-color,-12%) 100%);
29 | }
--------------------------------------------------------------------------------
/dist/BankManagement.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
17 |
18 |
38 |
39 |
40 | Test page for BankManagement
41 | Webstart: click to launch this app as webstart
42 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/dist/BankManagement.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/BankManagement.jar
--------------------------------------------------------------------------------
/dist/BankManagement.jnlp:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | BankManagement
5 | tanzeem
6 | null
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/dist/lib/controlsfx-8.20.8.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/lib/controlsfx-8.20.8.jar
--------------------------------------------------------------------------------
/dist/lib/mysql-connector-java-5.1.23-bin.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/lib/mysql-connector-java-5.1.23-bin.jar
--------------------------------------------------------------------------------
/dist/web-files/error.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/error.png
--------------------------------------------------------------------------------
/dist/web-files/get_java.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/get_java.png
--------------------------------------------------------------------------------
/dist/web-files/get_javafx.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/get_javafx.png
--------------------------------------------------------------------------------
/dist/web-files/javafx-chrome.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/javafx-chrome.png
--------------------------------------------------------------------------------
/dist/web-files/javafx-loading-100x100.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/javafx-loading-100x100.gif
--------------------------------------------------------------------------------
/dist/web-files/javafx-loading-25x25.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/javafx-loading-25x25.gif
--------------------------------------------------------------------------------
/dist/web-files/upgrade_java.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/upgrade_java.png
--------------------------------------------------------------------------------
/dist/web-files/upgrade_javafx.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/dist/web-files/upgrade_javafx.png
--------------------------------------------------------------------------------
/lib/controlsfx-8.20.8.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/lib/controlsfx-8.20.8.jar
--------------------------------------------------------------------------------
/lib/mysql-connector-java-6.0.4-bin.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chandandas27/Bank-Management-System/c25e1a14bc3bc0db680ddde451851e1926b60eaa/lib/mysql-connector-java-6.0.4-bin.jar
--------------------------------------------------------------------------------
/manifest.mf:
--------------------------------------------------------------------------------
1 | Manifest-Version: 1.0
2 | X-COMMENT: Main-Class will be added automatically by build
3 |
4 |
--------------------------------------------------------------------------------
/nbproject/build-impl.xml:
--------------------------------------------------------------------------------
1 |
2 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
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 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
187 |
188 |
189 |
190 |
191 |
192 |
193 |
194 |
195 |
196 |
197 |
198 |
199 |
200 |
201 |
202 |
203 |
204 |
205 |
206 |
207 |
208 |
209 |
210 |
211 |
212 |
213 |
214 |
215 |
216 |
217 |
218 |
219 |
220 |
221 |
222 |
223 |
224 |
225 |
226 |
227 |
228 |
229 |
230 |
231 |
232 |
233 |
234 | Must set src.dir
235 | Must set test.src.dir
236 | Must set build.dir
237 | Must set dist.dir
238 | Must set build.classes.dir
239 | Must set dist.javadoc.dir
240 | Must set build.test.classes.dir
241 | Must set build.test.results.dir
242 | Must set build.classes.excludes
243 | Must set dist.jar
244 |
245 |
246 |
247 |
248 |
249 |
250 |
251 |
252 |
253 |
254 |
255 |
256 |
257 |
258 |
259 |
260 |
261 |
262 |
263 |
264 |
265 |
266 |
267 |
268 |
269 |
270 |
271 |
272 |
273 |
274 |
275 |
276 |
277 |
278 |
279 |
280 |
281 |
282 |
283 |
284 |
285 |
286 |
287 |
288 |
289 |
290 |
291 |
292 |
293 |
294 |
295 |
296 |
297 |
298 |
299 |
300 |
301 |
302 |
303 |
304 |
305 |
306 |
307 |
308 |
309 |
310 |
311 |
312 |
313 |
314 |
315 |
316 |
317 |
318 |
319 |
320 |
321 |
322 |
323 |
324 |
325 |
326 |
327 |
328 |
329 |
330 |
331 |
332 |
333 |
334 |
335 |
336 |
337 |
338 |
339 |
340 |
341 |
342 |
343 |
344 | Must set javac.includes
345 |
346 |
347 |
348 |
349 |
350 |
351 |
352 |
353 |
354 |
355 |
356 |
357 |
358 |
359 |
360 |
361 |
362 |
363 |
364 |
365 |
366 |
367 |
368 |
369 |
370 |
371 |
372 |
373 |
374 |
375 |
376 |
377 |
378 |
379 |
380 |
381 |
382 |
383 |
384 |
385 |
386 |
387 |
388 |
389 |
390 |
391 |
392 |
393 |
394 |
395 |
396 |
397 |
398 |
399 |
400 |
401 |
402 |
403 |
404 |
405 |
406 |
407 |
408 |
409 |
410 |
411 |
412 |
413 |
414 |
415 |
416 |
417 |
418 |
419 |
420 |
421 |
422 |
423 |
424 |
425 |
426 |
427 |
428 |
429 |
430 |
431 |
432 |
433 |
434 |
435 |
436 |
437 |
438 |
439 |
440 |
441 |
442 |
443 |
444 |
445 |
446 |
447 |
448 |
449 |
450 |
451 |
452 |
453 |
454 |
455 |
456 |
457 |
458 |
459 |
460 |
461 |
462 |
463 |
464 |
465 |
466 |
467 |
468 |
469 |
470 |
471 |
472 |
473 | No tests executed.
474 |
475 |
476 |
477 |
478 |
479 |
480 |
481 |
482 |
483 |
484 |
485 |
486 |
487 |
488 |
489 |
490 |
491 |
492 |
493 |
494 |
495 |
496 |
497 |
498 |
499 |
500 |
501 |
502 |
503 |
504 |
505 |
506 |
507 |
508 |
509 |
510 |
511 |
512 |
513 |
514 |
515 |
516 |
517 |
518 |
519 |
520 |
521 |
522 |
523 |
524 |
525 |
526 |
527 |
528 |
529 |
530 |
531 |
532 |
533 |
534 |
535 |
536 |
537 |
538 |
539 |
540 |
541 |
542 |
543 |
544 |
545 |
546 |
547 |
548 |
549 |
550 |
551 |
552 |
553 |
554 |
555 |
556 |
557 |
558 |
559 |
560 |
561 |
562 |
563 |
564 |
565 |
566 |
567 |
568 |
569 |
570 |
571 |
572 |
573 |
574 |
575 |
576 |
577 |
578 |
579 |
580 |
581 |
582 |
583 |
584 |
585 |
586 |
587 |
588 |
589 |
590 |
591 |
592 |
593 |
594 |
595 |
596 |
597 |
598 |
599 |
600 |
601 |
602 |
603 |
604 |
605 |
606 |
607 |
608 |
609 |
610 |
611 |
612 |
613 |
614 |
615 |
616 |
617 |
618 |
619 |
620 |
621 |
622 |
623 |
624 |
625 |
626 |
627 |
628 |
629 |
630 |
631 |
632 |
633 |
634 |
635 |
636 |
637 |
638 |
639 |
640 |
641 |
642 |
643 |
644 |
645 |
646 |
647 |
648 |
649 |
650 |
651 |
652 |
653 |
654 |
655 |
656 |
657 |
658 |
659 |
660 |
661 |
662 |
663 |
664 |
665 |
666 |
667 |
668 |
669 |
670 |
671 |
672 |
673 |
674 |
675 |
676 |
677 |
678 |
681 |
682 |
683 |
684 |
685 |
686 |
687 |
688 |
689 |
690 |
691 |
692 |
693 |
694 |
695 |
696 |
697 |
698 |
699 |
700 |
701 |
702 |
703 |
704 |
705 |
706 |
707 |
708 |
709 |
710 |
711 |
712 |
713 |
714 |
715 |
716 |
717 |
718 |
719 |
720 |
721 |
722 |
723 | Must set JVM to use for profiling in profiler.info.jvm
724 | Must set profiler agent JVM arguments in profiler.info.jvmargs.agent
725 |
726 |
729 |
730 |
731 |
732 |
733 |
734 |
735 |
736 |
737 |
738 |
739 |
740 |
741 |
742 |
743 |
744 |
745 |
746 |
747 |
748 |
749 |
750 |
751 |
752 |
753 |
754 |
755 |
756 |
757 |
758 |
759 |
760 |
761 |
762 |
763 |
764 |
765 |
766 |
767 |
768 |
769 |
770 |
771 |
772 |
773 |
774 |
775 |
776 |
777 |
778 |
779 |
780 |
781 |
782 |
783 |
784 |
785 |
786 |
787 |
788 |
789 |
790 |
791 |
792 |
793 |
794 |
795 |
796 |
797 |
798 |
799 |
800 |
801 |
802 |
803 |
804 |
805 |
806 |
807 |
808 |
809 |
810 |
811 |
812 |
813 |
814 |
815 |
816 |
817 |
818 |
819 |
820 |
821 |
822 |
823 |
824 |
825 |
826 |
827 |
828 |
829 |
830 |
831 |
832 |
833 |
834 |
835 |
836 |
837 |
838 |
839 |
840 |
841 |
842 |
843 |
844 |
845 |
846 |
847 |
848 |
849 |
850 |
851 |
852 |
853 |
854 |
855 |
856 |
857 |
858 |
859 |
860 |
861 |
862 |
863 |
864 |
865 |
866 |
867 |
868 |
869 |
870 |
871 |
872 |
873 |
874 |
875 |
876 |
877 |
878 |
879 |
880 |
881 |
882 |
883 |
884 |
885 |
886 |
887 |
892 |
893 |
894 |
895 |
896 |
897 |
898 |
899 |
900 |
901 |
902 |
903 |
904 |
905 |
906 |
907 |
908 |
909 |
910 |
911 |
912 |
913 |
914 |
915 |
916 |
917 |
918 |
919 |
920 |
921 |
922 |
923 |
924 |
925 |
926 |
927 |
928 |
929 |
930 |
931 |
932 |
933 |
934 |
935 |
936 |
937 |
938 |
939 |
940 |
941 |
942 |
943 |
944 |
945 |
946 |
947 |
948 |
949 |
950 |
951 |
952 | Must select some files in the IDE or set javac.includes
953 |
954 |
955 |
956 |
957 |
958 |
959 |
960 |
961 |
966 |
967 |
968 |
969 |
970 |
971 |
972 |
973 |
974 |
975 |
976 |
977 |
978 |
979 |
980 |
981 |
982 |
983 |
984 |
985 |
986 |
987 |
988 |
989 |
990 |
991 |
992 |
993 |
994 |
995 |
996 |
997 |
998 |
999 |
1000 |
1001 |
1002 | To run this application from the command line without Ant, try:
1003 |
1004 | java -jar "${dist.jar.resolved}"
1005 |
1006 |
1007 |
1008 |
1009 |
1010 |
1011 |
1012 |
1013 |
1014 |
1015 |
1016 |
1017 |
1018 |
1019 |
1020 |
1021 |
1022 |
1023 |
1024 |
1025 |
1026 |
1027 |
1028 |
1029 |
1030 |
1031 |
1032 |
1033 |
1034 |
1035 |
1040 |
1041 |
1042 |
1043 |
1044 |
1045 |
1046 |
1047 |
1048 |
1049 |
1050 |
1051 | Must select one file in the IDE or set run.class
1052 |
1053 |
1054 |
1055 | Must select one file in the IDE or set run.class
1056 |
1057 |
1058 |
1063 |
1064 |
1065 |
1066 |
1067 |
1068 |
1069 |
1070 |
1071 |
1072 |
1073 |
1074 |
1075 |
1076 |
1077 |
1078 |
1079 |
1080 |
1081 |
1082 | Must select one file in the IDE or set debug.class
1083 |
1084 |
1085 |
1086 |
1087 | Must select one file in the IDE or set debug.class
1088 |
1089 |
1090 |
1091 |
1092 | Must set fix.includes
1093 |
1094 |
1095 |
1096 |
1097 |
1098 |
1099 |
1104 |
1107 |
1108 | This target only works when run from inside the NetBeans IDE.
1109 |
1110 |
1111 |
1112 |
1113 |
1114 |
1115 |
1116 |
1117 | Must select one file in the IDE or set profile.class
1118 | This target only works when run from inside the NetBeans IDE.
1119 |
1120 |
1121 |
1122 |
1123 |
1124 |
1125 |
1126 |
1127 | This target only works when run from inside the NetBeans IDE.
1128 |
1129 |
1130 |
1131 |
1132 |
1133 |
1134 |
1135 |
1136 |
1137 |
1138 |
1139 |
1140 | This target only works when run from inside the NetBeans IDE.
1141 |
1142 |
1143 |
1144 |
1145 |
1146 |
1147 |
1148 |
1149 |
1150 |
1151 |
1152 |
1153 |
1154 |
1155 |
1156 |
1157 |
1158 |
1159 |
1160 |
1161 |
1162 |
1165 |
1166 |
1167 |
1168 |
1169 |
1170 |
1171 |
1172 |
1173 |
1174 |
1175 |
1176 |
1177 |
1178 | Must select one file in the IDE or set run.class
1179 |
1180 |
1181 |
1182 |
1183 |
1184 | Must select some files in the IDE or set test.includes
1185 |
1186 |
1187 |
1188 |
1189 | Must select one file in the IDE or set run.class
1190 |
1191 |
1192 |
1193 |
1194 | Must select one file in the IDE or set applet.url
1195 |
1196 |
1197 |
1198 |
1203 |
1204 |
1205 |
1206 |
1207 |
1208 |
1209 |
1210 |
1211 |
1212 |
1213 |
1214 |
1215 |
1216 |
1217 |
1218 |
1219 |
1220 |
1221 |
1222 |
1223 |
1224 |
1225 |
1226 |
1227 |
1228 |
1229 |
1230 |
1231 |
1232 |
1233 |
1234 |
1235 |
1236 |
1237 |
1238 |
1239 |
1240 |
1241 |
1242 |
1247 |
1248 |
1249 |
1250 |
1251 |
1252 |
1253 |
1254 |
1255 |
1256 |
1257 |
1258 |
1259 |
1260 |
1261 |
1262 |
1263 |
1264 |
1265 |
1266 |
1267 |
1268 |
1269 |
1270 |
1271 |
1272 |
1273 | Must select some files in the IDE or set javac.includes
1274 |
1275 |
1276 |
1277 |
1278 |
1279 |
1280 |
1281 |
1282 |
1283 |
1284 |
1285 |
1290 |
1291 |
1292 |
1293 |
1294 |
1295 |
1296 |
1297 | Some tests failed; see details above.
1298 |
1299 |
1300 |
1301 |
1302 |
1303 |
1304 |
1305 |
1306 | Must select some files in the IDE or set test.includes
1307 |
1308 |
1309 |
1310 | Some tests failed; see details above.
1311 |
1312 |
1313 |
1314 | Must select some files in the IDE or set test.class
1315 | Must select some method in the IDE or set test.method
1316 |
1317 |
1318 |
1319 | Some tests failed; see details above.
1320 |
1321 |
1322 |
1327 |
1328 | Must select one file in the IDE or set test.class
1329 |
1330 |
1331 |
1332 | Must select one file in the IDE or set test.class
1333 | Must select some method in the IDE or set test.method
1334 |
1335 |
1336 |
1337 |
1338 |
1339 |
1340 |
1341 |
1342 |
1343 |
1344 |
1345 |
1350 |
1351 | Must select one file in the IDE or set applet.url
1352 |
1353 |
1354 |
1355 |
1356 |
1357 |
1358 |
1363 |
1364 | Must select one file in the IDE or set applet.url
1365 |
1366 |
1367 |
1368 |
1369 |
1370 |
1371 |
1372 |
1377 |
1378 |
1379 |
1380 |
1381 |
1382 |
1383 |
1384 |
1385 |
1386 |
1387 |
1388 |
1389 |
1390 |
1391 |
1392 |
1393 |
1394 |
1395 |
1396 |
1397 |
1398 |
1399 |
1400 |
1401 |
1402 |
1403 |
1404 |
1405 |
1406 |
1407 |
1408 |
1409 |
1410 |
1411 |
1412 |
1413 |
1414 |
1415 |
1416 |
1417 |
1418 |
1419 |
1420 |
1421 |
1422 |
--------------------------------------------------------------------------------
/nbproject/configs/Run_as_WebStart.properties:
--------------------------------------------------------------------------------
1 | # Do not modify this property in this configuration. It can be re-generated.
2 | $label=Run as WebStart
3 |
--------------------------------------------------------------------------------
/nbproject/configs/Run_in_Browser.properties:
--------------------------------------------------------------------------------
1 | # Do not modify this property in this configuration. It can be re-generated.
2 | $label=Run in Browser
3 |
--------------------------------------------------------------------------------
/nbproject/genfiles.properties:
--------------------------------------------------------------------------------
1 | build.xml.data.CRC32=428edb93
2 | build.xml.script.CRC32=d1c7e3c6
3 | build.xml.stylesheet.CRC32=8064a381@1.80.1.48
4 | # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
5 | # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
6 | nbproject/build-impl.xml.data.CRC32=428edb93
7 | nbproject/build-impl.xml.script.CRC32=ebb876e0
8 | nbproject/build-impl.xml.stylesheet.CRC32=830a3534@1.80.1.48
9 |
--------------------------------------------------------------------------------
/nbproject/private/configs/Run_as_WebStart.properties:
--------------------------------------------------------------------------------
1 | # Do not modify this property in this configuration. It can be re-generated.
2 | javafx.run.as=webstart
3 |
--------------------------------------------------------------------------------
/nbproject/private/configs/Run_in_Browser.properties:
--------------------------------------------------------------------------------
1 | # Do not modify this property in this configuration. It can be re-generated.
2 | javafx.run.as=embedded
3 |
--------------------------------------------------------------------------------
/nbproject/private/private.properties:
--------------------------------------------------------------------------------
1 | auxiliary.org-netbeans-modules-projectapi.issue214819_5f_fx_5f_enabled=true
2 | # No need to modify this property unless customizing JavaFX Ant task infrastructure
3 | endorsed.javafx.ant.classpath=.
4 | javafx.run.inbrowser=
5 | javafx.run.inbrowser.path=C:\\Program Files\\Internet Explorer\\iexplore.exe
6 | user.properties.file=C:\\Users\\CHANDAN DAS\\AppData\\Roaming\\NetBeans\\8.2\\build.properties
7 |
--------------------------------------------------------------------------------
/nbproject/private/private.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/nbproject/project.properties:
--------------------------------------------------------------------------------
1 | annotation.processing.enabled=true
2 | annotation.processing.enabled.in.editor=false
3 | annotation.processing.processor.options=
4 | annotation.processing.processors.list=
5 | annotation.processing.run.all.processors=true
6 | annotation.processing.source.output=${build.generated.sources.dir}/ap-source-output
7 | application.title=BankManagement
8 | application.vendor=tanzeem
9 | build.classes.dir=${build.dir}/classes
10 | build.classes.excludes=**/*.java,**/*.form
11 | # This directory is removed when the project is cleaned:
12 | build.dir=build
13 | build.generated.dir=${build.dir}/generated
14 | build.generated.sources.dir=${build.dir}/generated-sources
15 | # Only compile against the classpath explicitly listed here:
16 | build.sysclasspath=ignore
17 | build.test.classes.dir=${build.dir}/test/classes
18 | build.test.results.dir=${build.dir}/test/results
19 | compile.on.save=true
20 | compile.on.save.unsupported.javafx=true
21 | # Uncomment to specify the preferred debugger connection transport:
22 | #debug.transport=dt_socket
23 | debug.classpath=\
24 | ${run.classpath}
25 | debug.test.classpath=\
26 | ${run.test.classpath}
27 | # This directory is removed when the project is cleaned:
28 | dist.dir=dist
29 | dist.jar=${dist.dir}/BankManagement.jar
30 | dist.javadoc.dir=${dist.dir}/javadoc
31 | endorsed.classpath=
32 | excludes=
33 | file.reference.controlsfx-8.20.8.jar=lib\\controlsfx-8.20.8.jar
34 | includes=**
35 | # Non-JavaFX jar file creation is deactivated in JavaFX 2.0+ projects
36 | jar.archive.disabled=true
37 | jar.compress=false
38 | javac.classpath=\
39 | ${javafx.classpath.extension}:\
40 | ${file.reference.controlsfx-8.20.8.jar}:\
41 | ${libs.MySQLDriver.classpath}
42 | # Space-separated list of extra javac options
43 | javac.compilerargs=
44 | javac.deprecation=false
45 | javac.processorpath=\
46 | ${javac.classpath}
47 | javac.source=1.8
48 | javac.target=1.8
49 | javac.test.classpath=\
50 | ${javac.classpath}:\
51 | ${build.classes.dir}
52 | javac.test.processorpath=\
53 | ${javac.test.classpath}
54 | javadoc.additionalparam=
55 | javadoc.author=false
56 | javadoc.encoding=${source.encoding}
57 | javadoc.noindex=false
58 | javadoc.nonavbar=false
59 | javadoc.notree=false
60 | javadoc.private=false
61 | javadoc.splitindex=true
62 | javadoc.use=true
63 | javadoc.version=false
64 | javadoc.windowtitle=
65 | javafx.application.implementation.version=1.0
66 | javafx.binarycss=false
67 | javafx.classpath.extension=\
68 | ${java.home}/lib/javaws.jar:\
69 | ${java.home}/lib/deploy.jar:\
70 | ${java.home}/lib/plugin.jar
71 | javafx.deploy.allowoffline=true
72 | # If true, application update mode is set to 'background', if false, update mode is set to 'eager'
73 | javafx.deploy.backgroundupdate=false
74 | javafx.deploy.embedJNLP=true
75 | javafx.deploy.includeDT=true
76 | # Set true to prevent creation of temporary copy of deployment artifacts before each run (disables concurrent runs)
77 | javafx.disable.concurrent.runs=false
78 | # Set true to enable multiple concurrent runs of the same WebStart or Run-in-Browser project
79 | javafx.enable.concurrent.external.runs=false
80 | # This is a JavaFX project
81 | javafx.enabled=true
82 | javafx.fallback.class=com.javafx.main.NoJavaFXFallback
83 | # Main class for JavaFX
84 | javafx.main.class=bankmanagement.BankManagement
85 | javafx.preloader.class=
86 | # This project does not use Preloader
87 | javafx.preloader.enabled=false
88 | javafx.preloader.jar.filename=
89 | javafx.preloader.jar.path=
90 | javafx.preloader.project.path=
91 | javafx.preloader.type=none
92 | # Set true for GlassFish only. Rebases manifest classpaths of JARs in lib dir. Not usable with signed JARs.
93 | javafx.rebase.libs=false
94 | javafx.run.height=600
95 | javafx.run.width=800
96 | # Pre-JavaFX 2.0 WebStart is deactivated in JavaFX 2.0+ projects
97 | jnlp.enabled=false
98 | # Main class for Java launcher
99 | main.class=com.javafx.main.Main
100 | # For improved security specify narrower Codebase manifest attribute to prevent RIAs from being repurposed
101 | manifest.custom.codebase=*
102 | # Specify Permissions manifest attribute to override default (choices: sandbox, all-permissions)
103 | manifest.custom.permissions=
104 | manifest.file=manifest.mf
105 | meta.inf.dir=${src.dir}/META-INF
106 | platform.active=default_platform
107 | run.classpath=\
108 | ${dist.jar}:\
109 | ${javac.classpath}:\
110 | ${build.classes.dir}
111 | run.test.classpath=\
112 | ${javac.test.classpath}:\
113 | ${build.test.classes.dir}
114 | source.encoding=UTF-8
115 | src.dir=src
116 | test.src.dir=test
117 |
--------------------------------------------------------------------------------
/nbproject/project.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | org.netbeans.modules.java.j2seproject
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 | BankManagement
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/src/DB/DBConnection.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package DB;
7 |
8 | /***** DBConnection.java *****/
9 | import java.sql.Connection;
10 | import java.sql.DriverManager;
11 | import java.sql.SQLException;
12 | import java.util.Properties;
13 |
14 |
15 |
16 | public class DBConnection {
17 | private static Connection conn;
18 |
19 | public static String url = "jdbc:mysql://localhost:3306/bank?useSSL=false";
20 | private static String user = "root";//Username of database
21 |
22 |
23 |
24 | public static Connection connect() throws SQLException{
25 | try{
26 | Class.forName("com.mysql.jdbc.Driver").newInstance();
27 | }catch(ClassNotFoundException cnfe){
28 | System.err.println("Error: "+cnfe.getMessage());
29 | }catch(InstantiationException ie){
30 | System.err.println("Error: "+ie.getMessage());
31 | }catch(IllegalAccessException iae){
32 | System.err.println("Error: "+iae.getMessage());
33 | }
34 | conn = DriverManager.getConnection(url,user,"");
35 | // System.out.println(url);
36 | return conn;
37 | }
38 |
39 | public static Connection getConnection() throws SQLException, ClassNotFoundException{
40 | if(conn !=null && !conn.isClosed())
41 | return conn;
42 | connect();
43 | return conn;
44 | }
45 | }
--------------------------------------------------------------------------------
/src/DB/DeleteDatabase.java:
--------------------------------------------------------------------------------
1 | package DB;
2 |
3 | import java.sql.Connection;
4 | import javafx.collections.FXCollections;
5 |
6 | /*
7 | * To change this license header, choose License Headers in Project Properties.
8 | * To change this template file, choose Tools | Templates
9 | * and open the template in the editor.
10 | */
11 |
12 | /**
13 | *
14 | * @author Chandan Das
15 | */
16 | public class DeleteDatabase {
17 |
18 |
19 | // data.clear();
20 | // data.removeAll(data);
21 | public static void deleteRecord(int id,String tableName){
22 | Connection c ;
23 |
24 | try{
25 | c = DBConnection.connect();
26 |
27 | String query = "Delete from "+tableName+" where id='"+id+"';";
28 | c.createStatement().execute(query);
29 | c.close();
30 |
31 |
32 | }catch(Exception e){
33 | System.out.println("Error on Building Data");
34 | }
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/src/DB/DisplayDatabase.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package DB;
7 |
8 | /***** DisplayDatabase.java *****/
9 |
10 | import javafx.scene.image.Image;
11 | import javafx.scene.image.ImageView;
12 | import java.sql.Connection;
13 | import java.sql.ResultSet;
14 | import javafx.beans.property.SimpleStringProperty;
15 | import javafx.beans.value.ObservableValue;
16 | import javafx.collections.FXCollections;
17 | import javafx.collections.ObservableList;
18 | import javafx.geometry.Pos;
19 | import javafx.scene.control.Button;
20 | import javafx.scene.control.TableCell;
21 | import javafx.scene.control.TableColumn;
22 | import javafx.scene.control.TableColumn.CellDataFeatures;
23 | import javafx.scene.control.TableView;
24 | import javafx.util.Callback;
25 | import javafx.scene.control.cell.PropertyValueFactory;
26 | import javafx.scene.layout.Background;
27 | import javafx.scene.paint.Color;
28 |
29 |
30 |
31 |
32 |
33 |
34 | public class DisplayDatabase{
35 |
36 |
37 |
38 | public ObservableList getData() {
39 | return data;
40 | }
41 | //Tableview and data
42 | private ObservableList data;
43 |
44 |
45 |
46 |
47 | //Connection database
48 | public void buildData(TableView tableview,String SQL){
49 | if(!tableview.getColumns().isEmpty())
50 | tableview.getColumns().clear();
51 | Connection c ;
52 | data = FXCollections.observableArrayList();
53 | // data.clear();
54 | // data.removeAll(data);
55 |
56 | try{
57 | c = DBConnection.connect();
58 | // String SQL = "SELECT * from " + tableName;
59 | //ResultSet
60 | ResultSet rs = c.createStatement().executeQuery(SQL);
61 |
62 | /**********************************
63 | * TABLE COLUMN ADDED DYNAMICALLY *
64 | **********************************/
65 |
66 | for(int i=0 ; i,ObservableValue>(){
72 | public ObservableValue call(CellDataFeatures param) {
73 | return new SimpleStringProperty(param.getValue().get(j).toString());
74 | }
75 | });
76 |
77 |
78 | // Add all columns to tableview
79 |
80 | tableview.getColumns().addAll(col);
81 |
82 |
83 | }
84 |
85 | /********************************
86 | * Data added to ObservableList *
87 | ********************************/
88 |
89 | while(rs.next()){
90 | //Iterate Row
91 | ObservableList row = FXCollections.observableArrayList();
92 | for(int i=1 ; i<=rs.getMetaData().getColumnCount(); i++){
93 | //Iterate Column
94 |
95 | row.add(rs.getString(i));
96 |
97 | }
98 |
99 | //System.out.println("Row [1] added "+row );
100 | data.add(row);
101 |
102 | }
103 | //FINALLY ADDED TO TableView
104 | tableview.setItems(data);
105 |
106 |
107 | }catch(Exception e){
108 | System.out.println("Error on Building Data");
109 | }
110 | }
111 |
112 |
113 | }
--------------------------------------------------------------------------------
/src/DB/QueryDatabase.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package DB;
7 |
8 | import java.sql.Connection;
9 | import java.sql.ResultSet;
10 | import java.sql.SQLException;
11 | import java.util.logging.Level;
12 | import java.util.logging.Logger;
13 |
14 | /**
15 | *
16 | * @author Chandan Das
17 | */
18 | public class QueryDatabase {
19 |
20 | static ResultSet rs;
21 |
22 | public static ResultSet query(String q){
23 | try {
24 | Connection c = DBConnection.connect();
25 | rs = c.createStatement().executeQuery(q);
26 |
27 |
28 | } catch (SQLException ex) {
29 | Logger.getLogger(QueryDatabase.class.getName()).log(Level.SEVERE, null, ex);
30 | }
31 |
32 | return rs;
33 | }
34 |
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/src/bankmanagement/AccountHolderScene.fxml:
--------------------------------------------------------------------------------
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 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
--------------------------------------------------------------------------------
/src/bankmanagement/AccountHolderSceneController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package bankmanagement;
7 |
8 | import DB.DBConnection;
9 | import DB.DeleteDatabase;
10 | import DB.DisplayDatabase;
11 | import DB.QueryDatabase;
12 | import java.net.URL;
13 | import java.sql.Connection;
14 | import java.sql.ResultSet;
15 | import java.sql.SQLException;
16 | import java.time.LocalDate;
17 | import java.util.ArrayList;
18 | import java.util.ResourceBundle;
19 | import java.util.logging.Level;
20 | import java.util.logging.Logger;
21 | import javafx.collections.FXCollections;
22 | import javafx.collections.ObservableList;
23 | import javafx.event.ActionEvent;
24 | import javafx.fxml.FXML;
25 | import javafx.fxml.Initializable;
26 | import javafx.scene.control.Button;
27 | import javafx.scene.control.CheckBox;
28 | import javafx.scene.control.ComboBox;
29 | import javafx.scene.control.DatePicker;
30 | import javafx.scene.control.Label;
31 | import javafx.scene.control.MenuItem;
32 | import javafx.scene.control.TableView;
33 | import javafx.scene.control.TextField;
34 | import javafx.scene.layout.AnchorPane;
35 |
36 |
37 | /**
38 | * FXML Controller class
39 | *
40 | * @author Chandan Das
41 | */
42 | public class AccountHolderSceneController implements Initializable {
43 |
44 |
45 | /**
46 | * Initializes the controller class.
47 | * @param url
48 | * @param rb
49 | */
50 |
51 | @FXML
52 | private TextField cName;
53 | @FXML
54 | private TextField cAddress;
55 | @FXML
56 | private TextField cAdhaarId;
57 | @FXML
58 | private ComboBox cGenderCombo;
59 | @FXML
60 | private ComboBox cBranch;
61 | @FXML
62 | private Button addCBtn;
63 | @FXML
64 | private ComboBox cType;
65 | @FXML
66 | private TableView> acntHoldTable;
67 | @FXML
68 | private DatePicker cDOB;
69 |
70 | String accountNumber = "";
71 | String type = ("");
72 | String name = ("");
73 | String gender = ("");
74 | String address = ("");
75 | String branch = ("");
76 | LocalDate dob = null;
77 | double balance = 0;
78 | String aadhar = "";
79 |
80 | ObservableList branchList = FXCollections.observableArrayList();
81 | DisplayDatabase accountData = new DisplayDatabase();
82 |
83 | @FXML
84 | private TextField accnum;
85 |
86 | @Override
87 | public void initialize(URL url, ResourceBundle rb) {
88 | ObservableList genderList = FXCollections.observableArrayList();
89 | genderList.add("M");
90 | genderList.add("F");
91 | genderList.add("O");
92 | cGenderCombo.setItems( genderList);
93 |
94 | ObservableList typeList = FXCollections.observableArrayList();
95 | typeList.add("Savings");
96 | typeList.add("Current");
97 | typeList.add("Demat");
98 | cType.setItems( typeList);
99 | cType.setValue("Savings");
100 |
101 | ResultSet rs = QueryDatabase.query("Select BCode from branchtable;");
102 | if(rs!=null){
103 | try {
104 | while(rs.next()){
105 | branchList.add(rs.getString(1));
106 | }
107 | } catch (SQLException ex) {
108 | Logger.getLogger(AccountHolderSceneController.class.getName()).log(Level.SEVERE, null, ex);
109 | }
110 |
111 | }
112 | cBranch.setItems(branchList);
113 |
114 | accountData.buildData(acntHoldTable, "Select * from accountTable;");
115 |
116 | cDOB.setValue(LocalDate.now());
117 | }
118 |
119 |
120 |
121 |
122 | @FXML
123 | private void addCustomer(ActionEvent event) {
124 |
125 | getFields();
126 | try {
127 |
128 | Connection c;
129 | c = DBConnection.connect();
130 |
131 | if(!update){
132 |
133 |
134 |
135 | ResultSet rs= QueryDatabase.query("Select Count(Id) from accounttable where BCode ='"+branch+"';");
136 | if(rs==null){
137 | accountNumber = branch+"10001";
138 | }else{
139 | if(rs.next()){
140 | int id = Integer.parseInt(rs.getString(1));
141 | id++;
142 | id +=10000;
143 | accountNumber = branch+id;
144 | }else{
145 | accountNumber = branch+"10001";
146 | }
147 |
148 | }
149 |
150 |
151 | String query = "INSERT INTO accounttable (Account_Number,Account_Type,BCode,Name,Gender,Dob,Address,Aadhar,Balance)VALUES("+
152 |
153 | "'"+accountNumber+"',\n" +
154 | "'"+type+"',\n" +
155 | "'"+branch+"',\n" +
156 | "'"+name+"',\n" +
157 | "'"+gender+"',\n" +
158 | "'"+dob+"',\n" +
159 | "'"+address+"',\n" +
160 | "'"+aadhar+"',\n" +
161 |
162 | "'"+balance+"');";
163 |
164 |
165 |
166 | c.createStatement().execute(query);
167 |
168 |
169 | }else{
170 |
171 | String query = "Update accounttable set Account_Type='"+type+"',BCode='"+branch+"',Name='"+name+"',"
172 | + "Gender='"+gender+"',Dob='"+dob+"',Address='"+address+"',Aadhar='"+aadhar+"' Where Id='"+id+"';";
173 | System.out.println(query);
174 | c.createStatement().execute(query);
175 | }
176 |
177 | c.close();
178 |
179 | } catch (SQLException ex) {
180 | Logger.getLogger(AccountHolderSceneController.class.getName()).log(Level.SEVERE, null, ex);
181 | }
182 |
183 | clearFields();
184 |
185 | accountData.buildData(acntHoldTable, "Select * from accountTable;");
186 | }
187 |
188 |
189 | private void getFields() {
190 |
191 | name = cName.getText();
192 | type= cType.getValue();
193 | gender = cGenderCombo.getValue();
194 | address = cAddress.getText();
195 | branch = cBranch.getValue();
196 | dob = cDOB.getValue();
197 | balance= 0;
198 | aadhar = cAdhaarId.getText();
199 |
200 | }
201 |
202 | private void clearFields() {
203 | cName.clear();
204 | cType.setValue("Savings");
205 | cGenderCombo.setValue("");
206 | cAddress.clear();
207 | cBranch.setValue("");
208 | cDOB.setValue(LocalDate.now());
209 | balance= 0;
210 | cAdhaarId.clear();
211 | update = false;
212 | addCBtn.setText("Create Account");
213 | }
214 | String query="Select * from accountTable;";
215 | @FXML
216 | private void srcAcntNum(ActionEvent event) {
217 |
218 | String acc = accnum.getText();
219 | if(acc!=null && !acc.isEmpty()){
220 | query = "Select * from accountTable where Account_Number='"+acc+"';";
221 |
222 | }else{
223 | query = "Select * from accountTable;";
224 |
225 | }
226 | accountData.buildData(acntHoldTable, query);
227 | }
228 |
229 | @FXML
230 | private void mDeleteAccount(ActionEvent event) {
231 |
232 | int index = acntHoldTable.getSelectionModel().getFocusedIndex();
233 | ObservableList data = accountData.getData();
234 | ObservableList itemData = data.get(index);
235 |
236 | int id = Integer.parseInt(itemData.get(0));
237 |
238 | DeleteDatabase.deleteRecord(id, "accountTable");
239 | accountData.buildData(acntHoldTable, query);
240 | }
241 | boolean update = false;
242 | int id=1;
243 | @FXML
244 | private void mUpdateAccount(ActionEvent event) {
245 |
246 | int index = acntHoldTable.getSelectionModel().getFocusedIndex();
247 | ObservableList data = accountData.getData();
248 | ObservableList itemData = data.get(index);
249 |
250 |
251 | id = Integer.parseInt(itemData.get(0));
252 | cName.setText(itemData.get(4));
253 | cType.setValue(itemData.get(2));
254 | cGenderCombo.setValue(itemData.get(5));
255 | cAddress.setText(itemData.get(7));
256 | cBranch.setValue(itemData.get(3));
257 | cDOB.setValue(LocalDate.parse(itemData.get(6)));
258 | cAdhaarId.setText(itemData.get(8));
259 | update=true;
260 | addCBtn.setText("Update Account");
261 |
262 | }
263 |
264 | }
265 |
--------------------------------------------------------------------------------
/src/bankmanagement/BankMain.fxml:
--------------------------------------------------------------------------------
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 |
49 |
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/src/bankmanagement/BankMainController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package bankmanagement;
7 |
8 | import java.net.URL;
9 | import java.util.ResourceBundle;
10 | import javafx.event.ActionEvent;
11 | import javafx.fxml.FXML;
12 | import javafx.fxml.FXMLLoader;
13 | import javafx.fxml.Initializable;
14 | import javafx.scene.control.Label;
15 | import javafx.scene.control.ToggleButton;
16 | import javafx.scene.control.ToggleGroup;
17 | import javafx.scene.layout.AnchorPane;
18 | import javafx.scene.layout.BorderPane;
19 |
20 | /**
21 | *
22 | * @author Chandan Das
23 | */
24 | public class BankMainController implements Initializable {
25 |
26 | private Label label;
27 | @FXML
28 | private ToggleButton acntHoldSceneBtn;
29 | @FXML
30 | private ToggleGroup group1;
31 | @FXML
32 | private ToggleButton brchEmpSceneBtn;
33 | @FXML
34 | private ToggleButton tranSceneBtn;
35 | @FXML
36 | private AnchorPane mainAnchor;
37 | @FXML
38 | private BorderPane rootLayout;
39 | @FXML
40 | private ToggleButton seviceBtn;
41 | @FXML
42 | private ToggleGroup group11;
43 |
44 |
45 |
46 |
47 |
48 | @Override
49 | public void initialize(URL url, ResourceBundle rb) {
50 | changeScene("AccountHolderScene.fxml");
51 | // TODO
52 | }
53 |
54 | @FXML
55 | private void setAcntHoldScene(ActionEvent event) {
56 | changeScene("AccountHolderScene.fxml");
57 | }
58 |
59 | @FXML
60 | private void setBrchEmpScene(ActionEvent event) {
61 | changeScene("BranchEmployeeScene.fxml");
62 | }
63 |
64 | @FXML
65 | private void setTranScene(ActionEvent event) {
66 | changeScene("TransactoinScene.fxml");
67 | }
68 |
69 | public void changeScene(String scenePath){
70 |
71 | FXMLLoader loader;
72 | loader = new FXMLLoader(getClass().getResource(scenePath));
73 | AnchorPane pane = new AnchorPane();
74 | try{
75 | pane = (AnchorPane) loader.load();
76 | rootLayout.setCenter(pane);
77 | }
78 | catch(Exception e){
79 | }
80 |
81 | }
82 |
83 | @FXML
84 | private void setServiceScene(ActionEvent event) {
85 | changeScene("ServiceScene.fxml");
86 |
87 | }
88 |
89 | }
90 |
--------------------------------------------------------------------------------
/src/bankmanagement/BankManagement.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package bankmanagement;
7 |
8 | import javafx.application.Application;
9 | import javafx.fxml.FXMLLoader;
10 | import javafx.scene.Parent;
11 | import javafx.scene.Scene;
12 | import javafx.stage.Stage;
13 |
14 | /**
15 | *
16 | * @author Chandan Das
17 | */
18 | public class BankManagement extends Application {
19 |
20 | @Override
21 | public void start(Stage stage) throws Exception {
22 | Parent root = FXMLLoader.load(getClass().getResource("BankMain.fxml"));
23 |
24 | Scene scene = new Scene(root);
25 |
26 | stage.setScene(scene);
27 | stage.show();
28 | }
29 |
30 | /**
31 | * @param args the command line arguments
32 | */
33 | public static void main(String[] args) {
34 | launch(args);
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/src/bankmanagement/BranchEmployeeScene.fxml:
--------------------------------------------------------------------------------
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 |
45 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/src/bankmanagement/BranchEmployeeSceneController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package bankmanagement;
7 |
8 | import DB.DBConnection;
9 | import DB.DisplayDatabase;
10 | import DB.QueryDatabase;
11 | import java.net.URL;
12 | import java.sql.Connection;
13 | import java.sql.ResultSet;
14 | import java.sql.SQLException;
15 | import java.util.ResourceBundle;
16 | import java.util.logging.Level;
17 | import java.util.logging.Logger;
18 | import javafx.collections.FXCollections;
19 | import javafx.collections.ObservableList;
20 | import javafx.event.ActionEvent;
21 | import javafx.fxml.FXML;
22 | import javafx.fxml.Initializable;
23 | import javafx.scene.control.ComboBox;
24 | import javafx.scene.control.Label;
25 | import javafx.scene.control.TableView;
26 | import javafx.scene.control.TextField;
27 | import javafx.scene.layout.AnchorPane;
28 |
29 | /**
30 | * FXML Controller class
31 | *
32 | * @author Chandan Das
33 | */
34 | public class BranchEmployeeSceneController implements Initializable {
35 |
36 | @FXML
37 | private AnchorPane branchEmpAnchor;
38 | @FXML
39 | private TextField bCode;
40 | @FXML
41 | private TextField bName;
42 | @FXML
43 | private TextField bLoc;
44 | @FXML
45 | private TextField eName;
46 | @FXML
47 | private ComboBox cBranch;
48 | @FXML
49 | private TableView> eTableView;
50 |
51 | /**
52 | * Initializes the controller class.
53 | */
54 | ObservableList branchList = FXCollections.observableArrayList();
55 | DisplayDatabase empData = new DisplayDatabase();
56 | @FXML
57 | private TextField eSName;
58 | @FXML
59 | private Label warnMsg;
60 |
61 | @Override
62 | public void initialize(URL url, ResourceBundle rb) {
63 | ResultSet rs = QueryDatabase.query("Select BCode from branchtable;");
64 | if(rs!=null){
65 | try {
66 | while(rs.next()){
67 | branchList.add(rs.getString(1));
68 | }
69 | } catch (SQLException ex) {
70 | Logger.getLogger(BranchEmployeeSceneController.class.getName()).log(Level.SEVERE, null, ex);
71 | }
72 |
73 | }
74 | cBranch.setItems(branchList);
75 |
76 | empData.buildData(eTableView, "Select * from EmployeeTable Order By (Id) desc;");
77 |
78 | }
79 |
80 | String branchCode="";
81 | String branchName="";
82 | String branchLoc="";
83 |
84 | @FXML
85 | private void addBranch(ActionEvent event) {
86 | branchCode = bCode.getText();
87 | branchName = bName.getText();
88 | branchLoc = bLoc.getText();
89 |
90 | if(branchCode==null || branchCode.isEmpty()){
91 | warnMsg.setText("Enter Branch Code.");
92 | bCode.requestFocus();
93 | return;
94 | }
95 | if(branchName==null || branchName.isEmpty()){
96 | warnMsg.setText("Enter Branch Name.");
97 | bName.requestFocus();
98 | return;
99 | }
100 | if(branchLoc==null || branchLoc.isEmpty()){
101 | warnMsg.setText("Enter Branch Location.");
102 | bLoc.requestFocus();
103 | return;
104 | }
105 |
106 | Connection c;
107 | try{
108 | c = DBConnection.connect();
109 | String query = "INSERT INTO BranchTable (Name,BCode,Address) VALUES("+
110 | "'"+branchName+"',\n" +
111 | "'"+branchCode+"',\n" +
112 | "'"+branchLoc+"');";
113 |
114 | c.createStatement().execute(query);
115 |
116 | c.close();
117 |
118 | } catch (SQLException ex) {
119 | Logger.getLogger(BranchEmployeeSceneController.class.getName()).log(Level.SEVERE, null, ex);
120 | }
121 |
122 | bName.clear();
123 | bCode.clear();
124 | bLoc.clear();
125 |
126 | branchList.add(branchCode);
127 |
128 |
129 |
130 |
131 | }
132 |
133 | String empName="";
134 | String empBranch="";
135 |
136 | @FXML
137 | private void addEmployee(ActionEvent event) {
138 |
139 | empName = eName.getText();
140 | branchCode = cBranch.getValue();
141 |
142 | if(branchCode==null || branchCode.isEmpty()){
143 | warnMsg.setText("Select Branch Code.");
144 | cBranch.requestFocus();
145 | return;
146 | }
147 | if(empName==null || empName.isEmpty()){
148 | warnMsg.setText("Enter Employee's Name.");
149 | eName.requestFocus();
150 | return;
151 | }
152 |
153 |
154 | Connection c;
155 | try{
156 | c = DBConnection.connect();
157 | String query = "INSERT INTO EmployeeTable (Name,Branch) VALUES("+
158 | "'"+empName+"',\n" +
159 | "'"+branchCode+"');";
160 |
161 | c.createStatement().execute(query);
162 |
163 | c.close();
164 |
165 | } catch (SQLException ex) {
166 | Logger.getLogger(BranchEmployeeSceneController.class.getName()).log(Level.SEVERE, null, ex);
167 | }
168 |
169 | eName.clear();
170 |
171 |
172 | empData.buildData(eTableView, "Select * from EmployeeTable Order By (Id) desc;");
173 |
174 |
175 | }
176 |
177 | @FXML
178 | private void searchEmployee(ActionEvent event) {
179 |
180 | String query="";
181 | String name = eSName.getText();
182 | if(name!=null && !name.isEmpty()){
183 | query = "Select * from EmployeeTable where Name Like '%"+name+"%';";
184 |
185 | }else{
186 | query = "Select * from EmployeeTable;";
187 |
188 | }
189 |
190 |
191 | empData.buildData(eTableView,query);
192 | }
193 |
194 |
195 |
196 | }
197 |
--------------------------------------------------------------------------------
/src/bankmanagement/ServiceScene.fxml:
--------------------------------------------------------------------------------
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 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
--------------------------------------------------------------------------------
/src/bankmanagement/ServiceSceneController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package bankmanagement;
7 |
8 | import DB.DBConnection;
9 | import DB.DeleteDatabase;
10 | import DB.DisplayDatabase;
11 | import DB.QueryDatabase;
12 | import java.net.URL;
13 | import java.sql.Connection;
14 | import java.sql.PreparedStatement;
15 | import java.sql.ResultSet;
16 | import java.sql.SQLException;
17 | import java.time.LocalDate;
18 | import java.util.ResourceBundle;
19 | import java.util.logging.Level;
20 | import java.util.logging.Logger;
21 | import javafx.collections.FXCollections;
22 | import javafx.collections.ObservableList;
23 | import javafx.event.ActionEvent;
24 | import javafx.fxml.FXML;
25 | import javafx.fxml.Initializable;
26 | import javafx.scene.control.Button;
27 | import javafx.scene.control.DatePicker;
28 | import javafx.scene.control.Label;
29 | import javafx.scene.control.TableView;
30 | import javafx.scene.control.TextField;
31 | import org.controlsfx.control.textfield.AutoCompletionBinding;
32 | import org.controlsfx.control.textfield.TextFields;
33 |
34 | /**
35 | * FXML Controller class
36 | *
37 | * @author Chandan Das
38 | */
39 | public class ServiceSceneController implements Initializable {
40 |
41 | @FXML
42 | private Button addServBtn;
43 | @FXML
44 | private Label sWarnMsg;
45 | @FXML
46 | private Button srchTranServBtn;
47 |
48 | /**
49 | * Initializes the controller class.
50 | */
51 | DisplayDatabase tData = new DisplayDatabase();
52 | ObservableList accList = FXCollections.observableArrayList();
53 | @FXML
54 | private TextField sName;
55 | @FXML
56 | private TextField sAmount;
57 | @FXML
58 | private TextField sDesc;
59 | @FXML
60 | private TextField sAccNum;
61 | @FXML
62 | private DatePicker sDate;
63 | @FXML
64 | private TextField searchAccNum;
65 | @FXML
66 | private TableView> sTableView;
67 | @Override
68 | public void initialize(URL url, ResourceBundle rb) {
69 | // TODO
70 | ResultSet rs = QueryDatabase.query("Select Account_Number from accounttable;");
71 | if(rs!=null){
72 | try {
73 | while(rs.next()){
74 | accList.add(rs.getString(1));
75 | }
76 | } catch (SQLException ex) {
77 | Logger.getLogger(TransactoinSceneController.class.getName()).log(Level.SEVERE, null, ex);
78 | }
79 |
80 | }
81 |
82 | AutoCompletionBinding autoT = TextFields.bindAutoCompletion(sAccNum,accList);
83 |
84 |
85 | tData.buildData(sTableView, "Select * from serviceTable");
86 | }
87 |
88 |
89 | @FXML
90 | private void searchS(ActionEvent event) {
91 |
92 | String query = "Select * from servicetable Where ;";
93 | String accNum = searchAccNum.getText();
94 | if(accNum == null || accNum.isEmpty()){
95 | query = "Select * from servicetable;";
96 | }else{
97 | query+="Account_Num='"+accNum+"';";
98 | }
99 |
100 | tData.buildData(sTableView, query);
101 | }
102 |
103 | @FXML
104 | private void addService(ActionEvent event) {
105 | LocalDate date = sDate.getValue();
106 | String accNum = sAccNum.getText();
107 | String name = sName.getText();
108 | String amount = sAmount.getText();
109 | String desc = sDesc.getText();
110 |
111 | if(date==null){
112 | sWarnMsg.setText("Please Enter Date.");
113 | sDate.requestFocus();
114 | return;
115 | }
116 |
117 | if(accNum==null || accNum.isEmpty()){
118 | sWarnMsg.setText("Please Enter Account Number.");
119 | sAccNum.requestFocus();
120 | return;
121 | }
122 |
123 | if(name==null || name.isEmpty()){
124 | sWarnMsg.setText("Please Enter Name of Service.");
125 | sName.requestFocus();
126 | return;
127 | }
128 |
129 | if(amount==null || amount.isEmpty()){
130 | sWarnMsg.setText("Please Enter Amount.");
131 | sAmount.requestFocus();
132 | return;
133 | }
134 |
135 | if(desc==null || desc.isEmpty()){
136 | sWarnMsg.setText("Please Enter Description.");
137 | sDesc.requestFocus();
138 | return;
139 | }
140 |
141 | double amt = Double.parseDouble(amount);
142 | double balance = 0;
143 |
144 | try{
145 |
146 |
147 | ResultSet rs = QueryDatabase.query("Select Balance from accounttable where Account_Number ='"+accNum+"';");
148 | if(rs!=null){
149 | if(rs.next()){
150 | balance = Double.parseDouble(rs.getString(1));
151 |
152 | if(balance<=amt){
153 | sWarnMsg.setText("There's no enough balance in account.");
154 | return;
155 | }
156 |
157 | }else{
158 | sWarnMsg.setText("Invalid account number.");
159 | return;
160 | }
161 | }else{
162 | sWarnMsg.setText("invalid account number.");
163 | return;
164 | }
165 |
166 | Connection c;
167 |
168 | c = DBConnection.connect();
169 | String query = "INSERT INTO transactiontable (Date,Account_Num,Transaction_Type,Amount)VALUES("+
170 | "'"+date+"',\n" +
171 | "'"+accNum+"',\n" +
172 | "'Debit',\n" +
173 | "'"+amt+"');";
174 | PreparedStatement ps = c.prepareStatement(query,PreparedStatement.RETURN_GENERATED_KEYS);
175 | ps.execute();
176 | rs = ps.getGeneratedKeys();
177 | rs.next();
178 | String tId = rs.getString(1);
179 |
180 |
181 | balance-=amt;
182 |
183 |
184 | query = "Update accounttable set Balance='"+balance+"' where Account_Number='"+accNum+"';";
185 | c.createStatement().execute(query);
186 |
187 | query = "INSERT INTO Servicetable (Date,Account_Num,ServiceName,Description,Amount,TransactionId)VALUES("+
188 | "'"+date+"',\n" +
189 | "'"+accNum+"',\n" +
190 | "'"+name+"',\n" +
191 | "'"+desc+"',\n" +
192 | "'"+amt+"',\n" +
193 | "'"+tId+"');";
194 | c.createStatement().execute(query);
195 |
196 | c.close();
197 | } catch (SQLException ex) {
198 | Logger.getLogger(TransactoinSceneController.class.getName()).log(Level.SEVERE, null, ex);
199 | }
200 |
201 |
202 | tData.buildData(sTableView, "Select * from servicetable");
203 |
204 | clearFields();
205 |
206 | }
207 |
208 | private void clearFields() {
209 | sDate.setValue(LocalDate.now());
210 | sAccNum.clear();
211 | sName.clear();
212 | sAmount.clear();
213 | sDesc.clear();
214 |
215 | }
216 |
217 | @FXML
218 | private void deleteService(ActionEvent event) {
219 |
220 | try {
221 | int index = sTableView.getSelectionModel().getFocusedIndex();
222 | ObservableList data = tData.getData();
223 | ObservableList itemData = data.get(index);
224 |
225 | //transaction ID
226 | int tId = Integer.parseInt(itemData.get(5));
227 |
228 |
229 | Connection c;
230 |
231 | c = DBConnection.connect();
232 | String query="";
233 |
234 | query = "Update accounttable set Balance=Balance+"+itemData.get(4)+" where Account_Number='"+itemData.get(1)+"';";
235 |
236 | c.createStatement().execute(query);
237 |
238 |
239 |
240 | c.close();
241 | //Delete the transaction , which will auto delete the service provided as it's a foreign key.
242 | DeleteDatabase.deleteRecord(tId, "Transactiontable");
243 |
244 | tData.buildData(sTableView, "Select * from servicetable;");
245 | } catch (SQLException ex) {
246 | Logger.getLogger(TransactoinSceneController.class.getName()).log(Level.SEVERE, null, ex);
247 | }
248 |
249 |
250 |
251 | }
252 | }
253 |
--------------------------------------------------------------------------------
/src/bankmanagement/TransactoinScene.fxml:
--------------------------------------------------------------------------------
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 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
--------------------------------------------------------------------------------
/src/bankmanagement/TransactoinSceneController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * To change this license header, choose License Headers in Project Properties.
3 | * To change this template file, choose Tools | Templates
4 | * and open the template in the editor.
5 | */
6 | package bankmanagement;
7 |
8 | import DB.DBConnection;
9 | import DB.DeleteDatabase;
10 | import DB.DisplayDatabase;
11 | import DB.QueryDatabase;
12 | import java.net.URL;
13 | import java.sql.Connection;
14 | import java.sql.ResultSet;
15 | import java.sql.SQLException;
16 | import java.time.LocalDate;
17 | import java.util.ResourceBundle;
18 | import java.util.logging.Level;
19 | import java.util.logging.Logger;
20 | import javafx.collections.FXCollections;
21 | import javafx.collections.ObservableList;
22 | import javafx.event.ActionEvent;
23 | import javafx.fxml.FXML;
24 | import javafx.fxml.Initializable;
25 | import javafx.scene.control.Button;
26 | import javafx.scene.control.ComboBox;
27 | import javafx.scene.control.DatePicker;
28 | import javafx.scene.control.Label;
29 | import javafx.scene.control.TableView;
30 | import javafx.scene.control.TextField;
31 | import javafx.scene.layout.AnchorPane;
32 | import org.controlsfx.control.textfield.AutoCompletionBinding;
33 | import org.controlsfx.control.textfield.TextFields;
34 |
35 | /**
36 | * FXML Controller class
37 | *
38 | * @author Chandan Das
39 | */
40 |
41 | public class TransactoinSceneController implements Initializable {
42 |
43 | @FXML
44 | private AnchorPane tranServAnchor;
45 | @FXML
46 | private TextField tAccNum;
47 | @FXML
48 | private Button addTranBtn;
49 |
50 | @FXML
51 | private Button srchTranServBtn1;
52 |
53 | /**
54 | * Initializes the controller class.
55 | */
56 |
57 | DisplayDatabase tData = new DisplayDatabase();
58 | ObservableList accList = FXCollections.observableArrayList();
59 | ObservableList typeList = FXCollections.observableArrayList();
60 | @FXML
61 | private TextField tAmount;
62 | @FXML
63 | private ComboBox ctType;
64 | @FXML
65 | private Label tWarnMsg;
66 | @FXML
67 | private DatePicker tDate;
68 | @FXML
69 | private TableView> tTableView;
70 | @FXML
71 | private TextField sAccNum;
72 | @Override
73 | public void initialize(URL url, ResourceBundle rb) {
74 | // TODO
75 | ResultSet rs = QueryDatabase.query("Select Account_Number from accounttable;");
76 | if(rs!=null){
77 | try {
78 | while(rs.next()){
79 | accList.add(rs.getString(1));
80 | }
81 | } catch (SQLException ex) {
82 | Logger.getLogger(TransactoinSceneController.class.getName()).log(Level.SEVERE, null, ex);
83 | }
84 |
85 | }
86 |
87 | AutoCompletionBinding autoT = TextFields.bindAutoCompletion(tAccNum,accList);
88 |
89 | typeList.add("Credit");
90 | typeList.add("Debit");
91 | ctType.setItems(typeList);
92 | tData.buildData(tTableView, "Select * from transactiontable");
93 |
94 | }
95 |
96 |
97 | @FXML
98 | private void AddTransaction(ActionEvent event) {
99 | LocalDate date = tDate.getValue();
100 | String accNum = tAccNum.getText();
101 | String tType = ctType.getValue();
102 | String amount = tAmount.getText();
103 |
104 | if(date==null){
105 | tWarnMsg.setText("Please Enter Date.");
106 | tDate.requestFocus();
107 | return;
108 | }
109 |
110 | if(accNum==null || accNum.isEmpty()){
111 | tWarnMsg.setText("Please Enter Account Number.");
112 | tAccNum.requestFocus();
113 | return;
114 | }
115 |
116 | if(tType==null || tType.isEmpty()){
117 | tWarnMsg.setText("Please Enter Transaction Type.");
118 | ctType.requestFocus();
119 | return;
120 | }
121 |
122 | if(amount==null || amount.isEmpty()){
123 | tWarnMsg.setText("Please Enter Amount.");
124 | tAmount.requestFocus();
125 | return;
126 | }
127 |
128 | double amt = Double.parseDouble(amount);
129 | double balance =0;
130 | try{
131 |
132 |
133 | ResultSet rs = QueryDatabase.query("Select Balance from accounttable where Account_Number ='"+accNum+"';");
134 | if(rs!=null){
135 | if(rs.next()){
136 | balance = Double.parseDouble(rs.getString(1));
137 | if(tType.equalsIgnoreCase("Debit")){
138 | if(balance<=0){
139 | tWarnMsg.setText("There's no balance in account.");
140 | return;
141 | }
142 | }
143 | }else{
144 | tWarnMsg.setText("Invalid account number.");
145 | return;
146 | }
147 | }else{
148 | tWarnMsg.setText("invalid account number.");
149 | return;
150 | }
151 |
152 |
153 |
154 |
155 | Connection c;
156 |
157 | c = DBConnection.connect();
158 | String query = "INSERT INTO transactiontable (Date,Account_Num,Transaction_Type,Amount)VALUES("+
159 | "'"+date+"',\n" +
160 | "'"+accNum+"',\n" +
161 | "'"+tType+"',\n" +
162 | "'"+amt+"');";
163 |
164 | c.createStatement().execute(query);
165 | if(tType.equalsIgnoreCase("Debit")){
166 | balance-=amt;
167 | }else{
168 | balance+=amt;
169 | }
170 |
171 | query = "Update accounttable set Balance='"+balance+"' where Account_Number='"+accNum+"';";
172 | c.createStatement().execute(query);
173 |
174 | c.close();
175 | } catch (SQLException ex) {
176 | Logger.getLogger(TransactoinSceneController.class.getName()).log(Level.SEVERE, null, ex);
177 | }
178 |
179 |
180 | tData.buildData(tTableView, "Select * from transactiontable");
181 |
182 | clearFields();
183 |
184 | }
185 |
186 |
187 | @FXML
188 | private void searchT(ActionEvent event) {
189 | String query = "Select * from transactiontable Where ;";
190 | String accNum = sAccNum.getText();
191 | if(accNum == null || accNum.isEmpty()){
192 | query = "Select * from transactiontable;";
193 | }else{
194 | query+="Account_Num='"+accNum+"';";
195 | }
196 |
197 | tData.buildData(tTableView, query);
198 | }
199 |
200 | private void clearFields() {
201 |
202 | tDate.setValue(LocalDate.now());
203 | tAccNum.clear();
204 | ctType.setValue("");
205 | tAmount.clear();
206 | tWarnMsg.setText("");
207 |
208 |
209 | }
210 |
211 | @FXML
212 | private void deleteTransaction(ActionEvent event) {
213 |
214 | try {
215 | int index = tTableView.getSelectionModel().getFocusedIndex();
216 | ObservableList data = tData.getData();
217 | ObservableList itemData = data.get(index);
218 |
219 | int id = Integer.parseInt(itemData.get(0));
220 |
221 |
222 | Connection c;
223 |
224 | c = DBConnection.connect();
225 | String query="";
226 | if(itemData.get(3).equalsIgnoreCase("Debit")){
227 |
228 | query = "Update accounttable set Balance=Balance+"+itemData.get(4)+" where Account_Number='"+itemData.get(2)+"';";
229 | }else{
230 | query = "Update accounttable set Balance=Balance-"+itemData.get(4)+" where Account_Number='"+itemData.get(2)+"';";
231 |
232 | }
233 |
234 | c.createStatement().execute(query);
235 |
236 | c.close();
237 |
238 | DeleteDatabase.deleteRecord(id, "Transactiontable");
239 | tData.buildData(tTableView, "Select * from transactiontable;");
240 | } catch (SQLException ex) {
241 | Logger.getLogger(TransactoinSceneController.class.getName()).log(Level.SEVERE, null, ex);
242 | }
243 |
244 |
245 |
246 |
247 | }
248 |
249 | }
250 |
--------------------------------------------------------------------------------
/src/bankmanagement/style.css:
--------------------------------------------------------------------------------
1 | /*
2 | To change this license header, choose License Headers in Project Properties.
3 | To change this template file, choose Tools | Templates
4 | and open the template in the editor.
5 | */
6 | /*
7 |
8 | Author : Chandan Das
9 | */
10 |
11 | .toggle-button {
12 | -fx-color: #003333;
13 | }
14 |
15 | .toggle-button:selected {
16 | -fx-color: #918c8f;
17 | -fx-background-color:
18 | -fx-shadow-highlight-color,
19 | linear-gradient(to bottom, derive(-fx-color,-22%) 0%, derive(-fx-color,-15%) 100%),
20 | linear-gradient(to bottom, derive(-fx-color,-15%) 0%, derive(-fx-color,-10%) 50%, derive(-fx-color,-8%) 98%, derive(-fx-color,-12%) 100%);
21 | }
22 |
23 | .toggle-button:selected:focused {
24 | -fx-color: #918c8f;
25 | -fx-background-color:
26 | -fx-focus-color,
27 | linear-gradient(to bottom, derive(-fx-color,-22%) 0%, derive(-fx-color,-15%) 100%),
28 | linear-gradient(to bottom, derive(-fx-color,-15%) 0%, derive(-fx-color,-10%) 50%, derive(-fx-color,-8%) 98%, derive(-fx-color,-12%) 100%);
29 | }
--------------------------------------------------------------------------------