[Koha-bugs] [Bug 33847] Database update replaces undefined rules with defaults rather than the value that would be used

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Jul 18 02:21:55 CEST 2023


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

--- Comment #11 from David Cook <dcook at prosentient.com.au> ---
(In reply to Kyle M Hall from comment #10)
> (In reply to Tomás Cohen Arazi from comment #6)
> > We shouldn't be using our business classes on the DBRev, as they can change
> > in the future and thus break this DBRev.
> 
> I'm reading this as using DBIC directly is ok. Is that correct?

I agree that we shouldn't be using business classes in the DBRev. 

I think that DBIC directly should be OK so long as only core functionality is
used. (A number of DBIC classes like Suggestion.pm, Itemtype.pm,
ErmAgreement.pm, et cetera have additional code added after "DO NOT MODIFY THIS
OR ANYTHING ABOVE", which is added logic and not drawn directly from the
database.)

In the past, Ruby on Rails used to warn about using models in DB migrations but
those warnings appear to have disappeared from recent documentation:
https://guides.rubyonrails.org/v3.2/migrations.html#using-models-in-your-migrations

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


More information about the Koha-bugs mailing list