You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
51 lines
1.0 KiB
C++
51 lines
1.0 KiB
C++
#ifndef SEASON_H
|
|
#define SEASON_H
|
|
|
|
#include "../core_global.h"
|
|
|
|
#include <QObject>
|
|
#include <QString>
|
|
#include <QDate>
|
|
|
|
class CORESHARED_EXPORT Season : public QObject
|
|
{
|
|
Q_OBJECT
|
|
QX_REGISTER_FRIEND_CLASS(Season)
|
|
Q_PROPERTY(QString name READ name WRITE setName)
|
|
Q_PROPERTY(QDate validFrom READ validFrom WRITE setValidFrom)
|
|
Q_PROPERTY(QDate validTo READ validTo WRITE setValidTo)
|
|
Q_PROPERTY(bool active READ active WRITE setActive)
|
|
|
|
public:
|
|
explicit Season(QObject *parent = nullptr);
|
|
|
|
QString name() const;
|
|
void setName(const QString &name);
|
|
|
|
QDate validFrom() const;
|
|
void setValidFrom(const QDate &validFrom);
|
|
|
|
QDate validTo() const;
|
|
void setValidTo(const QDate &validTo);
|
|
|
|
bool active() const;
|
|
void setActive(bool active);
|
|
|
|
long id() const;
|
|
void setId(long id);
|
|
|
|
private:
|
|
long m_id;
|
|
QString m_name;
|
|
QDate m_validFrom;
|
|
QDate m_validTo;
|
|
bool m_active;
|
|
};
|
|
|
|
typedef QSharedPointer<Season> SeasonPtr;
|
|
|
|
QX_REGISTER_HPP_CORE(Season, QObject, 0)
|
|
|
|
|
|
#endif // SEASON_H
|