Jump to content

DesiLogi

Caspio Rockstar
  • Posts

    402
  • Joined

  • Last visited

  • Days Won

    34

Everything posted by DesiLogi

  1. @Flowers4Algernon, this video is really helpful--thanks for posting!
  2. Hi @foodblogger0919, Thanks for the tip--though I'm not understanding your first suggestion. When you say use 'target_blank within the form itself and not the destination 'window.open', how does that work? Because it's only in the Destination section that the new ID numbers for the new record can be accessed, correct? I wouldn't be able to direct the page to a new destination with parameters from the record created, if I use a call from the form itself. Unless you mean something different?
  3. Hi, I have a submission form that opens in an iframe in a FancyBox over a parent page. When the user submits the form the Destination has some code in it to open a new tab in the parent browser, with a new page. Sometimes there's no issue with a popup blocker but sometimes there is-and the user will rarely see the message in time to allow it. I realize that window.open can trigger a popup blocker unless it's user-triggered. The fact that this code is in the Destination section of the submission form must make it 'non-user triggered', I think, and so the popup blocker is engaged. Is there a way to open a new tab (in the parent section, not the iframe the submission form is in) from the Destination section that avoids a popup blocker? This is the current code: if(v_virt=="proposal"){ setTimeout(window.open('../../proposals/proposal?ProjectID=[@field:ProjectID]&ProposalID=[@field:ProposalID]&runnew=yes&cbResetParam=1','_blank'),1000); setTimeout(window.parent.jQuery.fancybox.close(),2000); } Thanks for any help!
  4. Quick update regarding webhooks--after trying to set them up in Make and Caspio, it was pointed out to me by Caspio support that if the table used in the webhook has a trigger (an Update webhook in my case, trying to use a table with an update trigger) it will not send data, and therefore won't work. Hopefully, this will be addressed fairly soon as most tables have triggers of one kind of another on them.
  5. Hi @Pufok, It's not that Caspio doesn't offer webhooks--they do now, if you build the bridges yourself--but that they don't have it set up as an inbuilt option in Make (unlike the way it is with Zapier, where you can do 'Zaps' based on instant triggers in Caspio). Here's what I got from Make support: So it's possible--I think--a bridge to Make (and therefore other apps via Make) for instant triggered action in Caspio, but it's a convoluted process you have to do yourself. Some of the advice on this forum is really helpful and I'm going to try to implement it. But I wish Caspio/Make was fully integrated for instant triggers, without having to go through all this.
  6. @Barry, Many thanks for posting this. The help articles I'd found left out the basic overview that you wrote out--that's helpful. I'm going to try to follow the steps and the video and see if I can make it work. I'll post again here with any relevant info so anyone can follow the steps.
  7. Hi, I use Make.com to check for records in a View and then update some data--this works fine but it's on a schedule, running constantly. I really need a Make.com scenario to be triggered when a record in a Caspio table is created (or updated, in another scenario). This isn't offered by default--Make.com has a message that Caspio doesn't have webhooks. But since Caspio has put out webhooks I thought this should be doable. I've tried to create that connection in Make.com's 'webhooks' section and then use it, but I cannot get it to work well. I don't have a lot of experience with json and Make. Zapier is simpler to set up but way too expensive, so I'd love to get Make.com to work. Does anyone know of a simple step-by-step article that details how to get webhooks to work with Make for instant triggers? I can't find anything on the net.
  8. This a really great article--I use Make.com for some record updating but haven't yet used Webhooks or AI integration. I find Make.com really confusing, though, compared to Zapier (which is ridiculously expensive). I'll give this angle a shot--thanks for posting!
  9. Thanks for posting this @RuisiHansamu, these are nice workflows.
  10. Hi @Volomeister, just wanted to bump this thread to see if you had a chance to take a look. I can't figure it out myself.
  11. Hi @Volomeister, Thanks for offering to take a look-- I can't export the datapages and dependancies because there's a number of tables and private data I'd need to filter out. But that's ok because it's not related to the datapages. If you use example text instead of datapages it'll do the same thing. The code below, when pasted into a regular html page will reproduce the issue upon print preview. <html> <style type="text/css" media="print"> @media print { body { position: relative; } .footer { position: absolute; bottom: 0; left: 0; width: 100%; height: 50px; } .content { margin-bottom: 60px; /* This ensures there is space for the footer */ } .page-break { display: block; page-break-before: always; } } </style> <body> <div class="content"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce sagittis odio vel felis eleifend, sit amet finibus augue suscipit. Sed consequat nunc vel pellentesque sodales. Duis et nibh nec enim condimentum molestie. Maecenas luctus dictum enim, vel interdum arcu fermentum sit amet. Pellentesque porttitor commodo viverra. Sed tristique dolor sed tristique volutpat. Proin vitae pulvinar nunc. <br /><br /> Donec felis dolor, venenatis ac sollicitudin sed, pulvinar congue dolor. Proin nulla massa, elementum ut rhoncus id, posuere non risus. Proin eu velit in nisi ultrices dictum vel a massa. Vestibulum eget sem at elit maximus lacinia eu in tortor. Suspendisse ullamcorper felis ut felis consequat venenatis. Donec in aliquam tellus, vel euismod lectus. Fusce tincidunt vestibulum nibh a maximus. Nullam maximus sodales ante, ac fringilla ipsum cursus porta. Nunc sed mi mi. Aliquam ultricies aliquet ex, sed ultrices diam placerat eget. <br /><br /> Cras pellentesque dolor et felis blandit iaculis. Nulla blandit in nunc vitae mattis. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse at nulla nec sapien porttitor porta lobortis eu purus. Ut mattis neque porttitor turpis euismod, ut ullamcorper metus ornare. Suspendisse potenti. Pellentesque eu elit in erat hendrerit egestas. Fusce commodo tempus massa, a elementum eros porta et. Duis at laoreet risus, sit amet semper urna. Integer faucibus mauris ut euismod blandit. <br /><br /> Vestibulum suscipit sodales arcu, in accumsan risus rhoncus sed. Nam porttitor lacus vitae purus lacinia, quis bibendum ante tempus. Vivamus eu mauris ut leo gravida ornare. Cras eu ligula cursus, aliquet enim eu, gravida quam. Proin scelerisque eu augue ac hendrerit. In sit amet erat et nunc vehicula bibendum non id mauris. Sed vel tristique diam, vitae feugiat eros. Vestibulum laoreet lorem est, at porttitor turpis scelerisque at. <br /><br /> Nulla ante elit, maximus eu nisl non, malesuada suscipit mauris. Curabitur tristique vel eros vel tincidunt. Proin interdum placerat metus, vitae tempor tellus tempor pulvinar. Aliquam luctus nunc nisi, non auctor lectus aliquet ac. Cras non metus in urna semper molestie eget eget mauris. Morbi mollis ac urna viverra consectetur. Vivamus cursus tellus id leo fringilla, non aliquet leo sagittis. Vivamus malesuada euismod convallis. Quisque vehicula, ante sed consectetur aliquet, lacus enim cursus neque, in feugiat mi urna a justo. Nam molestie est sit amet augue sagittis, nec hendrerit leo fringilla. Phasellus id cursus nisi. Maecenas vehicula non erat sit amet varius. Nulla et mauris vulputate, tempus purus eu, rutrum orci. Nulla egestas orci mauris, sed tincidunt sem blandit eget. Cras sed magna nec est scelerisque ullamcorper eu eget odio. <br /><br /> Aliquam ornare, tellus id porta tempus, enim massa rutrum enim, ut venenatis nibh lectus in nunc. Praesent ut lacus ultricies, laoreet quam a, posuere justo. Sed nisl odio, consequat at tincidunt a, efficitur eget quam. Nam commodo ex sed finibus iaculis. Ut luctus, nisl eu malesuada euismod, massa metus vulputate nunc, convallis finibus purus sapien non magna. Nunc blandit, sem vel ultrices tristique, lectus tellus facilisis turpis, scelerisque auctor turpis enim eu lorem. Sed nec est consectetur, ultrices felis vitae, tempus erat. Morbi ante elit, vehicula et tortor non, vestibulum pharetra libero. Integer a ex quis neque viverra vestibulum. Donec rhoncus odio vitae sapien rutrum, quis maximus leo feugiat. Vivamus risus justo, ultrices vitae quam ac, gravida auctor dui. Nullam at ultricies massa. Vivamus eu tellus luctus, suscipit quam non, eleifend nisl. <br /><br /> Vivamus placerat ipsum in justo eleifend, non bibendum turpis auctor. Sed tristique augue ipsum, eu viverra libero scelerisque quis. Aliquam erat volutpat. Duis at est molestie, facilisis enim ac, ultricies enim. Integer et ipsum maximus, pellentesque nibh et, lacinia elit. Vivamus faucibus, justo et interdum scelerisque, erat nisi elementum felis, vitae interdum nisl dui non velit. Quisque facilisis quis dolor et feugiat. Praesent ultricies vestibulum lectus, at vehicula massa commodo pharetra. Sed laoreet enim sed urna bibendum sodales. Sed enim odio, placerat at felis et, ultrices ultricies libero. Curabitur scelerisque id mi at tincidunt. Nullam commodo justo aliquam diam consequat, sed finibus lorem porttitor. <br /><br /> Phasellus bibendum diam turpis, et egestas urna fringilla nec. Morbi porttitor erat vitae justo tincidunt, ac dignissim ligula aliquam. Mauris nisl lacus, placerat sit amet ex et, accumsan interdum tortor. Aenean justo ex, posuere non eleifend sed, blandit a mauris. Sed fermentum in quam eget consequat. Phasellus eget aliquam sapien. Vivamus ac ultricies mauris. Aenean eu pharetra sem, convallis vehicula sapien. Cras lobortis at est fermentum pretium. Etiam eget lacus eget elit tincidunt ultrices. Suspendisse ac nulla et urna consectetur volutpat eu a orci. Aenean ornare mauris a libero semper rhoncus. Ut eleifend mauris quis lorem efficitur sagittis. Proin volutpat lectus ipsum, quis molestie tellus aliquam sit amet. <br /><br /> Vivamus placerat ipsum in justo eleifend, non bibendum turpis auctor. Sed tristique augue ipsum, eu viverra libero scelerisque quis. Aliquam erat volutpat. Duis at est molestie, facilisis enim ac, ultricies enim. Integer et ipsum maximus, pellentesque nibh et, lacinia elit. Vivamus faucibus, justo et interdum scelerisque, erat nisi elementum felis, vitae interdum nisl dui non velit. Quisque facilisis quis dolor et feugiat. Praesent ultricies vestibulum lectus, at vehicula massa commodo pharetra. Sed laoreet enim sed urna bibendum sodales. Sed enim odio, placerat at felis et, ultrices ultricies libero. Curabitur scelerisque id mi at tincidunt. Nullam commodo justo aliquam diam consequat, sed finibus lorem porttitor. <br /><br /> Phasellus bibendum diam turpis, et egestas urna fringilla nec. Morbi porttitor erat vitae justo tincidunt, ac dignissim ligula aliquam. Mauris nisl lacus, placerat sit amet ex et, accumsan interdum tortor. Aenean justo ex, posuere non eleifend sed, blandit a mauris. Sed fermentum in quam eget consequat. Phasellus eget aliquam sapien. Vivamus ac ultricies mauris. Aenean eu pharetra sem, convallis vehicula sapien. Cras lobortis at est fermentum pretium. Etiam eget lacus eget elit tincidunt ultrices. Suspendisse ac nulla et urna consectetur volutpat eu a orci. Aenean ornare mauris a libero semper rhoncus. Ut eleifend mauris quis lorem efficitur sagittis. Proin volutpat lectus ipsum, quis molestie tellus aliquam sit amet. <br /><br /> Phasellus bibendum diam turpis, et egestas urna fringilla nec. Morbi porttitor erat vitae justo tincidunt, ac dignissim ligula aliquam. Mauris nisl lacus, placerat sit amet ex et, accumsan interdum tortor. Aenean justo ex, posuere non eleifend sed, blandit a mauris. Sed fermentum in quam eget consequat. Phasellus eget aliquam sapien. Vivamus ac ultricies mauris. Aenean eu pharetra sem, convallis vehicula sapien. Cras lobortis at est fermentum pretium. Etiam eget lacus eget elit tincidunt ultrices. Suspendisse ac nulla et urna consectetur volutpat eu a orci. Aenean ornare mauris a libero semper rhoncus. Ut eleifend mauris quis lorem efficitur sagittis. Proin volutpat lectus ipsum, quis molestie tellus aliquam sit amet. <div class="page-break"></div> <!-- This forces a page break --> </div> <div class="footer" id="footer" style="height:50px; width:100%;text-align:center"> footer name info<br />footer address info </div> </body> </html>
  12. Hi, For the life of me I can't get this to work. I've tried 20 different solutions from S.O., had ChatGTP4 modify the code, etc. Hopefully, someone on this forum will have run into this and made it work... I have a simple html page that host 2 datapages, one for content and the other for the footer. The content datapage is a tabular report and the number of records varies from 1 to more than a 100, so the length on a page is dynamic and can run into multiple pages on print, and anywhere in the page: top, somewhere in the middle, bottom. The footer datapage is a details datapage with simple user name/address info that's usually 1-3 lines of text. I don't believe the datapages are the problem here as I've tried removing them and just putting text for content--with the same result. If I stick/anchor the footer to the bottom of the last page, for printing, I keep getting an extra blank page in print preview. Altering the CSS to remove the extra blank page "un-fixes" the footer from the bottom of the last page. I need both, in print preview: the footer to stick to the bottom of the last page only, and there to be no extra blank page after the footer. Does anyone have a solution to this? Here's the code I'm using that does stick the header at the bottom of the last page but has an empty blank page after it: <html> <style type="text/css" media="print"> @media print { body { position: relative; } .footer { position: absolute; bottom: 0; left: 0; width: 100%; height: 50px; } .content { margin-bottom: 60px; /* This ensures there is space for the footer */ } .page-break { display: block; page-break-before: always; } } </style> <body> <div class="content"> <script type="text/javascript" src="https://c0afw773.caspio.com/dp/c21040009f7f41d6de1a40ebaf0b/emb"></script> <div class="page-break"></div> <!-- This forces a page break --> </div> <div class="footer" id="footer" style="height:50px; width:100%"> <script type="text/javascript" src="https://c0afw773.caspio.com/scripts/embed.js"></script><script type="text/javascript">try{f_cbload(true, "c0afw773.caspio.com", "c2104000b2ca60c9339141d0a10d");}catch(v_e){;}</script> </div> </body> </html>
  13. Hi @IamNatoyThatLovesYou, Thanks-- I ended up using IntroJs (https://introjs.com/), which worked out really fantastic.
  14. Hi @SushiPizza, Thanks for the tip--the problem with autocomplete (cascade or not) is the field stores a number id but the display is a text value. Autocomplete only uses one field for both value and display. None of the cascades or dropdowns actually type-to-scroll in Inline Add.
  15. Hi, I have a datapage using Inline Add with dropdown selections. Normally a dropdown will auto-scroll as the user types in letters, i.e.. as they type 's' the dropdown scrolls to the first 's' and they can see all the other records that begin with 's'. And if they keep typing it further narrows the scroll. Here though it doesn't scroll at all and simply puts the first record with 's' (for this example) in the selection box but doesn't scroll the list. If the user doesn't want the first record they have to manually scroll all the way down. When there's a lot of records this can be very tedious and Caspio says this is expected behavior. Does anyone know of a javascript solution to enable type-to-scroll in Inline Add?
  16. Hi @autonumber- thanks for the tip but these fields need to be open to user input so I can't use a calculated field. I just want to autofill with a value and then if the user wants to override it they can. Hi @SushiPizza- thanks for posting--I'd missed the InlineEdit and InlineAdd syntax. I ended up piecing together some code that works for both the inline add and inline edit part, in case anyone else needs it--this goes in the footer of the Results page: var nameOfField = "InlineAddMarkUp"; var nameOfField2 = "InlineAddCost"; var nameOfField3 = "InlineAddPriceMarkedUp"; var nameOfField4 = "InlineEditMarkUp"; var nameOfField5 = "InlineEditCost"; var nameOfField6 = "InlineEditPriceMarkedUp"; document.addEventListener('DOMSubtreeModified', function(){ document.getElementsByName(nameOfField)[0].addEventListener('change', function(){ var v_cost = document.getElementsByName(nameOfField2)[0].value; var v_markup = document.getElementsByName(nameOfField)[0].value; var v_cprice = (Number(v_cost) * Number(v_markup)) + Number(v_cost); document.getElementsByName(nameOfField3)[0].value = v_cprice.toFixed(2); }); document.getElementsByName(nameOfField4)[0].addEventListener('change', function(){ var v_cost2 = document.getElementsByName(nameOfField5)[0].value; var v_markup2 = document.getElementsByName(nameOfField4)[0].value; var v_cprice2 = (Number(v_cost2) * Number(v_markup2)) + Number(v_cost2); document.getElementsByName(nameOfField6)[0].value = v_cprice2.toFixed(2); }); });
  17. Hi, Does anyone know how to use javascript to run calculations on a tabular report's results page, in inline insert and inline edit? I have code I run in the Details view to make a calculation when the user updates a field: document.addEventListener('DataPageReady', function (event) { var newmarkup = document.querySelector('[name*=EditRecordMarkUp]'); newmarkup.onchange = function() { var v_cost = document.getElementById("EditRecordCost").value; var v_markup = document.getElementById("EditRecordMarkUp").value; if(!isNaN(v_cost) && !isNaN(v_markup) && v_cost !=0 ){ var v_cprice = (Number(v_cost) * Number(v_markup)) + Number(v_cost); document.getElementById("EditRecordPriceMarkedUp").value = v_cprice.toFixed(2); } } }); This works great in the Details page, autofilling the field "PriceMarkedUp" when the user has entered a "Cost" and updates "Markup" value. The calculation is done for them. I also need to do this on the Tabular Results page, in Inline Insert for a new record and also Inline Edit for an update on the fly. Is it possible to do this? I guess you'd change "EditRecordMarkup" to "InlineEditMarkup" or "InlineInsertMarkup" but that doesn't seem to do it. Any suggestions would be great!
  18. Hi @kpcollier, One odd thing I can't figure out, though, is today (9/1/2023) when the Search form is opened I get the correct first date for the week of 8/27/2023 but the "last" date fills as 8/2/2023 instead of 9/2/2023. Yesterday, on 8/31 it did fill the last date as 9/2/2023. So it seems that the new month hangs up the "last" date somehow. Any idea how to fix it?
  19. @kpcollier, This is a great solution, as mine above wasn't always reliable. I just tweaked the date format at the end so the value is mm/dd/yyyy and can be used in a Search field (in this case starting Sunday and ending on Saturday): const today = new Date(); const first = today.getDate() - today.getDay(); const last = first + 6; const firstDay = new Date(today.setDate(first)); console.log(firstDay); const lastDay = new Date(today.setDate(last)); console.log(lastDay); var dayF = document.querySelector("[id*='Value3_2']"); var dayL = document.querySelector("[id*='Value3_3']"); dayF.value = firstDay.toLocaleDateString('en-US'); dayL.value = lastDay.toLocaleDateString('en-US');
  20. @futurist, Hey this is great--thanks for posting it. I'm looking forward to seeing where I can implement this as it does look a lot more modern. That's one thing about Caspio's datapages, they look REALLY dated now. I wish they'd update the Styles so us users don't have to spend so much time modifying just to make an app look current.
  21. Hi @DaveS, I ran into something similar and below is part of the solution, which I think is what you're looking for: This code in the header will show the Search Fields in mobile regardless of responsive settings: @media only screen and (min-width: 320px) { section[class^="cbFormSection"][class*="cbSearchSpa"] div{ display:block; } } @media only screen and (max-width: 576px) { section[class^="cbFormSection"] input[type=submit]{ width: 50% !important; } .cbSearchButtonContainer { display:none !important; } } I put in the .cbSearchButtonContainer part so you don't have 2 search buttons showing in mobile. You can change it for just the Search button instead of the container but I use the container class because of other things going on. Hope this is what you're looking for and helps--
  22. Hi @DaveS, Not sure if this is what you're needing, but the IF code you can run, about if there are records or not, can just have code to disable the button if there are no records--just use something like (using v_records as the variable for your record count). if (v_records == null){ document.getElementById("myBtn").disabled = true; } Sorry if this is off the mark, I may be misunderstanding what you're trying to do.
  23. SOLVED: If anyone needs the same solution, here's a scenario that works: In the Search form, when the user makes a selection from a search field, send a value to a Virtual Field. For example, if my user searches via Article I send the value "article" to Virtual 1. If the user searches via Workflow I send "workflow" to Virtual 1. (before submitting). 2. In Virtual 1 , On Exit send the value as a parameter. In this example, I use [@type]. 3. In the Results use a calculated field to get the parameter. In this example calculated field 1 would be '[@type]'. 4. In another calculated field use CASE/WHEN to grab values from different fields, depending on the Calcfield:1 value. In this example Calculated field 2 would be CASE WHEN [@calcfield:1] = "article" THEN [@field:Article_Order] WHEN [@calcfield:1] = "workflow" THEN [@field:Workflow_Order] END 5. Make sure to hide Virtual 1 in the Search form, and both calculated fields in the results. 6. In the Results Options section use Calculated Field 2 for the sole Order By field. This way, depending on which field the user selects to search by, the results will be ordered by the relevant field.
  24. Hi, Is it possible to change the field that's used for a simple sort order, depending on the Search field used, in a tabular/list datapage? I have two Search fields: "Article" and "Workflow" that bring up results. When the user Searches by "Article" the results need to order by field "Article_Order". When the user Searches by "Workflow" it needs to filter by field "Workflow_Order". The user will never Search by both at the same time. I need to do this programmatically so the user doesn't have to use the dropdown or column label sort as it would be confusing to them. I also hate to have to have 2 separate datapages just to deal with the different sort scenario. I imagine the first, easiest part is to remove any ordering from Results Options. But then, how do you put in OrderBy for the results, in either javascript or some kind of css?
  25. Hi, Does anyone have experience with creating onboarding tools within datapages? Things like info-bubbles, hotspots, checklists, etc., to help new users of an app? I need to be able to do things like this company offers (https://userguiding.com/) but within Caspio datapages, so messages can be anchored to specific fields/labels and locations. I've done a lot of video tutorials but have found people's attention span doesn't extend more than a few seconds, so I need to get pointed instructions/explanations into the workflow somehow. Any advice would be greatly appreciated!
×
×
  • Create New...