OpenCart 🇺🇦

Схема

public mixed addReturnReason ( $data )

Аргументы

Аргумент Возможный тип Описание
$data

Описание

Метод пока еще не документирован.

Исходный код

foreach ($data['return_reason'] as $language_id => $value) {
	if (isset($return_reason_id)) {
		$this->db->query("INSERT INTO " . DB_PREFIX . "return_reason SET return_reason_id = '" . (int)$return_reason_id . "', language_id = '" . (int)$language_id . "', name = '" . $this->db->escape($value['name']) . "'");
	} else {
		$this->db->query("INSERT INTO " . DB_PREFIX . "return_reason SET language_id = '" . (int)$language_id . "', name = '" . $this->db->escape($value['name']) . "'");

		$return_reason_id = $this->db->getLastId();
	}
}

$this->cache->delete('return_reason');