Skip to content

Commit

Permalink
draft edit link fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronald Krist committed Sep 26, 2023
1 parent e692d85 commit 39caa92
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion oarepo_model_builder_drafts/datatypes/components/draft.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def process_links(self, datatype, section: Section, **kwargs):
link_args=[
"cond=is_record",
f'if_=RecordLink("{{+ui}}{html_url_prefix}{{id}}")',
'else_=RecordLink("{+ui}/uploads/{id}")',
f'else_=RecordLink("{{+ui}}{html_url_prefix}{{id}}/edit")',
],
imports=[
Import("invenio_records_resources.services.ConditionalLink"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def process_tests(self, datatype, section, **extra_kwargs):
"publish": "https://{site_hostname}/api{BASE_URL}{pid_value}/draft/actions/publish",
"record": "https://{site_hostname}/api{BASE_URL}{pid_value}",
"self": "https://{site_hostname}/api{BASE_URL}{pid_value}/draft",
"self_html": "https://{site_hostname}/uploads/{pid_value}",
"self_html": "https://{site_hostname}{BASE_URL}{pid_value}/edit",
"versions": "https://{site_hostname}/api{BASE_URL}{pid_value}/versions",
},
"links_record": {
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = oarepo-model-builder-drafts
version = 4.0.8
version = 4.0.9
description =
authors = Ronald Krist <[email protected]>
readme = README.md
Expand Down

0 comments on commit 39caa92

Please sign in to comment.