Skip to content
Snippets Groups Projects
Commit 69b193bd authored by Robert Habermann's avatar Robert Habermann
Browse files

bump to 0.1.13

parent 63bcf0b4
No related branches found
No related tags found
No related merge requests found
......@@ -13,15 +13,13 @@ This project adheres to [Semantic Versioning](http://semver.org/).
0.2.0 - planned first release
-----------------------------
0.1.12 - 2016-11-04
0.1.13 - 2016-11-04
-------------------
- fix bug when https_verify is disabled
0.1.11 - 2016-11-04
-------------------
- add link api
- add dynamic_field_get access
- add article_get access
- add ticket_search_dynamic_field
0.1.10 - 2016-09-16
-------------------
......
......@@ -1109,6 +1109,43 @@ class Client(object):
else:
return self.result
def ticket_search_dynamic_field(self, name, value_list, operator=None):
"""Wrapper for search ticket
Args:
name (str): Name of DynamicField which the search should check
value_list (list): list of values to search for
operator (str): Search operator (defaults to: "Equals")
Valid options are:
"Equals", "Like", "GreaterThan", "GreaterThanEquals",
"SmallerThan", "SmallerThanEquals"
Returns:
**list** or **False**: The search result (as list) if successful, otherwise **False**.
"""
if not self.session_id_store.value:
raise SessionNotCreated("Call session_create() or "
"session_restore_or_set_up_new() first")
self.operation = "TicketSearch"
payload = {
"SessionID": self.session_id_store.value,
}
if not operator:
operator = "Equals"
else:
if operator not in ["Equals", "Like", "GreaterThan", "GreaterThanEquals",
"SmallerThan", "SmallerThanEquals"]:
raise NotImplementedError("Invalid Operator: \"{0}\"".format(operator))
payload.update({"DynamicField_{0}".format(name): {operator: value_list}})
if not self._parse_and_validate_response(self._send_request(payload)):
return False
else:
return self.result
def ticket_search_full_text(self, pattern):
"""Wrapper for search ticket for full text search
......
......@@ -4,5 +4,5 @@
# 3) we can import it into your module module
"""
__version_info__ = ('0', '1', '12')
__version_info__ = ('0', '1', '13')
__version__ = '.'.join(__version_info__)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment