<?php
/**
 *  ╔═══════════════════════════════════════════════════╗
 *  ║                                                   ║
 *  ║     ██╗  ██╗   █████╗    ██████╗                  ║
 *  ║     ██║  ██║  ██╔══██╗  ██╔═══██╗                 ║
 *  ║     ███████║  ███████║  ██║   ██║                 ║
 *  ║     ██╔══██║  ██╔══██║  ██║   ██║                 ║
 *  ║     ██║  ██║  ██║  ██║  ╚██████╔╝   SNS           ║
 *  ║                                                   ║    
 *  ║                                                   ║    
 *  ║     © 2023 HaoSNS™ All Rights Reserved            ║
 *  ║     官方网站: https://www.haosns.com                *
 *  ║     本代码由赣州乐易网络科技有限公司®提供             *
 *  ║                                                    *
 *  ║   未经授权禁止复制、传播或用于其他商业目的            *
 *  ║                                                   ║
 *  ╚═══════════════════════════════════════════════════╝
 */
/**
 * todo
 * name:菜单、权限名称
 * type：类型：1-菜单；2-权限
 * sons:子级菜单
 * ----auth_key：权限key(必须唯一)
 */
return [
    //首页
    [
        'name'  => '首页',
        'type'  => 1,
        'sons'  => [
            [
                'name'    => '首页',
                'type'    => 1,
                'sons'    => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'index/index.view'
                    ]
                ],
            ]
        ]

    ],
    // 帖子
    [
        'name'  => '帖子',
        'type'  => 1,
        'sons'  => [
            [
                'name'    => '帖子管理',
                'type'    => 1,
                'sons'    => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'community/article.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'community/article.manage'
                    ]
                ],
            ],
            [
                'name'    => '圈子管理',
                'type'    => 1,
                'sons'    => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'community/circle.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'community/circle.manage'
                    ]
                ],
            ],
            [
                'name'    => '话题管理',
                'type'    => 1,
                'sons'    => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'community/topic.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'community/topic.manage'
                    ]
                ],
            ]
        ]

    ],
    //商品
    [
        'name'  => '商城',
        'type'  => 1,
        'sons'  => [
            [
                'name'    => '商品管理',
                'type'    => 1,
                'sons'    => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'goods/goods.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/goods.manage'
                    ]

                ],
            ],
            [
                'name'  => '分类管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'   => 'goods/category.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/category.manage'
                    ]
                ]
            ],
            [
                'name'  => '品牌管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'goods/brand.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/brand.manage'
                    ]
                ],
            ],
            [
                'name'  => '商品单位',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'goods/unit.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/unit.manage'
                    ]

                ],
            ],
            [
                'name'  => '供应商管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'goods/supplier.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/supplier.manage'
                    ]

                ],
            ],
            [
                'name'  => '供应商分类',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'goods/suppliercategory.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/suppliercategory.manage'
                    ]
                ],
            ],
            //评价管理
            [
                'name'  => '评论管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'goods/comment.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'goods/comment.manage'
                    ]
                ],
            ],
        ],
    ],
    //订单
    [
        'name'  => '订单',
        'type'  => 1,
        'sons'=>[
            [
                'name'  => '订单管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'order/order.view'
                    ],
                    [
                        'name'      => '取消订单',
                        'type'      => 2,
                        'auth_key'  => 'order/order.cancel',
                    ],
                    [
                        'name'      => '修改价格',
                        'type'      => 2,
                        'auth_key'  => 'order/order.changeprice',
                    ],
                    [
                        'name'      => '修改运费',
                        'type'      => 2,
                        'auth_key'  => 'order/order.changeexpressprice',
                    ],
                    [
                        'name'      => '修改地址、发货',
                        'type'      => 2,
                        'auth_key'  => 'order/order.addressdelivery',
                    ],
                    [
                        'name'      => '确认收货',
                        'type'      => 2,
                        'auth_key'  => 'order/order.confirm',
                    ],
                    [
                        'name'      => '其他管理',
                        'type'      => 2,
                        'auth_key'  => 'order/order.manage'
                    ]

                ],
            ],
            [
                'name'  => '售后订单',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'order/aftersales.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'order/aftersales.manage'
                    ]

                ],
            ],
        ]
    ],
    //用户
    [
        'name'  => '用户',
        'type'  => 1,
        'sons'=>[
            [
                'name'  => '用户概览',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'user/profile.view'
                    ]
                ],
            ],
            [
                'name'  => '用户管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'user/list.view'
                    ],
                    [
                        'name'      => '调整用户账户',
                        'type'      => 2,
                        'auth_key'  => 'user/list.adjustaccount'
                    ],
                    [
                        'name'      => '其他管理',
                        'type'      => 2,
                        'auth_key'  => 'user/list.manage'
                    ],
                ],
            ],
            [
                'name'  => '用户等级',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'user/userlevel.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'user/userlevel.manage'
                    ]

                ],
            ],
            [
                'name'  => '用户标签',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'user/userlabel.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'user/userlabel.manage'
                    ]
                ],
            ],
        ]
    ],
    //营销
    [
        'name'  => '营销',
        'type'  => 1,
        'sons'=>[
          
            [
                'name'  => '应用中心',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/marketingapp.view'
                    ],
                ],
            ],
            //用户储值
            [
                'name'  => '充值概览',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/rechargesurvey.view'
                    ],
                ],
            ],
            [
                'name'  => '充值规则',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/rechargerule.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'marketing/rechargerule.save'
                    ],
                ],
            ],
            [
                'name'  => '充值记录',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/rechargerecord.view'
                    ]
                ],
            ],
            //信息通知
            [
                'name'  => '业务通知、验证码、卖家通知',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/notice.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'marketing/notice.manage'
                    ],
                ],
            ],
            [
                'name'  => '短信设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/smssetting.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'marketing/smssetting.manage'
                    ],
                ],
            ],

            //每日签到
            [
                'name'  => '签到概览',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/calendarsurvey.view'
                    ],
                ],
            ],
            [
                'name'  => '签到规则',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/calendarrule.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'marketing/calendarrule.save'
                    ],
                ],
            ],
            [
                'name'  => '签到记录',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'marketing/calendarrecord.view'
                    ]
                ],
            ],
            
        ]
    ],
    //财务
    [
        'name'  => '财务',
        'type'  => 1,
        'sons'=>[
            [
                'name'  => '财务概览',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'finance/profile.view'
                    ],
                ],
            ],
            [
                'name'  => '余额明细',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'finance/accountlog.view'
                    ]
                ],
            ],

        ]
    ],

    //渠道
    [
        'name'  => '渠道',
        'type'  => 1,
        'sons'=>[
            [
                'name'  => '微信公众号-渠道设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'channel/oasetting.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'channel/oasetting.save'
                    ],
                ],
            ],
            [
                'name'  => '微信公众号-菜单管理',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'channel/oamenu.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'channel/oamenu.save'
                    ],
                ],
            ],
            [
                'name'  => '微信公众号-关注回复、关键词回复、默认回复',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'channel/oafollowreply.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'channel/oafollowreply.manage'
                    ],
                ],
            ],
            [
                'name'  => '小程序-设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'channel/mpsetting.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'channel/mpsetting.save'
                    ],

                ],
            ],
            [
                'name'  => 'APP-设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'channel/appsetting.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'channel/appsetting.save'
                    ],

                ],
            ],
            [
                'name'  => 'H5-设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'channel/h5setting.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'channel/h5setting.save'
                    ],

                ],
            ]
        ]
    ],
    //设置
    [
        'name'  => '设置',
        'type'  => 1,
        'sons'=>[
            [
                'name'  => '店铺信息',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/shop.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/shop.save'
                    ],
                ],
            ],
            [
                'name'  => '分享设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/share.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/share.save'
                    ],
                ],
            ],
            [
                'name'  => '政策协议',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/protocol.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/protocol.save'
                    ],
                ],
            ],
            [
                'name'  => '支付方式',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/paymethod.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'setting/paymethod.save'
                    ],
                ],
            ],
            [
                'name'  => '支付配置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/payconfig.view'
                    ],
                    [
                        'name'      => '编辑',
                        'type'      => 2,
                        'auth_key'  => 'setting/payconfig.edit'
                    ],
                ],
            ],
            [
                'name'  => '配送方式',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/delivery.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'setting/delivery.manage'
                    ],
                ],
            ],
            [
                'name'  => '管理员',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/permissions.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'setting/permissions.manage'
                    ],
                ],
            ],
            [
                'name'  => '角色',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/role.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'setting/role.manage'
                    ],
                ]
            ],
            [
                'name'  => '商品设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/goods.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/goods.save'
                    ],
                ],
            ],
            [
                'name'  => '用户设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/user.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/user.save'
                    ],
                ],
            ],
            [
                'name'  => '登录注册',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/loginregister.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/loginregister.save'
                    ],
                ],
            ],
            [
                'name'  => '用户提现',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/withdrawdeposit.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/withdrawdeposit.save'
                    ],
                ],
            ],
            [
                'name'  => '交易设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/order.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/order.save'
                    ],
                ],
            ],
            [
                'name'  => '储存设置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/storage.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'setting/storage.manage'
                    ],
                ],
            ],
            [
                'name'  => '系统日志',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/systemlog.view'
                    ],
                ],
            ],
            [
                'name'  => '系统缓存',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/systemcache.view'
                    ],
                    [
                        'name'      => '清除系统缓存',
                        'type'      => 2,
                        'auth_key'  => 'setting/systemcache.clear'
                    ],
                ],
            ],
            [
                'name'  => '定时任务',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/task.view'
                    ],
                    [
                        'name'      => '管理',
                        'type'      => 2,
                        'auth_key'  => 'setting/task.manage'
                    ],
                ],
            ],
            [
                'name'  => '地图配置',
                'type'  => 1,
                'sons'  => [
                    [
                        'name'      => '查看',
                        'type'      => 2,
                        'auth_key'  => 'setting/map.view'
                    ],
                    [
                        'name'      => '保存',
                        'type'      => 2,
                        'auth_key'  => 'setting/map.save'
                    ],
                ],
            ],
        ]
    ]
];



