http://www.sencha.com/products/architect
If you bought Ext Designer this year, you get Architect for free.
Formerly Sencha Designer 2, and before that Ext Designer. Registering my version now and will post some videos soon.
Tuesday, April 17, 2012
Tuesday, April 3, 2012
Looks like Chrome 18 breaks Sencha ExtJS
Using Chrome 18, try clicking the reload button twice here:
http://dev.sencha.com/deploy/ext-4.0.7-gpl/examples/charts/Line.html
Many of the buttons in my app started disappearing in Chrome 18 only...hopefully will be fixed in 19!
http://dev.sencha.com/deploy/ext-4.0.7-gpl/examples/charts/Line.html
Many of the buttons in my app started disappearing in Chrome 18 only...hopefully will be fixed in 19!
Saturday, March 31, 2012
Things your server needs in order to not suck
On the database side, you need full-text search, you need transactions, check constraints, and you probably need real schemas.
Full-Text search allows you to find records by similarity, which is what most users expect these days (thanks Google). Some moron will tell ya, "oh you can use Lucene or Sphinx". Too bad they don't really talk to databases eh? Ya, polling your database for modified records every minute is a great idea. Upon getting Lucene to sync with MySQL you will end up like Mel Gibson in this scene:
http://www.youtube.com/watch?v=UpOqkz86_lg#t=135s
And you need transactions and check constraints if you remotely care about the integrity of your data. If you don't, please continue to use MyISAM.
You need schemas (real ones, not MySQL ones) if you want a multi-tenant system that doesn't suck. If you only have one tenant, this doesn't apply. You can still do it with MySQL, but it provides much butt-hurt.
The above requirements rules out MySQL. UPDATE: MySQL 5.6.4 supports full-text search on InnoDB! Holy shit. Still no check constraints or schemas though. Use PostgreSQL.
On the application server side, you need a comprehensive validation library, deeply-nested JSON support, support for table inheritance, and concurrency control in your ORM.
By deeply nested JSON support I mean being able to load JSON from a POST into your models and into your database in a couple lines of code, with validation. With hasOne, hasMany, and manyMany relationships. You should also be able to write 50 records or so, with relations of arbitrary nesting depth, very fast.
By support for table inheritance, I mean this: http://martinfowler.com/eaaCatalog/singleTableInheritance.html , and the other schemes. Ruby's ActiveRecord supports STI, and PHP's Doctrine supports single and multi. Yii's ActiveRecord sorta-kinda-almost supports STI, but requires some work.
Concurrency means that your UPDATE will fail if you try to update a record that someone has updated since you read it. Usually this means a query like this:
UPDATE mytable SET (field1='happy' and field2='monday') where id=59 and (field1='sad' and field2='sunday')
Unfortunately, this is not built in to Yii, which I have been using. Yii's validation library is actually really good, but it sucks at nested JSON and it doesn't do concurrency. It looks like Doctrine ORM does concurrency, but has no validation for some bizarre reason. I might have to switch to Ruby, or hell, even go back to ASP.Net
Full-Text search allows you to find records by similarity, which is what most users expect these days (thanks Google). Some moron will tell ya, "oh you can use Lucene or Sphinx". Too bad they don't really talk to databases eh? Ya, polling your database for modified records every minute is a great idea. Upon getting Lucene to sync with MySQL you will end up like Mel Gibson in this scene:
http://www.youtube.com/watch?v=UpOqkz86_lg#t=135s
And you need transactions and check constraints if you remotely care about the integrity of your data. If you don't, please continue to use MyISAM.
You need schemas (real ones, not MySQL ones) if you want a multi-tenant system that doesn't suck. If you only have one tenant, this doesn't apply. You can still do it with MySQL, but it provides much butt-hurt.
On the application server side, you need a comprehensive validation library, deeply-nested JSON support, support for table inheritance, and concurrency control in your ORM.
By deeply nested JSON support I mean being able to load JSON from a POST into your models and into your database in a couple lines of code, with validation. With hasOne, hasMany, and manyMany relationships. You should also be able to write 50 records or so, with relations of arbitrary nesting depth, very fast.
By support for table inheritance, I mean this: http://martinfowler.com/eaaCatalog/singleTableInheritance.html , and the other schemes. Ruby's ActiveRecord supports STI, and PHP's Doctrine supports single and multi. Yii's ActiveRecord sorta-kinda-almost supports STI, but requires some work.
Concurrency means that your UPDATE will fail if you try to update a record that someone has updated since you read it. Usually this means a query like this:
UPDATE mytable SET (field1='happy' and field2='monday') where id=59 and (field1='sad' and field2='sunday')
Unfortunately, this is not built in to Yii, which I have been using. Yii's validation library is actually really good, but it sucks at nested JSON and it doesn't do concurrency. It looks like Doctrine ORM does concurrency, but has no validation for some bizarre reason. I might have to switch to Ruby, or hell, even go back to ASP.Net
Tuesday, February 14, 2012
How to disable change / validation events when using loadRecord
When you use Basic.loadRecord() to load a record into a form, all of the form fields fire their change events, which you might not want. Here's a quick way to fix this:
This prevents change events from firing, but then re-enables them:
This prevents change events from firing, but then re-enables them:
var basic = form.getForm();
basic.getFields().each(function(item, index, length){
item.suspendCheckChange++;
});
basic.loadRecord(myRecord);
basic.getFields().each(function(item, index, length){
item.suspendCheckChange--;
});
How to prompt the user to save a dirty form if leaving the page
How to prompt the user to save a dirty form if leaving the page:
something like this:
- set the Basic Form's trackResetOnLoad to true
- handle the form's dirtychange event
something like this:
function my_onbeforeunload(e){
message = 'You have unsaved changes. Are you sure you want to leave this page?';
e = e || window.event;
if(e){
e.returnValue = message;
}
return message;
}
form.on('dirtychange', function(basic, dirty, eOpts){
window.onbeforeunload = dirty ? my_onbeforeunload : null;
});
Subscribe to:
Posts (Atom)