Fabrik Home

Go Back   Fabrik > Fabrik 2.0.x > Bronze Subscriber Support


Bronze Subscriber Support This is the monitored support forum for Bronze Supporters. Although we do our best to answer all posts in Bronze support on a FIFO basis (First In, First Out) every day, sometimes we simply don't have the time to get to everyone. We leave it up to you to keep your issues on our radar! If you haven't received a response within one working day, it is likely that you will need to "bump" your thread (by posting a short, polite follow-up saying something like "friendly bump"). It also helps everyone if you remember to close your threads once they are resolved (using the Thread Tools menu). You can always re-open them later if need be.

Closed Thread
 
Thread Tools
Old 01-31-2010, 01:03 AM   #1
fudge4u
Junior Member
 
Join Date: Apr 2009
Location: Michigan, USA
Posts: 10
Thanks: 1
Thanked 0 Times in 0 Posts
fudge4u has not earned any Fabrik kudos yet
Default How can I Email form only when I change data?

I have a form in which I change data. For instance, I change an element {Gift_Orders___Status} from "Ordered" to "Shipped". I want to be able to trigger an email to the client only when I change the data in the field so they know when their gift has been shipped. Is there a code that I could use for the "condition" box of the email plugin to give the result "true" if that particular element has changed?

Using Fabrik 2.0

I originally posted this in the community forum, but re-posted it here, as I am a bronze subscriber.

BTW, I am very pleased with this component and can't wait to get familiar with all it has to offer.

fudge4u is offline  


Old 01-31-2010, 06:19 PM   #2
cheesegrits
Support Gopher
 
cheesegrits's Avatar
 
Join Date: Aug 2007
Location: Huntsville, AL
Posts: 16,760
Thanks: 167
Thanked 527 Times in 492 Posts
cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God cheesegrits is a Fabrik God
Send a message via MSN to cheesegrits Send a message via Yahoo to cheesegrits Send a message via Skype™ to cheesegrits
Default

Try ...

PHP Code:
$orig JArrayHelper::fromObject($this->formModel->_origData);
return (
$orig['Gift_Orders___Status'] != $this->data['Gift_Orders___Status']) && $this->data['Gift_Orders___Status'] == 'Shipped'
-- hugh
__________________
SVN Info
Unfuddle (username and password 'anonymous')
Tutorials
cheesegrits is offline  
Old 01-31-2010, 11:32 PM   #3
fudge4u
Junior Member
 
Join Date: Apr 2009
Location: Michigan, USA
Posts: 10
Thanks: 1
Thanked 0 Times in 0 Posts
fudge4u has not earned any Fabrik kudos yet
Default

Thanks so much. It seems to be working from the front end but not on the back even though I have it set to email on both. Not a big deal for me at the moment. May I also ask what code I can use to send an email no matter what I change the data to? I have several status codes I use for that field and am considering triggering the email on just a "change" no matter what it changes to.
fudge4u is offline  
Old 02-01-2010, 03:13 PM   #4
rob
Administrator
 
rob's Avatar
 
Join Date: Jan 2007
Location: La Rochelle France
Posts: 9,123
Thanks: 105
Thanked 389 Times in 366 Posts
rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God rob is a Fabrik God
Default

[qyote] May I also ask what code I can use to send an email no matter what I change the data to?[/quote]
try this:
PHP Code:
$orig JArrayHelper::fromObject($this->formModel->_origData);
return (
$orig['Gift_Orders___Status'] != $this->data['Gift_Orders___Status']); 
rob is offline  
Old 02-01-2010, 08:35 PM   #5
fudge4u
Junior Member
 
Join Date: Apr 2009
Location: Michigan, USA
Posts: 10
Thanks: 1
Thanked 0 Times in 0 Posts
fudge4u has not earned any Fabrik kudos yet
Default

Thanks so much! You have a great product and great service. Keep up the good work!
fudge4u is offline  
Closed Thread

Bookmarks

Tags
conditionals , email notifications , form processing

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I Email form only when I change data? fudge4u Community Support 2 02-02-2010 07:01 AM
Grouped data in a form not getting email sakina.ali Community Support 3 05-11-2009 04:08 AM
change existing data when change option values. matthieueyenet Feature Requests 0 05-06-2009 03:47 PM
Email in form don't change Zeus Community Support 5 05-27-2008 07:27 PM
Form email is sent blank with no data gtrilo Community Support 12 04-13-2007 10:21 AM

» Unfuddle SVN
Project: Fabrik 2.x
Rev Comment
3745 fixed: J1.5.20 with mootools upgrade plugin enabled - table and form plugin code in admin section was not working fixed: js...
3744 fixed issue with emailtable plus js on send button
3743 fixed: js issues with table plugins, js issues with new mootools 1.2.4 system upgrade plugin in Joomla 1.5.20
3742 http://fabrikar.com/forums/showthread.php?t=17010
3741 j1.6 installation work - should now be installable if you make a zip with the folllowing folders: admin (for the...
3740 j16 - added update xml manifest in theory this allows for discovery and installation of upgrades to the component by...
3739 fixed: fabrikyoutube barfed if you entered an URL containing "watch?v=" which is exactly what's in a youtube URL if you copy...
3738 j1.6 fixed spelling mistake in language folder name
3737 added installation instruction file
3736 fixed: js error in email table plus
Powered by vBadvanced CMPS v3.0.0

All times are GMT. The time now is 03:10 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Template-Modifications by TMS
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios