Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
check
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
abook_web
check
Commits
3232b92a
Commit
3232b92a
authored
Nov 01, 2022
by
NGUYEN HOANG SON
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#50293 load operation select, template select modal
parent
f162edb3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
7 deletions
+20
-7
abvw/html/send-message.html
+2
-0
abvw/js/sendMessage/send-message.js
+18
-7
No files found.
abvw/html/send-message.html
View file @
3232b92a
...
@@ -25,6 +25,8 @@
...
@@ -25,6 +25,8 @@
<script
src=
"../common/js/constant.js?__UPDATEID__"
></script>
<script
src=
"../common/js/constant.js?__UPDATEID__"
></script>
<script
src=
"../common/js/common.js?__UPDATEID__"
></script>
<script
src=
"../common/js/common.js?__UPDATEID__"
></script>
<script
type=
"text/javascript"
src=
"../js/operationSelect/operation-select.js"
></script>
<script
type=
"text/javascript"
src=
"../js/notification-content/notification-content.js"
></script>
<script
type=
"text/javascript"
src=
"../js/template/template.js"
></script>
<script
type=
"text/javascript"
src=
"../js/template/template.js"
></script>
<script
type=
"text/javascript"
src=
"../js/sendMessage/send-message.js"
></script>
<script
type=
"text/javascript"
src=
"../js/sendMessage/send-message.js"
></script>
</head>
</head>
...
...
abvw/js/sendMessage/send-message.js
View file @
3232b92a
...
@@ -8,24 +8,33 @@ var SendMessage = {};
...
@@ -8,24 +8,33 @@ var SendMessage = {};
SendMessage
.
baseApiUrl
=
CONSTANT
.
URL
.
CMS
.
BASE
+
ClientData
.
userInfo_accountPath
()
+
CONSTANT
.
URL
.
CMS
.
API
.
BASE
+
'sendPushMessage/'
;
SendMessage
.
baseApiUrl
=
CONSTANT
.
URL
.
CMS
.
BASE
+
ClientData
.
userInfo_accountPath
()
+
CONSTANT
.
URL
.
CMS
.
API
.
BASE
+
'sendPushMessage/'
;
/**
/**
* default JSON
* Get input content
* @returns string
*/
*/
SendMessage
.
dummyJson
=
{
}
SendMessage
.
getCurrentMessageContent
=
function
()
{
SendMessage
.
getCurrentMessageContent
=
function
()
{
return
$
(
'#messageContent'
).
val
();
return
$
(
'#messageContent'
).
val
();
}
}
/**
* Get operation id selected
* @returns string
*/
SendMessage
.
getCurrentOperationId
=
function
()
{
SendMessage
.
getCurrentOperationId
=
function
()
{
return
$
(
'#operationSelected'
).
attr
(
'data-operation-id'
);
return
$
(
'#operationSelected'
).
attr
(
'data-operation-id'
);
}
}
/**
* Get send type selected
* @returns string
*/
SendMessage
.
getCurrentSendType
=
function
()
{
SendMessage
.
getCurrentSendType
=
function
()
{
return
$
(
'input[name="sendType"]:checked'
).
val
();
return
$
(
'input[name="sendType"]:checked'
).
val
();
}
}
/**
* Check data required when send message request to cms
* @returns boolean
*/
SendMessage
.
checkValidation
=
function
()
{
SendMessage
.
checkValidation
=
function
()
{
const
message
=
SendMessage
.
getCurrentMessageContent
();
const
message
=
SendMessage
.
getCurrentMessageContent
();
if
(
!
ValidationUtil
.
CheckRequiredForText
(
message
))
{
if
(
!
ValidationUtil
.
CheckRequiredForText
(
message
))
{
...
@@ -83,9 +92,11 @@ SendMessage.postMessage = function(message, operationId, sendType) {
...
@@ -83,9 +92,11 @@ SendMessage.postMessage = function(message, operationId, sendType) {
* init data, action when screen onload
* init data, action when screen onload
*/
*/
SendMessage
.
init
=
function
()
{
SendMessage
.
init
=
function
()
{
I18N
.
initi18n
();
TEMPLATE
.
loadHearder
(
"#includedHeader"
);
TEMPLATE
.
loadHearder
();
TEMPLATE
.
loadOperationSelect
(
'#includeOperationSelect'
);
TEMPLATE
.
loadNotificationSelect
(
'#includeTemplateModal'
);
//load lang for elements none class lang
//load lang for elements none class lang
I18N
.
initi18n
();
document
.
title
=
I18N
.
i18nText
(
'sendMessageTitle'
);
document
.
title
=
I18N
.
i18nText
(
'sendMessageTitle'
);
$
(
"label[for='sendTypeGroup']"
).
append
(
I18N
.
i18nText
(
'labelSendTypeGroup'
));
$
(
"label[for='sendTypeGroup']"
).
append
(
I18N
.
i18nText
(
'labelSendTypeGroup'
));
$
(
"label[for='sendTypeAll']"
).
append
(
I18N
.
i18nText
(
'labelSendTypeAll'
));
$
(
"label[for='sendTypeAll']"
).
append
(
I18N
.
i18nText
(
'labelSendTypeAll'
));
...
...
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