Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Stud.IP
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
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
Code review analytics
Issue analytics
Insights
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
Jan-Hendrik Willms
Stud.IP
Commits
4448e403
Commit
4448e403
authored
5 months ago
by
Jan-Hendrik Willms
Browse files
Options
Downloads
Patches
Plain Diff
add missing configurations for personal notifications, fixes #4711
Closes #4711 Merge request
studip/studip!3504
parent
040d121f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
db/migrations/5.3.24_add_personal_notification_configurations.php
+38
-0
38 additions, 0 deletions
...tions/5.3.24_add_personal_notification_configurations.php
with
38 additions
and
0 deletions
db/migrations/5.3.24_add_personal_notification_configurations.php
0 → 100644
+
38
−
0
View file @
4448e403
<?php
final
class
AddPersonalNotificationConfigurations
extends
Migration
{
public
function
description
()
{
return
'Adds missing configurations for "PERSONAL_NOTIFICATIONS_DEACTIVATED" and "PERSONAL_NOTIFICATIONS_AUDIO_DEACTIVATED"'
;
}
protected
function
up
()
{
$query
=
"INSERT IGNORE INTO `config`
(`field`, `value`, `type`, `range`, `mkdate`, `chdate`, `description`)
VALUES (:field, :value, 'boolean', 'user', UNIX_TIMESTAMP(), UNIX_TIMESTAMP(), :description)"
;
$statement
=
DBManager
::
get
()
->
prepare
(
$query
);
$statement
->
execute
([
':field'
=>
'PERSONAL_NOTIFICATIONS_DEACTIVATED'
,
':value'
=>
'0'
,
':description'
=>
'Deaktiviert die persönlichen Benachrichtigungen'
,
]);
$statement
->
execute
([
':field'
=>
'PERSONAL_NOTIFICATIONS_AUDIO_DEACTIVATED'
,
':value'
=>
'0'
,
':description'
=>
'Deaktiviert das Abspielen von Tönen für die persönlichen Benachrichtigungen'
,
]);
}
protected
function
down
()
{
$query
=
"DELETE FROM `config`
WHERE `field` IN (
'PERSONAL_NOTIFICATIONS_DEACTIVATED',
'PERSONAL_NOTIFICATIONS_AUDIO_DEACTIVATED'
)"
;
DBManager
::
get
()
->
execute
(
$query
);
}
}
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