Hey Charlie, hey Célia,
I am trying to use
xnat:abstractProjectAsset as suggested by Charlie.
I managed to create, build and install my plugin (
explugin) from this source code :
https://github.com/vferat/xnat-plugin-demo ( the plugin file can be downloaded form the artefact of the build_plugin workflow).
The first issue I find is that the default
xnat:abstractProjectAsset contains elements specific to an experiment such as data, time, duration... (see attached file "xnat_edit.PNG"). Do you know another data type is a bit more generic ? I know that I can simply remove these elements form the edit screens so they are always empty.
The second issue is that I would like to have one and only one
exprojectMetadata per project. Is there a way to specify this constraint in the schema definition, or should I handle this in the velocity/turbine scripts ?
For now, I need to define the experiment ID manually using the edit screen, but keep having an error while submitting the form ( see attached file "xnat_edit_error"). In the mean time, the report page doesn't work at all (see xnat_report_error) It seems that most of these issues could be solved by modifying the turbine files. However, I found very little literature on how to edit the turbine files. The xnat generated class
XDATScreen_edit_ex_projectMetadata inherits from
EditScreenA, but I am not sure how it works. Do you have any useful resources to share on this ? The datasets-plugin doesn't provide much help in this case, as everything seems to be done through the Rest API.
Best,
Victor