Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
BookingMyHrManagement
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
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
Chanachai
BookingMyHrManagement
Commits
08fda832
Commit
08fda832
authored
Dec 09, 2021
by
DESKTOP-HF0LVOG\myhr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update หน้าจองเบิก
parent
513f6499
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
60 additions
and
8 deletions
+60
-8
equirment.model.ts
src/app/models/equirment.model.ts
+1
-1
roomDetail.model.ts
src/app/models/roomDetail.model.ts
+3
-1
admin-equirment.component.ts
src/app/pages/admin-equirment/admin-equirment.component.ts
+1
-1
admin-pending.component.ts
src/app/pages/admin-pending/admin-pending.component.ts
+6
-0
equipment.component.html
src/app/pages/equipment/equipment.component.html
+0
-0
equipment.component.ts
src/app/pages/equipment/equipment.component.ts
+44
-2
lend-page.component.ts
src/app/pages/lend-page/lend-page.component.ts
+1
-1
pending.component.ts
src/app/pages/pending/pending.component.ts
+1
-1
item-detail.service.ts
src/app/service/item-detail.service.ts
+1
-1
room-detail.service.ts
src/app/service/room-detail.service.ts
+2
-0
nopic.jpg
src/assets/img/nopic.jpg
+0
-0
No files found.
src/app/models/equirment.model.ts
View file @
08fda832
import
{
CategoryModel
}
from
"./
I
temDetail.model"
;
import
{
CategoryModel
}
from
"./
i
temDetail.model"
;
export
class
Equirment
{
eqId
:
number
;
...
...
src/app/models/roomDetail.model.ts
View file @
08fda832
...
...
@@ -17,7 +17,8 @@ export class RoomDetail {
second
:
number
;
};
rStatus
:
string
;
rTelephone
:
number
;
rTelephone
:
string
;
email
:
undefined
;
Remark
:
string
;
constructor
(
init
?:
RoomDetail
)
{
Object
.
assign
(
this
,
init
);
...
...
@@ -28,6 +29,7 @@ export class RoomDetail {
this
.
eDate
=
''
;
this
.
rStatus
=
''
;
this
.
rTelephone
=
undefined
;
this
.
email
=
undefined
;
this
.
Remark
=
''
;
}
}
...
...
src/app/pages/admin-equirment/admin-equirment.component.ts
View file @
08fda832
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
NgbModal
,
ModalDismissReasons
}
from
'@ng-bootstrap/ng-bootstrap'
;
import
{
Equirment
}
from
'src/app/models/equirment.model'
;
import
{
ItemDetail
}
from
'src/app/models/
I
temDetail.model'
;
import
{
ItemDetail
}
from
'src/app/models/
i
temDetail.model'
;
import
{
RoomDetail
}
from
'src/app/models/RoomDetail.model'
;
import
{
MyRoom
,
Room
}
from
'src/app/models/rooms.model'
;
import
{
EquirmentService
}
from
'src/app/service/equirment.service'
;
...
...
src/app/pages/admin-pending/admin-pending.component.ts
View file @
08fda832
...
...
@@ -7,6 +7,7 @@ import { ItemDetailService } from 'src/app/service/item-detail.service';
import
{
RoomDetail
}
from
'src/app/models/roomDetail.model'
;
import
{
RoomDetailService
}
from
'src/app/service/room-detail.service'
;
import
{
MyRoom
,
Room
}
from
'src/app/models/rooms.model'
;
import
{
FormControl
,
Validators
}
from
'@angular/forms'
;
@
Component
({
selector
:
'app-admin-pending'
,
...
...
@@ -62,6 +63,9 @@ export class AdminPendingComponent implements OnInit {
thStime
:
string
;
thEtime
:
string
;
thtimeChange
(
time
:
string
,
item
:
any
){
let
timeSplit
=
time
.
split
(
":"
)
item
.
hour
=
parseInt
(
timeSplit
[
0
])
...
...
@@ -70,6 +74,8 @@ export class AdminPendingComponent implements OnInit {
}
constructor
(
private
calendar
:
NgbCalendar
,
public
formatter
:
NgbDateParserFormatter
,
private
modalService
:
NgbModal
,
private
ItemDetailService
:
ItemDetailService
,
private
RoomDetailService
:
RoomDetailService
)
{
this
.
fromDate
=
calendar
.
getToday
();
this
.
toDate
=
calendar
.
getNext
(
calendar
.
getToday
(),
'd'
,
10
);
...
...
src/app/pages/equipment/equipment.component.html
View file @
08fda832
This diff is collapsed.
Click to expand it.
src/app/pages/equipment/equipment.component.ts
View file @
08fda832
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
NgbModal
,
ModalDismissReasons
}
from
'@ng-bootstrap/ng-bootstrap'
;
import
{
Equirment
}
from
'src/app/models/equirment.model'
;
import
{
ItemDetail
}
from
'src/app/models/
I
temDetail.model'
;
import
{
ItemDetail
}
from
'src/app/models/
i
temDetail.model'
;
import
{
RoomDetail
}
from
'src/app/models/RoomDetail.model'
;
import
{
MyRoom
,
Room
}
from
'src/app/models/rooms.model'
;
import
{
EquirmentService
}
from
'src/app/service/equirment.service'
;
import
{
ItemDetailService
}
from
'src/app/service/item-detail.service'
;
import
{
RoomService
}
from
'src/app/service/room.service'
;
import
{
RoomDetailService
}
from
'src/app/service/room-detail.service'
;
import
{
FormBuilder
,
FormControl
,
FormGroup
,
Validators
}
from
'@angular/forms'
;
@
Component
({
...
...
@@ -31,13 +32,54 @@ export class EquipmentComponent implements OnInit {
modelItemDetail
=
new
ItemDetail
();
modelRoomDetail
=
new
RoomDetail
();
constructor
(
private
modalService
:
NgbModal
,
private
equirmentService
:
EquirmentService
,
private
roomService
:
RoomService
,
private
ItemDetailService
:
ItemDetailService
,
private
RoomDetailService
:
RoomDetailService
)
{
myFormRoom
:
FormGroup
;
myFormEquir
:
FormGroup
;
constructor
(
private
modalService
:
NgbModal
,
private
equirmentService
:
EquirmentService
,
private
roomService
:
RoomService
,
private
ItemDetailService
:
ItemDetailService
,
private
RoomDetailService
:
RoomDetailService
,
private
fb
:
FormBuilder
)
{
}
validate
(){
console
.
log
(
this
.
myFormRoom
.
controls
.
userNameForm
.
status
)
console
.
log
(
this
.
myFormRoom
)
// var form = document.getElementsByClassName('needs-validation')[0] as HTMLFormElement;
// if (form.checkValidity() === false) {
// event.preventDefault();
// event.stopPropagation();
// }
// form.classList.add('was-validated');
}
ngOnInit
()
{
this
.
listEquirmentModel
=
this
.
equirmentService
.
getListEquirment
();
this
.
listRoomModel
=
this
.
roomService
.
getListRoom
();
this
.
myFormRoom
=
new
FormGroup
({
userNameForm
:
new
FormControl
(
''
,[
Validators
.
required
]),
rTelephone
:
new
FormControl
(
''
,[
Validators
.
required
]),
email
:
new
FormControl
(
''
,[
Validators
.
required
,
Validators
.
email
]),
rName
:
new
FormControl
(),
rDesc
:
new
FormControl
(),
sDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
eDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
sTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
eTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
Remark
:
new
FormControl
()
});
this
.
myFormEquir
=
new
FormGroup
({
userNameForm
:
new
FormControl
(
''
,[
Validators
.
required
]),
eTelephone
:
new
FormControl
(
''
,[
Validators
.
required
]),
email
:
new
FormControl
(
''
,[
Validators
.
required
,
Validators
.
email
]),
eqName
:
new
FormControl
(
''
,[
Validators
.
required
]),
eqDesc
:
new
FormControl
(
''
,[
Validators
.
required
]),
sDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
eDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
sTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
eTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
Quantity
:
new
FormControl
(
''
,[
Validators
.
required
]),
Remark
:
new
FormControl
(
''
,[
Validators
.
required
]),
})
}
...
...
src/app/pages/lend-page/lend-page.component.ts
View file @
08fda832
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
ItemDetail
}
from
'src/app/models/
I
temDetail.model'
;
import
{
ItemDetail
}
from
'src/app/models/
i
temDetail.model'
;
@
Component
({
selector
:
'app-lend-page'
,
...
...
src/app/pages/pending/pending.component.ts
View file @
08fda832
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
NgbDate
,
NgbCalendar
,
NgbDateParserFormatter
}
from
'@ng-bootstrap/ng-bootstrap'
;
import
{
NgbModal
,
ModalDismissReasons
}
from
'@ng-bootstrap/ng-bootstrap'
;
import
{
ItemDetail
}
from
'src/app/models/
I
temDetail.model'
;
import
{
ItemDetail
}
from
'src/app/models/
i
temDetail.model'
;
import
{
ItemDetailService
}
from
'src/app/service/item-detail.service'
;
import
{
RoomDetail
}
from
'src/app/models/RoomDetail.model'
;
import
{
RoomDetailService
}
from
'src/app/service/room-detail.service'
;
...
...
src/app/service/item-detail.service.ts
View file @
08fda832
import
{
Injectable
}
from
'@angular/core'
;
import
{
HttpClient
,
HttpHeaders
}
from
'@angular/common/http'
;
import
{
ItemDetail
,
SearchItemDetailModel
}
from
'../models/
I
temDetail.model'
;
import
{
ItemDetail
,
SearchItemDetailModel
}
from
'../models/
i
temDetail.model'
;
@
Injectable
({
providedIn
:
'root'
})
export
class
ItemDetailService
{
...
...
src/app/service/room-detail.service.ts
View file @
08fda832
...
...
@@ -33,6 +33,7 @@ export class RoomDetailService {
},
rStatus
:
'รอการอนุมัติ'
,
rTelephone
:
undefined
,
email
:
undefined
,
Remark
:
'test'
,
},
{
...
...
@@ -60,6 +61,7 @@ export class RoomDetailService {
},
rStatus
:
'รอการอนุมัติ'
,
rTelephone
:
undefined
,
email
:
undefined
,
Remark
:
'test'
,
},
...
...
src/assets/img/nopic.jpg
0 → 100644
View file @
08fda832
1.8 KB
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