[RC1]Pay button when you pay directly in Sales receipt form

Bug #693810 reported by Laurent Urbain (Realdolmen)
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Medium
OpenERP R&D Addons Team 3

Bug Description

Last Trunk

In Accounting/Customers/Sales Receipt

I create new sales receipt
I select :

Payement : Pay directly
Account : Current

I validate and then there is a button Pay.
But when I validate the sales receipt, payement is already made. (See account moves)

The Pay button is maybe necessary when I select Pay Later or Group Funds ?
But he is missing in this case

In supplier vouchers, it's work fine :)

Thx

Related branches

Revision history for this message
Amit Parik (amit-parik) wrote :

Hello Larent0,

I have tested your scenario with latest code. But everything is works fine. When you validate the "Sale Receipt". Then in account.move entries in valid state not in paid. I have attached the screen-shot for your reference. So please check it.

Thanks .

Changed in openobject-addons:
status: New → Invalid
Revision history for this message
Amit Parik (amit-parik) wrote :
Revision history for this message
Amit Parik (amit-parik) wrote :
Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :

Yes, the moves are right but why when you pay directly, there is yet a Pay button?

Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :
Revision history for this message
Amit Parik (amit-parik) wrote :

Hello Laurent0,

You are right, you select a pay directly but you can see the pay button. Because "Pay" button is just a simple button, not a work flow button which has a type="action". So we can not hide this.

I hope you are understand.

Thanks.

Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :

Hi,

When you select pay later or group funds the pay button is not present.
It can be useful in this case.

I just change the != in = line 170 (voucher_sales_purchase_view.xml) and all work

<button icon="terp-dolar_ok!" name="276" context="{'narration':narration, 'title':'Customer Payment', 'type':'receipt', 'partner_id':partner_id, 'reference':reference, 'amount':amount}" type="action" string="Pay" attrs="{'invisible':[('pay_now','=','pay_now')]}"/>

The pay button is hiding when you pay directly and displayed when you pay later.

So I don't understand why you say it's not possible ?

Laurent

Revision history for this message
Amit Parik (amit-parik) wrote :

Hello Laurent,

When you sell products to a customer, you can give him a sales receipt or an invoice. When the sales receipt is confirmed, it creates journal items automatically and you can record the customer payment related to this sales receipt.

So first you can Validate the "sale receipt" and then pay. When you press "Pay" button then record goes to Customer payment. So the "Pay" button is required and we can not hide it.

Thanks.

Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :

Hi,

In the sale receipt :

I create a sale line of 1000 euros.
I choose Pay Directly and account : current.

I validate the sale receipt, press Pay button and validate the payment.

The current account is debit twice of 1000euros, when you validate the sale receipt and when you validate the payment.

I think it's not normal?

Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :
Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :
Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :
Revision history for this message
Laurent Urbain (Realdolmen) (laurent-urbain) wrote :
Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
importance: Undecided → Medium
status: Invalid → Confirmed
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
Purnendu Singh (OpenERP) (purnendu-singh) wrote :

Hello laurent,

You supposed to choose:
* an income account in the sale receipt line
* a cash account in the payment area
and then the lines are correctly created

And regarding the visibility of the Pay button we fixed this problem in lp:~openerp-commiter/openobject-addons/trunk-dev-addons3-psi2 branch.

Revision NO: 4578
Revision ID: <email address hidden>

Thanks

Changed in openobject-addons:
status: In Progress → Fix Committed
Revision history for this message
Fabien (Open ERP) (fp-tinyerp) wrote :

fixed in r4134, thanks for reporting.

Changed in openobject-addons:
status: Fix Committed → Fix Released
Changed in openobject-addons:
milestone: none → 6.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.