%%---------------------------------------------------- %% 个推仓检礼包 %% @author wujinhan<947537249@qq.com> %%---------------------------------------------------- -module(personal_push_data). -export([cfg/0]). -include("data_config.hrl"). -include("common.hrl"). cfg() -> #data_cfg{ name = personal_push_data ,lua_name = personal_push_data ,desc = "个推仓检礼包" ,source = "personal_push_data.xml" ,target = "personal_push_data.erl" ,inc = ["common.hrl", "personal_push.hrl"] ,callback = [ {{get_const, undefined}, cb_fun, handle, {get_fun, ["常量配置"], "get_const(~ts) -> ~ts; %% ~ts", [key, val, desc]}} ,{{get_trigger_desc, undefined}, cb_fun, handle, {get_fun, ["触发器"], "get_trigger_desc(~ts) -> ~ts; ", [id, desc]}} ,{{get_gift_type_list, "[]"}, cb_fun, handle, {get_tuple, ["触发器"], trigger, [id, gift_type]}} ,{get_trigger_list, cb_fun, handle, {tuple_list, ["触发器"], trigger}} ,{get_cond_id_list, cb_fun, handle, {tuple_list, ["仓检条件"], cond_id}} ,{get_rfm_list, cb_fun, handle, {tuple_type, ["RFM计算"], assess_type, [score, min, max]}} ,{get_score_range, cb_fun, handle, {tuple_list, ["RFM金额"], scores}} ,{{get_scores_to_money, "0"}, cb_fun, handle, {get_tuple, ["RFM金额"], scores, money}} ,{get_gift_list, cb_fun, handle, {record_type, ["个推礼包"], [type_id, money], personal_push_gift_data, all}} ,{get_gift, cb_fun, handle, {get_record, ["个推礼包"], gift_id, personal_push_gift_data, all}} ,{{get_type_cd, "0"}, cb_fun, handle, {get_tuple, ["礼包类型"], type_id, cool_time}} ,{get_warehouse_cond, cb_fun, handle, {get_tuple, ["仓检条件"], cond_id, [check_cond, weight]}} ] ,callback_cli = [ ] ,callback_json = [ {gift_info, cb_fun_json, handle, {key_val, ["个推礼包"], [gift_id], all}}, {gift_layout_info, cb_fun_json, handle, {type_get_val, ["礼包布局"], [layout, gift_id], all}} ] ,sheet = [ {["常量配置"],[ #f_column{type = term, name = key, desc = "常量标识", primary = true, add_list_sign = false,mod = all} ,#f_column{type = term, name = val, desc = "常量值", add_list_sign = false,mod= all} ,#f_column{type = bstr, name = desc, desc = "描述", mod = all} ]} ,{["触发器"],[ #f_column{type = int, name = id, desc = "id", primary = true, mod = all} ,#f_column{type = term, name = trigger, desc = "条件", add_list_sign = false, mod= all} ,#f_column{type = term, name = gift_type, desc = "触发礼包类型", mod= all} ,#f_column{type = bstr, name = desc, desc = "描述", mod = all} ]} ,{["礼包类型"],[ #f_column{type = int, name = type_id, desc = "礼包类型id", primary = true, mod = all} ,#f_column{type = bstr, name = name, desc = "类型名称", mod= all} ,#f_column{type = int, name = cool_time, desc = "冷却时间(s)", mod= all} ]} ,{["个推礼包"],[ #f_column{type = int, name = gift_id, desc = "礼包id", primary = true, mod = all} ,#f_column{type = int, name = type_id, desc = "类型id", mod= all} ,#f_column{type = int, name = charge_id, desc = "充值id", mod= server} ,#f_column{type = int, name = limit_count, desc = "限购次数", mod= server} ,#f_column{type = int, name = money, desc = "原价", mod= all} ,#f_column{type = int, name = costly_num, desc = "超值数值", mod= server} ,#f_column{type = int, name = valid_time, desc = "有效时间(s)", mod= server} ,#f_column{type = term, name = open_cond, desc = "开启条件", mod= server} ,#f_column{type = term, name = warehouse_id, desc = "仓检条件", mod= server} ,#f_column{type = term, name = award, desc = "奖励", mod= server} ,#f_column{type = bstr, name = name, desc = "礼包名称", mod= client} ,#f_column{type = int, name = layout, desc = "布局", mod= client} ,#f_column{type = bstr, name = face_id, desc = "头像id", mod= client} ]} ,{["仓检条件"],[ #f_column{type = int, name = cond_id, desc = "条件id", primary = true, mod = all} ,#f_column{type = term, name = check_cond, desc = "检测条件", add_list_sign = false, mod= all} ,#f_column{type = int, name = weight, desc = "权重", mod= all} ,#f_column{type = bstr, name = desc, desc = "说明", mod= all} ]} ,{["RFM计算"],[ #f_column{type = int, name = score, desc = "评估分数", mod = all} ,#f_column{type = int, name = assess_type, desc = "评估类型", mod= all} ,#f_column{type = int, name = min, desc = "下限", mod= all} ,#f_column{type = int, name = max, desc = "上限", mod= all} ]} ,{["RFM金额"],[ #f_column{type = int, name = id, desc = "id", mod = all} ,#f_column{type = term, name = scores, desc = "分数id(三个区间)", mod= all} ,#f_column{type = int, name = money, desc = "礼包金额", mod= all} ]} ,{["礼包布局"],[ #f_column{type = int, name = layout, desc = "布局", mod= client} ,#f_column{type = int, name = gift_id, desc = "礼包id", primary = true, mod = all} ,#f_column{type = bstr, name = content_img, desc = "文本图片层", mod= client} ,#f_column{type = bstr, name = bg, desc = "背景", mod= client} ,#f_column{type = bstr, name = res_id, desc = "伙伴资源id", mod= client} ,#f_column{type = bstr, name = desc, desc = "描述", mod= client} ,#f_column{type = bstr, name = action, desc = "动作名", mod= client} ,#f_column{type = bstr, name = name, desc = "描述", mod= client} ]} ] }.