Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

single attribute value dropdown displaying one letter /row #283

Open
ilovan opened this issue Sep 23, 2020 · 1 comment
Open

single attribute value dropdown displaying one letter /row #283

ilovan opened this issue Sep 23, 2020 · 1 comment
Assignees
Labels

Comments

@ilovan
Copy link
Contributor

ilovan commented Sep 23, 2020

https://cwrc.ca/islandora/object/ceww%3Ae9fa47db-3dea-41b1-bc73-9ec22366f7a8

edit "measure" tag
click on "type" dropdown

result: image.png

value once selected (let's say first) retains only that single letter (e.g. type="c")

@lucaju
Copy link
Contributor

lucaju commented Oct 5, 2020

This seems to be an edge case, but we need to double-check if there are more instances like this.
Reed schema defines the tag measure and its attributes as follows (image attached):
Screen Shot 2020-10-05 at 6 35 53 PM

Note that all the attributes are references to other definitions, except for type, which is define withing the measure tag scope. Type is optional. It has choices, but one choice is listed.

Maybe because it has just one choice (one instance of choice with just one possible value), the parser interprets the choices as a value. Other attributes have multiple choices, which is parsed as an array.

I added a short piece of code to correct this. If the attribute has choices, it should parse as an array instead of a string.
d69e8a9

lucaju added a commit that referenced this issue Oct 6, 2020
Single attribute choice attribute is parsed as a string. Certifiy that it becomes an array to be
displayed on as a dropdown option.

#283
lucaju pushed a commit that referenced this issue Dec 4, 2020
# [7.0.0](v6.0.0...v7.0.0) (2020-12-04)

### Bug Fixes

* **annotation:** fix issues with annotations been overwritten when saved ([9e3c0cf](9e3c0cf)), closes [#282](#282)
* **annotation:** get app version from package.json and app id from the current CWRC-Writer instance ([cc52a20](cc52a20))
* **annotation:** improve test to add contributors ([e9841d4](e9841d4))
* **nerve:** use data from the form elements to update the entity ([01a0c37](01a0c37))
* **nssi[nerve]:** skip teiheader when sending document to nssi[nerve] ([f797df5](f797df5)), closes [#285](#285)
* **schematags:** filter tags using uppercase input ([7b8ce13](7b8ce13)), closes [#286](#286)
* assure single attribute dropdown is an array instead of a string ([d69e8a9](d69e8a9)), closes [#283](#283)

### Code Refactoring

* **gitdialog:** provide writer instance to logout component ([9bc1ae6](9bc1ae6))

### Features

* 🎸 config commitzen. Bump up version due to CI changes ([d7119e5](d7119e5))
* 🎸 travis-ci tweak ([7e0f4ad](7e0f4ad))
* 🎸 travis-ci tweaks ([448f75f](448f75f))

### BREAKING CHANGES

* **gitdialog:** provide writer instance to logout component
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants