Opened 17 years ago
Closed 17 years ago
#955 closed enhancement (fixed)
Array slides – make test for barcode uniqueness
Reported by: | Nicklas Nordborg | Owned by: | Nicklas Nordborg |
---|---|---|---|
Priority: | minor | Milestone: | BASE 2.7 |
Component: | core | Version: | |
Keywords: | Cc: |
Description
As mentioned in the BASE core specifications enforcing array slide barcodes to be unique would cause problems with deleting/undeleting. Therefore it's the users' responsibility to keep barcodes unique.
However, managing a production installation in a setting where numerous array slides are tracked in BASE requires barcodes to be unique.
Therefore, if it still would pose a problem to enforce barcode uniqueness of array slides, a test for the same would be useful to avoid ending up in a situation where duplicated barcodes exist in the same system.
That is, when creating an array slide, either by adding one slide or by using the Multiple slides wizard (or if implemented by using an import plugin), a test is executed that verifies the uniqueness of entered barcodes. If entered barcodes already exists, the user is notified about this and allowed to abort the creation of new slides. The test would have to have complete read access to all slides in the system irrespectively of owner in order to perform verification.
Fancy variants where the duplicated barcode is highlighted or in some other way reported to the user can of course be added. If an import plugin is used, test for barcode uniqueness and alternative actions in response to existing duplicated could be handled by the plugin.
Change History (2)
comment:1 by , 17 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
This is how it can be implemented. Due to backwards compatibility this can't go very deep into the core.
ArraySlide.exists(String barcode)
as a static method. This will check if a slide with the barcode already exists in the database. Access permissions are ignored.ArraySlids.exists()
method to check if the barcode already exists. The method should only be called for new slides or if the barcode has changed.