@@ 68-85 (lines=18) @@ | ||
65 | ||
66 | // テンプレート変更の場合は. バリデーション前に内容差し替え. |
|
67 | if ($mode == 'change') { |
|
68 | if ($form->get('template')->isValid()) { |
|
69 | /** @var $data \Eccube\Entity\MailTemplate */ |
|
70 | $MailTemplate = $form->get('template')->getData(); |
|
71 | $form = $builder->getForm(); |
|
72 | $event = new EventArgs( |
|
73 | array( |
|
74 | 'form' => $form, |
|
75 | 'Order' => $Order, |
|
76 | 'MailTemplate' => $MailTemplate, |
|
77 | ), |
|
78 | $request |
|
79 | ); |
|
80 | $app['eccube.event.dispatcher']->dispatch(EccubeEvents::ADMIN_ORDER_MAIL_INDEX_CHANGE, $event); |
|
81 | $form->get('template')->setData($MailTemplate); |
|
82 | $form->get('subject')->setData($MailTemplate->getSubject()); |
|
83 | $form->get('header')->setData($MailTemplate->getHeader()); |
|
84 | $form->get('footer')->setData($MailTemplate->getFooter()); |
|
85 | } |
|
86 | } else if ($form->isValid()) { |
|
87 | switch ($mode) { |
|
88 | case 'confirm': |
|
@@ 231-249 (lines=19) @@ | ||
228 | ||
229 | // テンプレート変更の場合は. バリデーション前に内容差し替え. |
|
230 | if ($mode == 'change') { |
|
231 | if ($form->get('template')->isValid()) { |
|
232 | /** @var $data \Eccube\Entity\MailTemplate */ |
|
233 | $MailTemplate = $form->get('template')->getData(); |
|
234 | $form = $builder->getForm(); |
|
235 | ||
236 | $event = new EventArgs( |
|
237 | array( |
|
238 | 'form' => $form, |
|
239 | 'MailTemplate' => $MailTemplate, |
|
240 | ), |
|
241 | $request |
|
242 | ); |
|
243 | $app['eccube.event.dispatcher']->dispatch(EccubeEvents::ADMIN_ORDER_MAIL_MAIL_ALL_CHANGE, $event); |
|
244 | ||
245 | $form->get('template')->setData($MailTemplate); |
|
246 | $form->get('subject')->setData($MailTemplate->getSubject()); |
|
247 | $form->get('header')->setData($MailTemplate->getHeader()); |
|
248 | $form->get('footer')->setData($MailTemplate->getFooter()); |
|
249 | } |
|
250 | } else if ($form->isValid()) { |
|
251 | switch ($mode) { |
|
252 | case 'confirm': |