doc/3.14.rst
author Sylvain Thénault <sylvain.thenault@logilab.fr>
Thu, 22 Sep 2011 16:12:28 +0200
changeset 7828 749e1a67987f
parent 7827 9bbf83f68bcc
child 7859 15809afe093b
permissions -rw-r--r--
[entity] rename Entity._rest_attr_info into cw_rest_attr_info (closes #1942759)

API changes in cubicweb 3.14
----------------------------

* `Entity.fetch_order` and `Entity.fetch_unrelated_order` class methods have been
  replaced by `Entity.cw_fetch_order` and `Entity.cw_fetch_unrelated_order` with
  a different prototype:

  - instead of taking (attr, var) as two string argument, they now take (select,
    attr, var) where select is the rql syntax tree beinx constructed and var the
    variable *node*.

  - instead of returning some string to be inserted in the ORDERBY clause, it has
    to modify the syntax tree

  Backward compat is kept with proper warning, BESIDE cases below:

  - custom order method return **something else the a variable name with or
    without the sorting order** (e.g. cases where you sort on the value of a
    registered procedure as it was done in the tracker for instance). In such
    case, an error is logged telling that this sorting is ignored until API
    upgrade.

  - client code use direct access to one of those methods on an entity (no code
    known to do that)

* `Entity._rest_attr_info` class method has been renamed to
  `Entity.cw_rest_attr_info`

  No backward compat yet since this is a protected method an no code is known to
  use it outside cubicweb itself.