View user specific booking
Question

Hi Team,

After saving the booking ,If user clicks on view booking the details are not getting shown,Booking Id is not getting passed to view booking screen.It is always sending 53 as booking Id ,But In table I can see the new booking Id has created.

on click of viewBookings.no data displayed as it is sending booking Id as 53 everytime

Solution

Hi Ujwwala,

Please find attached the updated OML. I am not sure why do you want to append the items into the list, since you can directly populate the table with aggregate. 

Thanks & Kind Regards,

Sachin

columnnamesSachin01April2021.oml

Solution

Please check the attached OML for your solution of your questions. Hope it will help you.

Thanks & Kind Regards,

Sachin

empaddSachin26.oml

Solution

Please find attached the updated OML. I have added ListAppend action on button click which will refresh the list data which is bind with Tablelist.

Let me know, if you need any other help.

Thanks & Kind Regards,

Sachin

RestServeceApp1Sachin17.oml

Solution

Please see attached Sample OML for web blocks. Kindly look into this and let me know, if you have any question.

StarSachin.oml

Solution

The Radio group is bind with the PreferredFoodTypeId Identifier which is storing the value of entity identifier for the selected item into the group.

The below screenshot is the inspect of the page where you can see that value of each radio button is different, but name is same for radio button group (PreferredFoodTypeGroup). I hope this will clear all your confusion related to radio button group.

Solution

Hi Ujwwala,

Please find attached OML with changes to pull the time from BookingSlot entity instead of Foodtype entity. Kindly review it and let me know, if you need any other help.

For button you can use it's style property or write your own CSS.


Thanks & Kind Regards,

Sachin

Appres771.0.Sachin08oml.oml

Solution

Please find attached the updated OML. I have made some changes into both User/Admin Booking Screens. 

1. Admin Screen - > Records will save into both entities (BookingSlot and TimeForFood).

2. User Screen --> Time will be selected based on the Selected Food Type on screen and Record will save only into BookingSlot entity.

Kindly check and confirm.

Thanks & Kind Regards,

Sachin

Appres1Sachin04.oml

Hi Ujwwalla,

That's correct :). But like I said above the guided training paths will explain alot of the basics in outsystems and will help you a long way in to the platform. Link: https://www.outsystems.com/training/paths/ 

Also make sure to mark a post as solution if your question has been answered.


Greetings,


Nick


Hi Ujjwwala,

Could you please share the OML to look into this issue?

Thanks & Kind Regards,

Sachin

Hi Ujjwwala,

Please find attached the updated OML. I have made the changes to CreateBookingScreen and ViewBooking screens. In ViewBooking screen I have just soft deleted the record i.e. updated the booking status to "Cancelled" from "Booked". 

Thanks & Kind Regards,

Sachin

AppSachin010221.oml

Hi Sachin,

I have one query as when passed foodType-createbooking screen- I have created separate aggregate but in Text option text It is not showing the time ,The time option is not coming -If I give explicitly it comes,Any reason please.

App88.oml

Hi Ujwwala,

It looks like you don't have some records into the BookingSlot entity to pull the time from this entity. Can you please confirm?

Thanks & Kind Regards,

Sachin

Hi Sachin,

 If I use GetBookingSlotsbyId.List as a list for Time dropdown then I can select  the Text as Bookingslot.Time ,But if I select above list name as per screenshot,I can not select option Text automatically.

Hi Ujwwala,

I tried the both list options (GetBookingSlotById and GetBookingSlotsByFoofTypeId) and see that from both the list it is assigning the BookingSlot.Name into dropdown's Option Text property. And, we have to change it explicitly to BookingSlot.Time to populate the dropdown with Time.

As per my understanding, since dropdown's Options Contents defaults to "Text Only", the Option Text property looks for the entity attributes which are having data type as Text in the first place and in the Booking Slot entity it found Name attribute. So, for this reason it is default assigning BookingSlot.Name into the Text property instead of Time since it's datatype is Time not Text.

Hope this will make sense and resolve your query. :) And for more details please refer this link.

Thanks & Kind Regards,

Sachin



Hi Sachin,

I am trying to populate the structure response from rest in table on screen.

But table source will be list,Kindly check the below oml and suggest.

Thank you

RestServeceApp.oml

Hi Ujwwala,

Please find attached the updated OML. I have corrected the URL/path as shown below and it is giving the response which I have displayed on the screen. 

Please let me know, if you need any other help.

Thanks & Kind Regards,

