예제 #1
0
파일: __init__.py 프로젝트: triicst/JMS
 def ShareWorkflow(self, workflow_id, user_name, permissions):
     workflow = self.GetWorkflow(workflow_id)
     user = User.objects.get(username=user_name)
     
     Workflows.ShareWorkflow(self.user, workflow, user, Run=permissions["Run"], 
         Export=permissions["Export"], Publish=permissions["Publish"], 
         Edit=permissions["Edit"], Admin=permissions["Admin"]
     )
예제 #2
0
파일: __init__.py 프로젝트: triicst/JMS
 def UpdateWorkflow(self, workflow_id, workflow):
     with transaction.atomic():
         w = Workflows.UpdateWorkflow(self.user, workflow_id, workflow["WorkflowName"], 
             workflow["Category"], workflow["ShortDescription"])
         
         version = self.GetWorkflowVersion(w, 'dev')
         version = WorkflowVersions.UpdateWorkflowVersion(self.user, version, 
             workflow["ShortDescription"], workflow["LongDescription"])
     
     return w
예제 #3
0
파일: __init__.py 프로젝트: triicst/JMS
 def AddWorkflow(self, workflow):
     with transaction.atomic():
         #create the workflow
         w = Workflows.AddWorkflow(self.user, workflow["WorkflowName"], 
             workflow["Category"], workflow["Description"], False)
         
         #create the development workflow version
         version = WorkflowVersions.AddWorkflowVersion(self.user, w, 
             "dev",  workflow["Description"], "")
     
     return version
예제 #4
0
파일: __init__.py 프로젝트: triicst/JMS
 def UpdateWorkflowAvailability(self, worfklow_id, publicInd):
     workflow = self.GetWorkflow(worfklow_id)
     return Workflows.UpdateAvailability(self.user, workflow, publicInd)
예제 #5
0
파일: __init__.py 프로젝트: triicst/JMS
 def UnshareWorkflow(self, workflow_id, user_name):
     workflow = self.GetWorkflow(workflow_id)
     user = User.objects.get(username=user_name)
     Workflows.UnshareWorkflow(self.user, workflow, user)
예제 #6
0
파일: __init__.py 프로젝트: triicst/JMS
 def DeleteWorkflow(self, workflow_id):
     Workflows.DeleteWorkflow(self.user, workflow_id)
예제 #7
0
파일: __init__.py 프로젝트: triicst/JMS
 def GetWorkflow(self, workflow_id):
     return Workflows.GetWorkflow(self.user, workflow_id)
예제 #8
0
파일: __init__.py 프로젝트: triicst/JMS
 def GetWorkflows(self, ):
     return Workflows.GetWorkflows(self.user)