Beispiel #1
0
 public function buildDashboard()
 {
     $quarterlySales = new ChartComponent('quarterlySales');
     $quarterlySales->setDimensions(6, 6);
     $quarterlySales->setCaption("Quarterly Sales");
     $quarterlySales->setLabels(array("Q1", "Q2", "Q3", "Q4"));
     $quarterlySales->addYAxis('quantity', "Quantity");
     $quarterlySales->addSeries('sales', "Sales", array(13122, 41312, 46132, 51135), array('numberPrefix' => "\$"));
     $quarterlySales->addSeries('quantity', "Quantity", array(121, 392, 420, 489), array('yAxis' => 'quantity'));
     $quarterlySales->addComponentKPI('beverage', array('caption' => 'Beverages', 'value' => 22900, 'numberPrefix' => ' $', 'numberHumanize' => true));
     $quarterlySales->addComponentKPI('vegetable', array('caption' => 'Vegetables', 'value' => 10401, 'numberPrefix' => ' $', 'numberHumanize' => true));
     $quarterlySales->addComponentKPI('dairy', array('caption' => 'Dairy', 'value' => 27700, 'numberPrefix' => ' $', 'numberHumanize' => true));
     $this->addComponent($quarterlySales);
     $numTickets = new KPIComponent('numTickets');
     $numTickets->setDimensions(3, 3);
     $numTickets->setCaption("Open Support Tickets");
     $numTickets->setValue(42);
     $this->addComponent($numTickets);
     $satisfactionGauge = new GaugeComponent('satisfactionGauge');
     $satisfactionGauge->setDimensions(3, 3);
     $satisfactionGauge->setCaption('Customer Satisfaction');
     $satisfactionGauge->setValue(8);
     $satisfactionGauge->setLimits(0, 10);
     $this->addComponent($satisfactionGauge);
     $ticketPriorities = new KPIGroupComponent('ticketPriorities');
     $ticketPriorities->setDimensions(6, 3);
     $ticketPriorities->setCaption('Ticket Priorities');
     $ticketPriorities->addKPI('high', array('caption' => 'High Priority', 'value' => 6));
     $ticketPriorities->addKPI('normal', array('caption' => 'Normal Priority', 'value' => 36));
     $this->addComponent($ticketPriorities);
 }
 public function buildDashboard()
 {
     $labels = [];
     $data = [];
     $data2 = [];
     for ($i = -1; ++$i < 30;) {
         $labels[$i] = $i + 1 . ' Nov 2014';
         $data[$i] = rand(1, 20000);
         $data2[$i] = rand(1, 20000);
     }
     // $c1 = new ChartComponent("c1");
     // $c1->setCaption("Sales");
     // $c1->setDimensions(4, 4);
     // $c1->setLabels($labels);
     // $c1->addSeries("sales", "Sales", $data, array ("seriesDisplayType"=> 'column', "numberPrefix"=> '$'));
     // $this->addComponent ($c1);
     $c2 = new ChartComponent("c2");
     $c2->setCaption("Sales");
     $c2->setDimensions(6, 4);
     $c2->setLabels($labels);
     $c2->setYAxis("Hello");
     $c2->addYAxis("quantity", "Quantity", array("numberPrefix" => "#", 'numberHumanize' => true));
     $c2->addSeries("sales", "Sales", $data, array("seriesDisplayType" => 'column', "numberPrefix" => '$', 'numberHumanize' => true));
     $c2->addSeries("sales2", "Sales", $data2, array("seriesDisplayType" => 'column', "numberPrefix" => '$', 'yAxis' => 'quantity', 'numberHumanize' => true));
     $c2->setLabelStep(5);
     $this->addComponent($c2);
 }
 public function buildDashboard()
 {
     $this->setDashboardTitle("Genresman Dashboard");
     $form = new FormComponent('form1');
     $form->setCaption("Form Employees");
     $form->setDimensions(12, 3);
     $form->addDateRangeField('datebtw', 'Select Date', array("defaultStartDate" => "2014-04-23", "defaultEndDate" => "2014-05-01"));
     $this->addComponent($form);
     $dailySales = new ChartComponent('c1');
     $dailySales->setDimensions(7, 6);
     $dailySales->setCaption("Daily Sales");
     $dailySalesData = $this->getDailySales('2014-04-23', '2014-05-01');
     $dailySales->setYAxis("Revenue", array("numberHumanize" => true));
     $dailySales->addYAxis("covers", "Covers", array());
     $dailySales->setLabels(ArrayUtils::pluck($dailySalesData, "tarih2"));
     $dailySales->addSeries('food', "Food", ArrayUtils::pluck($dailySalesData, "cikis"));
     $dailySalesFoodData = $this->getDailySalesFood('2014-04-23', '2014-05-01');
     $dailySales->addSeries('covers', "Covers", ArrayUtils::pluck($dailySalesFoodData, "cikis"), array("yAxis" => "covers", "seriesDisplayType" => "line"));
     $this->addComponent($dailySales);
     $monthlySales = new ChartComponent('c2');
     $monthlySales->setDimensions(5, 6);
     $monthlySales->setCaption("Monthly Sales");
     $monthlySalesData = $this->getMonthlySales();
     $monthlySales->setYAxis("Revenue", array("numberHumanize" => true));
     $monthlySales->addYAxis("covers", "Covers", array());
     $monthlySales->setLabels(ArrayUtils::pluck($monthlySalesData, "ay"));
     $monthlySales->addSeries('food', "Food", ArrayUtils::pluck($monthlySalesData, "cikis"));
     $monthlySalesFood = $this->getMonthlySalesFood();
     $monthlySales->addSeries('covers', "Covers", ArrayUtils::pluck($monthlySalesFood, "cikis"), array("yAxis" => "food", "seriesDisplayType" => "line"));
     $this->addComponent($monthlySales);
     $item = new ChartComponent('c3');
     $item->setDimensions(7, 6);
     $item->setCaption("Item Categories");
     $item->setYAxis("", array("numberHumanize" => true));
     $itemCategories = $this->getItemCategories('2014-04-23', '2014-05-01');
     $item->setLabels(ArrayUtils::pluck($itemCategories, "grupadi"));
     $item->addSeries('items', "Items", ArrayUtils::pluck($itemCategories, "cikis"));
     $this->addComponent($item);
     $chart = new ChartComponent("pie_chart");
     $chart->setCaption("Clerk Sales");
     $chart->setDimensions(5, 6);
     $clerkData = $this->getClerkSales('2014-04-23', '2014-05-01');
     $chart->setLabels(ArrayUtils::pluck($clerkData, "garson"));
     $chart->setPieValues(ArrayUtils::pluck($clerkData, "cikis"), array("numberHumanize" => true));
     $this->addComponent($chart);
     $hour = new ChartComponent('c4');
     $hour->setDimensions(12, 6);
     $hour->setCaption("Hourly Sales");
     $hour->setYAxis("", array("numberHumanize" => true));
     $hourlySales = $this->getHourlySales('2014-04-23', '2014-05-01');
     $hour->setLabels(ArrayUtils::pluck($hourlySales, "SAAT"));
     $hour->addSeries('items', "Items", ArrayUtils::pluck($hourlySales, "CIKIS"));
     $this->addComponent($hour);
     $form->onApplyClick(array($dailySales, $item, $chart, $hour), "handleForm", $this);
 }
