Michael RICOIS 42cfff492f Simulator
2017-06-20 11:11:51 +02:00

20 lines
645 B
PHP

<?php
class SimulatorTheme extends ObjectModel
{
public $id_simulator_theme;
public $id_simulator;
public $name;
public static $definition = array(
'table' => 'simulator_theme', 'primary' => 'id_simulator_theme', 'multilang' => false,
'fields' => array(
'id_simulator' => array('type' => self::TYPE_INT),
'name' => array('type' => self::TYPE_STRING),
),
);
public static function getFromProduct($id_product)
{
return Db::getInstance()->getValue('SELECT `id_simulator_theme` FROM `'._DB_PREFIX_.'product` WHERE id_product = '.(int)$id_product);
}
}