Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

Variables on mail template on 1.8.0.1

Hi all,

we have osTicket V. 1.8.0.1 

we have new field on contact information named (mobile). 

we want to add this filed to Ticket Assignment Alert

what is the correct variable should be used

we try %{ticket.mobile} but it doesn't work
what is the correct objective ?

any idea?

Comments

  • edited December 2013
    You would go to: admin panel -> manage -> forms
    select the form that you added the fields to. [mine is under Ticket Details]
    Locate the row under Form Fields and see what you entered for a variable on the right.
    For example I have one that is:

    Label: Agency
    Type: Agencies [a custom list I made]
    required: checked
    Variable: agency

    You would then go to emails -> templates -> your in use template -> new ticket alert
    where I added

    Agency: %{ticket.agency}

    now new ticket announcements include the details from my custom list.

    note: updated to fix spelling and add a little more information.
  • thank you ntozier,

    i try to follow your instruction and its same result no information appear in email. 
    i attached some screen to explain what we looking for.

    imageimageimageimage
    Contact.JPG
    932 x 272 - 46K
    Email.JPG
    411 x 359 - 24K
    Temp.JPG
    1010 x 584 - 63K
    Ticket Details.JPG
    930 x 486 - 73K
  • strangely your forms section looks backwards from mine.

    I have
    sort,label,type,internal,required,variable,delete

    and you have
    delete,variable,required,internal,type,label,sort

    While I don't think that this is necessarily  problem it makes me wonder if you are using a modified version of osTicket and not one that you got from this site.  I'm running 1.8.0.1 and it works for me.
  • edited December 2013
    +1 I have this exact problem and I downloaded my software straight from this website yesterday, I've tried many compbonations but im sure that i have followed the instructions properly %{ticket.mycustomvariable} is not working.

    I should note however that the form i am using is a custom form with a custom list, i did not add the custom list to the ticket, i added the additional custom form with varibales i want on my email to the help topic "Custom Form:" area.

    UPDATE UPDATE!

    It works fine if i add the custom field to the built in form Tickets.  However if under a help top if if i add an additional custom form in this section (pasted below)

    New ticket options
    Custom Form: Extra information for tickets associated with this help topic   

    I cannot access my custom variables.  Should the prefix be something else besides ticket.?

    ticket . works on the built in form for tickets but it doesnt work for additional custom form tracking

    I dont want to add some of these data points to every single tickets it defeats the purpose of being able to add custom forms based on topics.

    What can I do?

    Best Regards,

    David
  • thank you David, we become 2 now :)

    Ntozier , i just change the layout form LTR to RTL, most of our user used Arabic.


  • Hello, has there been any change in this, or any new discoveries? If not, chalk me up as another user with the same issue. Just updated to 1.8 yesterday and I am impressed by the ease of adding new fields (I used to do this manually, man what a change), but can't get the data to go out in emails. 
  • Just some FYI on the issue. The data associated with the "Ticket Details" form is available via the %{ticket.<variable>} token. Data associated with the user via the "Contact Information" form is available via the %{ticket.user.<variable>} token. Data associated with other forms, such as the extra form added for the help topic, is not currently available.

    This is at least the design goal. So my point is to be careful to distinguish between fields for the users and fields for the tickets.

    I'd definitely welcome some feedback if it doesn't work this way, because it should.

    Cheers,
  • When I add fields to the Contact Information form, I cannot get the data to go out in emails no matter how I type in the variable. I have tried both %{ticket.<variable>} and %{ticket.user.<variable>} and both just end up as blank spaces in emails. I will gladly document it better, just let me know what you need for me to demonstrate it.


    As a confirmation to the information stated by others, I can get a custom field's information to go into and email if I add the custom field to the Ticket Details form, but the information I am collecting on the tickets should really be in the Contact Information section.
  • I'm having the same issue as cbauer using version 1.8.0.2. I have a custom list attached to the "Contact Information" form, but I can't get the variable to display any information when adding it to the email template using %{ticket.user.client_name1}. My company services a number of internal clients, so it's a field that we need to display on the new ticket email notification to our staff. Any help is appreciated.
  • Please provide a screen shot of your built in form, and the email template.
  • Here are screenshots from 1.8.1.
    CropperCapture[1].jpg
    961 x 651 - 186K
    CropperCapture[2].jpg
    941 x 429 - 163K
    CropperCapture[3].jpg
    760 x 417 - 57K
Sign In or Register to comment.