diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2017-02-15 16:21:06 +0100 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2017-02-16 10:39:59 +0100 |
commit | f7a42de9bfd6e34f1dc46da433d3f45976b1cd0e (patch) | |
tree | 421899ff287eb44459587aee6549ff098ab564fd /sinksh/syntax_modules/sink_list.cpp | |
parent | 73ef798bf849a01418895c2e88300e1c6730b665 (diff) | |
download | sink-f7a42de9bfd6e34f1dc46da433d3f45976b1cd0e.tar.gz sink-f7a42de9bfd6e34f1dc46da433d3f45976b1cd0e.zip |
PropertyParser to properly parse different property types.
Diffstat (limited to 'sinksh/syntax_modules/sink_list.cpp')
-rw-r--r-- | sinksh/syntax_modules/sink_list.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sinksh/syntax_modules/sink_list.cpp b/sinksh/syntax_modules/sink_list.cpp index 837f60d..d63749b 100644 --- a/sinksh/syntax_modules/sink_list.cpp +++ b/sinksh/syntax_modules/sink_list.cpp | |||
@@ -25,13 +25,12 @@ | |||
25 | 25 | ||
26 | #include "common/resource.h" | 26 | #include "common/resource.h" |
27 | #include "common/storage.h" | 27 | #include "common/storage.h" |
28 | #include "common/domain/event.h" | ||
29 | #include "common/domain/folder.h" | ||
30 | #include "common/resourceconfig.h" | 28 | #include "common/resourceconfig.h" |
31 | #include "common/log.h" | 29 | #include "common/log.h" |
32 | #include "common/storage.h" | 30 | #include "common/storage.h" |
33 | #include "common/definitions.h" | 31 | #include "common/definitions.h" |
34 | #include "common/store.h" | 32 | #include "common/store.h" |
33 | #include "common/propertyparser.h" | ||
35 | 34 | ||
36 | #include "sinksh_utils.h" | 35 | #include "sinksh_utils.h" |
37 | #include "state.h" | 36 | #include "state.h" |
@@ -109,7 +108,8 @@ bool list(const QStringList &args_, State &state) | |||
109 | if (options.options.contains("filter")) { | 108 | if (options.options.contains("filter")) { |
110 | for (const auto &f : options.options.value("filter")) { | 109 | for (const auto &f : options.options.value("filter")) { |
111 | auto filter = f.split("="); | 110 | auto filter = f.split("="); |
112 | query.filter(filter.at(0).toLatin1(), QVariant::fromValue(Sink::ApplicationDomain::Reference{filter.at(1).toLatin1()})); | 111 | const auto property = filter.value(0).toLatin1(); |
112 | query.filter(property, Sink::PropertyParser::parse(type.toLatin1(), property, filter.value(1))); | ||
113 | } | 113 | } |
114 | } | 114 | } |
115 | if (options.options.contains("id")) { | 115 | if (options.options.contains("id")) { |