Jump to content

Search the Community

Showing results for tags 'autosubmit'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Caspio Bridge
    • Caspio Apps for Ukraine
    • General Questions
    • Caspio JavaScript Solutions
    • Tables, Views and Relationships
    • Import/Export and DataHub
    • DataPages
    • Deployment
    • Security, Authentications, Roles, SAML
    • Styles and Localizations
    • Parameters
    • API and Integration
    • Calculations and aggregations
    • User JavaScript and CSS Discussions

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


MSN


Website URL


ICQ


Yahoo


Skype


Location


Interests

Found 5 results

  1. Hello, I'm trying to autosubmit and redirect, but everything I've tried fails to go to the next page. It either doesn't submit at all or repeatedly submits without redirecting. Background I've reviewed several threads on automatic submission. The most comprehensive seemed to be this one, but it is over 10 years old, and uses functionality no longer supported (window.onload). A few facts: Single Record Update page Embedded (we're using Webflow, though I expect that is not important) Upon submission I need to re-direct to another page (location specified in an app parameter) The code I'm currently using is from this 2014 post and is below. <script type="text/javascript"> document.addEventListener('DataPageReady', function (event) { const error = document.querySelector('div[data-cb-name="HeaderErrorMsg"]'); if(!error){ if(document.getElementById("caspioform")) { document.getElementById("caspioform").style.display = 'none'; setTimeout('document.forms["caspioform"].submit()',1000); } } }); </script> In addition to playing with the Javascript, I've tried each version of the JS with 2 destination approaches: Navigate to a new page (with the page specified) Display a message, with the script below to do the redirection <script> setTimeout(function () { window.location.href = "[@app:xxxxx]"; }, 2000); Check your email inbox </script> Would be very appreciative of any suggestions!
  2. Hi there, I am using the standard autosubmit script to send users to one form using parameters to auto fill it and autosubmit it and then on to another form. However some users get stuck in a loop if a field in the first autosubmit form are already in the table, and they never get to the second form and don't see the error message. Is there a way to write into this script "if field already exists in table [users] DO NOT autosubmit, instead show an error message? <script type="text/javascript"> if(document.getElementById("caspioform")) { document.getElementById("caspioform").style.display = 'none'; setTimeout('document.forms["caspioform"].submit()',1000); } </script> Many thanks Nikki
  3. We have a requirement for our Users to be able to update v quickly a large number of records within a tabular type report. The Bulk Edit/Update on its own wont work for us as we need to - when updating each of the records - to concatenate two Notes fields together along with a system date within each record and update another field. We can do this quite easily with JS in aa single Details Page (simple JS concatenating the two different notes values and adding today's date). However this approach does not seem to work on the Bulk Edit/Update - as whilst we can change a common field value across multiple records we cant get JS to individually do a concatenation in each of the records involved. Am really interested in any ideas for this. Our latest thinking - please comment - is to use a Tabular report of searched records to display in std tabular form to the User. But to have an HTML block at the end that has a URL link they can click. This would open some kind of hidden web window/tab containing a Details record that we can apply the JS to (as advised above) for concatenating the two Notes field values and the date within each record. We have not quite got this to work and I would be really interested in views from this Forum. A key stumbling block is to arrange for a Parameter value that can be selected once - whilst at the Tabular report - and then reused/retained as the User works his/her way down the list by clinking on the link quickly opening/closing a Details form (using Auto Submit?). This parameter value we use to update a field with the records status. It and the values of the Notes fields that we concatenate and then update another field and really the record changes we are trying to accomplish. We have tried using a second datapage with a dropdown of the values that would hold a parameter value to pass over. However it loses its value after the first click. We were wondering if we could have somekind of dropbox field that we could set once and which would then keep its parameter value held whilst the User was clicking the html link block on the Tabular report and then activating the hidden web window/tab with the Details record. Any ideas from you experts out there :-)
  4. I have a Single Record Update data page, whit a autosubmit. Depending on the value I want the destination after record update to a specific page. Something like this. <script> var machtiging = "[@authfield:GEBRUIKERS_Machtiging]"; if(machtiging=="Yes") if(document.getElementById("caspioform")) { document.getElementById("caspioform").style.display = 'none'; setTimeout('document.forms["caspioform"].submit()',1000); window.location="[@app:logout]"; } else if(document.getElementById("caspioform")) { document.getElementById("caspioform").style.display = 'none'; setTimeout('document.forms["caspioform"].submit()',1000); } window.location="[@app:horseplanner_home]"; } </script> This is not good ,i now. but for the idea. does anyone have an idea
  5. Hello All! I am building a routine to delete a "Lead" that is organized into many normalized tables. tblLead -tblPerson -tblPhone -tblEmail -tblAddress -tblVehicle -tblPolAuto -tblPolHome -tblNote -tblActionLog -tblLinkDupes Each child table uses LeadID as a Foreign Key to relate to tblLead. Using SQL deleting these records would be an easy feat... (and I may end up doing this every night after my scheduled task export backup, but that is far from optimal) DELETE FROM tblPerson WHERE LeadID=x; DELETE FROM tblPhone WHERE LeadID=x; etc. In Caspio I cannot think of a fast way to do this. My anticipated approach is to cycle through an auto-submitted and confimation disabled data page for every table, but what is going to happen when the child table has more than one record where LeadID=x. Has anybody dealt with this?
×
×
  • Create New...