cacher data
This commit is contained in:
@@ -571,10 +571,28 @@ class WrenchApi extends BaseController
|
||||
$out = $local_out;
|
||||
}
|
||||
|
||||
$this->doCacheStep($in, $out);
|
||||
return json_encode( ( new \App\Models\ResultFormatter() )->processOutJson($in, $out));
|
||||
|
||||
}
|
||||
|
||||
private function doCacheStep($in, $out){
|
||||
|
||||
switch ($in["action"]) {
|
||||
case WRENCHBOARD_ACCOUNT_LOGIN:
|
||||
$endpoint = "SESSION-".$out["sessionid"];
|
||||
$this->saveCache($endpoint,$out);
|
||||
break;
|
||||
}
|
||||
// $endpoint = "WRENCH_BLOG_DATA";
|
||||
// $res1 = $this->getCache($endpoint);
|
||||
// if (count($res1)==0){
|
||||
// $rawData = $this->apiData();
|
||||
// $res1= $rawData['payload']; //[0]['payload'];
|
||||
// $this->saveCache($endpoint,$res1);
|
||||
// }
|
||||
return 0;
|
||||
}
|
||||
private function procOfferInterest($in) {
|
||||
$proc = $in['proc'];
|
||||
$in['interest'] = 0;
|
||||
|
||||
Reference in New Issue
Block a user