Mercurial > repos > eduardo > annotateviz
comparison static/js/gff_app.js @ 0:7537482eed36 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/annotateviz commit 9bbaa3eacc76ff3bf2b6da313cc0d85705f15dd1-dirty
| author | eduardo |
|---|---|
| date | Sat, 17 Jun 2017 13:31:06 -0400 |
| parents | |
| children | 92921dfea0b5 |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:7537482eed36 |
|---|---|
| 1 /** | |
| 2 * Created by wh_admin on 14/06/2017. | |
| 3 */ | |
| 4 var app = angular.module('app', ['ngTouch', 'ui.grid','ui.grid.grouping', 'ui.grid.pagination', 'ui.grid.exporter']); | |
| 5 | |
| 6 app.controller('MainCtrl', ['$scope', '$http', '$interval', 'uiGridGroupingConstants', function ($scope, $http, $interval, uiGridGroupingConstants ){ | |
| 7 $scope.gridOptions = { | |
| 8 enableFiltering: true, | |
| 9 enableGridMenu: true, | |
| 10 enableSelectAll: true, | |
| 11 exporterCsvFilename: 'myFile.csv', | |
| 12 exporterMenuPdf: false, | |
| 13 treeRowHeaderAlwaysVisible: false, | |
| 14 paginationPageSizes: [25, 50], | |
| 15 paginationPageSize: 25, | |
| 16 exporterCsvLinkElement: angular.element(document.querySelectorAll(".custom-csv-link-location")), | |
| 17 //enableHorizontalScrollbar: 0, | |
| 18 //enableVerticalScrollbar: 1, | |
| 19 columnDefs: [ | |
| 20 { name: 'contig', grouping: { groupPriority: 0 }, sort: { priority: 0, direction: 'desc' }, width: '25%', cellTemplate: '<div><div ng-if="!col.grouping || col.grouping.groupPriority === undefined || col.grouping.groupPriority === null || ( row.groupHeader && col.grouping.groupPriority === row.treeLevel )" class="ui-grid-cell-contents" title="TOOLTIP">{{COL_FIELD CUSTOM_FILTERS}}</div></div>' }, | |
| 21 { name: 'mRNA', grouping: { groupPriority: 1 }, sort: { priority: 1,direction: 'desc' }, width: '25%', cellTemplate: '<div><div ng-if="!col.grouping || col.grouping.groupPriority === undefined || col.grouping.groupPriority === null || ( row.groupHeader && col.grouping.groupPriority === row.treeLevel )" class="ui-grid-cell-contents" title="TOOLTIP">{{COL_FIELD CUSTOM_FILTERS}}</div></div>' }, | |
| 22 { name: 'prediction', width: '25%' }, | |
| 23 { name: 'source', width: '10%' }, | |
| 24 { name: 'score', width: '5%'}, | |
| 25 ], | |
| 26 onRegisterApi: function( gridApi ) { | |
| 27 $scope.gridApi = gridApi; | |
| 28 } | |
| 29 }; | |
| 30 | |
| 31 //var baseurl= '/api/datasets/'+hdaId+'?provider=sqlite-dict&data_type=raw_data&query='; | |
| 32 //var select="select%20seqid,seqid,source,featuretype,start,end,score,strand,frame,attributes%20from%20features"; | |
| 33 //var url= baseurl + select; | |
| 34 $http.get('trans.json') | |
| 35 .success (function(response){ | |
| 36 $scope.gridOptions.data = response; | |
| 37 //mygridOptions.totalItems = mygridOptions.data.length; | |
| 38 });//end get_url | |
| 39 }]) |
