Project

General

Profile

Actions

bug #10394

closed

Details page for derived unit only shows categorical data

Added by Katja Luther 12 months ago. Updated 11 months ago.

Status:
Closed
Priority:
Highest
Assignee:
Category:
cdm-dataportal
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Severity:
normal
Found in Version:

Description

The details page for derived units shows the character data entered for the specimen, but the value for the quantitative data is empty and therefore not shown.

The value is created by DefaultCategoricalDescriptionBuilder.


Files

clipboard-202310191315-haqx8.png (21.9 KB) clipboard-202310191315-haqx8.png Andreas Müller, 10/19/2023 01:15 PM
Screenshot 2023-10-19 143531.png (32.3 KB) Screenshot 2023-10-19 143531.png Katja Luther, 10/19/2023 02:35 PM
Screenshot 2023-10-19 143444.png (10.5 KB) Screenshot 2023-10-19 143444.png Katja Luther, 10/19/2023 02:36 PM

Related issues

Related to EDIT - feature request #10420: Order exact values in QuantitativeDataFormatterClosedAndreas Müller

Actions
Actions #1

Updated by Andreas Müller 12 months ago

  • Tags changed from additivity to additivity, specimen

Is this a dataportal issue?

Actions #2

Updated by Andreas Müller 12 months ago

  • Category changed from cdmlib to cdm-dataportal
Actions #3

Updated by Katja Luther 11 months ago

Andreas Müller wrote in #note-1:

Is this a dataportal issue?

Maybe more a cdmlib issue because the data collection is done in DefaultCategoricalDescriptionBuilder, but currently it is only used in data portal.

Actions #4

Updated by Katja Luther 11 months ago

  • Status changed from New to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

I adapted the QuantitativeDataDescriptionBuilder, an example for review can be find here:
https://test.e-taxonomy.eu/dataportal/preview/caryophyllales_spp/cdm_dataportal/occurrence/c46a81e6-ec01-465a-a00d-7bf88fcec32d

Actions #5

Updated by Katja Luther 11 months ago

  • % Done changed from 0 to 50
Actions #6

Updated by Andreas Müller 11 months ago

A null check is not needed if calling HibernateProxyHelper.deproxy(). I removed it in code.

Actions #7

Updated by Andreas Müller 11 months ago

There is an explicit unlikely argument warning in the code:

Can you please adapt the code accordingly!

Actions #8

Updated by Andreas Müller 11 months ago

  • Status changed from Resolved to Feedback
  • Assignee changed from Andreas Müller to Katja Luther
Actions #9

Updated by Andreas Müller 11 months ago

... or add a test showing that the result is correct for integer values.

Actions #10

Updated by Andreas Müller 11 months ago

OK, for the above link it seems to work as there are also int values. However, to me it is unclear if the if statement is needed at all and if needs to be implemented such. But I see it is old code so it is not related to this ticket.

Actions #11

Updated by Andreas Müller 11 months ago

Also the parameter naming is strange. The List is called "float values". Maybe we can correct this, too.

Actions #12

Updated by Andreas Müller 11 months ago

I will adapt the code

Actions #13

Updated by Andreas Müller 11 months ago

  • % Done changed from 50 to 90

Done. Please review code adaptation. If correct we can close the ticket as functionality works as expected.

Actions #14

Updated by Katja Luther 11 months ago

I think this does not work as it should:

The prior implementation was:

Actions #15

Updated by Andreas Müller 11 months ago

Should be fixed. Can you test again?

Actions #16

Updated by Andreas Müller 11 months ago

By the way, is there a reason, why the values are not ordered? I would expect it to be wanted behaviour to order them.

Actions #17

Updated by Andreas Müller 11 months ago

Is the above test publicly available with a link?

Actions #18

Updated by Katja Luther 11 months ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

This looks fine now. I added sorting to the list of values.

Actions #19

Updated by Katja Luther 11 months ago

Andreas Müller wrote in #note-17:

Is the above test publicly available with a link?

This is my local installation of the centaurea/flora of greece portal.

Actions #20

Updated by Andreas Müller 11 months ago

  • Status changed from Resolved to Closed
  • % Done changed from 90 to 100

I tested again with the above link (and adapted data). Works as expected and we can close this ticket.

Actions #21

Updated by Andreas Müller 11 months ago

  • Assignee changed from Andreas Müller to Katja Luther
Actions #22

Updated by Andreas Müller 11 months ago

Actions

Also available in: Atom PDF