This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

PWO FillOrder raises error in v7.1.1 (call only internally)

Hi all

I used a script in v6 to add Orders which are directly assigned, therewith no approver is needed.

This was done by:

   Dim Bag As New PropertyBag()
   Bag.PutValue("UID_PersonOrdered", UID_Person)
   Bag.PutValue("UID_PersonInserted", UID_Person)
   Bag.PutValue("UID_Org", UID_OrgPr)
   Bag.PutValue("OrderReason", OrderReason)
   Bag.PutValue("OrderState", "Assigned")
   Bag.PutValue("ValidUntil", ValidUntil)

   Dim dbPWO As ISingleDbObject = Connection.CreateSingle("PersonWantsOrg")
   dbPWO.Custom.CallMethod("FillOrder", Bag)

Now in v7.1.1 I receive the error when calling FillOrder:

[2133323] This method can only be called internally.
at QER.Customizer.PersonWantsOrg.FillOrder(ISession session, IEntity entity, PropertyBag propBag, CancellationToken ct)

How can I create an order with the orderstate=Assigned in v7? One Forumentry here refers to the same Problem but the solution was to create an Order which has to be approved, which does not work in my case. Is there a new method I should use?

By the way, I received the error while the Job was processed by the JobQueue, not in designer. (As far as I know, when Debugging in the designer, this method does not work, but when called from the Service, it should)

Thanks for your help,

Kind regards,
Rolf

 

Parents Reply Children
No Data