2
0
Fork 0

WIP open file for a while

This commit is contained in:
Willem 2017-06-10 16:53:29 +02:00
parent f937019e42
commit d280fb9af3
122 changed files with 5702 additions and 10 deletions

View file

@ -0,0 +1,31 @@
'use strict';
//
// Auto generated controller server router controller
//
crudRouteInit.push(function ($routeProvider, $locationProvider) {
$routeProvider.when('/ui/server/routes', {
redirectTo: '/ui/server/routes/tech',
});
$routeProvider.when('/ui/server/routes/tech', {
templateUrl: '<%= troot.tmeta.tserver.tslugs.tbase %>/<%= troot.tmeta.tserver.tslugs.tplugin %>/uiAngularServerRoutes/thtml/routes?group1=all,api_server,api_plugin,tentity_rss,tentity_json&group2=tentity_csv,tentity_xml,tentity_angular,tentity_config',
controller: XPageServerTechRoutes,
});
$routeProvider.when('/ui/server/routes/model', {
templateUrl: '/api/angular/thtml/routes?group1=moviedb,pagila&group2=all',
controller: XPageServerModelRoutes,
});
});
function XPageServerTechRoutes($scope, $http) {
$http.get('<%= troot.tmeta.tserver.tslugs.tbase %>/<%= troot.tmeta.tserver.tslugs.tserver %>/<%= troot.tmeta.tplugin.serverConfigRoutes.tslug %>?groups=api/server,api/plugin,tentity/json,tentity/xml,tentity/rss,tentity/csv,tentity/angular,tentity/config').success(function(data, status, headers, config) {
$scope.serverRoutes = data.data;
});
}
function XPageServerModelRoutes($scope, $http) {
$http.get('<%= troot.tmeta.tserver.tslug %>/json/server/routes?groups=moviedb,pagila').success(function(data, status, headers, config) {
$scope.serverRoutes = data.data;
});
}

View file

@ -0,0 +1,20 @@
<div class="table-responsive">
<h3><%= routeGroup.toUpperCase() %></h3>
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<th>Path</th>
<th>Method</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="route in serverRoutes['<%= routeGroup %>']">
<td ng-if="route.httpMethod!=='GET'">
<a href="{{route.uriPath}}" target="_blank">{{route.uriPath}}<a>
</td>
<td ng-if="route.httpMethod==='GET'">{{route.uriPath}}</td>
<td>{{route.httpMethod}}</td>
</tr>
</tbody>
</table>
</div>

View file

@ -0,0 +1,26 @@
<h2>Server Routes</h2>
<p>This page show all the nodejs express routes.</p>
<div class="">
<% if (query.group1 && query.group2) { %>
<div class="col-lg-6">
<% query.group1.split(',').forEach(function (routeGroup) { %>
<%- include('routes-group', {routeGroup: routeGroup}); %>
<% }) %>
</div>
<div class="col-lg-6">
<% query.group2.split(',').forEach(function (routeGroup) { %>
<%- include('routes-group', {routeGroup: routeGroup}); %>
<% }) %>
</div>
<% } else if (query.group1) { %>
<div class="col-lg-12">
<% query.group1.split(',').forEach(function (routeGroup) { %>
<%- include('routes-group', {routeGroup: routeGroup}); %>
<% }) %>
</div>
<% } else { %>
<div class="col-lg-12">
<%- include('routes-group', {routeGroup: 'all'}); %>
</div>
<% } %>
</div>