diff options
author | John Wiegley <johnw@newartisans.com> | 2012-04-26 16:39:25 -0500 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2012-04-26 16:39:25 -0500 |
commit | 64a9b42381c26baf24e58b40f50f0b253e551811 (patch) | |
tree | 5447a29dff64c3a8b7be8100a01bcb4a2d73b0bb /src/py_xact.cc | |
parent | 7cc550fc22357e2ded194d3e65287c6b3317f5ae (diff) | |
parent | b4407c10c0071365322b2963747bf42a57fd7304 (diff) | |
download | fork-ledger-64a9b42381c26baf24e58b40f50f0b253e551811.tar.gz fork-ledger-64a9b42381c26baf24e58b40f50f0b253e551811.tar.bz2 fork-ledger-64a9b42381c26baf24e58b40f50f0b253e551811.zip |
Merge branch 'release/v3.0.0-20120426'
Diffstat (limited to 'src/py_xact.cc')
-rw-r--r-- | src/py_xact.cc | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/py_xact.cc b/src/py_xact.cc index 604d8d59..3d792c7b 100644 --- a/src/py_xact.cc +++ b/src/py_xact.cc @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003-2010, John Wiegley. All rights reserved. + * Copyright (c) 2003-2012, John Wiegley. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -76,6 +76,12 @@ namespace { return **elem; } + string py_xact_to_string(xact_t&) + { + // jww (2012-03-01): TODO + return empty_string; + } + } // unnamed namespace using namespace boost::python; @@ -107,6 +113,11 @@ void export_xact() ; class_< xact_t, bases<xact_base_t> > ("Transaction") + .def("id", &xact_t::id) + .def("seq", &xact_t::seq) + + .def("__str__", py_xact_to_string) + .add_property("code", make_getter(&xact_t::code), make_setter(&xact_t::code)) @@ -117,8 +128,6 @@ void export_xact() .def("add_post", &xact_t::add_post, with_custodian_and_ward<1, 2>()) .def("magnitude", &xact_t::magnitude) - .def("idstring", &xact_t::idstring) - .def("id", &xact_t::id) .def("lookup", &xact_t::lookup) |