3liz / qgis-pgmetadata-plugin

QGIS Plugin to manage some metadata from PostgreSQL layer
GNU General Public License v2.0
12 stars 10 forks source link

Fix issue #115: preserve backslashes in links when substituting into templates #118

Closed effjot closed 2 years ago

effjot commented 2 years ago

(I apologise for the mess in the last commits. The tests failed and I thought all those quotes and backslashes tripped the tests up. They do in the syntax highlighting of some apps. But I just had forgotten a function comment in the upgrade.sql.)

Gustry commented 2 years ago

You referring to Windows style path C:\\Users\... in the links right ? Is-it possible to add tests ? (There are already tests about HTML template in the test_sql.py, maybe you can update an existing link ?)

You can also add a item in the changelog file if you want.

effjot commented 2 years ago

You referring to Windows style path C:\Users... in the links right ?

Exactly. However, they have to be stored as file:///C:\… (three forward slashes) in order for the Qgis URL handler to open them correctly.

Is-it possible to add tests ? (There are already tests about HTML template in the test_sql.py, maybe you can update an existing link ?)

I have added tests for both HTML template and DCAT export. Is it intended that the dataset license is added to each link? In real use cases, links may point to some different data/publications that are not licensed the same way as the dataset itself.

effjot commented 2 years ago

Do you need anything more for this PR?

mdouchin commented 2 years ago

Thanks !

effjot commented 2 years ago

Thanks!