Sha256: 1311abc53b515426911554f0f9275d44c5cec1b68e9ff98f948067a0d6dc4329
Contents?: true
Size: 1015 Bytes
Versions: 9
Compression:
Stored size: 1015 Bytes
Contents
'use strict'; angular.module('apiDocoApp') .controller('DocumentationController', ['$scope', '$window', function ($scope, $window) { $scope.navigateToCurrentVersion = function (versionName) { var version = $scope.documentationVersions.filter(function(v) { return v.name === versionName; })[0]; $window.location.href = version.path; }; $scope.versionAddress = function () { return $window.location.href.split('#')[0]; }; $scope.viewRaw = function(data) { var dataStingified = JSON.stringify(data, null, 2); var x = window.open(); x.document.open(); x.document.write('<html><body><pre>' + dataStingified + '</pre></body></html>'); x.document.close(); }; $scope.initMenuToggle = function() { $(document).ready(function () { $("#menu-toggle").click(function(e) { e.preventDefault(); $("#wrapper").toggleClass("toggled"); }); }); }; $scope.init = function () { $scope.initMenuToggle(); }; $scope.init(); }]);
Version data entries
9 entries across 9 versions & 1 rubygems