Sachin

RestServeceAppSachin15.oml

Hi sachin,


Thank you for the reply,

On a similar line trying to print table as source of structure ,but it is not printing,

Wanted to print complete record,Kindly check.


Thanks,

Ujwwala


RestServeceApp1.oml

Solution

Please find attached the updated OML. I have added ListAppend action on button click which will refresh the list data which is bind with Tablelist.

Let me know, if you need any other help.

Thanks & Kind Regards,

Sachin

RestServeceApp1Sachin17.oml

Hi Sachin,

I have requirement to show the entities whatever in my database to shown in dropdown.

Example all 3 entities employee ,Address and Deparatment to be shown.

Once I select the entitity ,In the next dropdown It should show the columns of that entity.

Please suggest .Also if I can show the datatypes of the column in next dropdown.

empadd.oml

Hi Ujwwala,

Please find attached the updated OML. Just you need to make a changes into the GetEntity aggregate for EspaceID. Currently, I have assigned it 113 which is of my environment.

Kindly let me know, if you need any other help.

Thanks & Kind Regards,

Sachin

empaddSachin25.oml

Hi Sachin,

Wanted to know how to provide select option in dropdown in start as empty text in dropdown "select entity" does get considered and once I select the entity then column then based on column (attribute) in next dropdown user should be aware of what is the text (length/mandatory  and data type of the selected field)..Please provide suggestion as based on attribute how all information above can be shown at once .which widget should be used to show user validation all at a time.

Thank you for your help.

Solution

Please check the attached OML for your solution of your questions. Hope it will help you.

Thanks & Kind Regards,

Sachin

empaddSachin26.oml

Hi Sachin,

I have added google maps for reactive but its not allowing to use on screen,

API key and all are all these to be generated,SImply I am looking based on address it should show location

mapaddress.oml

Hi Ujwwala,

I have added a new screen ShowGoogleMap for your requirements. Please refer that into the attached OML. And to generate the API, please refer this link.

Thanks & Kind Regards,

Sachin

mapaddressSachin03April2021.oml

Hi Sachin,

Do we need to create a project -I am referring https://www.youtube.com/watch?v=SIJUM9rH4qQ,

I am not geetting what is this project is for ,Also please find attached,I have tried with same API key but not getting location,wanted to do with restauarant address.

Do I need to create project and enable javascript libraray ,Please suggest

mapadd.oml

Hi Ujwwala,

Yes, please generate the API key as generated as shown in video. I have generated into the same way which was shown in Video. You can name anything to that project. It does not matter for API key generation.

Thanks & Kind Regards,

Sachin

Hi Sachin,

I want to remove the selected element in next dropdown and keep on doing this,

Can you please suggest how to do that and save the mapping in a table from left column and right column,Example both the tables are from diff sources,and finally need to save

Reference SelectDropdownDemoScreen (sbsam.outsystemscloud.com)

columnname1.oml

Hi Ujwwala,

Please find attached the OML for removing the selected element from next dropdown. Kindly review this and let me know, if you need any other help.

Thanks & Kind Regards,

Sachin


columnname1Sachin09.oml

Hi Sachin,

I have tried to replicate same and created jquery script but it says 

Please add the reference as shown below.

And in the screen Required Script property please select Jquery.

Hi Sachin,

There are two client actions.

1)ddlattributeonchange-here id will come in each dropdown -as once selected it need not to come.

Other way

2)dropdown2onchange-Here I want once selected the item-we should get message as already selected and dropdown should be refreshed with all items except selected one.and default selection should not be selected.


Kindly suggest both the ways.

colu23.oml

Hi Sachin tried to check with the jquery http://jsfiddle.net/yxh4h/

$(function() {

      $('.dropdown').change(function() {

           $("'.dropdown' > option:selected").each(function () {

            dropdownval = $(this).val();

            $('.dropdown').not(this).find('option[value="' + dropdownval + '"]').remove();

        });

})

});


for the 1st option but it is not removing Id in next dropdown.

Kindly suggest and please check 2nd option as well


Thanks

Hi Sachin,

I am trying to get the cellname from columncount as ,input to cell read is columncount,It will read the cell headers ,But if user give start and end column on screen then how to incretment to give the input to cellread as cellname?Please suggest as on screen user will enter start and end col A1 to A10 example then all headers should be visible on screen

Sorry,Cellname will be start A1 End G1 Example.

Hi Ujwwala,

