Hard Coded Values

From Koha Wiki
Jump to navigation Jump to search

Koha was initially created back in 1999. Since then, a lot of modifications were done to get where we are now.

However, some other parts weren't touched for a while. This causes us to have some hard coded values here and there in the code.

This page is used to regroup all of those values in a single place.

accountlines.accounttype

  • A = Account Management Fee
  • CH
  • CR = C?? Returned
  • F = Fine
  • FFOR = Fine Forgiven
  • FN
  • FU = Fine Unpaid
  • IP
  • L = Lost Item
  • LR = Lost and Returned (C4::Circulation->_FixAccountForLostAndReturned)
  • M = Sundry
  • N = New Card
  • O = Overdue
  • Pay = Payment
  • RE
  • REF
  • Rent = Rental Fee
  • Rep = Replacement (?)
  • Res
  • RL
  • W = Writeoff

accounttypes as of 13.12.2015

I have tried to map all actually used values. I have used git grep on current master.

  • A = Account management fee
  • C = Credit
  • CR = a line appended to lost fee after returning it = it means C4::Circulation->_FixAccountForLostAndReturned, when found lost and return state, change line with "L" account type to "LR" and add line with "CR", also updated accountoffsets table!
  • F = Fine (overdue fine)
  • FFOR = Forgiven overdue fine
  • FOR = Forgiven
  • FU = overdue fine
  • L = Lost item
  • LR = Lost and Returned
  • M = Sundry
  • N = New card
  • O = overdue fine
  • Pay = Payment
  • REF = Refund?
  • Rent = Rental fee and renewel of rental item
  • Rep = Replacement
  • Res = Reserve charge
  • W = Write off
updated August 12, 2016
  • Pay 00 - cash via SIP2
  • Pay 02 - credit card via SIP2
  • HE - Hold expiration charge

In C4::Overdues->GetFine is used sql with condition accounttype like "F%"