mirror of
https://github.com/grocy/grocy.git
synced 2026-04-05 20:36:15 +02:00
This commit's contents were auto-generated. They wrap all viewjs
in functions and define a common prologue.
New file contents:
```js
function VIEWNAMEView(Grocy, scope = null)
{
var $scope = $;
if(scope != null)
{
$scope = $(scope).find;
}
// original contents indented with \t
}
```
38 lines
648 B
JavaScript
38 lines
648 B
JavaScript
function openapiuiView(Grocy, scope = null)
|
|
{
|
|
var $scope = $;
|
|
if (scope != null)
|
|
{
|
|
$scope = $(scope).find;
|
|
}
|
|
|
|
/* global SwaggerUIBundle, SwaggerUIStandalonePreset */
|
|
function HideTopbarPlugin()
|
|
{
|
|
return {
|
|
components: {
|
|
Topbar: function() { return null }
|
|
}
|
|
}
|
|
}
|
|
|
|
const swaggerUi = SwaggerUIBundle({
|
|
url: Grocy.OpenApi.SpecUrl,
|
|
dom_id: '#swagger-ui',
|
|
deepLinking: true,
|
|
presets: [
|
|
SwaggerUIBundle.presets.apis,
|
|
SwaggerUIStandalonePreset
|
|
],
|
|
plugins: [
|
|
SwaggerUIBundle.plugins.DownloadUrl,
|
|
HideTopbarPlugin
|
|
],
|
|
layout: 'StandaloneLayout',
|
|
docExpansion: "list"
|
|
});
|
|
|
|
window.ui = swaggerUi;
|
|
|
|
}
|