1 | <?php |
||
12 | trait Followable |
||
13 | { |
||
14 | use HandlesRequestAndResponse, HasEntityIdName; |
||
15 | /** |
||
16 | * Follow user by user_id. |
||
17 | * |
||
18 | * @param $entityId |
||
19 | * |
||
20 | * @return bool |
||
21 | */ |
||
22 | public function follow($entityId) |
||
26 | |||
27 | /** |
||
28 | * UnFollow user by user_id. |
||
29 | * |
||
30 | * @param $entityId |
||
31 | * |
||
32 | * @return bool |
||
33 | */ |
||
34 | public function unFollow($entityId) |
||
38 | |||
39 | /** |
||
40 | * Make api call for follow/unFollow a entity (user/board). |
||
41 | * |
||
42 | * @param int $entityId |
||
43 | * @param string $resourceUrl |
||
44 | * |
||
45 | * @return bool |
||
46 | */ |
||
47 | protected function followCall($entityId, $resourceUrl) |
||
53 | |||
54 | /** |
||
55 | * @return string |
||
56 | */ |
||
57 | protected function getFollowUrl() |
||
61 | |||
62 | /** |
||
63 | * @return string |
||
64 | */ |
||
65 | protected function getUnFollowUrl() |
||
69 | } |
||
70 |