Email Notification with Table of objects

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Re: Email Notification with Table of objects

Post by tford »

I always feel better when Henrik agrees 8)
Tom - V8.8 build 3137 - MySql / PostGres
kklosson
Posts: 1617
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Email Notification with Table of objects

Post by kklosson »

I did. :(
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Jaymer
Posts: 2430
Joined: Tue Jan 13, 2015 10:58 am
Location: Tampa, FL
Contact:

Re: Email Notification with Table of objects

Post by Jaymer »

It’s unfortunate that dicking around with this takes up so much time.
https://www.awareim.com/forum/viewtopic ... 70&p=51034

You might try converting to list line, just to see if it runs using your query.
Also check the tomcat output to see if it complains about a syntax issue.
Read that thread About the weirdness of the examples.

And you might not even be happy ultimately with the output of the list table.
Henrik just got improvements to that done a year ago because of a bug.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.

Jaymer
Aware Programming & Consulting - Tampa FL
aware_support
Posts: 7523
Joined: Sun Apr 24, 2005 12:36 am
Contact:

Re: Email Notification with Table of objects

Post by aware_support »

Check out the output of the Aware IM Server after you run the function - there must be some clues there.
Aware IM Support Team
kklosson
Posts: 1617
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Email Notification with Table of objects

Post by kklosson »

All of the logs indicate everything happened without a hitch. I see no errors or problems.
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
aware_support
Posts: 7523
Joined: Sun Apr 24, 2005 12:36 am
Contact:

Re: Email Notification with Table of objects

Post by aware_support »

Please attach the server log
Aware IM Support Team
kklosson
Posts: 1617
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Email Notification with Table of objects

Post by kklosson »

Gladly. Do you refer to the system.log in the AwareIM\bin folder?
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
aware_support
Posts: 7523
Joined: Sun Apr 24, 2005 12:36 am
Contact:

Re: Email Notification with Table of objects

Post by aware_support »

No, I refer to the output of the Aware IM Server. In the Control Panel select View/Server Console
Aware IM Support Team
Jhstephenson
Posts: 297
Joined: Wed Apr 22, 2015 11:44 pm

Re: Email Notification with Table of objects

Post by Jhstephenson »

Did this ever get resolved? I need to do something very similar and want to avoid any traps.

Thanks,
Jim
kklosson
Posts: 1617
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Email Notification with Table of objects

Post by kklosson »

It did form me. Say the word and I will describe the path.
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Jhstephenson
Posts: 297
Joined: Wed Apr 22, 2015 11:44 pm

Re: Email Notification with Table of objects

Post by Jhstephenson »

That would be great. Fire away.
kklosson
Posts: 1617
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Email Notification with Table of objects

Post by kklosson »

1. Create an HTML document with your needs.
2. In your notification, select that document for the HTML section of the notification.
3. Here's what my HTML document looks like. Useless to you except how to present a table. It provides some info, then a table of items. You can translate to your needs.
4. let me know if you get stuck.

Hello <<Investigator.FirstName>>,

You currently have <<Count PHS WHERE (PHS.Investigator=Investigator and PHS.Case_Stage<> '7 - Closed' AND PHS.Candidate.Status='Active')>> open investigations:
<<LIST_TABLE(`FIND PHS WHERE (PHS.Investigator=Investigator AND PHS.Case_Stage<> '7 - Closed' AND PHS.Candidate.Status='Active') ORDER By Case_DateOpened DESC`,`CandidateFullName`,`CandidateGroup`,`Case_DateOpened`,`Case_Stage`,`Case_ModifiedTimeStamp`)>>

You currently have <<Count Review WHERE(Review.Reviewer=Investigator AND (Review.Complete<>'Yes' OR Review.Complete IS UNDEFINED) AND Review.Results IS UNDEFINED) >> pending review assignments:
<<LIST_TABLE(`FIND Review WHERE Review.Reviewer=Investigator AND (Review.Complete<>'Yes' OR Review.Complete IS UNDEFINED) AND Review.Results IS UNDEFINED Order by Review.DateStarted`,`CandidateName`,`CandidateGroup`,`DateStarted`,`StartedBy`,`ReviewPurpose`,`NotesToReviewer`)>>

You currently have <<Count Task WHERE(Task.Investigator=Investigator AND Task.Status<>'Completed' AND Task.Status<>'Abandoned' AND Task.Status<>'Rejected' AND Task.DateInitiated IS DEFINED) >> pending tasks:
<<LIST_TABLE(`FIND Task WHERE(Task.Investigator=Investigator AND Task.Status<>'Completed' AND Task.Status<>'Abandoned' AND Task.Status<>'Rejected' AND Task.DateInitiated IS DEFINED) Order by Task.DateDue DESC`,`SC_CandidateFullName`,`TaskName`,`Status`,`InitiatedBy`,`DateDue`,`TaskDetails`)>>
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Jhstephenson
Posts: 297
Joined: Wed Apr 22, 2015 11:44 pm

Re: Email Notification with Table of objects

Post by Jhstephenson »

Well, I think I am stuck. I followed your steps and about the only thing I get is the subject is correct.

Here is what my HTML Document Looks like:

Code: Select all

<strong>Open PASS Reports Prepared By: </strong><<PASS_EmployeeReportSummary.Employee.Name>> <br>  
Date: <<CURRENT_DATE>><br> 

You currently have <<Count PASS WHERE (PASS.PreparedBy=PASS_EmployeeReportSummary.Employee and PASS.ReportProgress.ReportProgress=`Open`)>> open PASS Reports:

<<LIST_TABLE(`FIND PASS WHERE (PASS.PreparedBy=Employee and PASS.ReportProgress.ReportProgress=`Open`) ORDER By Date_Event DESC`,`tempEmployeeName`,`Date_Event_DatePartOnly`,`SummaryOfEvent`)>>
My subject line looks like this and it works:

Code: Select all

Open PASS Reports for <<PASS_EmployeeReportSummary.Employee.Name>>
The email message I receive when I run it looks like this:

Open PASS Reports for James Stephenson

Open PASS Reports Prepared By: <>
Date: <>

You currently have <> open PASS Reports:
<>


The process I run looks like this:

Code: Select all

FIND PASS_EmployeeReportSummary WHERE PASS_EmployeeReportSummary.scEmployeeStatus='Active' AND PASS_EmployeeReportSummary.Preparer_TotalOpenReports>0 IN BATCHES OF 1 
SEND OutgoingEmail_OpenReportsForPreparer TO PASS_EmployeeReportSummary.Employee 
Somewhere I am missing something. What seems odd to me is that even the CURRENT_DATE doesn't show anything.
kklosson
Posts: 1617
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Email Notification with Table of objects

Post by kklosson »

Looking at my HTML, I'm using the back-ass apostrophe in some places but not others. Might try that. Don't know about the CURRENT_DATE.
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Post Reply