Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Leif Andersson
ReglerAddress
Commits
e0feda08
Commit
e0feda08
authored
Sep 12, 2015
by
Leif Andersson
Browse files
Added handling of mailinglists when email changes.
parent
5304073d
Changes
2
Hide whitespace changes
Inline
Side-by-side
action.add_edit.php
View file @
e0feda08
...
...
@@ -62,7 +62,7 @@ foreach ($simpleFields as $key => $name) {
$place
=
$this
->
CreateInputText
(
$id
,
$key
,
$person
->
$key
,
30
);
$smarty
->
assign
(
'input_'
.
$key
,
$place
);
}
$smarty
->
assign
(
'title_Andrad'
,
'Ändrad'
);
$smarty
->
assign
(
'title_Andrad'
,
'Ändrad'
);
$smarty
->
assign
(
'value_Andrad'
,
$person
->
Andrad
);
foreach
(
$areaFields
as
$key
=>
$name
)
{
...
...
@@ -89,13 +89,14 @@ if ($ID) {
$smarty
->
assign
(
'groupsButton'
,
$place
);
$epost
=
$person
->
Epost
;
$place
=
''
;
foreach
(
Person
::
$firstFields
as
$field
)
{
if
(
isset
(
$params
[
$field
]))
{
$place
.
=
$this
->
CreateInputHidden
(
$id
,
$field
,
$params
[
$field
]);
}
}
$place
.
=
$this
->
CreateInputHidden
(
$id
,
'oldEpost'
,
$epost
);
$smarty
->
assign
(
'hidden'
,
$place
);
...
...
action.changeDatabase.php
View file @
e0feda08
<?php
require_once
'lib/class.Group.php'
;
if
(
!
isset
(
$gCms
))
exit
;
//
echo '<pre>'; print_r($params); echo '</pre>'; exit;
//echo '<pre>'; print_r($params); echo '</pre>'; exit;
if
(
!
$this
->
CheckPermission
(
'Use ReglerAddress'
))
{
return
$this
->
DisplayErrorPage
(
$id
,
$params
,
$returnid
,
'ReglerAddress access denied.'
);
}
if
(
isset
(
$params
[
'doGroups'
]))
{
$paramsB
=
array
();
foreach
(
Person
::
$firstFields
as
$field
)
{
...
...
@@ -33,7 +36,7 @@ if (isset($params['cancelUpdate'])) {
if
(
isset
(
$params
[
'submit'
]))
{
$record
=
new
Person
(
$params
);
echo
'<pre>'
;
print_r
(
$record
);
echo
'</pre>'
;
//
echo '<pre>'; print_r($record); echo '</pre>';
$record
->
updateRecord
();
$paramsB
[
'module_message'
]
=
'Adressinformation ändrad'
;
foreach
(
Person
::
$firstFields
as
$field
)
{
...
...
@@ -41,6 +44,10 @@ if (isset($params['submit'])) {
$paramsB
[
$field
]
=
$params
[
$field
];
}
}
if
(
isset
(
$params
[
'oldEpost'
])
&&
isset
(
$params
[
'Epost'
]))
{
if
(
$params
[
'oldEpost'
]
!=
$params
[
'Epost'
])
Group
::
setMailLists
();
}
$this
->
Redirect
(
$id
,
'defaultadmin'
,
$returnid
,
$paramsB
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment