Files
fc/server/tools/gen_data/cfg/charge_data.erl
T

210 lines
15 KiB
Erlang
Raw Normal View History

2026-05-23 22:10:14 +08:00
%%----------------------------------------------------
%% 数据配置文件
%% @author whjing2011@gmail.com
%%----------------------------------------------------
-module(charge_data).
-export([cfg/0]).
-include("data_config.hrl").
-include("common.hrl").
cfg() ->
#data_cfg{
name = charge_data
,lua_name = charge_data
,desc = "充值配置数据"
,source = "charge_data.xml"
,target = "charge_data.erl"
,inc = ["common.hrl", "charge.hrl"]
,callback = [
{list, cb_fun, handle, {list, ["DATA"]}}
,{list2, cb_fun, handle, {list, ["永久累充"]}}
,{get_award, cb_fun, handle, {get_tuple, ["永久累充"], id, item_list}}
,{get_limit_charge, cb_fun, handle, {get_tuple, ["永久累充"], id, charge_sum}}
,{{get,undefined}, cb_fun, handle, {get_record, ["DATA"], id, charge_data, [id, name, val, gold, first_add, add, vip_exp
, pic, is_show, type, items, is_iosverify]}}
,{get_lose_gold, cb_fun, handle, {get_tuple, ["DATA"], id, lose_gold}}
,{{get_const, undefined}, cb_fun, handle, {get_fun, ["常量配置"], "get_const(~ts) -> ~ts; %% ~ts", [key, val, desc]}}
,{list_triple_rebate, cb_fun, handle, {list, ["三倍返利"]}}
,{get_triple_rebate, cb_fun, handle, {get_record, ["三倍返利"], id, triple_rebate_data, all}}
,{get_limit_triple, cb_fun, handle, {get_tuple, ["三倍返利"], id, charge_sum}}
,{first_gift_list, cb_fun, handle, {tuple_list, ["首充礼包"], [id, charge_sum]}}
,{{first_gift_award, "[]"}, cb_fun, handle, {get_tuple, ["首充礼包"], id, item_list}}
,{first_gift_list_id, cb_fun, handle, {tuple_list, ["首充返钻"], charge_id}}
,{get_first_gift_gold, cb_fun, handle, {get_tuple, ["首充返钻"], charge_id, gold}}
,{day_first_gift_list, cb_fun, handle, {list, ["首充调整"]}}
,{{day_first_gift_award, "[]"}, cb_fun, handle, {get_tuple, ["首充调整"], id, item_list}}
,{get_need_exp, cb_fun, handle, {get_tuple, ["首充调整"], id, need_exp}}
,{gte_first_gift_fid, cb_fun, handle, {get_tuple, ["首充调整"], id, fid}}
,{day_first_gift_list2, cb_fun, handle, {list, ["首充调整利维坦"]}}
,{{day_first_gift_award2, "[]"}, cb_fun, handle, {get_tuple, ["首充调整利维坦"], id, item_list}}
,{get_need_exp2, cb_fun, handle, {get_tuple, ["首充调整利维坦"], id, need_exp}}
,{gte_first_gift_fid2, cb_fun, handle, {get_tuple, ["首充调整利维坦"], id, fid}}
,{day_first_gift_list4, cb_fun, handle, {list, ["首充调整耶梦利维坦"]}}
,{{day_first_gift_award4, "[]"}, cb_fun, handle, {get_tuple, ["首充调整耶梦利维坦"], id, item_list}}
,{get_need_exp4, cb_fun, handle, {get_tuple, ["首充调整耶梦利维坦"], id, need_exp}}
,{gte_first_gift_fid4, cb_fun, handle, {get_tuple, ["首充调整耶梦利维坦"], id, fid}}
,{day_first_gift_list_new, cb_fun, handle, {list, ["新版首冲"]}}
,{{day_first_gift_award_new, "[]"}, cb_fun, handle, {get_tuple, ["新版首冲"], id, item_list}}
,{get_need_exp_new, cb_fun, handle, {get_tuple, ["新版首冲"], id, need_exp}}
,{gte_first_gift_fid_new, cb_fun, handle, {get_tuple, ["新版首冲"], id, fid}}
,{{day_gift, undefined}, cb_fun, handle, {get_tuple, ["每日礼包"], charge_id, [id, limit_count, limit_vip]}}
,{{day_gift_open_id, undefined}, cb_fun, handle, {tuple_type, ["每日礼包"], show_vip_lv, id}}
,{day_gift_reward, cb_fun, handle, {get_fun, ["每日礼包奖励"], "day_gift_reward({~ts, Lev}) when Lev >= ~ts andalso Lev =< ~ts -> ~ts;", [id, min, max, reward]}}
,{{get_vip_ext, "[]"}, cb_fun, handle, {get_tuple, ["月卡额外奖励"], [id, vip], reward}}
,{day_charge_reward, cb_fun, handle, {get_fun, ["每日首充"], "day_charge_reward(OpenDay) when OpenDay >= ~ts andalso OpenDay =< ~ts -> ~ts;", [min, max, reward]}}
]
,callback_cli = [
{constant, cb_fun_lua, handle, {key_val, ["常量配置"], key, all}}
,{charge_data, cb_fun_lua, handle, {key_val, ["DATA"], id, all}}
,{charge_reward_data, cb_fun_lua, handle, {key_val, ["永久累充"], id, all}}
,{first_reward_data, cb_fun_lua, handle, {key_val, ["首充礼包"], id, all}}
,{first_charge_data, cb_fun_lua, handle, {key_val, ["首充调整"], id, all}}
,{daily_gift_data, cb_fun_lua, handle, {key_val, ["每日礼包"], id, all}}
,{daily_gift_award, cb_fun_lua, handle, {type_val, ["每日礼包奖励"], [id], [min, max, reward]}}
,{supre_reward_data, cb_fun_lua, handle, {key_val, ["月卡额外奖励"], vip, all}}
,{daily_reward, cb_fun_lua, handle, {type_get_val, ["每日首充"], [id], all}}
,{new_first_charge_data, cb_fun_lua, handle, {key_val, ["新版首冲"], id, all}}
,{first_charge_lwt_data, cb_fun_lua, handle, {key_val, ["首充调整利维坦"], id, all}}
,{new_first_charge_data3, cb_fun_lua, handle, {key_val, ["首充调整耶梦利维坦"], id, all}}
],callback_json = [
{constant, cb_fun_json, handle, {key_val, ["常量配置"], key, all}}
,{charge_data, cb_fun_json, handle, {key_val, ["DATA"], id, all}}
,{charge_reward_data, cb_fun_json, handle, {key_val, ["永久累充"], id, all}}
,{first_reward_data, cb_fun_json, handle, {key_val, ["首充礼包"], id, all}}
,{first_charge_data, cb_fun_json, handle, {key_val, ["首充调整"], id, all}}
,{daily_gift_data, cb_fun_json, handle, {key_val, ["每日礼包"], id, all}}
,{daily_gift_award, cb_fun_json, handle, {type_val, ["每日礼包奖励"], [id], [min, max, reward]}}
,{supre_reward_data, cb_fun_json, handle, {key_val, ["月卡额外奖励"], vip, all}}
,{daily_reward, cb_fun_json, handle, {type_get_val, ["每日首充"], [id], all}}
,{new_first_charge_data, cb_fun_json, handle, {key_val, ["新版首冲"], id, all}}
,{first_charge_lwt_data, cb_fun_json, handle, {key_val, ["首充调整利维坦"], id, all}}
,{new_first_charge_data3, cb_fun_json, handle, {key_val, ["首充调整耶梦利维坦"], id, all}}
]
,sheet = [
{["DATA"], [
#f_column{type = int, name = id, desc = "ID", mod = all, primary = true}
,#f_column{type = bstr, name = name, desc = "名称", mod = all}
,#f_column{type = float, name = val, desc = "充值金额", mod = all}
,#f_column{type = int, name = gold, desc = "获得元宝", mod = all}
,#f_column{type = int, name = first_add, desc = "首次赠送元宝", mod = all}
,#f_column{type = int, name = add, desc = "赠送元宝", mod = all}
,#f_column{type = int, name = vip_exp, desc = "VIP经验", mod = all}
,#f_column{type = bstr, name = pic, desc = "图标", mod = all}
,#f_column{type = kv, name = is_show, desc = "是否显示", kv_type = bool}
,#f_column{type = int, name = type, desc = "类型", mod = all}
,#f_column{type = term, name = items, desc = "礼包ID", mod = all}
,#f_column{type = int, name = lose_gold, desc = "特殊处理", mod = all}
,#f_column{type = int, name = sort, desc = "排序ID",val_cli="0",mod = all}
,#f_column{type = int, name = is_iosverify, desc = "提审服显示", mod = all}
,#f_column{type = int, name = pay_id, desc = "内购ID映射", mod = client}
]}
,{["常量配置"], [
#f_column{type = atom, name = key, desc = "", primary = true, mod = all}
,#f_column{type = term, name = val, desc = "", add_list_sign=false, mod = all}
,#f_column{type = str, name = desc, desc = "描述", mod = all}
,#f_column{type = int, name = id, desc = "伙伴ID", mod = all}
]}
,{["永久累充"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = float, name = charge_sum, desc = "充值总数", mod = all}
,#f_column{type = term, name = item_list, desc = "奖励物品", mod = all}
,#f_column{type = term, name = spe_item_list, desc = "特殊物品", mod = all}
]}
,{["三倍返利"], [
#f_column{type = int, name = id, desc = "开放档次", primary = true, mod = all}
,#f_column{type = int, name = charge_sum, desc = "累计钻石", mod = all}
,#f_column{type = int, name = reward_times, desc = "奖励倍数", mod = all}
,#f_column{type = str, name = mail_title, desc = "邮件标题", mod = all}
,#f_column{type = str, name = mail_content, desc = "邮件内容", mod = all}
]}
,{["首充礼包"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = float, name = charge_sum, desc = "充值档次", mod = all}
,#f_column{type = term, name = item_list, desc = "奖励物品", mod = all}
,#f_column{type = int, name = button, desc = "对应按钮", mod = all}
,#f_column{type = term, name = effect_list, desc = "特效物品", mod = all}
]}
,{["首充返钻"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = int, name = charge_id, desc = "充值ID", mod = all}
,#f_column{type = bstr, name = name, desc = "名称", mod = all}
,#f_column{type = float, name = val, desc = "充值金额", mod = all}
,#f_column{type = int, name = gold, desc = "获得钻石", mod = all}
]}
,{["新版首冲"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = int, name = fid, desc = "归属ID", mod = all}
,#f_column{type = int, name = day, desc = "天数", mod = all}
,#f_column{type = term, name = item_list, desc = "奖励物品", mod = all}
,#f_column{type = int, name = need_exp, desc = "需要充值钻石数量", mod = all}
]}
,{["首充调整"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = int, name = fid, desc = "归属ID", mod = all}
,#f_column{type = int, name = day, desc = "天数", mod = all}
,#f_column{type = term, name = item_list, desc = "奖励物品", mod = all}
,#f_column{type = int, name = need_exp, desc = "需要充值钻石数量", mod = all}
,#f_column{type = term, name = effect_list, desc = "特效", mod = client}
]}
,{["首充调整利维坦"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = int, name = fid, desc = "归属ID", mod = all}
,#f_column{type = int, name = day, desc = "天数", mod = all}
,#f_column{type = term, name = item_list, desc = "奖励物品", mod = all}
,#f_column{type = int, name = need_exp, desc = "需要充值钻石数量", mod = all}
,#f_column{type = term, name = effect_list, desc = "特效", mod = client}
]}
,{["首充调整耶梦利维坦"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = int, name = fid, desc = "归属ID", mod = all}
,#f_column{type = int, name = day, desc = "天数", mod = all}
,#f_column{type = term, name = item_list, desc = "奖励物品", mod = all}
,#f_column{type = int, name = need_exp, desc = "需要充值钻石数量", mod = all}
,#f_column{type = term, name = effect_list, desc = "特效", mod = client}
,#f_column{type = bstr, name = desc, desc = "类型描述", mod = client}
,#f_column{type = bstr, name = desc1, desc = "描述1", mod = client}
,#f_column{type = bstr, name = desc2, desc = "描述1", mod = client}
,#f_column{type = bstr, name = desc3, desc = "界面资源", mod = client}
,#f_column{type = bstr, name = desc4, desc = "界面美术字", mod = client}
,#f_column{type = bstr, name = desc5, desc = "立绘标识", mod = client}
]}
,{["每日礼包"], [
#f_column{type = int, name = id, desc = "ID", primary = true, mod = all}
,#f_column{type = bstr, name = name, desc = "名称", mod = all}
,#f_column{type = int , name = charge_id, desc = "充值ID", mod = all}
,#f_column{type = float, name = val, desc = "直购金额", mod = all}
,#f_column{type = int, name = limit_count, desc = "每日可购数量", mod = all}
,#f_column{type = int, name = limit_vip, desc = "VIP限制", mod = all}
,#f_column{type = int, name = show_lv, desc = "显示等级限制", mod = all}
,#f_column{type = int, name = show_vip_lv, desc = "显示VIP限制", mod = all}
,#f_column{type = bstr, name = bg_res, desc = "背景资源", mod = client}
,#f_column{type = bstr, name = desc, desc = "描述内容", mod = client}
,#f_column{type = int, name = sort_id, desc = "排序ID", mod = client}
,#f_column{type = int, name = is_double, desc = "是否显示双倍", mod = client}
,#f_column{type = float, name = old_price, desc = "原价显示", mod = client}
,#f_column{type = bstr, name = icon_res, desc = "图标资源", mod = client}
]}
,{["每日礼包奖励"], [
#f_column{type = int, name = id, desc = "礼包ID", mod = all}
,#f_column{type = int, name = min, desc = "等级下限", mod = all}
,#f_column{type = int, name = max, desc = "等级上限", mod = all}
,#f_column{type = term, name = reward, desc = "奖励", mod = all}
]}
,{["月卡额外奖励"], [
#f_column{type = int, name = id, desc = "ID", mod = all}
,#f_column{type = int, name = vip, desc = "VIP等级", mod = all}
,#f_column{type = term, name = reward, desc = "奖励", mod = all}
]}
,{["每日首充"], [
#f_column{type = int, name = id, desc = "ID", mod = all}
,#f_column{type = int, name = min, desc = "开服天数下限", mod = all}
,#f_column{type = int, name = max, desc = "开服天数上限", mod = all}
,#f_column{type = term, name = reward, desc = "奖励", mod = all}
]}
]
}.