Defaults array#34
Conversation
|
I merged the validate stuff into this branch. |
|
These changes do pattern matching against valueConstrant.validatePattern property created in the profile editor. This uses simple HTML5 pattern validation (which is a regexp). If there is valueConstrant.validatePattern present for the property it will add a "pattern" attribute to the input box. Invalid entries will have red text until it matches. Also, if the input is invalid, it will raise an alert box saying so when clicking the "+" button, and the value will not be added to the store. |
kirkhess
left a comment
There was a problem hiding this comment.
The defaults were not working correctly, I think I fixed it in the latest commit. Basically, if you have a literal value there's should be no default uri.
The validation appears to work.
|
I think 6956208 fixed everything. |
This is the twin to the changes in the profile editor that will work with the new data model-- the new data model being defaults (defaultURI and defaultLiteral) are no longer singletons. These two properties are combined into an object and pushed to the "defaults" array. We now can have multiple default values.
The changes basically will create a defaults array from singletons (if available) and continue on with filling in the form using the array. This way the update will work with both data models and all of the profiles will not need to be changed in advance.
As I pointed out earlier in an email, the lines that save the default triples to bfestore have been previously commented out. I didn't uncomment the commented out lines, figuring this was done for a reason. Therefore, the defaults never get stored or saved. It will be easy enough to get this to work again in the future.