An open API service indexing awesome lists of open source software.

https://github.com/donkeycode/propel-lockable-behavior

Allows you to mark columns edited as lock and choose forceUpdate or not
https://github.com/donkeycode/propel-lockable-behavior

Last synced: about 2 months ago
JSON representation

Allows you to mark columns edited as lock and choose forceUpdate or not

Awesome Lists containing this project

README

          

# LockableBehavior

[![Build Status](https://travis-ci.org/donkeycode/propel-lockable-behavior.svg)](https://travis-ci.org/donkeycode/propel-lockable-behavior)

The **LockableBehavior** behavior allows you to mark columns edited and choose forceUpdate or not.

Installation
------------

Cherry-pick the `LockableBehavior.php` file is `src/`, put it somewhere,
then add the following line to your `propel.ini` or `build.properties` configuration file:

``` ini
propel.behavior.visibility.class = path.to.LockableBehavior
```

Usage
-----

Just add the following XML tag in your `schema.xml` file:

``` xml


```

The **lockable** behavior requires four parameters to work:

* `apply_to`: the list of column to apply the visibility behavior

## In php :

* `$post->activateLocker()` set true to locker fields at `preSave`
* `$post->activateLockCheck()` revert locked fields at `preSave` to only persist not locked fields