public function actionDeletePreference(){
        $post= Auction::$app->request->post('id');

        $post = Json::decode($post,true);

        if(DealerPreference::model()->deletePreference($post)) {
            return $this->actionIndex();
        }
    }
Ejemplo n.º 2
0
 /**
  * @return \yii\db\ActiveQuery
  */
 public function getDealerPreferences()
 {
     return $this->hasMany(DealerPreference::className(), ['dealer' => 'id']);
 }