Reco family

This commit is contained in:
CHIEFSOFT\ameye
2024-11-07 06:00:54 -05:00
parent 21db457bbc
commit 983973a30d
2 changed files with 65 additions and 3 deletions
+42
View File
@@ -454,6 +454,48 @@ class ResultFormatter extends Model
);
}
break;
case WRENCHBOARD_FAMILY_HOMEBANNERS:
$total = $out["total_record"];
$res = array(
"status" => $out["status"],
"total_record" => ($total - 1),
"internal_return" => $out["internal_return"],
"family_action" => 0,
"home_dash_type" => $out["home_dash_type"],
"result_list" => array(),
);
for ($i = 0; $i < $total; $i++) {
$key = sprintf("%05d", $i);
$banner_action = $out["action_${key}"];
$res["result_list"][] =
[$banner_action =>
["banner" =>
[
"text" => $out["title_${key}"],
"contract" => $out["contract_${key}"],
"card_type" => $out["card_type_${key}"],
"style" => $out["card_style_${key}"],
"description" => $out["description_${key}"],
"blog_id" => $out["blog_id_${key}"],
"card_icon" => $out["card_icon_${key}"],
"offer_id" => $out["offer_id_${key}"],
"image" => $this->fixEmptyBanner( $out["banner_${key}"]),
"banner_location" => $out["banner_location_${key}"],
"link_path" => $out["link_path_${key}"],
"action" => $banner_action,
"button_text" => $out["button_text_${key}"],
"short_button_text" => $out["short_button_text_${key}"],
"short_title" => $out["short_title_${key}"],
"short_description" => $out["short_description_${key}"],
"short_style" => $out["short_style_${key}"],
"status"=> 1
]
]
];
}
break;
case WRENCHBOARD_CONTRACT_MSGLIST:
$total = $out["total_record"];
$res = array(