Skip to content

Commit

Permalink
Merge pull request #51 from suraj-webkul/compatible-to-2.0.0
Browse files Browse the repository at this point in the history
Compatible to 2.0.0
  • Loading branch information
devansh-webkul authored Sep 25, 2024
2 parents c39145b + 7a7f63e commit dbfb1fd
Show file tree
Hide file tree
Showing 80 changed files with 2,159 additions and 991 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## **v2.0.0 (25th of September 2024)**

* [compatible] Compatible to krayin v2.0.0.

## **v1.0.1 (25th of September 2024)**

* #47 [fixed] If the admin is clicking on the google icon then the app locale is getting changes automatically.
Expand Down
60 changes: 47 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ It packs in lots of demanding features that allows your business to scale in no

### 2. Requirements:

* **Krayin**: v1.2.1 or higher.
* **Krayin**: v2.0.0 or higher.


### 3. Installation:
Expand All @@ -35,15 +35,48 @@ php artisan route:cache
~~~

~~~
php artisan vendor:publish
php artisan vendor:publish --force
-> Press 0 and then press enter to publish all assets and configurations.
-> Search GoogleServiceProvider navigate to it and then press enter to publish all assets and configurations.
~~~


### 4. Configuration:

* Goto .env file and add following lines
* Goto **routes/breadcrumbs.php** file and add following lines

```php
Breadcrumbs::for('google.calendar.create', function (BreadcrumbTrail $trail) {
$trail->parent('dashboard');
$trail->push(trans('google::app.calendar.index.title'), route('admin.google.index', ['route' => request('route')]));
});

Breadcrumbs::for('google.meet.create', function (BreadcrumbTrail $trail) {
$trail->parent('dashboard');
$trail->push(trans('google::app.meet.index.title'), route('admin.google.index', ['route' => request('route')]));
});
```

* Goto **config/krayin-vite.php** file and add following lines

```php
<?php

return [
'viters' => [
// ...

'google' => [
'hot_file' => 'google-vite.hot',
'build_directory' => 'google/build',
'package_assets_directory' => 'src/Resources/assets',
],
],
];

```

* Goto **.env** file and add following lines

```.env
GOOGLE_CLIENT_ID=
Expand All @@ -52,25 +85,25 @@ GOOGLE_REDIRECT_URI="${APP_URL}/google/oauth"
GOOGLE_WEBHOOK_URI="${APP_URL}/google/webhook"
```

* Goto config/services.php file and add following lines
* Goto **config/services.php** file and add following lines

```php
return [
// ...

'google' => [
// Our Google API credentials.
'client_id' => env('GOOGLE_CLIENT_ID'),
'client_secret' => env('GOOGLE_CLIENT_SECRET'),
'client_id' => env('GOOGLE_CLIENT_ID'),
'client_secret' => env('GOOGLE_CLIENT_SECRET'),

// The URL to redirect to after the OAuth process.
'redirect_uri' => env('GOOGLE_REDIRECT_URI'),
'redirect_uri' => env('GOOGLE_REDIRECT_URI'),

// The URL that listens to Google webhook notifications (Part 3).
'webhook_uri' => env('GOOGLE_WEBHOOK_URI'),
'webhook_uri' => env('GOOGLE_WEBHOOK_URI'),

// Let the user know what we will be using from his Google account.
'scopes' => [
'scopes' => [
// Getting access to the user's email.
\Google_Service_Oauth2::USERINFO_EMAIL,

Expand All @@ -80,23 +113,24 @@ return [

// Enables automatic token refresh.
'approval_prompt' => 'force',
'access_type' => 'offline',
'access_type' => 'offline',

// Enables incremental scopes (useful if in the future we need access to another type of data).
'include_granted_scopes' => true,
],
];
```

* Goto app/Http/Middleware/VerifyCsrfToken.php file and add following line under $except array
* Goto **app/Http/Middleware/VerifyCsrfToken.php** file and add following line under $except array

```php
protected $except = [
// ...
'google/webhook',
];
```

* Goto app/Console/Kernel.php file and update the schedule function with the following lines
* Goto **app/Console/Kernel.php** file and update the schedule function with the following lines

```php
protected function schedule(Schedule $schedule)
Expand Down
42 changes: 18 additions & 24 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,25 +1,19 @@
{
"private": true,
"scripts": {
"dev": "npm run development",
"development": "mix",
"watch": "mix watch",
"watch-poll": "mix watch -- --watch-options-poll=1000",
"hot": "mix watch --hot",
"prod": "npm run production",
"production": "mix --production"
},
"devDependencies": {
"cross-env": "^7.0.3",
"laravel-mix": "^6.0.6",
"laravel-mix-merge-manifest": "^2.0.0",
"lodash": "^4.17.19",
"postcss": "^8.1.14",
"sass": "^1.32.8",
"sass-loader": "^11.0.1",
"vue": "^2.6.12",
"vue-loader": "^15.9.6",
"vue-template-compiler": "^2.6.12"
},
"dependencies": {}
}
"private": true,
"scripts": {
"dev": "vite",
"build": "vite build"
},
"devDependencies": {
"autoprefixer": "^10.4.16",
"axios": "^1.6.4",
"laravel-vite-plugin": "^0.7.2",
"postcss": "^8.4.23",
"tailwindcss": "^3.3.2",
"vite": "^4.0.0",
"vue": "^3.4.19"
},
"dependencies": {
"@vitejs/plugin-vue": "^4.2.3"
}
}
6 changes: 6 additions & 0 deletions postcss.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
}
1 change: 1 addition & 0 deletions publishable/assets/build/assets/app-0d3ab032.css
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.icon-google:before{content:""}@font-face{font-family:icomoon;src:url(icomoon-f9134904.woff?w2trdd) format("woff");font-weight:400;font-style:normal;font-display:block}
1 change: 1 addition & 0 deletions publishable/assets/build/assets/app-321a3eb1.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions publishable/assets/build/assets/app-4ed993c7.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

Binary file not shown.
24 changes: 24 additions & 0 deletions publishable/assets/build/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"src/Resources/assets/css/app.css": {
"file": "assets/app-0d3ab032.css",
"isEntry": true,
"src": "src/Resources/assets/css/app.css"
},
"src/Resources/assets/fonts/icomoon.woff": {
"file": "assets/icomoon-f9134904.woff",
"src": "src/Resources/assets/fonts/icomoon.woff"
},
"src/Resources/assets/images/google-calendar-icon.png": {
"file": "assets/google-calendar-icon-058ce74e.png",
"src": "src/Resources/assets/images/google-calendar-icon.png"
},
"src/Resources/assets/images/google-meet-icon.png": {
"file": "assets/google-meet-icon-9a5427aa.png",
"src": "src/Resources/assets/images/google-meet-icon.png"
},
"src/Resources/assets/js/app.js": {
"file": "assets/app-4ed993c7.js",
"isEntry": true,
"src": "src/Resources/assets/js/app.js"
}
}
1 change: 0 additions & 1 deletion publishable/assets/css/admin.css

This file was deleted.

1 change: 0 additions & 1 deletion publishable/assets/images/google-active-icon.svg

This file was deleted.

Loading

0 comments on commit dbfb1fd

Please sign in to comment.