Beispiel #4
0
 public function buildDashboard()
 {
     $quarterlySales = new ChartComponent('quarterlySales');
     $quarterlySales->setDimensions(6, 6);
     $quarterlySales->setCaption("Quarterly Sales");
     $quarterlySales->setLabels(array("Q1", "Q2", "Q3", "Q4"));
     $quarterlySales->addYAxis('quantity', "Quantity");
     $quarterlySales->addSeries('sales', "Sales", array(13122, 41312, 46132, 51135), array('numberPrefix' => "\$"));
     $quarterlySales->addSeries('quantity', "Quantity", array(121, 392, 420, 489), array('yAxis' => 'quantity'));
     $this->addComponent($quarterlySales);
 }
 public function buildDashboard()
 {
     $chart = new ChartComponent("my_first_chart");
     $chart->setCaption("Car Sales figures");
     $chart->setYAxis("Sales", array("numberPrefix" => "\$", "numberHumanize" => true));
     $chart->addYAxis("quantity", "Quantity", array());
     $chart->setDimensions(4, 4);
     $chart->setLabels(["Jan", "Feb", "Mar"]);
     $chart->addSeries("sales", "Sales", [1355340, 2214134, 1854313], array("seriesDisplayType" => "column", "numberPrefix" => "\$"));
     $chart->addSeries("car_quantity", "Quantity", [14, 19, 17], array("yAxis" => "quantity"));
     $this->addComponent($chart);
 }
