[Koha-bugs] [Bug 29012] Some rules are not saved when left blank while editing a 'rule' line in smart-rules.pl

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu Feb 24 08:53:12 CET 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29012

--- Comment #12 from Kevin Carnes <kevin.carnes at ub.lu.se> ---
(In reply to Kevin Carnes from comment #9)
> (In reply to Nick Clemens from comment #7)
> > (In reply to Jonathan Druart from comment #4)
> > > I am not sure the patch is the correct way to fix it.
> > > If no value has not been filled in, we shouldn't default.
> > > 
> > > In my opinion we should better improve the way we calculate/retrieve the
> > > rules instead.
> > 
> > I think this fix is correct for current use of rules as a 'row' - we have
> > all the current rules inthe table grouped, and don't expect to fall back on
> > any individual column if a row is set for a patron/category type
> > 
> > I do think there are other issues:
> > bug 28774  made rentaldiscount not save if blank, but creates the same issue
> > here of defaulting to a higher rule level
> > unseen_renewals of '0' seems to translate to 'unlimited' - I don't think
> > that's correct
> 
> It appears that unseen_renewals is saved even when blank, so I removed it
> from the patch. Would somebody please confirm this?

Ok, unseen_renewals is only saved when UnseenRenewals is enabled. It now
defaults to "" which is unlimited. '0' means none are allowed. It only starts
counting unseen renewals when UnseenRenewals is not unlimited. It might make
more sense to always count unseen renewals.

The default value for rentaldiscount is 0, so it won't be blank and won't be
affected by bug 28774.

I also updated onboarding.pl for the Web installer. I don't know if there are
any more rules that should be fixed there.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list