File indexing completed on 2024-05-19 05:08:41

0001 /*
0002     SPDX-FileCopyrightText: 2000-2003 Michael Edwardes <mte@users.sourceforge.net>
0003     SPDX-FileCopyrightText: 2000-2003 Javier Campos Morales <javi_c@users.sourceforge.net>
0004     SPDX-FileCopyrightText: 2000-2003 Felix Rodriguez <frodriguez@users.sourceforge.net>
0005     SPDX-FileCopyrightText: 2000-2003 John C <thetacoturtle@users.sourceforge.net>
0006     SPDX-FileCopyrightText: 2000-2003 Thomas Baumgart <ipwizard@users.sourceforge.net>
0007     SPDX-FileCopyrightText: 2000-2003 Kevin Tambascio <ktambascio@users.sourceforge.net>
0008     SPDX-FileCopyrightText: 2017 Łukasz Wojniłowicz <lukasz.wojnilowicz@gmail.com>
0009     SPDX-License-Identifier: GPL-2.0-or-later
0010 */
0011 
0012 #ifndef KEDITLOANWIZARD_H
0013 #define KEDITLOANWIZARD_H
0014 
0015 // ----------------------------------------------------------------------------
0016 // QT Includes
0017 
0018 // ----------------------------------------------------------------------------
0019 // KDE Includes
0020 
0021 // ----------------------------------------------------------------------------
0022 // Project Includes
0023 
0024 #include "knewloanwizard.h"
0025 
0026 /**
0027   * @author Thomas Baumgart
0028   */
0029 class KEditLoanWizardPrivate;
0030 class KEditLoanWizard : public KNewLoanWizard
0031 {
0032     Q_OBJECT
0033 public:
0034     explicit KEditLoanWizard(const MyMoneyAccount& account, QWidget *parent = nullptr);
0035     ~KEditLoanWizard() override;
0036 
0037     /**
0038       * This method returns the schedule for the payments. The account
0039       * where the amortization should be transferred to is the one
0040       * we currently edited with this wizard.
0041       *
0042       * @return MyMoneySchedule object for payments
0043       */
0044     const MyMoneySchedule schedule() const;
0045 
0046     /**
0047       * This method returns a MyMoneyAccount object with all data
0048       * filled out as provided by the wizard.
0049       *
0050       * @return updated MyMoneyAccount object
0051       */
0052     const MyMoneyAccount account() const;
0053 
0054 
0055     void loadWidgets(const MyMoneyAccount& acc);
0056 
0057     const MyMoneyTransaction transaction() const;
0058 
0059     bool validateCurrentPage() final override;
0060 
0061 protected:
0062     void updateEditSummary();
0063 
0064 private:
0065     Q_DISABLE_COPY(KEditLoanWizard)
0066     Q_DECLARE_PRIVATE(KEditLoanWizard)
0067 };
0068 
0069 #endif