How To: Kinetic - Updateable UBAQ in a Grid

Ope hey der. It’s me! Jessica!

Haven’t done one of these in a while and a good topic came up from another thread that I figured I’d make a more official post on.

How in the heck do you wire up a UBAQ to a grid in Kinetic and, you know, actually make it update?!

Drum Roooooolllllllll

You gotta work for it. Boooo. :slight_smile:

  1. This step is hopefully obvious, but go build your UBAQ. I’m not gonna get into that, there are plenty of posts on how to do so. Work yer Google-Fu on EpiUsers.
  2. Open up Application Studio on the form you want to add the grid to.
  3. Create a DataView to hold the BAQ information for the update

  1. Throw a panel card grid to your work surface (you can also use a regular grid).

  1. Go to the Properties of your new panel grid and go to the Grid Model property and make it editable.

  1. Add your columns from your UBAQ.

  1. Make the column you want to update… well… updateable!

  1. Go to the Grid Model > Provider Model property and set the view you created in step #3 and enter your BAQ ID

  1. Go back to the top level properties of your grid and go down to Action Data.

  1. Add a new Tool for Save. Give it an ID for use later, a description (what will be shown to the user when they hover, an icon (optional), and add it to the primary toolbar (optional).
    You can find the icons here: Material Design Icons (pictogrammers.github.io) Use whatever you want, just make sure that it’s in the format of “mdi + icon name”. For example, the icon’s name that I used was “mdi-ghost”, so I would enter mdi mdi-ghost

  1. Create a new event and make the Trigger be Control > On Click > Your tool ID from Step #10

>>> Click here if you’re on a version below 2022.2 for steps 12 and 13 <<<

  1. Call the erp-baq widget and wire it up for an update and attach the view you created to it.


image

  1. Lastly, throw on another erp-baq for the grid refresh.

Voila!

Context with my UBAQ: I just made a simple UBAQ where I can update the TypeCode. It will only show the top 10 purchased parts, so you can see that when I change the top to to manufactured and save it, they drop off after the refresh.
UBAQ_Kinetic2

13 Likes

Hmm, everything was going well until the erp-baq widget. I don’t have the same options on mine that you display above. Any idea why? I’m on version 11.2.100.12

Go into the BAQ Execute Options. Setting update there should probably do.

This was done on 2022.2.2.

I don’t see where I’d do that.

Oh, interesting!
Let me hop on an older system and take a look.

1 Like

Okay, some modifications for 2021.2.X for steps 12 and 13.

  1. Call the rest-erp widget and wire it up as follows:

image

Add the name of the view you created in step 3.
image

Parameter Path must be queryResultDataset
Parameter Name must be Results
View Name is the view you created in Step 3

Add the name of your view from Step 3 in Dataset Id and Server Dataset Id
image

  1. Add an erp-baq widget for the refresh.

image

That should do it for anyone under 2022.2.

3 Likes

@hmwillett In step 6, you’re adding columns from your BAQ, but it doesn’t look like you bind your grid to the dataview or BAQ until step 9. How do you properly add the columns you want to see? And is there a difference if you when adding them under Grid Model > Columns or Grid Model > Provider Model > Columns?

I always seem to have an issue creating columns for BAQ Dataviews. If I do nothing under the columns it will return everything from the BAQ, but the column headings are ugly. I can’t seem to find the right location and format to add individual columns.

Think I answered my own Question

Add Columns using Grid Model > Columns (like your step 6 screenshot) and be sure not to do anything in Gird Model > Provider Model > Columns.

Just need to Add New and provide Field (Name of BAQ/Dataview Field Only) and Title values.

BIG IMPORTANT You need to save and exit your custom layer before these changes fully take effect. If you go directly to preview, data does not load. Upon re-opening the kinetic custom layer everything was all good.

BIG IMPORTANT #2 If you’re BAQ Dataview is utilizing a Parent/Child Relationship. All of the relationship fields must be added to your columns

Thanks Hannah! This worked great. My mistake when running though this is I didn’t include all my columns and I only added the columns I wanted to display. This meant I missed my key fields that were needed by the BAQ update.

1 Like