working/Evergreen.git
5 years agosprinkle more setTimeout dust...
Galen Charlton [Sat, 25 Jan 2020 15:58:00 +0000 (10:58 -0500)]
sprinkle more setTimeout dust...

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd au_by_id option to unified search
Galen Charlton [Sat, 25 Jan 2020 15:54:26 +0000 (10:54 -0500)]
add au_by_id option to unified search

This specifies performing queries on au-linked fields by
ID rather than adding joins to query the fields by user
barcode or username, etc.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimplement the run-immediately checkbox
Galen Charlton [Sat, 25 Jan 2020 15:28:08 +0000 (10:28 -0500)]
implement the run-immediately checkbox

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoupdate 'set as default seach buttons' to include search type
Galen Charlton [Sat, 25 Jan 2020 13:27:08 +0000 (08:27 -0500)]
update 'set as default seach buttons' to include search type

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agogrid: use bolder styling for the 'Nothing to Display' message
Galen Charlton [Sat, 25 Jan 2020 13:16:19 +0000 (08:16 -0500)]
grid: use bolder styling for the 'Nothing to Display' message

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimplement LI grid filtering for acqlia title and author
Galen Charlton [Fri, 24 Jan 2020 11:18:51 +0000 (06:18 -0500)]
implement LI grid filtering for acqlia title and author

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoset default search operator for acqlia fields to "contains"
Galen Charlton [Thu, 23 Jan 2020 15:24:44 +0000 (10:24 -0500)]
set default search operator for acqlia fields to "contains"

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agocan't use strong.match(/regex/) in Angular templates
Galen Charlton [Thu, 23 Jan 2020 14:53:22 +0000 (09:53 -0500)]
can't use strong.match(/regex/) in Angular templates

... so in this case, switch to startsWith() and endsWith().
See https://github.com/angular/angular/issues/6419

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoSpecialization between PO and LI
Mike Rylander [Tue, 28 Jan 2020 16:38:55 +0000 (11:38 -0500)]
Specialization between PO and LI

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoSpecial case for LI and PO state fields
Mike Rylander [Tue, 28 Jan 2020 16:26:41 +0000 (11:26 -0500)]
Special case for LI and PO state fields

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoPrefix available fields with their friendly IDL class name
Mike Rylander [Tue, 28 Jan 2020 15:30:21 +0000 (10:30 -0500)]
Prefix available fields with their friendly IDL class name

Signed-off-by: Mike Rylander <mrylander@gmail.com>
5 years agowrap the search form in a <form> element
Galen Charlton [Wed, 22 Jan 2020 22:57:28 +0000 (17:57 -0500)]
wrap the search form in a <form> element

Also adjust button types and ngModelOptions with the goal
of enabling press-enter-to-submit-form.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd expanded to control visibility of the search form
Galen Charlton [Wed, 22 Jan 2020 22:49:05 +0000 (17:49 -0500)]
add expanded to control visibility of the search form

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoremove TODO comment that is now TODONE
Galen Charlton [Wed, 22 Jan 2020 19:53:42 +0000 (14:53 -0500)]
remove TODO comment that is now TODONE

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd support for search conjunction ("all" or "any")
Galen Charlton [Wed, 22 Jan 2020 17:23:51 +0000 (12:23 -0500)]
add support for search conjunction ("all" or "any")

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimplement additional navigation links
Galen Charlton [Tue, 21 Jan 2020 01:02:32 +0000 (20:02 -0500)]
implement additional navigation links

Along the way, also:

- make the acq search components react to route and route query
  param changes
