Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Creation of datasets/harvest sources with no organization specified #3046
CKAN Version if known (or site URL)
Please describe the expected behaviour
Alternative 1: When adding a new dataset/harvest source and no organization has been created so far, the user should be promoted with a note that this has to be done first. Maybe the form could be grayed out.
Alternative 2: When adding a new dataset/harvest source and no organization has been created so far, the form should still include the organization-field. When the user puts focus on it, a dialogue opens assisting the user in creating a new organization.
Please describe the actual behaviour
When adding a new dataset/harvest source and no organization has been created so far, the form field for organization is not displayed. The form can be filled out. After saving an error message reads
This is confusing since no such field is provided.
What steps can be taken to reproduce the issue?
Same changes applied to the
@TkTech I agree that it would be nice to redirect the user after they created the organization but I guess that it would not be worth the extra logic that we would need to introduce for this. This is a scenario that should not really happen too often so maybe we can just let the users navigate back by themselves.
The output page looks fine, I'd probably make it look a bit more warning-y.
But the checks need to cover more cases.
You are using
Then the problem that might happen is that datasets have to belong to an org, you are not an admin/editor member of any org (which is what you are checking with
@amercader I already thought that there would be some more cases to take care of ;)
I just pushed another change that should take care of this.
I also realized that my previous changes would always display the warning message and never the form because it is not possible in jinja to create a