Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
student-attendance-detail-service
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shaphen Pangburn
student-attendance-detail-service
Commits
a9c7afcb
Commit
a9c7afcb
authored
Apr 02, 2021
by
Shaphen Pangburn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[whole team]: Successfully seed and use CRU operations on seeded Objects
parent
38d030f7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
22 deletions
+17
-22
Attendance.java
...ava/com/nisum/attendance/attendance/model/Attendance.java
+7
-5
attendance.sql
attendance/src/main/resources/attendance.sql
+10
-17
No files found.
attendance/src/main/java/com/nisum/attendance/attendance/model/Attendance.java
View file @
a9c7afcb
package
com
.
nisum
.
attendance
.
attendance
.
model
;
package
com
.
nisum
.
attendance
.
attendance
.
model
;
import
com.sun.org.apache.xpath.internal.operations.Bool
;
import
javax.persistence.Entity
;
import
javax.persistence.Entity
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GeneratedValue
;
...
@@ -16,18 +15,21 @@ public class Attendance {
...
@@ -16,18 +15,21 @@ public class Attendance {
private
Long
Id
;
private
Long
Id
;
private
Long
studentId
;
private
Long
studentId
;
Date
attendanceDate
;
Date
attendanceDate
;
Bool
didAttend
;
Bool
ean
didAttend
;
public
Attendance
(
Date
attendanceDate
,
Bool
didAttend
)
{
public
Attendance
(){}
public
Attendance
(
Long
studentId
,
Date
attendanceDate
,
Boolean
didAttend
)
{
this
.
studentId
=
studentId
;
this
.
attendanceDate
=
attendanceDate
;
this
.
attendanceDate
=
attendanceDate
;
this
.
didAttend
=
didAttend
;
this
.
didAttend
=
didAttend
;
}
}
public
void
setDidAttend
(
Bool
didAttend
)
{
public
void
setDidAttend
(
Bool
ean
didAttend
)
{
this
.
didAttend
=
didAttend
;
this
.
didAttend
=
didAttend
;
}
}
public
Bool
getDidAttend
()
{
public
Bool
ean
getDidAttend
()
{
return
didAttend
;
return
didAttend
;
}
}
...
...
attendance/src/main/resources/attendance.sql
View file @
a9c7afcb
...
@@ -7,20 +7,13 @@ CREATE TABLE ATTENDANCE (
...
@@ -7,20 +7,13 @@ CREATE TABLE ATTENDANCE (
DID_ATTEND
BOOLEAN
DEFAULT
FALSE
DID_ATTEND
BOOLEAN
DEFAULT
FALSE
);
);
--CREATE TABLE tutorials_tbl (
INSERT
INTO
ATTENDANCE
VALUES
-- id INT NOT NULL,
(
1
,
10
,
'0001-02-01'
,
TRUE
),
-- title VARCHAR(50) NOT NULL,
(
2
,
20
,
'0001-02-02'
,
FALSE
),
-- author VARCHAR(20) NOT NULL,
(
3
,
30
,
'0001-02-03'
,
TRUE
),
-- submission_date DATE
(
4
,
30
,
'0001-02-04'
,
TRUE
),
--);
(
5
,
20
,
'0001-02-03'
,
TRUE
),
--
(
6
,
10
,
'0001-02-02'
,
FALSE
),
--INSERT INTO ATTENDANCE VALUES
(
7
,
10
,
'0001-02-03'
,
TRUE
),
-- (1, 10, 0001-02-01, true),
(
8
,
30
,
'0001-02-05'
,
TRUE
),
-- (2, 20, 0001-02-02, false),
(
9
,
10
,
'0001-02-04'
,
FALSE
);
-- (3, 30, 0001-02-03, true),
\ No newline at end of file
-- (4, 30, 0001-02-04, true),
-- (5, 20, 0001-02-03, true),
-- (6, 10, 0001-02-02, false),
-- (7, 10, 0001-02-03, true),
-- (8, 30, 0001-02-05, true),
-- (9, 10, 0001-02-04, false);
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment