Embedding a child report on Exact Form, and actually formatting it without using Juiced "Exact Form Plus" (I'm almost there)

  • 38
  • 3
  • Question
  • Updated 11 months ago
  • Answered

Okay so I've searched and searched and I can't seem to find anyone who's been able to pull this off, and every time someone asks, they’re referred to Juiced Technology’s Exact Form Plus add-on, which I’m sure is great, but that costs money that I don’t want to spend, and I think it would be really cool if I could pull this off myself. I’ve been at it all day and I’ve gotten pretty far, but now I’m at a roadblock and need help!

My goal is to embed a child report on my Exact Form (EF), and format it to match the rest of the form. Think of my exact form as a Purchase Order, and the embedded report would be the list of items on the order. (It’s worth noting that once I’ve initially created an EF, I do all my edits directly through HTML using Microsoft Expression.)

Hopefully the rest of this makes sense.......

Method 1:
I was able to get the child report to show on the EF by placing:
~=qdb.GetURL("childDBID", "API_GenResultsTable^query={'36'.TV.'"+ field["Record ID#"]+"'})~
in a text area of my exact form. Functionally, this solves my issue, (the query ensures that only the related child records are shown, '36' is the fid of the Related Record field on the child form, and '"+ field["Record ID#"]+"' is the rid of the parent). The problem with this method though is that the report looks just like it does on Qbase, and isn't anything close to how my exact form is formatted.

Method 2:
I created an HTML version of my child report by using the API_GenResultsTable. Using this method, I was able to get the report to match my EF format PERFECTLY just by adding some CSS to the header of the EF. I used this as a guide to make my html report: https://www.quickbase.com/api-guide/gen_results_table.html
The problem with this method though, is that I can’t figure out how to filter the records so only the related child records show up, so now I have this massive list of unrelated records on my exact form.

Based off of the above, Method 2 is obviously the way to go. So now I need to filter it. I tried to add a query like so:

<s cript lang="javascript" src="https://xcor.quickbase.com/db/chidDBID?a=API_GenResultsTable&jht=1&query={'36'.TV.'"+ field["Record ID#"]+"'}"></script>
in my EF, but it didn’t work at all & just gave me a blank page, so I tried changing it up a few times such as:
&query={'36'.TV.'[Record ID#]'}
&query={'36'.TV.'~Record ID#~'}
But I really can’t figure out how to get the syntax correct. It’s a url reference, but it’s treated as javascript (I think?), so I’m really not sure how to approach it

What am I doing wrong? Is there an easy way to pull the record ID from QB and place it in my query?







Photo of Matthew

Matthew

  • 60 Points

Posted 4 years ago

  • 38
  • 3
Photo of Matthew

Matthew

  • 60 Points
Okay so i did find something that I missed. the query should be: &query={'36'.TV.'_FID_3'}
But if I do that, then it's wanting to grab the rid (fid 3) from the child table, when it need to find the parent rid..
Photo of Keith

Keith, Champion

  • 1,214 Points 1k badge 2x thumb
Hi Matthew,

I can certainly understand that you would rather not pay an additional charge for functionality like this.  However, we've found that most of our clients do not have the time or resources or don't want to spend the time and resources to attempt to perfect this as you are doing.  They instead have focused their time and resources on their business and so they appreciate that there are add-ons like Exact Forms Plus available to them that can provide that extra functionality that they want and need.  Although embedding the child data as you are trying to do on your own is a powerful feature of Exact Forms Plus, there are many other features that help justify its cost.  We at Juiced are always looking to add additional functionality to Exact Forms Plus to make it even more attractive as well.  

We are also getting ready to release a new add-on for NO monthly charge...Exact Forms Basic. This will provide a lot of functionality that is not available with native Exact Forms, including the embedded child data formatting that you are working on.  It will be a scaled down version of Exact Forms Plus with limits on the number of documents you can create every month and limits on some advanced functionality but it will hopefully be something that a lot of QuickBase users will find a value with. 

We plan on offering this add-on for NO monthly charge, just a small one-time setup charge to cover the time it takes to install it in your app.  Availability will be on or around December 1.  I'll post back here with more details as we get closer to making Exact Forms Basic available. 



And a special offer to you Matthew for starting this thread, you can be our first pre-release client on Exact Forms Basic.  Let me know if you are interested. 

Keith
Photo of Matthew

Matthew

  • 60 Points
Keith,
I understand the convenience and capability of EF+, but it's just in my nature to try to accomplish things on my own, sometimes just to see how close I can get.
As of today I've answered my own question. I couldn't get the syntax correct for the query on method 2, so I stepped back and thought about method 1. Using method 1 I was able to properly set up the query to filter and organize exactly what i wanted to display, (which took care of the hard part in my opinion.) Then I had to figure out how to get the formatting correct, so I spent some time reading through stackexchange and W3Schools.com, and basically created my own CSS page with styling code that overrides the CSS page that gets generated by QBase for the embedded table, and after some tinkering I've actually pulled it off! I have an embedded report on my exact form, that actually matches the formatting on the rest of my form, and I did it all myself. Oh and here's a kicker, when I started this, I knew next to nothing about CSS and how it applies to HTML aside from simple in-line stuff.

Now that being said, there is a risk to all of this: if the QBase developers change the way that the CSS or HTML gets generated for these embedded tables, there is a chance that my CSS overrides will stop working. Not the end of the world, but it would take time to try and fix it.

So Keith, I might be interested in the Exact Forms Basic product. I'd like to see what the capabilities and limitations are compared to EF Plus, and get some more info about it. How can I contact you?

-Matt
Photo of Lee Parker

Lee Parker

  • 102 Points 100 badge 2x thumb
Matt, I hope you are doing well this afternoon. I am also attempting to reference a child (or grandchild) report from an exact form on a parent. Would you mind sharing how you got around the field reference issue? Thanks! Lee
Photo of Derek Roush

Derek Roush

  • 182 Points 100 badge 2x thumb
Matt,

Maybe things have changed by now, but can you give any insight into where you edited the CSS to change the embedded table formatting?  I've been looking at the w3schools pages, but I haven't had any luck changing the table font through the inline tags or internal style sheet.  I tried copying the QB style sheet, changing all the font tags, and changing the CSS reference to my new external version.  Nothing has changed the font in the embedded table.
Photo of QuickBase Tools

QuickBase Tools

  • 22 Points
Hi Matt,
  good for you, persistence pays off.  Always a good feeling when you can get creative with QuickBase and get it to do what you want it to do.  

contact me using info@juicedtech.com

Keith