Skip to content

Commit

Permalink
Merge pull request #201 from Meraj-Webkul/v1.3.2
Browse files Browse the repository at this point in the history
updated to v1.3.2
  • Loading branch information
vivek-webkul authored Sep 27, 2021
2 parents 1f1037b + f351c24 commit a8f84ce
Show file tree
Hide file tree
Showing 8 changed files with 74 additions and 18 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG for v1.3.x.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# CHANGELOG for v1.3.0
# CHANGELOG for v1.3.2

#### This changelog consists the bug & security fixes and new features being included in the releases listed below.

## **v1.3.0(31th of March, 2021)** - *Release*
## **v1.3.2(31th of March, 2021)** - *Release*

* [feature] functionality to edit home page layout from admin panel.

Expand Down
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
# CHANGELOG for v0.1.x
# CHANGELOG for v1.3.2

#### This changelog consists the bug & security fixes and new features being included in the releases listed below.

## **v1.3.2(20th of september, 2021)** - *Release*

- [compatible] Bagisto Version v1.3.2.

- [Bug] Dynamic Entries of firebase details.

## **v0.1.5(17th of February, 2020)** - *Release*

- [Bug] Default shipping method and payment method is not selected during checkout.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ It packs with lots of demanding features that allows your business to scale in n

### 2. Requirements:

* **Bagisto**: v1.3.0.
* **Bagisto**: v1.3.2.


### 3. Installation:
Expand Down
2 changes: 1 addition & 1 deletion publishable/pwa/firebase-messaging-sw.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
importScripts('https://www.gstatic.com/firebasejs/4.8.1/firebase-app.js');
importScripts('https://www.gstatic.com/firebasejs/4.8.1/firebase-messaging.js');

firebase.initializeApp({messagingSenderId: '1007045788486'});
firebase.initializeApp({messagingSenderId: "{{core()->getConfigData('pwa.settings.push-notification.messaging-id')}}"});

const messaging = firebase.messaging();

