Browse Source

更新list-frame

lrf 5 years ago
parent
commit
1bcaa08159
1 changed files with 17 additions and 14 deletions
  1. 17 14
      layout/admin/README.md

+ 17 - 14
layout/admin/README.md

@@ -1,14 +1,17 @@
-* list-frame:
-  * props:{
-      * title:String 标题名
-      * filter:Array 搜索条件的数组 {
-          * label:显示查询的字符,
-          * model:数据库字段,
-          * type: 搜索类型 default=> String; select
-          * list: 如果是select类型,需要将选项放置list字段中 [{label,value}]
-          }
-      * totalRow: Number 数据总数
-      * needPag: 是否需要分页
-      * returns: 有,则会出现后退标题
-      * needFilter: 是否需要查询
-    }
+## list-frame:
+#### prop
+|参数|类型|默认值|是否必填|说明|
+|:-:|:-:|:-:|:-:|:-:|
+|title|String|`-`|否|card的标题|
+|needFilter|Boolean|true|否|是否使用搜索框|
+|filter|Array|[]|否|搜索框的数组|
+|needPag|Boolean|true|否|是否使用分页|
+|total|Number|0|否|数据总数,分页使用|
+|needAdd|Boolean|true|否|是否使用添加按钮|
+|returns|any|null|否|返回按钮指向的位置|
+#### slot
+|插槽名|说明|
+|:-:|:-:|
+|title|card标题自定义写,不包括add按钮|
+|filter|搜索位置|
+|options|filter中如果有select,需要用options插槽把选项拿出来|