public function actionDelall() {
if (Yii::app()->request->isPostRequest) {
$criteria = new CDbCriteria;
$criteria->addInCondition('rec_id', $_POST['selectdel']);
Cartdb::model()->deleteAll($criteria);
if (isset(Yii::app()->request->isAjaxRequest)) {
echo 'ok';
}
else
$this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('index'));
}
else
throw new CHttpException(400, 'Invalid request. Please do not repeat this request again.');
}