Bug 5215 - Barcode field not cleared when using "Add and Duplicate" option on additem.pl
authorChris Nighswonger <cnighswonger@foundations.edu>
Fri, 10 Sep 2010 19:20:51 +0000 (15:20 -0400)
committerChris Nighswonger <cnighswonger@foundations.edu>
Fri, 10 Sep 2010 19:28:08 +0000 (15:28 -0400)
commit01247f2fc05eb90949057869522ffcc141940571
tree0dd54ae6ab686976dea77188a37f514ccd861676
parente58961f689422aa1d5ed4518820481b16d62cb4a
Bug 5215 - Barcode field not cleared when using "Add and Duplicate" option on additem.pl

The barcode field is not cleared/incremented properly when using the "Add and
Duplicate" option. Rather it is pre-populated with the previously used barcode
which causes additem.pl to return a duplicate barcode error if the cataloger
does not catch the mistake.

The problem is caused by the fact that the current item record is simply
duplicated and re-loaded into the form.

The solution is to add code which either pre-populates with the next barcode
number if the incremental pattern is set or clears the p subfield if one of the
various patterns using the javascript plugin is selected.

In reality C4::Barcodes should be implimented here along with all necessary changes elsewhere.
cataloguing/additem.pl