I haven’t been able to test the hold logic (soon, I hope). Once I got the VuFind base code up to date, I ceased to able to log in when I tried to place a hold. Web Services successfully logs me in from the ILS’s
perspective but module/VuFind/src/VuFind/Auth/Manager.php is throwing a ‘authentication_error_technical’ in the login function. My auth method is set to ILS in config.ini.
Any idea what might be going on?
Okay, after some frantic refactoring this morning, I’ve got services set up for the hold logic:
You can now override the 'VuFind\ILSHoldLogic' and/or 'VuFind\ILSTitleHoldLogic' services to inject custom behavior.
Let me know if you have any questions/problems… and apologies in advance if it’s a bit painful merging up to the current master. There are a lot of parts in motion right now.
I only understand the options you’re offering at a high level so I can’t comprehend what the full set of ramifications would be for either choice. I’ll answer in this fashion: the solution should offer the most
versatility in affecting how/when/what hold-related links appear. For example, we don’t do recalls – patrons place holds on anything that’s holdable and wait their turn. Generally we offer title holds, but we switch to copy holds for volume-/issue- based items
(title holds and copy holds are mutually exclusive).
So does one of the options achieve maximum versatility better than the other? (If you go with option #2, I can definitely say I’m going to need some help with the infrastructure.
Right now, there's no extension point for the hold logic code. There are a couple of approaches:
1.) We could define the hold logic as a service in one of the configured plugin managers, and then have everything that uses it pull it from there; then you would be able to configure a custom hold logic class just like other things.
2.) We could add setters to classes that rely on the hold logic -- so, for example, the SolrMarc record driver could have setHoldLogic/getHoldLogic methods, with getHoldLogic constructing a default \VuFind\ILS\Logic\Holds object if no override was set. Then
using an alternative class would be a matter of creating a custom factory for the SolrMarc class that injects a different Holds logic object.
Does that make sense? I think #1 might be a bit less work for you to deal with, but it makes our huge configuration yet another notch larger. Option #2 requires less default configuration, but it makes the custom configuration a little less convenient. Let
me know if you have thoughts/preferences, and I can help create the infrastructure you need to plug in your custom class if that would be useful. (Hopefully I'll have a few minutes tomorrow).
From: Chanel Wheeler [Chanel.Wheeler@yavapai.us]
Sent: Tuesday, February 26, 2013 4:14 PM
To: vufind-tech (email@example.com)
Subject: [VuFind-Tech] VuFind 2 - extending class from file not in module.config.php
I’m extending VuFind/ILS/Logic/Holds. I don’t see anything in the VuFind module.config.php that I should add/customize for my local module. The reason this is of particular concern is because VuFind isn’t picking
up my local Holds.php with the extended class (I even tried putting gibberish in it and VuFind isn’t barfing). I’ve deleted the cached Objects directory and restarted VuFind. What else do I need to do?
Library Network Programmer/Analyst
Yavapai Library Network
1120 Commerce Dr.
Prescott, AZ 86305
Phone: (928) 442-5741
Open a help desk ticket