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

[ODP-235] Allow private and hidden teams #537

Draft
wants to merge 20 commits into
base: dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ckan-backend-dev/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ DATAPUSHER_REWRITE_RESOURCES=True
DATAPUSHER_REWRITE_URL=http://ckan-dev:5000

# Extensions
CKAN__PLUGINS=image_view text_view webpage_view resource_proxy datatables_view datastore datapusher activity s3filestore scheming_datasets scheming_organizations scheming_groups wri auth hierarchy_display hierarchy_form hierarchy_group_form issues envvars
CKAN__PLUGINS=image_view text_view webpage_view resource_proxy datatables_view datastore datapusher activity s3filestore scheming_datasets scheming_organizations scheming_groups wri auth hierarchy_display issues envvars
CKAN__VIEWS__DEFAULT_VIEWS=image_view text_view webpage_view datatables_view
CKAN__HARVEST__MQ__TYPE=redis
CKAN__HARVEST__MQ__HOSTNAME=redis
Expand All @@ -101,7 +101,7 @@ CKANEXT__S3FILESTORE__HOST_NAME=http://minio:9000

# scheming
CKAN___SCHEMING__DATASET_SCHEMAS=ckanext.wri.schema:ckan_dataset.yaml
CKAN___SCHEMING__ORGANIZATION_SCHEMAS=ckanext.scheming:custom_org_with_address.json
CKAN___SCHEMING__ORGANIZATION_SCHEMAS=ckanext.wri.schema:custom_org_with_address.json
CKAN___SCHEMING__GROUP_SCHEMAS=ckanext.scheming:custom_group_with_status.json
CKAN___SCHEMING__PRESETS=ckanext.wri.schema:presets.json

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
send_group_notification,
)
import ckan.logic as logic
from ckanext.wri.logic.action.get import validate_visibility

from ckan.common import _, config
import ckan.plugins.toolkit as tk
Expand Down Expand Up @@ -404,6 +405,8 @@ def migration_status(context: Context, data_dict: DataDict):


def package_create(context: Context, data_dict: DataDict):

validate_visibility(context, data_dict)
data_dict["is_pending"] = True
data_dict["is_approved"] = False
data_dict["approval_status"] = "pending"
Expand Down
Loading
Loading