mirror of https://gitlab.com/bashrc2/epicyon
Skills metadata
parent
a0d10b7c14
commit
c1eda4399b
|
@ -578,9 +578,11 @@ def personUpgradeActor(baseDir: str, personJson: {},
|
||||||
if personJson.get('occupationName'):
|
if personJson.get('occupationName'):
|
||||||
occupationName = personJson['occupationName']
|
occupationName = personJson['occupationName']
|
||||||
del personJson['occupationName']
|
del personJson['occupationName']
|
||||||
|
updateActor = True
|
||||||
if personJson.get('occupation'):
|
if personJson.get('occupation'):
|
||||||
occupationName = personJson['occupation']
|
occupationName = personJson['occupation']
|
||||||
del personJson['occupation']
|
del personJson['occupation']
|
||||||
|
updateActor = True
|
||||||
|
|
||||||
# if the older skills format is being used then switch
|
# if the older skills format is being used then switch
|
||||||
# to the new one
|
# to the new one
|
||||||
|
|
|
@ -722,10 +722,12 @@ def htmlHeaderWithPersonMarkup(cssFilename: str, instanceTitle: str,
|
||||||
|
|
||||||
skillsMarkup = ''
|
skillsMarkup = ''
|
||||||
if actorJson.get('hasOccupation'):
|
if actorJson.get('hasOccupation'):
|
||||||
skillsList = actorJson['hasOccupation']['skills']
|
occupationStr = ''
|
||||||
if actorJson['hasOccupation'].get('name'):
|
if actorJson['hasOccupation'].get('name'):
|
||||||
occupationName = actorJson['hasOccupation']['name']
|
occupationName = actorJson['hasOccupation']['name']
|
||||||
occupationStr = ' "name": "' + occupationName + '",\n'
|
occupationStr += ' "name": "' + occupationName + '",\n'
|
||||||
|
skillsList = actorJson['hasOccupation']['skills']
|
||||||
|
if skillsList:
|
||||||
skillsMarkup = \
|
skillsMarkup = \
|
||||||
' "hasOccupation": {\n' + \
|
' "hasOccupation": {\n' + \
|
||||||
' "@type": "Occupation",\n' + \
|
' "@type": "Occupation",\n' + \
|
||||||
|
|
Loading…
Reference in New Issue