Please find attached OML where you can upload any excel and it get saved into the database and then you can read it's header values.

Kindly review it and let me know, if you need any other help.

Thanks & Kind Regards,

Sachin

ExcelDataUploadSachin19.oml

Hi Sachin,

I have added to show message on client action and not mapped columns .But not mapped columns -not coming correctly and I want to show message to user to continue mapping even if all not filled and to give warning message also

column23.oml

Now the logic of not mapped working,But need to continue saving even if all not mapped.

column24.oml

Hi Sachin,

Please find latest.

I have added javascript but wanted to show custom message as its browser specific env deatils on dialogoue should nt cm ,I have checked confirmation dialogogue component but sure to use.Also please let me know if there is any Intelligenect where execl columns can be directly mapped to DB columns with name match similar

column33.oml

Hi Ujwwala,

Please find attached OML for customized confirmation message. I have used SweetAlert component available into the forge. Please refer below link to install it in your environment to use. I have used this into SaveMappingonClick action. 

https://www.outsystems.com/forge/Component_Reviews.aspx?ProjectId=7559&ReadAllReviews=True

Kindly let me know, if you need any other help.

Thanks & Kind Regards,

Sachin

CustomizedConfirmationMessage.oml

Hi Sachin,

I want to show sheet names on upload of excel so I have used this on getsheets action.

Workbook_GetProperties.Properties.Workbook.Worksheets to loop throgh and store in list.Now on screen want to show the sheets names  as tabs on screen-on clicking the respective tab-  name of the sheet  to be shown in input box in form. and based on the tab selected it should show the excel headers

Please suggest

Hi Sachin,

I have added google geocoding extension and want to pass the address and get the map location.

In restaurant -update restaurant I have passed address to fetch lat and long but not working,

Please check

restadd6.oml

Hi Ujwwala,

Please see below how we need to pass address and google GeoCode API keys to get the latitude and longitude for that address and show on google Maps. 

You need to enable the Google GeoCode API option in your google account. Also, we would need to pass the key generated through your google account to get the values for both the latitude and longitude.

There is a minor change need to make into the Google_Geocoding extension in the URL from http to https. Since now google is supporting https not http to get the data.


Thanks & Kind Regards,

Sachin

Hi Sachin,

PFA,I want to send the city name as input to block and get waether data,Curruently hardcoded city name.


weatherData.oml

Tried with api key to gte loc address in map but stil not working,please suggest

Locmap.oml

Hello,


It's a bit hard to locate the issue from those screenshots alone, is it possible to share the oml? For example I can see that for the bookingId you are passing on you are using a list, are u sure this list is filtered and that it is using the right Id? It can also be that you forgot to refresh your data after saving your booking. Since you are saying its always id 53 my bet is that your aggregate doesn't have the right filters. The oml could help me find the problem


Also Please let me know how to cancel booking,Do I need to create any action on canel,I have just assigned cacelled status to record.PLease check.how to update cancelled status for the same record.

App.oml

mvp_badge
MVP

Hi Ujwwala,

From the screenshots you have shared on thing I can notice is that you are passing BookingSlotId not BookingId.

Also please let me know hoe to cancel the record specific.

App.oml

Hello,

I updated your code a bit and created a new action (BookingSlotActionNick). In here I have placed some comments so it might help you understand the code a little bit better. For deleting a Bookingslot you just have to use the deleteaction and the right Id. 


Besides that, this is very basic OutSystems, have you followed the training path? This can help you understand the platform better. You can find the different training paths on the following link:


https://www.outsystems.com/training/paths/


App.oml

Hi Nick,

Thanks for the reply,I have tried similar what you have done but getting Insertion error on Save booking slot as User.

Can you please guide what is wrong here.

App1.oml

Hi Nick,

Can you please let me know how to add the time in foodTime table  while adding slot,I have created flow but records are not getting added in timefood table.I want to return list of time from aggregate to populate on createbooking screen(on selection of foodtype).

Kindly suggest

Appres.oml

Hi Ujwwala,

First of all you need to design a new screen to add the time in Timeforfood entity. Since it looks like you are trying to pull the time based on the PreferredFoodTypeID from TimeforFood entity which is only possible when there are different entries exist into this entity for PreferredFoodType. 

Please refer the attached OML for reference.

If you need any help, please feel free to let me know.

Thanks & Kind Regards,

Sachin

AppresSachin03.oml

Hi Sachin,

Thank you .