- add user_id and ws_ou to the Angular and AngularJS nav bars

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimplement save search as default button
Galen Charlton [Mon, 20 Jan 2020 23:01:05 +0000 (18:01 -0500)]
implement save search as default button

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd workstation settings for saving default searches
Galen Charlton [Mon, 20 Jan 2020 22:42:14 +0000 (17:42 -0500)]
add workstation settings for saving default searches

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohook up selected value for comboboxes for acq search form
Galen Charlton [Mon, 20 Jan 2020 17:13:24 +0000 (12:13 -0500)]
hook up selected value for comboboxes for acq search form

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agocombobox: teach it how to start with a selected value when IDL-based
Galen Charlton [Mon, 20 Jan 2020 17:12:53 +0000 (12:12 -0500)]
combobox: teach it how to start with a selected value when IDL-based

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimplement passing search form parameters via URL
Galen Charlton [Sun, 19 Jan 2020 21:58:07 +0000 (16:58 -0500)]
implement passing search form parameters via URL

TODO: avoid double-search on page startup
TODO: consider having the LI search results flesh invoice_entries
      so that the invoice link can be displayed only when it
      would display results

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohook up __between operator
Galen Charlton [Sun, 19 Jan 2020 20:31:23 +0000 (15:31 -0500)]
hook up __between operator

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohook up __age, __starts, and __ends operators
Galen Charlton [Sun, 19 Jan 2020 20:20:48 +0000 (15:20 -0500)]
hook up __age, __starts, and __ends operators

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP#1860351: fix hasWorkPermHere() in Angular client
Galen Charlton [Sun, 19 Jan 2020 19:47:40 +0000 (14:47 -0500)]
LP#1860351: fix hasWorkPermHere() in Angular client

Fixes a bug where the Angular client's hasWorkPermHere() check
could return incorrect results and thus incorrectly report
whether or not the staff user currently has particularl permissions
at their current workstation.

To test
-------
[1] Arrange for a workstation whose internal ID is larger than
    any of the org unit IDs.
[2] Log in to that workstation with a user who has permission
    to update monograph parts.
[4] In the experimental Angular staff catalog, go to a record
    (e.g., /eg2/en-US/staff/catalog/record/21/monoparts) and note
    that the New Monograph Part button is disabled.
[5] Apply the patch and repeat step 4. This time, the button
    should be active.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoalternative way of setting the background of nav-tabs
Galen Charlton [Sun, 19 Jan 2020 18:58:30 +0000 (13:58 -0500)]
alternative way of setting the background of nav-tabs

Looks like it needs to be a global style for now.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agostylistic tweaks
Galen Charlton [Fri, 17 Jan 2020 23:32:03 +0000 (18:32 -0500)]
stylistic tweaks

- change tab style back to pills to match staff catalog
- add some padding

TODO: fix grey background of entire page

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd support for removing search terms
Galen Charlton [Fri, 17 Jan 2020 22:59:02 +0000 (17:59 -0500)]
add support for removing search terms

This also removes the 'Add Search Term' button in favor
of +/- buttons at the end of each search row to match the
Angular staff catalog.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agorefactor the search form into a separate component
Galen Charlton [Fri, 17 Jan 2020 22:47:42 +0000 (17:47 -0500)]
refactor the search form into a separate component

This enables including the form *in* the tab and simplifies
initializing the form during a tab change.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd select-from-file widget
Galen Charlton [Fri, 17 Jan 2020 17:06:17 +0000 (12:06 -0500)]
add select-from-file widget

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoclear search value upon changing selected field
Galen Charlton [Fri, 17 Jan 2020 16:43:00 +0000 (11:43 -0500)]
clear search value upon changing selected field

TODO: consider if there are cases where we're OK not
      clearing the field, e.g., if both the previous
      and new fields both have the same type. Note
      that just clearing the value is what the Dojo
      interface did.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoignore empty search term values
Galen Charlton [Fri, 17 Jan 2020 16:42:43 +0000 (11:42 -0500)]
ignore empty search term values

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohook up date selection widget
Galen Charlton [Fri, 17 Jan 2020 16:35:31 +0000 (11:35 -0500)]
hook up date selection widget

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agotake record type into account when processing search terms from form
Galen Charlton [Fri, 17 Jan 2020 16:12:09 +0000 (11:12 -0500)]
take record type into account when processing search terms from form

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohook up more widgets to search form
Galen Charlton [Fri, 17 Jan 2020 16:07:20 +0000 (11:07 -0500)]
hook up more widgets to search form

