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
df379163
Commit
df379163
authored
Nov 17, 2022
by
Kang Donghun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add function that display pdfprint button on reportForm
parent
296597ca
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
53 additions
and
7 deletions
+53
-7
abweb/common/js/common.js
+27
-0
abweb/html/reportForm.html
+0
-4
abweb/js/reportForm/reportForm.js
+21
-2
abweb/js/reportList/reportList.js
+5
-1
No files found.
abweb/common/js/common.js
View file @
df379163
...
@@ -1111,6 +1111,33 @@ COMMON.checkLogin = function (option) {
...
@@ -1111,6 +1111,33 @@ COMMON.checkLogin = function (option) {
return
true
;
return
true
;
}
}
/**
* check quick report
*/
COMMON
.
checkQuickReport
=
function
(
operationId
,
callback
)
{
if
(
operationId
)
{
let
params
=
{};
params
.
sid
=
COMMON
.
getSid
();
params
.
operationId
=
operationId
;
let
url
=
COMMON
.
format
(
ClientData
.
conf_checkApiUrl
(),
ClientData
.
userInfo_accountPath
())
+
CONSTANT
.
URL
.
CMS
.
API
.
IS_QUICK_REPORT
;
COMMON
.
cmsAjax
(
url
,
params
,
false
,
function
(
result
)
{
if
(
callback
)
callback
(
result
);
},
function
()
{
COMMON
.
showAlert
(
'msgOperationEmpty'
);
COMMON
.
avwScreenMove
(
'index.html'
);
},
);
}
else
{
COMMON
.
showAlert
(
'error'
);
COMMON
.
avwScreenMove
(
'index.html'
);
}
};
/*
/*
* Operations for session storage [ end ]
* Operations for session storage [ end ]
*/
*/
...
...
abweb/html/reportForm.html
View file @
df379163
...
@@ -35,10 +35,6 @@
...
@@ -35,10 +35,6 @@
<div
id=
"includedMainTitle"
></div>
<div
id=
"includedMainTitle"
></div>
<div
class=
"quickReportBtn"
id=
"quickReportBtn"
onclick=
"submitForm();"
>
<img
src=
"../common/img/icon_pdf.svg"
alt=
"pdf出力"
class=
"p-1 w-40px"
data-toggle=
"tooltip"
data-placement=
"bottom"
title=
"pdfPrint"
>
</div>
<!-- report list -->
<!-- report list -->
<div
class=
"mb-5"
id=
"report-form"
></div>
<div
class=
"mb-5"
id=
"report-form"
></div>
...
...
abweb/js/reportForm/reportForm.js
View file @
df379163
...
@@ -5,13 +5,18 @@
...
@@ -5,13 +5,18 @@
var
RF
=
{};
var
RF
=
{};
RF
.
isQuickReport
;
/**
/**
* init
* init
*/
*/
RF
.
init
=
function
()
{
RF
.
init
=
function
()
{
//Check if user is logged in
//Check if user is logged in
COMMON
.
checkAuth
(
false
);
COMMON
.
checkAuth
(
false
);
const
operationId
=
sessionStorage
.
getItem
(
"operationId"
);
COMMON
.
checkQuickReport
(
operationId
,
function
(
result
)
{
RF
.
isQuickReport
=
result
.
isQuickReport
;
})
RF
.
loadCommon
();
RF
.
loadCommon
();
RF
.
initFormView
();
RF
.
initFormView
();
};
};
...
@@ -106,10 +111,24 @@ RF.initBreadcrumb = function () {
...
@@ -106,10 +111,24 @@ RF.initBreadcrumb = function () {
]
]
}
}
}
}
TEMPLATE
.
loadMainNavsTitle
(
'#includedMainTitle'
,
CONSTANT
.
PAGE_NAME
.
REPORT_FORM
,
navs
,
null
);
TEMPLATE
.
loadMainNavsTitle
(
'#includedMainTitle'
,
CONSTANT
.
PAGE_NAME
.
REPORT_FORM
,
navs
,
RF
.
loadMainTitleCallback
);
}
}
/**
/**
* load main title callcack
*/
RF
.
loadMainTitleCallback
=
function
()
{
//add dashboard setting item
if
(
RF
.
isQuickReport
)
{
var
elmA
=
$
(
'<div class="quickReportBtn" id="quickReportBtn" onclick="submitForm();">'
);
let
elmImg
=
$
(
'<img src="../common/img/icon_pdf.svg" alt="pdf出力" class="p-1 w-40px" data-toggle="tooltip" data-placement="bottom" title="pdfPrint">'
);
elmImg
.
attr
(
'title'
,
I18N
.
i18nText
(
'reportForm'
));
elmA
.
append
(
elmImg
);
$
(
'#mainTitleHeader'
).
after
(
elmA
);
}
};
/**
* iinit form view
* iinit form view
*/
*/
RF
.
initFormView
=
function
()
{
RF
.
initFormView
=
function
()
{
...
...
abweb/js/reportList/reportList.js
View file @
df379163
...
@@ -14,6 +14,10 @@ RL.init = function () {
...
@@ -14,6 +14,10 @@ RL.init = function () {
COMMON
.
showLoading
();
COMMON
.
showLoading
();
COMMON
.
checkAuth
(
false
);
COMMON
.
checkAuth
(
false
);
console
.
log
(
'ReportList init start'
);
console
.
log
(
'ReportList init start'
);
const
operationId
=
sessionStorage
.
getItem
(
"operationId"
);
COMMON
.
checkQuickReport
(
operationId
,
function
(
result
)
{
RL
.
isQuickReport
=
result
.
isQuickReport
;
})
RL
.
checkQuickReport
();
RL
.
checkQuickReport
();
RL
.
loadCommon
();
RL
.
loadCommon
();
RL
.
initTaskReportList
();
RL
.
initTaskReportList
();
...
@@ -117,7 +121,7 @@ RL.loadMainTitleCallback = function () {
...
@@ -117,7 +121,7 @@ RL.loadMainTitleCallback = function () {
//add dashboard setting item
//add dashboard setting item
if
(
RL
.
isQuickReport
)
{
if
(
RL
.
isQuickReport
)
{
var
elmA
=
$
(
'<div id="btnPdfPrint" onclick="RL.goPdfPrint();">'
);
var
elmA
=
$
(
'<div id="btnPdfPrint" onclick="RL.goPdfPrint();">'
);
let
elmImg
=
$
(
'<img src="../common/img/icon_pdf.svg" alt="pdf出力" class="p-1 w-40px" data-toggle="tooltip" data-placement="bottom" title="pdf
出力
">'
);
let
elmImg
=
$
(
'<img src="../common/img/icon_pdf.svg" alt="pdf出力" class="p-1 w-40px" data-toggle="tooltip" data-placement="bottom" title="pdf
Print
">'
);
elmImg
.
attr
(
'title'
,
I18N
.
i18nText
(
'reportList'
));
elmImg
.
attr
(
'title'
,
I18N
.
i18nText
(
'reportList'
));
elmA
.
append
(
elmImg
);
elmA
.
append
(
elmImg
);
$
(
'#mainTitleHeader'
).
after
(
elmA
);
$
(
'#mainTitleHeader'
).
after
(
elmA
);
...
...
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