diff --git a/zero.Core/Entities/DateRange.cs b/zero.Core/Entities/DateRange.cs
new file mode 100644
index 00000000..8b6c7b71
--- /dev/null
+++ b/zero.Core/Entities/DateRange.cs
@@ -0,0 +1,11 @@
+using System;
+
+namespace zero.Core.Entities
+{
+ public class DateRange
+ {
+ public DateTimeOffset? From { get; set; }
+
+ public DateTimeOffset? To { get; set; }
+ }
+}
diff --git a/zero.Core/Entities/PriceRange.cs b/zero.Core/Entities/PriceRange.cs
new file mode 100644
index 00000000..f4c67531
--- /dev/null
+++ b/zero.Core/Entities/PriceRange.cs
@@ -0,0 +1,11 @@
+using System;
+
+namespace zero.Core.Entities
+{
+ public class PriceRange
+ {
+ public decimal? From { get; set; }
+
+ public decimal? To { get; set; }
+ }
+}
diff --git a/zero.Web.UI/App/components/tables/table-filter-overlay.vue b/zero.Web.UI/App/components/tables/table-filter-overlay.vue
index c2b646de..4006d451 100644
--- a/zero.Web.UI/App/components/tables/table-filter-overlay.vue
+++ b/zero.Web.UI/App/components/tables/table-filter-overlay.vue
@@ -8,6 +8,7 @@
+
@@ -31,6 +32,12 @@
+
+
+
+
+
+
@@ -52,7 +59,8 @@
defaults: {},
model: {},
activeGroup: null,
- groups: []
+ groups: [],
+ filterName: null
}),
components: { EditorComponent },
@@ -77,14 +85,25 @@
onLoad()
{
this.groups = this.config.fields;
- this.model = JSON.parse(JSON.stringify(this.config.model || {}));
+ this.model = JSON.parse(JSON.stringify(this.config.model.filter || {}));
this.defaults = JSON.parse(JSON.stringify(this.config.defaults || {}));
+ this.filterName = this.config.model.name;
this.loading = false;
},
onSubmit()
{
- this.config.confirm(this.model);
+ this.config.confirm({
+ model: this.model,
+ filterName: this.filterName
+ });
+ },
+
+ onRemove()
+ {
+ this.config.confirm({
+ remove: true
+ });
}
}
@@ -131,8 +150,8 @@
.ui-table-filter-overlay-group-content
{
background: var(--color-box);
- margin: var(--padding-s) -32px;
- padding: var(--padding-m) var(--padding);
+ margin: var(--padding-s) 0;
+ padding: var(--padding-m) 0;
border-top: 1px solid var(--color-line);
border-bottom: 1px solid var(--color-line);
@@ -141,4 +160,9 @@
display: none;
}
}
+
+ .ui-table-filter-overlay-filtername .ui-property-content
+ {
+ margin-top: 12px !important;
+ }
\ No newline at end of file
diff --git a/zero.Web.UI/App/components/tables/table-filter.vue b/zero.Web.UI/App/components/tables/table-filter.vue
index 017d1fb8..1deaa6fe 100644
--- a/zero.Web.UI/App/components/tables/table-filter.vue
+++ b/zero.Web.UI/App/components/tables/table-filter.vue
@@ -3,14 +3,15 @@
-
+
-
-
+
-
+
+
+
-
+
@@ -29,6 +30,7 @@