You want to notify sales representatives about orders that have a high rate of return.
You decide to add an email task. You specify that the
email message use HTML format. When you edit an HTML message, you
can click a button that inserts a table. You list return values
by order number in a table. Then you attach to the email message
both the report that you saved previously , and the event list showing the event instances for
which the agent performed its tasks.
In the I want to area, click Add a task.
Click Send an email.
Click the source tab ,
and expand Sales (query).
Expand Sales Staff.
Click Email and drag it to the To: box.
In the Subject box, type
Urgent: Please contact customer
In the Body box, type:
Please contact your customer about the following returned order(s), and determine how to prevent it from happening again
Add a table to the Body message:
Click the insert table button .
Type 4 in the Number of columns box, type 2 in the Number of rows box, and click OK.
Type the column headings in the first row:
In the first cell, type
Order Number
In the second cell, type
Value of items returned
In the third cell, type
Reason description
In the fourth cell, type
Customer name (see attached contact information)
Select the heading row, and click the bold button .
Enter data items in the second row:
Click the source tab, expand Sales (query), then expand Order, and click Order number and drag it to the first cell.
Click the data items tab ,
click total_return_value_calc, and drag it
to the second cell.
Click the source tab, expand Returned items (query), then expand Return reason, and click Reason description and drag it to the third cell.
Expand Sales (query), then expand Retailer site, and click Retailer name and drag it to the fourth cell.
In the Body box, after the table, type
Thanks, the GO Sales Customer Loyalty Team
Click Attach, and click Attach the event output.
Click Attach, and click Attach the report Customer Contact.
Save the agent.
The next step in the creating an agent tutorial is to change the task execution rules for the email task.