|
|
@@ -204,33 +204,6 @@ class EditListDataProvider extends AddListDataProvider
|
|
|
public function update()
|
|
|
{
|
|
|
|
|
|
- /**
|
|
|
- *
|
|
|
- * provided aliases
|
|
|
- */
|
|
|
- $customEmails = explode(',',$this->formData['emailAliases']);
|
|
|
- $this->formData['emailAliases'] = [];
|
|
|
- foreach($customEmails as $email)
|
|
|
- {
|
|
|
- if ($email !== '')
|
|
|
- {
|
|
|
- $this->formData['emailAliases'][] = $email;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * provided owners
|
|
|
- */
|
|
|
- $owners = explode(',',$this->formData['owners']);
|
|
|
- $this->formData['owners'] = [];
|
|
|
- foreach($owners as $email)
|
|
|
- {
|
|
|
- if ($email !== '')
|
|
|
- {
|
|
|
- $this->formData['owners'][] = $email;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
/**
|
|
|
* display name
|
|
|
*/
|
|
|
@@ -268,28 +241,13 @@ class EditListDataProvider extends AddListDataProvider
|
|
|
$productManager = new ProductManager();
|
|
|
$productManager->loadByHostingId($hid);
|
|
|
|
|
|
- /**
|
|
|
- * load kerio manager by hosting id
|
|
|
- */
|
|
|
- $service = (new KerioManager())
|
|
|
- ->getApiByHosting($hid)
|
|
|
- ->soap
|
|
|
- ->service()
|
|
|
- ->updateDistributionList()
|
|
|
- ->setFormData($this->formData)
|
|
|
- ->setProductManager($productManager)
|
|
|
-
|
|
|
- ;
|
|
|
-
|
|
|
- /**
|
|
|
- *
|
|
|
- */
|
|
|
- $result = $service->run();
|
|
|
-
|
|
|
- if(!$result)
|
|
|
- {
|
|
|
- return (new HtmlDataJsonResponse())->setMessageAndTranslate($service->getError())->setStatusError();
|
|
|
- }
|
|
|
+ logModuleCall(
|
|
|
+ 'kerioEmail',
|
|
|
+ __FUNCTION__,
|
|
|
+ $this->formData,
|
|
|
+ 'Debug Formdata',
|
|
|
+ $hid
|
|
|
+ );
|
|
|
|
|
|
return (new HtmlDataJsonResponse())->setMessageAndTranslate('distributionListHasBeenUpdated')->setStatusSuccess();
|
|
|
|