- linked-field selectors
- id & int

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoclear search form upon changing results type tab
Galen Charlton [Fri, 17 Jan 2020 15:29:07 +0000 (10:29 -0500)]
clear search form upon changing results type tab

This matches behavior from the Dojo interface. This will
get modified a bit when adding support for default searches.

TODO: Consider preserving the state of the search form so that
it can be restored upon switch back to a given tab.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohook up search action to LI, invoice, and picklist grids
Galen Charlton [Fri, 17 Jan 2020 15:27:06 +0000 (10:27 -0500)]
hook up search action to LI, invoice, and picklist grids

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agostart fleshing out more of the search form
Galen Charlton [Thu, 16 Jan 2020 23:50:02 +0000 (18:50 -0500)]
start fleshing out more of the search form

- start adding appropriate input widgets based on
  field type
- set up proof of concept of integrating search terms
  from form with grid filters
- do some renaming and defining interfaces

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agode-lint
Galen Charlton [Thu, 16 Jan 2020 22:15:33 +0000 (17:15 -0500)]
de-lint

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agostart work on search form
Mike Rylander [Thu, 16 Jan 2020 21:57:04 +0000 (16:57 -0500)]
start work on search form

- IDL-based field selector
- conditional selection of search inputs

Signed-off-by: Mike Rylander <mrylander@gmail.com>
5 years agomark picklist entry_count column as unfilterable
Galen Charlton [Wed, 20 Nov 2019 16:06:35 +0000 (11:06 -0500)]
mark picklist entry_count column as unfilterable

(Search API provides no way of doing it, and as a virtual field,
 it would be a bit challenging to make it searchable.)

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agohandle case where grid filter supplies multiple conditions for a field
Galen Charlton [Fri, 15 Nov 2019 23:13:17 +0000 (18:13 -0500)]
handle case where grid filter supplies multiple conditions for a field

This can be the case for dates.

TODO: deal with au term rewriting; for conditions coming from grid
filters, it's always going to be an exact match on a single user
ID.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimplement more filter operators
Galen Charlton [Fri, 15 Nov 2019 22:54:38 +0000 (17:54 -0500)]
implement more filter operators

- contains
- does not contain
- starts with
- ends with

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoenable filtering for the other types; add TODO
Galen Charlton [Fri, 15 Nov 2019 22:02:33 +0000 (17:02 -0500)]
enable filtering for the other types; add TODO

TODO: Title and Author will require special work

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoimprove mapping of filter operators
Galen Charlton [Fri, 15 Nov 2019 21:55:59 +0000 (16:55 -0500)]
improve mapping of filter operators

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoWIP: start work on hooking up grid filters
Galen Charlton [Wed, 13 Nov 2019 23:13:46 +0000 (18:13 -0500)]
WIP: start work on hooking up grid filters

Notes:

- changed provider.name to provider
- need to do more fleshing of linked user fields
  on the line item grid
- need to figure out how to completely suppress certain
  columns from grid display (e.g., LI MARC, although I
  could envision a later widget that pops up a human-readable
  view)
- Wish typescript or Angular had a native deep copy
  of nested properties.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoPrint Selected Invoices action for invoice grid
Jason Etheridge [Wed, 20 Nov 2019 13:31:54 +0000 (08:31 -0500)]
Print Selected Invoices action for invoice grid

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agotweak invoice grid and middle layer retriever
Jason Etheridge [Wed, 20 Nov 2019 12:49:50 +0000 (07:49 -0500)]
tweak invoice grid and middle layer retriever

Flesh provider and shipper, and provide links to the legacy dojo for those and inv_ident

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agotweak columns for picklist and purchase order grids
Jason Etheridge [Wed, 20 Nov 2019 04:56:41 +0000 (23:56 -0500)]
tweak columns for picklist and purchase order grids

to better match the spec (unmandated columns hidden by default)

