Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
atlas
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dataplatform
atlas
Commits
05277c27
Commit
05277c27
authored
Jul 28, 2016
by
Shwetha GS
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ATLAS-1064 UI: Pagination for full text search results (Kalyanikashikar via shwethags)
parent
4bc3e738
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
26 deletions
+10
-26
SearchResultLayoutView_tmpl.html
...blic/js/templates/search/SearchResultLayoutView_tmpl.html
+1
-1
TableLayout.js
dashboardv2/public/js/utils/TableLayout.js
+2
-2
SearchResultLayoutView.js
dashboardv2/public/js/views/search/SearchResultLayoutView.js
+6
-23
release-log.txt
release-log.txt
+1
-0
No files found.
dashboardv2/public/js/templates/search/SearchResultLayoutView_tmpl.html
View file @
05277c27
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
<div
class=
"ellipsis"
><span
class=
"searchResult"
style=
" font-size: 16px;"
></span></div>
<div
class=
"ellipsis"
><span
class=
"searchResult"
style=
" font-size: 16px;"
></span></div>
<div
class=
"searchTable"
>
<div
class=
"searchTable"
>
<span
class=
"labelShowRecord pull-left"
data-id=
"pageRecordText"
></span>
<span
class=
"labelShowRecord pull-left"
data-id=
"pageRecordText"
></span>
<div
data-id=
"paginationDiv"
style=
"display:none"
>
<div
data-id=
"paginationDiv"
>
<ul
class=
"pager pull-right"
>
<ul
class=
"pager pull-right"
>
<li>
<li>
<button
class=
"btn"
data-id=
"previousData"
disabled=
true
>
Previous
</button>
<button
class=
"btn"
data-id=
"previousData"
disabled=
true
>
Previous
</button>
...
...
dashboardv2/public/js/utils/TableLayout.js
View file @
05277c27
...
@@ -308,9 +308,9 @@ define(['require',
...
@@ -308,9 +308,9 @@ define(['require',
renderFooterRecords
:
function
(
collectionState
)
{
renderFooterRecords
:
function
(
collectionState
)
{
var
collState
=
collectionState
;
var
collState
=
collectionState
;
var
totalRecords
=
collState
.
totalRecords
||
0
;
var
totalRecords
=
collState
.
totalRecords
||
0
;
var
pageStartIndex
=
totalRecords
?
(
collState
.
currentPage
*
collState
.
pageSize
)
:
1
;
var
pageStartIndex
=
totalRecords
?
(
collState
.
currentPage
*
collState
.
pageSize
)
:
0
;
var
pageEndIndex
=
pageStartIndex
+
this
.
collection
.
length
;
var
pageEndIndex
=
pageStartIndex
+
this
.
collection
.
length
;
this
.
$
(
'[data-id="r_footerRecords"]'
).
html
(
'<h5>Showing '
+
(
totalRecords
?
pageStartIndex
+
1
:
0
)
+
' - '
+
pageEndIndex
+
'</h5>'
);
this
.
$
(
'[data-id="r_footerRecords"]'
).
html
(
'<h5>Showing '
+
(
totalRecords
?
pageStartIndex
+
1
:
1
)
+
' - '
+
pageEndIndex
+
'</h5>'
);
return
this
;
return
this
;
},
},
/**
/**
...
...
dashboardv2/public/js/views/search/SearchResultLayoutView.js
View file @
05277c27
...
@@ -117,18 +117,13 @@ define(['require',
...
@@ -117,18 +117,13 @@ define(['require',
this
.
limit
=
25
;
this
.
limit
=
25
;
this
.
firstFetch
=
true
;
this
.
firstFetch
=
true
;
this
.
fetchList
=
0
;
this
.
fetchList
=
0
;
if
(
options
.
value
.
searchType
===
"dsl"
||
options
.
value
.
type
===
"dsl"
)
{
pagination
=
false
;
this
.
offset
=
0
;
this
.
offset
=
0
;
}
else
{
pagination
=
true
;
}
this
.
commonTableOptions
=
{
this
.
commonTableOptions
=
{
collection
:
this
.
searchCollection
,
collection
:
this
.
searchCollection
,
includeFilter
:
false
,
includeFilter
:
false
,
includePagination
:
pagination
,
includePagination
:
false
,
includePageSize
:
false
,
includePageSize
:
false
,
includeFooterRecords
:
pagination
,
includeFooterRecords
:
false
,
includeSizeAbleColumns
:
false
,
includeSizeAbleColumns
:
false
,
gridOpts
:
{
gridOpts
:
{
emptyText
:
'No Record found!'
,
emptyText
:
'No Record found!'
,
...
@@ -210,11 +205,9 @@ define(['require',
...
@@ -210,11 +205,9 @@ define(['require',
if
(
value
)
{
if
(
value
)
{
if
(
value
.
searchType
)
{
if
(
value
.
searchType
)
{
this
.
searchCollection
.
url
=
"/api/atlas/discovery/search/"
+
value
.
searchType
;
this
.
searchCollection
.
url
=
"/api/atlas/discovery/search/"
+
value
.
searchType
;
if
(
value
.
searchType
===
"dsl"
)
{
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
limit
:
this
.
limit
});
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
limit
:
this
.
limit
});
this
.
offset
=
0
;
this
.
offset
=
0
;
}
}
}
_
.
extend
(
this
.
searchCollection
.
queryParams
,
{
'query'
:
value
.
query
});
_
.
extend
(
this
.
searchCollection
.
queryParams
,
{
'query'
:
value
.
query
});
}
}
Globals
.
searchApiCallRef
=
this
.
searchCollection
.
fetch
({
Globals
.
searchApiCallRef
=
this
.
searchCollection
.
fetch
({
...
@@ -246,7 +239,6 @@ define(['require',
...
@@ -246,7 +239,6 @@ define(['require',
that
.
checkTableFetch
();
that
.
checkTableFetch
();
that
.
offset
=
that
.
offset
-
that
.
limit
;
that
.
offset
=
that
.
offset
-
that
.
limit
;
if
(
that
.
firstFetch
)
{
if
(
that
.
firstFetch
)
{
that
.
ui
.
paginationDiv
.
hide
();
that
.
renderTableLayoutView
();
that
.
renderTableLayoutView
();
}
}
}
}
...
@@ -318,11 +310,6 @@ define(['require',
...
@@ -318,11 +310,6 @@ define(['require',
this
.
$
(
'.fontLoader'
).
hide
();
this
.
$
(
'.fontLoader'
).
hide
();
this
.
$
(
'.searchTable'
).
show
();
this
.
$
(
'.searchTable'
).
show
();
this
.
$
(
'.searchResult'
).
show
();
this
.
$
(
'.searchResult'
).
show
();
if
(
this
.
value
.
searchType
==
"dsl"
||
this
.
value
.
type
===
"dsl"
)
{
this
.
ui
.
paginationDiv
.
show
();
}
else
{
this
.
ui
.
paginationDiv
.
hide
();
}
}
}
},
},
getEntityTableColumns
:
function
()
{
getEntityTableColumns
:
function
()
{
...
@@ -621,11 +608,9 @@ define(['require',
...
@@ -621,11 +608,9 @@ define(['require',
onClicknextData
:
function
()
{
onClicknextData
:
function
()
{
var
that
=
this
;
var
that
=
this
;
this
.
ui
.
previousData
.
removeAttr
(
"disabled"
);
this
.
ui
.
previousData
.
removeAttr
(
"disabled"
);
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
offset
:
function
()
{
that
.
offset
=
that
.
offset
+
that
.
limit
;
that
.
offset
=
that
.
offset
+
that
.
limit
;
return
that
.
offset
;
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
}
offset
:
that
.
offset
});
});
this
.
previousClick
=
false
;
this
.
previousClick
=
false
;
this
.
fetchCollection
();
this
.
fetchCollection
();
...
@@ -633,11 +618,9 @@ define(['require',
...
@@ -633,11 +618,9 @@ define(['require',
onClickpreviousData
:
function
()
{
onClickpreviousData
:
function
()
{
var
that
=
this
;
var
that
=
this
;
this
.
ui
.
nextData
.
removeAttr
(
"disabled"
);
this
.
ui
.
nextData
.
removeAttr
(
"disabled"
);
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
offset
:
function
()
{
that
.
offset
=
that
.
offset
-
that
.
limit
;
that
.
offset
=
that
.
offset
-
that
.
limit
;
return
that
.
offset
;
$
.
extend
(
this
.
searchCollection
.
queryParams
,
{
}
offset
:
that
.
offset
});
});
this
.
previousClick
=
true
;
this
.
previousClick
=
true
;
this
.
fetchCollection
();
this
.
fetchCollection
();
...
...
release-log.txt
View file @
05277c27
...
@@ -6,6 +6,7 @@ INCOMPATIBLE CHANGES:
...
@@ -6,6 +6,7 @@ INCOMPATIBLE CHANGES:
ALL CHANGES:
ALL CHANGES:
ATLAS-1064 UI: Pagination for full text search results (Kalyanikashikar via shwethags)
ATLAS-1006 Paginate full text search results (shwethags)
ATLAS-1006 Paginate full text search results (shwethags)
ATLAS-1046 UI: Search pagination refinements (Kalyanikashikar via sumasai)
ATLAS-1046 UI: Search pagination refinements (Kalyanikashikar via sumasai)
ATLAS-1056 Differentiate between tag and term using attribute "taxonomy.namespace" (kevalbhat18 via sumasai)
ATLAS-1056 Differentiate between tag and term using attribute "taxonomy.namespace" (kevalbhat18 via sumasai)
...
...
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