-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: add shopware 6.6 compatiblity (#24)
- Loading branch information
Showing
9 changed files
with
31 additions
and
71 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -64,3 +64,6 @@ build: | |
assets: | ||
enable_es_build_for_admin: true | ||
enable_es_build_for_storefront: true | ||
|
||
changelog: | ||
enabled: true |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...inistration/src/module/frosh-adminer/page/frosh-adminer-view/frosh-adminer-view.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
17 changes: 16 additions & 1 deletion
17
src/Resources/public/administration/js/frosh-platform-adminer.js
100644 → 100755
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,16 @@ | ||
!function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p=(window.__sw__.assetPath + '/bundles/froshplatformadminer/'),r(r.s="rVCN")}({cgKg:function(e,t){Shopware.Service("privileges").addPrivilegeMappingEntry({category:"additional_permissions",parent:null,key:"system",roles:{frosh_adminer:{privileges:[],dependencies:[]}}})},rVCN:function(e,t,r){"use strict";function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var r=0;r<t.length;r++){var o=t[r];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(i=o.key,a=void 0,a=function(e,t){if("object"!==n(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(i,"string"),"symbol"===n(a)?a:String(a)),o)}var i,a}function a(e,t){return(a=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function u(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=l(e);if(t){var o=l(this).constructor;r=Reflect.construct(n,arguments,o)}else r=n.apply(this,arguments);return c(this,r)}}function c(e,t){if(t&&("object"===n(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}r.r(t);var f=Shopware.Classes.ApiService,s=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&a(e,t)}(l,e);var t,r,n,c=u(l);function l(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"frosh_adminer";return o(this,l),c.call(this,e,t,r)}return t=l,(r=[{key:"loginToAdminer",value:function(){var e="".concat(this.getApiBasePath(),"/login");return this.httpClient.get(e,{headers:this.getBasicHeaders()}).then((function(e){return f.handleResponse(e)}))}}])&&i(t.prototype,r),n&&i(t,n),Object.defineProperty(t,"prototype",{writable:!1}),l}(f),p=Shopware.Application;p.addServiceProvider("AdminerService",(function(e){var t=p.getContainer("init");return new s(t.httpClient,e.loginService)}));r("cgKg");Shopware.Component.register("frosh-adminer-view",{template:'<sw-page class="adminer">\n <template slot="smart-bar-header">\n <h2>Adminer</h2>\n </template>\n\n <template slot="content">\n <iframe v-if="apiAdminerUrl" :src="apiAdminerUrl" width="100%" height="99%" frameborder="0"></iframe>\n </template>\n\n <template slot="smart-bar-actions">\n <sw-button variant="primary" v-if="apiAdminerUrl" @click="openNewTab">\n {{ $tc(\'frosh-adminer.openInNewTab\') }}\n </sw-button>\n </template>\n</sw-page>\n',inject:["AdminerService"],created:function(){this.createdComponent()},data:function(){return{apiAdminerUrl:!1}},methods:{createdComponent:function(){var e=this;this.AdminerService.loginToAdminer().then((function(t){e.apiAdminerUrl=t.url}))},openNewTab:function(){window.open(this.apiAdminerUrl)}}}),Shopware.Module.register("frosh-adminer",{type:"plugin",name:"frosh-adminer.title",description:"frosh-adminer.title",color:"#9AA8B5",icon:"regular-database",favicon:"icon-module-settings.png",routes:{list:{component:"frosh-adminer-view",path:"list",privilege:"system.frosh_adminer"}},settingsItem:[{group:"plugins",to:"frosh.adminer.list",icon:"regular-database",label:"frosh-adminer.title",privilege:"system.frosh_adminer"}],extensionEntryRoute:{extensionName:"FroshPlatformAdminer",route:"frosh.adminer.list"}})}}); | ||
(()=>{var n=Shopware.Classes.ApiService,t=class extends n{constructor(e,i,m="frosh_adminer"){super(e,i,m)}loginToAdminer(){let e=`${this.getApiBasePath()}/login`;return this.httpClient.get(e,{headers:this.getBasicHeaders()}).then(i=>n.handleResponse(i))}},a=t;var{Application:o}=Shopware;o.addServiceProvider("AdminerService",r=>{let e=o.getContainer("init");return new a(e.httpClient,r.loginService)});Shopware.Service("privileges").addPrivilegeMappingEntry({category:"additional_permissions",parent:null,key:"system",roles:{frosh_adminer:{privileges:[],dependencies:[]}}});var s=`<sw-page class="adminer"> | ||
<template #smart-bar-header> | ||
<h2>Adminer</h2> | ||
</template> | ||
<template #content> | ||
<iframe v-if="apiAdminerUrl" :src="apiAdminerUrl" width="100%" height="99%" frameborder="0"></iframe> | ||
</template> | ||
<template #smart-bar-actions> | ||
<sw-button variant="primary" v-if="apiAdminerUrl" @click="openNewTab"> | ||
{{ $tc('frosh-adminer.openInNewTab') }} | ||
</sw-button> | ||
</template> | ||
</sw-page> | ||
`;var{Component:d}=Shopware;d.register("frosh-adminer-view",{template:s,inject:["AdminerService"],created(){this.createdComponent()},data(){return{apiAdminerUrl:!1}},methods:{createdComponent(){this.AdminerService.loginToAdminer().then(r=>{this.apiAdminerUrl=r.url})},openNewTab(){window.open(this.apiAdminerUrl)}}});var{Module:l}=Shopware;l.register("frosh-adminer",{type:"plugin",name:"frosh-adminer.title",description:"frosh-adminer.title",color:"#9AA8B5",icon:"regular-database",favicon:"icon-module-settings.png",routes:{list:{component:"frosh-adminer-view",path:"list",privilege:"system.frosh_adminer"}},settingsItem:[{group:"plugins",to:"frosh.adminer.list",icon:"regular-database",label:"frosh-adminer.title",privilege:"system.frosh_adminer"}],extensionEntryRoute:{extensionName:"FroshPlatformAdminer",route:"frosh.adminer.list"}});})(); |