I want to add the entries in the table timeforfood at the same time of booking slot .So in one server action I wanto update both the tables,will it be possible,also please let me by this way how we can return time list from aggregatr timeforfood table by passing foodtype a,

Thank you

Yes, it is possible to add the records into the TimeForFood and BookingSlot entities in the same server action. However, could you please confirm from which entity you want to display the time in the CreateBookingScreen? Since you are trying to get the time and populate the time dropdown from TimeForFood entity and at the same time want to add the time into these 2 entities which is not possible.

In your question of how you can return time from aggregate from TimeForFood entity - On the change event of FoodType dropdown an client action has been triggered which will populate the data into the aggregate based on the selection of FoodType by passing the FoodTypeIndentifier ID. I have done this for you in the OML attached yesterday. Please check client action Dropdown1OnChange3 in CreateBookingScreen and the aggregate added to it.

Thanks & Kind Regards,

Sachin

Hi Sachin,

When admin is doing booking slot at the same time entry should go to timefood and from user specific booking he should pass the typefood and get the time list from aggregate from timefood .

I have tried o update in two table but is inserting into timefood table as default entries,

Please suggest

Appres1.oml

Solution

Please find attached the updated OML. I have made some changes into both User/Admin Booking Screens. 

1. Admin Screen - > Records will save into both entities (BookingSlot and TimeForFood).

2. User Screen --> Time will be selected based on the Selected Food Type on screen and Record will save only into BookingSlot entity.

Kindly check and confirm.

Thanks & Kind Regards,

Sachin

Appres1Sachin04.oml

Hi Sachin,

Thank you for the reply,

I have created two role and two users Admin/User where in based on roles they should redirect ,I have given screen based roles ,But it is only redirecting to admin role screen only.

Appres7.oml

Hi Ujwwala,

You are passing Username into the CheckRoleAction where as it requires UserID. I have made some minor changes, please verify it in the attached OML and let me know, if you need any other help. 

Have a great ahead!!

Thanks & Kind Regards,

Sachin

Appres7Sachin06.oml

Hi Sachin,

Thank you .

I have tried with the oml you sent but with the users craeted it is not navigating to screen for which roles I have assgned already.

Also from user link, personal-hcea5oih.outsystemscloud.com/Users) ,I have craeted two users and assigned role to them but now I am not able to login with AdminUser and pwd as AdminUser-It saysInvalid Permissions (personal-hcea5oih.outsystemscloud.com) ,

Please let me know wht can be the reason for not rediecting to respective screen and also not able to login ad adminUser .

Invalid permission issue is resolved now,But with the two created users I am not able to redirect to their respective screens.I have set the roles screenwise,Is this the correct way or is there any alternative way instaed of every time time screenwise we need to do.

Thank you

Please refer the attached OML and let me know if you need any other help. I have made some changes into the Login Client Action. On the Login button submission I had called "Login" client action and into this action called your created client action LoginClient to verify which role that particular have and based on the redirected to the User/Admin page.

Appres7Sachin06Ver1.0.oml

Hi Sachin,

Thank you for your reply in earlier post,In addition to this instead of creating separate timefood entityi I am trying to fetch from the main entity bookingslot passing foodtype but it is not filtering  in createbookingscreen

Also kindly let me know the style for all buttons they need to fixed at places.(They are not alligned)

User: AdminUser Pwd:AdminUser


Appres771.0.oml

Solution

Hi Ujwwala,

Please find attached OML with changes to pull the time from BookingSlot entity instead of Foodtype entity. Kindly review it and let me know, if you need any other help.

For button you can use it's style property or write your own CSS.


Thanks & Kind Regards,

Sachin

Appres771.0.Sachin08oml.oml

Hi Sachin,

Thank you for reply,

AS per this I can see after refreshing aggregate we should populate list in time dropdown and the value should be time .I see its Id any specific reason.Please clarify.

Also  to filter  records in aggregate do we need to create local variable again as we are not able to select bookingslot object's foodtypeId.Any reason.Please clarify.


Hi Ujwwala,

Please see below the answers for your questions.

1. Generally, when we bind a dropdown to any entity we used to setup it's variable to that particular entity identifier, so when we save record it's identifier get saved into the referenced entity. So, for this reason I had bind the Time dropdown with BookingSlot entity identifier.

2. As far as I know, Yes. Since, we need to pass the entity identifier into the filter parameters for the selected value from dropdown.

Kindly, let me know, if you need any other clarification.

Thanks & Kind Regards,

Sachin

  

