123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117 |
- <?php
- namespace App\JsonRpc;
- use Hyperf\RpcClient\AbstractServiceClient;
- class WebsiteService extends AbstractServiceClient implements WebsiteServiceInterface
- {
- /**
- * 定义对应服务提供者的服务名称
- * @var string
- */
- protected string $serviceName = 'WebsiteService';
- /**
- * 定义对应服务提供者的服务协议
- * @var string
- */
- protected string $protocol = 'jsonrpc-http';
- /**
- * @param string $keyword
- * @param int $page
- * @param int $pageSize
- * @return mixed
- */
- public function getWebsitetList(string $keyword, int $page, int $pageSize)
- {
- return $this->__request(__FUNCTION__, compact('keyword','page','pageSize'));
- }
- /**
- * @param array $data
- * @return mixed
- */
- public function createWebsite(array $data)
- {
- return $this->__request(__FUNCTION__, $data);
- }
- /**
- * @param int $id
- * @param array $data
- * @return mixed
- */
- public function updateWebsite(int $id, array $data)
- {
- return $this->__request(__FUNCTION__,$id, $data);
- }
- /**
- * @param int $id
- * @return mixed
- */
- public function delWebsite(int $id)
- {
- return $this->__request(__FUNCTION__,$id);
- }
- /**
- * @param int $id
- * @return mixed
- */
- public function getWebsiteInfo(int $id)
- {
- return $this->__request(__FUNCTION__,$id);
- }
- /**
- * @param array $data
- * @return array
- */
- public function getWebsiteColumn(array $data): array
- {
- return $this->__request(__FUNCTION__, $data);
- }
- /**
- * @param string $keyword
- * @param int $page
- * @param int $pageSize
- * @return mixed
- */
- public function getWebsiteColumnList(string $keyword, int $page, int $pageSize)
- {
- return $this->__request(__FUNCTION__, compact('keyword','page','pageSize'));
- }
- /**
- * @param array $data
- * @return mixed
- */
- public function createWebsiteColumn(array $data)
- {
- return $this->__request(__FUNCTION__, $data);
- }
- /**
- * @param int $id
- * @param array $data
- * @return mixed
- */
- public function updateWebsiteColumn(int $id, array $data)
- {
- return $this->__request(__FUNCTION__,$id, $data);
- }
- /**
- * @param int $id
- * @return mixed
- */
- public function delWebsiteColumn(int $id)
- {
- return $this->__request(__FUNCTION__,$id);
- }
- }
|