This commit is contained in:
CHIEFSOFT\ameye
2024-01-08 12:10:57 -05:00
parent 7e99b01ad0
commit c691824005
2 changed files with 33 additions and 1 deletions
+1
View File
@@ -30,6 +30,7 @@ long WrenchUpdateProfile(CVars in, CVars &out);
long WrenchUpdateAccountTerms(CVars in, CVars &out);
long WrenchUpdateAccountDescription(CVars in, CVars &out);
long WrenchMyPageIntro(CVars in, CVars &out);
long WrenchMyPage(CVars in, CVars &out);
long LogWrenchBoardMember(CVars in, CVars &out);
+32 -1
View File
@@ -497,7 +497,7 @@ long account_calls(CVars in, CVars &out) {
break;
case WRENCHBOARD_ACCOUNT_MYPAGE:
return WrenchMyPage(in, out);
break;
case WRENCHBOARD_ACCOUNT_PAGEINTRO:
@@ -511,6 +511,37 @@ long account_calls(CVars in, CVars &out) {
#define PHP_API_TRANSFER_COMPLETE 200
long WrenchMyPage(CVars in, CVars &out) {
logfmt(logINFO, "WrenchMyPageIntro()");
long ret = PHP_API_BAD_PARAM;
const PGresult *res;
CVars x;
try {
REQ_LONG(in, "member_id", 1, -1);
REQ_STRING(in, "uid", 3, 150, "(.*)");
REQ_STRING(in, "intro", 3, 150, "(.*)");
REQ_STRING(in, "description", 3, 150, "(.*)");
x["intro"] = in["intro"];
x["intro"].set_valid(true);
x["description"] = in["description"];
x["description"].set_valid(true);
if ( load_db_record(out, "SELECT d.id AS detail_id,d.* FROM members_detail d "
"LEFT JOIN members m ON m.id =d.member_id "
"WHERE d.member_id=%lu AND m.uid='%s' AND active = 1 ", in["member_id"].Long(), in["uid"].c_str()) > 0){
}
else{
ret = PHP_API_OK;
}
} catch (bad_parameter) {
out["status"] = "ERROR";
}
return ret;
}
long WrenchMyPageIntro(CVars in, CVars &out) {
logfmt(logINFO, "WrenchMyPageIntro()");