flux-eco/ui-transformer
Composer 安装命令:
composer require flux-eco/ui-transformer
包简介
Component for flux-capacitor apps developed by fluxlabs ag
README 文档
README
This component tranforms in json instances described data for the usage in a user interface. e.g.
- makes translation of untranslated strings
- merges json documents which are linked by references
Usage
@see directory examples
.env
UI_TRANSFORM_TRANSLATION_FILES_DIRECTORY=configs/translations
UI_TRANSFORM_UI_DEFINITION_DIRECTORY=configs/ui
UI_TRANSFORM_PAGE_LIST_DEFINITION_FILE_PATH=configs/ui/pages.yaml
UI_TRANSFORM_MARKDOWN_TO_HTML_CONVERTER_REST_API_URL=http://localhost:9001
translations\de.yaml
pageTitle:
todo: Todo's
topic: Thema
topic:
title: Thema
description: Beschreibung
todo:
title: ToDo
description: Beschreibung
action:
delete: Delete
edit: Edit
ui\pages.yaml
- $ref: topic/page.yaml
- $ref: todo/page.yaml
ui\topic\page.yaml
title:
type: lngKey
key: pageTitle.topic
url: "/listdata/Topic"
avatar: "/icons/seminars.png"
pageType: ListData
projectionName: topic
editForm:
$ref: editForm.yaml
createForm:
$ref: createForm.yaml
itemActions:
edit:
type: form
key: editForm
title:
type: lngKey
key: action.edit
delete:
type: form
key: deleteForm
title:
type: lngKey
key: action.delete
todos:
type: subobject
key: todos
title:
type: lngKey
key: pageTitle.todo
projectionName: todo
ui\topic\editForm.yaml
rootObjectAggregateName: ToDo
properties:
- title:
type: lngKey
key: topic.title
key: title
dataIndex: title
valueType: string
width: m
formItemProps:
rules:
- required: true
message: Please enter a Title
- title:
type: lngKey
key: topic.description
key: description
dataIndex: description
valueType: textarea
width: m
formItemProps: [ ]
ui...
-> @see directory examples
example.php
<?php
require_once __DIR__ . '/../vendor/autoload.php';
fluxDotEnv\loadDotEnv(__DIR__);
//get page list
$pages = fluxUiTransformer\getPages();
echo "getPages(): ".PHP_EOL;
print_r($pages).PHP_EOL.PHP_EOL;
//get page
$pageTopic = fluxUiTransformer\getPageDefinition('topic');
echo "getPageDefinition('topic'): ".PHP_EOL;
print_r($pageTopic).PHP_EOL;
outputs
getPages():
Array
(
[data] => Array
(
[0] => Array
(
[title] => Thema
[url] => /listdata/Topic
[avatar] => /icons/seminars.png
[pageType] => ListData
[projectionName] => topic
[editForm] => Array
(
[rootObjectAggregateName] => ToDo
[properties] => Array
(
[0] => Array
(
[title] => Thema
[key] => title
[dataIndex] => title
[valueType] => string
[width] => m
[formItemProps] => Array
(
[rules] => Array
(
[0] => Array
(
[required] => 1
[message] => Please enter a Title
)
)
)
)
[1] => Array
(
[title] => Beschreibung
[key] => description
[dataIndex] => description
[valueType] => textarea
[width] => m
[formItemProps] => Array
(
)
)
)
)
[createForm] => Array
(
[rootObjectAggregateName] => Topic
[properties] => Array
(
[0] => Array
(
[title] => Thema
[key] => title
[dataIndex] => title
[valueType] => string
[width] => m
[formItemProps] => Array
(
[rules] => Array
(
[0] => Array
(
[required] => 1
[message] => Please enter a Title
)
)
)
)
[1] => Array
(
[title] => Beschreibung
[key] => description
[dataIndex] => description
[valueType] => textarea
[width] => m
[formItemProps] => Array
(
)
)
)
)
[itemActions] => Array
(
[edit] => Array
(
[type] => form
[key] => editForm
[title] => Edit
)
[delete] => Array
(
[type] => form
[key] => deleteForm
[title] => Delete
)
[todos] => Array
(
[type] => subobject
[key] => todos
[title] => Todo's
[projectionName] => todo
)
)
)
[1] => Array
(
[title] => Todo's
[url] => /listdata/Todo
[avatar] => /icons/seminars.png
[pageType] => ListData
[projectionName] => todo
[editForm] => Array
(
[rootObjectAggregateName] => Todo
[properties] => Array
(
[0] => Array
(
[title] => ToDo
[key] => title
[dataIndex] => title
[valueType] => string
[width] => m
[formItemProps] => Array
(
[rules] => Array
(
[0] => Array
(
[required] => 1
[message] => Please enter a Title
)
)
)
)
[1] => Array
(
[title] => Beschreibung
[key] => description
[dataIndex] => description
[valueType] => textarea
[width] => m
[formItemProps] => Array
(
)
)
)
)
[createForm] => Array
(
[rootObjectAggregateName] => Todo
[properties] => Array
(
[0] => Array
(
[title] => ToDo
[key] => title
[dataIndex] => title
[valueType] => string
[width] => m
[formItemProps] => Array
(
[rules] => Array
(
[0] => Array
(
[required] => 1
[message] => Please enter a Title
)
)
)
)
[1] => Array
(
[title] => Beschreibung
[key] => description
[dataIndex] => description
[valueType] => textarea
[width] => m
[formItemProps] => Array
(
)
)
)
)
[itemActions] => Array
(
[edit] => Array
(
[type] => form
[key] => editForm
[title] => Edit
)
[delete] => Array
(
[type] => form
[key] => deleteForm
[title] => Delete
)
)
)
)
[status] => success
[total] => 2
)
getPageDefinition('topic'):
Array
(
[title] => Thema
[url] => /listdata/Topic
[avatar] => /icons/seminars.png
[pageType] => ListData
[projectionName] => topic
[editForm] => Array
(
[rootObjectAggregateName] => ToDo
[properties] => Array
(
[0] => Array
(
[title] => Thema
[key] => title
[dataIndex] => title
[valueType] => string
[width] => m
[formItemProps] => Array
(
[rules] => Array
(
[0] => Array
(
[required] => 1
[message] => Please enter a Title
)
)
)
)
[1] => Array
(
[title] => Beschreibung
[key] => description
[dataIndex] => description
[valueType] => textarea
[width] => m
[formItemProps] => Array
(
)
)
)
)
[createForm] => Array
(
[rootObjectAggregateName] => Topic
[properties] => Array
(
[0] => Array
(
[title] => Thema
[key] => title
[dataIndex] => title
[valueType] => string
[width] => m
[formItemProps] => Array
(
[rules] => Array
(
[0] => Array
(
[required] => 1
[message] => Please enter a Title
)
)
)
)
[1] => Array
(
[title] => Beschreibung
[key] => description
[dataIndex] => description
[valueType] => textarea
[width] => m
[formItemProps] => Array
(
)
)
)
)
[itemActions] => Array
(
[edit] => Array
(
[type] => form
[key] => editForm
[title] => Edit
)
[delete] => Array
(
[type] => form
[key] => deleteForm
[title] => Delete
)
[todos] => Array
(
[type] => subobject
[key] => todos
[title] => Todo's
[projectionName] => todo
)
)
)
Contributing 💜
Please ...
- ... register an account at https://git.fluxlabs.ch
- ... create pull requests 🔥
Adjustment suggestions / bug reporting 🐾
Please ...
- ... register an account at https://git.fluxlabs.ch
- ... ask us for a Service Level Agreement: support@fluxlabs.ch 😘
- ... read and create issues
flux-eco/ui-transformer 适用场景与选型建议
flux-eco/ui-transformer 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 29 次下载、GitHub Stars 达 0, 最近一次更新时间为 2022 年 03 月 27 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「flux-eco」 「fluxlabs」 「ui-transformer」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 flux-eco/ui-transformer 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 flux-eco/ui-transformer 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 flux-eco/ui-transformer 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Makes a json schema instance for the transmitted values and schema
Offers value objects
Component for flux-capacitor apps developed by fluxlabs
Loads .env-Files
Creates projections of aggregate root objects
Handling mysql databases with json based table schemas
统计信息
- 总下载量: 29
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 11
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0-only
- 更新时间: 2022-03-27