Bot Framework Composer - Multiply Choice with Values from PVA - bots

I'm trying to create a meal bot for company intern use. The meal plan changes weekly and I would like to fill the choices with the values from the PVA (Power Virtual Agent). After the user submits his meal choice, I would like to prevent the user from submitting another choice. This is the Dialog I created so far. It works with static values, but I don't know how to add the global variables from the pva. And I don't know how to prevent the user from submitting more than once.
Those are the variables I wanna use in the multiple choice card:
I already checked the "Bot (any topic can access)" checkbox, which creates a global variable.

Related

Handling different user types and data access in react

I am working on a React application with two user types: Buyer and Seller. A Seller can access some (not all) data from the user through a search bar using the user's email. So for example, if a buyer wants to know what interests the buyer to buy, and he has the user's email and did a search query it can show the user's interest if and only if the user made these data available to show if looked up.
Now, I have two user types, and one of the users Seller is getting access to info from the other Buyer. How to implement that the right way? And how to make sure the search is working properly. Any ideas? Thanks!
You can really only achieve this properly through a database, what you want to do is have a user table that contains all of the users connected to your app, then, one of the fields you would have for the user is AccountType, there, you would declare a 0 for a buyer or a 1 for a seller. For the search bar you would use a FlatList that contains the data you want to display, since your question is so broad I can't really provide you with examples, but if you read this you should be able to make what you want:
For the database (using MySql): https://dev.mysql.com/doc/refman/8.0/en/
For the FlatList and SearchBar: https://www.geeksforgeeks.org/how-to-add-searchbar-in-react-native/ - https://reactnative.dev/docs/flatlist

Accessing Anylogic Agents not created automatically at the start of the model

With Anylogic Agent based modelling, If you create Population of Agents (for Example MyAgent and myAgents are the type and population respectively) but leave it empty at design time and when the model runs initially, say they are created by use of the inject function. When the model creates them by inject through the logic of the model, the population - myAgents still remain empty. Where is the population of these agents? I know they exist because i can count them and access their properties. How to access a particular member of this group and browse through their properties of each, like you can with existing non empty populations?
Ok, i just realized how to do this. When you add agents by say injecting them and you have "add agents to Default Population" (the default option). It doesnt go to the population "myAgents". I am not sure where it goes (in what population) but if you want it to go to "myAgents" you have to choose "Add agents to:" Custom Population and choose myAgents.

Django Viewflow with custom views - start different flows, depending on user selection in the first screen

I have a view with StartFlowMixin, it contains a form - user posts the form and a workflow starts. That works fine currently, but I need to introduce a dropdown in the form with 4 options - based on the selection in that dropdown I need to run a different flow.
E.g. the dropdown contains options like Apply for position A, Apply for position B, etc. Based on the selection the applicant needs to enter different information and different people need to approve the application.
How can I do this? One option would be to have a single workflow with a lot of ifs, but I don't like that.
The core of the BPMN approach for business process modeling is to record every user's decisions.
You could use flow.Switch for that case - http://docs.viewflow.io/viewflow_core_node.html#viewflow.nodes.Switch
Or you could use your own view, that would call required flow.StartFunction, to start actual flow - http://docs.viewflow.io/viewflow_core_node.html#viewflow.nodes.StartFunction

Dialogflow: Determine product name or Select a product from a list which are fetched using a webhook

I am trying to build a bot(custom UI in my website) where a user will enter a product name to view the details of it and I will provide a link to the product full details page. I have a situation where if the user enters a name and there are multiple results from my database, I want to show him those products as quick replies so that he can select one from them.
How do I recognize that the user has entered the product name and anything else? I can use #sys.any, but all small conversation will also go there, which will be of no use.
The same problem occurs when I display him a list of products with matching name. But now when the user clicks on any of the button I am taking him to a custom follow-up intent where I have entered the template for a product entity. But, dialogflow only recognizes the products that have been defined in the entity(listed few products and checked auto expand).
I have tried using #sys.any instead, but the intent is called for any string the user types in. Lets say, the user does not respond and after a while he types in "hi", my intent with any is being called. How do I overcome this situation?
So far as I understand, I can see two ways to solve this query. First, using an entity & defining your product list over there for bot to understand user responses (which you have done) but this will become an overhead when you have a list of say 1000/more products. Second way, you can continue using #sys.any & define a parameter, write a webhook where you validate user entered response to product list in database & check if it is present over there, if yes, show product details or say, entered response is incorrect.

Load Runner facing isse during Dyanmic data handling

I am using load runner 9.5. I am facing a problem during Dyanmic data handling. Scenario is given below-
I have Library management application. Login-> Select book(data display based on User credential) -->Purchage and Logout.
Ex: Guest user: 50 Books display to choose
Admin : All Books display choose
Normal user : 100 Bokks display choose
Please help me How to handle these type of dynamic data based on user role. Is there need to create different script with different role ?
Please follow the below steps -
Record the same flow with the same user credential 2 times (Replica of first script)
Compare the scripts using W diff
Find the values which are different like purchase order, timestamp and user session.
Correlate the values which are highlighted in yellow means value which is different in each script.
Have you had the benefit of training in LoadRunner and a mentor for your first year of work in this field?

Resources