mirror of
https://github.com/fralx/LimeReport.git
synced 2024-12-24 00:33:02 +03:00
checkIfEmpty has been refactored
This commit is contained in:
parent
229e8f529d
commit
54562d80cd
@ -736,11 +736,15 @@ bool CallbackDatasource::checkIfEmpty(){
|
||||
if (m_rowCount == 0) {
|
||||
return true;
|
||||
} else {
|
||||
QVariant result = true;
|
||||
QVariant isEmpty = true;
|
||||
QVariant recordCount = 0;
|
||||
CallbackInfo info;
|
||||
info.dataType = CallbackInfo::RowCount;
|
||||
emit getCallbackData(info, recordCount);
|
||||
if (recordCount.toInt()>0) return false;
|
||||
info.dataType = CallbackInfo::IsEmpty;
|
||||
emit getCallbackData(info,result);
|
||||
return result.toBool();
|
||||
emit getCallbackData(info,isEmpty);
|
||||
return isEmpty.toBool();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user