30 #ifndef STRING2MONTH_FILTER_H
31 #define STRING2MONTH_FILTER_H
33 #include "../AbstractSimpleFilter.h"
37 #include <QXmlStreamWriter>
57 if (!
d_inputs.value(0))
return QDateTime();
59 QString input_value =
d_inputs.value(0)->textAt(row);
61 int month_value = input_value.toInt(&ok);
64 QDate temp = QDate::fromString(input_value,
"MMM");
66 temp = QDate::fromString(input_value,
"MMMM");
70 month_value = temp.month();
75 QDate result_date = QDate(1900,1,1).addMonths(month_value - 1);
76 QTime result_time = QTime(0,0,0,0);
77 return QDateTime(result_date, result_time);
81 if (!col)
return false;
85 if (!
d_inputs.value(0))
return false;
86 for (
int row = i.
start(); row <= i.
end(); row++) {
96 int rows =
d_inputs.value(0)->rowCount();
97 for (
int i=0; i<rows; i++)
112 #endif // ifndef STRING2MONTH_FILTER_H