Skip to content

Commit 3023aec

Browse files
committed
refactor: get rid of base notice URI double-replace
The double-replace function was likely a leftover from the Standard Forms mapping days, in order to account for undesireable characters in notice IDs. In the eForms SDK, validation takes place at the source in order to enforce a pattern, and therefore we need not bother about handling corner cases when using these IDs in the URI.
1 parent a08026b commit 3023aec

93 files changed

Lines changed: 515 additions & 515 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/mappings-can/AwardDecision-can.rml.ttl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ tedm:MG-AwardDecision_ND-SettledContract a rr:TriplesMap ;
3838
rr:subjectMap
3939
[
4040
rdfs:label "ND-SettledContract" ;
41-
rml:reference "if(exists(cbc:AwardDate)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/AwardDecision/' || encode-for-uri(cbc:AwardDate) else null" ;
41+
rml:reference "if(exists(cbc:AwardDate)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/AwardDecision/' || encode-for-uri(cbc:AwardDate) else null" ;
4242
rr:class epo:AwardDecision
4343
] ;
4444
rr:predicateObjectMap
@@ -79,7 +79,7 @@ tedm:MG-AwardDecision_ND-LotResult a rr:TriplesMap ;
7979
#
8080
# ASSUMPTION: all SettledContract AwardDates under the LotResult
8181
# are the same date
82-
rml:reference "'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/AwardDecision/' || (if(exists(/*/ext:UBLExtensions/ext:UBLExtension/ext:ExtensionContent/efext:EformsExtension/efac:NoticeResult/efac:SettledContract[cbc:ID/text() = //efac:SettledContract/cbc:ID/text()]/cbc:AwardDate)) then encode-for-uri((/*/ext:UBLExtensions/ext:UBLExtension/ext:ExtensionContent/efext:EformsExtension/efac:NoticeResult/efac:SettledContract[cbc:ID/text() = //efac:SettledContract/cbc:ID/text()]/cbc:AwardDate)[1]) else if (exists(efac:SettledContract/cbc:ID) and not(exists(efac:SettledContract[2]/cbc:ID))) then encode-for-uri(efac:SettledContract/cbc:ID) else encode-for-uri(cbc:ID))" ;
82+
rml:reference "'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/AwardDecision/' || (if(exists(/*/ext:UBLExtensions/ext:UBLExtension/ext:ExtensionContent/efext:EformsExtension/efac:NoticeResult/efac:SettledContract[cbc:ID/text() = //efac:SettledContract/cbc:ID/text()]/cbc:AwardDate)) then encode-for-uri((/*/ext:UBLExtensions/ext:UBLExtension/ext:ExtensionContent/efext:EformsExtension/efac:NoticeResult/efac:SettledContract[cbc:ID/text() = //efac:SettledContract/cbc:ID/text()]/cbc:AwardDate)[1]) else if (exists(efac:SettledContract/cbc:ID) and not(exists(efac:SettledContract[2]/cbc:ID))) then encode-for-uri(efac:SettledContract/cbc:ID) else encode-for-uri(cbc:ID))" ;
8383
rr:class epo:AwardDecision
8484
] ;
8585
rr:predicateObjectMap

