Project

General

Profile

« Previous | Next » 

Revision 53031

Parameterize context utils methods with a boolean parameter for productionIndex, add production url
In delete claims method add check for deleting record

View differences:

Migration.java
79 79
                source= buildProject(relation.getSourceId(),relation.getClaimId());
80 80
                claim.setSourceType(ClaimUtils.PROJECT);
81 81
            } else if (relation.getSourceType().equals(ClaimUtils.CONTEXT)) {
82
                Context context = dmfContextHandler.fetchContextByIdFromDmf(relation.getSourceId());
82
                Context context = dmfContextHandler.fetchContextByIdFromDmf(relation.getSourceId(), false);
83 83
                source = context;
84 84
                claim.setSourceType(ClaimUtils.CONTEXT);
85 85
            } else if (relation.getSourceType().equals(ClaimUtils.DATASET) || relation.getSourceType().equals(ClaimUtils.PUBLICATION)) {
......
144 144
                    source = buildProject(relation.getSourceId(), relation.getClaimId());
145 145
                    claim.setSourceType(ClaimUtils.PROJECT);
146 146
                } else if (relation.getSourceType().equals(ClaimUtils.CONTEXT)) {
147
                    Context context = dmfContextHandler.fetchContextByIdFromDmf(relation.getSourceId());
147
                    Context context = dmfContextHandler.fetchContextByIdFromDmf(relation.getSourceId(), false);
148 148
                    source = context;
149 149
                    claim.setSourceType(ClaimUtils.CONTEXT);
150 150
                } else if (relation.getSourceType().equals(ClaimUtils.DATASET) || relation.getSourceType().equals(ClaimUtils.PUBLICATION)) {
......
228 228
            System.out.println("Claim id:" + claim.getId());
229 229

  
230 230
            //first work with the Source
231
            Context context = dmfContextHandler.extractContextFromDMF(relation.getContextDmf());
231
            Context context = dmfContextHandler.extractContextFromDMF(relation.getContextDmf(), false);
232 232
            claim.setSourceType(ClaimUtils.CONTEXT);
233 233
            claim.setSource(context);
234 234

  
......
276 276
            logger.info("Claim id:" + claim.getId());
277 277

  
278 278
            //first work with the Source
279
            Context context = dmfContextHandler.extractContextFromDMF(relation.getContextDmf());
279
            Context context = dmfContextHandler.extractContextFromDMF(relation.getContextDmf(),false);
280 280
            claim.setSourceType(ClaimUtils.CONTEXT);
281 281
            claim.setSource(context);
282 282

  

Also available in: Unified diff