wipo-gbd-transformation 1.1.53__py3-none-any.whl → 1.1.55__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of wipo-gbd-transformation might be problematic. Click here for more details.

Files changed (37) hide show
  1. gbdtransformation/brands/catm/filters.py +2 -1
  2. gbdtransformation/brands/catm/template.yml +9 -5
  3. gbdtransformation/brands/chtm/filters.py +153 -181
  4. gbdtransformation/brands/chtm/schema +79 -91
  5. gbdtransformation/brands/chtm/template.yml +98 -107
  6. gbdtransformation/brands/natm/__init__.py +2 -3
  7. gbdtransformation/brands/natm/filters.py +8 -2
  8. gbdtransformation/brands/notm/__init__.py +5 -0
  9. gbdtransformation/brands/notm/filters.py +117 -0
  10. gbdtransformation/brands/notm/template.yml +165 -0
  11. gbdtransformation/brands/phtm/schema +79 -50
  12. gbdtransformation/brands/phtm/schema.classic +50 -0
  13. gbdtransformation/brands/phtm/template.classic.yml +102 -0
  14. gbdtransformation/brands/phtm/template.yml +1 -102
  15. gbdtransformation/brands/vctm/__init__.py +5 -0
  16. gbdtransformation/brands/vctm/filters.py +75 -0
  17. gbdtransformation/brands/vctm/schema +87 -0
  18. gbdtransformation/brands/vctm/template.yml +1 -0
  19. gbdtransformation/brands/vctm/tests/__init__.py +0 -0
  20. gbdtransformation/brands/xxxx/template.yml +1 -1
  21. gbdtransformation/designs/woid/filters.py +26 -1
  22. gbdtransformation/designs/woid/template.yml +166 -1
  23. gbdtransformation/designs/xxid/template.yml +118 -2
  24. gbdtransformation/execs-nico.py +709 -0
  25. gbdtransformation/execs.py +9 -4
  26. gbdtransformation/gbd-transform.exec.tgz +0 -0
  27. {wipo_gbd_transformation-1.1.53.dist-info → wipo_gbd_transformation-1.1.55.dist-info}/METADATA +5 -3
  28. {wipo_gbd_transformation-1.1.53.dist-info → wipo_gbd_transformation-1.1.55.dist-info}/RECORD +33 -24
  29. wipo_gbd_transformation-1.1.55.dist-info/SOURCES_Stefans-Mac-Studio.local_Sep-18-063455-2024_Conflict.txt +690 -0
  30. {wipo_gbd_transformation-1.1.53.dist-info → wipo_gbd_transformation-1.1.55.dist-info}/WHEEL +1 -1
  31. gbdtransformation/designs/bgid/__init__.py +0 -5
  32. gbdtransformation/designs/bgid/filters.py +0 -91
  33. gbdtransformation/designs/bgid/schema +0 -106
  34. gbdtransformation/designs/bgid/template.yml +0 -169
  35. {wipo_gbd_transformation-1.1.53.dist-info → wipo_gbd_transformation-1.1.55.dist-info}/LICENSE.md +0 -0
  36. {wipo_gbd_transformation-1.1.53.dist-info → wipo_gbd_transformation-1.1.55.dist-info}/entry_points.txt +0 -0
  37. {wipo_gbd_transformation-1.1.53.dist-info → wipo_gbd_transformation-1.1.55.dist-info}/top_level.txt +0 -0
