feat(payment): 支付&付费菜单按参考主题重构并新增提现策略页
- 子菜单重组为知识付费/余额充值/VIP会员/创作分成/推广返佣/收款接口/提现策略 - 收款接口页 1:1 复刻 Zibll 双下拉结构,仅保留支付宝/微信/PayPal/Stripe/易支付 - 订单前缀/流水号前缀/提现单号前缀配置保留并移入收款接口页 - 知识付费/推广返佣按参考主题全字段复刻,余额充值并入充值卡配置 - 新增 tabbed/between_number/page_select 表单控件及后端 pages 搜索源 - 清理旧 SPA 组件、无消费者 REST 端点与废弃配置键(不写双路兼容) - 更新存量契约测试至新 schema 文件
This commit is contained in:
1 parent
fb5cdf247d
commit
a48007a44d
36 files changed
+2042
-2273
No files matched your search
@@ -0,0 +1,238 @@
|
||||
/**
|
||||
* 知识付费 — 1:1 复刻参考主题对应页面(免登陆购买 / 模块位置 / 优惠码 /
|
||||
* 客户服务 / 付费下载 / 商品预置参数),并保留 AKSRT 订单展示与状态文案。
|
||||
*/
|
||||
export const knowledgeSchema = {
|
||||
key: 'payment.knowledge',
|
||||
title: '知识付费',
|
||||
icon: 'fa fas fa-shopping-bag',
|
||||
description: '付费内容总开关、免登陆购买、模块显示、优惠码与商品预置参数配置。',
|
||||
defaults: {
|
||||
pay_no_logged_in: true,
|
||||
pay_cookie_day: 15,
|
||||
pay_no_logged_remind: '您当前未登录!建议登陆后购买,可保存购买订单',
|
||||
pay_box_position: 'top',
|
||||
pay_free_logged_show: true,
|
||||
pay_show_user: true,
|
||||
pay_show_paycount: true,
|
||||
coupon_post_s: false,
|
||||
coupon_desc: '',
|
||||
pay_mark: '付费',
|
||||
payment_show_ip: false,
|
||||
payment_show_device: false,
|
||||
payment_show_order_no: true,
|
||||
payment_show_create_time: true,
|
||||
payment_show_pay_time: true,
|
||||
payment_order_status_pending: '待支付',
|
||||
payment_order_status_paid: '已支付',
|
||||
payment_order_status_refunding: '退款中',
|
||||
payment_order_status_refunded: '已退款',
|
||||
payment_order_status_closed: '已关闭',
|
||||
pay_service: [],
|
||||
down_alone_page: false,
|
||||
down_user_log: 50,
|
||||
down_post_log: 50,
|
||||
down_remote_to_local_s: true,
|
||||
down_remote_to_local_size: 2048,
|
||||
down_remote_to_local_ext: 'zip,rar,7z,text,png,jpg,jpeg,gif,mp3,mp4,avi,wmv,flv,swf,doc,docx,xls,xlsx,ppt,pptx,pdf',
|
||||
down_verify_nonce: true,
|
||||
pay_modo_default: '0',
|
||||
points_price_default: 0,
|
||||
vip_1_points_default: 0,
|
||||
vip_2_points_default: 0,
|
||||
pay_price_default: '0.01',
|
||||
pay_original_price_default: '',
|
||||
pay_promotion_tag_default: '<i class="fa fa-fw fa-bolt"></i> 限时特惠',
|
||||
vip_1_price_default: '0',
|
||||
vip_2_price_default: '0',
|
||||
pay_rebate_discount: '0',
|
||||
pay_cuont_default: { min: 0, max: 0 },
|
||||
pay_details_default: '',
|
||||
pay_extra_hide_default: '',
|
||||
pay_attributes_default: [],
|
||||
pay_gallery_show_default: 1,
|
||||
},
|
||||
groups: [
|
||||
{
|
||||
key: 'notice',
|
||||
title: '说明',
|
||||
icon: 'fa fas fa-info-circle',
|
||||
fields: [
|
||||
{
|
||||
key: 'knowledge_notice',
|
||||
label: '',
|
||||
type: 'content',
|
||||
ui_only: true,
|
||||
content: '<p><b>知识付费</b></p><ul style="margin:6px 0 0 18px;line-height:1.9"><li>知识付费功能主要分为文章付费、付费会员、余额系统、推广返佣、创作分成等功能组成,您可以根据您的需要开启对应功能</li><li>使用支付功能请先在「收款接口」页配置好收款通道</li></ul>',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'guest-buy',
|
||||
title: '免登陆购买',
|
||||
icon: 'fa fas fa-user-clock',
|
||||
fields: [
|
||||
{ key: 'pay_no_logged_in', label: '免登陆购买', type: 'switch', default: true, help: '开启后如果用户未登录则使用浏览器缓存验证是否购买' },
|
||||
{ key: 'pay_cookie_day', label: 'Cookie时间(天)', type: 'number', default: 15, min: 1, max: 31, dependsOn: { key: 'pay_no_logged_in', value: true }, help: '免登陆购买的浏览器缓存有效时间' },
|
||||
{ key: 'pay_no_logged_remind', label: '未登录提醒', type: 'textarea', default: '您当前未登录!建议登陆后购买,可保存购买订单', rows: 2, dependsOn: { key: 'pay_no_logged_in', value: true } },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'box-position',
|
||||
title: '模块显示位置',
|
||||
icon: 'fa fas fa-arrows-alt',
|
||||
fields: [
|
||||
{
|
||||
key: 'pay_box_position',
|
||||
label: '购买模块位置',
|
||||
type: 'radio',
|
||||
default: 'top',
|
||||
options: [
|
||||
{ label: '文章模块上方', value: 'box_top' },
|
||||
{ label: '文章内容顶部', value: 'top' },
|
||||
{ label: '文章内容底部', value: 'bottom' },
|
||||
{ label: '文章模块下方', value: 'box_bottom' },
|
||||
],
|
||||
help: '在文章页面中购买模块的显示位置',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'display-basic',
|
||||
title: '基础显示',
|
||||
icon: 'fa fas fa-eye',
|
||||
fields: [
|
||||
{ key: 'pay_free_logged_show', label: '免费资源登录可见', type: 'switch', default: true, help: '免费资源必须登录后才能查看' },
|
||||
{ key: 'pay_show_user', label: '订单数据', type: 'switch', default: true, help: '在用户中心显示订单数据' },
|
||||
{ key: 'pay_show_paycount', label: '销量显示', type: 'switch', default: true, help: '商品详情显示销售数量' },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'coupon',
|
||||
title: '商品优惠码',
|
||||
icon: 'fa fas fa-ticket-alt',
|
||||
fields: [
|
||||
{ key: 'coupon_post_s', label: '为所有商品启用优惠券功能', type: 'switch', default: false, help: '开启后将为所有商品显示输入优惠码的功能;也可以单独给任意一个商品开启' },
|
||||
{ key: 'coupon_desc', label: '优惠码默认说明', type: 'textarea', default: '', rows: 1, dependsOn: { key: 'coupon_post_s', value: true }, help: '用户填写优惠码时展示的提醒内容,支持HTML代码' },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'display',
|
||||
title: '展示设置',
|
||||
icon: 'fa fas fa-list-alt',
|
||||
fields: [
|
||||
{ key: 'pay_mark', label: '付费标记', type: 'input', default: '付费' },
|
||||
{ key: 'payment_show_ip', label: '显示用户IP', type: 'switch', default: false },
|
||||
{ key: 'payment_show_device', label: '显示设备信息', type: 'switch', default: false },
|
||||
{ key: 'payment_show_order_no', label: '显示订单号', type: 'switch', default: true },
|
||||
{ key: 'payment_show_create_time', label: '显示创建时间', type: 'switch', default: true },
|
||||
{ key: 'payment_show_pay_time', label: '显示支付时间', type: 'switch', default: true },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'status',
|
||||
title: '状态设置',
|
||||
icon: 'fa fas fa-tags',
|
||||
fields: [
|
||||
{ key: 'payment_order_status_pending', label: '待支付状态文案', type: 'input', default: '待支付' },
|
||||
{ key: 'payment_order_status_paid', label: '已支付状态文案', type: 'input', default: '已支付' },
|
||||
{ key: 'payment_order_status_refunding', label: '退款中状态文案', type: 'input', default: '退款中' },
|
||||
{ key: 'payment_order_status_refunded', label: '已退款状态文案', type: 'input', default: '已退款' },
|
||||
{ key: 'payment_order_status_closed', label: '已关闭状态文案', type: 'input', default: '已关闭' },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'service',
|
||||
title: '客户服务',
|
||||
icon: 'fa fas fa-headphones',
|
||||
fields: [
|
||||
{
|
||||
key: 'pay_service',
|
||||
label: '用户服务内容',
|
||||
type: 'group',
|
||||
button_title: '添加服务项',
|
||||
default: [],
|
||||
fields: [
|
||||
{ key: 'value', label: '服务内容', type: 'input', default: '' },
|
||||
{ key: 'icon', label: '自定义图标', type: 'icon', default: '' },
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'feature',
|
||||
title: '商品功能配置',
|
||||
icon: 'fa fas fa-cubes',
|
||||
fields: [
|
||||
{
|
||||
key: 'pay_type_option',
|
||||
label: '商品功能配置',
|
||||
type: 'tabbed',
|
||||
tabs: [
|
||||
{
|
||||
key: 'download',
|
||||
title: '付费下载',
|
||||
fields: [
|
||||
{ key: 'down_alone_page', label: '独立下载页面', type: 'switch', default: false, help: '开启后,付费资源的下载链接会跳转独立页面显示' },
|
||||
{ key: 'down_user_log', label: '保存用户下载记录(条)', type: 'number', default: 50, min: 0, help: '填0则不保存,注意记录量太大可能会影响网站性能' },
|
||||
{ key: 'down_post_log', label: '保存文章下载记录(条)', type: 'number', default: 50, min: 0, help: '填0则不保存,注意记录量太大可能会影响网站性能' },
|
||||
{ key: 'down_remote_to_local_s', label: '远程文件转本地文件下载', type: 'switch', default: true, help: '当下载地址为外链文件时,先将远程文件下载到本地服务器,再提供给用户下载,可完全隐藏远程下载地址' },
|
||||
{ key: 'down_remote_to_local_size', label: '文件大小限制(Kb)', type: 'number', default: 2048, min: 0 },
|
||||
{ key: 'down_remote_to_local_ext', label: '文件格式限制', type: 'input', default: 'zip,rar,7z,text,png,jpg,jpeg,gif,mp3,mp4,avi,wmv,flv,swf,doc,docx,xls,xlsx,ppt,pptx,pdf', help: '限制使用此功能的文件格式,多个用英文逗号隔开' },
|
||||
{ key: 'down_verify_nonce', label: '下载前检测用户环境', type: 'switch', default: true, help: '防止机器批量扫描下载,有效防止跨站攻击' },
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'presets',
|
||||
title: '商品预置参数配置',
|
||||
icon: 'fa fas fa-sliders-h',
|
||||
fields: [
|
||||
{
|
||||
key: 'presets_notice',
|
||||
label: '',
|
||||
type: 'content',
|
||||
ui_only: true,
|
||||
content: '在下方配置的参数新建文章时候会自动填入,方便新建文章的设置。最终以文章配置为准',
|
||||
},
|
||||
{
|
||||
key: 'pay_modo_default',
|
||||
label: '支付类型',
|
||||
type: 'radio',
|
||||
default: '0',
|
||||
options: [
|
||||
{ label: '普通商品(金钱购买)', value: '0' },
|
||||
{ label: '积分商品(积分购买,依赖于用户积分功能)', value: 'points' },
|
||||
],
|
||||
},
|
||||
{ key: 'points_price_default', label: '积分售价(积分)', type: 'number', default: 0, min: 0 },
|
||||
{ key: 'vip_1_points_default', label: '一级会员积分售价(积分)', type: 'number', default: 0, min: 0 },
|
||||
{ key: 'vip_2_points_default', label: '二级会员积分售价(积分)', type: 'number', default: 0, min: 0 },
|
||||
{ key: 'pay_price_default', label: '执行价', type: 'input', sanitize_type: 'money_decimal', default: '0.01', suffix: '元' },
|
||||
{ key: 'pay_original_price_default', label: '原价', type: 'input', sanitize_type: 'money_decimal', default: '', suffix: '元', help: '显示在执行价格前面,并划掉' },
|
||||
{ key: 'pay_promotion_tag_default', label: '促销标签', type: 'textarea', sanitize_type: 'html', default: '<i class="fa fa-fw fa-bolt"></i> 限时特惠', rows: 1 },
|
||||
{ key: 'vip_1_price_default', label: '一级会员价格', type: 'input', sanitize_type: 'money_decimal', default: '0', suffix: '元', help: '填0则为一级会员免费' },
|
||||
{ key: 'vip_2_price_default', label: '二级会员价格', type: 'input', sanitize_type: 'money_decimal', default: '0', suffix: '元', help: '填0则为二级会员免费' },
|
||||
{ key: 'pay_rebate_discount', label: '推广折扣', type: 'input', sanitize_type: 'money_decimal', default: '0', suffix: '元', help: '通过推广链接购买,额外优惠的金额;需开启推广返佣功能,且不能超过实际购买价' },
|
||||
{ key: 'pay_cuont_default', label: '销量浮动', type: 'between_number', default: { min: 0, max: 0 }, help: '为真实销量增加或减少的数量,系统会根据此处设置的区间获取随机值作为预置参数' },
|
||||
{ key: 'pay_details_default', label: '更多详情', type: 'textarea', sanitize_type: 'html', default: '', rows: 3, help: '可插入任意的HTML代码' },
|
||||
{ key: 'pay_extra_hide_default', label: '额外隐藏内容', type: 'textarea', sanitize_type: 'html', default: '', rows: 3, help: '可插入任意的HTML代码' },
|
||||
{
|
||||
key: 'pay_attributes_default',
|
||||
label: '资源属性',
|
||||
type: 'group',
|
||||
button_title: '添加属性',
|
||||
default: [],
|
||||
fields: [
|
||||
{ key: 'key', label: '属性名称', type: 'input', default: '' },
|
||||
{ key: 'value', label: '属性内容', type: 'input', default: '' },
|
||||
],
|
||||
},
|
||||
{ key: 'pay_gallery_show_default', label: '付费图片免费查看数量(张)', type: 'number', default: 1, min: 0, help: '设置付费图片可免费查看前几张图片的数量的默认值' },
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
||||
Reference in new issue
Block a user