-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlibrary.js
More file actions
47 lines (39 loc) · 1.03 KB
/
Copy pathlibrary.js
File metadata and controls
47 lines (39 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
'use strict';
const controllers = require('./lib/controllers');
const routeHelpers = require('./lib/routeHelpers');
const plugin = module.exports;
plugin.init = async function (params) {
const { router, middleware } = params;
// Setup routes
routeHelpers.setupRoutes(router, middleware);
return;
};
plugin.addAdminNavigation = function (header) {
header.plugins.push({
route: '/plugins/marketplace',
icon: 'fa-shopping-cart',
name: 'Marketplace'
});
return header;
};
plugin.addNavigation = function (header) {
header.navigation.push({
route: '/marketplace',
title: 'Marketplace',
enabled: true,
iconClass: 'fa-shopping-cart',
textClass: 'visible-xs-inline',
text: 'Marketplace'
});
return header;
};
plugin.getAreas = function(areas) {
areas = areas.concat([
{
name: "Marketplace Sidebar",
template: "marketplace/sidebar",
location: "marketplace"
}
]);
return areas;
};