22 lines
353 B
PHP
22 lines
353 B
PHP
<?php
|
|
|
|
class ArticlePoints extends Model
|
|
{
|
|
|
|
function __construct($fromArray = array())
|
|
{
|
|
$this->_tableName_ = 'articlePoints';
|
|
parent::__construct($fromArray);
|
|
}
|
|
|
|
static function model()
|
|
{
|
|
return new self();
|
|
}
|
|
|
|
function deleteByArticle($id)
|
|
{
|
|
App::DB()->query('DELETE FROM `' . $this->_tableName_ . '` WHERE `articleId` = ' . $id);
|
|
}
|
|
}
|