virtual columns such as picklist's entry_count have to be specified with eg-grid

hiding fleshed user columns was causing some uncaught errors and the grid to
misrender when manually unhidden. Adding a label helped, but would render the
cell as [object Object].  Using a cell template to handle that object was
providing different errors (.id() was accessible, but not .usrname()).  So,
unfleshing those for now.

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agowebby wrappers for these legacy interfaces
Jason Etheridge [Wed, 20 Nov 2019 03:24:26 +0000 (22:24 -0500)]
webby wrappers for these legacy interfaces

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agotweak Create and Clone Selection List dialogs
Jason Etheridge [Tue, 19 Nov 2019 05:36:30 +0000 (00:36 -0500)]
tweak Create and Clone Selection List dialogs

Auto-focus and clear the input widgets, and default the clone widget to
"Copy of <selected list>"

5 years agobetter error handling
Jason Etheridge [Mon, 11 Nov 2019 20:00:48 +0000 (15:00 -0500)]
better error handling

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agoflesh some columns for purchase order grid
Jason Etheridge [Mon, 11 Nov 2019 19:52:57 +0000 (14:52 -0500)]
flesh some columns for purchase order grid

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agofleshing some columns for the list of selection lists :)
Jason Etheridge [Mon, 11 Nov 2019 19:27:25 +0000 (14:27 -0500)]
fleshing some columns for the list of selection lists :)

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agosome form validation
Jason Etheridge [Mon, 11 Nov 2019 18:53:54 +0000 (13:53 -0500)]
some form validation

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agopicklist merge dialog
Jason Etheridge [Mon, 11 Nov 2019 13:43:29 +0000 (08:43 -0500)]
picklist merge dialog

5 years agopicklist delete dialog
Jason Etheridge [Mon, 11 Nov 2019 12:36:26 +0000 (07:36 -0500)]
picklist delete dialog

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agopicklist clone dialog
Jason Etheridge [Mon, 11 Nov 2019 01:48:22 +0000 (20:48 -0500)]
picklist clone dialog

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agocreate selection list action
Jason Etheridge [Fri, 8 Nov 2019 22:41:02 +0000 (17:41 -0500)]
create selection list action

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agostub picklist actions with UI perm checks
Jason Etheridge [Fri, 8 Nov 2019 15:06:04 +0000 (10:06 -0500)]
stub picklist actions with UI perm checks

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agohyperlinks for certain columns
Jason Etheridge [Wed, 6 Nov 2019 18:06:12 +0000 (13:06 -0500)]
hyperlinks for certain columns

in the acq search purchase order and selection list result grids

Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agoadd eg-file-reader to Angular sandbox
Galen Charlton [Fri, 8 Nov 2019 23:41:21 +0000 (18:41 -0500)]
add eg-file-reader to Angular sandbox

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agonew Angular file-reader component
Galen Charlton [Fri, 8 Nov 2019 23:39:34 +0000 (18:39 -0500)]
new Angular file-reader component

This adds a ControlValueAccessor wrapper around a file
reader form input. Any file loaded via that input is interpreted
as a text file whose lines are to be split into an array on
newlines, with leading and trailng whitespace removed.

Usage is:

<eg-file-reader [(ngModel)]="fileContents">
</eg-file-reader>

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agofix ng lint warnings
Galen Charlton [Fri, 1 Nov 2019 17:57:01 +0000 (13:57 -0400)]
fix ng lint warnings

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoRework IN and BETWEEN field transform support
Mike Rylander [Fri, 1 Nov 2019 16:52:49 +0000 (12:52 -0400)]
Rework IN and BETWEEN field transform support

This commit refactors the previous IN and BETWEEN field transform
support to streamline things a bit.  Gone are the changes to the complex
predicate handler to special-case BETWEEN, replaced by changes to the IN
and BETWEEN clause generators to handle field transformation directly.

