Hi,
I have added a dynamic field as sub_type dropdown in the new ticket email form, and I am filling this by jquery on chang of type but there is a problem when any field is selected then it (sub_type dropdown) get blank. Hope the question is clear. If not please let me know.
I am digging since yesterday but unable to find the solution. If you know please let me know as it will be very helpfull for me to sortout the problem.
thanks
Ticket form customization
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: Ticket form customization
Please show your JavaScript code...
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Re: Ticket form customization
Thanks for the reply.
following is the code which i am using to get the sub types from the database using jquery, ajax and php.
$('#TypeID').bind('change', function (Event) {
var typeid= $("#TypeID").val();
if(typeid=='' || typeid==null)
typeid=0;
$.ajax({
url: "/ajax/get_subtypes.php",
type: "POST",
data: "ticket_type_id="+typeid,
dataType: 'json',
cache: false,
success: function (data) {
$("#DynamicField_subtype").html(data['sub_types']);
}
});
});
But when I select any value from type drop down, It show the subtypes for a moment and then get blank.
following is the code which i am using to get the sub types from the database using jquery, ajax and php.
$('#TypeID').bind('change', function (Event) {
var typeid= $("#TypeID").val();
if(typeid=='' || typeid==null)
typeid=0;
$.ajax({
url: "/ajax/get_subtypes.php",
type: "POST",
data: "ticket_type_id="+typeid,
dataType: 'json',
cache: false,
success: function (data) {
$("#DynamicField_subtype").html(data['sub_types']);
}
});
});
But when I select any value from type drop down, It show the subtypes for a moment and then get blank.
You do not have the required permissions to view the files attached to this post.