Using custom fields in view and email

  • Stefano Bettega
  • Topic Author
  • Offline
  • New Member
  • New Member
More
11 years 4 months ago #33596 by Stefano Bettega
Using custom fields in view and email was created by Stefano Bettega
Hi Tuan,
I've been asked to add a Distributor name field to each member profile. This field contains the name of the vendor who sold the subscription to the final user. This data has to be used in two ways:
  1. when sending subscription expiration reminders, this field shoudl be included in email content, like [FIRST_NAME], [LAST_NAME], ...to generate an email body like "Dear [FIRST_NAME], [LAST_NAME], your [DISTRIBUTOR] subscription plan [PLAN_TITLE] is going to expire in...
  2. when listing subscrbers in administration backend, it should be visible and queried, to filter whose user come from a specific distributor (a combo box listing distributors is really not needed here, just a mere plain query is suitable)
I've added a custom field to any user profile, using the custom field editor, and field shows up. When exporting data fields is correctly contained into CSV, but I'm wondering how to get it visible in email and subscriber list..
I modified
Code:
/administrator/components/com_osmembership/views/subscribers/tmpl/default.php
to remove the net gross column (which we don't need) and I used
Code:
var_dump($row)
to view contents of available view query: custom fields are not listed here. I saw also that in
Code:
/administrator/components/com_osmembership/controllers/subscribers.php
there is the query to export custom fields. I'm wondering where is the query to generate the subscriber list and how to modify it, and also how to get this field and add it to email.

Thanks in advance and regards
Stefano

Please Log in or Create an account to join the conversation.

More
11 years 4 months ago #33606 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: Using custom fields in view and email
Hi Stefano

This will require some customization to the extension. Do you have a Skype account so that we can discuss more details about it ?

Tuan

Please Log in or Create an account to join the conversation.