1
This commit is contained in:
parent
e1ed493313
commit
1e03c45df2
@ -44,9 +44,8 @@ class IndexController extends BaseApiController
|
|||||||
|
|
||||||
public function index()
|
public function index()
|
||||||
{
|
{
|
||||||
$now_money=$this->request->get('money');
|
|
||||||
$a= (new User())->update(['now_money'=>$now_money],['id'=>366]);
|
return json(1);
|
||||||
return json($a);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -198,12 +198,10 @@ class User extends BaseModel
|
|||||||
|
|
||||||
public static function onBeforeWrite($data)
|
public static function onBeforeWrite($data)
|
||||||
{
|
{
|
||||||
var_dump($data->toArray());
|
channelLog($data->getData()??[], 'user', '更新前');
|
||||||
channelLog($data->toArray()??[], 'user', '更新前');
|
|
||||||
}
|
}
|
||||||
public static function onAfterWrite($data)
|
public static function onAfterWrite($data)
|
||||||
{
|
{
|
||||||
var_dump($data->toArray());
|
|
||||||
|
|
||||||
channelLog($data->toArray()??[], 'user', '更新后');
|
channelLog($data->toArray()??[], 'user', '更新后');
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user