This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
var englishTranslations = (function() { | |
var translations = {}; | |
Ext.apply(translations, | |
//duplicates | |
{ | |
something: this.kohive | |
}, | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
filterPanelConfig: { | |
filters: [ | |
{ | |
title: 'Tags', | |
iconCls: 'tag', | |
store: this.albumStore, | |
convert: function(item) { | |
return item.get('tag_list').split(','); | |
} | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @class ExtMVC.view.scaffold.Index | |
* Adds a print button to each grid (remove by setting the hasPrintButton config to false) | |
* | |
* This is an example in support of http://edspencer.net/2009/07/extoverride-monkey-patching-ext-js.html | |
*/ | |
(function() { | |
var originalBuildTopToolbar = ExtMVC.view.scaffold.Index.prototype.buildTopToolbar; | |
Ext.override(ExtMVC.view.scaffold.Index, { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright 2020 Ed Spencer | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation | |
* files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, | |
* modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the | |
* Software is furnished to do so, subject to the following conditions: | |
* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var combo = new Ext.form.ComboBox({ | |
xtype: 'combo', | |
name : 'perpage', | |
width: 40, | |
listWidth: 40, | |
store: new Ext.data.ArrayStore({ | |
fields: ['id'], | |
data : [ | |
['15'], | |
['25'], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @class Ext.ux.HumanReadableGrid | |
* @extends Ext.grid.GridPanel | |
* An extended MVC scaffold grid with support for easily showing human-readable strings for associated models | |
* instead of the default numerical ID. See loadAssociatedModel documentation for implementation details | |
*/ | |
Ext.ux.HumanReadableGrid = Ext.extend(Ext.grid.GridPanel, { | |
closable: true, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=== Contents of ../config/environment.json === | |
{ | |
//define the app. files are loaded in this order | |
overrides : ['Ext.Ajax', 'Ext.Component'], | |
plugins : ['Printer', 'Notification', 'GroupTabPanel', 'ColumnTree', 'Exporter', 'PazPar2'], | |
models : ['Operator', 'Fund'], | |
controllers: ['Application', '] | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
edward-spencers-mac-pro:root ed$ ruby script/build auto all | |
Built Ext MVC Application | |
Built the ColumnTree plugin | |
Built the DrilldownLayout plugin | |
Built the Exporter plugin | |
Built the GroupNavPanel plugin | |
Built the Notification plugin | |
Built the PazPar2 plugin | |
Built the Printer plugin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Defines all routes required for this application | |
*/ | |
ExtMVC.router.Router.defineRoutes = function(map) { | |
/** | |
* Sets up REST-like urls for a given model or models: | |
* | |
* map.resources('users'); | |
* | |
* Is equivalent to: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+--------------------------+-----------+-----------+-----------+-----------+ | |
| Name | Lines | LOC | Classes | LOC/C | | |
+--------------------------+-----------+-----------+-----------+-----------+ | |
| Controllers | 1876 | 1288 | 53 | 24 | | |
| Models | 1466 | 936 | 49 | 19 | | |
| Views | 9816 | 7035 | 94 | 74 | | |
| Libraries | 375 | 257 | 5 | 51 | | |
| Controller Specs | 174 | 119 | 4 | 29 | | |
| Model Specs | 171 | 134 | 3 | 44 | | |
| View Specs | 446 | 315 | 3 | 105 | |