承接 kitzberger/dragon-drop 相关项目开发

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

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

kitzberger/dragon-drop

Composer 安装命令:

composer require kitzberger/dragon-drop

包简介

ViewHelper to add 'copy-paste' to EXT:mask containers in the page module

关键字:

README 文档

README

This extension provides fluid viewhelpers to add copy/paste functionality to EXT:mask backend templates.

CopyRecord/CutRecord ViewHelper

These two viewhelpers can be used within backend templates to provide "copy CE" and "cut CE" links:

<html data-namespace-typo3-fluid="true"
      xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
      xmlns:dnd="http://typo3.org/ns/Kitzberger/DragonDrop/ViewHelpers">

<div class="mask-element">
    <dnd:be.copyRecord uid="{row.uid}" />
    <dnd:be.cutRecord uid="{row.uid}" />
    <h4>{row.header}</h4>
</div>

PasteLink ViewHelper

This viewhelper can be used within backend templates to provide a paste link for "clipped" CEs within container elements.

<html data-namespace-typo3-fluid="true"
      xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
      xmlns:dnd="http://typo3.org/ns/Kitzberger/DragonDrop/ViewHelpers">

<div class="mask-accordion">
    <dnd:be.pasteLink target="{row}"
                      override="{colPos:999, tx_mask_accordion_items_parent: row.uid}" />

    <ul>
        <f:for each="{data.tx_mask_accordion_items}" as="item">
            <li>
                {item.header} (id={item.uid})
            </li>
        </f:for>
    </ul>
</div>

This'll render an extra paste button into the accordion element:

page module

These are the attributes

  • target which needs to be set to a array representing the target record. Currently only the array key pid is being used internally.
  • override which contains the field modifications the newly created record will be updated with. For EXT:mask containers that's at least colPos=999 and the "parent field".

This extension comes with a DataHandler hook that updates the "children count" field of the container after attaching the copied CE to it. The name of said "children count" will be derived from TCA.

Compatibility with EXT:mask

In order to make this work with EXT:mask you need to make sure that the "parent field" is present in TCA. Please check the configuration module in the backend.

If it's not present (yet) you need to provide it yourself, see github.com/Gernott/mask/issues/389 for details.

Prevent hidden records

In case you don't want the paste record to be hidden, you can override the hidden property with 0 via the override attribute, e.g.

<dnd:be.pasteLink target="{row}"
                  override="{colPos:999, tx_mask_accordion_items_parent: row.uid, hidden:0}" />

Allowed CTypes

To prevent certain CTypes to be pasted into your mask element you can specify the allowed attribute:

<dnd:be.pasteLink target="{row}"
                  override="{colPos:999, tx_mask_accordion_items_parent: row.uid}"
                  allowed="textmedia,mask_elementX" />

Customize button text

In case you don't want the button text to be that paste icon, you can set a different button text:

<dnd:be.pasteLink target="{row}" ...>
    Paste here
</dnd:be.pasteLink>

kitzberger/dragon-drop 适用场景与选型建议

kitzberger/dragon-drop 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 3.85k 次下载、GitHub Stars 达 1, 最近一次更新时间为 2021 年 03 月 02 日, 在 PHP 生态内属于活跃度较高的组件。

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

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

围绕 kitzberger/dragon-drop 我们能提供哪些服务?
定制开发 / 二次开发

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

BUG 修复 & 性能优化

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

项目外包 & 长期维护

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

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

统计信息

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

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2021-03-02