承接 lizmap/lizmap-pgmetadata-module 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

lizmap/lizmap-pgmetadata-module

Composer 安装命令:

composer require lizmap/lizmap-pgmetadata-module

包简介

Jelix module for Lizmap, which adds tools to show layers metadata created with PgMetadata

README 文档

README

Lint JS 🎳 Lint PHP 🎳 Release 🚀 Packagist

This module is designed for Lizmap Web Client, and allows displaying PostgreSQL layers metadata stored in the layer database.

The metadata must be created in the PostgreSQL database as designed in the PgMetadata QGIS plugin.

Metadata information panel

Installation

Once Lizmap Web Client application is installed and working, you can install the pgmetadata module:

Since version 0.2.4, it is recommended to install the module with Composer, the package manager for PHP. If you can't use it or if you are using Lizmap 3.3 or lower, use the manual way to install the module (jump to the corresponding section below)

Automatic installation with Composer and lizmap 3.4 or higher

  • into lizmap/my-packages, create the file composer.json (if it doesn't exist) by copying the file composer.json.dist, and install the modules with Composer:
cp -n lizmap/my-packages/composer.json.dist lizmap/my-packages/composer.json
composer require --working-dir=lizmap/my-packages "lizmap/lizmap-pgmetadata-module"
  • Then go into lizmap/install/ and execute Lizmap install scripts :

If you are using Lizmap 3.6 or higher, first execute

php configurator.php pgmetadata
php configurator.php pgmetadataAdmin

Then, for Lizmap 3.4 and higher:

php installer.php
./clean_vartmp.sh
./set_rights.sh

Go to the next section "Publish your metadata as a DCAT catalog".

Manual installation into lizmap 3.3 or 3.4 without Composer

  • Get the last ZIP archive in the release page of the GitHub repository.
  • Extract the archive and copy the pgmetadata and pgmetadataAdmin directories in Lizmap Web Client folder lizmap/lizmap-modules/
  • Edit the config file lizmap/var/config/localconfig.ini.php and add into the section [modules]:
pgmetadata.access=2
pgmetadataAdmin.access=2
  • Add into the section [simple_urlengine_entrypoints]:
admin="jacl2db~*@classic,jacl2db_admin~*@classic,jauthdb_admin~*@classic,master_admin~*@classic,admin~*@classic,jcommunity~*@classic,pgmetadataAdmin~*@classic"

If the parameter already exists, add ,pgmetadataAdmin~*@classic into the value.

  • If you are using Lizmap 3.6 or higher, execute
php lizmap/install/configurator.php pgmetadata
php lizmap/install/configurator.php pgmetadataAdmin
  • Then execute Lizmap install scripts into lizmap/install/ :
php lizmap/install/installer.php
./lizmap/install/clean_vartmp.sh
./lizmap/install/set_rights.sh

Publish your metadata as a DCAT catalog

If you need to publish your metadata catalog as an RDF catalog, for example to be harvested by a third-party metadata platform such as Ckan, you need to declare the needed credentials to your PostgreSQL database hosting the metadata.

To do it, go into the administration interface of Lizmap, click on the pgmetadata menu item, and you could indicate these credentials.

Then, you would be able to access the following URLs

  • The full RDF catalog with a URL like: https://[YOUR_LIZMAP_URL]/index.php/pgmetadata/dcat/
  • One dataset record by UUID identifier with: https://[YOUR_LIZMAP_URL]/index.php/pgmetadata/dcat/?id=76853e57-387e-4b8d-9ee8-f176e11cd9ce
  • Filter datasets containing a specified keyword (exact match): https://[YOUR_LIZMAP_URL]/index.php/pgmetadata/dcat/?q=akeyword

The XML created and returned would be like:

<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:dct="http://purl.org/dc/terms/"
    xmlns:dcat="http://www.w3.org/ns/dcat#"
    xmlns:owl="http://www.w3.org/2002/07/owl#"
    xmlns:foaf="http://xmlns.com/foaf/0.1/"
    xmlns:adms="http://www.w3.org/ns/adms#"
    xmlns:vcard="http://www.w3.org/2006/vcard/ns#"
    xmlns:schema="http://schema.org/"
    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#">
<dcat:Catalog rdf:about="https://lizmap.com">
    <dct:description>PgMetadata DCAT RDF catalog</dct:description>
    <dct:language>fr</dct:language>
    <dct:title>PgMetadata</dct:title>
    <dcat:dataset>
      <dcat:Dataset rdf:about="http://lizmap.localhost/index.php/pgmetadata/dcat/?id=76853e57-387e-4b8d-9ee8-f176e11cd9ce">
        <dct:identifier>76853e57-387e-4b8d-9ee8-f176e11cd9ce</dct:identifier>
        <dct:title>Test title</dct:title>
        <dct:description>Test abstract.</dct:description>
        <dct:language>en</dct:language>
        <dct:license>Licence Ouverte Version 2.1</dct:license>
        <dct:rights>Open</dct:rights>
        <dct:accrualPeriodicity>Yearly</dct:accrualPeriodicity>
        <dct:spatial>{"type":"Polygon","coordinates":[[[3.854,43.5786],[3.854,43.622],[3.897,43.622],[3.897,43.5786],[3.854,43.5786]]]}</dct:spatial>
        <dct:created rdf:datatype="http://www.w3.org/2001/XMLSchema#dateTime">2020-12-31T09:16:16.980258</dct:created>
        <dct:issued rdf:datatype="http://www.w3.org/2001/XMLSchema#dateTime">2020-12-31T09:16:16.980258</dct:issued>
        <dct:modified rdf:datatype="http://www.w3.org/2001/XMLSchema#dateTime">2020-12-31T09:16:16.980258</dct:modified>
        <dcat:contactPoint>
          <vcard:Organization>
            <vcard:fn>Jane Doe - Acme (GIS)</vcard:fn>
            <vcard:hasEmail rdf:resource="jane.doe@acme.gis">jane.doe@acme.gis</vcard:hasEmail>
          </vcard:Organization>
        </dcat:contactPoint>
        <dct:creator>
          <foaf:Organization>
            <foaf:name>Jane Doe - Acme (GIS)</foaf:name>
            <foaf:mbox>jane.doe@acme.gis</foaf:mbox>
          </foaf:Organization>
        </dct:creator>
        <dct:publisher>
          <foaf:Organization>
            <foaf:name>Bob Robert - Corp (Spatial div)</foaf:name>
            <foaf:mbox>bob.bob@corp.spa</foaf:mbox>
          </foaf:Organization>
        </dct:publisher>
        <dcat:distribution>
          <dcat:Distribution>
            <dct:title>test link</dct:title>
            <dct:description>Link description</dct:description>
            <dcat:downloadURL>https://metadata.is.good</dcat:downloadURL>
            <dcat:mediaType>application/pdf</dcat:mediaType>
            <dct:format>a file</dct:format>
            <dct:bytesize>590</dct:bytesize>
          </dcat:Distribution>
        </dcat:distribution>
        <dcat:keyword>tag_one</dcat:keyword>
        <dcat:keyword>tag_two</dcat:keyword>
        <dcat:theme>test theme</dcat:theme>
        <dcat:theme>New test theme</dcat:theme>
      </dcat:Dataset>
    </dcat:dataset>
</dcat:Catalog>
</rdf:RDF>

Contribution guide

For PHP, the project is using PHP-CS-Fixer. For JavaScript, it's using ESLint. Install it using npm install.

There are commands in the Makefile to run them.

Getting help

lizmap/lizmap-pgmetadata-module 适用场景与选型建议

lizmap/lizmap-pgmetadata-module 是一款 基于 PLpgSQL 开发的 Composer 扩展包,目前已累计 219 次下载、GitHub Stars 达 1, 最近一次更新时间为 2020 年 11 月 19 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「metadata」 「module」 「jelix」 「lizmap」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 lizmap/lizmap-pgmetadata-module 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 lizmap/lizmap-pgmetadata-module 我们能提供哪些服务?
定制开发 / 二次开发

基于 lizmap/lizmap-pgmetadata-module 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 219
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 4
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 5
  • Forks: 4
  • 开发语言: PLpgSQL

其他信息

  • 授权协议: MPL-2.0
  • 更新时间: 2020-11-19