Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
design
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abookCheck
design
Commits
6e4fc5ac
Commit
6e4fc5ac
authored
Aug 17, 2022
by
NGUYEN HOANG SON
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
implement dashboard items data, action
parent
25d81d19
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
69 additions
and
50 deletions
+69
-50
app/index.html
+69
-50
No files found.
app/index.html
View file @
6e4fc5ac
...
...
@@ -180,56 +180,11 @@
<section
class=
"container-fluid main-section"
>
<main>
<h2
class=
"fs-8 font-weight-bold mt-4 pb-2 border-bottom text-dark multi-lang"
data-msg=
"pickupHeaderTitle"
>
ピックアップ
</h2>
<div
class=
"item-wrap"
>
<div
class=
"item"
>
<a
href=
"pickup.html"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_new.svg"
alt=
"新規報告"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"newRegistrationTitle"
>
新規報告
</div>
</a>
</div>
<div
class=
"item"
>
<a
href=
"pickup.html"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_proccess.svg"
alt=
"工程管理"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"continousWorkTitle"
>
工程管理
</div>
<span
class=
"count fs-7"
>
30
</span>
</a>
</div>
<div
class=
"item"
>
<a
href=
"pickup.html"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_alert.svg"
alt=
"警告を含む報告"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"reportWarningTitle"
>
警告を含む報告
</div>
<span
class=
"count fs-7"
>
99+
</span>
</a>
</div>
<div
class=
"item-wrap"
id=
"pickupItems"
>
</div>
<h2
class=
"fs-8 font-weight-bold mt-4 pb-2 border-bottom text-dark multi-lang"
data-msg=
"communicationHeaderTitle"
>
コミュニケーション
</h2>
<div
class=
"item-wrap"
>
<div
class=
"item"
>
<a
href=
"message-list.html"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_message_lsit.svg"
alt=
"メッセージ一覧"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"messageListTitle"
>
メッセージ一覧
</div>
<span
class=
"count fs-7"
>
2
</span>
</a>
</div>
<div
class=
"item"
>
<a
href=
"#"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_send_message.svg"
alt=
"メッセージ送信"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"sendMessageTitle"
>
メッセージ送信
</div>
</a>
</div>
<div
class=
"item"
>
<a
href=
"#"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_remote.svg"
alt=
"遠隔支援"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"distanceSupportTitle"
>
遠隔支援
</div>
</a>
</div>
<div
class=
"item"
>
<a
href=
"#"
class=
"d-block text-dark text-decoration-none mb-1 p-3"
>
<img
src=
"img/icon_chat.svg"
alt=
"チャット"
>
<div
class=
"fs-8 multi-lang"
data-msg=
"chatTitle"
>
チャット
</div>
</a>
</div>
<div
class=
"item-wrap"
id=
"communicationItems"
>
</div>
</main>
</section>
...
...
@@ -238,11 +193,11 @@
<footer
class=
"fixed-bottom bg-light"
>
<nav
class=
"d-flex justify-content-around"
>
<a
class=
"d-block w-100 text-center py-2 text-decoration-none text-secondary bottom-nav"
onclick=
"clickBottomNav('dashboard', this);"
>
<a
class=
"d-block w-100 text-center py-2 text-decoration-none text-secondary bottom-nav"
onclick=
"
CHK_Dashboard.
clickBottomNav('dashboard', this);"
>
<img
src=
"img/icon_dashboard_inactive.svg"
data-inactive-src=
"img/icon_dashboard_inactive.svg"
data-src=
"img/icon_dashboard.svg"
alt=
"ダッシュボード"
class=
"p-1"
>
<div
class=
"fs-7 multi-lang"
data-msg=
"buttonDashboard"
>
ダッシュボード
</div>
</a>
<a
class=
"d-block w-100 text-center py-2 text-decoration-none text-primary bottom-nav"
onclick=
"clickBottomNav('operationList', this);"
>
<a
class=
"d-block w-100 text-center py-2 text-decoration-none text-primary bottom-nav"
onclick=
"
CHK_Dashboard.
clickBottomNav('operationList', this);"
>
<i
class=
"fas fa-tasks fs-14 p-1"
></i>
<div
class=
"fs-7 multi-lang"
data-msg=
"buttonOperationList"
>
作業一覧
</div>
</a>
...
...
@@ -280,7 +235,67 @@
</body>
<script>
function
clickBottomNav
(
pageId
,
elm
)
{
var
CHK_Dashboard
=
{};
CHK_Dashboard
.
pickupItems
=
[
{
id
:
'newReport'
,
href
:
'pickup.html'
,
count
:
0
,
enabled
:
true
,
img
:
{
src
:
'img/icon_message_lsit.svg'
},
msg
:
'newRegistrationTitle'
},
{
id
:
'continousWork'
,
href
:
'pickup.html'
,
count
:
88
,
enabled
:
true
,
img
:
{
src
:
'img/icon_proccess.svg'
},
msg
:
'continousWorkTitle'
},
{
id
:
'reportWarning'
,
href
:
'pickup.html'
,
count
:
0
,
enabled
:
true
,
img
:
{
src
:
'img/icon_alert.svg'
},
msg
:
'reportWarningTitle'
},
];
CHK_Dashboard
.
communicationItems
=
[
{
id
:
'messageList'
,
href
:
'message-list.html'
,
count
:
77
,
enabled
:
true
,
img
:
{
src
:
'img/icon_new.svg'
},
msg
:
'messageListTitle'
},
{
id
:
'sendMessage'
,
href
:
''
,
count
:
0
,
enabled
:
true
,
img
:
{
src
:
'img/icon_send_message.svg'
},
msg
:
'sendMessageTitle'
},
{
id
:
'distanceSupport'
,
href
:
''
,
count
:
0
,
enabled
:
true
,
img
:
{
src
:
'img/icon_remote.svg'
},
msg
:
'distanceSupportTitle'
},
{
id
:
'chat'
,
href
:
''
,
count
:
0
,
enabled
:
true
,
img
:
{
src
:
'img/icon_chat.svg'
},
msg
:
'chatTitle'
},
];
CHK_Dashboard
.
initPickups
=
function
()
{
$
(
"#pickupItems"
).
empty
();
CHK_Dashboard
.
pickupItems
.
forEach
(
function
(
item
)
{
if
(
item
.
enabled
==
true
)
{
var
html
=
CHK_Dashboard
.
initHtmlItem
(
item
);
$
(
"#pickupItems"
).
append
(
html
);
}
});
}
CHK_Dashboard
.
initCommunications
=
function
()
{
$
(
"#communicationItems"
).
empty
();
CHK_Dashboard
.
communicationItems
.
forEach
(
function
(
item
)
{
if
(
item
.
enabled
==
true
)
{
var
html
=
CHK_Dashboard
.
initHtmlItem
(
item
);
$
(
"#communicationItems"
).
append
(
html
);
}
});
}
CHK_Dashboard
.
initHtmlItem
=
function
(
item
)
{
var
countText
=
''
+
item
.
count
;
if
(
item
.
count
>=
100
)
{
countText
=
'99+'
;
}
var
countDClass
=
''
;
if
(
typeof
item
.
count
==
'undefined'
||
item
.
count
<
1
)
{
countDClass
=
' d-none'
;
}
var
countSpan
=
'<span class="count fs-7'
+
countDClass
+
'">'
+
countText
+
'</span>'
;
var
html
=
$
(
'<div class="item" id="'
+
item
.
id
+
'">'
+
'<a href="'
+
item
.
href
+
'" class="d-block text-dark text-decoration-none mb-1 p-3">'
+
'<img src="'
+
item
.
img
.
src
+
'">'
+
'<div class="fs-8 multi-lang" data-msg="'
+
item
.
msg
+
'">'
+
getMsg
(
item
.
msg
)
+
'</div>'
+
countSpan
+
'</a>'
+
'</div>'
);
return
html
;
}
CHK_Dashboard
.
init
=
function
()
{
console
.
log
(
"CHK_Dashboard.init"
);
CHK_Dashboard
.
initPickups
();
CHK_Dashboard
.
initCommunications
();
}
CHK_Dashboard
.
clickBottomNav
=
function
(
pageId
,
elm
)
{
var
i
,
pages
,
navs
;
pages
=
document
.
getElementsByClassName
(
"page-content"
);
for
(
i
=
0
;
i
<
pages
.
length
;
i
++
)
{
...
...
@@ -305,6 +320,9 @@
if
(
img
&&
img
.
getAttribute
(
"data-src"
))
{
img
.
src
=
img
.
getAttribute
(
"data-src"
);
}
if
(
pageId
==
'dashboard'
)
{
CHK_Dashboard
.
init
();
}
}
</script>
</html>
\ 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