// Unifi User
function AddNameUsrUni() {
    var btnAddUsrUni = $('#BtnAddNameUsrUni').val();
    var UniName = $('#TxtAddNameUsrUni').val();
    //$('#adduniusr').modal('dispose');
    $.ajax({
        url: 'ops/ops.php',
        type: 'POST',
        data: {
            btnAddUsrUniP: btnAddUsrUni,
            UniNameP: UniName,
        },
        success: function (data, status) {
            // function to display data;
            location.replace(location.href);
        }
    });
}

function AddPayUsrUni() {
    var JBtnAddPayUsrUni = $('#BtnAddPayUsrUni').val();
    var JTxtuniPayDate = $('#TxtuniPayDate').val();
    var JTxtSlctUsrUni = $('#TxtSlctUsrUni').val();
    var JTxtdesc = $('#Txtdesc').val();
    var JTxtbyran = $('#Txtbyran').val();

    $.ajax({
        url: 'ops/ops.php',
        type: 'POST',
        data: {
            BtnAddPayUsrUniP: JBtnAddPayUsrUni,
            TxtuniPayDateP: JTxtuniPayDate,
            TxtSlctUsrUniP: JTxtSlctUsrUni,
            TxtdescP: JTxtdesc,
            TxtbyranP: JTxtbyran, 
        },
        success: function (data, status) {
           // alert('Data Save');
            swal("SAVED!");
            //console.log(JTxtSlctUsrUni);
            // function to display data;
        
        }
    });
}

$(document).on("click",".BtnLstPayUni",function dispLstPayUni(){
    var dispLstPayUni="true";
    //alert("Masuk Function");
     $.ajax({
          url:'ops/ops.php',
          type:'POST',
          data:{
            dispLstPayUniP:dispLstPayUni
               },
          success:function(data,status){
             //console.log(data);
               $('#dispLstUniPayTbl').html(data);
           }      
          });
 });

 // Roomstay
