GnuCashew ~ Web Application compatible with GnuCash sql data files.
GCW
Loading...
Searching...
No Matches
Dbo/Accounts/Accounts.h
Go to the documentation of this file.
1#line 2 "src/Dbo/Accounts/Accounts.h"
2
3#ifndef __DBO_ACCOUNTS_H___
4#define __DBO_ACCOUNTS_H___
5
6#include "Item.h"
7
8namespace GCW {
9 namespace Dbo {
10 namespace Accounts {
11
12/*!
13** \brief Load Root Account
14**
15*/
16auto rootAccount()-> Item::Ptr ;
17
18/*!
19** \brief Load Root Account
20**
21*/
23
24/*!
25** \brief Load Account by GUID
26*/
27auto load( const std::string & _guid )-> Item::Ptr ;
28
29/*!
30** \brief Load Account by GUID
31*/
32auto byGuid( const std::string & _guid )-> Item::Ptr ;
33
34/*!
35** \brief Load Account by 'child name' and 'parent id'
36*/
37auto byChildName( const std::string & _parentGuid, const std::string & _childName )-> Item::Ptr ;
38
39/*!
40** \brief Load Account by 'full name' with ':' account separator
41*/
42auto byFullName( const std::string & _fullName )-> Item::Ptr ;
43auto byFullName( const char * _fullName )-> Item::Ptr ;
44auto byFullName( const Wt::WString & _fullName )-> Item::Ptr ;
45
46/*!
47** \brief Load all accounts
48*/
50
51/*!
52** \brief Load accounts as; if( !hidden() && !placeHolder() )
53*/
55
56/*!
57** \brief Load active accounts
58**
59** This loads active accounts, including the account with the
60** listed GUID. This is useful for assembling combo boxes where
61** the 'parent' account is being set up. In this case, if the
62** parent account is a placeholder account or a hidden account
63** then it shouldn't be shown.
64**
65*/
66auto activeAccountsAnd( const std::string & _guid )-> Item::Vector ;
67
68/*!
69** \brief Account Fullname via GUID
70*/
71auto fullName( const std::string & _guid )-> std::string ;
72
73/*!
74** \brief Account Fullname via Item
75*/
76auto fullName( Item::Ptr _item )-> std::string ;
77
78/*!
79** \brief Is Account Type
80**
81** This returns .true. if the account is an _type account,
82** meaning, if the acccount itself is not designated as an
83** _type (could be BANK or CASH or something), then the
84** parent tree is walked all the way to root and returns
85** .true. if any of the parent accounts are an _type account.
86*/
87
88auto isType( const Item::Ptr _acctItem, GCW::Dbo::Accounts::Type _type )-> bool ;
89auto isType( const std::string & _guid, GCW::Dbo::Accounts::Type _type )-> bool ;
90
91/*!
92** \brief Account Children Namespace
93*/
94namespace Children {
95
96/*!
97** \brief Child Accounts via parent
98**
99*/
100auto byParent( const std::string & _parentGuid )-> Item::Vector;
101
102 } // Children
103 } // Accounts
104 } // Dbo
105} // GCW
106
107
108
109#endif // __DBO_ACCOUNTS_H___
110
111
std::vector< Ptr > Vector
Definition BaseItem.h:41
Wt::Dbo::ptr< Item > Ptr
Definition BaseItem.h:39
auto byParent(const std::string &_parentGuid) -> Item::Vector
Child Accounts via parent.
auto rootAccount() -> Item::Ptr
Load Root Account.
auto activeAccountsAnd(const std::string &_guid) -> Item::Vector
Load active accounts.
auto load(const std::string &_guid) -> Item::Ptr
Load Account by GUID.
auto templateRootAccount() -> Item::Ptr
Load Root Account.
auto activeAccounts() -> Item::Vector
Load accounts as; if( !hidden() && !placeHolder() )
auto allAccounts() -> Item::Vector
Load all accounts.
auto isType(const Item::Ptr _acctItem, GCW::Dbo::Accounts::Type _type) -> bool
Is Account Type.
auto byFullName(const std::string &_fullName) -> Item::Ptr
Load Account by 'full name' with ':' account separator.
auto byGuid(const std::string &_guid) -> Item::Ptr
Load Account by GUID.
auto byChildName(const std::string &_parentGuid, const std::string &_childName) -> Item::Ptr
Load Account by 'child name' and 'parent id'.
auto fullName(const std::string &_guid) -> std::string
Account Fullname via GUID.
Definition App.h:18