更新记录

1.0.0(2023-04-28) 下载此版本

实现小程序表格的合并等功能


平台兼容性

Vue2 Vue3
×
App 快应用 微信小程序 支付宝小程序 百度小程序 字节小程序 QQ小程序
× × × × × ×
钉钉小程序 快手小程序 飞书小程序 京东小程序
× × × ×
H5-Safari Android Browser 微信浏览器(Android) QQ浏览器(Android) Chrome IE Edge Firefox PC-Safari
× × × × × × × × ×
# 使用说明
组件传入参数
theader 数组对象(表格头)
    name:左侧显示
    roomNumber:右侧显示
    prop:表格头内容
tableData 二维数组(表格内容)
    isMerger 是否合并(1为合并)
    isRemove是否删除(1删除) people人数
    room房间号
    roomwidth表格宽度,基础为13
    select是否被选中
    storeyNum楼层号
    mergerId合并id(需要合并的表格)

## 数据
eg.
theader = [
    {name: "楼层", roomNumber: "房间号", prop: "name"},
    {name: "", prop: "1"},
    {name: "", prop: "1"},
    {name: "", prop: "1"},
    {name: "", prop: "1"}
]

tabelData = [
    [
        // isMerger 是否合并(1为合并),isRemove是否删除(1删除) people人数, room房间号, roomwidth表格宽度,基础为130,select是否被选中,storeyNum楼层号, mergerId合并id(需要合并的表格)
        {id: "1651769875267837953", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 1, roomWidth: 130, select: false,storeyNum: 4},
        {id: "1651769875267837954", isMerger: 1, isRemove: 0, mergerId: "1651769875267837954", people: 5,room: 2, roomWidth: 0, select: false,storeyNum: 4},
        {id: "1651769875267837955", isMerger: 1, isRemove: 0, mergerId: "1651769875267837954", people: 5,room: 3, roomWidth: 260, select: false,storeyNum: 4},
        {id: "1651769875267837956", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 4, roomWidth: 130, select: false,storeyNum: 4},
    ],
    [
        {id: "1651769875267837957", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 1, roomWidth: 130, select: false,storeyNum: 3},
        {id: "1651769875267837958", isMerger: 0, isRemove: 0, mergerId: "", people: 5,room: 2, roomWidth: 130, select: false,storeyNum: 3},
        {id: "1651769875267837959", isMerger: 1, isRemove: 0, mergerId: "1651769875267837959", people: 5,room: 3, roomWidth: 0, select: false,storeyNum: 3},
        {id: "1651769875267837960", isMerger: 1, isRemove: 0, mergerId: "1651769875267837959", people: 2,room: 4, roomWidth: 260, select: false,storeyNum: 3},
    ],
    [
        {id: "1651769875267837961", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 1, roomWidth: 130, select: false,storeyNum: 2},
        {id: "1651769875267837962", isMerger: 0, isRemove: 0, mergerId: "", people: 5,room: 2, roomWidth: 130, select: false,storeyNum: 2},
        {id: "1651769875267837963", isMerger: 0, isRemove: 0, mergerId: "", people: 5,room: 3, roomWidth: 130, select: false,storeyNum: 2},
        {id: "1651769875267837964", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 4, roomWidth: 130, select: false,storeyNum: 2},
    ],
    [
        {id: "1651769875267837965", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 1, roomWidth: 130, select: false,storeyNum: 1},
        {id: "1651769875267837966", isMerger: 0, isRemove: 0, mergerId: "", people: 5,room: 2, roomWidth: 130, select: false,storeyNum: 1},
        {id: "1651769875267837967", isMerger: 0, isRemove: 0, mergerId: "", people: 5,room: 3, roomWidth: 130, select: false,storeyNum: 1},
        {id: "1651769875267837968", isMerger: 0, isRemove: 0, mergerId: "", people: 2,room: 4, roomWidth: 130, select: false,storeyNum: 1},
    ],
]

隐私、权限声明

1. 本插件需要申请的系统权限列表:

2. 本插件采集的数据、发送的服务器地址、以及数据用途说明:

3. 本插件是否包含广告,如包含需详细说明广告表达方式、展示频率:

许可协议

MIT协议

使用中有什么不明白的地方,就向插件作者提问吧~ 我要提问