Also addressed a compiler warning about misleading indentation.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
5 years agomake the results grids have sticky headers
Galen Charlton [Fri, 1 Nov 2019 16:27:28 +0000 (12:27 -0400)]
make the results grids have sticky headers

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agotweaks to line-item results display
Galen Charlton [Fri, 1 Nov 2019 15:37:53 +0000 (11:37 -0400)]
tweaks to line-item results display

- The line item ID now links to either to the Dojo purchase
  order display (with that line item highlighted), or, if there
  is no purchase order, to the Dojo selection list display (again,
  with that line item highlighted).
- The "Catalog" link is now dispayed only when the line item
  is linked to a bib record
- Fix a display issue if the line item is not linked to a provider.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agofirst pass at AcqSearchService
Galen Charlton [Fri, 1 Nov 2019 15:16:26 +0000 (11:16 -0400)]
first pass at AcqSearchService

This adds AcqSearchService, which knows how to produce
a GridDataSource of the appropriate type and default
search parameters and options. This also adds results
components for purchase orders, invoices, and selection lists.
Note that the new results components don't customize
the columns that are displayed.

AcqSearchService is intentionally _not_ set up as a singleton,
and instead is used as a provider by the four results components.
This can be changed if a reason turns up later to have the service
retain some state for the duration of the application session
(as opposed to the duration of the results component; note that this
may mean that the results component will need to embed the search
form component so that it can readily share the grid data source
with it).

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoremove tooltips from some lineitem results columns
Galen Charlton [Fri, 1 Nov 2019 14:20:29 +0000 (10:20 -0400)]
remove tooltips from some lineitem results columns

The "Links" column definitely doesn't need it, and it's distracting
when present for the of the grid columns that we know are unlikely
to ever get wide like ID, status, and estimated unit price.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoadd line item search results grid
Galen Charlton [Fri, 1 Nov 2019 01:35:18 +0000 (21:35 -0400)]
add line item search results grid

TODO:

- make invoice link on the results table link to an invoice
  search once we're further along
- move the search to a separate service

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoteach open-ils.acq.lineitem.retrieve more fleshing
Galen Charlton [Fri, 1 Nov 2019 01:08:31 +0000 (21:08 -0400)]
teach open-ils.acq.lineitem.retrieve more fleshing

In particular, teach it how to flesh the LI provider,
Vandelay queue, and claim policy so that Angular LI search
can display them without having to make additional server
requests.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agofix typo
Galen Charlton [Thu, 31 Oct 2019 23:20:12 +0000 (19:20 -0400)]
fix typo

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoGive searchFieldTransformPredicate a special case to handle transformation of fields...
Mike Rylander [Thu, 31 Oct 2019 22:09:24 +0000 (18:09 -0400)]
Give searchFieldTransformPredicate a special case to handle transformation of fields used in BETWEEN operations

Signed-off-by: Mike Rylander <mrylander@gmail.com>
5 years agoFix new __age acq search operator
Galen Charlton [Thu, 31 Oct 2019 20:53:11 +0000 (16:53 -0400)]
Fix new __age acq search operator

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agofix some lint
Galen Charlton [Thu, 31 Oct 2019 19:59:17 +0000 (15:59 -0400)]
fix some lint

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoUpdate acq search operators
Mike Rylander [Thu, 31 Oct 2019 19:23:22 +0000 (15:23 -0400)]
Update acq search operators

Add __age (interval), __starts, and __ends operators.

Update __between to support __castdate modifier, for a more natural
comparison of dates entered by humans to timestamps stored in the
database.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
5 years agochange style of the tabset to "pills"
Galen Charlton [Wed, 23 Oct 2019 14:54:13 +0000 (10:54 -0400)]
change style of the tabset to "pills"

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agostart laying out the Angular acq search app
Galen Charlton [Tue, 22 Oct 2019 19:29:40 +0000 (15:29 -0400)]
start laying out the Angular acq search app

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP#1843599: AngularJS MARC editor once again sets bib source
Galen Charlton [Fri, 20 Dec 2019 17:40:34 +0000 (12:40 -0500)]
LP#1843599: AngularJS MARC editor once again sets bib source