src/mappings-can/BudgetProvider-can.rml.ttl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ tedm:MG-BudgetProvider_ND-FinancingParty a rr:TriplesMap ;
3535
rr:subjectMap
3636
[
3737
rdfs:label "ND-FinancingParty" ;
38-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/BudgetProvider/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
38+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/BudgetProvider/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
3939
rr:class epo:BudgetProvider
4040
] ;
4141
rr:predicateObjectMap
@@ -81,7 +81,7 @@ tedm:MG-Lot-contextualisedBy-BudgetProvider_ND-FinancingParty a rr:TriplesMap ;
8181
rr:subjectMap
8282
[
8383
rdfs:label "ND-FinancingParty" ;
84-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Lot/{../efac:TenderLot/cbc:ID}" ;
84+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Lot/{../efac:TenderLot/cbc:ID}" ;
8585
rr:class epo:Lot
8686
] ;
8787
.
@@ -97,7 +97,7 @@ tedm:MG-BudgetProvider-seeAlso-LotAwardOutcome_ND-FinancingParty a rr:TriplesMap
9797
rr:subjectMap
9898
[
9999
rdfs:label "ND-FinancingParty" ;
100-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/BudgetProvider/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
100+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/BudgetProvider/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
101101
rr:class epo:BudgetProvider
102102
] ;
103103
.
@@ -113,7 +113,7 @@ tedm:MG-BudgetProvider-announcesRole-ResultNotice_ND-FinancingParty a rr:Triples
113113
rr:subjectMap
114114
[
115115
rdfs:label "ND-FinancingParty" ;
116-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/BudgetProvider/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
116+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/BudgetProvider/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
117117
rr:class epo:BudgetProvider
118118
] ;
119119
.
@@ -131,7 +131,7 @@ tedm:MG-Organization-playedBy-BudgetProvider_ND-FinancingParty a rr:TriplesMap ;
131131
[
132132
rdfs:label "ND-FinancingParty" ;
133133
rdfs:comment "Financing Party (ID reference)";
134-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Organization/{cac:PartyIdentification/cbc:ID}" ;
134+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Organization/{cac:PartyIdentification/cbc:ID}" ;
135135
rr:class org:Organization
136136
] ;
137137
.

src/mappings-can/Business-can.rml.ttl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ tedm:MG-Business_ND-OrganizationUboReference a rr:TriplesMap ;
3636
rr:subjectMap
3737
[
3838
rdfs:label "ND-OrganizationUboReference" ;
39-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Organization/{../efac:Company/cac:PartyIdentification/cbc:ID}" ;
39+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Organization/{../efac:Company/cac:PartyIdentification/cbc:ID}" ;
4040
rr:class epo:Business
4141
] ;
4242
rr:predicateObjectMap
@@ -70,7 +70,7 @@ tedm:MG-Person-hasBeneficialOwner-Business_ND-OrganizationUboReference a rr:Trip
7070
rdfs:label "ND-OrganizationUboReference" ;
7171
rdfs:label "OPT-302-Organization" ;
7272
rdfs:comment "Beneficial Owner Reference of MG-Person under ND-OrganizationUboReference" ;
73-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Person/{cbc:ID}" ;
73+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Person/{cbc:ID}" ;
7474
rr:class person:Person
7575
] ;
7676
.
@@ -86,7 +86,7 @@ tedm:MG-Business_ND-Organization a rr:TriplesMap ;
8686
rr:subjectMap
8787
[
8888
rdfs:label "ND-Organization" ;
89-
rml:reference "if(exists(efbc:ListedOnRegulatedMarketIndicator)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/Organization/' || efac:Company/cac:PartyIdentification/cbc:ID else null";
89+
rml:reference "if(exists(efbc:ListedOnRegulatedMarketIndicator)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/Organization/' || efac:Company/cac:PartyIdentification/cbc:ID else null";
9090
rr:class epo:Business
9191
] ;
9292
rr:predicateObjectMap
@@ -113,7 +113,7 @@ tedm:MG-Identifier-identifier-Person_ND-UBO a rr:TriplesMap ;
113113
rr:subjectMap
114114
[
115115
rdfs:label "ND-UBO" ;
116-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/BeneficialOwnerTechnicalIdentifier${replace(translate(path(), concat(codepoints-to-string(123), codepoints-to-string(125), '/[]'), ' _'), 'Q .*? ', '')}" ;
116+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/BeneficialOwnerTechnicalIdentifier${replace(translate(path(), concat(codepoints-to-string(123), codepoints-to-string(125), '/[]'), ' _'), 'Q .*? ', '')}" ;
117117
rr:class adms:Identifier
118118
] ;
119119
rr:predicateObjectMap
@@ -149,7 +149,7 @@ tedm:MG-Person_ND-UBO a rr:TriplesMap ;
149149
rr:subjectMap
150150
[
151151
rdfs:label "ND-UBO" ;
152-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Person/{cbc:ID}" ;
152+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Person/{cbc:ID}" ;
153153
rr:class person:Person
154154
] ;
155155
rr:predicateObjectMap
@@ -213,7 +213,7 @@ tedm:MG-Address-registeredAddress-Person_ND-UBOAddress a rr:TriplesMap ;
213213
rr:subjectMap
214214
[
215215
rdfs:label "ND-UBOAddress" ;
216-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/UBOAddress${replace(translate(path(), concat(codepoints-to-string(123), codepoints-to-string(125), '/[]'), ' _'), 'Q .*? ', '')}" ;
216+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/UBOAddress${replace(translate(path(), concat(codepoints-to-string(123), codepoints-to-string(125), '/[]'), ' _'), 'Q .*? ', '')}" ;
217217
rr:class locn:Address
218218
] ;
219219
rr:predicateObjectMap
@@ -286,7 +286,7 @@ tedm:MG-Person_ND-UBONationality a rr:TriplesMap ;
286286
rr:subjectMap
287287
[
288288
rdfs:label "ND-UBONationality" ;
289-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Person/{../cbc:ID}" ;
289+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Person/{../cbc:ID}" ;
290290
rr:class person:Person
291291
] ;
292292
rr:predicateObjectMap

