diff --git a/src/Controller/MainController.php b/src/Controller/MainController.php index a2b7f58..e3e1257 100644 --- a/src/Controller/MainController.php +++ b/src/Controller/MainController.php @@ -572,6 +572,7 @@ class MainController extends AppController { $resultSet = []; // get avg prices + /* $conn_local = ConnectionManager::get('localdb'); $stmt_price = $conn_local->execute("SELECT AVG(USD) AS AvgUSD, DATE_FORMAT(Created, '$sqlDateFormat') AS TimePeriod " . "FROM PriceHistory WHERE DATE_FORMAT(Created, '$sqlDateFormat') >= ? GROUP BY TimePeriod ORDER BY TimePeriod ASC", [$start->format($dateFormat)]); @@ -582,6 +583,7 @@ class MainController extends AppController { } $resultSet[$price->TimePeriod]['AvgUSD'] = (float) $price->AvgUSD; } + */ $conn = ConnectionManager::get('default'); // get avg block sizes for the time period diff --git a/src/Model/Entity/Claim.php b/src/Model/Entity/Claim.php index a7651e7..cfd183d 100644 --- a/src/Model/Entity/Claim.php +++ b/src/Model/Entity/Claim.php @@ -29,7 +29,7 @@ class Claim extends Entity { $ctTag = 'image'; } - if (!$ctTag && $this->claim_type == 1) { + if (!$ctTag && $this->claim_type == 2) { $ctTag = 'identity'; } return $ctTag; @@ -37,11 +37,11 @@ class Claim extends Entity { function getAutoThumbText() { $autoThumbText = ''; - if ($this->claim_type == 1) { - $autoThumbText = strtoupper(substr($this->name, 1, min( strlen($this->name), 3 ))); + if ($this->claim_type == 2) { + $autoThumbText = strtoupper(substr($this->name, 1, min(strlen($this->name), 10))); } else { $str = (strlen(trim($this->title)) > 0) ? $this->title : $this->name; - $autoThumbText = strtoupper(substr($str, 0, min (strlen($str), 2 ))); + $autoThumbText = strtoupper(substr($str, 0, min(strlen($str), 5))); } return $autoThumbText; }