Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PyOTRS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Coopdevs
Som Connexió
OTRS
PyOTRS
Commits
69b193bd
Commit
69b193bd
authored
8 years ago
by
Robert Habermann
Browse files
Options
Downloads
Patches
Plain Diff
bump to 0.1.13
parent
63bcf0b4
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
CHANGELOG.rst
+2
-4
2 additions, 4 deletions
CHANGELOG.rst
pyotrs/lib.py
+37
-0
37 additions, 0 deletions
pyotrs/lib.py
pyotrs/version.py
+1
-1
1 addition, 1 deletion
pyotrs/version.py
with
40 additions
and
5 deletions
CHANGELOG.rst
+
2
−
4
View file @
69b193bd
...
...
@@ -13,15 +13,13 @@ This project adheres to [Semantic Versioning](http://semver.org/).
0.2.0 - planned first release
-----------------------------
0.1.1
2
- 2016-11-04
0.1.1
3
- 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
-------------------
...
...
This diff is collapsed.
Click to expand it.
pyotrs/lib.py
+
37
−
0
View file @
69b193bd
...
...
@@ -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
...
...
This diff is collapsed.
Click to expand it.
pyotrs/version.py
+
1
−
1
View file @
69b193bd
...
...
@@ -4,5 +4,5 @@
# 3) we can import it into your module module
"""
__version_info__
=
(
'
0
'
,
'
1
'
,
'
1
2
'
)
__version_info__
=
(
'
0
'
,
'
1
'
,
'
1
3
'
)
__version__
=
'
.
'
.
join
(
__version_info__
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment