Closed sgoodswen closed 8 years ago
DNA yield is defined as PositiveIntegerField. The proposed change will change the database scheme.
This also a problem in the Lab Amplification tab when entering extraction result details you are only able to enter a whole number for DNA yield. Please change this to accept up to 2 decimal places.
If we use decimalfield, you have to define the maximal allowed digits. How many do you want?
5 digits e.g. 000.00 (i.e. 3 digits before 2 decimal places)
Do you want dna yield EnrichmentResult to be changed to decimal type too?
EnrichmentResult should also be changed for consistence after discussion.
If you enter more than 2 decimal places the program correctly warns with a "Please select a valid value" message. However, if more than 3 digits precede the decimal point e.g. 1000 or 1000.33 no message is displayed (although the program correctly does not respond to the [submit] button).
I used Firefox and Chromium and I had error message. This one is of them:
Did you use Safari? I have not changed any error handling which is from the base library. Have you seen any error messages before in any forms?
I am using Firefox 45.0.1 on a Mac. For the DNA yield I only see this type of error:
@sgoodswen it looks like a reasonable response even it is not in red. Not sure why it has different colours for errors.
I still do not get an error if more than 3 digits precede the decimal point e.g. 1000 or 1000.33
If you cannot save changes with invalid data, that means validation works. If you cannot save but you cannot see error message, and it happens in majority browsers, then we have to do more tests and maybe finish this later given the limited available time .
I confirm that you cannot save changes with invalid data e.g. 1000 or 1000.33, and this is what we want. However, for the record I do not see any error messages when using a Mac and Firefox, Windows 7 and Firefox, or Windows 7 and Internet explorer 11 when entering either1000 or 1000.33 I also confirm that the actual reported issue .i.e. “DNA yield in Extraction results needs 2 decimal places” has been fixed and therefore this issue can be closed
From: Li-ReDBox [notifications@github.com] Sent: Friday, 1 April 2016 11:17 AM To: acadsamplesdb/acad_samples Cc: Stephen Goodswen Subject: Re: [acadsamplesdb/acad_samples] DNA yield in Extraction results needs 2 decimal places (#21)
If you cannot save changes with invalid data, that means validation works. If you cannot save but you cannot see error message, and it happens in majority browsers, then we have to do more tests and maybe finish this later given the limited available time .
— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHubhttps://github.com/acadsamplesdb/acad_samples/issues/21#issuecomment-204193573
Thank @sgoodswen very much for doing the confirmations on different browsers. It is bad that user could not get good response if using certain browsers but at least the software does not allow un-wanted data pass.
This issue has been fixed
In the Lab extractions tab when entering sample details you are only able to enter a whole number for DNA yield. Please change this to accept up to 2 decimal places.