File: /var/www/vhost/disk-apps/demo-telemedicina.teky.com.co/public/js/clinic_document/clinic_info.js
$('#btn_enf_actual_lab').click(function () {
view = window.localStorage.getItem('view');
view= JSON.parse(view);
if(view){
$('#btn-modal-text').prop('disabled', true);
$('#text-area-modal').prop('disabled', true);
}else{
$('#btn-modal-text').prop('disabled', false);
$('#text-area-modal').prop('disabled', false);
}
valor = $(this).attr('data-id');
$('#btn-modal-text').attr('data-id', valor);
valor2 = $('#enf_actual_lab').val();
$('#text-area-modal').val(valor2);
});
$('#btn_examen_fisico').click(function () {
view = window.localStorage.getItem('view');
view= JSON.parse(view);
if(view){
$('#btn-modal-text').prop('disabled', true);
$('#text-area-modal').prop('disabled', true);
}else{
$('#btn-modal-text').prop('disabled', false);
$('#text-area-modal').prop('disabled', false);
}
valor = $(this).attr('data-id');
$('#btn-modal-text').attr('data-id', valor);
valor2 = $('#examen_fisico').val();
$('#text-area-modal').val(valor2);
});
$('#btn_motivo_consulta').click(function () {
view = window.localStorage.getItem('view');
view= JSON.parse(view);
if(view){
$('#btn-modal-text').prop('disabled', true);
$('#text-area-modal').prop('disabled', true);
}else{
$('#btn-modal-text').prop('disabled', false);
$('#text-area-modal').prop('disabled', false);
}
valor = $(this).attr('data-id');
$('#btn-modal-text').attr('data-id', valor);
valor2 = $('#motivo_consulta').val();
$('#text-area-modal').val(valor2);
});
function maxLengthCheck(object)
{
if (object.value.length > object.maxLength)
object.value = object.value.slice(0, object.maxLength)
}