found the answer thanks @willvin $('#ctrl-eftpos, #ctrl-app_payment, #ctrl-discount, #ctrl-cash').on('input', function(){
var $eftpos = $(this).closest('form').find('#ctrl-eftpos').val(); var $app_payment = $(this).closest('form').find('#ctrl-app_payment').val(); var $discount = $(this).closest('form').find('#ctrl-discount').val(); var $cash = $(this).closest('form').find('#ctrl-cash').val();
var $gross_sales_dom = $(this).closest('form').find('#ctrl-gross_sales');
var $eftpos = $(this).closest('form').find('#ctrl-eftpos').val(); var $app_payment = $(this).closest('form').find('#ctrl-app_payment').val(); var $discount = $(this).closest('form').find('#ctrl-discount').val(); var $cash = $(this).closest('form').find('#ctrl-cash').val();
var $gross_sales_dom = $(this).closest('form').find('#ctrl-gross_sales');
hi there i have a problem here. i try to use client event in my phprad , it should calculate a decimal data type, my database data type are already decimal 7,2 change the value step to 0.01
but when ever i put the decimal number from 1 field to another , the calculation doesnt work.
here is my script $('#ctrl-eftpos, #ctrl-app_payment, #ctrl-discount, #ctrl-cash').on('input', function(){
var $eftpos = $(this).closest('form').find('#ctrl-eftpos').val(); var $app_payment = $(this).closest('form').find('#ctrl-app_payment').val(); var $discount = $(this).closest('form').find('#ctrl-discount').val(); var $cash = $(this).closest('form').find('#ctrl-cash').val();
var $gross_sales_dom = $(this).closest('form').find('#ctrl-gross_sales');