Changeset 2265613
- Timestamp:
- 03/23/2020 05:56:44 AM (6 years ago)
- Location:
- cf7-db-tool/trunk
- Files:
-
- 4 edited
-
assets/js/cf7-db-bulkmail.js (modified) (5 diffs)
-
cf7-db-tool.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
src/Plugin.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
cf7-db-tool/trunk/assets/js/cf7-db-bulkmail.js
r2265274 r2265613 32 32 33 33 var Totalusers = document.getElementById("dbtool-user-list"); 34 var resetButton = document.getElementById('ResetData') 34 var resetButton = document.getElementById('ResetData'); 35 var TargetToInputForm = document.getElementById('dbtool-recipient-emails'); 35 36 36 37 function getSelectedOptions(sel, fn) { 37 38 var opts = [], opt; 38 39 39 // loop through options in select list 40 40 for (var i=0, len=sel.options.length; i<len; i++) { 41 41 opt = sel.options[i]; 42 43 42 // check if selected 44 if ( opt.selected ) {43 if ( opt.selected && !TargetToInputForm.value.includes(opt.value) ) { 45 44 // add to array of option elements to return from this function 46 45 opts.push(opt); 47 48 46 // invoke optional callback function if provided 49 47 if (fn) { … … 60 58 // display in textarea for this example 61 59 opt.setAttribute("disabled",'true') 62 var display = document.getElementById('dbtool-recipient-emails'); 63 if(display.value == ''){ 64 display.value += opt.value; 60 if(TargetToInputForm.value == ''){ 61 TargetToInputForm.value += opt.value; 65 62 }else{ 66 display.value += ',' + opt.value;63 TargetToInputForm.value += ',' + opt.value; 67 64 } 68 65 } … … 70 67 document.getElementById('dbtool-user-list').onchange = function(e) { 71 68 // get reference to display textarea 72 var display = document.getElementById('dbtool-recipient-emails'); 69 73 70 // callback fn handles selected options 74 71 getSelectedOptions(this, callback); 75 76 77 78 79 72 if(resetButton.computedStyleMap().get('cursor').value=='not-allowed') { 80 73 resetButton.style.cssText = "opacity: 1;cursor: pointer;" … … 84 77 // Funtion for select all email to receiver input 85 78 document.getElementById('select_all').onclick = function(e) { 86 var TargetToInputForm = document.getElementById('dbtool-recipient-emails');87 88 79 TargetToInputForm.value = ''; 89 80 var emailList = ""; … … 100 91 101 92 // Reset function for disable remove from mail list 102 103 93 resetButton.onclick = function(e) { 104 94 for (var i = 0; i < Totalusers.length; i++) { -
cf7-db-tool/trunk/cf7-db-tool.php
r2265276 r2265613 8 8 * Text Domain: cf7-db-tool 9 9 * Tags: contact, cf7, contact form 7, db, export, save, wpcf7, contact form 7 db, contact form 7 database, contact form 7 data export, contact form 7 database addon 10 * Version: 3.1. 210 * Version: 3.1.3 11 11 */ 12 12 13 define('CF7_DBT_VERSION', '3.1. 2');14 define('CF7_DBT_DB_VERSION', '3.1. 2');13 define('CF7_DBT_VERSION', '3.1.3'); 14 define('CF7_DBT_DB_VERSION', '3.1.3'); 15 15 define('CF7_DBT_PATH', __DIR__); 16 16 define('CF7_DBT_URL', plugins_url(basename(CF7_DBT_PATH))); -
cf7-db-tool/trunk/readme.txt
r2265276 r2265613 4 4 Requires at least: 4.8 5 5 Tested up to: 5.3 6 Stable tag: 3.1. 26 Stable tag: 3.1.3 7 7 License: GPLv2 or later 8 8 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 28 28 * Send individual reply email form admin (Available if form submission contains any email address) 29 29 * Bulk email * 30 * Choose users mail form specefic form31 30 32 31 Upcoming features: -
cf7-db-tool/trunk/src/Plugin.php
r2263980 r2265613 233 233 foreach ($results as $mail){ 234 234 $fields = unserialize($mail->fields); 235 236 235 if(!in_array($fields["your-email"],$usersEmail)){ 237 236 array_push($usersEmail,$fields["your-email"]); 238 237 } 239 240 238 } 241 239 foreach ($usersEmail as $email){
Note: See TracChangeset
for help on using the changeset viewer.