e
Showing
1 changed file
with
24 additions
and
5 deletions
| ... | @@ -324,16 +324,22 @@ function getInputFormValues($validation, $name) { | ... | @@ -324,16 +324,22 @@ function getInputFormValues($validation, $name) { |
| 324 | } | 324 | } |
| 325 | }); | 325 | }); |
| 326 | }); | 326 | }); |
| 327 | |||
| 327 | 328 | ||
| 328 | function updateNotificationType() { | 329 | function updateNotificationType() { |
| 329 | var type = jQuery('#notif_type').val(); | 330 | var type = jQuery('#notif_type').val(); |
| 330 | var date = new Date().toLocaleDateString("en-US", {year: 'numeric', month: 'long', day: 'numeric'}); | 331 | var date = new Date().toLocaleDateString("en-US", {year: 'numeric', month: 'long', day: 'numeric'}); |
| 332 | |||
| 333 | |||
| 334 | |||
| 335 | |||
| 336 | |||
| 331 | 337 | ||
| 332 | var header ='<link rel="stylesheet" href="https://cbvinstitute.com/assets/css/custom-editor-style.css" type="text/css" media="all"><div><span style="font-size: 9.5pt;">If you are unable to clearly view the below E-Flash, please click<b><a><span style="font-weight: normal;"> here</span></a></b></span><hr /><img class=""alignnone" src="https://cbvinstitute.com/wp-content/uploads/2019/02/email_logo.png" alt="Logo" width="81" height="57" align="left" /><span style="font-size: 9.5pt; line-height: 115%; float: right;">'+date+'</span><div>'; | 338 | var header ='<div><span style="font-size: 9.5pt;">If you are unable to clearly view the below E-Flash, please click<b><a><span style="font-weight: normal;"> here</span></a></b></span><hr /><img class=""alignnone" src="https://cbvinstitute.com/wp-content/uploads/2019/02/email_logo.png" alt="Logo" width="81" height="57" align="left" /><span style="font-size: 9.5pt; line-height: 115%; float: right;">'+date+'</span><div>'; |
| 333 | 339 | ||
| 334 | var footer ='<div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><p class="footer"><strong><span style="font-family: GothamLight; font-size: 12px;"> To opt out, please:<br />1. Log in to cicbv.ca<br />2. Click on your name<br />3. From the drop down menu select profile<br />4. Edit E-flash settings<br />If you have any questions, please contact us: admin@cicbv.ca<br /></span></strong></p>' | 340 | var footer ='<div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><p class="footer"><strong><span style="font-family: GothamLight; font-size: 12px;"> To opt out, please:<br />1. Log in to cicbv.ca<br />2. Click on your name<br />3. From the drop down menu select profile<br />4. Edit E-flash settings<br />If you have any questions, please contact us: admin@cicbv.ca<br /></span></strong></p>' |
| 335 | 341 | ||
| 336 | var header_fr ='<link rel="stylesheet" href="https://cbvinstitute.com/assets/css/custom-editor-style.css" type="text/css" media="all"><div><span style="font-size: 9.5pt;">If you are unable to clearly view the below E-Flash, please click<b><a><span style="font-weight: normal;"> here</span></a></b></span><hr /><img class=""alignnone" src="https://cbvinstitute.com/wp-content/uploads/2019/02/email_logo_fr.png" alt="Logo" width="81" height="57" align="left" /><span style="font-size: 9.5pt; line-height: 115%; float: right;">'+date+'</span><div>'; | 342 | var header_fr ='<div><span style="font-size: 9.5pt;">If you are unable to clearly view the below E-Flash, please click<b><a><span style="font-weight: normal;"> here</span></a></b></span><hr /><img class=""alignnone" src="https://cbvinstitute.com/wp-content/uploads/2019/02/email_logo_fr.png" alt="Logo" width="81" height="57" align="left" /><span style="font-size: 9.5pt; line-height: 115%; float: right;">'+date+'</span><div>'; |
| 337 | 343 | ||
| 338 | var footer_fr ='<div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><p class="footer"><strong><span style="font-family: GothamLight; font-size: 12px;"> To opt out, please:<br />1. Log in to cicbv.ca<br />2. Click on your name<br />3. From the drop down menu select profile<br />4. Edit E-flash settings<br />If you have any questions, please contact us: admin@cicbv.ca<br /></span></strong></p>' | 344 | var footer_fr ='<div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><div> </div><p class="footer"><strong><span style="font-family: GothamLight; font-size: 12px;"> To opt out, please:<br />1. Log in to cicbv.ca<br />2. Click on your name<br />3. From the drop down menu select profile<br />4. Edit E-flash settings<br />If you have any questions, please contact us: admin@cicbv.ca<br /></span></strong></p>' |
| 339 | 345 | ||
| ... | @@ -344,13 +350,26 @@ function getInputFormValues($validation, $name) { | ... | @@ -344,13 +350,26 @@ function getInputFormValues($validation, $name) { |
| 344 | jQuery('.scheduled_sendto').hide(); | 350 | jQuery('.scheduled_sendto').hide(); |
| 345 | jQuery('.trigger-extended').show(); | 351 | jQuery('.trigger-extended').show(); |
| 346 | }else if (type == "newsletter") { | 352 | }else if (type == "newsletter") { |
| 347 | jQuery('.scheduled-extended').show(); | 353 | |
| 354 | $.ajax({ | ||
| 355 | url : "http://"+window.location.hostname+"/wp-content/themes/cbv/assets/css/custom-editor-style.css", | ||
| 356 | dataType: "text", | ||
| 357 | success : function (result) { | ||
| 358 | var style = '<style>'+result+'</style>'; | ||
| 359 | |||
| 360 | jQuery('.scheduled-extended').show(); | ||
| 348 | jQuery('.trigger-extended').hide(); | 361 | jQuery('.trigger-extended').hide(); |
| 349 | jQuery(".text_verson").hide(); | 362 | jQuery(".text_verson").hide(); |
| 350 | jQuery('.attachments').hide(); | 363 | jQuery('.attachments').hide(); |
| 351 | jQuery('.scheduled_sendto').show(); | 364 | jQuery('.scheduled_sendto').show(); |
| 352 | $(tinymce.get('en_html').getBody()).html(header+footer); | 365 | $(tinymce.get('en_html').getBody()).html(style +header+footer); |
| 353 | $(tinymce.get('fr_html').getBody()).html(header_fr+footer_fr); | 366 | $(tinymce.get('fr_html').getBody()).html(style +header_fr+footer_fr); |
| 367 | } | ||
| 368 | }); | ||
| 369 | |||
| 370 | |||
| 371 | |||
| 372 | |||
| 354 | jQuery('#execute_date').datetimepicker({ | 373 | jQuery('#execute_date').datetimepicker({ |
| 355 | format: 'Y-m-d, H:i', | 374 | format: 'Y-m-d, H:i', |
| 356 | defaultDate: new Date() | 375 | defaultDate: new Date() | ... | ... |
-
Please register or sign in to post a comment