src/mappings-can/Contract-can.rml.ttl

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ tedm:MG-Identifier-identifier-Contract_ND-SettledContract a rr:TriplesMap ;
3535
rr:subjectMap
3636
[
3737
rdfs:label "ND-SettledContract" ;
38-
rml:reference "if (exists(efac:ContractReference/cbc:ID)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/SettledContractIdentifier$' || replace(replace(replace(path(.), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
38+
rml:reference "if (exists(efac:ContractReference/cbc:ID)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/SettledContractIdentifier$' || replace(replace(replace(path(.), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
3939
rr:class adms:Identifier
4040
] ;
4141
rr:predicateObjectMap
@@ -70,7 +70,7 @@ tedm:MG-Contract_ND-SettledContract a rr:TriplesMap ;
7070
rr:subjectMap
7171
[
7272
rdfs:label "ND-SettledContract" ;
73-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/SettledContract/{cbc:ID}" ;
73+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/SettledContract/{cbc:ID}" ;
7474
rr:class epo:Contract
7575
] ;
7676
rr:predicateObjectMap
@@ -217,7 +217,7 @@ tedm:MG-Fund_ND-SettledContract a rr:TriplesMap ;
217217
rr:subjectMap
218218
[
219219
rdfs:label "ND-SettledContract" ;
220-
rml:reference "if (exists(efac:Funding)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(.), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
220+
rml:reference "if (exists(efac:Funding)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(.), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
221221
rr:class epo:Fund
222222
] ;
223223
.
@@ -232,7 +232,7 @@ tedm:MG-Fund-isFundedBy-Contract_ND-SettledContract a rr:TriplesMap ;
232232
rr:subjectMap
233233
[
234234
rdfs:label "ND-SettledContract" ;
235-
rml:reference "if (exists(efac:Funding)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(.), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
235+
rml:reference "if (exists(efac:Funding)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(.), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
236236
rr:class epo:Fund
237237
] ;
238238
rr:predicateObjectMap
@@ -263,7 +263,7 @@ tedm:MG-Identifier-identifier-Fund-isFundedBy-Contract_ND-ContractEUFunds a rr:T
263263
rr:subjectMap
264264
[
265265
rdfs:label "ND-ContractEUFunds" ;
266-
rml:reference "if (exists(efbc:FinancingIdentifier)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/ContractFundIdentifier$' || replace(replace(replace(path(..), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
266+
rml:reference "if (exists(efbc:FinancingIdentifier)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/ContractFundIdentifier$' || replace(replace(replace(path(..), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
267267
rr:class adms:Identifier
268268
] ;
269269
rr:predicateObjectMap
@@ -298,7 +298,7 @@ tedm:MG-Fund-isFundedBy-Contract_ND-ContractEUFunds a rr:TriplesMap ;
298298
rr:subjectMap
299299
[
300300
rdfs:label "ND-ContractEUFunds" ;
301-
rml:reference "if((exists(cbc:FundingProgramCode)) or (exists(cbc:Description))) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(..), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
301+
rml:reference "if((exists(cbc:FundingProgramCode)) or (exists(cbc:Description))) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(..), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_') else null" ;
302302
rr:class epo:Fund
303303
] ;
304304