This patch fixes a regression introduced by the patch for bug 1693580
that prevent changes to the bib source from being made via the AngularJS
MARC editor.

To test
-------
[1] Apply the patch.
[2] Create a new bib record and save it with a non-empty source. Verify
    that the record sets the source as expected.
[3] Edit a bib record and change the source. Verify that the new source
    is retained when the record is saved.
[4] Edit an authority record and save it. Verify that it can be updated
    without error. (Note that authority records do not have sources in
    the same way that bib records do.)

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Rogan Hamby <rhamby@esilibrary.com>
Signed-off-by: Jason Etheridge <jason@EquinoxInitiative.org>
5 years agoLP#1855329: Hold shelf query speed problem
Mike Rylander [Thu, 5 Dec 2019 20:12:57 +0000 (15:12 -0500)]
LP#1855329: Hold shelf query speed problem

In bug 1827250 I suggested Jason Stephenson look at an alternate SQL
formulation to solve the original problem. He did, and deemed it faster,
so went with that. Unfortunately, on PG 9.6, we're seeing some data sets
that decide on a /very/ poor plan for the wide-hold query with the
solution as implemented, but the original suggestion from Jason works
fine.

In the face of evidence controverting my thought that giving PG more
options for planning is better in this case, this commit moves to his
original query change.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Stephenson <jason@sigio.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP#1858138: (follow-up) flesh creator and editor in sandbox's acp grid
Galen Charlton [Fri, 3 Jan 2020 16:02:29 +0000 (11:02 -0500)]
LP#1858138: (follow-up) flesh creator and editor in sandbox's acp grid

Doing so ensures that the usrnames are displayed in the respective
grid columns rather than the au ID.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Bill Erickson <berickxx@gmail.com>
5 years agoLP#1858138: remove remaining uses of showLinkSelector
Galen Charlton [Fri, 3 Jan 2020 15:35:56 +0000 (10:35 -0500)]
LP#1858138: remove remaining uses of showLinkSelector

Now that showLinkSelector is deprecated and does nothing,
remove current uses of it.

To test
-------
[1] Apply the patch.
[2] Visit Angular admin interfaces that have grids that
    refer to linked IDL classes, e.g.,

    - Local Admin -> Carousels (carousel type)
    - Server Admin -> Weights Association (circ weights and hold
                                           weights)
    - Local Admin -> Item Tags (copy tag type)
    - Acq Admin -> EDI Accounts (provider)

[3] Verify that the columns for linked fields display the
    appropriate selector field rather than the numeric ID.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Bill Erickson <berickxx@gmail.com>
5 years agoLP1858138 Sandbox example of simple grid filtering
Bill Erickson [Thu, 2 Jan 2020 21:31:31 +0000 (16:31 -0500)]
LP1858138 Sandbox example of simple grid filtering

Adds a trimmed down grid example demonstrating consistent filtering and
link selector display for auto and manual fields without requiring any
additional grid markup to define basic column behevior.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP1858138 Link selector consolidation/repairs
Bill Erickson [Thu, 2 Jan 2020 21:28:46 +0000 (16:28 -0500)]
LP1858138 Link selector consolidation/repairs

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP1858138 Grid IDL field definition repairs and more
Bill Erickson [Thu, 2 Jan 2020 21:22:34 +0000 (16:22 -0500)]
LP1858138 Grid IDL field definition repairs and more

* Deprecate showLinkSelectors, since FormatService now performs that
  logic under the covers.  Includes deprecation console warning.

* Fix Grid field IDL class extraction off-by-one error.  The code was
  stamping the source field with the class of the field's link target
  instead of the class the field actually belonged to.

* Allow for IDL field info extraction from the 'name' attribute when no
  'path' attribute is defined.

* Avoid console errors when clearing combobox values in grid filters.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP1858138 Link selector consolidation/repairs
Bill Erickson [Thu, 2 Jan 2020 21:17:59 +0000 (16:17 -0500)]
LP1858138 Link selector consolidation/repairs

