���� JFIF �� � ( %"1"%)+...383,7(-.-
![]() Server : Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/7.4.20 System : Linux st2.domain.com 3.10.0-1127.10.1.el7.x86_64 #1 SMP Wed Jun 3 14:28:03 UTC 2020 x86_64 User : apache ( 48) PHP Version : 7.4.20 Disable Function : NONE Directory : /var/www/html/adimi/application/modules/dashboard/assets/js/ |
"use strict"; $("#add_supplier").on('submit',function(event) { event.preventDefault(); var formdata = new FormData($(this)[0]); $.ajax({ url: $(this).attr("action"), type: $(this).attr("method"), data: formdata, processData: false, contentType: false, success: function (data, status) { if (data == '1') { $('#message').css('display','block'); $('#message').html('Supplier added successfully'); setTimeout(function(){ window.location.href = window.location.href; }, 2000); }else if(data == '2'){ $('#error_message').css('display','block'); $('#error_message').html('Supplier already exist !'); }else if(data == '3'){ $('#error_message').css('display','block'); $('#error_message').html('Supplier name and mobile is required!'); } }, error: function (xhr, desc, err) { } }); }); $("#add_category").on('submit',function(event) { event.preventDefault(); var formdata = new FormData($(this)[0]); $.ajax({ url: $(this).attr("action"), type: $(this).attr("method"), data: formdata, processData: false, contentType: false, success: function (data, status) { if (data == '1') { $('#message1').css('display','block'); $('#message1').html('Category added successfully'); setTimeout(function(){ window.location.href = window.location.href; }, 1000); }else if (data == '2'){ $('#error_message1').css('display','block'); $('#error_message1').html('Category already exist !'); }else if(data == '3'){ $('#error_message1').css('display','block'); $('#error_message1').html('Category name required!'); } }, error: function (xhr, desc, err) { } }); });