mirror of
https://github.com/appwrite/appwrite.git
synced 2026-11-18 20:36:03 +00:00
added filters
This commit is contained in:
1 parent
95f67b274d
commit
9fa42e8084
3 files changed
+20
No files matched your search
@@ -92,6 +92,11 @@ Database::addFilter(
|
||||
$filters = $attribute->getAttribute('filters', []);
|
||||
$attribute->setAttribute('encrypt', in_array('encrypt', $filters));
|
||||
break;
|
||||
|
||||
case Database::VAR_POINT:
|
||||
case Database::VAR_LINESTRING:
|
||||
case Database::VAR_POLYGON:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -41,3 +41,15 @@ Structure::addFormat(APP_DATABASE_ATTRIBUTE_FLOAT_RANGE, function ($attribute) {
|
||||
$max = $attribute['formatOptions']['max'] ?? INF;
|
||||
return new Range($min, $max, Range::TYPE_FLOAT);
|
||||
}, Database::VAR_FLOAT);
|
||||
|
||||
Structure::addFormat(APP_DATABASE_ATTRIBUTE_POINT, function () {
|
||||
return new \Utopia\Validator\Text(0, 0);
|
||||
}, Database::VAR_POINT);
|
||||
|
||||
Structure::addFormat(APP_DATABASE_ATTRIBUTE_LINE, function () {
|
||||
return new \Utopia\Validator\Text(0, 0);
|
||||
}, Database::VAR_LINESTRING);
|
||||
|
||||
Structure::addFormat(APP_DATABASE_ATTRIBUTE_POLYGON, function () {
|
||||
return new \Utopia\Validator\Text(0, 0);
|
||||
}, Database::VAR_POLYGON);
|
||||
Reference in new issue
Block a user