diff --git a/app/Views/notification.php b/app/Views/notification.php index b346857a..341871ec 100755 --- a/app/Views/notification.php +++ b/app/Views/notification.php @@ -421,7 +421,7 @@ - +
@@ -604,6 +604,18 @@ +
Attachments
+ + + + + + + + + +
AttachmentsAction
+
@@ -1439,8 +1451,8 @@ function addHTMLInput(data = null) { - console.log('addHTMLInput function called'); - console.log(template_name); + console.log(`:) addHTMLInput function called for ${template_name}`); // REF : PS + var container = ''; if (template_name == 'member_welcome_mail') { container = document.getElementById('attachment_tbody'); @@ -1448,6 +1460,9 @@ else if (template_name == 'member_common_mail') { container = document.getElementById('attachment_tbody_common'); } + else if (template_name == 'member_reminder_mail') { + container = document.getElementById('attachment_tbody_reminder'); + } else { container = document.getElementById('attachment_tbody_ecard'); } @@ -1472,20 +1487,39 @@ const newFormRow = document.createElement('tr'); newFormRow.className = 'dynamic-form-row'; - newFormRow.innerHTML = ` - -
-
-
- + // newFormRow.innerHTML = ` + // + // + //
+ //
+ // + //
+ //
+ // + //
+ //
+ // + // + // `; // DONT DELETE IT REF : VVJ + + newFormRow.innerHTML = ` +
+
+
+ +
+
+ +
-
- -
-
- - - `; + + `; // REF : PS container.appendChild(newFormRow); @@ -1493,21 +1527,38 @@ // If no data is passed, create a new empty row const newRow = document.createElement('tr'); newRow.className = 'dynamic-form-row'; + newRow.innerHTML = `
+
+
+ +
+
+ +
+
+
+ `; // REF : PS - newRow.innerHTML = ` - -
-
-
- -
-
- -
-
-
- - `; + // newRow.innerHTML = ` + // + //
+ //
+ //
+ // + //
+ //
+ // + //
+ //
+ //
+ // + // `; // DONT DELETE IT REF : VVJ container.appendChild(newRow); } } @@ -1519,6 +1570,9 @@ else if (template_name == 'member_common_mail') { container = document.getElementById('attachment_tbody_common'); } + else if (template_name == 'member_reminder_mail') { + container = document.getElementById('attachment_tbody_reminder'); + } else { const container = document.getElementById('attachment_tbody_ecard'); } @@ -1537,6 +1591,7 @@ // var template_name = template_name; var client_id = $('#general_PrimaryKey').val(); // console.log(client_id); + console.log(`:) Submitted for ${template_name}`); const formData = new FormData(form); formData.append('template_name', template_name); @@ -1771,7 +1826,7 @@ const validTemplates = [ "account_maneger_summary_mail", "member_reminder_mail","member_common_mail", "member_ecard_mail", "member_welcome_mail", "member_review_and_summary_mail", "client_hr_summary_mail" ]; - + console.log(`:) getMailTemplateData function called for ${template_name}`); // REF : PS if (!validTemplates.includes(template_name)) { console.error("Invalid template name:", template_name); return; @@ -1789,7 +1844,7 @@ type: "GET", dataType: 'json', success: function(res) { - console.log('get Mail Template Data', res); + console.log(':) getMailTemplateData Resp are', res); if (res) { // Set subject @@ -1840,6 +1895,8 @@ $('.testmail').toggle(!!res.id); $('#attachment_table').toggle(!!res.id); $('#attachment_table_ecard').toggle(!!res.id); + $('#attachment_table_common').toggle(!!res.id); + $('#attachment_table_reminder').toggle(!!res.id); $('.setid').attr('data-id', res.id || ''); if (template_name == "member_common_mail"){ $('#notification_temp_id').val(res.id);