Expand Down
18 changes: 9 additions & 9 deletions publishable/pwa/service-worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -193,22 +193,22 @@ function formFilter(response) {

// Give the service worker access to Firebase Messaging.
// Note that you can only use Firebase Messaging here, other Firebase libraries are not available in the service worker.
importScripts('https://www.gstatic.com/firebasejs/4.8.1/firebase-app.js');
importScripts('https://www.gstatic.com/firebasejs/4.8.1/firebase-messaging.js');
importScripts('http://www.gstatic.com/firebasejs/4.8.1/firebase-app.js');
importScripts('http://www.gstatic.com/firebasejs/4.8.1/firebase-messaging.js');

const firebaseConfig = {
apiKey: "AIzaSyC-HKvgBpSVK27IZdxv5U7s-WDTzODswO8",
authDomain: "laravel-pwa-5c45c.firebaseapp.com",
databaseURL: "https://laravel-pwa-5c45c.firebaseio.com",
projectId: "laravel-pwa-5c45c",
apiKey: "{{core()->getConfigData('pwa.settings.push-notification.web-api-key')}}",
authDomain: "{{core()->getConfigData('pwa.settings.push-notification.auth-domain')}}",
databaseURL: "{{core()->getConfigData('pwa.settings.push-notification.database-url')}}",
projectId: "{{core()->getConfigData('pwa.settings.push-notification.project-id')}}",
storageBucket: "",
messagingSenderId: "444825614301",
appId: "1:444825614301:web:ee31ac20d8c7de3e"
messagingSenderId: "{{core()->getConfigData('pwa.settings.push-notification.messaging-id')}}",
appId: "{{core()->getConfigData('pwa.settings.push-notification.app-id')}}"
};

// Initialize the Firebase app in the service worker by passing in themessagingSenderId.
firebase.initializeApp({
'messagingSenderId': '444825614301'
'messagingSenderId': "{{core()->getConfigData('pwa.settings.push-notification.messaging-id')}}"
});

// Retrieve an instance of Firebase Messaging so that it can handle background messages
Expand Down
44 changes: 41 additions & 3 deletions src/Config/system.php
Original file line number Diff line number Diff line change
Expand Up @@ -149,24 +149,62 @@
'name' => 'topic',
'title' => 'pwa::app.admin.system.topic',
'type' => 'text',
'validation' => 'required',
'default' => 'bagisto',
'validation' => 'alpha_num',
'validation' => 'alpha_num|required',
'channel_based' => true,
'locale_based' => true
], [
'name' => 'messaging-id',
'title' => 'pwa::app.admin.system.messagingId',
'type' => 'text',
'validation' => 'numeric',
'validation' => 'required',
'validation' => 'numeric|required',
'channel_based' => true,
'locale_based' => true
], [
'name' => 'api-key',
'title' => 'pwa::app.admin.system.server-key',
'type' => 'password',
'validation' => 'required',
'channel_based' => true,
'locale_based' => false
], [
'name' => 'auth-domain',
'title' => 'pwa::app.admin.system.auth-domain',
'type' => 'text',
'validation' => 'required',
'channel_based' => true,
'locale_based' => false
], [
'name' => 'database-url',
'title' => 'pwa::app.admin.system.database-url',
'type' => 'text',
'validation' => 'required',
'channel_based' => true,
'locale_based' => false
], [
'name' => 'project-id',
'title' => 'pwa::app.admin.system.project-id',
'type' => 'password',
'validation' => 'required',
'channel_based' => true,
'locale_based' => false
], [
'name' => 'app-id',
'title' => 'pwa::app.admin.system.app-id',
'type' => 'password',
'validation' => 'required',
'channel_based' => true,
'locale_based' => false
], [
'name' => 'web-api-key',
'title' => 'pwa::app.admin.system.api-key',
'type' => 'password',
'validation' => 'required',
'channel_based' => true,
'locale_based' => false
]
],
]
]

Expand Down
3 changes: 3 additions & 0 deletions src/DataGrids/PushNotificationDataGrid.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,20 +67,23 @@ public function addColumns()
public function prepareActions()
{
$this->addAction([
'title' => trans('pwa::app.admin.datagrid.view'),
'type' => 'View',
'route' => 'pwa.pushnotification.edit',
'icon' => 'icon pencil-lg-icon',
'method' => 'GET'
]);

$this->addAction([
'title' => trans('pwa::app.admin.datagrid.delete'),
'type' => 'Delete',
'route' => 'pwa.pushnotification.delete',
'icon' => 'icon trash-icon',
'method' => 'GET'
]);

$this->addAction([
'title' => trans('pwa::app.admin.datagrid.send'),
'type' => 'send',
'route' => 'pwa.pushnotification.pushtofirebase',
'icon' => 'icon bell-icon',
Expand Down
11 changes: 10 additions & 1 deletion src/Resources/lang/en/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,13 @@
'theme-color' => 'Theme Color',
'add_in_pwa' => 'Add in PWA',
'messagingId' => 'Messaging Id',
'api-key' => 'Server API Key',
'api-key' => 'API Key',
'auth-domain' => 'AUTH DOMAIN',
'database-url' => 'DATABASE URL',
'project-id' => 'PROJECT ID',
'app-id' => 'APP ID',
'public-vapid-key' => 'PUBLIC VAPID Key',
'server-key' => 'SERVER Key',
'enable_slider' => 'Enable Slider',
'background-color' => 'Background Color',
'small' => 'App Icon (48x48)',
Expand Down Expand Up @@ -52,6 +58,9 @@
'datagrid' => [
'id' => 'ID',
'title' => 'Title',
'delete' => 'Delete',
'view' => 'View',
'send' => 'Send',
'target-url' => 'Target URL',
'description' => 'Description',
]
Expand Down

0 comments on commit a8f84ce

Please sign in to comment.