Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
U
useranalytics
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
reynaldi adriantama
useranalytics
Commits
6f5e0b0f
Commit
6f5e0b0f
authored
4 years ago
by
Anggi Saputra
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tble
parent
f441d5d9
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
329 additions
and
0 deletions
+329
-0
public/template/js/demo/table-user-browser.js
public/template/js/demo/table-user-browser.js
+45
-0
public/template/js/demo/table-user-button.js
public/template/js/demo/table-user-button.js
+45
-0
public/template/js/demo/table-user-image.js
public/template/js/demo/table-user-image.js
+41
-0
public/template/js/demo/table-user-info.js
public/template/js/demo/table-user-info.js
+71
-0
public/template/js/demo/table-user-other.js
public/template/js/demo/table-user-other.js
+41
-0
public/template/js/demo/table-user-page.js
public/template/js/demo/table-user-page.js
+45
-0
public/template/js/demo/table-user-video.js
public/template/js/demo/table-user-video.js
+41
-0
No files found.
public/template/js/demo/table-user-browser.js
0 → 100644
View file @
6f5e0b0f
// SAVE
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
loadtablebrowser
(
validasiToken
);
function
loadtablebrowser
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadtablebrowser
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
let
data
=
result
.
data
;
console
.
log
(
data
);
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
browser_name
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
browser_ver
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tbluserwebbrowser
"
).
append
(
cols
);
counter
++
;
}
// console.log(data);
}
});
})
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
public/template/js/demo/table-user-button.js
0 → 100644
View file @
6f5e0b0f
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
loadtablebutton
(
validasiToken
);
function
loadtablebutton
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadtablebutton
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
let
data
=
result
.
data
;
console
.
log
(
data
);
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
nodebtn
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
date
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
time
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tbluserwebbtn
"
).
append
(
cols
);
counter
++
;
}
// console.log(data);
}
});
})
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
public/template/js/demo/table-user-image.js
0 → 100644
View file @
6f5e0b0f
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
loadtablepage
(
validasiToken
);
function
loadtablepage
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadtableimage
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
let
data
=
result
.
data
;
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
nodeimage
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
date
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
time
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tbluserwebimage
"
).
append
(
cols
);
counter
++
;
}
}
});
})
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
public/template/js/demo/table-user-info.js
0 → 100644
View file @
6f5e0b0f
loadUserWebsite
(
validasiToken
);
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
function
loadUserWebsite
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loaduserweb
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
if
(
result
){
let
data
=
result
.
data
;
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
mac_address
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
city
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
browser_name
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_public
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
date_first_visit
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tbluserwebinfo
"
).
append
(
cols
);
counter
++
;
}
$
(
'
#dataTable
'
).
DataTable
({
scrollY
:
'
350px
'
,
scrollX
:
false
,
fixedHeader
:
true
,
scrollCollapse
:
true
,
autoWidth
:
false
,
paging
:
true
,
columnDefs
:
[
{
width
:
30
,
targets
:
0
},
{
width
:
200
,
targets
:
1
},
{
width
:
200
,
targets
:
2
},
{
width
:
150
,
targets
:
3
},
{
width
:
150
,
targets
:
4
},
{
width
:
200
,
targets
:
5
},
{
width
:
150
,
targets
:
6
},
],
});
}
else
{
alert
(
result
.
info
);
}
},
error
:
function
(
xhr
){
alert
(
xhr
.
status
+
'
-
'
+
xhr
.
statusText
);
}
});
});
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
public/template/js/demo/table-user-other.js
0 → 100644
View file @
6f5e0b0f
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
loadtablepage
(
validasiToken
);
function
loadtablepage
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadtableother
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
let
data
=
result
.
data
;
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
nodeother
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
date
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
time
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tbluserwebother
"
).
append
(
cols
);
counter
++
;
}
}
});
})
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
public/template/js/demo/table-user-page.js
0 → 100644
View file @
6f5e0b0f
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
loadtablepage
(
validasiToken
);
function
loadtablepage
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadtablepage
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
let
data
=
result
.
data
;
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
name_page
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
date_access
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
time_access
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
total_time
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tabeluserwebpage
"
).
append
(
cols
);
counter
++
;
}
// console.log(data);
}
});
})
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
public/template/js/demo/table-user-video.js
0 → 100644
View file @
6f5e0b0f
var
tableToExcel
=
(
function
()
{
var
uri
=
'
data:application/vnd.ms-excel;base64,
'
,
template
=
'
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><meta http-equiv="content-type" content="text/plain; charset=UTF-8"/></head><body><table>{table}</table></body></html>
'
,
base64
=
function
(
s
)
{
return
window
.
btoa
(
unescape
(
encodeURIComponent
(
s
)))
}
,
format
=
function
(
s
,
c
)
{
return
s
.
replace
(
/{
(\w
+
)
}/g
,
function
(
m
,
p
)
{
return
c
[
p
];
})
}
return
function
(
table
,
name
)
{
if
(
!
table
.
nodeType
)
table
=
document
.
getElementById
(
table
)
var
ctx
=
{
worksheet
:
name
||
'
Worksheet
'
,
table
:
table
.
innerHTML
}
window
.
location
.
href
=
uri
+
base64
(
format
(
template
,
ctx
))
}
})();
loadtablepage
(
validasiToken
);
function
loadtablepage
(
token
){
$
(
document
).
ready
(
function
(){
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadtablevideo
'
,
data
:
{
token
:
token
,
},
success
:
function
(
result
){
let
data
=
result
.
data
;
let
counter
=
1
;
for
(
z
in
data
){
var
cols
=
""
;
cols
+=
'
<tr>
'
cols
+=
'
<td>
'
+
counter
+
'
</td>
'
cols
+=
'
<td>
'
+
data
[
z
].
ip_address_client
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
nodevideo
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
date
+
'
</td>
'
;
cols
+=
'
<td>
'
+
data
[
z
].
time
+
'
</td>
'
;
cols
+=
'
</tr>
'
$
(
"
#tbluserwebvideo
"
).
append
(
cols
);
counter
++
;
}
}
});
})
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
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