majlis-erc / manuForma

The manuForma application is designed to make TEI data creation and distributed editing faster and easier.
6 stars 1 forks source link

Error message #611

Closed mMoliere closed 2 months ago

mMoliere commented 3 months ago

@wsalesky In Works appears an error message whenever an author is added using the lookup-feature:

Screenshot 2024-05-21 at 11-36-36 Edit Works TEI records

wsalesky commented 3 months ago

@mMoliere Part of the problem is that the form expects the following:

<author>
              <forename/>
              <surname/>
</author>

In other parts of the app, the author lookup requires <author ref="https://jalit.org/person/18">Abraham al-Harzilānī</author>

I can make a special call for authors with forename and surname, but it would be cleaner code to just change the expectation for the author element in the work record to accept a text node and have no children. This would happen in the schema.

What do you think?

mMoliere commented 2 months ago

@wsalesky I agree that a clean solution is preferable. But the schema for works already specifies that the content of <author> can only be a <textNode>.

https://github.com/majlis-erc/manuForma/blob/bc19b7519b5d7037ba28b89062a098b1551b5960/forms/schemas/work-schema.xml#L294-L305

wsalesky commented 2 months ago

@mMoliere Sorry, I must not have updated my version of the schema. Please merge this: https://github.com/majlis-erc/manuForma/pull/627

And let me know if the issue is resolved.

mMoliere commented 2 months ago

@wsalesky I'm afraid the error is still there.

wsalesky commented 2 months ago

Try this please: https://github.com/majlis-erc/manuForma/pull/630

mMoliere commented 2 months ago

The error is still there

wsalesky commented 2 months ago

@mMoliere did you regenerate the Work form? It looks like the version on the server is the old one.

mMoliere commented 2 months ago

@wsalesky You're right, I forgot to refresh the works forms. I was distracted from the other bug. Thank you, it works!