Tony CHEMIT pushed to branch develop at ultreiaio / ird-observe

Commits:

6 changed files:

Changes:

  • client/src/main/java/fr/ird/observe/client/ui/content/ObserveFocusManager.java
    ... ... @@ -35,6 +35,8 @@ import fr.ird.observe.client.ui.content.data.longline.logbook.FloatlinesComposit
    35 35
     import fr.ird.observe.client.ui.content.data.longline.logbook.HooksCompositionLogbookUI;
    
    36 36
     import fr.ird.observe.client.ui.content.data.longline.logbook.LonglineGlobalCompositionLogbookUI;
    
    37 37
     import fr.ird.observe.client.ui.content.data.longline.logbook.SetLonglineLogbookUI;
    
    38
    +import fr.ird.observe.client.ui.content.data.longline.logbook.TripLonglineLandingLogbookListUI;
    
    39
    +import fr.ird.observe.client.ui.content.data.longline.logbook.TripLonglineSampleLogbookListUI;
    
    38 40
     import fr.ird.observe.client.ui.content.data.longline.obs.ActivityLonglineObsListUI;
    
    39 41
     import fr.ird.observe.client.ui.content.data.longline.obs.ActivityLonglineObsUI;
    
    40 42
     import fr.ird.observe.client.ui.content.data.longline.obs.BaitsCompositionObsUI;
    
    ... ... @@ -559,6 +561,9 @@ public class ObserveFocusManager {
    559 561
             builder.put(ActivityLonglineObsListUI.class, new ContentListUIObserveLayoutFocusTraversalPolicy());
    
    560 562
             builder.put(ActivityLonglineLogbookListUI.class, new ContentListUIObserveLayoutFocusTraversalPolicy());
    
    561 563
     
    
    564
    +        builder.put(TripLonglineLandingLogbookListUI.class, new ContentListUIObserveLayoutFocusTraversalPolicy());
    
    565
    +        builder.put(TripLonglineSampleLogbookListUI.class, new ContentListUIObserveLayoutFocusTraversalPolicy());
    
    566
    +
    
    562 567
             builder.put(TripLonglineUI.class, new ObserveLayoutFocusTraversalPolicy<TripLonglineUI>() {
    
    563 568
     
    
    564 569
                 @Override
    

  • client/src/main/java/fr/ird/observe/client/ui/content/data/longline/logbook/CatchLonglineLogbookUI.jaxx
    ... ... @@ -36,6 +36,7 @@
    36 36
         fr.ird.observe.dto.data.longline.SetLonglineLogbookCatchDto
    
    37 37
         fr.ird.observe.dto.referential.SpeciesReference
    
    38 38
         fr.ird.observe.dto.referential.SexReference
    
    39
    +    fr.ird.observe.dto.referential.WeightMeasureMethodReference
    
    39 40
         fr.ird.observe.dto.referential.longline.BaitHaulingStatusReference
    
    40 41
         fr.ird.observe.dto.referential.longline.CatchFateLonglineReference
    
    41 42
         fr.ird.observe.dto.referential.longline.HealthnessReference
    
    ... ... @@ -156,10 +157,10 @@
    156 157
                       <NumberEditor id='totalWeight' constructorParams='this' styleClass="float3"/>
    
    157 158
                     </cell>
    
    158 159
                     <cell>
    
    159
    -                  <JLabel id='weightDeterminationMethodLabel'/>
    
    160
    +                  <JLabel id='weightMeasureMethodLabel'/>
    
    160 161
                     </cell>
    
    161 162
                     <cell weightx='1' anchor='east'>
    
    162
    -                  <BeanComboBox id='weightDeterminationMethod' constructorParams='this' genericType='HealthnessReference'/>
    
    163
    +                  <BeanComboBox id='weightMeasureMethod' constructorParams='this' genericType='WeightMeasureMethodReference'/>
    
    163 164
                     </cell>
    
    164 165
                   </row>
    
    165 166
     
    

  • client/src/main/java/fr/ird/observe/client/ui/content/data/longline/logbook/CatchLonglineLogbookUI.jcss
    ... ... @@ -76,6 +76,10 @@
    76 76
       selectedItem:{tableEditBean.getSpeciesCatch()};
    
    77 77
     }
    
    78 78
     
    
    79
    +#weightMeasureMethod {
    
    80
    +  selectedItem:{tableEditBean.getWeightMeasureMethod()};
    
    81
    +}
    
    82
    +
    
    79 83
     #onBoardProcessing {
    
    80 84
       selectedItem:{tableEditBean.getOnBoardProcessing()};
    
    81 85
     }
    

  • client/src/main/java/fr/ird/observe/client/ui/content/data/longline/logbook/CatchLonglineLogbookUIHandler.java
    ... ... @@ -96,14 +96,14 @@ public class CatchLonglineLogbookUIHandler extends ContentTableUIHandler<SetLong
    96 96
     
    
    97 97
             addReferentialFilter(CatchLonglineLogbookDto.PROPERTY_SPECIES_CATCH, (ReferentialReferencesFilter<SpeciesDto, SpeciesReference>) incomingReferences -> {
    
    98 98
                 String speciesListId = ObserveSwingApplicationContext.get().getConfig().getSpeciesListLonglineCatchId();
    
    99
    -            String tripLonglineId = getSelectedId();
    
    99
    +            String tripLonglineId = ObserveSwingApplicationContext.get().getNavigationSelect().getLongline().getTrip().getId();
    
    100 100
                 List<SpeciesReference> result = getTripLonglineService().getSpeciesByListAndTrip(tripLonglineId, speciesListId).toList();
    
    101 101
                 return DtoReferenceCollection.filterEnabled(result);
    
    102 102
             });
    
    103 103
     
    
    104 104
             addReferentialFilter(CatchLonglineLogbookDto.PROPERTY_PREDATOR, (ReferentialReferencesFilter<SpeciesDto, SpeciesReference>) incomingReferences -> {
    
    105 105
                 String speciesListId = ObserveSwingApplicationContext.get().getConfig().getSpeciesListLonglineDepredatorId();
    
    106
    -            String tripLonglineId = getSelectedId();
    
    106
    +            String tripLonglineId = ObserveSwingApplicationContext.get().getNavigationSelect().getLongline().getTrip().getId();
    
    107 107
                 List<SpeciesReference> result = getTripLonglineService().getSpeciesByListAndTrip(tripLonglineId, speciesListId).toList();
    
    108 108
                 return DtoReferenceCollection.filterEnabled(result);
    
    109 109
             });
    
    ... ... @@ -211,7 +211,7 @@ public class CatchLonglineLogbookUIHandler extends ContentTableUIHandler<SetLong
    211 211
             boolean isGrouped = CatchAcquisitionMode.GROUPED.equals(newMode);
    
    212 212
     
    
    213 213
             ui.getTotalWeight().setEnabled(isGrouped);
    
    214
    -        ui.getWeightDeterminationMethod().setEnabled(isGrouped);
    
    214
    +        ui.getWeightMeasureMethod().setEnabled(isGrouped);
    
    215 215
             ui.getCount().setEnabled(isGrouped);
    
    216 216
     
    
    217 217
             if (createMode) {
    

  • client/src/main/java/fr/ird/observe/client/ui/content/data/longline/logbook/TripLonglineSampleLogbookListUIHandler.java
    ... ... @@ -83,7 +83,7 @@ public class TripLonglineSampleLogbookListUIHandler extends ContentListUIHandler
    83 83
     
    
    84 84
         @Override
    
    85 85
         protected ContentMode getContentMode() {
    
    86
    -        String selectedId = getSelectedId();
    
    86
    +        String selectedId = getSelectedParentId();
    
    87 87
             if (!selectedId.equals(getEditNode().getId())) {
    
    88 88
                 addInfoMessage(n("observe.common.TripLonglineDto.message.no.active.found"));
    
    89 89
                 return ContentMode.READ;
    

  • persistence/src/main/resources/db/migration/8.0/08_add_weight_category-common.sql
    ... ... @@ -21,4 +21,4 @@
    21 21
     ---
    
    22 22
     CREATE TABLE observe_longline.WeightCategory(topiaid VARCHAR(255) NOT NULL,topiaversion BIGINT NOT NULL, topiacreatedate DATE, lastupdatedate TIMESTAMP NOT NULL, code VARCHAR(255), status INTEGER DEFAULT 1, needComment BOOLEAN DEFAULT false, uri VARCHAR(255), label1 VARCHAR(255), label2 VARCHAR(255), label3 VARCHAR(255),label4 VARCHAR(255),label5 VARCHAR(255),label6 VARCHAR(255),label7 VARCHAR(255),label8 VARCHAR(255));
    
    23 23
     ALTER TABLE observe_longline.WeightCategory ADD CONSTRAINT PK_WeightCategory PRIMARY KEY(topiaid);
    
    24
    -INSERT INTO observe_common.LASTUPDATEDATE(topiaId, topiaversion, topiacreatedate, TYPE , LASTUPDATEDATE) values ('fr.ird.observe.entities.LastUpdateDate#666#1005', 0,CURRENT_DATE, 'fr.ird.observe.entities.referentiel.longline.WeightCategory', CURRENT_TIMESTAMP);
    24
    +INSERT INTO observe_common.LASTUPDATEDATE(topiaId, topiaversion, topiacreatedate, TYPE , LASTUPDATEDATE) values ('fr.ird.observe.entities.LastUpdateDate#666#1005', 0,CURRENT_DATE, 'fr.ird.observe.entities.referentiel.longline.WeightCategoryLongline', CURRENT_TIMESTAMP);