[IMP] split state field in two boolean fields with the same feature in b...

with the same feature in base delivery_carrier_label

validated on https://code.launchpad.net/~akretion-team/carriers-deliveries/7-split-default-option-state-from-deliv-method-dbl/+merge/224027

this PR replace the previous closed
On 08/25/2014 08:57 AM, Yannick Vaucher wrote:
> In base_delivery_carrier_label/stock.py:
> 
>> @@ -163,7 +163,8 @@ def carrier_id_change(self, cr, uid, ids, carrier_id, context=None):
>>              available_option_ids = []
>>              for available_option in carrier.available_option_ids:
>>                  available_option_ids.append(available_option.id)
>> -                if available_option.state in ['default_option', 'mandatory']:
>> +                if available_option.mandatory \
>> +                        or available_option.by_default:
> 
> Operator position is a matter of taste here it can still be on start of
> second line
> 
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/OCA/carrier-delivery/pull/11/files#r16644073>.
> 

http://legacy.python.org/dev/peps/pep-0008/#maximum-line-length

> Make sure to indent the continued line appropriately. The preferred
place to break around a binary operator is after the operator, not
before it. Some examples:

```
class Rectangle(Blob):

    def __init__(self, width, height,
                 color='black', emphasis=None, highlight=0):
        if (width == 0 and height == 0 and
                color == 'red' and emphasis == 'strong' or
                highlight > 100):
            raise ValueError("sorry, you lose")
        if width == 0 and height == 0 and (color == 'red' or
                                           emphasis is None):
            raise ValueError("I don't think so -- values are %s, %s" %
                             (width, height))
        Blob.__init__(self, width, height,
                      color, emphasis, highlight)
```