@@ -355,7 +355,7 @@ tedm:MG-Organization-playedBy-Buyer-signedByBuyer-Contract_ND-ContractSignatory
355355
rr:subjectMap
356356
[
357357
rdfs:label "ND-ContractSignatory" ;
358-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Organization/{cac:PartyIdentification/cbc:ID}" ;
358+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Organization/{cac:PartyIdentification/cbc:ID}" ;
359359
rr:class org:Organization
360360
] ;
361361
.
@@ -372,7 +372,7 @@ tedm:MG-Buyer-signedByBuyer-Contract_ND-ContractSignatory a rr:TriplesMap ;
372372
rr:subjectMap
373373
[
374374
rdfs:label "ND-ContractSignatory" ;
375-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/Buyer/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
375+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/Buyer/{encode-for-uri(concat(cac:PartyIdentification/cbc:ID, cac:PartyIdentification/cbc:ID/@schemeName))}" ;
376376
rr:class epo:Buyer
377377
] ;
378378
rr:predicateObjectMap
@@ -404,7 +404,7 @@ tedm:MG-Contract_ND-LotResultContractReference a rr:TriplesMap ;
404404
rr:subjectMap
405405
[
406406
rdfs:label "ND-SettledContract" ;
407-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/SettledContract/{cbc:ID}" ;
407+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/SettledContract/{cbc:ID}" ;
408408
rr:class epo:Contract
409409
] ;
410410
rr:predicateObjectMap
@@ -436,7 +436,7 @@ tedm:MG:PurchaseContract_ND-SettledContract a rr:TriplesMap ;
436436
rr:subjectMap
437437
[
438438
rdfs:label "ND-SettledContract" ;
439-
rml:reference "if (exists(efbc:ContractFrameworkIndicator)) then 'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/SettledContract/' || cbc:ID else null" ;
439+
rml:reference "if (exists(efbc:ContractFrameworkIndicator)) then 'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/SettledContract/' || cbc:ID else null" ;
440440
rr:class epo:PurchaseContract
441441
] ;
442442
rr:predicateObjectMap
@@ -580,7 +580,7 @@ tedm:MG-Contract_ND-PayerParty a rr:TriplesMap ;
580580
rr:subjectMap
581581
[
582582
rdfs:label "ND-PayerParty" ;
583-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/SettledContract/{../../efac:SettledContract/cbc:ID}" ;
583+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/SettledContract/{../../efac:SettledContract/cbc:ID}" ;
584584
rr:class epo:Contract
585585
] ;
586586
rr:predicateObjectMap
@@ -609,7 +609,7 @@ tedm:MG-langString-description-Fund-isFundedBy-Contract_ND-ContractEUFunds a rr:
609609
rr:subjectMap [
610610
rr:class epo-not:Fund ;
611611
rdfs:label "ND-ContractEUFunds" ;
612-
rml:reference "'http://data.europa.eu/a4g/resource/' || replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-') || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(../..), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_')" ;
612+
rml:reference "'http://data.europa.eu/a4g/resource/' || /*/cbc:ID[@schemeName='notice-id'] || '-' || /*/cbc:VersionID || '/ContractFund$' || replace(replace(replace(path(../..), 'Q\\{[^}]+\\}', ''), '\\[([0-9]+)\\]', '$1'), '/', '_')" ;
613613
] ;
614614
rr:predicateObjectMap [
615615
tedm:minSDKVersion "1.9.1" ;
@@ -647,7 +647,7 @@ tedm:MG-langString-title-Contract_ND-SettledContract a rr:TriplesMap ;
647647
rr:subjectMap [
648648
rr:class epo-not:Contract ;
649649
rdfs:label "ND-SettledContract" ;
650-
rr:template "http://data.europa.eu/a4g/resource/{replace(replace(/*/cbc:ID[@schemeName='notice-id'], ' ', '-' ), '/' , '-')}-{/*/cbc:VersionID}/SettledContract/{../cbc:ID}" ;
650+
rr:template "http://data.europa.eu/a4g/resource/{/*/cbc:ID[@schemeName='notice-id']}-{/*/cbc:VersionID}/SettledContract/{../cbc:ID}" ;
651651
] ;
652652
rr:predicateObjectMap [
653653
rr:predicate dct:title ;

0 commit comments

Comments
 (0)