hyperf-view/builder/Generator/Stubs/Controller/numberOperation.stub

17 lines
614 B
Plaintext

/**
* 数字运算操作
* @return ResponseInterface
* @throws \Psr\Container\ContainerExceptionInterface
* @throws \Psr\Container\NotFoundExceptionInterface
*/
#[PutMapping("numberOperation"), Permission("{UPDATE_PERMISSION}"), OperationLog]
public function numberOperation(): ResponseInterface
{
return $this->service->numberOperation(
(int) $this->request->input('{PK}'),
(string) $this->request->input('{NUMBER_FIELD}'),
(int) $this->request->input('{NUMBER_VALUE}', 1),
) ? $this->success() : $this->error();
}