install_platform_config.sql 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. -- 微信小程序和抖音小程序配置数据插入语句
  2. -- 先检查是否存在平台配置根节点,不存在则插入
  3. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  4. ('shop.platform', 'shop', '平台配置', '平台配置管理', 'group', '', '', '', '', '', '');
  5. -- 微信小程序配置组
  6. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  7. ('shop.platform.WechatMiniProgram', 'shop.platform', '微信小程序', '微信小程序平台配置', 'group', '', '', '', '', '', '');
  8. -- 微信小程序基本信息
  9. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  10. ('shop.platform.WechatMiniProgram.app_id', 'shop.platform.WechatMiniProgram', '小程序AppId', 'AppID是小程序开发标识码,配合AppSecret可调用小程序的接口能力', 'string', '', '', '', 'required', '', ''),
  11. ('shop.platform.WechatMiniProgram.secret', 'shop.platform.WechatMiniProgram', '小程序密钥', 'AppSecret是校验小程序开发者身份的密钥,具有极高的安全性', 'string', '', '', '', 'required', '', ''),
  12. ('shop.platform.WechatMiniProgram.status', 'shop.platform.WechatMiniProgram', '小程序开启状态', '是否开启微信小程序功能', 'boolean', '', '0', '', '', '', '');
  13. -- 微信小程序登录配置
  14. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  15. ('shop.platform.WechatMiniProgram.auto_login', 'shop.platform.WechatMiniProgram', '微信自动登录', '进入应用后,用户将会自动授权登录,未注册用户将会自动注册', 'boolean', '', '1', '', '', '', ''),
  16. ('shop.platform.WechatMiniProgram.bind_mobile', 'shop.platform.WechatMiniProgram', '绑定手机号', '授权登录后,未绑定手机号的用户,将会立即提醒绑定手机号', 'boolean', '', '1', '', '', '', '');
  17. -- 微信小程序支付配置组
  18. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  19. ('shop.platform.WechatMiniProgram.payment', 'shop.platform.WechatMiniProgram', '支付配置', '小程序支付方式配置', 'group', '', '', '', '', '', ''),
  20. ('shop.platform.WechatMiniProgram.payment.wechat', 'shop.platform.WechatMiniProgram.payment', '微信支付配置', '微信支付相关配置', 'int', '', '1', '', '', '', ''),
  21. ('shop.platform.WechatMiniProgram.payment.alipay', 'shop.platform.WechatMiniProgram.payment', '支付宝支付配置', '支付宝支付相关配置', 'int', '', '0', '', '', '', ''),
  22. ('shop.platform.WechatMiniProgram.payment.methods', 'shop.platform.WechatMiniProgram.payment', '支付方式', '可用的支付方式列表', 'array', '', '[\"wechat\",\"balance\"]', '', '', '', '');
  23. -- 微信小程序分享配置
  24. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  25. ('shop.platform.WechatMiniProgram.share', 'shop.platform.WechatMiniProgram', '分享信息', '小程序分享配置信息', 'array', '', '[]', '', '', '', '');
  26. -- 抖音小程序配置组
  27. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  28. ('shop.platform.DouyinMiniProgram', 'shop.platform', '抖音小程序', '抖音小程序平台配置', 'group', '', '', '', '', '', '');
  29. -- 抖音小程序基本信息
  30. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  31. ('shop.platform.DouyinMiniProgram.app_id', 'shop.platform.DouyinMiniProgram', '抖音小程序AppId', '抖音小程序应用ID', 'string', '', '', '', 'required', '', ''),
  32. ('shop.platform.DouyinMiniProgram.secret', 'shop.platform.DouyinMiniProgram', '抖音小程序密钥', '抖音小程序应用密钥', 'string', '', '', '', 'required', '', ''),
  33. ('shop.platform.DouyinMiniProgram.status', 'shop.platform.DouyinMiniProgram', '抖音小程序开启状态', '是否开启抖音小程序功能', 'boolean', '', '0', '', '', '', '');
  34. -- 抖音小程序登录配置
  35. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  36. ('shop.platform.DouyinMiniProgram.auto_login', 'shop.platform.DouyinMiniProgram', '自动登录', '进入应用后,用户将会自动授权登录,未注册用户将会自动注册', 'boolean', '', '1', '', '', '', ''),
  37. ('shop.platform.DouyinMiniProgram.bind_mobile', 'shop.platform.DouyinMiniProgram', '绑定手机号', '授权登录后,未绑定手机号的用户,将会立即提醒绑定手机号', 'boolean', '', '1', '', '', '', '');
  38. -- 抖音小程序支付配置组
  39. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  40. ('shop.platform.DouyinMiniProgram.payment', 'shop.platform.DouyinMiniProgram', '支付配置', '抖音小程序支付方式配置', 'group', '', '', '', '', '', ''),
  41. ('shop.platform.DouyinMiniProgram.payment.wechat', 'shop.platform.DouyinMiniProgram.payment', '微信支付配置', '微信支付相关配置', 'int', '', '0', '', '', '', ''),
  42. ('shop.platform.DouyinMiniProgram.payment.alipay', 'shop.platform.DouyinMiniProgram.payment', '支付宝支付配置', '支付宝支付相关配置', 'int', '', '1', '', '', '', ''),
  43. ('shop.platform.DouyinMiniProgram.payment.methods', 'shop.platform.DouyinMiniProgram.payment', '支付方式', '可用的支付方式列表', 'array', '', '[\"alipay\",\"balance\"]', '', '', '', '');
  44. -- 抖音小程序分享配置
  45. INSERT IGNORE INTO `fa_config` (`name`, `group`, `title`, `tip`, `type`, `visible`, `value`, `content`, `rule`, `extend`, `setting`) VALUES
  46. ('shop.platform.DouyinMiniProgram.share', 'shop.platform.DouyinMiniProgram', '分享信息', '抖音小程序分享配置信息', 'array', '', '[]', '', '', '', '');