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
374f8af9
Commit
374f8af9
authored
Dec 13, 2021
by
DESKTOP-HF0LVOG\myhr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add function
parent
6fcec8df
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
7 deletions
+15
-7
admin-pending.component.ts
src/app/pages/admin-pending/admin-pending.component.ts
+1
-1
room-detail.service.ts
src/app/service/room-detail.service.ts
+14
-6
No files found.
src/app/pages/admin-pending/admin-pending.component.ts
View file @
374f8af9
...
...
@@ -234,7 +234,7 @@ export class AdminPendingComponent implements OnInit {
}
saveStatus
()
{
this
.
RoomDetailService
.
add
RoomDetail
(
this
.
modelRoomDetail
)
this
.
RoomDetailService
.
update
RoomDetail
(
this
.
modelRoomDetail
)
this
.
modalService
.
dismissAll
();
this
.
ngOnInit
();
console
.
log
(
this
.
modelRoomDetail
)
...
...
src/app/service/room-detail.service.ts
View file @
374f8af9
...
...
@@ -75,6 +75,14 @@ export class RoomDetailService {
this
.
listRoomDetail
.
push
(
model
);
}
updateRoomDetail
(
model
:
RoomDetail
){
let
temp
=
this
.
listRoomDetail
.
filter
(
x
=>
x
.
Id
==
model
.
Id
)
console
.
log
(
"temp"
,
temp
);
}
getListRoomDetail
()
{
return
this
.
listRoomDetail
;
}
...
...
@@ -115,12 +123,12 @@ export class RoomDetailService {
})
}
updateRoomDetail
(
RoomDetailModel
:
RoomDetail
)
{
this
.
http
.
put
(
this
.
url
+
"/"
+
RoomDetailModel
.
Id
,
RoomDetailModel
).
subscribe
(
response
=>
{
console
.
log
(
response
);
alert
(
"อัพเดทข้อมูลอุปกรณ์สำเร็จ"
)
})
}
//
updateRoomDetail(RoomDetailModel: RoomDetail) {
//
this.http.put(this.url + "/" + RoomDetailModel.Id, RoomDetailModel).subscribe(response => {
//
console.log(response);
//
alert("อัพเดทข้อมูลอุปกรณ์สำเร็จ")
//
})
//
}
RoomDetailModel
(
rId
:
string
)
{
...
...
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