// Cria nova contrato $("#btn_save_pagamentos").click(function (e){ $.ajaxSetup({ headers: { 'X-CSRF-TOKEN': $('meta[name="_token"]').attr('content') } }) e.preventDefault(); var formData = { credor: $('#credor_modal_man').val(), valor : $('#valor_modal_man').val(), qtd_parcelas: $('#qtd_parcelas_modal_man').val(), dividir: $("input[name='dividir_modal_man']:checked").val(), dt_vcto: $('#dt_vcto_modal_man').val(), } var state = $('#btn_save_pagamentos').val(); var type = "POST"; //Valida se pode cadastrar a configuração //if($('#liberacadastro_contrato_modal').val() == "true"){ $.ajax({ type: type, url: "../../get-pagar/pagamento", data: formData, dataType: 'json', success: function (data) { //console.log(data); // alert('Salvo com sucesso'); //$("#alertModalsuccess_contrato").removeClass('d-none'); // $('#frm_create_contrato').trigger("reset"); // $('#CadConfParModal').modal('hide'); // location.reload(); $.each(JSON.parse(data),function(key,value){ $('#validation_return').append('
'+value+''+value+''+value+''+value+''); }, success: function (data) { $('#modalBaixaLote').modal('hide'); $("#bt_filtrar").click(); }, error: function (data) { $("#gif_load").html('
Erro ao executar as baixas das comissões.