New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KZL-30 Persistent search filters across collections and reloads #428

Merged
merged 26 commits into from Aug 14, 2018

Conversation

Projects
None yet
5 participants
@xbill82
Member

xbill82 commented Aug 9, 2018

What does this PR do ?

This PR enables the Data -> Index -> Collection -> Browse view to remember search filters across collections, reloads and document edits.

How should this be manually tested?

Persistent filters across collections

  1. Perform a search on a collection (quick, basic o raw) - you should see the filter specified in the URL
  2. Switch to another collection
  3. Switch back to the previous collection
  4. The filter specified for the previous search is still defined

Persistent filters across reloads

  1. Perform a search on a collection (quick, basic o raw)
  2. The the filter is specified in the URL
  3. Reload the page
  4. The filter specified for the previous search is still defined

Persistent filters across document edits

  1. Perform a search on a collection (quick, basic o raw)
  2. Edit a document in the results
  3. After updating the document, the results of the search are still visible

Persistent filters across sessions

  1. Perform a search on a collection (quick, basic o raw)
  2. Logout and login again
  3. Browse to the previous collection
  4. The filter specified for the previous search is still defined

Note that this happens even if you login as another user.

Boyscout

A major refactoring has been performed on the search filters system.

etrousset and others added some commits Jul 18, 2018

}
},
methods: {
isChecked(id) {

This comment has been minimized.

@Aschen

Aschen Aug 9, 2018

Contributor

This shouldn't be a computed value ?

@Aschen

Aschen Aug 9, 2018

Contributor

This shouldn't be a computed value ?

This comment has been minimized.

@xbill82

xbill82 Aug 13, 2018

Member

No. This is a function that returns true if the document with the given id is selected. Computed values do not accept arguments.

@xbill82

xbill82 Aug 13, 2018

Member

No. This is a function that returns true if the document with the given id is selected. Computed values do not accept arguments.

this.close()
this.refreshSearch()
this.isLoading = false
return null

This comment has been minimized.

@Aschen

Aschen Aug 9, 2018

Contributor

Why return null ?
(+ others below)

@Aschen

Aschen Aug 9, 2018

Contributor

Why return null ?
(+ others below)

This comment has been minimized.

@xbill82

xbill82 Aug 13, 2018

Member

I don't know. Even if the blame points on me, I didn't code these methods, I just formatted them via Prettier.

@xbill82

xbill82 Aug 13, 2018

Member

I don't know. Even if the blame points on me, I didn't code these methods, I just formatted them via Prettier.

Show outdated Hide outdated src/components/Common/CrudlDocument.vue Outdated
}
},
methods: {
isChecked(id) {

This comment has been minimized.

@Aschen

Aschen Aug 9, 2018

Contributor

Should be a computed value

@Aschen

Aschen Aug 9, 2018

Contributor

Should be a computed value

This comment has been minimized.

@xbill82

xbill82 Aug 13, 2018

Member

See above.

@xbill82

xbill82 Aug 13, 2018

Member

See above.

Show outdated Hide outdated src/components/Security/Profiles/CommonList.vue Outdated
Show outdated Hide outdated src/components/Common/CommonList.vue Outdated
Show outdated Hide outdated test/unit/specs/vuex/common/crudlDocument/mutations.spec.js Outdated

xbill82 added some commits Aug 9, 2018

@xbill82 xbill82 referenced this pull request Aug 13, 2018

Merged

Filters css refactor #430

@Aschen

Aschen approved these changes Aug 14, 2018

@Aschen Aschen merged commit dd67ccc into 2.x Aug 14, 2018

3 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
deploy/netlify Deploy preview ready!
Details

@Aschen Aschen deleted the KZL-30-restore-last-search-query-after-doc-edit branch Aug 14, 2018

@scottinet scottinet referenced this pull request Sep 12, 2018

Merged

Release 2.2.0 #451

scottinet added a commit that referenced this pull request Sep 13, 2018

Release 2.2.0 (#451)
* Fix bugs (#409)

Fix bugs

* to change

* Fix last change from PR 406

* corrected grammar (ENG) (#414)

* Grammar corrections and changed bin name.

* main menu: Added Console Admin current version

-Added current Kuzzle Admin Console version next to Kuzzle logo
in the top menu bar

* Removed dependency from Bower

* main menu: fixed typo

* First automatic fix

* Fixed width of the sidebar

* Bower.json harakiri (#417)

* No more bower in package.json and Dockerfile

* I mean, no Bower AT ALL

* main menu: Added Console Admin current version

-Added current Kuzzle Admin Console version next to Kuzzle logo
in the top menu bar

* main menu: fixed typo

* packages: updated mocha to 5.2.0

* packages: updated karma to 2.0.4

* packages: updated url-loader and tough-cookie

-url-loader@1.0.1

* packages: updated  mime and stringstream

* gitignore: add vscode files to .gitignore

* gitignore: add vscode files to .gitignore

* Enabled Prettier

* First draft of the style guides in CONTRIBUTING

* Sass variables are now available to components scoped stylesheets

* Bumped eslint and vue-loader

* Automatically formatted everything

* filters: refactoring

-renamed some props and events
-removed some dead code in the store

* filters: refactor

-removed dead code

* refactoring: avoid huge logic expression...

... with no meaning in temple, use a
computed in stead, so that the meaning of the
logic expression becomes more obvious...

* basic-filter: fixed operand drop list size

* filter restoration: search filter are now stored and restored

for each index/collection, a current filter is stored and restored
tested with quickSearch only
doesn't not restore the display of Filters component...

* wip

* add query params in router

* New version of package-locl.json

* add input-fields label css rules to fix checkbox bug

* 1st stage of filters big refactor

* WIP refactoring filters

* Basic search refactored and working

* Raw search refactored and working

* Pagination refactored and working

* Tiny cleanups

* Watch refactored and working

* Fixed security

* Fixed reset button in Watch

* Minor cleanups

* Unit tested filter manager + minor fixes

* Cleanup of ESLint errors on test files

* Removed FilterManager class

* 408 fix scroll after login (#426)

* Fix missing scrollbar after login

* Add explanation

* Wooooops...

* Applied remarks from @Aschen

* Distributed collection-item styles in components

* Quickfilters styles dispatched to components

* Dispatched advanced filter styles to components

* Dispatched principal layout styles to components

* Side nav styles dispatched to components

* Treeview fixes and style dispatch

* KZL-30 Persistent search filters across collections and reloads (#428)

* gitignore: add vscode files to .gitignore

* gitignore: add vscode files to .gitignore

* filters: refactoring

-renamed some props and events
-removed some dead code in the store

* filters: refactor

-removed dead code

* refactoring: avoid huge logic expression...

... with no meaning in temple, use a
computed in stead, so that the meaning of the
logic expression becomes more obvious...

* basic-filter: fixed operand drop list size

* filter restoration: search filter are now stored and restored

for each index/collection, a current filter is stored and restored
tested with quickSearch only
doesn't not restore the display of Filters component...

* wip

* add query params in router

* 1st stage of filters big refactor

* WIP refactoring filters

* Basic search refactored and working

* Raw search refactored and working

* Pagination refactored and working

* Tiny cleanups

* Watch refactored and working

* Fixed security

* Fixed reset button in Watch

* Minor cleanups

* Unit tested filter manager + minor fixes

* Cleanup of ESLint errors on test files

* Removed FilterManager class

* Wooooops...

* Applied remarks from @Aschen

* add bind methods in jsonFormatter directive (#429)

* Harmonized classes with BEM convention

* Make BasicFilter great again

* Minor naming and indentation fixes

* Roles CRUDL refactored and working

* Profiles refactored and working

* Got vuex-router-sync out of the way. Good riddance.

* Wow, there was a conflict left since ages

* Filters css refactor (#430)

* gitignore: add vscode files to .gitignore

* gitignore: add vscode files to .gitignore

* filters: refactoring

-renamed some props and events
-removed some dead code in the store

* filters: refactor

-removed dead code

* refactoring: avoid huge logic expression...

... with no meaning in temple, use a
computed in stead, so that the meaning of the
logic expression becomes more obvious...

* basic-filter: fixed operand drop list size

* filter restoration: search filter are now stored and restored

for each index/collection, a current filter is stored and restored
tested with quickSearch only
doesn't not restore the display of Filters component...

* wip

* add query params in router

* 1st stage of filters big refactor

* WIP refactoring filters

* Basic search refactored and working

* Raw search refactored and working

* Pagination refactored and working

* Tiny cleanups

* Watch refactored and working

* Fixed security

* Fixed reset button in Watch

* Minor cleanups

* Unit tested filter manager + minor fixes

* Cleanup of ESLint errors on test files

* Removed FilterManager class

* Wooooops...

* Applied remarks from @Aschen

* Distributed collection-item styles in components

* Quickfilters styles dispatched to components

* Dispatched advanced filter styles to components

* Dispatched principal layout styles to components

* Side nav styles dispatched to components

* Treeview fixes and style dispatch

* Harmonized classes with BEM convention

* Make BasicFilter great again

* Fixed Treeview disappearing on medium screens

* Shrinked the main wrapper a little bit and centered it (#436)

* KZL 301 - Display realtime search result when updating filters (#432)

* gitignore: add vscode files to .gitignore

* gitignore: add vscode files to .gitignore

* filters: refactoring

-renamed some props and events
-removed some dead code in the store

* filters: refactor

-removed dead code

* refactoring: avoid huge logic expression...

... with no meaning in temple, use a
computed in stead, so that the meaning of the
logic expression becomes more obvious...

* basic-filter: fixed operand drop list size

* filter restoration: search filter are now stored and restored

for each index/collection, a current filter is stored and restored
tested with quickSearch only
doesn't not restore the display of Filters component...

* wip

* add query params in router

* 1st stage of filters big refactor

* WIP refactoring filters

* Basic search refactored and working

* Raw search refactored and working

* Pagination refactored and working

* Tiny cleanups

* Watch refactored and working

* Fixed security

* Fixed reset button in Watch

* Minor cleanups

* Unit tested filter manager + minor fixes

* Cleanup of ESLint errors on test files

* Removed FilterManager class

* Wooooops...

* Applied remarks from @Aschen

* Distributed collection-item styles in components

* Quickfilters styles dispatched to components

* Dispatched advanced filter styles to components

* Dispatched principal layout styles to components

* Side nav styles dispatched to components

* Treeview fixes and style dispatch

* Harmonized classes with BEM convention

* Make BasicFilter great again

* Perform realtime instant search when quickfilter is updated

* Perform realtime instant search when basic filters are updated

* Keep QuickFilter opened when refreshing results in realtime + add throttle

* Fix tests

* Fixed Treeview disappearing on medium screens

* Applied remark from @benoitvidis

* KZL 299 - Autocomplete on attribute name in basic filters (#434)

* Add autocomplete field on attribute input, build item list from collection mapping

* Add custom autocomplete component + integrate it for BasicFilter attributes

* Use the autocomplete in watch view

* Change selected item color

* Use coding standard style for event

* Scope style + use color variable

* Dont open list if no results

* Update for PR

* Temporary revert of #436

* Display warning when using https version of admin console

* KZL-300 Buttons to switch between list views (#435)

* Refactored Data Documents List

* Implemented listType buttons

* Pagination doesn't make sense on every view

* Applied #436 to the documents page only

* Applied remark from @jenow

* Applied #436 to document watch

* Fixed edit User/Document pencil icons

* Fixed bug on basic search

* First draft of the document boxes view

* added Pagination to the boxes view

* Add a ViewMap component
 - allow user to select which geo_point field to use

* fix alignment

* Hide useless button according to the view

* Show informations and actions about document when click on it

* Css tricks

* Remember list view type (#443)

* Now remembering list view in currentFilter

* Preventing event emission if button is disabled

* manual merge

* nitpicking

* Add comment to template

* Apply @xbill82 recommandations

* Shrinked vertical layout of initial pages (#445)

* Now remembering list view in currentFilter

* Preventing event emission if button is disabled

* Shrinked a little bit the vertical layout of signup and createEnvironment page

* Applied remarks from @Aschen

* [Boyscout] Fixed error in CONTRIBUTING.md

* Fix bug

* Applied remarks from @Njuelle

* KZL 461 - Display warning when using https version of admin console (#440)

* Display warning when using https version of admin console

* Display warning if ssl is unchecked + fix bug

* Update for PR

* UI/UX tweaks to make collection-creation workflow more human

* Change way to identify geo_point because of local bug

* Better headline in collection create or update page

* Prettier on all files

* bem class name

* Dispatched styles from collection.scss to components

* Added disclaimer TODO comments

* The Mapping in CreateOrUpdateDocument is no longer a JsonEditor

* Fixed eslint error due to Prettier

* [KZL-181] As an end user, i'd like to use Kuzzle Admin Console on my desktop (#439)

* hotfif ci

* [ImgBot] optimizes images

*Total -- 214.79kb -> 105.72kb (50.78%)

/src/assets/logo-white-vertical.png -- 33.19kb -> 10.92kb (67.1%)
/static/favicon/favicon-196x196.png -- 20.93kb -> 10.06kb (51.94%)
/static/favicon/apple-touch-icon-120x120.png -- 5.08kb -> 2.46kb (51.67%)
/static/favicon/mstile-150x150.png -- 20.72kb -> 10.06kb (51.46%)
/static/favicon/apple-touch-icon-144x144.png -- 12.06kb -> 5.89kb (51.11%)
/static/favicon/mstile-144x144.png -- 12.06kb -> 5.89kb (51.11%)
/static/favicon/apple-touch-icon-152x152.png -- 12.86kb -> 6.29kb (51.09%)
/static/favicon/mstile-310x310.png -- 27.05kb -> 13.64kb (49.56%)
/static/favicon/apple-touch-icon-114x114.png -- 7.59kb -> 3.96kb (47.85%)
/static/favicon/mstile-310x150.png -- 14.79kb -> 7.77kb (47.46%)
/static/favicon/favicon-96x96.png -- 4.92kb -> 2.64kb (46.23%)
/src/assets/logo-white-horizontal.png -- 16.38kb -> 9.12kb (44.33%)
/static/favicon/apple-touch-icon-76x76.png -- 3.67kb -> 2.11kb (42.58%)
/static/favicon/apple-touch-icon-72x72.png -- 3.10kb -> 1.86kb (39.96%)
/src/assets/logo.png -- 13.85kb -> 8.41kb (39.24%)
/static/favicon/apple-touch-icon-57x57.png -- 1.88kb -> 1.28kb (31.88%)
/static/favicon/mstile-70x70.png -- 1.61kb -> 1.15kb (28.81%)
/static/favicon/favicon-128.png -- 1.61kb -> 1.15kb (28.81%)
/static/favicon/apple-touch-icon-60x60.png -- 1.45kb -> 1.05kb (27.39%)

* [KZL-181] use Kuzzle Admin Console on my desktop

* [KZL-181] Apply @Aschen suggestions

* Admin console version in package name
* Adjust zoomFactor property

* Not very happy

* I only needed a max-width...

* Variablized container width

* Fixed some bugs on mac 13' screen

* Raised list container max-width

* Revert "Raised list container max-width"

This reverts commit e21f114.

* Raised list container max-width to 1150px

* Updated package-lock

* Fixed JSON DocumentForm labels (#449)

* Fixed JSON DocumentForm labels

* Adjusted padding on the Docuement Create Or Update Raw Json Form

* Fixed max document create form width

* Fixed overflow of dropdown in document list

* Document cr friendly msg (#450)

* Fixed JSON DocumentForm labels

* Adjusted padding on the Docuement Create Or Update Raw Json Form

* Added a message in the create document form

* Release 2.2.0

@scottinet scottinet referenced this pull request Sep 26, 2018

Closed

Release 2.3.0 #462

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment