Skip to content

Commit

Permalink
fix view path + readme
Browse files Browse the repository at this point in the history
  • Loading branch information
uyab committed Dec 14, 2021
1 parent b748ec2 commit 5623634
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ composer require laravolt/metabase

Add following entries to `config/services.php`:
```php
'metabase' => [
'url' => env('METABASE_URL'),
'secret' => env('METABASE_SECRET'),
],
'metabase' => [
'url' => env('METABASE_URL'),
'secret' => env('METABASE_SECRET'),
],
```

And finally, update your `.env` file:
Expand All @@ -29,6 +29,10 @@ METABASE_SECRET=secret

## Common Problems
### Embedding is not enabled for this object.
TODO
Solution: https://www.metabase.com/learn/embedding/embedding-charts-and-dashboards

### Not found.
Solution: make sure your dashboard or question ID was correct

### Message seems corrupt or manipulated.
Solution: check your secret key.
4 changes: 4 additions & 0 deletions src/MetabaseServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ class MetabaseServiceProvider extends ServiceProvider
*/
public function boot(): void
{
$viewPath = __DIR__.'/../resources/views';
$this->loadViewsFrom($viewPath, 'metabase');
$this->publishes([$viewPath => resource_path('views/vendor/metabase')]);

Blade::component('metabase', MetabaseComponent::class);
}
}

0 comments on commit 5623634

Please sign in to comment.