Closed jusabatier closed 1 year ago
havent done anything special in the database, but with the localConfig.json merges from georchestra/datadir#318, creating a new context and enabling the permalink plugin in it, i seem to have the permalink tab here:
saving the permalink:
PERMALINK
category entry in the gs_category
table
[localhost:5432] georchestra@georchestra=> select * from mapstore.gs_category ;
id | name
-----+-------------
1 | MAP
2 | THUMBNAIL
3 | DETAILS
4 | DASHBOARD
5 | TEMPLATE
6 | USERSESSION
7 | GEOSTORY
8 | CONTEXT
123 | PERMALINK
(9 rows)
gs_stored_data
table
[localhost:5432] georchestra@georchestra=> select id,length(stored_data),resource_id from mapstore.gs_stored_data where resource_id=124;
id | length | resource_id
-----+--------+-------------
124 | 59901 | 124
gs_resource
table
[localhost:5432] georchestra@georchestra=> select * from mapstore.gs_resource where id=124;
id | creation | description | lastupdate | metadata | name | category_id
-----+-------------------------+-------------------------------------------+------------+----------+--------------------------------------+-------------
124 | 2023-08-08 11:49:41.957 | ceci est une description de mon permalink | NULL | | 50b2d2a1-dfc8-433f-9c30-0fbdde66fb02 | 123
gs_security
table to configure public access to the permalink
[localhost:5432] georchestra@georchestra=> select * from mapstore.gs_security where resource_id=124 ;
id | canread | canwrite | group_id | resource_id | user_id | username | groupname
-----+---------+----------+----------+-------------+---------+-----------+-----------
126 | t | t | NULL | 124 | NULL | testadmin | NULL
127 | t | f | NULL | 124 | NULL | NULL | everyone
- and 3 attributes are added to `gs_attribute` table
[localhost:5432] georchestra@georchestra=> select * from mapstore.gs_attribute where resource_id=124 ; id | attribute_date | name | attribute_number | attribute_text | attribute_type | resource_id -----+----------------+--------------+------------------+-------------------------------------+----------------+------------- 128 | NULL | type | NULL | context | STRING | 124 129 | NULL | pathTemplate | NULL | /context/${name}?category=PERMALINK | STRING | 124 130 | NULL | title | NULL | salledes | STRING | 124
so afaict in very basic testing #583 properly works here.
and fwiw i also have the permalink tab in the default mapstore map where the share plugin is enabled (eg outside of a context)
if that matters, i dont have an override for pluginsConfig.json
in /etc/georchestra
so the default is used.
my mapstore webapp comes from the debian package version 2023.02.xx.202308071444~de52fd4
built from the latest commit on the 2023.02 branch of the repo (eg https://github.com/georchestra/mapstore2-georchestra/commit/de52fd4b73618b8f00b2bf7e5418de64b75ba2f8)
Ok, I get it working by adding this line : https://github.com/georchestra/datadir/blob/master/mapstore/configs/localConfig.json#L48
It should be added to the release's Configuration changes.
@jusabatier Updated release notes
Describe the bug
In the last release (2023.02.00-RC2-geOrchestra), we have a new Permalink feature. I configured my localConfig.json and pluginConfig.json like explained in the release note. Also update the database to add the permalink resource type.
But doesn't have app.jsx file in my configs, so I skipped this step.
I can activate the permalink plugin in context creator, but when I open the context, the permalink tab is missing in the share popup.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
There should be a permalink tab in the share popup
@catmorales @MaelREBOUX @landryb @tdipisa