[POS-commit] r7121 - in stoqlib/trunk/stoqlib/domain: . test
Johan Dahlin
jdahlin at async.com.br
Wed Aug 8 16:41:27 BRT 2007
Author: jdahlin
Date: Wed Aug 8 16:41:27 2007
New Revision: 7121
Modified:
stoqlib/trunk/stoqlib/domain/sale.py
stoqlib/trunk/stoqlib/domain/test/test_sale.py
Log:
Remove get_clone, it's unused after the recent POS refactoring. Update docstrings.
Modified: stoqlib/trunk/stoqlib/domain/sale.py
==============================================================================
--- stoqlib/trunk/stoqlib/domain/sale.py (original)
+++ stoqlib/trunk/stoqlib/domain/sale.py Wed Aug 8 16:41:27 2007
@@ -268,7 +268,7 @@
@ivar return_date: the date sale was returned
@ivar discount_value:
@ivar surcharge_value:
- @ivar total_amount: the total sale amount
+ @ivar total_amount: the total value of all the items in the same
@ivar notes: Some optional additional information related to this sale.
@ivar client_role: This field indicates what client role is tied with
the sale order. This is important since a client can have two roles
@@ -278,7 +278,6 @@
@ivar coupon_id:
@ivar service_invoice_number:
@ivar cfop:
- @ivar renegotiation_data:
"""
implements(IContainer)
@@ -546,12 +545,6 @@
self.add_sellable(sellable_cert)
return sellable_cert
- def get_clone(self):
- conn = self.get_connection()
- return Sale(client_role=self.client_role, client=self.client,
- cfop=self.cfop, coupon_id=None, branch=self.branch,
- salesperson=self.salesperson, connection=conn)
-
#
# Accessors
#
Modified: stoqlib/trunk/stoqlib/domain/test/test_sale.py
==============================================================================
--- stoqlib/trunk/stoqlib/domain/test/test_sale.py (original)
+++ stoqlib/trunk/stoqlib/domain/test/test_sale.py Wed Aug 8 16:41:27 2007
@@ -150,12 +150,6 @@
self.failUnless(IGiftCertificate(
sale.add_custom_gift_certificate(Decimal(230), u'11'), None))
- def test_get_clone(self):
- sale = self.create_sale()
- clone = sale.get_clone()
- self.assertEqual(clone.client, sale.client)
- self.assertEqual(clone.salesperson, sale.salesperson)
-
def testCheckPaymentGroup(self):
sale_no_payment = self.create_sale()
More information about the POS-commit
mailing list