$(function() {
	//Agregado para bloquear el textarea de "concepto"  en el edit del invoice
	//$("textarea[class='expanding']").attr("disabled", "true");
	//
	/*
	$('#cancelDialog').dialog({
	autoOpen: false,
	bgiframe: true,
	resizable: true,
	draggable: true,
	height:280,
	width:600,
	modal: true,
	overlay: {
	backgroundColor: '#000000',
	opacity: 0.5
	},
	open: function(msg){
	$.ajax({
	type: "POST",
	url: '/modules/admin/invoices/actions.php',
	data: "id="+ id + "&action=cancelInvoice" + idfactura_refacturado + observaciones + idconceptocancelacion,
	success: function(msg){
	$("#messages").html(msg);
	$("#messages").show();
	}
	});
	}
	});


	
	$.ajax({
		type: "POST",
		url: '/interplanet/frontend/modules/clientareainvoices/viewInvoice.php',
		data: "id="+ id + "&action=cancelInvoice",
		success: function(msg){
			$("#messages").html('<a href="http://facturas.desarrolloplanet.com.mx/pdf/pdf.php?folio=' + msg + '">PDF</a>');
			$("#messages").show();
		}
	});*/
});
function test(id){
	//alert('id: '+id);
	//$('#cancelDialog').dialog("open");
	$.ajax({
		type: "POST",
		url: '/interplanet/frontend/modules/clientareainvoices/viewInvoice.php',
		data: "id="+ id + "&action=cancelInvoice",
		success: function(msg){
			$("#messages").html('<a href="http://facturas.suempresa.com/pdf/pdf.php?folio=' + msg + '">PDF</a>');
			$("#messages").show();
		}
	});
}
