Bug 12718 - Show extended patron attributes in the OPAC

At some point the patron details page in the OPAC lost the display of
patron attributes. This patch returns the attributes to the update page.

To test, log in to the OPAC as a patron who has data in one or more
extended patron attributes. View the "your personal details" page
(opac-memberentry.pl):

- Confirm that the information displays correctly.
- Test with OPACPatronDetails both on and off.
- Test with patron who has no data in extended patron attributes.

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Attributes only display when 'display in OPAC' is configured.
Attribute shows correct description, when authorised value is used.
Works as expected, updating is currently not yet possible.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402: Use an object for contacts

In preparation for adding the ability to handle multiple contacts, this
patch moves booksellers' contacts into their own class,
C4::Bookseller::Contact.

To test:
1) Apply patch.
2) Run database update.
3) Edit a bookseller, making sure to add a contact.
4) View the bookseller's information, making sure the contact
   information is there.
5) Run the unit test:
    > prove t/db_dependent/Bookseller.t

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paola Rossi <paola.rossi@cineca.it>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402: Move contacts to separate table

This patch normalizes the data structures used for bookseller
contacts.

To test:
1) Repeat tests described on previous patch.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paola Rossi <paola.rossi@cineca.it>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402: Add ability to enter multiple contacts

Some vendors may have more than one contact. For example, a technical
contact and a billing contact, or a contact for journals and a contact
for monographs. Rather than require that each contact be either made
into a separate vendor or recorded somewhere outside of Koha, it would
be really useful of Koha had the ability to add multiple additional
contacts to vendors in the Acquisitions module.

To test:
1) Apply patch.
2) Edit a bookseller, making sure to add a contact.
3) View the bookseller's information, making sure the contact
   information is there.
4) Run the unit test:
    > prove t/db_dependent/Bookseller.t
5) Add multiple contacts to a vendor, see that they show up.
6) Delete one contact from a vendor with multiple contacts,
   see that the result is correct.
7) Sign off.

Note: This test plan can supersede that on the previous two patches,
as all functionality of the previous two patches is required by this
one.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paola Rossi <paola.rossi@cineca.it>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402 [Template follow-up] Add multiple contacts for vendors

This template-only follow-up tweaks the button labels and restructures
the vendor view layout a little bit to make it more amenable to multiple
contacts:

- Add spaces after button icons
- Change "Add contact" to "Add another contact" in hopes of making it
  less ambiguous whether clicking it will submit the whole form.
- Eliminate duplicate headers on the vendor view page by making the
  contact name the subheading for each individual contact.

To test, view details for vendors with one or more contacts, and try
editing to add additional contacts. Everything should look good and work
correctly.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paola Rossi <paola.rossi@cineca.it>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402 follow-up: choose contacts for claims

This patch makes it possible to choose a particular contact for
acquisitions and serials claims. To test:

1) Select a contact to use for claiming late orders and a contact
   to use for claiming late issues.
2) Send a claim for a late order and a claim for a late issue.
3) Note that the claims went out to the proper people.
4) Run the unit test with:
    > prove t/db_dependent/Letters.t
5) Sign off.

Note: the claim messages are recorded in the logs in the *Acquisitions*
module, not the Letters module as you might expect

This patch also fixes several perlcritic violations and centralizes
contact-related unit testing in Bookseller.t.

Signed-off-by: Paola Rossi <paola.rossi@cineca.it>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402: FIX conflicts in Letters.t

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
10402: DBRev 3.17.00.016

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
10402: DBIx::Class schema update

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 10402: (QA followup) amend unit tests