CORE-POS/IS4C

View on GitHub
fannie/modules/plugins2.0/FreshDeals/FreshDealsData.php

Summary

Maintainability
B
5 hrs
Test Coverage

Method get_view has 62 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    protected function get_view()
    {
        $batchR = $this->connection->query("SELECT batchID, batchName, endDate FROM batches WHERE batchName LIKE '%FRESH DEAL%' ORDER BY batchID DESC");
        $opts = '';
        while ($row = $this->connection->fetchRow($batchR)) {
Severity: Major
Found in fannie/modules/plugins2.0/FreshDeals/FreshDealsData.php - About 2 hrs to fix

    Method get_batchID_view has 54 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        protected function get_batchID_view()
        {
            if (!is_array($this->batchID)) {
                $this->batchID = array($this->batchID);
            }
    Severity: Major
    Found in fannie/modules/plugins2.0/FreshDeals/FreshDealsData.php - About 2 hrs to fix

      Method getSales has 31 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          private function getSales($upc, $store, $start, $end)
          {
              $dlog = DTransactionsModel::selectDlog($start, $end);
              $upcs = array();
              if (substr($upc, 0, 2) == 'LC') {
      Severity: Minor
      Found in fannie/modules/plugins2.0/FreshDeals/FreshDealsData.php - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status