@@ -, +, @@ PatronQuickAdd PatronQuickAddFields 1 - Apply patch 2 - run updatedatabase.pl 3 - Add a new patron and ensure nothing has changed 4 - Enable quick add (do not add any fields) 5 - Only required fields should be displayed 6 - Ensure you can save patron 7 - Verify that subsequent edits use only full form 8 - Verify that data on form submitted is the data saved to patron 9 - Add fields to PatronQuickAddFields --- .../bug_3534_add_PatronQuickAdd_sysprefs.sql | 2 + installer/data/mysql/sysprefs.sql | 2 + .../prog/en/modules/admin/preferences/patrons.pref | 7 +++ .../prog/en/modules/members/memberentrygen.tt | 69 ++++++++++++++++++++-- 4 files changed, 76 insertions(+), 4 deletions(-) create mode 100644 installer/data/mysql/atomicupdate/bug_3534_add_PatronQuickAdd_sysprefs.sql --- a/installer/data/mysql/atomicupdate/bug_3534_add_PatronQuickAdd_sysprefs.sql +++ a/installer/data/mysql/atomicupdate/bug_3534_add_PatronQuickAdd_sysprefs.sql @@ -0,0 +1,2 @@ +INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('PatronQuickAdd', '0', 'Enables the ability to pay fees and fines from the OPAC via PayPal', NULL, 'YesNo'); +INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('PatronQuickAddFields', '', 'A list of fields separated by "|" to be displayed along with mandatory fields in the patron quick add form if enabled', NULL, 'Free'); --- a/installer/data/mysql/sysprefs.sql +++ a/installer/data/mysql/sysprefs.sql @@ -369,6 +369,8 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('PatronSelfRegistrationVerifyByEmail','0',NULL,'If enabled, any patron attempting to register themselves via the OPAC will be required to verify themselves via email to activate his or her account.','YesNo'), ('PatronsPerPage','20','20','Number of Patrons Per Page displayed by default','Integer'), ('EnablePayPalOpacPayments', '0', NULL , 'Enables the ability to pay fees and fines from the OPAC via PayPal', 'YesNo' ), +('PatronQuickAdd', '0', NULL , 'Enables the patron quick add form when entering a new patron. Displays only mandatory fields and fields specified in PatronQuickAddFields', 'YesNo' ), +('PatronQuickAddFields', '', NULL , 'A list of fields separated by "|" to be displayed along with mandatory fields in the patron quick add form if enabled', 'Free' ), ('PayPalChargeDescription', 'Koha fee payment', NULL , 'This preference defines what the user will see the charge listed as in PayPal', 'Free'), ('PayPalPwd', '', NULL , 'Your PayPal API password', 'Free'), ('PayPalSandboxMode', '1', NULL , 'If enabled, the system will use PayPal''s sandbox server for testing, rather than the production server.', 'YesNo'), --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref @@ -100,6 +100,13 @@ Patrons: class: integer - results per page in the staff client. - + - pref: PatronQuickAdd + choices: + yes: Use + no: "Don't use" + - "the patron quick add form when entering a new patron. Displays only mandatory fields and fields specified here:" + - pref: PatronQuickAddFields + - - "Use the SMS::Send::" - pref: SMSSendDriver - driver to send SMS messages. --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt @@ -8,6 +8,32 @@ // +[% UNLESS ( check_member ) %]
[% END %] @@ -796,7 +822,7 @@ [% ELSE %] [% END %] - [% END %] + [% END % ] [% END %] [% IF ( mandatorypassword ) %]Required[% END %][% IF ( ERROR_password_mismatch ) %]Passwords do not match[% END %] @@ -1014,16 +1040,51 @@ [% UNLESS ( check_member ) %]
+ [% IF opadd %] + + [% END %] - [% IF ( opadd ) %] + [% IF ( opadd ) %] Cancel [% ELSE %] Cancel [% END %]
[% END %] +
- + +[% IF Koha.Preference('PatronQuickAdd') && opadd && !check_member %] +
+
Quick Add +
    +
+
+ +
+ + + Cancel +
+ +
+ +[% END %] --