Skip to content

Instantly share code, notes, and snippets.

@agborkowski
agborkowski / gist:1879462
Created February 21, 2012 22:27
MySql: database values normalization
/**
* Database values normalization shows diferences betwen @OUTPUT_LOW - @OUTPUT_HIGH
* its sample for forex database with tips table and 5 colls
* open FLOAT(8,5), high FLOAT(8,5), low FLOAT(8,5), close FLOAT(8,5),
* volume TINYINT(4), symbol (ENUM), time (DATETIME).
* tested on MySql
*
* @author AgBorkowski [email protected]
* @uses http://www.heatonresearch.com/content/really-simple-introduction-normalization (java)
* @link http://blog.aeonmedia.eu/2011/02/mysql-database-values-normalization
@agborkowski
agborkowski / gist:1879411
Created February 21, 2012 22:18
form buttons
Ext.define('APP.view.classificationIndicators.Edit', {
extend: 'Ext.window.Window',
//...
initComponent: function() {
var me = this;
Ext.applyIf(me, {
buttons: [{
text: 'Cancel',
scope: this,
@agborkowski
agborkowski / app.css
Created February 21, 2012 22:15
bordered submit button
/* app */
.app-btn-submit{
border: 1px solid black !important;
}
Dispatcher::applyFilter('_callable', function($self, $params, $chain) {
$ctrl = $chain->next($self, $params, $chain);
if (Auth::check('default')) {
return $ctrl;
}
if (isset($ctrl->publicActions) && in_array($params['params']['action'], $ctrl->publicActions)) {
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
return $ctrl;
}