1 package dinamica; 2 3 16 public class GenericChart extends GenericTransaction 17 { 18 19 22 public int service(Recordset inputParams) throws Throwable 23 { 24 25 super.service(inputParams); 27 28 Recordset rs = getChartInfoRecordset(); 30 31 String session = getConfig().getConfigValue("//chart/session"); 33 String imageid = getConfig().getConfigValue("//chart/image-id"); 34 String plugin = getConfig().getConfigValue("//chart/plugin"); 35 Integer width = new Integer (getConfig().getConfigValue("//chart/width")); 36 Integer height = new Integer (getConfig().getConfigValue("//chart/height")); 37 String title = getConfig().getConfigValue("//chart/title"); 38 String titlex = getConfig().getConfigValue("//chart/title-x"); 39 String titley = getConfig().getConfigValue("//chart/title-y"); 40 String series = getConfig().getConfigValue("//chart/title-series"); 41 String recordset = getConfig().getConfigValue("//chart/recordset"); 42 String fieldx = getConfig().getConfigValue("//chart/field-x"); 43 String fieldy = getConfig().getConfigValue("//chart/field-y"); 44 String color = getConfig().getConfigValue("//chart/color", null); 45 46 rs.addNew(); 48 rs.setValue("title", title); 49 rs.setValue("title-x", titlex); rs.setValue("title-y", titley); rs.setValue("column-x", fieldx); 52 rs.setValue("column-y", fieldy); rs.setValue("title-series", series); rs.setValue("width", width); rs.setValue("height", height); rs.setValue("data", recordset); 58 59 rs.setValue("chart-plugin", plugin); 60 61 rs.setValue("session", session); 64 rs.setValue("image-id", imageid); 65 66 rs.setValue("color", color); 69 70 71 publish("chartinfo", rs); 72 73 return 0; 75 76 } 77 78 } 79 | Popular Tags |