diff --git a/line.py b/line.py
index 57c0c1c..5c6dd01 100644
--- a/line.py
+++ b/line.py
@@ -84,6 +84,8 @@ class Line(SecondCurrencyMixin, Workflow, ModelSQL, ModelView):
'on_change_with_category_view', searcher='search_category_view')
feature = fields.Function(fields.Char(string='Feature', readonly=True,
states={'invisible': True}), 'on_change_with_feature')
+ booktransf_feature = fields.Function(fields.Char(string='Feature', readonly=True,
+ states={'invisible': True}), 'on_change_with_booktransf_feature')
bookingtype = fields.Selection(string='Type', required=True,
help='Type of Booking', selection=sel_bookingtype,
@@ -607,6 +609,14 @@ class Line(SecondCurrencyMixin, Workflow, ModelSQL, ModelView):
if self.cashbook:
return self.cashbook.btype.feature
+ @fields.depends('booktransf', '_parent_booktransf.feature')
+ def on_change_with_booktransf_feature(self, name=None):
+ """ get 'feature' of counterpart
+ """
+ if self.booktransf:
+ if self.booktransf.btype:
+ return self.booktransf.btype.feature
+
@fields.depends('description')
def on_change_with_descr_short(self, name=None):
""" to speed up list-view
diff --git a/locale/de.po b/locale/de.po
index be5df9f..b533724 100644
--- a/locale/de.po
+++ b/locale/de.po
@@ -606,6 +606,10 @@ msgctxt "field:cashbook.book,feature:"
msgid "Feature"
msgstr "Merkmal"
+msgctxt "field:cashbook.book,booktransf_feature:"
+msgid "Feature"
+msgstr "Merkmal"
+
##################
# cashbook.split #
diff --git a/locale/en.po b/locale/en.po
index 20d9de3..0326dff 100644
--- a/locale/en.po
+++ b/locale/en.po
@@ -570,6 +570,10 @@ msgctxt "field:cashbook.book,feature:"
msgid "Feature"
msgstr "Feature"
+msgctxt "field:cashbook.book,booktransf_feature:"
+msgid "Feature"
+msgstr "Feature"
+
msgctxt "model:cashbook.split,name:"
msgid "Split booking line"
msgstr "Split booking line"
diff --git a/tests/test_line.py b/tests/test_line.py
index aa6dded..0cb6608 100644
--- a/tests/test_line.py
+++ b/tests/test_line.py
@@ -995,6 +995,11 @@ class LineTestCase(ModuleTestCase):
self.assertEqual(book.lines[0].rec_name, '05/01/2022|to|-1.00 usd|Transfer Out [Book 2 | 0.00 usd | Open]')
self.assertEqual(len(book.lines[0].references), 0)
+ # check counterpart
+ self.assertEqual(book.lines[0].booktransf.rec_name, 'Book 2 | 0.00 usd | Open')
+ self.assertEqual(book.lines[0].booktransf.btype.feature, 'gen')
+ self.assertEqual(book.lines[0].booktransf_feature, 'gen')
+
# check payee
self.assertEqual(book.lines[0].payee.rec_name, 'Book 2 | 0.00 usd | Open')
self.assertEqual(Line.search_count([('payee', 'ilike', 'book 2%')]), 1)
diff --git a/view/line_form.xml b/view/line_form.xml
index 7595bcd..37ddf6f 100644
--- a/view/line_form.xml
+++ b/view/line_form.xml
@@ -59,4 +59,5 @@ full copyright notices and license terms. -->
+