This topic contains 7 replies, has 3 voices, and was last updated by mirche 9 years, 1 month ago.
- Topic
Hi fellow Oro’ers,
I’ve recently viewed the oro workflow webinar and I was quite impressed by the presentation itself. Since there was a nice demo and code example on how these workflows work as far as the configuration goes, great job Oro team!
Since I’ve had some play time with the workflows I recently ran into some trouble. Although the workflows are very flexible and very well documented (in the workflow bundle), I came across an maybe somewhat impossible configuration.
The workflow basically follows the same flow as the b2b_flow_sales_funnel flow only with some extended fields. The dealbreaker on this was adding an attachment/file/image type to the flow. What I basically wanted to create is when an opportunity is being approved, read close_as_won, I want to be able to add an Attachment (file/image) for future reference. Since the attachment isn’t a property path on any of the entities which live in this workflow I figured that I had to create a new entity:
12345approval_document:label: madia.extendopportunity.attachment.entity_labeltype: entityoptions:class: Oro\Bundle\AttachmentBundle\Entity\FileOk so far so good, this will correctly load into the workflow. Next thing was to add an image uploader to the correct form:
12approval_document:form_type: oro_fileThis turned out just as nice as I had in mind. The problem I’ve encountered is on saving this darn thing. I’ve tried to add a init_actions => create_entity or create_object with the sales_flow_owner as the owner of the file. I’ve tried to add a post_actions => create_entity and create_object, but it will produce the same error over and over again:
A model for "Oro\Bundle\WorkflowBundle\Model\WorkflowData::approval_document" was not found
For now I’m stuck at this error for a couple a days and to be honest don’t have the knowledge (yet) to see or create something for this. I wonder if some of you might have tried this or solved this, for me (for now) impossible error. Maybe some of you might have some ideas on what to do or explain why this is happening? I look forward to your responses!
Kind Regards,
Jaimy Casteleijn
The forum ‘OroCRM – Programming Questions’ is closed to new topics and replies.