美文网首页
列表结构

列表结构

作者: sundern | 来源:发表于2018-06-28 13:02 被阅读0次

1.<youi:grid></youi:grid>标签

属性:

src:【一般为分页的查询方法】

id:grid_【列表展示内容】

showConvertDropdown:(没发现用处)

idKeys:(没发现用处)

styleClass:grid-query-inline(当查询条件只占一行时)

2.列表查询块

通常使用<youi:fieldLayout></youi:fieldLayout>标签包围

属性:

columns:【列数】

styleClass:col-sm-10 no-border

子标签:<youi:fieldText/>

属性:

property:【列字段】

caption:【查询条件框前的label描述文本】

operator:【查询操作符,比如LIKE】

3.展示列:<youi:gridCol/>

属性:

property:【列字段】

caption:【列表第一行头描述文本】

width:【列宽】

align :【对齐方式】

4.操作的两种表示方式

(实际最终两种方式在页面解析出来的都是<a>标签

(1)使用函数render写入<a>标签

<youi:gridCol property="button" caption="操作" width="20%" renderer="renderButton"/>

<%--操作按钮写入--%>

<youi:func name="renderButton">   

      var htmls = [];   

      htmls.push('<a class="youi-icon edit icon-edit" data-command="gridCommand" data-name="edit">编辑a>');  

      htmls.push('<a class="youi-icon split icon-split" data-command="gridCommand">a> ');   

     htmls.push('<a class="youi-icon delete icon-delete" data-command="gridCommand" data-name="delete">删除a> ');  

      htmls.push('<a class="youi-icon split icon-split" data-command="gridCommand">a> ');    

     htmls.push('<a class="youi-icon index icon-index" data-command="gridCommand" data-name="relate_index">关联指标a> ')    

    return htmls.join('');

<youi:func>

(2)gridCol中的type属性为button

<youi:gridCol width="20%" align="center" type="button" property="button" caption="操作">   

    <youi:button name="edit" caption="编辑"/>   

    <youi:button name="split" caption=""/>   

    <youi:button name="editItems" caption="数据项" icon="proxy-list"/>   

    <youi:button name="split" caption=""/>   

    <youi:button name="removeRecord" icon="delete-ml" caption="删除"/>

<youi:gridCol>

两种方式的规则一样,当操作的按钮数量超过三个,需要在列上查询下的靠右方添加操作说明,在行内的操作处只显示图标。

比如:

<p class="pull-right grid-operate-explanation">

    <span>操作说明:</span>

    <span class="icon-eye-open"> 查看</span>

    <span class="icon-delete-ml">删除</span>

    <span class="icon-send-files">发送列表</span>

</p>

button的操作:<youi:func></youi:func>

属性:

name:【<youi:grid>的id】_【<youi:button>的name或者的data-name】

5.【应用场景】编辑列表数据保存后刷新列表回调方法

<youi:func name="subpage_【被关闭的页面<youi:subpage>的subpageId】_change" params="record">

    $elem('【<youi:grid>的id】',pageId).grid('refresh');

</youi:func>

相关文章

  • 列表结构

    1.标签 属性: src:【一般为分页的查询方法】 id:grid_...

  • Redis降低内存占用

    1.Redis降低内存占用方案 短结构 分片结构 2.短结构 2.1 压缩列表 以列表为例,列表是由双向链表实现,...

  • 2019-01-11

    方法列表(objc_method_list)结构 先了解方法结构 方法列表结构 分类是如何实现的? categor...

  • Js列表

    列表是有序的数据,常用语最受欢迎榜单、购物车列表、其他列表展示。 在js中并不存在列表结构,所以列表结构需要...

  • 数据结构与算法-散列表查找实现

    散列表查找算法实现 首先是需要定义一个散列表的结构以及一些相关的常数。其中HashTable就是散列表结构。结构当...

  • HTML

    列表 结构标记 列表分为:有序列表和无序列表 无序列表 无序列表是一个项目的列...

  • 2021超详细的HashMap原理分析,面试官就喜欢问这个!

    一、散列表结构 散列表结构就是数组+链表的结构 二、什么是哈希? Hash也称散列、哈希,对应的英文单词Hash,...

  • Python_by_4plus_Week0(3)

    五 Data Structure (数据结构) python的四种数据结构,分别是:列表、字典、元组、集合。 列表...

  • 商品列表-结构

    新建一个HotShopList.vue的组件html代码实现如下 CSS代码实现如下 效果如图

  • 6. Python的数据结构

    在Python中有三种内建的数据结构——列表、元组和字典。 列表 列表(List)是处理一组有序项目的数据结构,列...

网友评论

      本文标题:列表结构

      本文链接:https://www.haomeiwen.com/subject/nvgwyftx.html