Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
H
HIAST-Clinics
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
almohanad.hafez
HIAST-Clinics
Commits
90825204
Commit
90825204
authored
Aug 25, 2024
by
Almouhannad
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(F) Add scroll to top behavior
parent
d8b28e98
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
33 additions
and
13 deletions
+33
-13
app.module.ts
Clinics.Frontend/src/app/app.module.ts
+2
-0
create-doctor-user-form.component.html
...e-doctor-user-form/create-doctor-user-form.component.html
+1
-1
doctor-user.component.html
...p/components/admin/doctor-user/doctor-user.component.html
+1
-1
doctor-users.component.html
...components/admin/doctor-users/doctor-users.component.html
+1
-1
update-doctor-user.component.html
...dmin/update-doctor-user/update-doctor-user.component.html
+1
-1
waiting-list.component.html
...nts/receptionist/waiting-list/waiting-list.component.html
+1
-1
header.component.css
...pp/components/shared/template/header/header.component.css
+1
-1
header.component.html
...p/components/shared/template/header/header.component.html
+7
-7
scroll-to-top.directive.ts
...cs.Frontend/src/app/directives/scroll-to-top.directive.ts
+18
-0
No files found.
Clinics.Frontend/src/app/app.module.ts
View file @
90825204
...
@@ -43,6 +43,7 @@ import { EmployeeSerialNumberPopUpComponent } from './components/receptionist/em
...
@@ -43,6 +43,7 @@ import { EmployeeSerialNumberPopUpComponent } from './components/receptionist/em
import
{
EmployeeComponent
}
from
'./components/receptionist/employee/employee.component'
;
import
{
EmployeeComponent
}
from
'./components/receptionist/employee/employee.component'
;
import
{
WaitingListService
}
from
'./services/waitingList/waiting-list.service'
;
import
{
WaitingListService
}
from
'./services/waitingList/waiting-list.service'
;
import
{
EmployeesDataService
}
from
'./services/employees/employees-data.service'
;
import
{
EmployeesDataService
}
from
'./services/employees/employees-data.service'
;
import
{
ScrollToTopDirective
}
from
'./directives/scroll-to-top.directive'
;
@
NgModule
({
@
NgModule
({
...
@@ -104,6 +105,7 @@ import { EmployeesDataService } from './services/employees/employees-data.servic
...
@@ -104,6 +105,7 @@ import { EmployeesDataService } from './services/employees/employees-data.servic
CreateEmployeeFormComponent
,
CreateEmployeeFormComponent
,
EmployeeSerialNumberPopUpComponent
,
EmployeeSerialNumberPopUpComponent
,
EmployeeComponent
,
EmployeeComponent
,
ScrollToTopDirective
,
],
],
// identifies the root component that Angular should
// identifies the root component that Angular should
...
...
Clinics.Frontend/src/app/components/admin/create-doctor-user-form/create-doctor-user-form.component.html
View file @
90825204
...
@@ -6,7 +6,7 @@
...
@@ -6,7 +6,7 @@
<div
class=
"container text-center mb-3"
>
<div
class=
"container text-center mb-3"
>
<div
class=
"custom-back-button"
>
<div
class=
"custom-back-button"
>
<a
[
routerLink
]="['..']"
>
<a
[
routerLink
]="['..']"
appScrollToTop
>
<button
class=
"btn btn-outline-primary"
>
<button
class=
"btn btn-outline-primary"
>
عودة
<i
class=
"bi bi-arrow-left"
></i>
عودة
<i
class=
"bi bi-arrow-left"
></i>
</button>
</button>
...
...
Clinics.Frontend/src/app/components/admin/doctor-user/doctor-user.component.html
View file @
90825204
...
@@ -23,7 +23,7 @@
...
@@ -23,7 +23,7 @@
<!-- #region buttons-->
<!-- #region buttons-->
<a
[
routerLink
]="['
update
',
doctorUser
.
id
]"
class=
"d-grid gap-3 custom-edit-button"
>
<a
[
routerLink
]="['
update
',
doctorUser
.
id
]"
class=
"d-grid gap-3 custom-edit-button"
appScrollToTop
>
<button
class=
"btn btn-outline-secondary"
>
<button
class=
"btn btn-outline-secondary"
>
تعديل
<i
class=
"bi bi-pencil-fill"
></i>
تعديل
<i
class=
"bi bi-pencil-fill"
></i>
</button>
</button>
...
...
Clinics.Frontend/src/app/components/admin/doctor-users/doctor-users.component.html
View file @
90825204
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<!-- #region buttons-->
<!-- #region buttons-->
<div
class=
"text-center custom-create-button"
>
<div
class=
"text-center custom-create-button"
>
<a
[
routerLink
]="['
create
']"
><button
class=
"btn btn-lg btn-outline-success mb-5"
style=
"width: 35%;"
>
إضافة طبيب +
</button></a>
<a
[
routerLink
]="['
create
']"
appScrollToTop
><button
class=
"btn btn-lg btn-outline-success mb-5"
style=
"width: 35%;"
>
إضافة طبيب +
</button></a>
</div>
</div>
<!-- #endregion -->
<!-- #endregion -->
...
...
Clinics.Frontend/src/app/components/admin/update-doctor-user/update-doctor-user.component.html
View file @
90825204
...
@@ -6,7 +6,7 @@
...
@@ -6,7 +6,7 @@
<div
class=
"container text-center mb-3 custom-title"
>
<div
class=
"container text-center mb-3 custom-title"
>
<div
class=
"custom-back-button"
>
<div
class=
"custom-back-button"
>
<a
[
routerLink
]="['../..']"
>
<a
[
routerLink
]="['../..']"
appScrollToTop
>
<button
class=
"btn btn-outline-primary"
>
<button
class=
"btn btn-outline-primary"
>
عودة
<i
class=
"bi bi-arrow-left"
></i>
عودة
<i
class=
"bi bi-arrow-left"
></i>
</button>
</button>
...
...
Clinics.Frontend/src/app/components/receptionist/waiting-list/waiting-list.component.html
View file @
90825204
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<!-- #region buttons-->
<!-- #region buttons-->
<div
class=
"custom-bttuons-after-title custom-create-button"
>
<div
class=
"custom-bttuons-after-title custom-create-button"
>
<a
[
routerLink
]="['
create
']"
><button
class=
"btn btn-lg btn-outline-success mb-5"
>
إضافة +
</button></a>
<a
[
routerLink
]="['
create
']"
appScrollToTop
><button
class=
"btn btn-lg btn-outline-success mb-5"
>
إضافة +
</button></a>
</div>
</div>
<!-- #endregion -->
<!-- #endregion -->
...
...
Clinics.Frontend/src/app/components/shared/template/header/header.component.css
View file @
90825204
/* #region Custom */
/* #region Custom */
.custom-app-name
{
.custom-app-name
{
font-size
:
30px
;
font-size
:
1.8em
;
font-weight
:
700
;
font-weight
:
700
;
color
:
var
(
--heading-color
);
color
:
var
(
--heading-color
);
}
}
...
...
Clinics.Frontend/src/app/components/shared/template/header/header.component.html
View file @
90825204
...
@@ -50,15 +50,15 @@
...
@@ -50,15 +50,15 @@
</ul>
</ul>
</li>
</li>
<li><a
[
routerLink
]="['
admin
/
receptionists
']"
><button
class=
"btn"
<li><a
[
routerLink
]="['
admin
/
receptionists
']"
appScrollToTop
><button
class=
"btn"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Admin-Receptionists
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Admin-Receptionists
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Admin-Receptionists
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Admin-Receptionists
')}"
(
click
)="
showDropdown=
false;
selectButton
('
Admin-Receptionists
')"
>
موظفو الاستقبال
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
Admin-Receptionists
')"
>
موظفو الاستقبال
</button></a></li>
<li><a
[
routerLink
]="['
admin
/
doctors
']"
><button
class=
"btn"
<li><a
[
routerLink
]="['
admin
/
doctors
']"
appScrollToTop
><button
class=
"btn"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Admin-Dorctors
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Admin-Dorctors
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Admin-Dorctors
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Admin-Dorctors
')}"
(
click
)="
showDropdown=
false;
selectButton
('
Admin-Dorctors
')"
>
الأطباء
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
Admin-Dorctors
')"
>
الأطباء
</button></a></li>
<li><a
[
routerLink
]="'
home
'"
><button
class=
"btn"
<li><a
[
routerLink
]="'
home
'"
appScrollToTop
><button
class=
"btn"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Home
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Home
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Home
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Home
')}"
(
click
)="
showDropdown=
false;
selectButton
('
Home
')"
>
الصفحة الرئيسية
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
Home
')"
>
الصفحة الرئيسية
</button></a></li>
...
@@ -80,7 +80,7 @@
...
@@ -80,7 +80,7 @@
</ul>
</ul>
</li>
</li>
<li><a
[
routerLink
]="'
home
'"
><button
class=
"btn"
<li><a
[
routerLink
]="'
home
'"
appScrollToTop
><button
class=
"btn"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Home
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Home
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Home
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Home
')}"
(
click
)="
showDropdown=
false;
selectButton
('
Home
')"
>
الصفحة الرئيسية
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
Home
')"
>
الصفحة الرئيسية
</button></a></li>
...
@@ -99,7 +99,7 @@
...
@@ -99,7 +99,7 @@
class=
"bi bi-chevron-down toggle-dropdown"
></i></button>
class=
"bi bi-chevron-down toggle-dropdown"
></i></button>
<ul
[
ngClass
]="{'
show
'
:
showDropdown
}"
>
<ul
[
ngClass
]="{'
show
'
:
showDropdown
}"
>
<li><a
(
click
)="
openPopUp
(
employeeSerialNumber
)
;
showDropdown =
false;"
>
الاستعلام عن موظف
</a></li>
<li><a
(
click
)="
openPopUp
(
employeeSerialNumber
)
;
showDropdown =
false;"
>
الاستعلام عن موظف
</a></li>
<li><a
(
click
)="
showDropdown =
false;"
[
routerLink
]="['
receptionist
/
employees
/
create
']"
>
إضافة موظف
</a></li>
<li><a
(
click
)="
showDropdown =
false;"
[
routerLink
]="['
receptionist
/
employees
/
create
']"
appScrollToTop
>
إضافة موظف
</a></li>
<li
(
click
)="
onLogout
();"
><a>
تسجيل الخروج
</a></li>
<li
(
click
)="
onLogout
();"
><a>
تسجيل الخروج
</a></li>
</ul>
</ul>
</li>
</li>
...
@@ -108,11 +108,11 @@
...
@@ -108,11 +108,11 @@
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
RecDotctors
'),
'
btn-outline-secondary
'
:
!
isSelected
('
RecDotctors
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
RecDotctors
'),
'
btn-outline-secondary
'
:
!
isSelected
('
RecDotctors
')}"
(
click
)="
showDropdown=
false;
selectButton
('
RecDotctors
')"
>
الأطباء
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
RecDotctors
')"
>
الأطباء
</button></a></li>
<li><a
[
routerLink
]="'
receptionist
/
waitinglist
'"
><button
class=
"btn"
<li><a
[
routerLink
]="'
receptionist
/
waitinglist
'"
appScrollToTop
><button
class=
"btn"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
WaitingList
'),
'
btn-outline-secondary
'
:
!
isSelected
('
WaitingList
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
WaitingList
'),
'
btn-outline-secondary
'
:
!
isSelected
('
WaitingList
')}"
(
click
)="
showDropdown=
false;
selectButton
('
WaitingList
')"
>
قائمة الانتظار
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
WaitingList
')"
>
قائمة الانتظار
</button></a></li>
<li><a
[
routerLink
]="'
home
'"
><button
class=
"btn"
<li><a
[
routerLink
]="'
home
'"
><button
class=
"btn"
appScrollToTop
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Home
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Home
')}"
[
class
]="{'
btn-outline-primary
'
:
isSelected
('
Home
'),
'
btn-outline-secondary
'
:
!
isSelected
('
Home
')}"
(
click
)="
showDropdown=
false;
selectButton
('
Home
')"
>
الصفحة الرئيسية
</button></a></li>
(
click
)="
showDropdown=
false;
selectButton
('
Home
')"
>
الصفحة الرئيسية
</button></a></li>
...
...
Clinics.Frontend/src/app/directives/scroll-to-top.directive.ts
0 → 100644
View file @
90825204
import
{
Directive
}
from
'@angular/core'
;
import
{
Router
,
NavigationEnd
}
from
'@angular/router'
;
import
{
ViewportScroller
}
from
'@angular/common'
;
@
Directive
({
selector
:
'[appScrollToTop]'
})
export
class
ScrollToTopDirective
{
constructor
(
private
viewportScroller
:
ViewportScroller
,
private
router
:
Router
)
{
}
ngAfterViewInit
()
{
this
.
router
.
events
.
subscribe
(
event
=>
{
if
(
event
instanceof
NavigationEnd
)
{
this
.
viewportScroller
.
scrollToPosition
([
0
,
0
]);
}
});
}
}
\ 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