imeji-community / imeji

imeji source code can now be found on https://github.com/MPDL/imeji.
https://github.com/MPDL/imeji
13 stars 15 forks source link

API: no validation for date elements #1120

Closed ioverka closed 8 years ago

ioverka commented 8 years ago

It looks like submitted values for md elements of type "date" are not validated to the full extend, i.e.

{
    "value": {"date": "test"},
    "statementUri": "http://spot.mpdl.mpg.de/statement/LRXnDGUPUeiM83O0",
    "typeUri": "http://imeji.org/terms/metadata#date"
}

returns: "1422, Invalid value provided for metadata of type Date (test...)" - but

{
    "value": {"date": "20156"},
    "statementUri": "http://spot.mpdl.mpg.de/statement/LRXnDGUPUeiM83O0",
    "typeUri": "http://imeji.org/terms/metadata#date"
}

works fine, see https://spot.mpdl.mpg.de/collection/Xme8ziI7M1YEMel/item/5Vq5Vp2Qpon_2ph

natasab commented 8 years ago

Hm... could not get to any validation which is working now on my local instance.. Checkng..

natasab commented 8 years ago

Resolved via

https://github.com/MPDL-Innovations/spot/commit/78b53c955d021bacb6ebe8b69b6049e186ecc219

should be available on dev-faces for testing in couple of mins

natasab commented 8 years ago

Issue has been fixed longer time ago.. I will close it asap.