Update contact data class and reset the member type back.
authorSteve Sutton <steve@gaslightmedia.com>
Mon, 2 Jul 2018 20:46:49 +0000 (16:46 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Mon, 2 Jul 2018 20:46:49 +0000 (16:46 -0400)
Placing the member type in export back to original location.
Commenting out the force_list parts in the fields array for the data
class.

classes/data/dataContacts.php
views/admin/ajax/contactsListExport.html
views/admin/ajax/contactsListExportCsv.html
views/admin/contacts/index.html

index 0a27159..be75079 100644 (file)
@@ -133,7 +133,7 @@ class GlmDataContacts extends GlmDataAbstract
                     'l_blank' => true,
                 'required' => true,
                 'default' => 30,
-                'force_list' => true,
+                // 'force_list' => true,
                 'view_only' => $limitedEdit,
                 'use' => 'a'
             ),
@@ -169,7 +169,7 @@ class GlmDataContacts extends GlmDataAbstract
                 'list' => $this->config['contact_type'],
                 'required' => true,
                 'default' => $this->config['contact_type_numb']['Personal'],
-                'force_list' => true,
+                // 'force_list' => true,
                 'view_only' => $limitedEdit,
                 'use' => 'a'
             ),
@@ -181,7 +181,7 @@ class GlmDataContacts extends GlmDataAbstract
                 'list' => $this->config['contact_role'],
                 'required' => true,
                 'default' => $this->config['contact_role_numb']['EntityManager'],
-                'force_list' => true,
+                // 'force_list' => true,
                 'view_only' => $limitedEdit,
                 'use' => 'a'
             ),
@@ -245,7 +245,7 @@ class GlmDataContacts extends GlmDataAbstract
                     'p_field' => 'name',
                     'p_orderby' => 'name',
                     'p_blank' => true,
-                'force_list' => true,
+                // 'force_list' => true,
                 'use' => 'a'
             ),
 
@@ -262,7 +262,7 @@ class GlmDataContacts extends GlmDataAbstract
                 'type' => 'list',
                 'list' => $this->config['states'],
                 'default' => 'MI',
-                'force_list' => true,
+                // 'force_list' => true,
                 'use' => 'a'
             ),
 
@@ -279,7 +279,7 @@ class GlmDataContacts extends GlmDataAbstract
                 'type' => 'list',
                 'list' => $this->config['countries'],
                 'default' => 'US',
-                'force_list' => true,
+                // 'force_list' => true,
                 'use' => 'a'
             ),
 
index 1548949..ffbd14f 100644 (file)
@@ -12,7 +12,6 @@
             <thead>
                 <tr>
                     {if $select.exportId}<th align="left">ID</th>{/if}
-                    {if $select.exportMemberType}<th align="left">Member Type</th>{/if}
                     {if $select.exportFname}<th align="left">First Name</th>{/if}
                     {if $select.exportLname}<th align="left">Last Name</th>{/if}
                     {if $select.exportAddr1}<th align="left">Address 1</th>{/if}
@@ -31,6 +30,7 @@
                     {if $select.exportFax}<th align="left">Fax</th>{/if}
                     {if $select.exportEmail}<th align="left">E-Mail</th>{/if}
                     {if $select.exportAltEmail}<th align="left">Alt E-Mail</th>{/if}
+                    {if $select.exportMemberType}<th align="left">Member Type</th>{/if}
                     {if $CFHeaders}{foreach $CFHeaders as $cHead}<th align="left">{$cHead}</th>{/foreach}{/if}
                 </tr>
             </thead>
@@ -39,7 +39,6 @@
         {foreach $contacts as $m}
                 <tr>
                     {if $select.exportId}<td>{$m.id}</td>{/if}
-                    {if $select.exportMemberType}<td>{$m.member_type}</td>{/if}
                     {if $select.exportFname}<td>{$m.fname}</td>{/if}
                     {if $select.exportLname}<td>{$m.lname}</td>{/if}
                     {if $select.exportAddr1}<td>{$m.addr1}</td>{/if}
@@ -58,6 +57,7 @@
                     {if $select.exportFax}<td>{$m.fax}</td>{/if}
                     {if $select.exportEmail}<td>{$m.email}</td>{/if}
                     {if $select.exportAltEmail}<td>{$m.alt_email}</td>{/if}
+                    {if $select.exportMemberType}<td>{$m.member_type}</td>{/if}
                     {if $CFHeaders}{foreach $CFHeaders as $cHead}<td>{$m[$cHead]}</td>{/foreach}{/if}
 
                 </tr>
index 198f22d..c45eba3 100644 (file)
@@ -1,7 +1,5 @@
 {if $haveMembers}
-
 {if $select.exportId}"ID",{/if}
-{if $select.exportMemberType}"Member Type",{/if}
 {if $select.exportFname}"First Name",{/if}
 {if $select.exportLname}"Last Name",{/if}
 {if $select.exportAddr1}"Address 1",{/if}
 {if $select.exportFax}"Fax",{/if}
 {if $select.exportEmail}"E-Mail",{/if}
 {if $select.exportAltEmail}"Alt E-Mail",{/if}
+{if $select.exportMemberType}"Member Type",{/if}
 {if $CFHeaders}{foreach $CFHeaders as $cHead}"{$cHead}",{/foreach}{/if}
 
 {foreach $contacts as $m}
 {if $select.exportId}"{$m.id}",{/if}
-{if $select.exportMemberType}"{$m.member_type}",{/if}
 {if $select.exportFname}"{$m.fname}",{/if}
 {if $select.exportLname}"{$m.lname}",{/if}
 {if $select.exportAddr1}"{$m.addr1}",{/if}
@@ -43,6 +41,7 @@
 {if $select.exportFax}"{$m.fax}",{/if}
 {if $select.exportEmail}"{$m.email}",{/if}
 {if $select.exportAltEmail}"{$m.alt_email}",{/if}
+{if $select.exportMemberType}"{$m.member_type}",{/if}
 {if $CFHeaders}{foreach $CFHeaders as $cHead}"{$m[$cHead]}",{/foreach}{/if}
 
 {/foreach}
index 7eb1c0d..9b295cf 100644 (file)
                             <tr>
                             <td class="exportFieldsTd">
                                 <input type="checkbox" name="exportId"> Contact ID<br>
-                                <input type="checkbox" name="exportMemberType" checked> Member Type<br>
                                 <input type="checkbox" name="exportFname" checked> First Name<br>
                                 <input type="checkbox" name="exportLname" checked> Last Name<br>
                                 <input type="checkbox" name="exportAddr1" checked> Address 1<br>
                                 <input type="checkbox" name="exportCounty" checked> County<br>
                                 <input type="checkbox" name="exportState" checked> State<br>
                                 <input type="checkbox" name="exportZip" checked> ZIP<br>
+                                <input type="checkbox" name="exportCountry" checked> Country<br>
                             </td>
                             <td class="exportFieldsTd">
-                                <input type="checkbox" name="exportCountry" checked> Country<br>
                                 <input type="checkbox" name="exportOrg" checked> Organization<br>
                                 <input type="checkbox" name="exportTitle" checked> Title/Position<br>
                                 <input type="checkbox" name="exportOfficePhone" checked> Office Phone<br>
                                 <input type="checkbox" name="exportFax" checked> Fax Phone<br>
                                 <input type="checkbox" name="exportEmail" checked> Email<br>
                                 <input type="checkbox" name="exportAltEmail" checked> Alt Email<br>
+                                <input type="checkbox" name="exportMemberType" checked> Member Type<br>
                             </td>
                             </tr>
                         </table>