Move more of the IDL link class selector extraction logic into the IDL
service.

Avoid using 'name' as a fall-through selector field when no 'name' field
exists on the class.

Teach the idl service to log warnings on invalid class and field name
combinations in selector lookups.

Modify fm-editor and combobox to use the new idl link selector
functions.

While we're in there, avoid unnecessary API calls from the combobox
by preventing async data lookups with a search term of "_CLICK_".

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP1858138 Action/Trigger IDL selector additions
Bill Erickson [Thu, 2 Jan 2020 20:19:16 +0000 (15:19 -0500)]
LP1858138 Action/Trigger IDL selector additions

Adds selector field entries for Action/Trigger hook, collector,
validator, reactor, and cleanup classes for ease of admin page building.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP#1857156: handle HHH:MM:SS durations in loans
Galen Charlton [Fri, 20 Dec 2019 17:55:16 +0000 (12:55 -0500)]
LP#1857156: handle HHH:MM:SS durations in loans

This patch fixes a problem where loan durations of the form
HHH:MM:SS, where the hours component is longer than 2 digits, could
cause checkouts to fail. This sort of duration has been observed
in cases where a library wanted a long-term reserves loan that
doesn't have the due time bumped up to midnight.

To test
-------
[1] Set up a circulation policy that has a loan duration of 167:59:59.
[2] Attempt a checkout that uses that policy. Note that the checkout
    will fail.
[3] Apply the patch and repeat step 2. This time, the checkout should
    succeed.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Dan Scott <dan@coffeecode.net>
Signed-off-by: Michele Morgan <mmorgan@noblenet.org>
5 years agoLP1858118 Hatch enabled check repairs
Bill Erickson [Tue, 12 Nov 2019 20:13:39 +0000 (15:13 -0500)]
LP1858118 Hatch enabled check repairs

Teach code asking Hatch whether printing is enabled to properly handle
the asynchronous response of the setting which now exists as a
workstation setting instead of a localStorage setting.

Related, if Hatch is unavailable, use browser printing regardless of the
hatch printing workstation setting.

Additionally update the "reprint last" handling to store the
last_printed value in localStorage instead of attempting to save its
value as a workstation setting.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Dan Scott <dan@coffeecode.net>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoDocs: Fixing asciidoc syntax so fop doesn't complain about staff client admin manual
Jane Sandberg [Mon, 30 Dec 2019 22:50:47 +0000 (14:50 -0800)]
Docs: Fixing asciidoc syntax so fop doesn't complain about staff client admin manual

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
5 years agoDocs: LP1767378 follow up: adding manual anchor
Jane Sandberg [Mon, 30 Dec 2019 22:24:58 +0000 (14:24 -0800)]
Docs: LP1767378 follow up: adding manual anchor

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
5 years agoDocs: fixed a spacing issue
lfloyd [Mon, 23 Dec 2019 17:53:04 +0000 (12:53 -0500)]
Docs: fixed a spacing issue

Signed-off-by: Lynn Floyd <lfloyd@library.in.gov>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
5 years agoDOCS: LP 1767378 Work Log documentation
lfloyd [Mon, 23 Dec 2019 16:25:40 +0000 (11:25 -0500)]
DOCS: LP 1767378 Work Log documentation

Updated Work Log documentation with new image.
Deleted old image files, noted which holds log.

Signed-off-by: Lynn Floyd <lfloyd1@library.in.gov>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
5 years agoLP#1855931: (follow-up) make grid filter control cells wrap as well
Galen Charlton [Fri, 27 Dec 2019 21:45:42 +0000 (16:45 -0500)]
LP#1855931: (follow-up) make grid filter control cells wrap as well

