承接 menatwork/contao-multicolumnwizard-bundle 相关项目开发

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

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

menatwork/contao-multicolumnwizard-bundle

Composer 安装命令:

composer require menatwork/contao-multicolumnwizard-bundle

包简介

MultiColumWizard for Contao OpenSource CMS

README 文档

README

Build Status Latest Version tagged Latest Version on Packagist Installations via composer per month

The repository of contao-multicolumnwizard-bundle was moved to contao-community-alliance. We plan to support this version with bugfixes until the new version from the CCA is released.

MultiColumnWizard

The MultiColumnWizard is a widget for mapping several fields of the same and/or different type (input type) in a DCA element. The individual fields of the MCW are listed column by column in the backend and can be extended row by row as a group. The arrangement corresponds to a multidimensional array of the form array[rows][fields], which is stored in the database as a serialized array. The widget is almost identical to MultiTextWizard or MultiSelectWizard. It extends the functionality of any widget.

More information can be found in the contao wiki http://de.contaowiki.org/MultiColumnWizard

Install

The Multicolumnwizard is usually installed via an extension. If it is necessary to install Multicolumnwizard yourself, please use the console with the composer via the call

composer require menatwork/contao-multicolumnwizard-bundle

or

web/contao-manager.phar.php composer require menatwork/contao-multicolumnwizard-bundle

Developers should add the Multicolumnwizard to their composer.json as a dependent package.

Usages

Usage with columnFields

<?php
$GLOBALS['TL_DCA']['tl_theme']['fields']['templateSelection'] = [
    'label'     => &$GLOBALS['TL_LANG']['tl_theme']['templateSelection'],
    'exclude'   => true,
    'inputType' => 'multiColumnWizard',
    'eval'      => [
        'columnFields' => [
            'ts_client_os'      => [
                'label'     => &$GLOBALS['TL_LANG']['tl_theme']['ts_client_os'],
                'exclude'   => true,
                'inputType' => 'select',
                'eval'      => [
                    'style'              => 'width:250px',
                    'includeBlankOption' => true,
                ],
                'options'   => [
                    'option1' => 'Option 1',
                    'option2' => 'Option 2',
                ],
            ],
            'ts_client_browser' => [
                'label'     => &$GLOBALS['TL_LANG']['tl_theme']['ts_client_browser'],
                'exclude'   => true,
                'inputType' => 'text',
                'eval'      => ['style' => 'width:180px'],
            ],
        ],
    ],
    'sql'       => 'blob NULL',
];
?>

Usage with callback

<?php
$GLOBALS['TL_DCA']['tl_table']['fields']['anything'] = [
    'label'     => &$GLOBALS['TL_LANG']['tl_table']['anything'],
    'exclude'   => true,
    'inputType' => 'multiColumnWizard',
    'eval'      => [
        'mandatory'       => true,
        'columnsCallback' => ['Class', 'Method'],
    ],
    'sql'       => 'blob NULL',
];
?>

Disable Drag and Drop

<?php
$GLOBALS['TL_DCA']['tl_theme']['fields']['templateSelection'] = [
    'label'     => &$GLOBALS['TL_LANG']['tl_theme']['templateSelection'],
    'exclude'   => true,
    'inputType' => 'multiColumnWizard',
    'eval'      => [
        // add this line for use the up and down arrows
        'dragAndDrop'  => false,
        'columnFields' => [
            'ts_client_browser' => [
                'label'     => &$GLOBALS['TL_LANG']['tl_theme']['ts_client_browser'],
                'exclude'   => true,
                'inputType' => 'text',
                'eval'      => ['style' => 'width:180px'],
            ],
        ],
    ],
    'sql'       => 'blob NULL',
];
?>

Hide buttons

<?php
$GLOBALS['TL_DCA']['tl_theme']['fields']['templateSelection'] = [
    'label'     => &$GLOBALS['TL_LANG']['tl_theme']['templateSelection'],
    'exclude'   => true,
    'inputType' => 'multiColumnWizard',
    'eval'      => [
        // add this line for hide one or all buttons
        'buttons'      =>
        [
            'new'    => false,
            'copy'   => false,
            'delete' => false,
            'up'     => false,
            'down'   => false,
            'move'   => false
        ],
        // as alternative to hide all buttons use the next line
        //'hideButtons'  => true,
        'columnFields' => [
            'ts_client_browser' => [
                'label'     => &$GLOBALS['TL_LANG']['tl_theme']['ts_client_browser'],
                'exclude'   => true,
                'inputType' => 'text',
                'eval'      => ['style' => 'width:180px'],
            ],
        ],
    ],
    'sql'       => 'blob NULL',
];
?>

Other parameters

From version 3.6.11:

There is a new parameter wrapper_style in eval with which the enclosing element of a widget can be styled; in the standard output this is a table cell td.

With the following specification:

<?php
$GLOBALS['TL_DCA']['tl_theme']['fields']['templateSelection'] = [
    'inputType' => 'multiColumnWizard',
    //...
    'columnFields' => [
        'ts_client_browser' => [
            'label'     => &$GLOBALS['TL_LANG']['tl_theme']['ts_client_browser'],
            'exclude'   => true,
            'inputType' => 'text',
            'eval'      => [
                'wrapper_style' => 'width:47%',
                'style'         => 'width:100%'
            ],
        ],
    ],
    //...
];
?>

this source code is generated:

<td style="width:47%" class="hidelabel mcwUpdateFields">
  <input style="width:100%" type="text" name="mcwtest_default[0][ts_client_browser]" id="ctrl_mcwtest_default_row0_ts_client_browser" class="tl_text" value="" data-action="focus->contao--scroll-offset#store" data-contao--scroll-offset-target="autoFocus">
</td>

From version 3.6.10:

Use default in eval to set multiple default values and rows.

<?php
$GLOBALS['TL_DCA']['tl_theme']['fields']['templateSelection'] = [
    'inputType' => 'multiColumnWizard',
    'eval'      => [
        'default'      => [
            ['ts_client_os' => 'option1', 'ts_client_browser' => 'FF'],
            ['ts_client_os' => 'option2', 'ts_client_browser' => 'Chrome'],
        ],
        'columnFields' => [
            'ts_client_os'      => [
                //...
            ],
            'ts_client_browser' => [
                //...
            ],
        ],
    ],
    'sql'       => 'blob NULL',
];
?>

The descriptions of the columns are displayed in the column header as a tooltip next to the icon 🛈 - the character or text can be changed in the language file.

From version 3.6.5:

The Symfony translator can be used to translate the label and description. To do this, set the useTranslator key to true.

<?php
$GLOBALS['TL_DCA']['tl_theme']['fields']['anything'] = [
//...
    'inputType' => 'multiColumnWizard',
    'eval'      => [
        'useTranslator' => true,
// ...
    ],
];
?>

menatwork/contao-multicolumnwizard-bundle 适用场景与选型建议

menatwork/contao-multicolumnwizard-bundle 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 369.68k 次下载、GitHub Stars 达 2, 最近一次更新时间为 2018 年 12 月 02 日, 在 PHP 生态内属于活跃度较高的组件。

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

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

围绕 menatwork/contao-multicolumnwizard-bundle 我们能提供哪些服务?
定制开发 / 二次开发

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

BUG 修复 & 性能优化

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

项目外包 & 长期维护

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

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

统计信息

  • 总下载量: 369.68k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 20
  • 依赖项目数: 153
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 3
  • Forks: 13
  • 开发语言: PHP

其他信息

  • 授权协议: LGPL-3.0-or-later
  • 更新时间: 2018-12-02