Jump to content


Jason

Member Since 23 Aug 2011
Offline Last Active Feb 13 2017 03:58 PM
*****

Topics I've Started

Performance3 branch and reporting branch changes

13 March 2013 - 10:14 PM

Performance3 Branch

 

I have merged performance3 into default.  RedBeanModel now extends BeanModel.  You can now call things like Opportunity::isAnAttribute statically for example.  Look at BeanModel for more static method calls.  This is helpful because now you don't have to always new-up a model if you are just looking for some information about an attribute or something else on that class.

 

Reporting Branch

Very shortly, hopefully tomorrow, I will be merging reporting to default.  There is some new functionality around relations support for model metadata.

 

In Account.php for example:

 

 'industry'         => array(RedBeanModel::HAS_ONE,              'OwnedCustomField', RedBeanModel::OWNED),

 

becomes

 

 

'industry'         => array(RedBeanModel::HAS_ONE,              'OwnedCustomField', RedBeanModel::OWNED,  RedBeanModel::LINK_TYPE_SPECIFIC, 'industry'),
 
There is now support for the link name.  This means you can have 2 relations to the same class, that can have different link names.  The upgrade script for 1.5 will support existing model relations. If you are doing any custom models, then you will need to deal with this using CustomManagement.

Should we move the 'show older comments' link to after the last comment?

20 January 2013 - 05:17 AM

This is in the conversations module.  Take a look at this task

https://www.pivotalt...y/show/40634763

and let us know what you think.

 

I added an attached image to explain more


Ordering of methods in classes - Refactor

18 July 2012 - 05:57 PM

I am thinking about re-factoring all classes so the method ordering is consistent.

I propose we do this ordering:

public static
protected static
private static
public non-static
protected non-static
private non-static

Does everyone like this ordering or should we do it different? Is this a best practice for this?

Can someone in the community help us with this issue?

18 June 2012 - 03:03 AM

We have a bug here, well it isn't really a bug, it's more of a performance improvement I would like to make.

https://www.pivotalt...y/show/29832289

Basically if you look at the ajax calls we are including 2 extra js files related to the dropkick (Makes the dropdowns look pretty). We are doing this on purpose even though when the system is minified both of these files need to be loaded.

The content of dropdownInteraction.js makes sense to load each time which is fine. But the thing I couldn't figure out is why we need to include jquery.dropbox.js on that ajax call when it was already included on the main page load as part of the minified request. If you don't include it in the ajax call, then the dropkick doesn't work.

Hopefully one of our community members could troubleshoot this further.

Thanks
Jason

Loading and Managing Language Packs

01 March 2012 - 07:49 PM

Sacha,
I reviewed the command. Good start. Here are my thoughts, I am curious what you think:

First of all I want to point out that up until now all customizations are done in the db. Also file attachments are stored in the db. This is done on purpose so it makes it easier to load balance scale etc. With the language packs, now we are talking about modifying the file system. I was looking at http://www.yiiframew.../en/topics.i18n and noticed CDbMessageSource. It would be interesting to use CDbMessageSource because then we can just load packs into the db. I am not sure how compatible this db mechanism is with what we have now. We probably would have to extend it and have it supported via RedBean. This should not be hard.

Then I am thinking on install or update it can just load the existing language files into the db. Or it could only load packs into the db as you install them. Then defer to the db for the packs only. If we did something like this, then the installation would be very simple, since the command line (or later via admin ui) could actually pull from a ‘channel’ with the zip and load it into the Db. Or maybe it doesn’t pull a zip but calls an api to pull the pack data and then puts it into the db.

This starts to get into upgrades in general and we are going to need a great mechanism for that, but one thing at a time.

What do you think? Thoughts?