Beispiel #6
0
 public function buildDashboard()
 {
     $chart = new ChartComponent();
     $chart->setDimensions(8, 6);
     $chart->setYAxis("Sales", array("numberPrefix" => "\$ ", "numberHumanize" => true));
     $chart->addYAxis('profit', "Profit %", array("numberSuffix" => "%"));
     $chart->setCaption("Showing monthly sales and profit of a retail company");
     $chart->setLabels(array("March", "April", "May", "June", "July"));
     $chart->addSeries("product_A", "Product A", array(25601.34, 20148.82, 17372.76, 35407.15, 38105.68), array("numberPrefix" => '$', "seriesDisplayType" => 'column'));
     $chart->addSeries("product_B", "Product B", array(57401.85, 41941.19, 45263.37, 117320.16, 114845.27), array("numberPrefix" => '$', "seriesDisplayType" => 'column'));
     $chart->addSeries("profit", "Profit %", array(20, 42, 10, 23, 16), array("numberPrefix" => '$', "seriesDisplayType" => 'line', "yAxis" => "profit"));
     $this->addComponent($chart);
 }
Beispiel #7
0
 public function buildDashboard()
 {
     $chart = new ChartComponent();
     $chart->setCaption("Visits from search engines");
     $chart->setDimensions(8, 6);
     $chart->setYAxis("Revenue", array("numberPrefix" => "\$ ", "numberHumanize" => true));
     $chart->addYAxis('quantity', "Quantity", array());
     $chart->setCaption("Sales");
     $chart->setLabels(["March", "April", "May", "June", "July"]);
     $chart->addSeries("product_A", "Product A", [25601.34, 20148.82, 17372.76, 35407.15, 38105.68], array("numberPrefix" => '$', "seriesDisplayType" => 'column'));
     $chart->addSeries("product_B", "Product B", [57401.85, 41941.19, 45263.37, 117320.16, 114845.27], array("numberPrefix" => '$', "seriesDisplayType" => 'column'));
     $chart->addSeries("total_quantity", "Total Quantity", [45000, 44835, 42835, 77557, 92633], array("numberPrefix" => '$', "seriesDisplayType" => 'line', "yAxis" => "quantity"));
     $this->addComponent($chart);
 }
