[% USE raw %] [% USE Asset %] [% USE Branches %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] Koha › Administration › [% IF op =='add_form' %] Credit types › [% IF credit_type.code %] Modify credit type [% ELSE %] New credit type [% END %] [% ELSE %] Credit types [% END %] [% INCLUDE 'doc-head-close.inc' %] [% INCLUDE 'header.inc' %] [% INCLUDE 'prefs-admin-search.inc' %]
[% FOREACH m IN messages %]
[% SWITCH m.code %] [% CASE 'success_on_saving' %] Credit type saved successfully. [% CASE 'error_on_saving' %] An error occurred when saving this credit type. [% CASE 'success_on_archive' %] Credit type archived successfully. [% CASE 'success_on_restore' %] Credit type restored successfully. [% CASE %] [% m.code | html %] [% END %]
[% END %] [% IF op == 'add_form' %] [% IF credit_type %]

Modify a credit type

[% ELSE %]

New credit type

[% END %]
  1. [% IF credit_type %] [% credit_type.code | html %] [% ELSE %] Required. Maximum length is 64 letters [% END %]
  2. [% IF credit_type && credit_type.is_system %] [% credit_type.description | html %] [% ELSE %] Required [% END %]
  3. [% IF credit_type && credit_type.is_system %] [% IF credit_type.can_be_added_manually %]Yes[% ELSE %]No[% END %] [% ELSIF credit_type.can_be_added_manually %] [% ELSE %] [% END %]
  4. [% IF credit_type.credit_number_enabled %] [% ELSE %] [% END %] Enable automatic generation of credit number (see AutoCreditNumber)
  5. [% IF credit_type && credit_type.is_system %] No library limitation [% ELSE %] Select 'All libraries' if this credit type should be available at all libraries. Otherwise select libraries you want to associate credit type with. [% END %]
Cancel
[% END %] [% IF op == 'list' %]

Account credit types

[% IF credit_types.count %] [% FOREACH credit_type IN credit_types %] [% END %]
Archived System Code Description Available for Credit number enabled Library limitations Actions
[% credit_type.archived | html %] [% credit_type.is_system | html %] [% credit_type.code | html %] [% credit_type.description | html %] [% IF credit_type.can_be_added_manually %]Manual credit[% END %] [% IF credit_type.credit_number_enabled %]Yes[% ELSE %]No[% END %] [% IF credit_type.library_limits.count > 0 %] [% library_limits_str = "" %] [% FOREACH library IN credit_type.library_limits %] [%- IF loop.first -%] [% library_limits_str = library.branchname _ " (" _ library.branchcode _ ")" %] [% ELSE %] [% library_limits_str = library_limits_str _ "\n" _ library.branchname _ " (" _ library.branchcode _ ")" %] [% END %] [% END %] [% limits_count = credit_type.library_limits.count %] [% tnx('{count} library limitation', '{count} library limitations', limits_count, { count => limits_count }) %] [% ELSE %] No limitation [% END %] [% IF !credit_type.archived %] Edit [% END %] [% IF !credit_type.is_system && !credit_type.archived %] Archive [% END %] [% IF !credit_type.is_system && credit_type.archived %] Restore [% END %]
[% ELSE %]
There are no account credit types defined. Create new credit type
[% END %] [% END %]
[% MACRO jsinclude BLOCK %] [% Asset.js("js/admin-menu.js") | $raw %] [% INCLUDE 'datatables.inc' %] [% END %] [% INCLUDE 'intranet-bottom.inc' %]