Remove status table

This commit is contained in:
Benoît Burnichon
2015-12-23 14:12:23 +01:00
parent 699cfad0b6
commit af25e6bfd8
2 changed files with 0 additions and 87 deletions

View File

@@ -1163,25 +1163,6 @@ class record_adapter implements RecordInterface, cache_cacheableInterface
['status' => bindec($status), 'record_id' => $this->record_id]
);
$status = strrev($status);
$length = strlen($status);
$sqlValues = [];
for ($i = 4; $i < $length; $i++) {
$sqlValues[] = join(',', array(
'null',
$connection->quote($this->getRecordId()),
$connection->quote($i),
$connection->quote($status[$i])
));
}
$sql = "REPLACE INTO status (id, record_id, name, value)"
. " VALUES (" . join('),(', $sqlValues) . ")";
$stmt = $connection->prepare($sql);
$stmt->execute();
$stmt->closeCursor();
$this->delete_data_from_cache(self::CACHE_STATUS);
$this->dispatch(RecordEvents::STATUS_CHANGED, new StatusChangedEvent($this));