Beispiel #8
0
 public function buildDashboard()
 {
     $quarterlySales = new ChartComponent('quarterlySales');
     $quarterlySales->setDimensions(6, 6);
     $quarterlySales->setCaption("Quarterly Sales");
     $quarterlySales->setLabels(array("Q1", "Q2", "Q3", "Q4"));
     $quarterlySales->addYAxis('quantity', "Quantity");
     $quarterlySales->addSeries('sales', "Sales", array(13122, 41312, 46132, 51135), array('numberPrefix' => "\$"));
     $quarterlySales->addSeries('quantity', "Quantity", array(121, 392, 420, 489), array('yAxis' => 'quantity'));
     $quarterlySales->addComponentKPI('beverage', array('caption' => 'Beverages', 'value' => 22900, 'numberPrefix' => ' $', 'numberHumanize' => true));
     $quarterlySales->addComponentKPI('vegetable', array('caption' => 'Vegetables', 'value' => 10401, 'numberPrefix' => ' $', 'numberHumanize' => true));
     $quarterlySales->addComponentKPI('dairy', array('caption' => 'Dairy', 'value' => 27700, 'numberPrefix' => ' $', 'numberHumanize' => true));
     $quarterlySales->addDrillStep('drillIntoMonths', $this);
     $this->addComponent($quarterlySales);
     $numTickets = new KPIComponent('numTickets');
     $numTickets->setDimensions(3, 3);
     $numTickets->setCaption("Open Support Tickets");
     $numTickets->setValue(42);
     $this->addComponent($numTickets);
     $satisfactionGauge = new GaugeComponent('satisfactionGauge');
     $satisfactionGauge->setDimensions(3, 3);
     $satisfactionGauge->setCaption('Customer Satisfaction');
     $satisfactionGauge->setValue(8);
     $satisfactionGauge->setLimits(0, 10);
     $this->addComponent($satisfactionGauge);
     $ticketPriorities = new KPIGroupComponent('ticketPriorities');
     $ticketPriorities->setDimensions(6, 3);
     $ticketPriorities->setCaption('Ticket Priorities');
     $ticketPriorities->addKPI('high', array('caption' => 'High Priority', 'value' => 6));
     $ticketPriorities->addKPI('normal', array('caption' => 'Normal Priority', 'value' => 36));
     $this->addComponent($ticketPriorities);
     $productsTable = new TableComponent('productsTable');
     $productsTable->setDimensions(6, 6);
     $productsTable->setCaption('Products');
     $productsTable->addColumn('name', 'Name');
     $productsTable->addColumn('category', 'Category');
     $productsTable->addColumn('price', 'Price', array('dataType' => "number", 'numberPrefix' => "\$", 'textAlign' => "right", 'numberForceDecimals' => true));
     $productsTable->addMultipleRows($this->tableData);
     $this->addComponent($productsTable);
     $productFilterForm = new FormComponent('productFilterForm');
     $productFilterForm->setDimensions(6, 6);
     $productFilterForm->setCaption('Filter Products');
     $productFilterForm->addMultiSelectField('category', 'Select Category', array('Vegetables', 'Dairy', 'Beverages'));
     $productFilterForm->addTextField('name', 'Product Name Contains');
     $productFilterForm->addNumericRangeField('price', 'Price', array(5, 20));
     $this->addComponent($productFilterForm);
     $productFilterForm->onApplyClick(array($productsTable), 'handleApplyClick', $this);
 }
 public function buildDashboard()
 {
     $chart = new ChartComponent();
     $chart->setCaption("Company Revenue and Profits");
     $chart->setDimensions(8, 6);
     $chart->setLabels(array("Aug", "Sept", "Oct", "Nov", "Dec"));
     $chart->addSeries("revenue", "Product A", array(20000, 17000, 22000, 19000, 23000), array("numberPrefix" => "\$"));
     $chart->addYAxis("profit", "Profit %", array("numberSuffix" => "%"));
     $chart->addSeries("profit", "Profit %", array(25, 5.88, 36.36, 10.52, 30.43), array("seriesDisplayType" => "line", "numberSuffix" => "%", "yAxis" => "profit"));
     $chart->setYAxis('Revenue', array("numberPrefix" => '$', "numberHumanize" => true));
     $this->addComponent($chart);
     $chart1 = new ChartComponent();
     $chart1->setCaption("Company Sales");
     $chart1->setDimensions(6, 6);
     $chart1->setLabels(array("Jan", "Feb", "Mar", "Apr", "May", "June"));
     $chart1->addSeries("Revenue", "Revenue", array(5854, 4171, 1375, 1875, 2246, 2696));
     $chart1->addSeries("Profit", "Profit", array(3242, 3171, 700, 1287, 1856, 1126), array("seriesDisplayType" => "area"));
     $chart1->addSeries("Predicted_Profit", "Predicted Profit", array(4342, 2371, 740, 3487, 2156, 1326), array("seriesDisplayType" => "line"));
     $chart1->setYAxis('Sales', array("numberPrefix" => '$', "numberHumanize" => true));
     $this->addComponent($chart1);
 }
