Author: pmacadden
Date: 2010-04-30 17:23:45 +0200 (Fri, 30 Apr 2010)
New Revision: 29329
Added:
plugins/pmPropelWorkflowableBehaviorPlugin/trunk/LICENSE
Modified:
plugins/pmPropelWorkflowableBehaviorPlugin/trunk/README
Log:
license and readme updated.
Added: plugins/pmPropelWorkflowableBehaviorPlugin/trunk/LICENSE
===================================================================
--- plugins/pmPropelWorkflowableBehaviorPlugin/trunk/LICENSE
(rev 0)
+++ plugins/pmPropelWorkflowableBehaviorPlugin/trunk/LICENSE 2010-04-30
15:23:45 UTC (rev 29329)
@@ -0,0 +1,19 @@
+Copyright (c) 2010 Patricio Mac Adden
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is furnished
+to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
Modified: plugins/pmPropelWorkflowableBehaviorPlugin/trunk/README
===================================================================
--- plugins/pmPropelWorkflowableBehaviorPlugin/trunk/README 2010-04-30
15:04:46 UTC (rev 29328)
+++ plugins/pmPropelWorkflowableBehaviorPlugin/trunk/README 2010-04-30
15:23:45 UTC (rev 29329)
@@ -0,0 +1,55 @@
+pmPropelWorkflowableBehaviorPlugin
+==================================
+
+The `pmPropelWorkflowableBehaviorPlugin` provides a behavior that adds workflow
+capabilities to a Propel object.
+
+Installation
+------------
+
+ * Install the plugin
+
+ * Subversion
+
+ $ svn co
http://svn.symfony-project.com/plugins/pmModuleEnablerPlugin/trunk
pmModuleEnablerPlugin
+
+ * Add the behavior in your propel model:
+
+ [php]
+ <?php
+
+ class PurchaseOrder extends BasePurchaseOrder
+ {
+ }
+
+ sfPropelBehavior::add('PurchaseOrder', array('workflowable', array(
+ 'status_column_name' => 'status', // this is the default value, a
+ // column name
+ 'possible_status_values' => array() // this is the default value, an
+ // array of possible values
+ )));
+
+ * Rebuild your model
+
+ [bash]
+ $ ./symfony propel:build-all
+
+Methods
+-------
+
+ * stepForward: step forward in the workflow
+
+ [php]
+ $purchase_order->stepForward();
+
+ * stepBackward: step backward in the workflow
+
+ [php]
+ $purchase_order->stepBackward();
+
+If the model contains a method named 'canStepForward' (or 'canStepBackward'),
+it's used to determine if the object can step forward (or can step backward).
+Otherwise, the object steps forward (or backward) only if the next (or
previous)
+value is valid (is in possible_status_values array).
+
+If the model can't step forward (or backward) an exeption is thrown.
--
You received this message because you are subscribed to the Google Groups
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/symfony-svn?hl=en.