static private function getChanged(Model $model, $action)
    {
        $changed = $model->getDirty();
        if ($action == 'deleted' || empty($changed)) {
            $changed = null;
        }
        return $changed;
    }