Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kontaktverfolgung
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package 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
studip-plugins-oeffentlich
Kontaktverfolgung
Commits
f807c5eb
Commit
f807c5eb
authored
4 years ago
by
Thomas Hackl
Browse files
Options
Downloads
Patches
Plain Diff
allow search via matriculation number in contact search
parent
f90398c0
No related branches found
Branches containing commit
Tags
v1.7.1
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
controllers/tracersearch.php
+22
-1
22 additions, 1 deletion
controllers/tracersearch.php
plugin.manifest
+1
-1
1 addition, 1 deletion
plugin.manifest
with
23 additions
and
2 deletions
controllers/tracersearch.php
+
22
−
1
View file @
f807c5eb
...
...
@@ -41,7 +41,28 @@ class TracersearchController extends AuthenticatedController
{
Navigation
::
activateItem
(
'/search/tracer/search'
);
$this
->
qs
=
QuickSearch
::
get
(
'user'
,
new
StandardSearch
(
'user_id'
))
->
withButton
();
if
(
Config
::
get
()
->
CONTACT_TRACER_MATRICULATION_DATAFIELD_ID
!=
null
)
{
$sql
=
"SELECT DISTINCT auth_user_md5.user_id, CONCAT(auth_user_md5.Nachname, ', ', "
.
"auth_user_md5.Vorname, ' (', auth_user_md5.username, ')'), auth_user_md5.perms "
.
"FROM auth_user_md5 "
.
"LEFT JOIN user_info ON (user_info.user_id = auth_user_md5.user_id) "
.
"LEFT JOIN user_visibility ON (user_visibility.user_id = auth_user_md5.user_id) "
.
"LEFT JOIN datafields_entries ON (datafields_entries.range_id = auth_user_md5.user_id "
.
"AND datafields_entries.datafield_id = "
.
DBManager
::
get
()
->
quote
(
Config
::
get
()
->
CONTACT_TRACER_MATRICULATION_DATAFIELD_ID
)
.
") "
.
"WHERE ((CONCAT(auth_user_md5.Vorname, ' ', auth_user_md5.Nachname) LIKE REPLACE(:input, ' ', '% ') "
.
"OR CONCAT(auth_user_md5.Nachname, ' ', auth_user_md5.Vorname) LIKE REPLACE(:input, ' ', '% ') "
.
"OR CONCAT(auth_user_md5.Nachname, ', ', auth_user_md5.Vorname) LIKE :input "
.
"OR auth_user_md5.username LIKE :input) AND "
.
get_vis_query
(
'auth_user_md5'
,
'search'
)
.
" OR datafields_entries.content LIKE :input) "
.
" AND auth_user_md5.visible != 'never' "
.
" ORDER BY Nachname ASC, Vorname ASC"
;
$search
=
new
SQLSearch
(
$sql
,
dgettext
(
'tracer'
,
'Person suchen'
),
'user_id'
);
}
else
{
$search
=
new
StandardSearch
(
'user_id'
);
}
$this
->
qs
=
QuickSearch
::
get
(
'user'
,
$search
)
->
withButton
();
$days
=
Config
::
get
()
->
CONTACT_TRACER_DAYS_BEFORE_AUTO_DELETION
;
...
...
This diff is collapsed.
Click to expand it.
plugin.manifest
+
1
−
1
View file @
f807c5eb
pluginname=Kontaktverfolgung
pluginclassname=ContactTracer
origin=upa
version=1.7.
0
version=1.7.
1
description=Trace contacts and personal presence via Stud.IP
studipMinVersion=4.2
studipMaxVersion=4.9.99
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