Clarity

Expand all | Collapse all

GEL EMAIL CC

  • 1.  GEL EMAIL CC

    Posted Mar 03, 2015 11:26 AM

    This may be redundant, and if there is a thread out there already, please delete this one, but I have been unable to find much on the way of CC for gel:email.

     

    When I try, it says CC is not supported. I checked out the jakarta website and it does look like there is CC support for Jelly, but I'm assuming the default library that comes with Clarity does not include that.

     

    I did find this thread with no answer to what sounds like the same question:

     

    https://communities.ca.com/message/10045278#10045278

     

    How does one enable cc capability for gel:email?

    "jelly:com.niku.union.gel.GELTagLibrary"

     

    Thanks.



  • 2.  Re: GEL EMAIL CC

    Posted Mar 03, 2015 12:03 PM

    Just checked the Gel:Email Tag and it only supports the following:

     

    Subject

    To

    FromName

    From

    SmtpHost

    ServerUsername

    ServerPassword.

     

    I checked the commons-jelly-tags-email.jar and the email tag is in that jar which was in the 13.3 codebase.

     

    For total control you could use javax.mail.

     

    Can we sent Meeting Invite from Clarity?

     

    V/r,

    Gene



  • 3.  Re: GEL EMAIL CC

    Posted Mar 03, 2015 12:11 PM

    yet this thread ; does gel mail tag not recognize CC ? suggests its a matter of using capitalised 'CC'?

     

    --

     

    My experience years ago was that it did not work (using the standard GEL method), so I just used multiple "to" people, but I don't recall trying explictly capital 'CC'.

     

    There are other email methods that you can use though - I recall threads discussing those (mostly around formatted emails which the standard method does not support).  <-- EDIT oops that is just what Gene is also saying.



  • 4.  Re: GEL EMAIL CC

    Posted Mar 03, 2015 12:15 PM

    Yep in the commons-jelly-tags-email.jar, the setting is a capital 'CC' of type Expression.

     

    V/r,

    Gene



  • 5.  Re: GEL EMAIL CC

    Posted Mar 03, 2015 12:28 PM

    I saw CC, and tried it with caps, but the same error came back when validating the code. Tag email does not have attribute CC



  • 6.  Re: GEL EMAIL CC

    Posted Mar 03, 2015 02:38 PM

    I tested the jelly email and it worked with CC for me.

     

    Using this gel script:

    <?xml version="1.0" encoding="utf-8"?>
    <gel:script
        xmlns:core="jelly:core"
        xmlns:email="jelly:email"
        xmlns:gel="jelly:com.niku.union.gel.GELTagLibrary"
        xmlns:file="jelly:com.niku.union.gel.FileTagLibrary"
        xmlns:soap="jelly:com.niku.union.gel.SOAPTagLibrary"
        xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
        xmlns:sql="jelly:sql" xmlns:xog="http://www.niku.com/xog"
        xmlns:xsd="http://www.w3.org/2001/XMLSchema"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    
        <!-- Wrap our script in a loop so we can use break to exit cleanly -->
        <core:set var="scriptBreak" value="[1]" />
        <core:forEach var="dummy" items="${scriptBreak}">
            <core:set var="rowEmails" value="ggreiff@example.com;genegreiff@example.com" />
    
            <core:forEach items="${rowEmails}" trim="true" var="rowEmail">
                    <gel:out><core:expr value="${rowEmail}" />    </gel:out>
                <core:set value="${rowEmail};${vRoleEmail}" var="vRoleEmail" />
            </core:forEach>
    
            <gel:out>
                <core:expr value="${vRoleEmail}" />
            </gel:out>
            <core:set var="message">
            <![CDATA[
    My test email message.
                ]]>
                </core:set>
            <email:email  server="localhost" from="gene@example.com" CC="${rowEmails}" subject="TestEmail" to="gcubed@example.com" message="${message}"/>
        </core:forEach>
    
    </gel:script>
    
    

     

     

    I have a smtp listener for testing which shows the email sent with CC.

     

     

     

     

    V/r,

    Gene



  • 7.  Re: GEL EMAIL CC

    Posted Mar 04, 2015 03:52 AM

    Cool - this is jelly:email not gel:email though?



  • 8.  Re: GEL EMAIL CC

    Posted Mar 04, 2015 03:32 PM

    Correct.  Which was included in my 13.3 installation.  I haven't check to see if it works in OnDemand yet.  Maybe I will ask support if it is available in OnDemand.

     

     

    V/r,

    Gene



  • 9.  Re: GEL EMAIL CC

    Posted Jun 19, 2015 02:58 PM

    Hi Gene! this is great stuff!

         Do you know if it's possible to send emails with HTML format?  Also, do you know how to use the other EmailTag class properties?

    private File attachment = null;

    private boolean encodeXML = false;

     

    Thanks!

     

    Kind regards!

    Patricio



  • 10.  Re: GEL EMAIL CC

    Posted Sep 01, 2015 09:11 AM

    yes, it does work On-Demand.  I have confirmed.

     

    The only thing I don't know if HTML format works using Jelly email.  I have tried a few tags but it is not recognizing them. 

     

    Can HTML formatting be used with jelly email?



  • 11.  Re: GEL EMAIL CC

    Posted Dec 02, 2015 07:02 PM

    Yes, HTML email works as well.  Here is an example.

     

    <gel:parse var="htmlMessage">
                <message><![CDATA[
    <html>
    <body>
      <table width="1200" cellpadding="0" cellspacing="0">

       <tr>
        <td valign="top" align="left">
         <hr style="color:#DF0101;height=10px" />
        </td>
       </tr>

       <tr>
        <td>
         <font size="3" face="Calibri">
          Hello,</br>

    <p> Work Order: <a href="http://www.test.net/niku/app?action=projmgr.npioStaffing.other&id=${gel_objectInstanceId}"><b>${project_name}${gel_objectInstanceID}</b></a>  has been submitted into the ITS Demand Management process and resources from your team are requested to complete this work.</p> 

    <p>Please visit the work order in Clarity and replace the requested role with a resource name within 2 business days. If you have any questions please contact the ITS demand desk at: itsdesk@catholichealth.com.
    </br>
    </br>
    Thank you,</br>
    The Demand Desk
         </font>
        </td>
       </tr>

      </table>
    </body>
    </html>

    ]]></message>
            </gel:parse>



  • 12.  Re: GEL EMAIL CC

    Posted Dec 02, 2015 07:04 PM

    Sorry, not sure about the jelly email, just the gel email   That is a good question I'm interested to know.



  • 13.  Re: GEL EMAIL CC

    Posted Oct 31, 2016 12:45 PM

    Following up on this because I asked the question again in a new thread a few hours ago. 

     

    1. The library referenced by Gene appears to be the commons-jelly-tags-email.jar and is utilized by referencing the email:email tag. 

     

    You DO get cc, bcc, and attach support for this; however, you DO NOT get html support. 

     

    2. I still don't know the location of the library for gel:email. It would be interesting to see where that library/class exists and what it contains. With the email:email, you do have to provide your server info within the tag. Easy enough, but gel:email does not require. 

     

    3. gel:email does not support cc, bcc, or attachment, but it DOES support html. 

     

    So, it would be nice to find the location of the gel:email library, and see if there is a way to merge the two. 

     

    (Considering deleting my thread from before)

     

    Thanks.