Skip to content

Commit d3f57c8

Browse files
luccasmmgmpolidoristeveoni
authored
Sync dev staging may 12 (#685)
* Harvest dynamic configs pt. 2 (#635) * Update ckanext-s3filestore branch * Fix typo * Update layer manager to use wri release * Fix Dockerfile * [ODP-235] Allow private and hidden teams (#537) * update teams create and edit form * update organization list api * update schema * update api * remove extras * fix type errors * update user_list_wri to support private teams * fix api call * remove chained action * add visibility * fix breaking changes * update env * update env plugin * fix test * update test * add visibility to org during dataset edit * add test for private teams * remove logs * update private team functionality * Merge branch 'priveateams' of https://github.com/wri/wri-odp into priveateams * Merge branch 'priveateams' of https://github.com/wri/wri-odp into priveateams * resolve conflict * undo changes * update organization patch and create * add private attribute to fetched orgs * update organization_list sql logic * improve team visbility * improve error message * update private team test * update failing test * update test * update settings * update test * update test * update test * update test * update test * update test * update test * update docker compose * add tooltip * update test * add padlock to private teams * add back auth plugin * Harvest config feb 03 2025 (#637) * Fix variable replacement in harvest worker configs and switch from /tmp path to /srv/app * Add whoami output to start_ckan.sh * [download_event.py] Add missing closing parenthesis * Set supervisor home by variable * Fix harvest config permissions * Use CKAN_IMAGE variable instead of local image name * Handle sed supervisor changes as root; Add start_ckan sub-script * Revert sub-script; Always use user ckan for supervisor * Fix sed commands * Use root user with ckan home for supervisord * Revert "Harvest config feb 03 2025 (#637)" This reverts commit e68155a. * Harvest dynamic configs pt. 3 (#638) * Add supercronic for harvest run command (#640) * Fix alignment * Fix build * Fix build * [ODP-414] add email notification when download-flow fails (#641) * add email notification when flow fails * update error notification * empty * remove pgclient version * update libpq --------- Co-authored-by: Michael Polidori <[email protected]> * Upgrade to CKAN 2.11 (#632) * Update setup.py * Update Members permission to team form + ODP-370 (#642) * members can not * update role: Editor can create sub-team and admin moving subteam from public to private should not throw error * disabled Public option if parent is private * Trigger CI --------- Co-authored-by: Luccas Mateus <[email protected]> * Change setup.py and setup.cfg * Fix ckanext-wri install (#643) * Improve resource location design (#646) * Trigger CI * [odp-426]: Add edit icon to dashboard entities (#648) * [odp-426]: Add edit icon to dashboard entities * update schema * Add bulk purge collaborator issue patch (#645) * Increase UWSGI timeouts; Extract URLs from markdown links in learn_more (#649) * Resource location search improvements (#650) * add authorized check to group/teams last node (#651) * Trigger CI * Rm global from DatafileLocation * Trigger CI * enable edit icon for collaborators (#652) * Fix typo * intgration test for collaborator permission (#654) * enable edit icon for collaborators * add intergration test for dashboard collaborator permission * Improve speed * Improve js * Fix prefetching * Change color of area select tool * Improvements map * Remove edit icon on teams/topic page for editor (#656) * enable edit icon for collaborators * remove editor permision * empty * Fix tests * Fix tests * Fix tests * Fix test * Clear all session storage * Fix tests * Fix tests * Fix private teams tests * Fix cypress.config.js * Fix tests * Fix tests * Fix tests * Fix tests * Fix whitespace wrap on text * Trigger CI * Add group admin email to workflow error mail (#663) * enable edit icon for collaborators * send workflow error to team admin * removed email check * E2etest (#657) * enable edit icon for collaborators * empty * add check to ensure org is actually private * update * update * fix test * update test * empty * update * update test * update test * update test * update test * update test * update test to see if organization create api is truly working * update test * remove other test for now * push update * update env.example * fix test * empty * Fix git vulnerability * Fix git * Add if condition (#664) * [odp-449] Teams Implementation - Root parent Team Edit (#669) * enable edit icon for collaborators * admin should be able to edit root team * ODP-447 (#668) * ODP-447 * Fix build * Fix tests * Fix t ests * Trigger CI * [Dev] Increase proxy-read-timeout to avoid early external request disconnects (#665) * Odp 448 (#670) * ODP-448 * Add extra tests * Fix session leakage * Fix tests * Forgot to commit * Fix tests * Add required indicator for non-sysadmins (#672) * Change data stored in orttho * Fix odp430 (#674) * enable edit icon for collaborators * fix odp-430 * Trigger CI * Add better warning * Add extras to list of defaultvalues (#676) * enable edit icon for collaborators * fix odp-430 * add extras to default value * Form-id * Trigger CI * [Odp 458] create/edit dataset in sub-team public (#678) * enable edit icon for collaborators * extend capacity so editor can create or edit dataset in subteam * editor should be able to see public subteam in organization_list_for_user api * parent team admin should be able to edit subteam public dataset * add missing visbility check: public dataset can not be assigned to private team * reshape logic * update patch * remove log * update test * empty * [ODP-453] Teams Implementation - Edit sub team (private or public) (#675) * Add integration tests * Bump ckanext-hierarchy commit: fix cascading roles * Fix tests * Fix tests * Fix tests * Fix tests * Limit setting private Teams to public only to sysadmins (#679) * Add docs for subpaths (#568) * Add docs for subpaths * Force rerun pipeline * Allow Team Admins public to private permissions (#680) * use sysadmin key to fetch dataset collaborators (#682) * enable edit icon for collaborators * use sysadmin key to fetch dataset collaborators * Hide by default when no viz available * fix: first publish * Fix test * Fix caution max-w * Set create_unowned_dataset to False; Remove dev testing GitHub Actions file * Remove duplicate form-id --------- Co-authored-by: Michael Polidori <[email protected]> Co-authored-by: Stephen Oni <[email protected]>
1 parent 0ad250e commit d3f57c8

File tree

45 files changed

+2154
-1159
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+2154
-1159
lines changed

ckan-backend-dev/.env.example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ CKAN_SMTP_PASSWORD=testpassword
5959
CKAN_SMTP_MAIL_FROM=ckan@localhost
6060
TZ=UTC
6161
CKAN_INI=/srv/app/production.ini
62-
CKAN__AUTH__CREATE_UNOWNED_DATASET=True
62+
CKAN__AUTH__CREATE_UNOWNED_DATASET=False
6363
CKAN__AUTH__ALLOW_DATASET_COLLABORATORS=True
6464
CKAN__AUTH__ALLOW_ADMIN_COLLABORATORS=True
6565
CKAN__AUTH__ALLOW_COLLABORATORS_TO_CHANGE_OWNER_ORG=True

ckan-backend-dev/ckan/Dockerfile.dev

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ RUN pip3 install -e 'git+https://github.com/ckan/ckanext-scheming.git@5ce30cf285
3434
pip3 install httpretty && \
3535
pip3 install -e 'git+https://github.com/datopian/ckanext-auth.git@okta#egg=ckanext-auth' && \
3636
pip3 install -r 'https://raw.githubusercontent.com/datopian/ckanext-auth/okta/requirements.txt' && \
37-
pip3 install -e 'git+https://github.com/datopian/ckanext-hierarchy.git@wri#egg=ckanext-hierarchy' && \
37+
pip3 install -e 'git+https://github.com/datopian/ckanext-hierarchy.git@5d069a5d032ba384f43d266fc397a0aa0a4b444c#egg=ckanext-hierarchy' && \
3838
pip3 install -e 'git+https://github.com/datopian/[email protected]#egg=ckanext-issues' && \
3939
# Required by ckanext-issues, but it's no longer included in any of the requirements files or the subdependencies
4040
pip3 install mock && \

ckan-backend-dev/ckan/patches/ckan/01_roles.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ diff --git a/ckan/ckan/authz.py b/ckan/ckan/authz.py
77
if _has_user_permission_for_groups(user_id, permission, [group_id]):
88
return True
99
- capacities = check_config_permission('roles_that_cascade_to_sub_groups')
10-
+ capacities = ['admin']
10+
+ capacities = ['admin', 'editor']
1111
assert isinstance(capacities, list)
1212
# Handle when permissions cascade. Check the user's roles on groups higher
1313
# in the group hierarchy for permission.

ckan-backend-dev/src/ckanext-wri/ckanext/wri/logic/action/get.py

Lines changed: 38 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1007,11 +1007,9 @@ def organization_list_wri(context: Context, data_dict: DataDict):
10071007
user_orgs = None
10081008
if not user:
10091009
private_orgs = get_private_organizations(context)
1010-
log.warning(f"Private orgs: {private_orgs} \n\n {orgs}")
10111010

10121011
if user:
10131012
user_orgs = orgs
1014-
log.warning(f"User orgs: {user_orgs} \n\n {orgs}")
10151013
results = get_hierarchy_group(context, orgs, "organization", q, private_orgs, user_orgs)
10161014
return results
10171015

@@ -1409,24 +1407,49 @@ def organization_list_for_user(context: Context,
14091407
.filter(model.Member.state == 'active') \
14101408
.join(model.Group)
14111409

1412-
group_ids: set[str] = set()
1410+
14131411
roles_that_cascade = cast(
14141412
"list[str]",
14151413
authz.check_config_permission('roles_that_cascade_to_sub_groups')
14161414
)
1415+
group_extra_alias = aliased(model.GroupExtra)
1416+
public_groups_query = (
1417+
model.Session.query(model.Group.id)
1418+
.outerjoin(group_extra_alias, model.Group.id == group_extra_alias.group_id)
1419+
.filter(
1420+
_or_(
1421+
_and_(
1422+
group_extra_alias.key == 'visibility',
1423+
group_extra_alias.value == 'public'
1424+
),
1425+
group_extra_alias.key == None
1426+
)
1427+
)
1428+
)
1429+
public_group_ids = {gid for gid, in public_groups_query.all()}
1430+
group_ids: set[str] = set()
14171431
group_ids_to_capacities: dict[str, str] = {}
14181432
for member, group in q.all():
1433+
group_ids.add(group.id)
1434+
group_ids_to_capacities[group.id] = member.capacity
1435+
children_group_ids = [
1436+
grp_tuple[0] for grp_tuple
1437+
in group.get_children_group_hierarchy(type='organization')
1438+
]
14191439
if member.capacity in roles_that_cascade:
1420-
children_group_ids = [
1421-
grp_tuple[0] for grp_tuple
1422-
in group.get_children_group_hierarchy(type='organization')
1423-
]
1440+
14241441
for group_id in children_group_ids:
1442+
group_ids.add(group_id)
14251443
group_ids_to_capacities[group_id] = member.capacity
1426-
group_ids |= set(children_group_ids)
1444+
else:
1445+
for group_id in children_group_ids:
1446+
if group_id in public_group_ids:
1447+
group_ids.add(group_id)
1448+
group_ids_to_capacities[group_id] = member.capacity
14271449

1428-
group_ids_to_capacities[group.id] = member.capacity
1429-
group_ids.add(group.id)
1450+
1451+
# group_ids_to_capacities[group.id] = member.capacity
1452+
# group_ids.add(group.id)
14301453

14311454
if not group_ids:
14321455
return []
@@ -1449,6 +1472,8 @@ def organization_list_for_user(context: Context,
14491472

14501473

14511474

1475+
1476+
14521477
@logic.side_effect_free
14531478
def organization_list(context: Context,
14541479
data_dict: DataDict) -> ActionResult.OrganizationList:
@@ -1782,21 +1807,10 @@ def organization_patch(context, data_dict):
17821807
if not isSysadmin:
17831808
temp_context = {"model": context["model"], "session": context["session"], "user": context["user"]}
17841809
old_org = get_action("organization_show")(temp_context, data_dict)
1785-
old_parent = old_org.get("groups", [])
1786-
if len(old_parent) == 0 or data_dict.get("parent") is None:
1787-
raise ValidationError({"message": _("You can't edit or create a Parent Team")})
17881810
if old_org.get("visibility", "public") == "private" and visibility == "public":
17891811
raise ValidationError({"message":
1790-
_("Team has private visibility and cannot be updated; Only sysadmin can update private team")
1812+
_("Team has private visibility and cannot be updated; Only sysadmin can switch private to public")
17911813
})
1792-
1793-
if visibility == "private":
1794-
users = old_org.get("users", [])
1795-
if users:
1796-
c_user = str(user)
1797-
user_capacity = [user.get("capacity") for user in users if user.get("name") == c_user]
1798-
if "admin" not in user_capacity:
1799-
raise ValidationError({"message": _("You can't update visibility of a team")})
18001814

18011815

18021816
if visibility == "public":
@@ -1824,22 +1838,12 @@ def validate_visibility(context, data_dict):
18241838

18251839
visibility = data_dict.get('visibility_type', "public")
18261840
owner_org = data_dict.get('owner_org', None)
1827-
id = data_dict.get('id', None)
1828-
if visibility in ["public", "internal"] and id:
1829-
package_show = get_action("package_show")(context, {"id": id})
1830-
id_org = package_show.get("owner_org", None)
1831-
if id_org:
1832-
org = get_action("organization_show")(context, {"id": id_org})
1833-
org_visibility = org.get("visibility", "public")
1834-
if org_visibility == "public":
1835-
raise ValidationError({"message": _("Organization has private visibility and cannot be made public")})
1836-
1837-
elif visibility in ["public", "internal"] and owner_org:
1841+
if visibility in ["public", "internal"] and owner_org:
18381842
org = get_action("organization_show")(context, {"id": owner_org})
18391843
org_visibility = org.get("visibility", "public")
18401844
if org_visibility == "private":
18411845
raise ValidationError({"message": _("Organization has private visibility and cannot create public datasets")})
1842-
1846+
18431847

18441848

18451849

ckan-backend-dev/src/ckanext-wri/ckanext/wri/logic/action/update.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,7 @@ def old_package_patch(context: Context, data_dict: DataDict) -> ActionResult.Pac
468468
You must be authorized to edit the dataset and the groups that it belongs
469469
to.
470470
"""
471+
validate_visibility(context, data_dict)
471472
_before_dataset_create_or_update(context, data_dict)
472473
_check_access("package_patch", context, data_dict)
473474

ckan-backend-dev/src/ckanext-wri/ckanext/wri/logic/auth/auth.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,15 @@ def package_update(up_func, context, data_dict):
106106
# if there is an owner org then we must have update_dataset
107107
# permission for that organization
108108
if authz.users_role_for_group_or_org(package.owner_org, user) != "admin":
109-
return {
110-
"success": False,
111-
"msg": _("User %s not authorized to edit package %s")
112-
% (str(user), package.id),
113-
}
109+
if not authz.has_user_permission_for_group_or_org(
110+
package.owner_org, user, "admin"
111+
):
112+
return {
113+
"success": False,
114+
"msg": _("User %s not authorized to edit package %s")
115+
% (str(user), package.id),
116+
}
117+
114118
else:
115119
if authz.check_config_permission("allow_dataset_collaborators"):
116120
# if org-level auth failed, check dataset-level auth

deployment/ckan/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ RUN pip3 install -e 'git+https://github.com/ckan/ckanext-scheming.git@5ce30cf285
1414
pip3 install -r 'https://raw.githubusercontent.com/datopian/ckanext-s3filestore/wri/signed-url/dev-requirements.txt' && \
1515
pip3 install -e 'git+https://github.com/datopian/ckanext-auth.git@a9e42702b797eaf3ffe967040867519219d32224#egg=ckanext-auth' && \
1616
pip3 install -r 'https://raw.githubusercontent.com/datopian/ckanext-auth/okta/requirements.txt' && \
17-
pip3 install -e 'git+https://github.com/datopian/ckanext-hierarchy.git@wri#egg=ckanext-hierarchy' && \
17+
pip3 install -e 'git+https://github.com/datopian/ckanext-hierarchy.git@5d069a5d032ba384f43d266fc397a0aa0a4b444c#egg=ckanext-hierarchy' && \
1818
pip3 install -e 'git+https://github.com/datopian/ckanext-issues.git@ea2b3cbace924a162de009fd8e5626052ebc99e1#egg=ckanext-issues' && \
1919
# Required by ckanext-issues, but it's no longer included in any of the requirements files or the subdependencies
2020
pip3 install mock && \
@@ -93,6 +93,7 @@ RUN ckan config-tool ${CKAN_INI} "ckan.plugins = ${CKAN__PLUGINS}"
9393
RUN ckan config-tool ${CKAN_INI} "ckan.auth.create_user_via_web = false"
9494
RUN ckan config-tool ${CKAN_INI} "ckan.root_path = /private-admin/{{LANG}}"
9595
RUN ckan config-tool ${CKAN_INI} "ckan.plugins = ${CKAN__PLUGINS}"
96+
RUN ckan config-tool ${CKAN_INI} "ckan.auth.create_unowned_dataset = false"
9697

9798
RUN if [ "$GITHUB_ACTIONS" = "true" ]; then ckan config-tool ${CKAN_INI} "ckan.cors.origin_allow_all = True"; fi
9899

deployment/ckan/patches/ckan/01_roles.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ diff --git a/ckan/ckan/authz.py b/ckan/ckan/authz.py
77
if _has_user_permission_for_groups(user_id, permission, [group_id]):
88
return True
99
- capacities = check_config_permission('roles_that_cascade_to_sub_groups')
10-
+ capacities = ['admin']
10+
+ capacities = ['admin', 'editor']
1111
assert isinstance(capacities, list)
1212
# Handle when permissions cascade. Check the user's roles on groups higher
1313
# in the group hierarchy for permission.
Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:mobile="http://www.google.com/schemas/sitemap-mobile/1.0" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1" xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
3-
<url><loc>http://localhost:3000</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
4-
<url><loc>http://localhost:3000/applications</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
5-
<url><loc>http://localhost:3000/applications/404</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
6-
<url><loc>http://localhost:3000/auth/password-reset</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
7-
<url><loc>http://localhost:3000/datasets/404</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
8-
<url><loc>http://localhost:3000/search</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
9-
<url><loc>http://localhost:3000/teams</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
10-
<url><loc>http://localhost:3000/teams/404</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
11-
<url><loc>http://localhost:3000/topics</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
12-
<url><loc>http://localhost:3000/topics/404</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
13-
<url><loc>http://localhost:3000/user-guide</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
14-
<url><loc>http://localhost:3000/user-guide/basic-definition</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
15-
<url><loc>http://localhost:3000/user-guide/dataset-view-pages</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
16-
<url><loc>http://localhost:3000/user-guide/search-page</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
17-
<url><loc>http://localhost:3000/user-guide/teams-topics</loc><lastmod>2025-03-23T20:54:07.812Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
3+
<url><loc>http://localhost:3000</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
4+
<url><loc>http://localhost:3000/applications</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
5+
<url><loc>http://localhost:3000/applications/404</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
6+
<url><loc>http://localhost:3000/auth/password-reset</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
7+
<url><loc>http://localhost:3000/datasets/404</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
8+
<url><loc>http://localhost:3000/search</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
9+
<url><loc>http://localhost:3000/teams</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
10+
<url><loc>http://localhost:3000/teams/404</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
11+
<url><loc>http://localhost:3000/topics</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
12+
<url><loc>http://localhost:3000/topics/404</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
13+
<url><loc>http://localhost:3000/user-guide</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
14+
<url><loc>http://localhost:3000/user-guide/basic-definition</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
15+
<url><loc>http://localhost:3000/user-guide/dataset-view-pages</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
16+
<url><loc>http://localhost:3000/user-guide/search-page</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
17+
<url><loc>http://localhost:3000/user-guide/teams-topics</loc><lastmod>2025-04-10T14:12:02.675Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
1818
</urlset>

deployment/frontend/src/components/_shared/SimpleSelect.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ export default function SimpleSelect<T extends FieldValues, V extends Object>({
3737
name,
3838
id,
3939
onChange: _onChange = (val) => {},
40-
}: SimpleSelectProps<T, V> & { onChange?: (val: any) => void }) {
40+
disabled,
41+
}: SimpleSelectProps<T, V> & { onChange?: (val: any) => void, disabled?: boolean }) {
4142
const { control } = formObj ?? useForm()
4243
return (
4344
<Controller
@@ -59,6 +60,7 @@ export default function SimpleSelect<T extends FieldValues, V extends Object>({
5960
}
6061
setSelected(e)
6162
}}
63+
disabled={disabled}
6264
>
6365
{({ open }) => (
6466
<>

0 commit comments

Comments
 (0)