Hi Sachin,


Thank you for earlier reply,

Would like to use radio button group to pass preferredfoodTypeId in craetebookinscreen.

same as dropdown,But mapping id is not getting.


Thank you

App25.oml

Please see attached updated OML. I have added radio button group on the createBookingScreen.

App25Sachin28.oml

Hi Sachin,

As seen and the passed value of radio button each is Label value ,but in table it is storing as value.

It seems se dont get option as entites.statisentity.Id option?

PLease clarify how in backend it is storing as ID(Is it because the variable radiogroup is mapped to PreffoodIDentifier?)

Solution

The Radio group is bind with the PreferredFoodTypeId Identifier which is storing the value of entity identifier for the selected item into the group.

The below screenshot is the inspect of the page where you can see that value of each radio button is different, but name is same for radio button group (PreferredFoodTypeGroup). I hope this will clear all your confusion related to radio button group.

Hi Sachin,

Thank you for the reply,Seeing HTML as usual flow ,now it is clear.


Regards,

Ujwwala

Hi Sachin,

I am going through web block but source and target blocks example I am not getting clarity.

I am not getting why we have input parameters in source block .Ideally Instead if we need to pass it to parent  or target block it should be as local variable as sender.(Also source block events we have input parameter)

If you have any sample oml of source web block and target web block,Kindly provide

Thank you

Solution

Please see attached Sample OML for web blocks. Kindly look into this and let me know, if you have any question.

StarSachin.oml

Hi Sachin,


Thank you for help.

Will go through it.


Regards,

Ujwwala

Hi Sachin,

As I have checked I did not get relevance of rating input variable in block.We have mapped it to curruent record  so ideally it shows always the prev value which is thr in DB already.

1)I mean where in the flow complete we are using Rating input param of block. as in handler also we are passing RatingValue.

2)Also please clarify during save how the rating is getting stored as we are not assigning rating value,The local rating value should be assigned to the handlers rating value which received from block.(2nd img)


HI Sachin,


1st point got it as Rating variable on screen level need to maintain for the screen field.

2nd point did not get

Got the answer for 2nd image as well as we are storing as voting type on screen so it will gets stored .

Hi Sachin,

I am trying to print the column names in table ,

Please check and suggest why listappend on iteration of aggregate not works.

columnnames.oml

Hi Sachin,

Want to use list in dropdown and expression,

Please suggest

columnnames.oml

Solution

Hi Ujwwala,

Please find attached the updated OML. I am not sure why do you want to append the items into the list, since you can directly populate the table with aggregate. 

Thanks & Kind Regards,

Sachin

columnnamesSachin01April2021.oml

Can you please share more details on this? I am not clear with the requirements.

Hi Sachin,

Thank you,

Meanwhile I was trying with listappend and somewhere I have seen listappend can not be used in client action,Is it so?

PFA and please let me know list final I am not able to take it on table expression,is it valid first of all which I am doing.

Thanks

columnnames.oml

Hi Sachin ,need to show two tables side by side in a container but not understanding ,How to show,I checked advance UI patter silik UI but I am not understanding how to use,

Can you please suggest,

Can you please check this how would you like to show the tables on side by side? If so, please refer attached OML.

columnnamesSachin01April2021TableDisplay.oml

Hi Sachin,

Thank you for your help,I have seen widget hierarchy and understood distribution of container.

Thank you


Hello ujwawala,


The issue is that you linked your aggregate to your form and you're not taking the local variable. The issue here is because you don't do that, you are trying to create a bookingslot without values and since the preferredfoodtype is a mandatory field the database is complaining that he can't create a bookingslot without preferredfoodtype. So what do you need to do: 

In your form you need to assign every inputfield to the local variable like in this screenshot:

Make sure to apply it aswell to the field above it so you have a record that is filled with data.


Thank you Nick for your quick help.

So as I understood whenever we need to submit the form we should send it as local variable and on server action to pass finally to the createDB Record

So above rule is general I can consider whenever we are inputting from form and it is kind of post request with Body and we are sending while object(local object in outsystem) and mapping form values individually to this object and finally passing to server action which in turn will be responsible to make entry to the database table.

Thanks,

Ujwwala

Hi Ujwwalla,

That's correct :). But like I said above the guided training paths will explain alot of the basics in outsystems and will help you a long way in to the platform. Link: https://www.outsystems.com/training/paths/ 

Also make sure to mark a post as solution if your question has been answered.


Greetings,


Nick


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.