ODF additions

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@3390 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Paul Holmes-Higgin
2006-07-24 15:40:11 +00:00
parent 1f02554c1d
commit f6f2ca6d5b
17 changed files with 95 additions and 135 deletions

View File

@@ -17,6 +17,7 @@
package org.alfresco.web.action.evaluator;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.security.PermissionService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.bean.repository.Node;
@@ -33,8 +34,7 @@ public final class ApproveDocEvaluator implements ActionEvaluator
public boolean evaluate(Node node)
{
return (node.getProperties().get("app:approveStep") != null &&
node.isLocked() == false &&
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false);
node.isLocked() == false);
}
}
/*

View File

@@ -0,0 +1,42 @@
/*
* Copyright (C) 2005 Alfresco, Inc.
*
* Licensed under the Mozilla Public License version 1.1
* with a permitted attribution clause. You may obtain a
* copy of the License at
*
* http://www.alfresco.org/legal/license.txt
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
* either express or implied. See the License for the specific
* language governing permissions and limitations under the
* License.
*/
package org.alfresco.web.action.evaluator;
import org.alfresco.model.ContentModel;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.bean.repository.Node;
/**
* UI Action Evaluator - 'Approve' workflow step for document.
*
* @author Kevin Roast
*/
public final class ApproveNonDraftDocEvaluator implements ActionEvaluator
{
/**
* @see org.alfresco.web.action.ActionEvaluator#evaluate(org.alfresco.web.bean.repository.Node)
*/
public boolean evaluate(Node node)
{
return (node.getProperties().get("app:approveStep") != null &&
node.isLocked() == false &&
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false);
}
}
/*
<a:booleanEvaluator value='#{r["app:approveStep"] != null && r.workingCopy == false && r.locked == false}'>
*/

View File

@@ -17,6 +17,7 @@
package org.alfresco.web.action.evaluator;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.security.PermissionService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.bean.repository.Node;
@@ -33,8 +34,7 @@ public final class RejectDocEvaluator implements ActionEvaluator
public boolean evaluate(Node node)
{
return (node.getProperties().get("app:rejectStep") != null &&
node.isLocked() == false &&
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false);
node.isLocked() == false);
}
}
/*

View File

@@ -0,0 +1,42 @@
/*
* Copyright (C) 2005 Alfresco, Inc.
*
* Licensed under the Mozilla Public License version 1.1
* with a permitted attribution clause. You may obtain a
* copy of the License at
*
* http://www.alfresco.org/legal/license.txt
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
* either express or implied. See the License for the specific
* language governing permissions and limitations under the
* License.
*/
package org.alfresco.web.action.evaluator;
import org.alfresco.model.ContentModel;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.bean.repository.Node;
/**
* UI Action Evaluator - 'Reject' workflow step for document.
*
* @author Kevin Roast
*/
public final class RejectNonDraftDocEvaluator implements ActionEvaluator
{
/**
* @see org.alfresco.web.action.ActionEvaluator#evaluate(org.alfresco.web.bean.repository.Node)
*/
public boolean evaluate(Node node)
{
return (node.getProperties().get("app:rejectStep") != null &&
node.isLocked() == false &&
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false);
}
}
/*
<a:booleanEvaluator value='#{r["app:rejectStep"] != null && r.workingCopy == false && r.locked == false}'>
*/