[%- USE LxERP -%][%- USE L -%] [%- INCLUDE 'common/flash.html' %] [% L.javascript_tag('jquery.selectboxes', 'jquery.multiselect2side') %]

[%- LxERP.t8("Introduction of clients") %]

[% LxERP.t8("kivitendo has been extended to handle multiple clients within a single installation.") %] [% LxERP.t8("Therefore several settings that had to be made for each user in the past have been consolidated into the client configuration.") %] [% LxERP.t8("You have to grant users access to one or more clients.") %] [% LxERP.t8("The user can chose which client to connect to during login.") %]

[% LxERP.t8("The access rights a user has within a client instance is still governed by his group membership.") %] [% LxERP.t8("Only groups that have been configured for the client the user logs in to will be considered.") %]

[% LxERP.t8("The following list has been generated automatically from existing users collapsing users with identical settings into a single entry.") %] [% LxERP.t8("Please select which client configurations you want to create.") %] [% LxERP.t8("The 'name' is the field shown to the user during login.") %] [% LxERP.t8("It can be changed later but must be unique within the installation.") %]

[%- FOREACH client = SELF.clients %] [%- L.hidden_tag("clients[+].dummy", 1) %]

[%- L.checkbox_tag("clients[].enabled", label=LxERP.t8("Create new client #1", loop.count), checked=client.enabled) %]

[%- LxERP.t8("General settings") %]
[%- LxERP.t8("Client name") %]: [%- L.input_tag("clients[].name", client.name) %] [%- LxERP.t8("Company name") %]: [%- L.input_tag("clients[].company", client.company) %] [%- LxERP.t8("Address") %]: [%- L.textarea_tag("clients[].address", client.address, rows=4, cols=40) %]
[%- LxERP.t8("Tax number") %]: [%- L.input_tag("clients[].taxnumber", client.taxnumber) %] [%- LxERP.t8("VAT ID") %]: [%- L.input_tag("clients[].co_ustid", client.co_ustid) %] [%- LxERP.t8("DUNS-Nr") %]: [%- L.input_tag("clients[].duns", client.duns) %]
[%- LxERP.t8("SEPA creditor ID") %]: [%- L.input_tag("clients[].sepa_creditor_id", client.sepa_creditor_id) %]
[%- LxERP.t8("Print templates") %]: [%- L.select_tag("clients[].templates", SELF.templates, default=client.templates) %]
[%- LxERP.t8("User access") %]
[%- LxERP.t8("Users with access to this client") %]: [% L.select_tag('clients[].users[]', SELF.users, id='users_multi_' _ loop.count, value_key='id', title_key='login', default=client.users, multiple=1) %]
[%- LxERP.t8("Groups that are valid for this client for access rights") %]: [% L.select_tag('clients[].groups[]', SELF.groups, id='groups_multi_' _ loop.count, value_key='id', title_key='name', default=client.groups, multiple=1) %]
[%- LxERP.t8("Database settings") %]
[%- LxERP.t8("Database Host") %]: [%- L.input_tag("clients[].dbhost", client.dbhost) %] [%- LxERP.t8("Port") %]: [%- L.input_tag("clients[].dbport", (client.dbport || 5432)) %] [%- LxERP.t8("Database name") %]: [%- L.input_tag("clients[].dbname", client.dbname) %]
[%- LxERP.t8("User") %]: [%- L.input_tag("clients[].dbuser", client.dbuser) %] [%- LxERP.t8("Password") %]: [%- L.input_tag("clients[].dbpasswd", client.dbpasswd) %]
[% L.multiselect2side('users_multi_' _ loop.count, labelsx => LxERP.t8('All users'), labeldx => LxERP.t8('Users with access')) %] [% L.multiselect2side('groups_multi_' _ loop.count, labelsx => LxERP.t8('All groups'), labeldx => LxERP.t8('Groups valid for this client')) %] [%- END %]

[%- L.hidden_tag('action', 'list_users') %] [% L.submit_tag('dummy', LxERP.t8('Continue')) %]