This patch applies "word-wrap: normal" to filter control cells
as well, making it more likely that they will stay aligned with
the width of their corresponding header cells. This can be tested
by adding visible columns to the "Grid with filtering" table in
the Angular sandbox (/eg2/en-US/staff/sandbox) and verifying that
the column after "Circulating Library" continues to have its
filter widget stay aligned with its label.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
5 years agolp1855931 wrap text for wide Angular eg-grid column headers
Mike Risher [Tue, 10 Dec 2019 23:15:35 +0000 (23:15 +0000)]
lp1855931 wrap text for wide Angular eg-grid column headers

Make column headers text wrap so that you can fully read the header even if
it's several words long.  This will help when there are multiple headers
that start with the same word and they show up identically.

Signed-off-by: Mike Risher <mrisher@catalyte.io>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
5 years agoLP#1857350: (follow-up) fix lint issue
Galen Charlton [Fri, 27 Dec 2019 22:50:08 +0000 (17:50 -0500)]
LP#1857350: (follow-up) fix lint issue

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Bill Erickson <berickxx@gmail.com>
5 years agoLP1857350 Org selector sorts by display value
Bill Erickson [Thu, 26 Dec 2019 18:18:26 +0000 (13:18 -0500)]
LP1857350 Org selector sorts by display value

When displaying the org unit selector, sort each set of children by the
display label (defaults to shortname).

Fixes issues with the org server sortTree function and adds a unit test
to test the repaired sort function.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agolp1843640 Standing Penalty Followup
Mike Risher [Fri, 13 Sep 2019 21:53:42 +0000 (21:53 +0000)]
lp1843640 Standing Penalty Followup
Fix 2 issues:  grid not updating when a new record is created and
double clicking a row doesn't edit it

Signed-off-by: Mike Risher <mrisher@catalyte.io>
Changes to be committed:
modified:   Open-ILS/src/eg2/src/app/staff/admin/local/standing-penalty.component.html
modified:   Open-ILS/src/eg2/src/app/staff/admin/local/standing-penalty.component.ts

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP1848778 Use consistent MARC breaker delimiter
Bill Erickson [Fri, 18 Oct 2019 17:47:17 +0000 (13:47 -0400)]
LP1848778 Use consistent MARC breaker delimiter

Use the '$' delimiter in the read-only MARC breaker view for
consistency with the flat text MARC editor to easy copy/paste from one
to the other.

To test
-------
[1] Apply the patch.
[2] Set up two records in a record bucket and initiate a merge. Note
    that when you select a lead record and choose to edit it in
    flat text mode, you can copy and paste fields from the subordinate
    record display without having to change the subfield delimiter
    character.
[3] Mark a record for overlay, perform a Z39.50 search, then select
    a hit and choose the overlay action. Note that you can copy and
    paste fields from the record to overlay when editing the incoming
    record using the flat text editor.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agoLP#1780283 Checking One Bill Checks Them All
Dan Briem [Fri, 9 Aug 2019 03:45:40 +0000 (23:45 -0400)]
LP#1780283 Checking One Bill Checks Them All

Under Patron->Bills->History if Bill # isn't visible for the Transactions
grid or Payment ID isn't visible for Payments grid, rows can't be selected
individually. This adds the required attribute to those field directives.

1. Under a patron account with multiple bills, go to Bills->History
2. Remove Bill # from the Transactions grid
3. Try to select an individual row (note all rows are selected)
4. Apply patch and repeat steps 1-3 (note rows are selected individually)

Signed-off-by: Dan Briem <dbriem@wlsmail.org>
Signed-off-by: Josh Stompro <stompro@stompro.org>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
5 years agolp1712644 Prevent check out due date in past
Katlyn Beck [Mon, 26 Nov 2018 21:23:48 +0000 (21:23 +0000)]
lp1712644 Prevent check out due date in past

- Prevents selecting past due date when checking out an item
- Prevents saving a due date with hatch when input date is invalid

Signed-off-by: Katlyn Beck <kbeck@catalyte.io>
Signed-off-by: Kyle Huckins <khuckins@catalyte.io>
Signed-off-by: Terran McCanna <tmccanna@georgialibraries.org>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>