← Back to team overview

openerp-community-reviewer team mailing list archive

[Bug 1317455] Re: [7.0] [account_check_writing] Amount in words and print check button are not shown in "Write Checks" form

 

** Branch linked: lp:~alhashash/ocb-addons/7.0-bug-1317455-check-show-
amount-in-words

** Also affects: ocb-addons
   Importance: Undecided
       Status: New

** Also affects: ocb-addons/7.0
   Importance: Undecided
       Status: New

-- 
You received this bug notification because you are a member of OpenERP
Community Backports, which is subscribed to OpenERP Community Backports
(Addons).
https://bugs.launchpad.net/bugs/1317455

Title:
  [7.0] [account_check_writing] Amount in words and print check button
  are not shown in "Write Checks" form

Status in OpenERP Community Backports (Addons):
  New
Status in OpenERP Community Backports (Addons) 7.0 series:
  New
Status in OpenERP Addons (modules):
  New

Bug description:
  Install account_check_writing module and create/validate a supplier
  check from from Accounting > ?Write Checks"

  The amount in words and print check buttons are not shown.

  The attrs condition in the inherited view has incorrect condition.

      attrs="{'invisible':[('allow_check','!=',1)]}"

  It should be

      attrs="{'invisible':[('allow_check','!=',True)]}"

  Unlike python which has True==1, attrs expressions, which are
  evaluated client-side using undescore.js methods, True!=1.

  I think web client should map boolean values to integers in
  instance.web.form.compute_domain() to maintain consistancy with python
  expressions.

  To find if there are similar issues in other modules, I search using
  the regex:

      attrs\s*=\s*"[^"]*'!?=',\s*1\s*\)[^"]*"

  Only the view sale.view_order_line_form2 has this issue but it is
  probably a dead view and not used anywhere.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ocb-addons/+bug/1317455/+subscriptions