BPS C++ API  2.24.4
bpsschedulecalendarwidget.h
Go to the documentation of this file.
1 
4 #ifndef BPSSCHEDULECALENDARWIDGET_H
5 #define BPSSCHEDULECALENDARWIDGET_H
6 
7 #include "bpsgui_global.h"
8 #include <QCalendarWidget>
9 #include <QVariant>
10 
11 class BpsDatastore;
12 class BpsSchedule;
13 
20 {
21  Q_OBJECT
23 
24 public:
28  BpsScheduleCalendarWidget(QWidget* aParent = nullptr);
29 
30  virtual ~BpsScheduleCalendarWidget();
31 
36 
42  void setCronText(const QString& aCronText);
43 
51  void loadExceptionDays(BpsDatastore* aDatastore, const QVariant& aPartnerKey = QVariant());
52 
60  void loadExceptionDays(BpsDatastore* aDatastore, const QVariantList& aPartnerKeys);
61 
67 
73  bool isScheduleDate(const QDate& aDate) const;
74 
80  bool gotoNextScheduleDate(const QDate& aDate);
81 
86 
87 protected:
89  virtual void paintCell(QPainter* aPainter, const QRect& aRect, const QDate& aDate) const;
91 };
92 
93 #endif // BPSSCHEDULECALENDARWIDGET_H
#define BPS_PRIVATE(Class)
Declare pointer to private object in a public class.
Definition: bpsglobals.h:102
Public include file for BPS GUI library macros.
#define BPSGUI_EXPORT
Declare class an import from the shared library.
Definition: bpsgui_global.h:22
BPS datastore class.
Definition: bpsdatastore.h:61
Schedule calendar widget.
Definition: bpsschedulecalendarwidget.h:20
BpsScheduleCalendarWidget(QWidget *aParent=nullptr)
void loadExceptionDays(BpsDatastore *aDatastore, const QVariantList &aPartnerKeys)
Load exception days from datastore.
void setCronText(const QString &aCronText)
Set the CRON text defining the schedule.
bool isScheduleDate(const QDate &aDate) const
Convenience function to check if a certain date is a schedule date.
QDateTime selectedDateTime() const
void clearExceptionDays()
Clear the list of exception days.
bool gotoNextScheduleDate(const QDate &aDate)
Set the current date to the next schedule date after the given date.
void loadExceptionDays(BpsDatastore *aDatastore, const QVariant &aPartnerKey=QVariant())
Load exception days from datastore.
BpsSchedule * schedule() const
Schedule object processing.
Definition: bpsschedule.h:19
virtual void paintCell(QPainter *painter, const QRect &rect, const QDate &date) const const