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
6fcec8df
Commit
6fcec8df
authored
Dec 13, 2021
by
DESKTOP-HF0LVOG\myhr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update หน้ารายการอนุมัติ admin เหลือสถานะ
parent
716d2d9e
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
102 additions
and
94 deletions
+102
-94
equirment.model.ts
src/app/models/equirment.model.ts
+1
-1
rooms.model.ts
src/app/models/rooms.model.ts
+2
-2
admin-pending.component.html
src/app/pages/admin-pending/admin-pending.component.html
+32
-25
admin-pending.component.ts
src/app/pages/admin-pending/admin-pending.component.ts
+56
-52
equipment.component.html
src/app/pages/equipment/equipment.component.html
+5
-6
item-detail.service.ts
src/app/service/item-detail.service.ts
+4
-4
room-detail.service.ts
src/app/service/room-detail.service.ts
+2
-4
No files found.
src/app/models/equirment.model.ts
View file @
6fcec8df
...
@@ -12,7 +12,7 @@ export class Equirment {
...
@@ -12,7 +12,7 @@ export class Equirment {
this
.
eqName
=
''
;
this
.
eqName
=
''
;
this
.
eqDesc
=
''
;
this
.
eqDesc
=
''
;
this
.
eqType
=
''
;
this
.
eqType
=
''
;
this
.
eqPic
=
''
;
this
.
eqPic
=
'
assets/img/nopic.jpg
'
;
}
}
}
}
...
...
src/app/models/rooms.model.ts
View file @
6fcec8df
...
@@ -19,10 +19,10 @@ export class MyRoom implements Room{
...
@@ -19,10 +19,10 @@ export class MyRoom implements Room{
// Object.assign(this, init);
// Object.assign(this, init);
this
.
rId
=
init
?.
rId
!
;
this
.
rId
=
init
?.
rId
!
;
this
.
rName
=
init
?.
rName
!
;
this
.
rName
=
init
?.
rName
!
;
this
.
rPic
=
''
;
this
.
rPic
=
'
assets/img/nopic.jpg
'
;
this
.
roomLimit
=
0
;
this
.
roomLimit
=
0
;
this
.
rDesc
=
''
;
this
.
rDesc
=
''
;
console
.
log
(
"sssssssssssss"
,
init
)
}
}
}
}
...
...
src/app/pages/admin-pending/admin-pending.component.html
View file @
6fcec8df
...
@@ -90,11 +90,11 @@
...
@@ -90,11 +90,11 @@
<td>
{{ item.room.rName }}
</td>
<td>
{{ item.room.rName }}
</td>
<td>
{{ item.room.rDesc }}
</td>
<td>
{{ item.room.rDesc }}
</td>
<td>
{{ item.userName }}
</td>
<td>
{{ item.userName }}
</td>
<td>
{{ item.sDate
.replaceAll("/","-")
}} {{ item.sTime.hour }}:{{
<td>
{{ item.sDate
| date : 'dd/MM/yyyy'
}} {{ item.sTime.hour }}:{{
item.sTime.minute }}
</td>
item.sTime.minute }}
</td>
<td>
{{ item.eDate
.replaceAll("/","-")
}} {{ item.eTime.hour }}:{{
<td>
{{ item.eDate
| date : 'dd/MM/yyyy'
}} {{ item.eTime.hour }}:{{
item.eTime.minute }}
</td>
item.eTime.minute }}
</td>
<td>
{{ item.rStatus }}
</td>
<td>
{{ item.rStatus
==0 ? "รอดำเนินการ" : "อนุมัติ"
}}
</td>
<div
class=
"text-center"
>
<div
class=
"text-center"
>
<button
type=
"button"
class=
"btn btn-info btn-sm btn-circle "
<button
type=
"button"
class=
"btn btn-info btn-sm btn-circle "
style=
"line-height: 0px"
(
click
)="
openRoomDetail
(
Room
,
item
)"
><i
style=
"line-height: 0px"
(
click
)="
openRoomDetail
(
Room
,
item
)"
><i
...
@@ -157,7 +157,7 @@
...
@@ -157,7 +157,7 @@
<td>
{{ item.eDate.replaceAll("/","-")}} {{ item.eTime.hour }}:{{
<td>
{{ item.eDate.replaceAll("/","-")}} {{ item.eTime.hour }}:{{
item.eTime.minute }}
</td>
item.eTime.minute }}
</td>
<td>
{{ item.Quantity }}
</td>
<td>
{{ item.Quantity }}
</td>
<td>
{{ item.eStatus }}
</td>
<td>
{{ item.eStatus
==0 ? "รอดำเนินการ" : "อนุมัติ"
}}
</td>
<div
class=
"text-center"
>
<div
class=
"text-center"
>
<button
type=
"button"
class=
"btn btn-info btn-sm btn-circle "
<button
type=
"button"
class=
"btn btn-info btn-sm btn-circle "
style=
"line-height: 0px"
(
click
)="
openItemDetail
(
lend
,
item
)"
><i
style=
"line-height: 0px"
(
click
)="
openItemDetail
(
lend
,
item
)"
><i
...
@@ -282,21 +282,23 @@
...
@@ -282,21 +282,23 @@
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
" row"
>
<div
class=
" col-md-6 mb-2"
>
<label>
สถานะ
</label>
<select
class=
"form-select form-control"
aria-label=
"Default select example"
[(
ngModel
)]="
modelRoomDetail
.
rStatus
"
formControlName=
"rStatus"
>
<option
value=
"0"
style=
"color: black;"
>
รอดำเนินการ
</option>
<option
value=
"1"
style=
"color: black;"
>
อนุมัติ
</option>
<option
value=
"2"
style=
"color: black;"
>
ยกเลิก
</option>
<option
value=
"3"
style=
"color: black;"
>
สำเร็จแล้ว
</option>
</select>
</div>
</div>
</form>
</form>
<div
class=
" card-footer"
>
<div
class=
" card-footer"
>
<button
class=
" btn btn-fill btn-danger"
type=
"submit"
(
click
)="
save
Room
()"
>
อนุมัติ
</button>
<button
class=
" btn btn-fill btn-danger"
type=
"submit"
(
click
)="
save
Status
()"
>
บันทึก
</button>
<button
class=
" btn btn-fill btn-danger"
type=
"cancel"
<button
class=
" btn btn-fill btn-danger"
type=
"cancel"
(
click
)="
modal
.
dismiss
('
Cross
click
')"
>
ยกเลิก
</button>
(
click
)="
modal
.
dismiss
('
Cross
click
')"
>
ยกเลิก
</button>
<div
ngbDropdown
class=
"d-inline-block"
>
<button
class=
"btn btn-sm btn-outline-primary"
id=
"dropdownBasic1"
ngbDropdownToggle
>
สถานะ
</button>
<div
ngbDropdownMenu
aria-labelledby=
"dropdownBasic1"
>
<button
ngbDropdownItem
>
รอดำเนินการ
</button>
<button
ngbDropdownItem
>
อนุมัติ
</button>
<button
ngbDropdownItem
>
ยกเลิก
</button>
<button
ngbDropdownItem
>
สำเร็จแล้ว
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -400,21 +402,26 @@
...
@@ -400,21 +402,26 @@
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
" row"
>
<div
class=
" col-md-6 mb-2"
>
<div
class=
" form-group"
>
<label>
สถานะ
</label>
<br>
<select
class=
"form-select form-control"
aria-label=
"Default select example"
[(
ngModel
)]="
modelItemDetail
.
eStatus
"
formControlName=
"eStatus"
>
<option
value=
"0"
style=
"color: black;"
>
รอดำเนินการ
</option>
<option
value=
"1"
style=
"color: black;"
>
อนุมัติ
</option>
<option
value=
"2"
style=
"color: black;"
>
ยกเลิก
</option>
<option
value=
"3"
style=
"color: black;"
>
สำเร็จแล้ว
</option>
</select>
</div>
</div>
</div>
</form>
</form>
<div
class=
" card-footer"
>
<div
class=
" card-footer"
>
<button
class=
" btn btn-fill btn-danger"
type=
"submit"
(
click
)="
saveEquirment
()"
>
อนุมัติ
</button>
<button
class=
" btn btn-fill btn-danger"
type=
"submit"
(
click
)="
saveEquirment
()"
>
อนุมัติ
</button>
<button
class=
" btn btn-fill btn-danger"
type=
"cancel"
<button
class=
" btn btn-fill btn-danger"
type=
"cancel"
(
click
)="
modal
.
dismiss
('
Cross
click
')"
>
ยกเลิก
</button>
(
click
)="
modal
.
dismiss
('
Cross
click
')"
>
ยกเลิก
</button>
<div
ngbDropdown
class=
"d-inline-block"
>
<button
class=
"btn btn-sm btn-outline-primary"
id=
"dropdownBasic1"
ngbDropdownToggle
>
สถานะ
</button>
<div
ngbDropdownMenu
aria-labelledby=
"dropdownBasic1"
>
<button
ngbDropdownItem
>
รอดำเนินการ
</button>
<button
ngbDropdownItem
>
อนุมัติ
</button>
<button
ngbDropdownItem
>
ยกเลิก
</button>
<button
ngbDropdownItem
>
สำเร็จแล้ว
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
src/app/pages/admin-pending/admin-pending.component.ts
View file @
6fcec8df
...
@@ -56,8 +56,8 @@ export class AdminPendingComponent implements OnInit {
...
@@ -56,8 +56,8 @@ export class AdminPendingComponent implements OnInit {
closeResult
=
''
;
closeResult
=
''
;
listitemDetail
:
ItemDetail
[]
=
[];
listitemDetail
:
ItemDetail
[]
=
[];
listroomDetail
:
RoomDetail
[]
=
[];
listroomDetail
:
RoomDetail
[]
=
[];
modelEquirment
=
new
Equirment
();
modelEquirment
=
new
Equirment
();
modelRoom
=
new
MyRoom
();
modelRoom
=
new
MyRoom
();
...
@@ -71,11 +71,10 @@ export class AdminPendingComponent implements OnInit {
...
@@ -71,11 +71,10 @@ export class AdminPendingComponent implements OnInit {
thStime
:
string
;
thStime
:
string
;
thEtime
:
string
;
thEtime
:
string
;
thtimeChange
(
time
:
string
,
item
:
any
)
{
thtimeChange
(
time
:
string
,
item
:
any
)
{
let
timeSplit
=
time
.
split
(
":"
)
let
timeSplit
=
time
.
split
(
":"
)
item
.
hour
=
parseInt
(
timeSplit
[
0
])
item
.
hour
=
parseInt
(
timeSplit
[
0
])
item
.
minute
=
parseInt
(
timeSplit
[
1
])
item
.
minute
=
parseInt
(
timeSplit
[
1
])
console
.
log
(
this
.
modelRoomDetail
)
}
}
...
@@ -110,20 +109,18 @@ export class AdminPendingComponent implements OnInit {
...
@@ -110,20 +109,18 @@ export class AdminPendingComponent implements OnInit {
this
.
closeResult
=
`Dismissed
${
this
.
getDismissReason
(
reason
)}
`
;
this
.
closeResult
=
`Dismissed
${
this
.
getDismissReason
(
reason
)}
`
;
});
});
}
}
date
=
'10-12-2561'
date
=
'10-12-2561'
show
(
a
:
string
){
console
.
log
(
a
)
}
sDate
=
""
sDate
=
""
eDate
=
""
eDate
=
""
openItemDetail
(
content
:
string
,
item
:
ItemDetail
)
{
openItemDetail
(
content
:
string
,
item
:
ItemDetail
)
{
this
.
modelItemDetail
=
item
;
this
.
modelItemDetail
=
item
;
this
.
thStime
=
this
.
modelItemDetail
.
sTime
.
hour
+
':'
+
this
.
modelItemDetail
.
sTime
.
minute
this
.
thStime
=
this
.
modelItemDetail
.
sTime
.
hour
+
':'
+
this
.
modelItemDetail
.
sTime
.
minute
this
.
thEtime
=
this
.
modelItemDetail
.
eTime
.
hour
+
':'
+
this
.
modelItemDetail
.
eTime
.
minute
this
.
thEtime
=
this
.
modelItemDetail
.
eTime
.
hour
+
':'
+
this
.
modelItemDetail
.
eTime
.
minute
let
S
Date
=
this
.
modelItemDetail
.
sDate
.
split
(
'/'
)
let
s
Date
=
this
.
modelItemDetail
.
sDate
.
split
(
'/'
)
this
.
sDate
=
SDate
[
2
]
+
"-"
+
SDate
[
1
]
+
"-"
+
SDate
[
0
]
this
.
sDate
=
sDate
[
0
]
+
"-"
+
sDate
[
1
]
+
"-"
+
sDate
[
2
]
let
E
Date
=
this
.
modelItemDetail
.
eDate
.
split
(
'/'
)
let
e
Date
=
this
.
modelItemDetail
.
eDate
.
split
(
'/'
)
this
.
eDate
=
EDate
[
2
]
+
"-"
+
EDate
[
1
]
+
"-"
+
EDate
[
0
]
this
.
eDate
=
eDate
[
0
]
+
"-"
+
eDate
[
1
]
+
"-"
+
eDate
[
2
]
this
.
modalService
.
open
(
content
,
{
ariaLabelledBy
:
'modal-basic-title'
}).
result
.
then
((
result
)
=>
{
this
.
modalService
.
open
(
content
,
{
ariaLabelledBy
:
'modal-basic-title'
}).
result
.
then
((
result
)
=>
{
this
.
closeResult
=
`Closed with:
${
result
}
`
;
this
.
closeResult
=
`Closed with:
${
result
}
`
;
},
(
reason
)
=>
{
},
(
reason
)
=>
{
...
@@ -131,27 +128,26 @@ export class AdminPendingComponent implements OnInit {
...
@@ -131,27 +128,26 @@ export class AdminPendingComponent implements OnInit {
});
});
}
}
rDate
(
item
:
string
,
item2
:
string
){
rDate
(
item
:
string
,
item2
:
string
)
{
let
Dates
=
item
.
split
(
"-"
)
let
Dates
=
item
.
split
(
"-"
)
let
dates
=
Dates
[
2
]
+
"/"
+
Dates
[
1
]
+
"/"
+
Dates
[
0
]
let
dates
=
Dates
[
0
]
+
"/"
+
Dates
[
1
]
+
"/"
+
Dates
[
2
]
if
(
item2
==
"sdate"
)
{
if
(
item2
==
"sdate"
)
{
this
.
modelItemDetail
.
sDate
=
dates
this
.
modelItemDetail
.
sDate
=
dates
}
}
if
(
item2
==
"edate"
)
{
if
(
item2
==
"edate"
)
{
this
.
modelItemDetail
.
eDate
=
dates
this
.
modelItemDetail
.
eDate
=
dates
}
}
console
.
log
(
this
.
sDate
)
}
}
openRoomDetail
(
content
:
string
,
item
:
RoomDetail
)
{
openRoomDetail
(
content
:
string
,
item
:
RoomDetail
)
{
this
.
modelRoomDetail
=
item
;
this
.
modelRoomDetail
=
item
;
this
.
thStime
=
this
.
modelRoomDetail
.
sTime
.
hour
+
':'
+
this
.
modelRoomDetail
.
sTime
.
minute
this
.
thStime
=
this
.
modelRoomDetail
.
sTime
.
hour
+
':'
+
this
.
modelRoomDetail
.
sTime
.
minute
this
.
thEtime
=
this
.
modelRoomDetail
.
eTime
.
hour
+
':'
+
this
.
modelRoomDetail
.
eTime
.
minute
this
.
thEtime
=
this
.
modelRoomDetail
.
eTime
.
hour
+
':'
+
this
.
modelRoomDetail
.
eTime
.
minute
let
SDate
=
this
.
modelRoomDetail
.
sDate
.
split
(
'/'
)
let
SDate
=
this
.
modelRoomDetail
.
sDate
.
split
(
'/'
)
this
.
sDate
=
SDate
[
2
]
+
"-"
+
SDate
[
1
]
+
"-"
+
SDate
[
0
]
this
.
sDate
=
SDate
[
0
]
+
"-"
+
SDate
[
1
]
+
"-"
+
SDate
[
2
]
let
EDate
=
this
.
modelRoomDetail
.
eDate
.
split
(
'/'
)
let
EDate
=
this
.
modelRoomDetail
.
eDate
.
split
(
'/'
)
this
.
eDate
=
EDate
[
2
]
+
"-"
+
EDate
[
1
]
+
"-"
+
EDate
[
0
]
this
.
eDate
=
EDate
[
0
]
+
"-"
+
EDate
[
1
]
+
"-"
+
EDate
[
2
]
this
.
modalService
.
open
(
content
,
{
ariaLabelledBy
:
'modal-basic-title'
}).
result
.
then
((
result
)
=>
{
this
.
modalService
.
open
(
content
,
{
ariaLabelledBy
:
'modal-basic-title'
}).
result
.
then
((
result
)
=>
{
this
.
closeResult
=
`Closed with:
${
result
}
`
;
this
.
closeResult
=
`Closed with:
${
result
}
`
;
},
(
reason
)
=>
{
},
(
reason
)
=>
{
...
@@ -193,34 +189,35 @@ export class AdminPendingComponent implements OnInit {
...
@@ -193,34 +189,35 @@ export class AdminPendingComponent implements OnInit {
this
.
listitemDetail
=
this
.
ItemDetailService
.
getListItemDetail
();
this
.
listitemDetail
=
this
.
ItemDetailService
.
getListItemDetail
();
this
.
listroomDetail
=
this
.
RoomDetailService
.
getListRoomDetail
();
this
.
listroomDetail
=
this
.
RoomDetailService
.
getListRoomDetail
();
this
.
collectionSizeListRoom
=
this
.
listitemDetail
.
length
;
this
.
collectionSizeListRoom
=
this
.
listitemDetail
.
length
;
console
.
log
(
this
.
listitemDetail
);
this
.
myFormRoom
=
new
FormGroup
({
this
.
myFormRoom
=
new
FormGroup
({
userNameForm
:
new
FormControl
(
''
,[
Validators
.
required
]),
userNameForm
:
new
FormControl
(
''
,
[
Validators
.
required
]),
rTelephone
:
new
FormControl
(
''
,[
Validators
.
required
]),
rTelephone
:
new
FormControl
(
''
,
[
Validators
.
required
]),
email
:
new
FormControl
(
''
,[
Validators
.
required
,
Validators
.
email
]),
email
:
new
FormControl
(
''
,
[
Validators
.
required
,
Validators
.
email
]),
rName
:
new
FormControl
(
''
,[
Validators
.
required
]),
rName
:
new
FormControl
(
''
,
[
Validators
.
required
]),
rDesc
:
new
FormControl
(
''
,[
Validators
.
required
]),
rDesc
:
new
FormControl
(
''
,
[
Validators
.
required
]),
rType
:
new
FormControl
(
''
,[
Validators
.
required
]),
rType
:
new
FormControl
(
''
,
[
Validators
.
required
]),
sDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
sDate
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
eDate
:
new
FormControl
(
''
,
[
Validators
.
required
]),
sTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
sTime
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
eTime
:
new
FormControl
(
''
,
[
Validators
.
required
]),
Remark
:
new
FormControl
()
Remark
:
new
FormControl
(),
rStatus
:
new
FormControl
()
});
});
this
.
myFormEquir
=
new
FormGroup
({
this
.
myFormEquir
=
new
FormGroup
({
userNameForm
:
new
FormControl
(
''
,[
Validators
.
required
]),
userNameForm
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eTelephone
:
new
FormControl
(
''
,[
Validators
.
required
]),
eTelephone
:
new
FormControl
(
''
,
[
Validators
.
required
]),
email
:
new
FormControl
(
''
,[
Validators
.
required
,
Validators
.
email
]),
email
:
new
FormControl
(
''
,
[
Validators
.
required
,
Validators
.
email
]),
eqName
:
new
FormControl
(
''
,[
Validators
.
required
]),
eqName
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eqDesc
:
new
FormControl
(
''
,[
Validators
.
required
]),
eqDesc
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eqType
:
new
FormControl
(
''
,[
Validators
.
required
]),
eqType
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eqPic
:
new
FormControl
(
''
,[
Validators
.
required
]),
eqPic
:
new
FormControl
(
''
,
[
Validators
.
required
]),
sDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
sDate
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eDate
:
new
FormControl
(
''
,[
Validators
.
required
]),
eDate
:
new
FormControl
(
''
,
[
Validators
.
required
]),
sTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
sTime
:
new
FormControl
(
''
,
[
Validators
.
required
]),
eTime
:
new
FormControl
(
''
,[
Validators
.
required
]),
eTime
:
new
FormControl
(
''
,
[
Validators
.
required
]),
Quantity
:
new
FormControl
(
''
,[
Validators
.
required
]),
Quantity
:
new
FormControl
(
''
,
[
Validators
.
required
]),
Remark
:
new
FormControl
(
''
,[
Validators
.
required
]),
Remark
:
new
FormControl
(),
eStatus
:
new
FormControl
()
})
})
}
}
...
@@ -235,6 +232,13 @@ export class AdminPendingComponent implements OnInit {
...
@@ -235,6 +232,13 @@ export class AdminPendingComponent implements OnInit {
this
.
modalService
.
dismissAll
();
this
.
modalService
.
dismissAll
();
this
.
ngOnInit
();
this
.
ngOnInit
();
}
}
saveStatus
()
{
this
.
RoomDetailService
.
addRoomDetail
(
this
.
modelRoomDetail
)
this
.
modalService
.
dismissAll
();
this
.
ngOnInit
();
console
.
log
(
this
.
modelRoomDetail
)
}
}
}
export
class
NgbdDropdownBasic
{
export
class
NgbdDropdownBasic
{
...
...
src/app/pages/equipment/equipment.component.html
View file @
6fcec8df
...
@@ -151,9 +151,8 @@
...
@@ -151,9 +151,8 @@
<br>
<br>
<select
class=
"form-select"
aria-label=
"Default select example"
<select
class=
"form-select"
aria-label=
"Default select example"
[(
ngModel
)]="
modelEquirment
.
eqType
"
formControlName=
"eqType"
>
[(
ngModel
)]="
modelEquirment
.
eqType
"
formControlName=
"eqType"
>
<option
selected
>
เลือกหมวดหมู่
</option>
<option
value=
"4"
style=
"color: black;"
>
IT
</option>
<option
value=
"4"
>
IT
</option>
<option
value=
"5"
style=
"color: black;"
>
Company
</option>
<option
value=
"5"
>
Company
</option>
</select>
</select>
<div
style=
"color: red;"
*
ngIf=
"myFormEquir.controls.eqType.status=='INVALID'"
>
<div
style=
"color: red;"
*
ngIf=
"myFormEquir.controls.eqType.status=='INVALID'"
>
กรุณากรอกประเภทอุปกรณ์.
</div>
กรุณากรอกประเภทอุปกรณ์.
</div>
...
@@ -210,10 +209,10 @@
...
@@ -210,10 +209,10 @@
<div
class=
" form-group"
>
<div
class=
" form-group"
>
<label>
ประเภท
</label>
<label>
ประเภท
</label>
<br>
<br>
<select
class=
"form-select"
aria-label=
"Default select example"
<select
class=
"form-select
form-control
"
aria-label=
"Default select example"
[(
ngModel
)]="
modelRoom
.
rType
"
formControlName=
"rType"
>
[(
ngModel
)]="
modelRoom
.
rType
"
formControlName=
"rType"
>
<option
value=
"1"
>
ห้อง
</option>
<option
value=
"1"
style=
"color: black;"
>
ห้อง
</option>
<option
value=
"2"
>
รถ
</option>
<option
value=
"2"
style=
"color: black;"
>
รถ
</option>
</select>
</select>
<div
style=
"color: red;"
*
ngIf=
"myFormRoom.controls.rType.status=='INVALID'"
>
<div
style=
"color: red;"
*
ngIf=
"myFormRoom.controls.rType.status=='INVALID'"
>
กรุณากรอกประเภท.
</div>
กรุณากรอกประเภท.
</div>
...
...
src/app/service/item-detail.service.ts
View file @
6fcec8df
...
@@ -18,8 +18,8 @@ export class ItemDetailService {
...
@@ -18,8 +18,8 @@ export class ItemDetailService {
eqPic
:
"assets/img/mou.jpg"
eqPic
:
"assets/img/mou.jpg"
},
},
userName
:
'เกม'
,
userName
:
'เกม'
,
sDate
:
'
09/12/2021
'
,
sDate
:
'
2021/12/09
'
,
eDate
:
'
09/12/2021
'
,
eDate
:
'
2021/12/15
'
,
sTime
:
{
sTime
:
{
hour
:
22
,
hour
:
22
,
minute
:
30
,
minute
:
30
,
...
@@ -46,8 +46,8 @@ export class ItemDetailService {
...
@@ -46,8 +46,8 @@ export class ItemDetailService {
eqPic
:
"assets/img/notebook.jpg"
eqPic
:
"assets/img/notebook.jpg"
},
},
userName
:
'แป๊ะ'
,
userName
:
'แป๊ะ'
,
sDate
:
'
09/12/2021
'
,
sDate
:
'
2021/12/09
'
,
eDate
:
'
09/12/2021
'
,
eDate
:
'
2021/12/13
'
,
sTime
:
{
sTime
:
{
hour
:
22
,
hour
:
22
,
minute
:
30
,
minute
:
30
,
...
...
src/app/service/room-detail.service.ts
View file @
6fcec8df
...
@@ -31,7 +31,7 @@ export class RoomDetailService {
...
@@ -31,7 +31,7 @@ export class RoomDetailService {
minute
:
30
,
minute
:
30
,
second
:
0
second
:
0
},
},
rStatus
:
1
,
rStatus
:
0
,
rTelephone
:
'0123456789'
,
rTelephone
:
'0123456789'
,
email
:
'qwerty@qwerty'
,
email
:
'qwerty@qwerty'
,
Remark
:
'test'
,
Remark
:
'test'
,
...
@@ -46,7 +46,7 @@ export class RoomDetailService {
...
@@ -46,7 +46,7 @@ export class RoomDetailService {
roomLimit
:
50
,
roomLimit
:
50
,
rDesc
:
"จำนวนคน 50 คน"
,
rDesc
:
"จำนวนคน 50 คน"
,
},
},
userName
:
'
เกม
'
,
userName
:
'
แป๊ะ
'
,
sDate
:
'2021/12/15'
,
sDate
:
'2021/12/15'
,
eDate
:
'2021/12/15'
,
eDate
:
'2021/12/15'
,
sTime
:
{
sTime
:
{
...
@@ -72,9 +72,7 @@ export class RoomDetailService {
...
@@ -72,9 +72,7 @@ export class RoomDetailService {
}
}
addRoomDetail
(
model
:
RoomDetail
)
{
addRoomDetail
(
model
:
RoomDetail
)
{
this
.
listRoomDetail
.
push
(
model
);
this
.
listRoomDetail
.
push
(
model
);
console
.
log
(
this
.
listRoomDetail
);
}
}
getListRoomDetail
()
{
getListRoomDetail
()
{
...
...
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