also looking at this
Initial Progress
#2
11 files
+235
-34
Review threads live on the whole diff, not on one commit, so none are shown here - a thread's line means something in the branch's final form, and painting it into an intermediate step would put it on code it is not about.
| @@ -9,7 +9,7 @@ interface FolderInterface | ||
| 9 | 9 | * |
| 10 | 10 | * @return array |
| 11 | 11 | */ |
| 12 | public function all(): array; | |
| 12 | public static function all(): array; | |
| 13 | 13 | |
| 14 | 14 | /** |
| 15 | 15 | * Get specific folders. |
| @@ -18,7 +18,7 @@ interface FolderInterface | ||
| 18 | 18 | * |
| 19 | 19 | * @return array |
| 20 | 20 | */ |
| 21 | public function get($id = null): array; | |
| 21 | public static function get($id = null): array; | |
| 22 | 22 | |
| 23 | 23 | /** |
| 24 | 24 | * Search for specific folders. |
| @@ -27,7 +27,7 @@ interface FolderInterface | ||
| 27 | 27 | * |
| 28 | 28 | * @return array |
| 29 | 29 | */ |
| 30 | public function search($query): array; | |
| 30 | public static function search($query): array; | |
| 31 | 31 | |
| 32 | 32 | /** |
| 33 | 33 | * Get specific folders. |
| @@ -36,7 +36,7 @@ interface FolderInterface | ||
| 36 | 36 | * |
| 37 | 37 | * @return Response |
| 38 | 38 | */ |
| 39 | public function find($id): array; | |
| 39 | public static function find($id): array; | |
| 40 | 40 | |
| 41 | 41 | /** |
| 42 | 42 | * Create folder. |
| @@ -45,7 +45,7 @@ interface FolderInterface | ||
| 45 | 45 | * |
| 46 | 46 | * @return array |
| 47 | 47 | */ |
| 48 | public function create($name): array; | |
| 48 | public static function create($name): array; | |
| 49 | 49 | |
| 50 | 50 | /** |
| 51 | 51 | * Update folder. |
| @@ -55,7 +55,7 @@ interface FolderInterface | ||
| 55 | 55 | * |
| 56 | 56 | * @return array |
| 57 | 57 | */ |
| 58 | public function update($id, $name): array; | |
| 58 | public static function update($id, $name): array; | |
| 59 | 59 | |
| 60 | 60 | /** |
| 61 | 61 | * Delete a folder. |
| @@ -64,7 +64,7 @@ interface FolderInterface | ||
| 64 | 64 | * |
| 65 | 65 | * @return null |
| 66 | 66 | */ |
| 67 | public function delete($ids); | |
| 67 | public static function delete($ids); | |
| 68 | 68 | |
| 69 | 69 | /** |
| 70 | 70 | * Archive a folder. |
| @@ -73,7 +73,7 @@ interface FolderInterface | ||
| 73 | 73 | * |
| 74 | 74 | * @return array |
| 75 | 75 | */ |
| 76 | public function archive($ids): array; | |
| 76 | public static function archive($ids): array; | |
| 77 | 77 | |
| 78 | 78 | /** |
| 79 | 79 | * Unarchive a folder. |
| @@ -82,7 +82,7 @@ interface FolderInterface | ||
| 82 | 82 | * |
| 83 | 83 | * @return array |
| 84 | 84 | */ |
| 85 | public function unarchive($ids): array; | |
| 85 | public static function unarchive($ids): array; | |
| 86 | 86 | |
| 87 | 87 | /** |
| 88 | 88 | * Duplicate a folder. |
| @@ -91,5 +91,5 @@ interface FolderInterface | ||
| 91 | 91 | * |
| 92 | 92 | * @return array |
| 93 | 93 | */ |
| 94 | public function duplicate($ids): array; | |
| 94 | public static function duplicate($ids): array; | |
| 95 | 95 | } |
| @@ -9,7 +9,7 @@ interface MediaInterface | ||
| 9 | 9 | * |
| 10 | 10 | * @return array |
| 11 | 11 | */ |
| 12 | public function all(): array; | |
| 12 | public static function all(): array; | |
| 13 | 13 | |
| 14 | 14 | /** |
| 15 | 15 | * Get specific media. |
| @@ -18,7 +18,7 @@ interface MediaInterface | ||
| 18 | 18 | * |
| 19 | 19 | * @return array |
| 20 | 20 | */ |
| 21 | public function get($ids = null): array; | |
| 21 | public static function get($ids = null): array; | |
| 22 | 22 | |
| 23 | 23 | /** |
| 24 | 24 | * Search for specific media. |
| @@ -27,7 +27,7 @@ interface MediaInterface | ||
| 27 | 27 | * |
| 28 | 28 | * @return array |
| 29 | 29 | */ |
| 30 | public function search($query): array; | |
| 30 | public static function search($query): array; | |
| 31 | 31 | |
| 32 | 32 | /** |
| 33 | 33 | * Get specific media. |
| @@ -36,7 +36,7 @@ interface MediaInterface | ||
| 36 | 36 | * |
| 37 | 37 | * @return array |
| 38 | 38 | */ |
| 39 | public function find($id): array; | |
| 39 | public static function find($id): array; | |
| 40 | 40 | |
| 41 | 41 | /** |
| 42 | 42 | * Create media. |
| @@ -45,7 +45,7 @@ interface MediaInterface | ||
| 45 | 45 | * |
| 46 | 46 | * @return array |
| 47 | 47 | */ |
| 48 | public function create($name): array; | |
| 48 | public static function create($name): array; | |
| 49 | 49 | |
| 50 | 50 | /** |
| 51 | 51 | * Update media. |
| @@ -55,7 +55,7 @@ interface MediaInterface | ||
| 55 | 55 | * |
| 56 | 56 | * @return array |
| 57 | 57 | */ |
| 58 | public function update($id, $name): array; | |
| 58 | public static function update($id, $name): array; | |
| 59 | 59 | |
| 60 | 60 | /** |
| 61 | 61 | * Delete a media. |
| @@ -64,7 +64,7 @@ interface MediaInterface | ||
| 64 | 64 | * |
| 65 | 65 | * @return null |
| 66 | 66 | */ |
| 67 | public function delete($ids); | |
| 67 | public static function delete($ids); | |
| 68 | 68 | |
| 69 | 69 | /** |
| 70 | 70 | * Upload a media file. |
| @@ -73,7 +73,7 @@ interface MediaInterface | ||
| 73 | 73 | * |
| 74 | 74 | * @return array |
| 75 | 75 | */ |
| 76 | public function upload($path): array; | |
| 76 | public static function upload($path): array; | |
| 77 | 77 | |
| 78 | 78 | /** |
| 79 | 79 | * Archive a media. |
| @@ -82,7 +82,7 @@ interface MediaInterface | ||
| 82 | 82 | * |
| 83 | 83 | * @return array |
| 84 | 84 | */ |
| 85 | public function archive($ids): array; | |
| 85 | public static function archive($ids): array; | |
| 86 | 86 | |
| 87 | 87 | /** |
| 88 | 88 | * Unarchive a media. |
| @@ -91,7 +91,7 @@ interface MediaInterface | ||
| 91 | 91 | * |
| 92 | 92 | * @return array |
| 93 | 93 | */ |
| 94 | public function unarchive($ids): array; | |
| 94 | public static function unarchive($ids): array; | |
| 95 | 95 | |
| 96 | 96 | /** |
| 97 | 97 | * Make a media private. |
| @@ -100,7 +100,7 @@ interface MediaInterface | ||
| 100 | 100 | * |
| 101 | 101 | * @return array |
| 102 | 102 | */ |
| 103 | public function makePrivate($ids): array; | |
| 103 | public static function makePrivate($ids): array; | |
| 104 | 104 | |
| 105 | 105 | /** |
| 106 | 106 | * Make a media public. |
| @@ -109,7 +109,7 @@ interface MediaInterface | ||
| 109 | 109 | * |
| 110 | 110 | * @return array |
| 111 | 111 | */ |
| 112 | public function makePublic($ids): array; | |
| 112 | public static function makePublic($ids): array; | |
| 113 | 113 | |
| 114 | 114 | /** |
| 115 | 115 | * Duplicate a media. |
| @@ -118,5 +118,5 @@ interface MediaInterface | ||
| 118 | 118 | * |
| 119 | 119 | * @return array |
| 120 | 120 | */ |
| 121 | public function duplicate($ids): array; | |
| 121 | public static function duplicate($ids): array; | |
| 122 | 122 | } |
| @@ -9,7 +9,7 @@ interface TagInterface | ||
| 9 | 9 | * |
| 10 | 10 | * @return array |
| 11 | 11 | */ |
| 12 | public function all(): array; | |
| 12 | public static function all(): array; | |
| 13 | 13 | |
| 14 | 14 | /** |
| 15 | 15 | * Get specific tags. |
| @@ -18,7 +18,7 @@ interface TagInterface | ||
| 18 | 18 | * |
| 19 | 19 | * @return array |
| 20 | 20 | */ |
| 21 | public function get($ids = null): array; | |
| 21 | public static function get($ids = null): array; | |
| 22 | 22 | |
| 23 | 23 | /** |
| 24 | 24 | * Get specific tags. |
| @@ -27,7 +27,7 @@ interface TagInterface | ||
| 27 | 27 | * |
| 28 | 28 | * @return array |
| 29 | 29 | */ |
| 30 | public function find($id): array; | |
| 30 | public static function find($id): array; | |
| 31 | 31 | |
| 32 | 32 | /** |
| 33 | 33 | * Update a tag color. |
| @@ -37,7 +37,7 @@ interface TagInterface | ||
| 37 | 37 | * |
| 38 | 38 | * @return array |
| 39 | 39 | */ |
| 40 | public function update($id, $color): array; | |
| 40 | public static function update($id, $color): array; | |
| 41 | 41 | |
| 42 | 42 | /** |
| 43 | 43 | * Delete tags. |
| @@ -46,5 +46,5 @@ interface TagInterface | ||
| 46 | 46 | * |
| 47 | 47 | * @return null |
| 48 | 48 | */ |
| 49 | public function delete($ids); | |
| 49 | public static function delete($ids); | |
| 50 | 50 | } |
| @@ -3,7 +3,7 @@ | ||
| 3 | 3 | namespace Meema\LaravelMeema\Facades; |
| 4 | 4 | |
| 5 | 5 | use Illuminate\Support\Facades\Facade; |
| 6 | use Meema\LaravelMeema\Contracts\FavoriteInterface; | |
| 6 | use Meema\LaravelMeema\Models\Favorite; | |
| 7 | 7 | |
| 8 | 8 | class MeemaFavorite extends Facade |
| 9 | 9 | { |
| @@ -14,6 +14,6 @@ class MeemaFavorite extends Facade | ||
| 14 | 14 | */ |
| 15 | 15 | protected static function getFacadeAccessor() |
| 16 | 16 | { |
| 17 | return FavoriteInterface::class; | |
| 17 | return Favorite::class; | |
| 18 | 18 | } |
| 19 | 19 | } |
| @@ -3,7 +3,7 @@ | ||
| 3 | 3 | namespace Meema\LaravelMeema\Facades; |
| 4 | 4 | |
| 5 | 5 | use Illuminate\Support\Facades\Facade; |
| 6 | use Meema\LaravelMeema\Contracts\FolderInterface; | |
| 6 | use Meema\LaravelMeema\Models\Folder; | |
| 7 | 7 | |
| 8 | 8 | class MeemaFolder extends Facade |
| 9 | 9 | { |
| @@ -14,6 +14,6 @@ class MeemaFolder extends Facade | ||
| 14 | 14 | */ |
| 15 | 15 | protected static function getFacadeAccessor() |
| 16 | 16 | { |
| 17 | return FolderInterface::class; | |
| 17 | return Folder::class; | |
| 18 | 18 | } |
| 19 | 19 | } |
| @@ -3,7 +3,7 @@ | ||
| 3 | 3 | namespace Meema\LaravelMeema\Facades; |
| 4 | 4 | |
| 5 | 5 | use Illuminate\Support\Facades\Facade; |
| 6 | use Meema\LaravelMeema\Contracts\MediaInterface; | |
| 6 | use Meema\LaravelMeema\Models\Media; | |
| 7 | 7 | |
| 8 | 8 | class MeemaMedia extends Facade |
| 9 | 9 | { |
| @@ -14,6 +14,6 @@ class MeemaMedia extends Facade | ||
| 14 | 14 | */ |
| 15 | 15 | protected static function getFacadeAccessor() |
| 16 | 16 | { |
| 17 | return MediaInterface::class; | |
| 17 | return Media::class; | |
| 18 | 18 | } |
| 19 | 19 | } |
| @@ -3,7 +3,7 @@ | ||
| 3 | 3 | namespace Meema\LaravelMeema\Facades; |
| 4 | 4 | |
| 5 | 5 | use Illuminate\Support\Facades\Facade; |
| 6 | use Meema\LaravelMeema\Contracts\TagInterface; | |
| 6 | use Meema\LaravelMeema\Models\Tag; | |
| 7 | 7 | |
| 8 | 8 | class MeemaTag extends Facade |
| 9 | 9 | { |
| @@ -14,6 +14,6 @@ class MeemaTag extends Facade | ||
| 14 | 14 | */ |
| 15 | 15 | protected static function getFacadeAccessor() |
| 16 | 16 | { |
| 17 | return TagInterface::class; | |
| 17 | return Tag::class; | |
| 18 | 18 | } |
| 19 | 19 | } |
| @@ -0,0 +1,79 @@ | ||
| 1 | <?php | |
| 2 | ||
| 3 | namespace Meema\LaravelMeema\Models; | |
| 4 | ||
| 5 | use Meema\LaravelMeema\Contracts\FavoriteInterface; | |
| 6 | ||
| 7 | class Favorite implements FavoriteInterface | |
| 8 | { | |
| 9 | /** | |
| 10 | * List all favorites. | |
| 11 | * | |
| 12 | * @return array | |
| 13 | */ | |
| 14 | public function all(): array | |
| 15 | { | |
| 16 | return []; | |
| 17 | } | |
| 18 | ||
| 19 | /** | |
| 20 | * Get specific favorites. | |
| 21 | * | |
| 22 | * @param array $ids | |
| 23 | * | |
| 24 | * @return array | |
| 25 | */ | |
| 26 | public function get($ids = null): array | |
| 27 | { | |
| 28 | return []; | |
| 29 | } | |
| 30 | ||
| 31 | /** | |
| 32 | * Get specific favorites. | |
| 33 | * | |
| 34 | * @param int $id | |
| 35 | * | |
| 36 | * @return array | |
| 37 | */ | |
| 38 | public function find($id): array | |
| 39 | { | |
| 40 | return []; | |
| 41 | } | |
| 42 | ||
| 43 | /** | |
| 44 | * Create favorite. | |
| 45 | * | |
| 46 | * @param array $data | |
| 47 | * | |
| 48 | * @return array | |
| 49 | */ | |
| 50 | public function create($data): array | |
| 51 | { | |
| 52 | return []; | |
| 53 | } | |
| 54 | ||
| 55 | /** | |
| 56 | * Update favorite. | |
| 57 | * | |
| 58 | * @param int $id | |
| 59 | * @param string $data | |
| 60 | * | |
| 61 | * @return array | |
| 62 | */ | |
| 63 | public function update($id, $data): array | |
| 64 | { | |
| 65 | return []; | |
| 66 | } | |
| 67 | ||
| 68 | /** | |
| 69 | * Delete a favorite. | |
| 70 | * | |
| 71 | * @param array $ids | |
| 72 | * | |
| 73 | * @return null | |
| 74 | */ | |
| 75 | public function delete($ids) | |
| 76 | { | |
| 77 | return; | |
| 78 | } | |
| 79 | } | |
| @@ -1,15 +1,20 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | namespace Meema\LaravelMeema\Contracts; | |
| 3 | namespace Meema\LaravelMeema\Models; | |
| 4 | 4 | |
| 5 | interface FolderInterface | |
| 5 | use Meema\LaravelMeema\Contracts\FolderInterface; | |
| 6 | ||
| 7 | class Folder implements FolderInterface | |
| 6 | 8 | { |
| 7 | 9 | /** |
| 8 | 10 | * List all folders. |
| 9 | 11 | * |
| 10 | 12 | * @return array |
| 11 | 13 | */ |
| 12 | public function all(): array; | |
| 14 | public static function all(): array | |
| 15 | { | |
| 16 | return []; | |
| 17 | } | |
| 13 | 18 | |
| 14 | 19 | /** |
| 15 | 20 | * Get specific folders. |
| @@ -18,7 +23,10 @@ interface FolderInterface | ||
| 18 | 23 | * |
| 19 | 24 | * @return array |
| 20 | 25 | */ |
| 21 | public function get($id = null): array; | |
| 26 | public static function get($id = null): array | |
| 27 | { | |
| 28 | return []; | |
| 29 | } | |
| 22 | 30 | |
| 23 | 31 | /** |
| 24 | 32 | * Search for specific folders. |
| @@ -27,7 +35,10 @@ interface FolderInterface | ||
| 27 | 35 | * |
| 28 | 36 | * @return array |
| 29 | 37 | */ |
| 30 | public function search($query): array; | |
| 38 | public static function search($query): array | |
| 39 | { | |
| 40 | return []; | |
| 41 | } | |
| 31 | 42 | |
| 32 | 43 | /** |
| 33 | 44 | * Get specific folders. |
| @@ -36,7 +47,10 @@ interface FolderInterface | ||
| 36 | 47 | * |
| 37 | 48 | * @return Response |
| 38 | 49 | */ |
| 39 | public function find($id): array; | |
| 50 | public static function find($id): array | |
| 51 | { | |
| 52 | return []; | |
| 53 | } | |
| 40 | 54 | |
| 41 | 55 | /** |
| 42 | 56 | * Create folder. |
| @@ -45,7 +59,10 @@ interface FolderInterface | ||
| 45 | 59 | * |
| 46 | 60 | * @return array |
| 47 | 61 | */ |
| 48 | public function create($name): array; | |
| 62 | public static function create($name): array | |
| 63 | { | |
| 64 | return []; | |
| 65 | } | |
| 49 | 66 | |
| 50 | 67 | /** |
| 51 | 68 | * Update folder. |
| @@ -55,7 +72,10 @@ interface FolderInterface | ||
| 55 | 72 | * |
| 56 | 73 | * @return array |
| 57 | 74 | */ |
| 58 | public function update($id, $name): array; | |
| 75 | public static function update($id, $name): array | |
| 76 | { | |
| 77 | return []; | |
| 78 | } | |
| 59 | 79 | |
| 60 | 80 | /** |
| 61 | 81 | * Delete a folder. |
| @@ -64,7 +84,10 @@ interface FolderInterface | ||
| 64 | 84 | * |
| 65 | 85 | * @return null |
| 66 | 86 | */ |
| 67 | public function delete($ids); | |
| 87 | public static function delete($ids) | |
| 88 | { | |
| 89 | return; | |
| 90 | } | |
| 68 | 91 | |
| 69 | 92 | /** |
| 70 | 93 | * Archive a folder. |
| @@ -73,7 +96,10 @@ interface FolderInterface | ||
| 73 | 96 | * |
| 74 | 97 | * @return array |
| 75 | 98 | */ |
| 76 | public function archive($ids): array; | |
| 99 | public static function archive($ids): array | |
| 100 | { | |
| 101 | return []; | |
| 102 | } | |
| 77 | 103 | |
| 78 | 104 | /** |
| 79 | 105 | * Unarchive a folder. |
| @@ -82,7 +108,10 @@ interface FolderInterface | ||
| 82 | 108 | * |
| 83 | 109 | * @return array |
| 84 | 110 | */ |
| 85 | public function unarchive($ids): array; | |
| 111 | public static function unarchive($ids): array | |
| 112 | { | |
| 113 | return []; | |
| 114 | } | |
| 86 | 115 | |
| 87 | 116 | /** |
| 88 | 117 | * Duplicate a folder. |
| @@ -91,5 +120,8 @@ interface FolderInterface | ||
| 91 | 120 | * |
| 92 | 121 | * @return array |
| 93 | 122 | */ |
| 94 | public function duplicate($ids): array; | |
| 123 | public static function duplicate($ids): array | |
| 124 | { | |
| 125 | return []; | |
| 126 | } | |
| 95 | 127 | } |
| @@ -1,15 +1,20 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | namespace Meema\LaravelMeema\Contracts; | |
| 3 | namespace Meema\LaravelMeema\Models; | |
| 4 | 4 | |
| 5 | interface MediaInterface | |
| 5 | use Meema\LaravelMeema\Contracts\MediaInterface; | |
| 6 | ||
| 7 | class Media implements MediaInterface | |
| 6 | 8 | { |
| 7 | 9 | /** |
| 8 | 10 | * List all media. |
| 9 | 11 | * |
| 10 | 12 | * @return array |
| 11 | 13 | */ |
| 12 | public function all(): array; | |
| 14 | public static function all(): array | |
| 15 | { | |
| 16 | return []; | |
| 17 | } | |
| 13 | 18 | |
| 14 | 19 | /** |
| 15 | 20 | * Get specific media. |
| @@ -18,7 +23,10 @@ interface MediaInterface | ||
| 18 | 23 | * |
| 19 | 24 | * @return array |
| 20 | 25 | */ |
| 21 | public function get($ids = null): array; | |
| 26 | public static function get($ids = null): array | |
| 27 | { | |
| 28 | return []; | |
| 29 | } | |
| 22 | 30 | |
| 23 | 31 | /** |
| 24 | 32 | * Search for specific media. |
| @@ -27,7 +35,10 @@ interface MediaInterface | ||
| 27 | 35 | * |
| 28 | 36 | * @return array |
| 29 | 37 | */ |
| 30 | public function search($query): array; | |
| 38 | public static function search($query): array | |
| 39 | { | |
| 40 | return []; | |
| 41 | } | |
| 31 | 42 | |
| 32 | 43 | /** |
| 33 | 44 | * Get specific media. |
| @@ -36,7 +47,10 @@ interface MediaInterface | ||
| 36 | 47 | * |
| 37 | 48 | * @return array |
| 38 | 49 | */ |
| 39 | public function find($id): array; | |
| 50 | public static function find($id): array | |
| 51 | { | |
| 52 | return []; | |
| 53 | } | |
| 40 | 54 | |
| 41 | 55 | /** |
| 42 | 56 | * Create media. |
| @@ -45,7 +59,10 @@ interface MediaInterface | ||
| 45 | 59 | * |
| 46 | 60 | * @return array |
| 47 | 61 | */ |
| 48 | public function create($name): array; | |
| 62 | public static function create($name): array | |
| 63 | { | |
| 64 | return []; | |
| 65 | } | |
| 49 | 66 | |
| 50 | 67 | /** |
| 51 | 68 | * Update media. |
| @@ -55,7 +72,10 @@ interface MediaInterface | ||
| 55 | 72 | * |
| 56 | 73 | * @return array |
| 57 | 74 | */ |
| 58 | public function update($id, $name): array; | |
| 75 | public static function update($id, $name): array | |
| 76 | { | |
| 77 | return []; | |
| 78 | } | |
| 59 | 79 | |
| 60 | 80 | /** |
| 61 | 81 | * Delete a media. |
| @@ -64,7 +84,10 @@ interface MediaInterface | ||
| 64 | 84 | * |
| 65 | 85 | * @return null |
| 66 | 86 | */ |
| 67 | public function delete($ids); | |
| 87 | public static function delete($ids) | |
| 88 | { | |
| 89 | return; | |
| 90 | } | |
| 68 | 91 | |
| 69 | 92 | /** |
| 70 | 93 | * Upload a media file. |
| @@ -73,7 +96,10 @@ interface MediaInterface | ||
| 73 | 96 | * |
| 74 | 97 | * @return array |
| 75 | 98 | */ |
| 76 | public function upload($path): array; | |
| 99 | public static function upload($path): array | |
| 100 | { | |
| 101 | return []; | |
| 102 | } | |
| 77 | 103 | |
| 78 | 104 | /** |
| 79 | 105 | * Archive a media. |
| @@ -82,7 +108,10 @@ interface MediaInterface | ||
| 82 | 108 | * |
| 83 | 109 | * @return array |
| 84 | 110 | */ |
| 85 | public function archive($ids): array; | |
| 111 | public static function archive($ids): array | |
| 112 | { | |
| 113 | return []; | |
| 114 | } | |
| 86 | 115 | |
| 87 | 116 | /** |
| 88 | 117 | * Unarchive a media. |
| @@ -91,7 +120,10 @@ interface MediaInterface | ||
| 91 | 120 | * |
| 92 | 121 | * @return array |
| 93 | 122 | */ |
| 94 | public function unarchive($ids): array; | |
| 123 | public static function unarchive($ids): array | |
| 124 | { | |
| 125 | return []; | |
| 126 | } | |
| 95 | 127 | |
| 96 | 128 | /** |
| 97 | 129 | * Make a media private. |
| @@ -100,7 +132,10 @@ interface MediaInterface | ||
| 100 | 132 | * |
| 101 | 133 | * @return array |
| 102 | 134 | */ |
| 103 | public function makePrivate($ids): array; | |
| 135 | public static function makePrivate($ids): array | |
| 136 | { | |
| 137 | return []; | |
| 138 | } | |
| 104 | 139 | |
| 105 | 140 | /** |
| 106 | 141 | * Make a media public. |
| @@ -109,7 +144,10 @@ interface MediaInterface | ||
| 109 | 144 | * |
| 110 | 145 | * @return array |
| 111 | 146 | */ |
| 112 | public function makePublic($ids): array; | |
| 147 | public static function makePublic($ids): array | |
| 148 | { | |
| 149 | return []; | |
| 150 | } | |
| 113 | 151 | |
| 114 | 152 | /** |
| 115 | 153 | * Duplicate a media. |
| @@ -118,5 +156,8 @@ interface MediaInterface | ||
| 118 | 156 | * |
| 119 | 157 | * @return array |
| 120 | 158 | */ |
| 121 | public function duplicate($ids): array; | |
| 159 | public static function duplicate($ids): array | |
| 160 | { | |
| 161 | return []; | |
| 162 | } | |
| 122 | 163 | } |
| @@ -1,15 +1,20 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | namespace Meema\LaravelMeema\Contracts; | |
| 3 | namespace Meema\LaravelMeema\Models; | |
| 4 | 4 | |
| 5 | interface TagInterface | |
| 5 | use Meema\LaravelMeema\Contracts\TagInterface; | |
| 6 | ||
| 7 | class Tag implements TagInterface | |
| 6 | 8 | { |
| 7 | 9 | /** |
| 8 | 10 | * List all tags. |
| 9 | 11 | * |
| 10 | 12 | * @return array |
| 11 | 13 | */ |
| 12 | public function all(): array; | |
| 14 | public static function all(): array | |
| 15 | { | |
| 16 | return []; | |
| 17 | } | |
| 13 | 18 | |
| 14 | 19 | /** |
| 15 | 20 | * Get specific tags. |
| @@ -18,7 +23,10 @@ interface TagInterface | ||
| 18 | 23 | * |
| 19 | 24 | * @return array |
| 20 | 25 | */ |
| 21 | public function get($ids = null): array; | |
| 26 | public static function get($ids = null): array | |
| 27 | { | |
| 28 | return []; | |
| 29 | } | |
| 22 | 30 | |
| 23 | 31 | /** |
| 24 | 32 | * Get specific tags. |
| @@ -27,7 +35,10 @@ interface TagInterface | ||
| 27 | 35 | * |
| 28 | 36 | * @return array |
| 29 | 37 | */ |
| 30 | public function find($id): array; | |
| 38 | public static function find($id): array | |
| 39 | { | |
| 40 | return []; | |
| 41 | } | |
| 31 | 42 | |
| 32 | 43 | /** |
| 33 | 44 | * Update a tag color. |
| @@ -37,7 +48,10 @@ interface TagInterface | ||
| 37 | 48 | * |
| 38 | 49 | * @return array |
| 39 | 50 | */ |
| 40 | public function update($id, $color): array; | |
| 51 | public static function update($id, $color): array | |
| 52 | { | |
| 53 | return []; | |
| 54 | } | |
| 41 | 55 | |
| 42 | 56 | /** |
| 43 | 57 | * Delete tags. |
| @@ -46,5 +60,8 @@ interface TagInterface | ||
| 46 | 60 | * |
| 47 | 61 | * @return null |
| 48 | 62 | */ |
| 49 | public function delete($ids); | |
| 63 | public static function delete($ids) | |
| 64 | { | |
| 65 | return []; | |
| 66 | } | |
| 50 | 67 | } |