Okay, so let's let's now continue for implementing the rest of notations. Here this is a requisition approval, this human task will be have the information which the user will send to the process. So, I will open this human task and they will create a new human task. The name I will say for the requisition approval it titled requisition approval as well okay. Of course we can handle the reject and our if you want to make it more complicated you can handle the outcome if it is approved or if it is reject. So and if it is reject, you can send the email and terminate if it is approved, it should be continued.
But now you know how to can use a gateway in a way. So I will go now with without a chick. So here I will add a parameter which is a B loot this task should see of course it will see the data which is coming and it should not be updatable. So, it should be just read only and he will approve or reject to this task as an outcome and the police okay that session you will find here in a way is that object is going to choose a requisition approval in what So, is this fine Of course because it is not updatable, so there is no output and no other Come at all. So looks ok here. So this is for the human task.
In it loop this is called script notation. This script annotation is just for initialize some data. So in initial loop, I need to initialize some parameter with as zero first thing. So here is a data object, we can create a new. We can say, for example, new barometer, and it will be of type integer. And I need to assign zero to this route parameter, you can double click on it and right here, zero It means you assign zero to this loop parameter.
So, once this flow reached here, it will set a low bomb as a zero this is a web surface we will keep the whip surface later after we query the database tables then we will create a web surface. So this will keep it now later later on. So here increment loop I need to increment as up in parameter by one so here I will go sociation Here you'll find two parameter, double click this Okay, we can See here in blue forum plus one and you cannot say it here like this. So long form plus one and a twice a sign two brothers this will be to increment the loop parameter but it's okay okay. So this script as well is okay now save for this supplier human task two supplier which will receive a the order so here we will create supplier day two Please prepare this order okay.
And here it will use as a this order he will see the order formation from this object to see a we can add another muscle for example region Shan region because as far as our wants the user receive it he can reject it so, at least he can see the reason of the rejection I will add it here as well as a read only okay close okay okay. Because here in this human toss it can be restricted So, it will go Here's the reason he can at least a supplier can see what his problem why it is rejected. So, this is for the supplier. let's implement the received product from the supplier. We can copy sis name, we will create another human task we can see see product from supplier by to see product from supplier there below data which this task can see will be customer order and the rejection region and it will be updatable because the user in this human task can reject it and he can write the reason was rejection and there's a supplier will see this So, I will add this as Here of course this is the the outcome as well.
So I will create here new we can say Seaver How come I need to catch the outcome of this human task? So receiver outcome I will add it No it is not here I needed to add in here. So, the outcome of this human task which is approve or reject well what is this parameter received outcome and the payload of this human task will be a customer order object that object and rejection region and bris causes and depressed okay if you have a look into that association You will find here the input to this human task is this object and rejection region and you will find the outcome here will be go to the receiver outcome just to be sure all looks okay. For this gateway did go for rejection if the outcome is rejected, so here is a function I will check the receiver outcome if it is equal equal reject if an outcome equal equal reject, okay this is a condition okay it will back again to the supplier Okay, so now, the missing thing here is the whip surface.
And there's the other process which you have to create another process called error management or error catch error which will be we can we will be created if surface is not available error. This is an email notification actually we can send the email here indemnification say implementation okay this is a from or to all this we can add here is a to select function simple expression and it will be to me customer email. This is the customers email will be here in situ okay The content here's the subject. Your order is ready for item we can add something exists and right item. It's a symbol separation for item and we can add here that item may be good code item description. Okay.
And we can close this. So this is will be the subject your order is ready for item and item. Okay, here's the body as well. Come right Hi baby your order is any message you want to send and press K and the brace okay. So, this is the error if I will try to find one email server I can configure it so that you will be able to see how you can send him a notification. So, I will I will try to find this and I will let a During this course and I will show you how you can send the Configure the mail and how you can send a mail.
So now the only missing thing is the other process and the whip surface. From the custom video we can start for creating the tables which you need and the whip surface which is required. After that we can come and implement this web service. So see you next video.