USE `tmerclub_admin`;

# 新增文件上传配置，需要在后台重新配置文件上传
INSERT INTO `sys_config`(`param_key`, `param_value`, `remark`)
VALUES
    ('UPLOAD_FILE_CONFIG', '{\"storageType\":\"1\", \"endPoint\":\"\", \"accessKey\":\"\", \"secretKey\":\"\", \"bucketName\":\"\"}', '文件上传配置');

USE `tmerclub_auth`;
# 移除首页接口菜单资源授权,执行完sql需要手动移除redis缓存 查找key 'permission:uri_permissions:'
DELETE FROM menu_permission WHERE uri IN (
                                          '/p/order_statistics/list_shop_ranking_by_refund_count',
                                          '/p/order_statistics/list_shop_ranking_by_pay_actual',
                                          '/p/order_statistics/list_spu_ranking_by_order_count',
                                          '/p/order_statistics/get_order_info_by_day_count',
                                          '/p/order_statistics/get_detail_by_hour');

# 删除旧的微信小程序发货配置
USE `tmerclub_admin`;
DELETE FROM sys_config where param_key = 'WECHAT_SHIPPING_CONFIG';
# 将发货配置添加到微信小程序参数配置里面
UPDATE sys_config set param_value =
                          REPLACE(param_value,'}',',\"wechatShippingAudit\":false}') where param_key = 'MA_CONFIG';