P4A 3 goes RC

Time to release some bugfixes and prepare for the stable release, we had to cut out jQuery UI (and P4A_DB_Navigator’s drag&drop) from our roadmap ’cause it seems that jQuery UI won’t be released soon and we can’t wait anymore.

Anyway, here is the changelog:

– saveUploads() method was moved from P4A_Mask to P4A_Data_Source
– P4A_DB::quote() method’s 2nd param “autoquote” is now false by default,
solving some problems with P4A_Data_Field::getSQLValue() and getSQLNewValue()
– when P4A_DB_Source needs a quoted value now it uses P4A_DB->quote() with
autoquote turned on
– P4A_DB::quote() method, if autoquote param is on, always encloses the value
within single quotes
– jQuery::form was updated to 2.0.8
– jQuery::iFixPNG was updated to 2.1
– P4A_Menu’s CSS were changed a bit solving a bug with IE6 (too fast hide)
– P4A_DB_Navigator movements were disabled (due to the unavailable jQuery UI release)
thus now all allowMovements methods trigger errors

We’ll let this release “rest” for some weeks, during this time we’ll work on the documentation and website, fixing the bugs that will eventually come out. If everything will go smoothly as I hope, we’ll simply have to sync translations and release it as 3.0.0 final.

Download P4A 3.0.0-rc1, please help us with translations and report us all the bugs you find! Thank you so much!

10 thoughts on “P4A 3 goes RC

  1. Eddie

    Fabrizio, a process of my application re-configures the datasources and his relations, i use addJoin and addMultivalueField, but i had to implement two methods in P4_DB_Source: resetJoin and resetMultivalueField. These methods delete all or one indexed element. May be you can implement in the official version.

    Saludos. Eddie.

  2. Fabrizio Balliano Post author

    @Eddie: I’m wondering if add those methods to core but… I think that you’ve to launch the load() after modifying joins, but re-loading a db_source should be avoided

  3. Eddie

    Fabrizio,

    Why re-call the load() method must be avoided..? Which is the best practice to solve my problem..?

    Eddie

  4. Fabrizio Balliano Post author

    @Eddie: cause it recreated all data fields destroying the old ones, thus if you used them the references will be lost.

    you should not change the structure of a db_source once it’s created, you should only change where/filters/orders but not its structure

  5. Eddie

    Ok, i’ll try to implement my solution via helpers, anyway if you can add the methods resetJoin and resetMultivalueFields i’ll be satisfied.

    In other words, i need to buy the license to use my application internally without share the source code. What is the procedure…?

    Eddie

  6. Eddie

    Fabrizio,

    Since the update to 3.0.0-rc my forms with select fields which the source is a query, resets the application.

    Ex. (in form):

    $field
    ->setSource(P4A::singleton()->lasts)
    ->setSourceDescriptionField(“code”);

    Ex. (in main class):

    $lasts =& $this->build(“P4A_DB_Source”, “lasts”);
    $lasts
    ->setQuery(“SELECT * FROM periods;”)
    ->setPk(“id”)
    ->load();

    —————————————

    Eddie

  7. Fabrizio Balliano Post author

    @Eddie:
    1 – i think we should not have methods that make users think that reloading a db_source is possible when it shuld not be done :-(

    2 – if you don’t want to share the code you should buy a commercial license (it’s not available now, we’re working on that)

    3 – try removing the “;” char from the query

  8. Eddie

    Fabrizio,

    i’m reading your code to understand the load() method, to avoid the reloading i use a flag, this flag should be in the class (_loaded), and two methods could be implemented: isLoaded() and unload(). What do you think..?

    Saludos..!!

    Eddie

  9. Fabrizio Balliano Post author

    hum, a data source in a “not loaded” state is completely unuseful and broken thus you should avoid that state, I’m thinking about the unload but i’m a bit skeptical, I’ll talk to andrea about that :-)

Leave a Reply

Your email address will not be published. Required fields are marked *