Beispiel #10
0
 public function buildDashboard()
 {
     $this->setDashboardTitle("Sales Dashboard");
     $this->setActionPath("/static/transfer/build/tour/motherboard_action.php");
     // $yearwise = new ChartComponent ('yearly_sales');
     // $yearwise->setCaption ("Yearly Sales");
     // $yearwise->setDimensions (6, 6);
     // $yearData = $this->get_year();
     // $yearwise->setLabels(ArrayUtils::pluck($yearData, 'payment_year'));
     // $yearwise->setYAxis("Sales", array(
     //   "numberHumanize" => true,
     //   'numberPrefix' => "$"
     // ));
     // $totalSalesArr = ArrayUtils::pluck($yearData, "total_amount");
     // $yearwise->addSeries ("sales", "Sales", $totalSalesArr, array(
     //   'numberPrefix' => "$"
     // ));
     // $yearwise->addDrillStep("get_monthwise", $this);
     // $yearwise->addDrillStep("get_daywise", $this);
     // $totalSales = 0;
     // foreach ($totalSalesArr as $key => $value) {
     //   $totalSales += $value;
     // }
     // $yearwise->addComponentKPI("sales", array(
     //   "caption" => "Total Sales",
     //   "value" => $totalSales,
     //   "numberPrefix" => "$",
     //   "numberHumanize" => true
     // ));
     // $yearwise->addComponentKPI("second", array(
     //   "caption" => "Revenue",
     //   "value" => $totalSales,
     //   "numberPrefix" => "$",
     //   "numberHumanize" => true
     // ));
     // $this->addComponent ($yearwise);
     $category = new ChartComponent('category');
     $category->setCaption("Category wise Sales");
     $category->setDimensions(6, 6);
     $categoryData = $this->get_category();
     $quantityData = $this->get_units();
     $category->setLabels(ArrayUtils::pluck($categoryData, 'CategoryName'));
     $category->setYAxis("Sales", array("numberHumanize" => true, 'numberPrefix' => "\$"));
     $totalSalesArr = ArrayUtils::pluck($categoryData, "total_amount");
     $category->addSeries("sales", "Sales", $totalSalesArr, array('numberPrefix' => "\$"));
     $category->addYAxis('unitsAx', "Units in Inventory", array());
     $totalUnitsArr = ArrayUtils::pluck($quantityData, "total_quantity");
     $category->addSeries("units", "Units in Inventory", $totalUnitsArr, array("seriesDisplayType" => "line", "yAxis" => 'unitsAx'));
     $category->addDrillStep("get_prod", $this);
     $category->addComponentKPI("cost", array("caption" => "Total Sales", "value" => $this->get_cost_inventory(), "numberPrefix" => "\$"));
     $category->addComponentKPI("units", array("caption" => "Total Units in Inventory", "value" => $this->get_unit_inventory()));
     $this->addComponent($category);
     $chart = new ChartComponent("Customer_satisfaction");
     $chart->setCaption("Customer Satisfaction");
     $chart->setDimensions(6, 6);
     $chart->setLabels(["Very Unsatisfied", "UnSatisfied", "Neutral", "Satisfied", "Very Satisfied"]);
     $chart->setPieValues([4, 10, 25, 25, 36], array("numberSuffix" => "%"));
     $this->addComponent($chart);
     $table = new TableComponent('table');
     $table->setCaption("Average Shipping Time");
     $table->setDimensions(6, 6);
     $ship = $this->get_shipping();
     $table->addColumn('country', 'Country');
     $table->addColumn('avg_time', 'Average Time', array("textAlign" => "right"));
     $table->addMultipleRows($this->PolulateData($ship));
     $table->setRowsPerPage(12);
     $this->addComponent($table);
     $goods = new ChartComponent('goods_sold');
     $goods->setCaption("Cost of Goods Sold");
     $goods->setDimensions(6, 6);
     $yearArr = $this->get_yearName();
     $goods->setLabels(ArrayUtils::pluck($yearArr, 'payment_year'));
     $goods->setYAxis("Sales", array("numberHumanize" => true, 'numberPrefix' => "\$"));
     $goodsSoldData = $this->get_goodsSold();
     foreach ($goodsSoldData as $key => $value) {
         $goods->addSeries($key, $key, ArrayUtils::pluck($value, "total_amount"), array('numberPrefix' => "\$", 'seriesStacked' => true));
     }
     $this->addComponent($goods);
 }
 public function buildDashboard()
 {
     $c1 = new ChartComponent('c1');
     $c1->setCaption("Column Chart");
     $c1->setDimensions(4, 4);
     $c1->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c1->addSeries("seriesA", "Series A", [21, 33, 25, 41, 59], array('seriesDisplayType' => 'column', 'numberPrefix' => '$'));
     $c1->setYAxis("", array('minValue' => 10, 'maxValue' => 60, 'numTicks' => 6));
     $this->addComponent($c1);
     $c2 = new ChartComponent('c2');
     $c2->setCaption("Column Chart Dual Axis");
     $c2->setDimensions(4, 4);
     $c2->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c2->addSeries("seriesA", "Series A", [21, 33, 25, 41, 59], array('seriesDisplayType' => 'column', 'numberPrefix' => '$'));
     $c2->addSeries("seriesB", "Series B", array_reverse([21, 33, 25, 41, 59]), array('seriesDisplayType' => 'column', 'numberPrefix' => '$', 'yAxis' => 'second'));
     $c2->setYAxis("", array('minValue' => 10, 'maxValue' => 60, 'numTicks' => 6));
     $c2->addYAxis("second", "", array('minValue' => 10, 'maxValue' => 60, 'numTicks' => 6));
     $this->addComponent($c2);
     $c3 = new ChartComponent('c3');
     $c3->setCaption("Column Chart Stacked");
     $c3->setDimensions(4, 4);
     $c3->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c3->addSeries("seriesA", "Series A", [21, 33, 25, 41, 59], array('seriesDisplayType' => 'column', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c3->addSeries("seriesB", "Series B", array_reverse([21, 33, 25, 41, 59]), array('seriesDisplayType' => 'column', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c3->setYAxis("", array('minValue' => 21, 'maxValue' => 81, 'numTicks' => 6));
     $this->addComponent($c3);
     $c4 = new ChartComponent('c4');
     $c4->setCaption("Column Chart Negative");
     $c4->setDimensions(4, 4);
     $c4->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c4->addSeries("seriesA", "Series A", [21, 33, -25, 41, 59], array('seriesDisplayType' => 'column', 'numberPrefix' => '$'));
     $c4->setYAxis("", array('minValue' => -30, 'maxValue' => 60, 'numTicks' => 10));
     $this->addComponent($c4);
     $c5 = new ChartComponent('c5');
     $c5->setCaption("Column Chart Dual Axis Negative");
     $c5->setDimensions(4, 4);
     $c5->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c5->addSeries("seriesA", "Series A", [21, 33, -25, 41, 59], array('seriesDisplayType' => 'column', 'numberPrefix' => '$'));
     $c5->addSeries("seriesB", "Series B", array_reverse([21, 33, -25, 41, 59]), array('seriesDisplayType' => 'column', 'numberPrefix' => '$', 'yAxis' => 'second'));
     $c5->setYAxis("", array('minValue' => -30, 'maxValue' => 60, 'numTicks' => 10));
     $c5->addYAxis("second", "", array('minValue' => -30, 'maxValue' => 60, 'numTicks' => 10));
     $this->addComponent($c5);
     $c6 = new ChartComponent('c6');
     $c6->setCaption("Column Chart Stacked Negative");
     $c6->setDimensions(4, 4);
     $c6->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c6->addSeries("seriesA", "Series A", [21, 33, -25, 41, 59], array('seriesDisplayType' => 'column', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c6->addSeries("seriesB", "Series B", array_reverse([21, 33, -25, 41, 59]), array('seriesDisplayType' => 'column', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c6->setYAxis("", array('minValue' => -50, 'maxValue' => 90, 'numTicks' => 15));
     $this->addComponent($c6);
     $c7 = new ChartComponent('c7');
     $c7->setCaption("Bar Chart");
     $c7->setDimensions(4, 4);
     $c7->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c7->addSeries("seriesA", "Series A", [21, 33, 25, 41, 59], array('seriesDisplayType' => 'bar', 'numberPrefix' => '$'));
     $c7->setXAxis("", array('minValue' => 10, 'maxValue' => 60, 'numTicks' => 6));
     $this->addComponent($c7);
     $c8 = new ChartComponent('c8');
     $c8->setCaption("Bar Chart Negative");
     $c8->setDimensions(4, 4);
     $c8->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c8->addSeries("seriesA", "Series A", [21, 33, -25, 41, 59], array('seriesDisplayType' => 'bar', 'numberPrefix' => '$'));
     $c8->setXAxis("", array('minValue' => -30, 'maxValue' => 60, 'numTicks' => 10));
     $this->addComponent($c8);
     $c9 = new ChartComponent('c9');
     $c9->setCaption("Bar Chart Stacked");
     $c9->setDimensions(4, 4);
     $c9->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c9->addSeries("seriesA", "Series A", [21, 33, 25, 41, 59], array('seriesDisplayType' => 'bar', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c9->addSeries("seriesB", "Series B", array_reverse([21, 33, 25, 41, 59]), array('seriesDisplayType' => 'bar', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c9->setXAxis("", array('minValue' => 21, 'maxValue' => 81, 'numTicks' => 6));
     $this->addComponent($c9);
     $c10 = new ChartComponent('c10');
     $c10->setCaption("Bar Chart Stacked Negative");
     $c10->setDimensions(4, 4);
     $c10->setLabels(['January', 'February', 'March', 'April', 'May']);
     $c10->addSeries("seriesA", "Series A", [21, 33, -25, 41, 59], array('seriesDisplayType' => 'bar', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c10->addSeries("seriesB", "Series B", array_reverse([21, 33, 25, 41, 59]), array('seriesDisplayType' => 'bar', 'numberPrefix' => '$', 'seriesStacked' => true));
     $c10->setXAxis("", array('minValue' => -50, 'maxValue' => 90, 'numTicks' => 15));
     $this->addComponent($c10);
 }