@@ -1,50 +1,79 @@
1
- /RECORD
2
- __/AGENT
3
- ____/ADDR_STREET
4
- ____/AGENT_CODE
5
- ____/CITY_NAME
6
- ____/PERSON_NAME
7
- ____/PROVINCE_NAME
8
- __/APPL_SUBTYP
9
- __/APPL_TYP
10
- __/APPNO
11
- __/EXPIRATION_DATE
12
- __/FILE_NBR
13
- __/FILE_SEQ
14
- __/FILE_SER
15
- __/FILE_TYP
16
- __/FILING_DATE
17
- __/LAW_CODE
18
- __/LOGO
19
- ____/LOGO
20
- __/NICE_CLASS
21
- ____/NICE_CLASS_CODE
22
- ____/NICE_CLASS_DESCRIPTION
23
- __/OWNER
24
- ____/ADDR_STREET
25
- ____/CITY_NAME
26
- ____/NATIONALITY_COUNTRY_CODE
27
- ____/PERSON_NAME
28
- ____/PROVINCE_NAME
29
- ____/RESIDENCE_COUNTRY_CODE
30
- ____/STATE_CODE
31
- ____/STATE_NAME
32
- __/PRIORITIES
33
- ____/COUNTRY_CODE
34
- ____/PRIORITY_APPL_ID
35
- ____/PRIORITY_DATE
36
- __/PUBLICATION_DATE
37
- __/REGISTRATION_DATE
38
- __/REGISTRATION_NBR
39
- __/SIGN_TYPE
40
- __/STATUS_CATEGORY
41
- __/STATUS_DATE
42
- __/STATUS_NAME
43
- __/TITLE
44
- __/VIENNA
45
- ____/VIENNA_CLASS_CODE
46
- ____/VIENNA_ELEM_CODE
47
- ____/VIENNA_GROUP_CODE
48
- ____/VIENNA_NAME
49
- ____/VIENNA_TEXT
50
- __/sign_type
1
+ /Transaction
2
+ __/TradeMarkTransactionBody
3
+ ____/TransactionContentDetails
4
+ ______/TransactionCode
5
+ ______/TransactionData
6
+ ________/TradeMarkApplication
7
+ __________/TradeMarkDetails
8
+ ____________/TradeMark
9
+ ______________/ApplicantDetails
10
+ ________________/Applicant
11
+ __________________/ApplicantAddressBook
12
+ ____________________/FormattedNameAddress
13
+ ______________________/Address
14
+ ________________________/AddressCountryCode
15
+ ______________________/Name
16
+ ________________________/FreeFormatName
17
+ __________________________/FreeFormatNameDetails
18
+ ____________________________/FreeFormatNameLine
19
+ ____________________________/FreeFormatNameLine[@languageCode=en]
20
+ ______________/ApplicationDate
21
+ ______________/ApplicationLanguageCode
22
+ ______________/ApplicationNumber
23
+ ______________/ExpiryDate
24
+ ______________/GoodsServicesDetails
25
+ ________________/GoodsServices
26
+ __________________/ClassDescriptionDetails
27
+ ____________________/ClassDescription
28
+ ______________________/ClassNumber
29
+ ______________________/GoodsServicesDescription
30
+ ______________________/GoodsServicesDescription[@languageCode=en]
31
+ ______________/MarkCurrentStatusCode
32
+ ______________/MarkCurrentStatusDate
33
+ ______________/MarkDisclaimerDetails
34
+ ________________/MarkDisclaimer
35
+ ________________/MarkDisclaimer[@languageCode=en]
36
+ ______________/MarkEventDetails
37
+ ________________/MarkEvent
38
+ __________________/MarkEventCode
39
+ __________________/MarkEventDate
40
+ __________________/OfficeSpecificMarkEventName
41
+ ______________/MarkFeature
42
+ ______________/MarkImageDetails
43
+ ________________/MarkImage
44
+ __________________/MarkImageCategory
45
+ ____________________/CategoryCodeDetails
46
+ ______________________/CategoryCode
47
+ ____________________/CategoryKind
48
+ ____________________/CategoryVersion
49
+ __________________/MarkImageFileFormat
50
+ __________________/MarkImageFilename
51
+ ______________/PriorityDetails
52
+ ________________/Priority
53
+ __________________/PriorityCountryCode
54
+ __________________/PriorityDate
55
+ __________________/PriorityNumber
56
+ ______________/PublicationDetails
57
+ ________________/Publication
58
+ __________________/PublicationDate
59
+ __________________/PublicationIdentifier
60
+ __________________/PublicationSection
61
+ ______________/RegistrationDate
62
+ ______________/RegistrationNumber
63
+ ______________/RegistrationOfficeCode
64
+ ______________/RepresentativeDetails
65
+ ________________/Representative
66
+ __________________/RepresentativeAddressBook
67
+ ____________________/FormattedNameAddress
68
+ ______________________/Address
69
+ ________________________/AddressCountryCode
70
+ ______________________/Name
71
+ ________________________/FreeFormatName
72
+ __________________________/FreeFormatNameDetails
73
+ ____________________________/FreeFormatNameLine
74
+ ____________________________/FreeFormatNameLine[@languageCode=en]
75
+ ______________/WordMarkSpecification
76
+ ________________/MarkVerbalElementText
77
+ ________________/MarkVerbalElementText[@languageCode=en]
78
+ ______/TransactionIdentifier
79
+ ______/TransactionSubCode
@@ -0,0 +1,50 @@
1
+ /RECORD
2
+ __/AGENT
3
+ ____/ADDR_STREET
4
+ ____/AGENT_CODE
5
+ ____/CITY_NAME
6
+ ____/PERSON_NAME
7
+ ____/PROVINCE_NAME
8
+ __/APPL_SUBTYP
9
+ __/APPL_TYP
10
+ __/APPNO
11
+ __/EXPIRATION_DATE
12
+ __/FILE_NBR
13
+ __/FILE_SEQ
14
+ __/FILE_SER
15
+ __/FILE_TYP
16
+ __/FILING_DATE
17
+ __/LAW_CODE
18
+ __/LOGO
19
+ ____/LOGO
20
+ __/NICE_CLASS
21
+ ____/NICE_CLASS_CODE
22
+ ____/NICE_CLASS_DESCRIPTION
23
+ __/OWNER
24
+ ____/ADDR_STREET
25
+ ____/CITY_NAME
26
+ ____/NATIONALITY_COUNTRY_CODE
27
+ ____/PERSON_NAME
28
+ ____/PROVINCE_NAME
29
+ ____/RESIDENCE_COUNTRY_CODE
30
+ ____/STATE_CODE
31
+ ____/STATE_NAME
32
+ __/PRIORITIES
33
+ ____/COUNTRY_CODE
34
+ ____/PRIORITY_APPL_ID
35
+ ____/PRIORITY_DATE
36
+ __/PUBLICATION_DATE
37
+ __/REGISTRATION_DATE
38
+ __/REGISTRATION_NBR
39
+ __/SIGN_TYPE
40
+ __/STATUS_CATEGORY
41
+ __/STATUS_DATE
42
+ __/STATUS_NAME
43
+ __/TITLE
44
+ __/VIENNA
45
+ ____/VIENNA_CLASS_CODE
46
+ ____/VIENNA_ELEM_CODE
47
+ ____/VIENNA_GROUP_CODE
48
+ ____/VIENNA_NAME
49
+ ____/VIENNA_TEXT
50
+ __/sign_type
@@ -0,0 +1,102 @@
1
+ {% from 'navigation.tmpl' import match %}
2
+ {% set status = RECORD | translate_status %}
3
+
4
+ type: TRADEMARK
5
+ kind:
6
+ - Individual
7
+
8
+ st13: {{ RECORD.APPNO | st13('PH') }}
9
+
10
+ markFeature: {{ RECORD.SIGN_TYPE | translate_feature}}
11
+ registrationOfficeCode: PH
12
+ designatedCountries:
13
+ - PH
14
+
15
+ applicationNumber: {{ RECORD.APPNO }}
16
+ applicationDate: {{ RECORD.FILING_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
17
+ registrationNumber: {{ RECORD.REGISTRATION_NBR }}
18
+ registrationDate: {{ RECORD.REGISTRATION_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
19
+
20
+ reference:
21
+ {% if RECORD.APPL_TYP == 'M' %}
22
+ office: WO
23
+ registration:
24
+ - number: {{ RECORD.FILE_NBR }}
25
+ {% endif %}
26
+
27
+ applicationLanguageCode: en
28
+ expiryDate: {{ RECORD.EXPIRATION_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
29
+ {% if status == 'Ended' %}
30
+ terminationDate: {{ RECORD.EXPIRATION_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
31
+ {% endif %}
32
+
33
+ officeStatus: {{ RECORD.STATUS_NAME }}
34
+ gbdStatus: {{ status }}
35
+ statusDate: {{ RECORD.STATUS_DATE | convertdate2('%m/%d/%Y;%b\t%d\t%Y')}}
36
+
37
+ {% if RECORD.TITLE %}
38
+ wordMarkSpecification:
39
+ markVerbalElement:
40
+ - languageCode: en
41
+ text: {{ RECORD.TITLE}}
42
+ {% endif %}
43
+
44
+ {% if RECORD.SIGN_TYPE == 'B' or RECORD.SIGN_TYPE == 'L' %}
45
+ markImageDetails:
46
+ - name: {{ RECORD.LOGO.LOGO }}
47
+ {% if RECORD.VIENNA %}
48
+ classification:
49
+ kind: Vienna
50
+ code:
51
+ {% call(vienna) match('VIENNA', RECORD) %}
52
+ - {{ vienna.VIENNA_TEXT | pad_vienna }}
53
+ {% endcall %}
54
+ {% endif %}
55
+ {% endif %}
56
+
57
+ {% if RECORD.NICE_CLASS %}
58
+ goodsServicesClassification:
59
+ kind: Nice
60
+ version: {{ ASK_THE_OFFICE }}
61
+ class:
62
+ {% call(nice) match('NICE_CLASS', RECORD) %}
63
+ - code: {{ nice.NICE_CLASS_CODE | int }}
64
+ terms:
65
+ en:
66
+ {% for gsline in nice.NICE_CLASS_DESCRIPTION | split_terms %}
67
+ - {{ gsline | remove_trailing('.') | lower }}
68
+ {% endfor %}
69
+ {% endcall %}
70
+ {% endif %}
71
+
72
+ priorities:
73
+ {% call(priority) match('PRIORITIES', RECORD) %}
74
+ - countryCode: {{ priority.COUNTRY_CODE }}
75
+ number: {{ priority.PRIORITY_APPL_ID | remove_trailing('-') }}
76
+ date: {{ priority.PRIORITY_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
77
+ {% endcall %}
78
+
79
+ applicants:
80
+ {% call(applicant) match('OWNER', RECORD) %}
81
+ - fullName:
82
+ - text: {{ applicant.PERSON_NAME }}
83
+ languageCode: en
84
+ countryCode: {{ applicant.RESIDENCE_COUNTRY_CODE | remove_trailing('-', '.') }}
85
+ fullAddress:
86
+ - text: {{ applicant | get_address }}
87
+ languageCode: en
88
+ {% endcall %}
89
+
90
+ representatives:
91
+ {% call(rep) match('AGENT', RECORD) %}
92
+ {% if rep.PERSON_NAME %}
93
+ - identifier: {{ rep.AGENT_CODE }}
94
+ fullName:
95
+ - text: {{ rep.PERSON_NAME }}
96
+ languageCode: en
97
+ countryCode: PH
98
+ fullAddress:
99
+ - text: {{ rep | get_address }}
100
+ languageCode: en
101
+ {% endif %}
102
+ {% endcall %}
@@ -1,102 +1 @@
1
- {% from 'navigation.tmpl' import match %}
2
- {% set status = RECORD | translate_status %}
3
-
4
- type: TRADEMARK
5
- kind:
6
- - Individual
7
-
8
- st13: {{ RECORD.APPNO | st13('PH') }}
9
-
10
- markFeature: {{ RECORD.SIGN_TYPE | translate_feature}}
11
- registrationOfficeCode: PH
12
- designatedCountries:
13
- - PH
14
-
15
- applicationNumber: {{ RECORD.APPNO }}
16
- applicationDate: {{ RECORD.FILING_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
17
- registrationNumber: {{ RECORD.REGISTRATION_NBR }}
18
- registrationDate: {{ RECORD.REGISTRATION_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
19
-
20
- reference:
21
- {% if RECORD.APPL_TYP == 'M' %}
22
- office: WO
23
- registration:
24
- - number: {{ RECORD.FILE_NBR }}
25
- {% endif %}
26
-
27
- applicationLanguageCode: en
28
- expiryDate: {{ RECORD.EXPIRATION_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
29
- {% if status == 'Ended' %}
30
- terminationDate: {{ RECORD.EXPIRATION_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
31
- {% endif %}
32
-
33
- officeStatus: {{ RECORD.STATUS_NAME }}
34
- gbdStatus: {{ status }}
35
- statusDate: {{ RECORD.STATUS_DATE | convertdate2('%m/%d/%Y;%b\t%d\t%Y')}}
36
-
37
- {% if RECORD.TITLE %}
38
- wordMarkSpecification:
39
- markVerbalElement:
40
- - languageCode: en
41
- text: {{ RECORD.TITLE}}
42
- {% endif %}
43
-
44
- {% if RECORD.SIGN_TYPE == 'B' or RECORD.SIGN_TYPE == 'L' %}
45
- markImageDetails:
46
- - name: {{ RECORD.LOGO.LOGO }}
47
- {% if RECORD.VIENNA %}
48
- classification:
49
- kind: Vienna
50
- code:
51
- {% call(vienna) match('VIENNA', RECORD) %}
52
- - {{ vienna.VIENNA_TEXT | pad_vienna }}
53
- {% endcall %}
54
- {% endif %}
55
- {% endif %}
56
-
57
- {% if RECORD.NICE_CLASS %}
58
- goodsServicesClassification:
59
- kind: Nice
60
- version: {{ ASK_THE_OFFICE }}
61
- class:
62
- {% call(nice) match('NICE_CLASS', RECORD) %}
63
- - code: {{ nice.NICE_CLASS_CODE | int }}
64
- terms:
65
- en:
66
- {% for gsline in nice.NICE_CLASS_DESCRIPTION | split_terms %}
67
- - {{ gsline | remove_trailing('.') | lower }}
68
- {% endfor %}
69
- {% endcall %}
70
- {% endif %}
71
-
72
- priorities:
73
- {% call(priority) match('PRIORITIES', RECORD) %}
74
- - countryCode: {{ priority.COUNTRY_CODE }}
75
- number: {{ priority.PRIORITY_APPL_ID | remove_trailing('-') }}
76
- date: {{ priority.PRIORITY_DATE | convertdate('%Y-%m-%dT%H:%M:%S')}}
77
- {% endcall %}
78
-
79
- applicants:
80
- {% call(applicant) match('OWNER', RECORD) %}
81
- - fullName:
82
- - text: {{ applicant.PERSON_NAME }}
83
- languageCode: en
84
- countryCode: {{ applicant.RESIDENCE_COUNTRY_CODE | remove_trailing('-', '.') }}
85
- fullAddress:
86
- - text: {{ applicant | get_address }}
87
- languageCode: en
88
- {% endcall %}
89
-
90
- representatives:
91
- {% call(rep) match('AGENT', RECORD) %}
92
- {% if rep.PERSON_NAME %}
93
- - identifier: {{ rep.AGENT_CODE }}
94
- fullName:
95
- - text: {{ rep.PERSON_NAME }}
96
- languageCode: en
97
- countryCode: PH
98
- fullAddress:
99
- - text: {{ rep | get_address }}
100
- languageCode: en
101
- {% endif %}
102
- {% endcall %}
1
+ {% include "ipas/template.yml" %}
@@ -0,0 +1,5 @@
1
+ render = 'JSON'
2
+ source = 'national'
3
+
4
+ # VC/T/2015/109
5
+ appnum_mask = 'VC/T/\d{4}/(.*)'
@@ -0,0 +1,75 @@
1
+ import gbdtransformation.brands.ipas.filters as ipas
2
+ import gbdtransformation.common.filters as commons
3
+
4
+ ignore_namespace = [
5
+ 'http://www.wipo.int/standards/XMLSchema/trademarks',
6
+ 'http://www.wipo.int/standards/XMLSchema/wo-trademarks']
7
+
8
+ def get_appdate(appdate, appnum):
9
+ return appnum.split('/')[-2]
10
+
11
+ #return ipas.get_appdate(appdate, appnum)
12
+
13
+ def translate_type(header):
14
+ code = header.TransactionCode
15
+ if code == 'Trademark': return 'TRADEMARK'
16
+
17
+ raise Exception('Type "%s" is not mapped.' % code)
18
+
19
+ def translate_kind(trademark, header):
20
+ subcode = header.TransactionSubCode
21
+ if subcode == 'Trademarks': return ['Individual']
22
+ # it is None for all
23
+ # kind = trademark.KindMark
24
+
25
+ raise Exception('Kind "%s" not mapped.' % subcode)
26
+
27
+ def translate_status(trademark):
28
+ status = trademark.MarkCurrentStatusCode
29
+ """
30
+ if status == 'Converted': return 'Registered'
31
+ """
32
+ return ipas.translate_status(status)
33
+
34
+ def translate_feature(trademark):
35
+ feature = trademark.MarkFeature
36
+ if not feature: return 'Undefined'
37
+
38
+ return ipas.translate_feature(feature)
39
+
40
+ def translate_event(event):
41
+ if not event: return 'Unknown'
42
+
43
+ return ipas.translate_event(event)
44
+
45
+ # ---------------------------------------
46
+ # # language code is not accurate for markVerbalElement
47
+ # def guess_language(text, lang, default):
48
+ # if commons.is_latin(text):
49
+ # return 'en'
50
+ # else:
51
+ # return commons.guess_language(text, lang, default)
52
+
53
+ def verbal_lang_map(markVerbalElements, applang=None):
54
+ return ipas.verbal_lang_map(markVerbalElements, applang=applang)
55
+
56
+ def get_registration_nb(trademark, tmstatus):
57
+ if trademark.RegistrationNumber:
58
+ return trademark.RegistrationNumber
59
+
60
+ return None
61
+
62
+ def get_expiry_date(trademark, tmstatus):
63
+ return ipas.get_expiry_date(trademark, tmstatus)
64
+
65
+ def get_registration_date(trademark, tmstatus):
66
+ return ipas.get_registration_date(trademark, tmstatus)
67
+
68
+ def is_international(header):
69
+ return False
70
+
71
+ def get_ir_refnum(appnum):
72
+ return
73
+
74
+ def get_goods_services(goods_services):
75
+ return ipas.get_goods_services(goods_services)
@@ -0,0 +1,87 @@
1
+ /Transaction
2
+ __/TradeMarkTransactionBody
3
+ ____/TransactionContentDetails
4
+ ______/TransactionCode
5
+ ______/TransactionData
6
+ ________/TradeMarkApplication
7
+ __________/TradeMarkDetails
8
+ ____________/TradeMark
9
+ ______________/ApplicantDetails
10
+ ________________/Applicant
11
+ __________________/ApplicantAddressBook
12
+ ____________________/FormattedNameAddress
13
+ ______________________/Address
14
+ ________________________/AddressCountryCode
15
+ ________________________/FreeFormatAddress
16
+ __________________________/FreeFormatAddressLine
17
+ ______________________/Name
18
+ ________________________/FreeFormatName
19
+ __________________________/FreeFormatNameDetails
20
+ ____________________________/FreeFormatNameLine
21
+ ____________________________/FreeFormatNameLine[@languageCode=en]
22
+ ______________/ApplicationDate
23
+ ______________/ApplicationLanguageCode
24
+ ______________/ApplicationNumber
25
+ ______________/ExpiryDate
26
+ ______________/GoodsServicesDetails
27
+ ________________/GoodsServices
28
+ __________________/ClassDescriptionDetails
29
+ ____________________/ClassDescription
30
+ ______________________/ClassNumber
31
+ ______________________/GoodsServicesDescription
32
+ ______________________/GoodsServicesDescription[@languageCode=en]
33
+ ______________/KindMark
34
+ ______________/MarkCurrentStatusCode
35
+ ______________/MarkCurrentStatusDate
36
+ ______________/MarkDisclaimerDetails
37
+ ________________/MarkDisclaimer
38
+ ________________/MarkDisclaimer[@languageCode=en]
39
+ ______________/MarkEventDetails
40
+ ________________/MarkEvent
41
+ __________________/MarkEventCode
42
+ __________________/MarkEventDate
43
+ __________________/OfficeSpecificMarkEventCode
44
+ __________________/OfficeSpecificMarkEventDescription
45
+ __________________/OfficeSpecificMarkEventDescription[@languageCode=en]
46
+ ______________/MarkFeature
47
+ ______________/MarkImageDetails
48
+ ________________/MarkImage
49
+ __________________/MarkImageCategory
50
+ ____________________/CategoryCodeDetails
51
+ ______________________/CategoryCode
52
+ ____________________/CategoryKind
53
+ ____________________/CategoryVersion
54
+ __________________/MarkImageColourClaimedText
55
+ __________________/MarkImageColourClaimedText[@languageCode=en]
56
+ __________________/MarkImageFileFormat
57
+ __________________/MarkImageFilename
58
+ ______________/PriorityDetails
59
+ ________________/Priority
60
+ __________________/PriorityCountryCode
61
+ __________________/PriorityDate
62
+ __________________/PriorityNumber
63
+ ______________/PublicationDetails
64
+ ________________/Publication
65
+ __________________/PublicationDate
66
+ __________________/PublicationIdentifier
67
+ ______________/RegistrationDate
68
+ ______________/RegistrationNumber
69
+ ______________/RegistrationOfficeCode
70
+ ______________/RepresentativeDetails
71
+ ________________/Representative
72
+ __________________/RepresentativeAddressBook
73
+ ____________________/FormattedNameAddress
74
+ ______________________/Address
75
+ ________________________/AddressCountryCode
76
+ ________________________/FreeFormatAddress
77
+ __________________________/FreeFormatAddressLine
78
+ ______________________/Name
79
+ ________________________/FreeFormatName
80
+ __________________________/FreeFormatNameDetails
81
+ ____________________________/FreeFormatNameLine
82
+ ____________________________/FreeFormatNameLine[@languageCode=en]
83
+ ______________/WordMarkSpecification
84
+ ________________/MarkVerbalElementText
85
+ ________________/MarkVerbalElementText[@languageCode=en]
86
+ ______/TransactionIdentifier
87
+ ______/TransactionSubCode
@@ -0,0 +1 @@
1
+ {% include "ipas/template.yml" %}
File without changes
@@ -36,7 +36,7 @@ filingPlace:
36
36
  # some collections indicate that the application
37
37
  # originates from international filing and provide IR number
38
38
  # (question to ask in GBD participation questionnaire)
39
- referece:
39
+ reference:
40
40
  application:
41
41
  - number:
42
42
  date:
@@ -3,6 +3,7 @@ from gbdtransformation.designs import kinds as std_kinds
3
3
  from gbdtransformation.designs import status as std_status
4
4
  from gbdtransformation.designs.filters import st13
5
5
  from datetime import datetime, date
6
+ import json
6
7
 
7
8
  # namespaces defined in XML and to be ignored in procecssing
8
9
  ignore_namespace = [ "http://www.wipo.int/standards/XMLSchema/ST96/Design",
@@ -145,7 +146,7 @@ def format_address(address_lines):
145
146
  if not isinstance(address_lines, list):
146
147
  address_lines = [address_lines]
147
148
  for address_line in address_lines:
148
- if "__value" in address_line:
149
+ if address_line is not None and "__value" in address_line:
149
150
  address += address_line.__value + ' \n'
150
151
  if len(address) > 0:
151
152
  return address.strip()
@@ -153,6 +154,8 @@ def format_address(address_lines):
153
154
  return None
154
155
 
155
156
  def format_complete_address(PostalStructuredAddress):
157
+ if PostalStructuredAddress == None:
158
+ return None
156
159
  adr_lines = format_address(PostalStructuredAddress.AddressLineText)
157
160
  address = []
158
161
  if adr_lines:
@@ -344,4 +347,26 @@ def isApplicableToCountry(countryCode, hagueHistoryEvent):
344
347
  return True
345
348
  return False
346
349
 
350
+ """
351
+ Functions dedicated to Hague transaction history
352
+ """
353
+
354
+ transaction_header_elements = [ "HagueBulletinNumber", "PublicationDate" ]
355
+
356
+ def get_event_type(history):
357
+ for child in history:
358
+ if child.startswith("_"):
359
+ continue
360
+ if child not in transaction_header_elements:
361
+ return child
362
+ return None
363
+
364
+ def serialize(history):
365
+ #print(history)
366
+ jsonString = history.toJSON()
367
+ # keeping single quote in the JSON (even escaped) will fail when going back to yaml (yaml parsing error)
368
+ # so we need to use an alternative unicode for single quote.
369
+ jsonString = jsonString.replace("\'", "\u201A")
370
+ return json.loads(jsonString)
371
+
347
372