diff --git a/wrenchboard/src/shared_tool/sel_data.cc b/wrenchboard/src/shared_tool/sel_data.cc index 4b5fdc22..68af821a 100644 --- a/wrenchboard/src/shared_tool/sel_data.cc +++ b/wrenchboard/src/shared_tool/sel_data.cc @@ -331,6 +331,9 @@ long getBankCombo( CVars in, CVars &out ) { snprintf(vname, sizeof (vname), "code_%05d", i); out[vname] = rec["code"]; + snprintf(vname, sizeof (vname), "name_%05d", i); + out[vname] = rec["name"]; + } } ret = PHP_API_OK; diff --git a/www-api/public/svs/user/formarter.php b/www-api/public/svs/user/formarter.php index c2cf0136..8aeab249 100755 --- a/www-api/public/svs/user/formarter.php +++ b/www-api/public/svs/user/formarter.php @@ -296,7 +296,22 @@ function processOutJson($in, $out) { } break; - + case WRENCHBOARD_ACCOUNT_COUNTRY_BANKS: + $total = $out["total_record"]; + $res = array( + "status" => $out["status"], + "total_record" => ($total - 1), + "internal_return" => $out["internal_return"], + "result_list" => array(), + ); + for ($i = 0; $i < $total; $i++) { + $key = sprintf("%05d", $i); + $res["result_list"][] = array( + "name" => $out["name_${key}"], + "code" => $out["code_${key}"] + ); + } + break; case WRENCHBOARD_ACCOUNT_WALLETS: $total = $out["total_record"]; $res = array(