Angular staff catalog facets are effectively hard-coded

Bug #1932350 reported by Mike Rylander
48
This bug affects 9 people
Affects Status Importance Assigned to Milestone
Evergreen
Confirmed
High
Unassigned

Bug Description

Evergreen version: 3.6+
OpenSRF version: all
PG version: all

The public catalog templates allow an administrator to define the set and order of facets that could be displayed for any search result. The Angular staff catalog follows the same logic but does not have a way for an admin to specify the facet display configuration except by adjusting code and recompiling the Angular client.

Bill Erickson has put together a WIP branch to help address the more general problem of Angular catalog config and customization here:

  https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/berick/lpxxx-angular-dynamic-config

His branch addresses the specific concern of this bug but demonstrates a general framework for attacking (some of) this class of problems. Feedback (on the problem, and his branch) sought!

Revision history for this message
Mike Rylander (mrylander) wrote :

And as a first bit of feedback, I think it would be useful to have this file live in the opac template area near config.tt2 so that it can make use of the existing (public catalog) template override functionality.

Changed in evergreen:
assignee: Mike Rylander (mrylander) → nobody
Revision history for this message
Michele Morgan (mmorgan) wrote :

Related: bug 1934018

Revision history for this message
Mike Rylander (mrylander) wrote :

In an attempt to be the change you want to see in the world, I offer the branch at https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/miker/lp-1932350-angular-dynamic-config that extends Bill's patch by making the Angular dynamic content file into a template, so that it can be used in the same way as config.tt2, per hostname, and allow various settings within a consortium.

tags: added: pullrequest
Revision history for this message
Jason Boyer (jboyer) wrote :

Hi Mike, I loaded this to try it out and it looks like something's off. I'm getting a 404 for angular-config.js which kills the Angular catalog completely. My gateway logs have entries like AH00128: File does not exist: /openils/var/web/eg/eg2import/angular-config.js, referer: ... so it looks like the template processor isn't picking it up?

Revision history for this message
Galen Charlton (gmc) wrote :

Looks like the LocationMatch around line 766 of eg_vhost_24.conf is what's getting in the way.

Revision history for this message
Galen Charlton (gmc) wrote :

This patch should get the Apache side of things working.

Michele Morgan (mmorgan)
Changed in evergreen:
status: New → Confirmed
Andrea Neiman (aneiman)
tags: added: needswork
removed: pullrequest
Michele Morgan (mmorgan)
tags: added: staffcatalogblocker
Revision history for this message
Elizabeth Thomsen (et-8) wrote (last edit ):

Tested on Equinox community server, demo.evergreencatalog.com, on Release 3.11.1 and there is still no More option in facets, so we can only see the first five.

Revision history for this message
Elizabeth Thomsen (et-8) wrote :
Revision history for this message
Stephanie Leary (stephanieleary) wrote :

The issue of how many links are shown is covered in bug 1934018 (which has a branch); this one has to do with rearranging the Author, Topic, Genre, etc. boxes in the staff sidebar or showing different boxes altogether.

Revision history for this message
Chrisy Schroth (cschroth) wrote :

It seems as though this has been fixed. Our 3-11-7 catalog has had More links for the Staff Catalog facets in the Angular search when warranted for a while (we just noticed one day that they were there). I just checked on the Bug Squashing Week MOBIUS Test Server 1 to make sure and there are More links for Personal Author, Topic Subject, and Series Title. I don't think the other facets on my search have any more to show.

Revision history for this message
Stephanie Leary (stephanieleary) wrote :

The More links have been added, but it's still not possible to rearrange the facets. In facets.component.ts, there's a hard-coded list at the top:

display: [
        {facetClass : 'author', facetOrder : ['personal', 'corporate']},
        {facetClass : 'subject', facetOrder : ['topic']},
        {facetClass : 'identifier', facetOrder : ['genre']},
        {facetClass : 'series', facetOrder : ['seriestitle']},
        {facetClass : 'subject', facetOrder : ['name', 'geographic']}
    ]

I've been playing around (in my copious spare time) with some ways to turn this into a drag-and-drop interface. Several rabbit holes later, the Dragula library for Angular (https://valor-software.com/ng2-dragula/) looks like a possible replacement for several of our manually-created drag-and-drop functions.

That's as far as I've gotten without a formal project to work on this.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.