Merge pull request #6028 from dataease/pr@dev@fix_date

fix: 时间过滤
This commit is contained in:
Junjun 2023-09-06 11:56:49 +08:00 committed by GitHub
commit fd6599896e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1071,7 +1071,7 @@ public class MysqlQueryProvider extends QueryProvider {
} else {
date = String.format(MySQLConstants.DATE_FORMAT, originName, StringUtils.isNotEmpty(field.getDateFormat()) ? field.getDateFormat() : MysqlConstants.DEFAULT_DATE_FORMAT);
}
if (request.getOperator().equals("between")) {
if (request.getOperator().equals("between") && request.getDatasetTableField().getDeExtractType() != 1) {
whereName = String.format(MySQLConstants.UNIX_TIMESTAMP, date) + "*1000";
} else {
if (StringUtils.equalsIgnoreCase(request.getDateStyle(), "y_Q")) {