GnuCashew ~ GnuCash Enabled Web
GCW
SlotsWidget.h
Go to the documentation of this file.
1 #line 2 "src/Gui/SlotsWidget.h"
2 
3 #ifndef __GUI_SLOTSWIDGET_H___
4 #define __GUI_SLOTSWIDGET_H___
5 
6 #include <Wt/WContainerWidget.h>
7 #include <Wt/Dbo/QueryModel.h>
8 
9 #include "../GnuCashew.h"
10 #include "../Dbo/Slots.h"
11 #include "TableView.h"
12 
13 
14 namespace GCW {
15  namespace Gui {
16 
17 /*!
18 ** \brief SlotsWidget
19 **
20 ** The 'slots' table is used to 'extend' data in the various areas, such as notes on
21 ** transactions and so forth.
22 **
23 */
25 : public Wt::WContainerWidget
26 {
27  private:
28 
29  public:
30 
31  /*!
32  ** \brief Model
33  **
34  ** An alias for the Model in case this interface changes.
35  **
36  */
37  using Model = Wt::Dbo::QueryModel< GCW::Dbo::Slots::Item::Ptr >;
38 
39  /*!
40  ** \brief Constructor
41  **
42  */
43  SlotsWidget();
44 
45  /*!
46  ** \brief Table View
47  **
48  **
49  **
50  */
52 
53  std::shared_ptr< Model > model () { return m_model; }
54 
55  private:
56 
57  void loadData();
58 
59  std::shared_ptr< Model > m_model;
61 
62 }; // endclass SlotsWidget
63 
64  } // endnamespace Gui {
65 } // endnamespace GCW {
66 
67 #endif // end __GUI_SLOTSWIDGET_H___
68 
69 
GCW::Gui::TableView * m_tableView
Definition: SlotsWidget.h:60
Wt::Dbo::QueryModel< GCW::Dbo::Slots::Item::Ptr > Model
Model.
Definition: SlotsWidget.h:37
std::shared_ptr< Model > model()
Definition: SlotsWidget.h:53
GCW::Gui::TableView * tableView()
Table View.
Definition: SlotsWidget.h:51
SlotsWidget()
Constructor.
Definition: SlotsWidget.cpp:18
std::shared_ptr< Model > m_model
Definition: SlotsWidget.h:59
Custom Table View Class.
Definition: TableView.h:24
Definition: App.h:17