/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.rjconsultores.ventaboletos.web.utilerias.render;

import org.zkoss.zul.Checkbox;
import org.zkoss.zul.Listcell;
import org.zkoss.zul.Listitem;
import org.zkoss.zul.ListitemRenderer;

import com.rjconsultores.ventaboletos.entidad.Custom;
import com.rjconsultores.ventaboletos.enums.SistemaEnum;

/**
 *
 * @author Lucas
 */
public class RenderCustom implements ListitemRenderer {

	public void render(Listitem lstm, Object o) throws Exception {
		Custom custom = (Custom) o;
		
		Listcell lc = new Listcell(custom.getCustomId().toString());
		lc.setParent(lstm);

		lc = new Listcell(SistemaEnum.getSistema(custom.getSistema()).toString());
		lc.setParent(lstm);
		
		lc = new Listcell(custom.getChave());
		lc.setParent(lstm);
		
		lc = new Listcell(custom.getValor());
		lc.setParent(lstm);

		lstm.setAttribute("data", custom);
	}
}
