Refactoring Bpmn/Workflow handling layer (2nd commit)

This commit is contained in:
Erik Amaru Ortiz
2014-01-31 18:49:57 -04:00
parent 8ef25dcc5e
commit cf59ed1308
10 changed files with 506 additions and 69 deletions

View File

@@ -51,7 +51,7 @@ class Content extends BaseContent
* @param string $sUID
* @return variant
*/
public function load ($ConCategory, $ConParent, $ConId, $ConLang)
public static function load ($ConCategory, $ConParent, $ConId, $ConLang)
{
$content = ContentPeer::retrieveByPK( $ConCategory, $ConParent, $ConId, $ConLang );
if (is_null( $content )) {
@@ -76,7 +76,7 @@ class Content extends BaseContent
* @return string
*
*/
public function getDefaultContentLang ($ConCategory, $ConParent, $ConId, $destConLang)
public static function getDefaultContentLang ($ConCategory, $ConParent, $ConId, $destConLang)
{
$Criteria = new Criteria( 'workflow' );
$Criteria->clearSelectColumns()->clearOrderByColumns();
@@ -113,7 +113,7 @@ class Content extends BaseContent
* @return void
*
*/
public function updateEqualValue ($ConCategory, $ConParent, $ConId, $ConValue)
public static function updateEqualValue ($ConCategory, $ConParent, $ConId, $ConValue)
{
$con = Propel::getConnection('workflow');
$c1 = new Criteria('workflow');
@@ -136,7 +136,7 @@ class Content extends BaseContent
* @return string
* if the row doesn't exist, it will be created automatically, even the default 'en' language
*/
public function autoLoadSave ($ConCategory, $ConParent, $ConId, $destConLang)
public static function autoLoadSave ($ConCategory, $ConParent, $ConId, $destConLang)
{
//search in 'en' language, the default language
$content = ContentPeer::retrieveByPK( $ConCategory, $ConParent, $ConId, 'en' );
@@ -262,7 +262,7 @@ class Content extends BaseContent
* @param string $ConValue
* @return variant
*/
public function removeContent ($ConCategory, $ConParent, $ConId)
public static function removeContent ($ConCategory, $ConParent, $ConId)
{
try {
$c = new Criteria();

View File

@@ -406,7 +406,7 @@ class Task extends BaseTask
if ($this->validate()) {
$this->setTasTitle((isset($aData['TAS_TITLE']) ? $aData['TAS_TITLE']: ''));
$this->setTasDescription("");
$this->setTasDescription((isset($aData['TAS_DESCRIPTION']) ? $aData['TAS_DESCRIPTION']: ''));
$this->setTasDefTitle("");
$this->setTasDefDescription("");
$this->setTasDefProcCode("");