mirror of
https://github.com/Gnucash/gnucash.git
synced 2024-11-22 08:57:17 -06:00
[csv-export-helpers] move account_get_fullname_str to support file
This commit is contained in:
parent
e5349a8b36
commit
229efb52ed
@ -82,3 +82,12 @@ gnc_csv_add_line (std::ostream& ss, const StringVec& str_vec,
|
||||
|
||||
return !ss.fail();
|
||||
}
|
||||
|
||||
std::string
|
||||
account_get_fullname_str (Account *account)
|
||||
{
|
||||
auto name{gnc_account_get_full_name (account)};
|
||||
auto rv{std::string(name)};
|
||||
g_free (name);
|
||||
return rv;
|
||||
}
|
||||
|
@ -35,5 +35,7 @@ using StringVec = std::vector<std::string>;
|
||||
bool gnc_csv_add_line (std::ostream& ss, const StringVec& charsvec,
|
||||
bool use_quotes, const char* sep);
|
||||
|
||||
std::string account_get_fullname_str (Account*);
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -83,15 +83,7 @@ static std::string
|
||||
get_account_name (Split *split, bool full)
|
||||
{
|
||||
auto account{xaccSplitGetAccount (split)};
|
||||
if (full)
|
||||
{
|
||||
auto name{gnc_account_get_full_name (account)};
|
||||
auto rv{std::string(name)};
|
||||
g_free (name);
|
||||
return rv;
|
||||
}
|
||||
else
|
||||
return xaccAccountGetName (account);
|
||||
return full ? account_get_fullname_str (account) : xaccAccountGetName (account);
|
||||
}
|
||||
|
||||
// Number
|
||||
|
@ -40,15 +40,6 @@
|
||||
/* This static indicates the debugging module that this .o belongs to. */
|
||||
static QofLogModule log_module = GNC_MOD_ASSISTANT;
|
||||
|
||||
static std::string
|
||||
account_get_fullname_str (Account *account)
|
||||
{
|
||||
auto name{gnc_account_get_full_name (account)};
|
||||
auto rv{std::string(name)};
|
||||
g_free (name);
|
||||
return rv;
|
||||
}
|
||||
|
||||
/*******************************************************
|
||||
* csv_tree_export
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user