PHPackages                             quansitech/qscmf-columntype-modal - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Admin Panels](/categories/admin)
4. /
5. quansitech/qscmf-columntype-modal

ActiveLibrary[Admin Panels](/categories/admin)

quansitech/qscmf-columntype-modal
=================================

qscmf listbuilder column modal

v1.0.3(4y ago)0342↓100%1MITHTMLPHP &gt;=7.2.0

Since Mar 26Pushed 4y ago1 watchersCompare

[ Source](https://github.com/quansitech/qscmf-columntype-modal)[ Packagist](https://packagist.org/packages/quansitech/qscmf-columntype-modal)[ RSS](/packages/quansitech-qscmf-columntype-modal/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (1)Versions (5)Used By (0)

qscmf-columntype-modal
======================

[](#qscmf-columntype-modal)

qscmf 列表类型控件--modal框

#### 安装

[](#安装)

```
composer require quansitech/qscmf-columntype-modal
```

#### 如何使用

[](#如何使用)

- 设置modal框内容，可自定义html

> ```
> 通过使用占位符，可以动态展示list的值。
> 如列name，只需用 __name__ 作为占位符，生成list后会自动替换成该记录的真实name值。
> 若列名存在下划线，如nick_name，那么占位符就是 __nick_name__ ，以此类推。
> ```
>
>
>
> ```
> // 可以与formBuilder结合使用，展示渲染后的html
>  public function genModelHtml($id){
>      $info = D('Post')->getOne($id);
>      $builder = new FormBuilder();
>      $builder
>          ->addFormItem('title', 'text', '标题')
>          ->addFormItem('summary', 'textarea', '简介')
>          ->addFormItem('cover', 'picture', '封面', '尺寸为214*250px', ['width' => 214, 'height' => 250])
>          ->setFormData($info)
>          ->setShowBtn(false)
>          ->setReadOnly(true);
>
>      return $builder->display(true);
>  }
>
> $data_list = D('User')->limit(10)->select();
> foreach ($data_list as &$v){
>     $v['modal_html'] = $this->genModelHtml($v['post_id']);
> }
>
> // 当value为数组
> ->addTableColumn('nick_name', '用户名', 'modal', ['content' => '__modal_html__'], false, '点击查看更多信息')
>
> //当value为字符串
> ->addTableColumn('nick_name', '用户名', 'modal', '__modal_html__', false, '点击查看更多信息')
> ```

- 设置api\_url，将接口返回的info设置为modal框内容

> 1. 接口说明
>
> > - 需要返回JSON数据格式
> > - 若数据正常则设置status为1，否则为0
> > - 将需要返回的内容赋值给info
>
> 2. 用例
>
> ```
> // api_url的参数支持使用占位符，动态替换list的值
> // 如列id，只需用 __id__ 作为占位符，生成list后会自动替换成该记录的真实id值。
> // 若列名存在下划线，如user_id，那么占位符就是 __user_id__ ，以此类推。
>  $option = [
>      'api_url' => U('genModelHtml', ['id'=>'__id__'], true, true),
>      'width' => '50%',
>      'height' => '50%'
>  ];
>
>  // ListBuilder对应列配置
>  ->addTableColumn('nick_name', '用户名', 'modal', $option, false, '点击查看更多信息');
>
> public function genModelHtml($id){
>    $info = D('User')->getOne($id);
>
>    if (!$info){
>        $this->ajaxReturn(['status' => 0, 'info' => 'not found']);
>    }
>    $builder = new FormBuilder();
>    $builder
>        ->addFormItem('title', 'text', '标题')
>        ->addFormItem('summary', 'textarea', '简介')
>        ->addFormItem('cover', 'picture', '封面', '尺寸为214*250px', ['width' => 214, 'height' => 250])
>        ->setFormData($info)
>        ->setShowBtn(false)
>        ->setReadOnly(true);
>
>    $this->ajaxReturn(['status' => 1, 'info' => $builder->display(true)]);
> }
> ```

- 设置modal框宽度与高度，默认宽度50%，高度60%

> ```
> $option = [
>    'content' => 'modal content',
>    'width' => '50%',
>    'height' => '50%'
> ];
>
> ->addTableColumn('nick_name', '用户名', 'modal', $option, false, '点击查看更多信息')
> ```

###  Health Score

26

—

LowBetter than 46% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

4

Last Release

1816d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/15a0610fee78753bdad92fd45c3506455c0fd45ae51924797b1841d260495a3f?d=identicon)[tiderjian](/maintainers/tiderjian)

![](https://www.gravatar.com/avatar/6c2b4bb10b346cb957c091d3273e3332276b5d09a29e255d387184f5dd4b5976?d=identicon)[xhiny](/maintainers/xhiny)

---

Top Contributors

[![Xhiny](https://avatars.githubusercontent.com/u/35066497?v=4)](https://github.com/Xhiny "Xhiny (16 commits)")

---

Tags

componentadminmodalthinkphpqscmflistbuilder

### Embed Badge

![Health badge](/badges/quansitech-qscmf-columntype-modal/health.svg)

```
[![Health](https://phpackages.com/badges/quansitech-qscmf-columntype-modal/health.svg)](https://phpackages.com/packages/quansitech-qscmf-columntype-modal)
```

###  Alternatives

[zhongshaofa/easyadmin

基于ThinkPHP6.0和layui的快速开发的后台管理系统。

6589.3k](/packages/zhongshaofa-easyadmin)[rockys/ex-admin-thinkphp

Ex-admin-thinkphp 是一个基于Ant Design of Vue + Thinkphp 开发而成后台系统构建工具，无需关注页面模板JavaScript，只用php代码即可快速构建出一个功能完善的后台系统。

173.0k](/packages/rockys-ex-admin-thinkphp)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
