Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
myjob-manage
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
angular
myjob-manage
Commits
83db1670
Commit
83db1670
authored
Jul 11, 2025
by
Natthaphat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
เพิ่ม datagird sysfunction ## npm i --force
parent
5e69bb3f
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
121 additions
and
81 deletions
+121
-81
package-lock.json
package-lock.json
+6
-1
package.json
package.json
+9
-3
excel-list.component.html
...al/set-excel-reports/excel-list/excel-list.component.html
+70
-62
excel-list.component.ts
...rtal/set-excel-reports/excel-list/excel-list.component.ts
+19
-15
styles.scss
src/styles.scss
+17
-0
No files found.
package-lock.json
View file @
83db1670
...
@@ -35,7 +35,12 @@
...
@@ -35,7 +35,12 @@
"@syncfusion/ej2-angular-grids"
:
"^29.2.4"
,
"@syncfusion/ej2-angular-grids"
:
"^29.2.4"
,
"@syncfusion/ej2-angular-inputs"
:
"^29.2.4"
,
"@syncfusion/ej2-angular-inputs"
:
"^29.2.4"
,
"@syncfusion/ej2-angular-pivotview"
:
"^29.2.4"
,
"@syncfusion/ej2-angular-pivotview"
:
"^29.2.4"
,
"@syncfusion/ej2-grids"
:
"^29.2.11"
,
"@syncfusion/ej2-base"
:
"^29.2.4"
,
"@syncfusion/ej2-buttons"
:
"^29.2.4"
,
"@syncfusion/ej2-data"
:
"^29.2.4"
,
"@syncfusion/ej2-dropdowns"
:
"^29.2.4"
,
"@syncfusion/ej2-grids"
:
"^29.2.4"
,
"@syncfusion/ej2-inputs"
:
"^29.2.4"
,
"@tailwindcss/forms"
:
"^0.5.7"
,
"@tailwindcss/forms"
:
"^0.5.7"
,
"@types/google.maps"
:
"^3.58.1"
,
"@types/google.maps"
:
"^3.58.1"
,
"@types/googlemaps"
:
"^3.43.3"
,
"@types/googlemaps"
:
"^3.43.3"
,
...
...
package.json
View file @
83db1670
...
@@ -35,12 +35,17 @@
...
@@ -35,12 +35,17 @@
"
@ngx-translate/core
"
:
"^15.0.0"
,
"
@ngx-translate/core
"
:
"^15.0.0"
,
"
@ngx-translate/http-loader
"
:
"^8.0.0"
,
"
@ngx-translate/http-loader
"
:
"^8.0.0"
,
"
@syncfusion/ej2-angular-base
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-base
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-charts
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-dropdowns
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-dropdowns
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-grids
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-grids
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-inputs
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-inputs
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-pivotview
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-pivotview
"
:
"^29.2.4"
,
"
@syncfusion/ej2-grids
"
:
"^29.2.11"
,
"
@syncfusion/ej2-base
"
:
"^29.2.4"
,
"
@syncfusion/ej2-buttons
"
:
"^29.2.4"
,
"
@syncfusion/ej2-data
"
:
"^29.2.4"
,
"
@syncfusion/ej2-dropdowns
"
:
"^29.2.4"
,
"
@syncfusion/ej2-grids
"
:
"^29.2.4"
,
"
@syncfusion/ej2-inputs
"
:
"^29.2.4"
,
"
@syncfusion/ej2-angular-charts
"
:
"^29.2.4"
,
"
@tailwindcss/forms
"
:
"^0.5.7"
,
"
@tailwindcss/forms
"
:
"^0.5.7"
,
"
@types/google.maps
"
:
"^3.58.1"
,
"
@types/google.maps
"
:
"^3.58.1"
,
"
@types/googlemaps
"
:
"^3.43.3"
,
"
@types/googlemaps
"
:
"^3.43.3"
,
...
@@ -115,4 +120,4 @@
...
@@ -115,4 +120,4 @@
"
tailwindcss
"
:
"^3.3.2"
,
"
tailwindcss
"
:
"^3.3.2"
,
"
typescript
"
:
"~5.2.2"
"
typescript
"
:
"~5.2.2"
}
}
}
}
\ No newline at end of file
src/app/DPU/common/myportal/set-excel-reports/excel-list/excel-list.component.html
View file @
83db1670
...
@@ -90,7 +90,7 @@
...
@@ -90,7 +90,7 @@
</tr>
</tr>
<ng-container
*
ngIf=
"!isSearching"
>
<ng-container
*
ngIf=
"!isSearching"
>
<ng-container
<ng-container
*
ngFor=
"let items of template.filter | slice:
(page-1) * pageSize : (page-1) * pageSize + pageSize
; let i = index"
>
*
ngFor=
"let items of template.filter | slice:
page * pageSize : (page + 1) * pageSize
; let i = index"
>
<tr
(
mouseenter
)="
tableHover
.
set
(
items
.
templateId
,!
tableHover
.
get
(
items
.
templateId
))"
<tr
(
mouseenter
)="
tableHover
.
set
(
items
.
templateId
,!
tableHover
.
get
(
items
.
templateId
))"
(
mouseleave
)="
tableHover
.
clear
()"
(
mouseleave
)="
tableHover
.
clear
()"
[
ngStyle
]="{'
background-color
'
:tableHover
.
get
(
items
.
templateId
)?'
rgb
(
201
223
235
)'
:
'#
ebf2f6
'}"
>
[
ngStyle
]="{'
background-color
'
:tableHover
.
get
(
items
.
templateId
)?'
rgb
(
201
223
235
)'
:
'#
ebf2f6
'}"
>
...
@@ -140,7 +140,7 @@
...
@@ -140,7 +140,7 @@
</tr>
</tr>
<ng-container
*
ngIf=
"openTemplate.get(items.templateId)"
>
<ng-container
*
ngIf=
"openTemplate.get(items.templateId)"
>
<ng-container
<ng-container
*
ngFor=
"let item of items.templateFile | slice:
(page-1) * pageSize : (page-1) * pageSize +
pageSize ; let i = index"
>
*
ngFor=
"let item of items.templateFile | slice:
page * pageSize : (page+1) *
pageSize ; let i = index"
>
<tr
(
mouseenter
)="
tableHover
.
set
(
item
.
fileName
,!
tableHover
.
get
(
item
.
fileName
))"
<tr
(
mouseenter
)="
tableHover
.
set
(
item
.
fileName
,!
tableHover
.
get
(
item
.
fileName
))"
(
mouseleave
)="
tableHover
.
clear
()"
(
mouseleave
)="
tableHover
.
clear
()"
[
ngStyle
]="{'
background-color
'
:tableHover
.
get
(
item
.
fileName
)?'
rgb
(
201
223
235
)'
:
'#
ffffff
'}"
>
[
ngStyle
]="{'
background-color
'
:tableHover
.
get
(
item
.
fileName
)?'
rgb
(
201
223
235
)'
:
'#
ffffff
'}"
>
...
@@ -226,31 +226,25 @@
...
@@ -226,31 +226,25 @@
<div
class=
"ms-auto"
>
<div
class=
"ms-auto"
>
<nav
aria-label=
"Page navigation"
>
<nav
aria-label=
"Page navigation"
>
<ul
class=
"ti-pagination mb-0"
>
<ul
class=
"ti-pagination mb-0"
>
<li
*
ngIf=
"page
Index>0"
class=
"page-item {{pageIndex
==0 ? 'disabled' : ''}}"
><a
<li
*
ngIf=
"page
> 0"
class=
"page-item {{page
==0 ? 'disabled' : ''}}"
><a
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
(
click
)="
pageIndex =
pageIndex-1;updatePagedItems()"
>
{{'Previous' |
(
click
)="
page =
page
-
1
;
updatePagedItems
()"
>
{{'Previous' | translate}}
</a>
translate}}
</a></li>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"pageIndex-1>0"
(
click
)="
pageIndex =
pageIndex-2;updatePagedItems()"
>
{{pageIndex-1}}
</a>
</li>
</li>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"pageIndex>0 && ((pageIndex-1)*10 < (searchText == '' ? template.data.length : template.filter.length))"
*
ngIf=
"page > 0"
(
click
)="
page =
page
-
1
;
updatePagedItems
()"
>
{{page}}
</a>
(
click
)="
pageIndex =
pageIndex-1;updatePagedItems()"
>
{{pageIndex}}
</a></li>
</li>
<li
class=
"page-item"
><a
class=
"page-link active px-3 py-[0.375rem]"
<li
class=
"page-item"
><a
class=
"page-link active px-3 py-[0.375rem]"
href=
"javascript:void(0);"
>
{{page
Index +
1}}
</a>
href=
"javascript:void(0);"
>
{{page
+
1}}
</a>
</li>
</li>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"(page
Index+1)*10 < (searchText == '' ? template.data.length : template.filter.length)
"
*
ngIf=
"(page
+ 1) * pageSize < template.filter.length
"
(
click
)="
page
Index =
pageIndex+1;updatePagedItems()"
>
{{pageIndex +
2}}
</a></li>
(
click
)="
page
=
page
+
1
;
updatePagedItems
()"
>
{{page +
2}}
</a></li>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"(pageIndex+2)*10 < (searchText == '' ? template.data.length : template.filter.length)"
*
ngIf=
"(page + 2) * pageSize < template.filter.length"
(
click
)="
pageIndex =
pageIndex+2;updatePagedItems()"
>
{{pageIndex +3}}
</a></li>
(
click
)="
page =
page
+
2
;
updatePagedItems
()"
>
{{page + 3}}
</a></li>
<li
*
ngIf=
"(pageIndex+1)*10 < (searchText == '' ? template.data.length : template.filter.length)"
<li
*
ngIf=
"(page + 1) * pageSize < template.filter.length"
class=
"page-item"
><a
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
(
click
)="
pageIndex =
pageIndex+1;updatePagedItems()"
>
{{'Next' |
(
click
)="
page =
page
+
1
;
updatePagedItems
()"
>
{{'Next' | translate}}
</a>
translate}}
</a>
</li>
</li>
</ul>
</ul>
</nav>
</nav>
...
@@ -302,7 +296,9 @@
...
@@ -302,7 +296,9 @@
</div>
</div>
</div>
</div>
<div
class=
"xl:col-span-6 col-span-12"
>
<div
class=
"xl:col-span-6 col-span-12"
>
<label
for=
"deal-title"
class=
"form-label"
>
ชื่อกลุ่มรายงาน (ภาษาอังกฤษ)
</label>
<label
for=
"deal-title"
class=
"form-label"
>
ชื่อกลุ่มรายงาน (ภาษาอังกฤษ)
<span
class=
"required text-danger"
>
*
</span>
</label>
<input
type=
"text"
class=
"form-control"
id=
"deal-title"
placeholder=
""
<input
type=
"text"
class=
"form-control"
id=
"deal-title"
placeholder=
""
[(
ngModel
)]="
bodyTemplate
.
data
.
ename
"
>
[(
ngModel
)]="
bodyTemplate
.
data
.
ename
"
>
<div
class=
"text-danger"
*
ngIf=
"!bodyTemplate.data.ename"
>
<div
class=
"text-danger"
*
ngIf=
"!bodyTemplate.data.ename"
>
...
@@ -336,14 +332,18 @@
...
@@ -336,14 +332,18 @@
</div>
</div>
</div>
</div>
<div
class=
"ti-modal-footer flex justify-center gap-3 mb-3 mt-3"
>
<div
class=
"border-t"
>
<button
type=
"button"
class=
"ti-btn bg-danger text-white !font-medium"
(
click
)="
closeModalAddGroup
()"
>
<div
class=
"ti-modal-footer flex justify-center gap-3 mb-3 mt-3"
>
{{'Cancel' | translate}}
<button
type=
"button"
class=
"ti-btn bg-danger text-white !font-medium"
</button>
(
click
)="
closeModalAddGroup
()"
>
<button
type=
"button"
[
class
.
ti-btn-disabled
]="!
bodyTemplate
.
data
.
tname
||!
bodyTemplate
.
data
.
module
"
{{'Cancel' | translate}}
[
disabled
]="!
bodyTemplate
.
data
.
tname
||!
bodyTemplate
.
data
.
module
"
(
click
)="
closeModalAddGroup
()"
</button>
class=
"ti-btn bg-primary text-white !font-medium"
>
{{'Save' |
<button
type=
"button"
translate}}
</button>
[
class
.
ti-btn-disabled
]="!
bodyTemplate
.
data
.
tname
||
!
bodyTemplate
.
data
.
ename
||!
bodyTemplate
.
data
.
module
"
[
disabled
]="!
bodyTemplate
.
data
.
tname
||
!
bodyTemplate
.
data
.
ename
||!
bodyTemplate
.
data
.
module
"
(
click
)="
closeModalAddGroup
()"
class=
"ti-btn bg-primary text-white !font-medium"
>
{{'Save' |
translate}}
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -379,14 +379,18 @@
...
@@ -379,14 +379,18 @@
</label>
</label>
</div>
</div>
<div
*
ngIf=
"templateFileType=='portal'"
class=
"flex items-center gap-2"
>
<div
*
ngIf=
"templateFileType=='portal'"
class=
"flex items-center w-full col-span-2"
>
<input
*
ngIf=
"templateFile.portalId"
type=
"text"
class=
"form-control bg-white w-full"
<input
*
ngIf=
"templateFile.portalId"
type=
"text"
class=
"form-control bg-white w-full flex-grow"
style=
"border-radius: 0px;"
[
value
]="
templateFile
.
portalId
"
readonly
>
[
value
]="
templateFile
.
portalId
"
readonly
>
<button
type=
"button"
class=
"hs-dropdown-toggle ti-btn ti-btn-primary-full"
(
click
)="
openExcelPortalModal
()"
>
<button
type=
"button"
class=
"hs-dropdown-toggle ti-btn ti-btn-primary-full flex-shrink-0 !mb-0"
style=
"border-radius: 0.1rem;"
(
click
)="
openExcelPortalModal
()"
>
<i
class=
"ri-search-line font-semibold align-middle"
></i>
<i
class=
"ri-search-line font-semibold align-middle"
></i>
</button>
</button>
</div>
</div>
</div>
</div>
<!-- อัปโหลดไฟล์ -->
<!-- อัปโหลดไฟล์ -->
...
@@ -501,7 +505,7 @@
...
@@ -501,7 +505,7 @@
<div
class=
"border-t mt-3"
>
<div
class=
"border-t mt-3"
>
<div
class=
"ti-modal-footer flex justify-
center gap-3 mb-3 mt
-3"
>
<div
class=
"ti-modal-footer flex justify-
end gap-3 mb-3 mt-3 mr
-3"
>
<button
type=
"button"
class=
"ti-btn bg-danger text-white !font-medium"
<button
type=
"button"
class=
"ti-btn bg-danger text-white !font-medium"
(
click
)="
closeModaladdChild
()"
>
(
click
)="
closeModaladdChild
()"
>
{{'Cancel' | translate}}
{{'Cancel' | translate}}
...
@@ -592,7 +596,7 @@
...
@@ -592,7 +596,7 @@
</tbody>
</tbody>
<tbody
*
ngIf=
"excelPortalFilter().length"
>
<tbody
*
ngIf=
"excelPortalFilter().length"
>
<ng-container
<ng-container
*
ngFor=
"let item of excelPortalFilter() | slice:
(pageModal-1) * pageSizeModal : (pageModal-1) * pageSizeModal +
pageSizeModal ; let i = index"
>
*
ngFor=
"let item of excelPortalFilter() | slice:
pageModal * pageSizeModal : (pageModal+1) *
pageSizeModal ; let i = index"
>
<tr
(
mouseenter
)="
tableHover
.
set
(
item
.
excelId
,!
tableHover
.
get
(
item
.
excelId
))"
<tr
(
mouseenter
)="
tableHover
.
set
(
item
.
excelId
,!
tableHover
.
get
(
item
.
excelId
))"
(
mouseleave
)="
tableHover
.
clear
()"
(
mouseleave
)="
tableHover
.
clear
()"
[
ngStyle
]="{'
background-color
'
:tableHover
.
get
(
item
.
excelId
)?'
rgb
(
201
223
235
)'
:
'#
ebf2f6
'}"
>
[
ngStyle
]="{'
background-color
'
:tableHover
.
get
(
item
.
excelId
)?'
rgb
(
201
223
235
)'
:
'#
ebf2f6
'}"
>
...
@@ -646,7 +650,7 @@
...
@@ -646,7 +650,7 @@
</div>
</div>
</div>
</div>
<div
class=
"box-footer"
>
<div
class=
"box-footer
!border-t-0
"
>
<div
class=
"flex items-center flex-wrap overflow-auto"
*
ngIf=
"excelPortalFilter().length > 0"
>
<div
class=
"flex items-center flex-wrap overflow-auto"
*
ngIf=
"excelPortalFilter().length > 0"
>
<div
class=
"mb-2 sm:mb-0"
>
<div
class=
"mb-2 sm:mb-0"
>
<div>
<div>
...
@@ -656,31 +660,36 @@
...
@@ -656,31 +660,36 @@
</div>
</div>
<div
class=
"ms-auto"
>
<div
class=
"ms-auto"
>
<nav
aria-label=
"Page navigation"
>
<nav
aria-label=
"Page navigation"
>
<ul
class=
"ti-pagination
mb-0"
>
<ul
class=
"ti-pagination mb-0"
>
<li
*
ngIf=
"page
Index>0"
class=
"page-item {{pageIndex==0 ? 'disabled' : ''}}
"
><a
<li
*
ngIf=
"page
Modal > 0"
class=
"page-item
"
><a
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
(
click
)="
pageIndex =
pageIndex-1;updatePagedItems()"
>
{{'Previous' |
(
click
)="
pageModal =
pageModal
-
1
;
updatePagedItems
()"
>
{{'Previous' |
translate}}
</a></li>
translate}}
</a>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
</li>
*
ngIf=
"pageIndex-1>0"
(
click
)="
pageIndex =
pageIndex-2;updatePagedItems()"
>
{{pageIndex-1}}
</a>
<li
class=
"page-item"
*
ngIf=
"pageModal - 1 >= 0"
>
<a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
(
click
)="
pageModal =
pageModal
-
1
;
updatePagedItems
()"
>
{{pageModal}}
</a>
</li>
</li>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"pageIndex>0 && ((pageIndex-1)*10 < (searchText == '' ? excelPortalFilter().length : excelPortalFilter().length))"
(
click
)="
pageIndex =
pageIndex-1;updatePagedItems()"
>
{{pageIndex}}
</a></li>
<li
class=
"page-item"
><a
class=
"page-link active px-3 py-[0.375rem]"
<li
class=
"page-item"
><a
class=
"page-link active px-3 py-[0.375rem]"
href=
"javascript:void(0);"
>
{{page
Index +
1}}
</a>
href=
"javascript:void(0);"
>
{{page
Modal +
1}}
</a>
</li>
</li>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"(pageIndex+1)*10 < (searchText == '' ? excelPortalFilter().length : excelPortalFilter().length)"
<li
class=
"page-item"
(
click
)="
pageIndex =
pageIndex+1;updatePagedItems()"
>
{{pageIndex +2}}
</a></li>
*
ngIf=
"(pageModal + 1) * pageSizeModal < excelPortalFilter().length"
>
<li
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
<a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
*
ngIf=
"(pageIndex+2)*10 < (searchText == '' ? excelPortalFilter().length : excelPortalFilter().length)"
(
click
)="
pageModal =
pageModal
+
1
;
updatePagedItems
()"
>
{{pageModal + 2}}
</a>
(
click
)="
pageIndex =
pageIndex+2;updatePagedItems()"
>
{{pageIndex +3}}
</a></li>
</li>
<li
*
ngIf=
"(pageIndex+1)*10 < (searchText == '' ? excelPortalFilter().length : excelPortalFilter().length)"
<li
class=
"page-item"
*
ngIf=
"(pageModal + 2) * pageSizeModal < excelPortalFilter().length"
>
<a
class=
"page-link px-3 py-[0.375rem]"
href=
"javascript:void(0);"
(
click
)="
pageModal =
pageModal
+
2
;
updatePagedItems
()"
>
{{pageModal + 3}}
</a>
</li>
<li
*
ngIf=
"(pageModal + 1) * pageSizeModal < excelPortalFilter().length"
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
class=
"page-item"
><a
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
(
click
)="
page
Index =
pageIndex+1;
updatePagedItems()"
>
{{'Next' |
(
click
)="
page
Modal =
pageModal
+
1
;
updatePagedItems
()"
>
{{'Next' |
translate}}
</a>
translate}}
</a>
</li>
</li>
</ul>
</ul>
...
@@ -689,9 +698,8 @@
...
@@ -689,9 +698,8 @@
</div>
</div>
</div>
</div>
<div
class=
"border-t mt-3"
>
<div
class=
"mt-3"
>
<div
class=
"ti-modal-footer flex justify-end gap-3 mb-3 mt-3 mr-3"
>
<div
class=
"ti-modal-footer flex justify-center gap-3 mb-3 mt-3"
>
<button
type=
"button"
class=
"ti-btn bg-danger text-white !font-medium"
<button
type=
"button"
class=
"ti-btn bg-danger text-white !font-medium"
(
click
)="
closeModalexcel_portal
()"
>
(
click
)="
closeModalexcel_portal
()"
>
{{'Cancel' | translate}}
{{'Cancel' | translate}}
...
@@ -911,7 +919,7 @@
...
@@ -911,7 +919,7 @@
</tbody>
</tbody>
<tbody
*
ngIf=
"valueDetailFilter().length"
>
<tbody
*
ngIf=
"valueDetailFilter().length"
>
<tr
class=
"cursor-pointer"
<tr
class=
"cursor-pointer"
*
ngFor=
"let item of valueDetailFilter() | slice:
(pageModal-1) * pageSizeModal : (pageModal-1) * pageSizeModal +
pageSizeModal; let i=index"
*
ngFor=
"let item of valueDetailFilter() | slice:
pageModal * pageSizeModal : (pageModal+1) *
pageSizeModal; let i=index"
(
click
)="
selectData
(
item
);
closeModalmodalData
()"
(
click
)="
selectData
(
item
);
closeModalmodalData
()"
(
mouseenter
)="
tableHover
.
set
(
item
.
id
,!
tableHover
.
get
(
item
.
id
))"
(
mouseenter
)="
tableHover
.
set
(
item
.
id
,!
tableHover
.
get
(
item
.
id
))"
(
mouseleave
)="
tableHover
.
clear
()"
(
mouseleave
)="
tableHover
.
clear
()"
...
@@ -950,7 +958,7 @@
...
@@ -950,7 +958,7 @@
<div
class=
"ms-auto"
>
<div
class=
"ms-auto"
>
<nav
aria-label=
"Page navigation"
>
<nav
aria-label=
"Page navigation"
>
<ul
class=
"ti-pagination mb-0"
>
<ul
class=
"ti-pagination mb-0"
>
<li
*
ngIf=
"page
Index
>0"
class=
"page-item {{pageModal==0 ? 'disabled' : ''}}"
><a
<li
*
ngIf=
"page
Modal
>0"
class=
"page-item {{pageModal==0 ? 'disabled' : ''}}"
><a
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
class=
"page-link px-3 py-[0.375rem] cursor-pointer"
(
click
)="
pageModal =
pageModal-1;updatePagedItems()"
>
{{'Previous' |
(
click
)="
pageModal =
pageModal-1;updatePagedItems()"
>
{{'Previous' |
translate}}
</a></li>
translate}}
</a></li>
...
@@ -1086,9 +1094,9 @@
...
@@ -1086,9 +1094,9 @@
</app-pivot-syncfution>
</app-pivot-syncfution>
</div>
</div>
<div
class=
"border-t"
>
<div
class=
"border-t
mt-3
"
>
<div
class=
"ti-modal-footer flex justify-end gap-3 mb-3 mt-3 mr-3"
>
<div
class=
"ti-modal-footer flex justify-end gap-3 mb-3 mt-3 mr-3"
>
<button
*
ngIf=
"!loadingExcel"
type=
"button"
class=
"
btn btn-info
"
<button
*
ngIf=
"!loadingExcel"
type=
"button"
class=
"
ti-btn ti-btn-info-full
"
(
click
)="
pivotLayout
.
stimulate=
!pivotLayout.stimulate;savePerspective('pivot')"
>
(
click
)="
pivotLayout
.
stimulate=
!pivotLayout.stimulate;savePerspective('pivot')"
>
{{"Save Perspective"}}
{{"Save Perspective"}}
</button>
</button>
...
...
src/app/DPU/common/myportal/set-excel-reports/excel-list/excel-list.component.ts
View file @
83db1670
...
@@ -58,11 +58,12 @@ export class ExcelListComponent implements OnInit {
...
@@ -58,11 +58,12 @@ export class ExcelListComponent implements OnInit {
template
:
{
data
:
TemplateModel
[],
filter
:
TemplateModel
[],
loading
:
boolean
}
=
{
data
:
[],
filter
:
[],
loading
:
false
}
template
:
{
data
:
TemplateModel
[],
filter
:
TemplateModel
[],
loading
:
boolean
}
=
{
data
:
[],
filter
:
[],
loading
:
false
}
templateFile
:
TemplateFileModel
=
new
MyTemplateFileModel
()
templateFile
:
TemplateFileModel
=
new
MyTemplateFileModel
()
module
:
{
data
:
ModuleModel
[],
loading
:
boolean
}
=
{
data
:
[],
loading
:
false
}
module
:
{
data
:
ModuleModel
[],
loading
:
boolean
}
=
{
data
:
[],
loading
:
false
}
pagedItems
:
TemplateModel
[]
=
[];
pageIndex
:
number
=
0
;
pageIndex
:
number
=
0
;
itemsPerPage
:
number
=
10
;
itemsPerPage
:
number
=
10
;
page
=
1
page
=
0
pageSize
=
10
pageSize
=
10
pageModal
=
1
pageModal
=
0
pageSizeModal
=
10
pageSizeModal
=
10
searchBy
=
''
searchBy
=
''
condition
=
''
condition
=
''
...
@@ -150,8 +151,8 @@ export class ExcelListComponent implements OnInit {
...
@@ -150,8 +151,8 @@ export class ExcelListComponent implements OnInit {
modalRefvideoModal
:
any
;
modalRefvideoModal
:
any
;
modalRefprintModal
:
any
;
modalRefprintModal
:
any
;
modalRefmodalData
:
any
;
modalRefmodalData
:
any
;
modalRefgridModal
:
any
;
modalRefgridModal
:
MatDialogRef
<
any
>
;
modalRefpivotModal
:
any
;
modalRefpivotModal
:
MatDialogRef
<
any
>
;
searchText
:
string
=
''
;
searchText
:
string
=
''
;
@
ViewChild
(
'addGroupModal'
)
addGroupModal
!
:
TemplateRef
<
any
>
;
@
ViewChild
(
'addGroupModal'
)
addGroupModal
!
:
TemplateRef
<
any
>
;
...
@@ -195,12 +196,15 @@ export class ExcelListComponent implements OnInit {
...
@@ -195,12 +196,15 @@ export class ExcelListComponent implements OnInit {
this
.
pageIndex
=
index
;
this
.
pageIndex
=
index
;
this
.
updatePagedItems
();
this
.
updatePagedItems
();
}
}
updatePagedItems
():
void
{
updatePagedItems
()
{
const
start
=
this
.
pageIndex
*
this
.
itemsPerPage
;
const
data
=
this
.
searchText
==
''
?
this
.
template
.
data
:
this
.
template
.
filter
;
const
end
=
start
+
this
.
itemsPerPage
;
const
source
=
this
.
searchText
==
''
?
this
.
template
.
data
:
this
.
template
.
filter
;
const
start
=
this
.
page
*
this
.
pageSize
;
// ถ้า page = 1 → เริ่มที่ index 10
this
.
template
.
filter
=
source
.
slice
(
start
,
end
);
const
end
=
start
+
this
.
pageSize
;
this
.
pagedItems
=
data
.
slice
(
start
,
end
);
}
}
getExcelPortalList
()
{
getExcelPortalList
()
{
this
.
excelPortal
.
loading
=
true
this
.
excelPortal
.
loading
=
true
this
.
excelReportService
.
getExcelPortalList
().
subscribe
(
response
=>
{
this
.
excelReportService
.
getExcelPortalList
().
subscribe
(
response
=>
{
...
@@ -343,8 +347,8 @@ export class ExcelListComponent implements OnInit {
...
@@ -343,8 +347,8 @@ export class ExcelListComponent implements OnInit {
}
}
openExcelPortalModal
()
{
openExcelPortalModal
()
{
this
.
pageModal
=
1
;
this
.
pageModal
=
0
;
this
.
pageSizeModal
=
10
;
this
.
pageSizeModal
=
5
;
this
.
modalRefexcel_portal
=
this
.
modal
.
open
(
this
.
excel_portalModal
,
{
this
.
modalRefexcel_portal
=
this
.
modal
.
open
(
this
.
excel_portalModal
,
{
width
:
'1500px'
,
width
:
'1500px'
,
...
@@ -802,7 +806,7 @@ export class ExcelListComponent implements OnInit {
...
@@ -802,7 +806,7 @@ export class ExcelListComponent implements OnInit {
this
.
dataList
=
response
.
excelData
as
any
this
.
dataList
=
response
.
excelData
as
any
this
.
loadingExcel
=
false
this
.
loadingExcel
=
false
if
(
type
===
'grid'
)
{
if
(
type
===
'grid'
)
{
this
.
modal
.
open
(
this
.
gridModal
,
{
this
.
modal
RefgridModal
=
this
.
modal
.
open
(
this
.
gridModal
,
{
width
:
'1000px'
,
width
:
'1000px'
,
height
:
'700px'
,
height
:
'700px'
,
data
:
{
data
:
{
...
@@ -813,8 +817,8 @@ export class ExcelListComponent implements OnInit {
...
@@ -813,8 +817,8 @@ export class ExcelListComponent implements OnInit {
autoFocus
:
false
autoFocus
:
false
});
});
}
else
if
(
type
===
'pivot'
)
{
}
else
if
(
type
===
'pivot'
)
{
this
.
modal
.
open
(
this
.
pivotModal
,
{
this
.
modal
RefpivotModal
=
this
.
modal
.
open
(
this
.
pivotModal
,
{
width
:
'
8
00px'
,
width
:
'
10
00px'
,
height
:
'580px'
,
height
:
'580px'
,
data
:
{
data
:
{
pivotData
:
(
response
.
excelPerspective
as
any
).
pivotStr
,
pivotData
:
(
response
.
excelPerspective
as
any
).
pivotStr
,
...
@@ -939,7 +943,7 @@ export class ExcelListComponent implements OnInit {
...
@@ -939,7 +943,7 @@ export class ExcelListComponent implements OnInit {
closeModalgridModal
()
{
closeModalgridModal
()
{
this
.
modalRefgridModal
?.
close
()
this
.
modalRefgridModal
?.
close
()
}
}
closeModalpivotModal
()
{
closeModalpivotModal
()
{
this
.
modalRefpivotModal
?.
close
()
this
.
modalRefpivotModal
?.
close
()
}
}
...
...
src/styles.scss
View file @
83db1670
...
@@ -31,6 +31,23 @@
...
@@ -31,6 +31,23 @@
@import
"../node_modules/angular-calendar/scss/angular-calendar.scss"
;
@import
"../node_modules/angular-calendar/scss/angular-calendar.scss"
;
@import
'../node_modules/quill/dist/quill.core.css'
;
@import
'../node_modules/quill/dist/quill.core.css'
;
@import
'../node_modules/quill/dist/quill.snow.css'
;
@import
'../node_modules/quill/dist/quill.snow.css'
;
@import
url('https://fonts.googleapis.com/css?family=Nunito+Sans:300,400,600,700,800')
;
@import
url("https://fonts.googleapis.com/css?family=Kanit:300,400,600,700,800")
;
@import
url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css")
;
@import
'../node_modules/@syncfusion/ej2-base/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-buttons/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-calendars/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-dropdowns/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-inputs/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-navigations/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-popups/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-splitbuttons/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-angular-grids/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-grids/styles/material.css'
;
@import
'../node_modules/@syncfusion/ej2-lists/styles/material.css'
;
@import
"../node_modules/@syncfusion/ej2-splitbuttons/styles/material.css"
;
@import
'../node_modules/@syncfusion/ej2-angular-pivotview/styles/material.css'
;
// @import "../node_modules/angular-calendar/scss/angular-calendar.scss";
// @import "../node_modules/angular-calendar/scss/angular-calendar.scss";
//swiperjs
//swiperjs
...
...
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