Forum Discussion
MarkShnier__You
Qrew Legend
5 years agoThere may be Syntax which exists to do multiple API calls and refresh the page, but if so, the syntax is brutally confusing.
This Syntax is simpler to next successive calls but has the disadvantage that the last step needs to be to land the user on a record or a report, meaning that the same button cannot be used on a record and a random report.
$URLONE
& "&rdr=" & URLEncode($URLTWO)
& URLEncode("&rdr=" & URLEncode($URLTHREE))
& URLEncode(URLEncode("&rdr=" & URLEncode($URLFOUR)))
& URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($URLFIVE))))
& URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($URLSIX)))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($URLSEVEN))))))
So in you case you need three slices off that salami
var text URLONE = URLRoot() & "db/" & "App2ID" & "?act=API_EditRecord&rid=" & [App2Record ID]
& "&_fid_994=" & Now()
& "&_fid_992=Note from " & UserToName(User())
& "&apptoken=xxxxxxxxxxxxxxx";
var text URLTWO = URLRoot() & "db/" & "App1ID" & "?act=API_EditRecord&rid=" & [App2Record ID]
do something else
& "&apptoken=xxxxxxxxxxxxxxx";
var text URLTHREE = URLRoot(0 & "db/" & dbid() & "?a=dr&rid=" & [Record ID#];
$URLONE
& "&rdr=" & URLEncode($URLTWO)
& URLEncode("&rdr=" & URLEncode($URLTHREE))
The Product Managers at Quick Base are aware that doing all this stuff is not really "no code low code" and there are plans on the Product Roadmap in the medium term to allow us to execute APIs, hopefully successive APIs, and refresh the screen without the use of javascript. The don't like us using Javascript as its a security loophole, but they also realize they need ot provide an alternative.
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------
This Syntax is simpler to next successive calls but has the disadvantage that the last step needs to be to land the user on a record or a report, meaning that the same button cannot be used on a record and a random report.
$URLONE
& "&rdr=" & URLEncode($URLTWO)
& URLEncode("&rdr=" & URLEncode($URLTHREE))
& URLEncode(URLEncode("&rdr=" & URLEncode($URLFOUR)))
& URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($URLFIVE))))
& URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($URLSIX)))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($URLSEVEN))))))
So in you case you need three slices off that salami
var text URLONE = URLRoot() & "db/" & "App2ID" & "?act=API_EditRecord&rid=" & [App2Record ID]
& "&_fid_994=" & Now()
& "&_fid_992=Note from " & UserToName(User())
& "&apptoken=xxxxxxxxxxxxxxx";
var text URLTWO = URLRoot() & "db/" & "App1ID" & "?act=API_EditRecord&rid=" & [App2Record ID]
do something else
& "&apptoken=xxxxxxxxxxxxxxx";
var text URLTHREE = URLRoot(0 & "db/" & dbid() & "?a=dr&rid=" & [Record ID#];
$URLONE
& "&rdr=" & URLEncode($URLTWO)
& URLEncode("&rdr=" & URLEncode($URLTHREE))
The Product Managers at Quick Base are aware that doing all this stuff is not really "no code low code" and there are plans on the Product Roadmap in the medium term to allow us to execute APIs, hopefully successive APIs, and refresh the screen without the use of javascript. The don't like us using Javascript as its a security loophole, but they also realize they need ot provide an alternative.
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------
ChristineWhite
5 years agoQrew Assistant Captain
Thank you, I tried updating my button to the following. URLGOLD worked but not URLULH. Did I add to the javascript code correctly?
var text URLGOLD = URLRoot() & "db/" & Dbid() & "?act=API_EditRecord&rid=" & [Project ID#] &
"&_fid_1778=" & URLEncode(Now()) &
"&_fid_1779=" & ToText(User()) &
"&apptoken=xxxxxxxxxxxxxxx";
var text URLULH=URLRoot() & "db/" & "ULHAPPID" & "?act=API_EditRecord&rid=" & [VZULH App Record ID]
& "&_fid_994=" & Now()
& "&_fid_992=" & Now() & " IRM Ready for Review per " & UserToName(User())
& "&apptoken=xxxxxxxxxxxxxxxxxx";
var text URLTHREE = URLRoot() & "db/" & Dbid() & "?a=dr&rid=" & [Project ID#];
"javascript:" &
"$.get('" &
$URLGOLD
& "&rdr=" & URLEncode($URLULH)
& URLEncode("&rdr=" & URLEncode($URLTHREE))&
"',function(){" &
"location.reload();"&
"});" &
"void(0);"
------------------------------
Christine White
------------------------------
var text URLGOLD = URLRoot() & "db/" & Dbid() & "?act=API_EditRecord&rid=" & [Project ID#] &
"&_fid_1778=" & URLEncode(Now()) &
"&_fid_1779=" & ToText(User()) &
"&apptoken=xxxxxxxxxxxxxxx";
var text URLULH=URLRoot() & "db/" & "ULHAPPID" & "?act=API_EditRecord&rid=" & [VZULH App Record ID]
& "&_fid_994=" & Now()
& "&_fid_992=" & Now() & " IRM Ready for Review per " & UserToName(User())
& "&apptoken=xxxxxxxxxxxxxxxxxx";
var text URLTHREE = URLRoot() & "db/" & Dbid() & "?a=dr&rid=" & [Project ID#];
"javascript:" &
"$.get('" &
$URLGOLD
& "&rdr=" & URLEncode($URLULH)
& URLEncode("&rdr=" & URLEncode($URLTHREE))&
"',function(){" &
"location.reload();"&
"});" &
"void(0);"
------------------------------
Christine White
------------------------------
- MarkShnier__You5 years ago
Qrew Legend
No, that was my point. You cannot use the javascript refresh method with multiple API calls. or, at least if you can, the syntax is brutal.
var text URLGOLD = URLRoot() & "db/" & Dbid() & "?act=API_EditRecord&rid=" & [Project ID#] &
"&_fid_1778=" & URLEncode(Now()) &
"&_fid_1779=" & ToText(User()) &
"&apptoken=xxxxxxxxxxxxxxx";
var text URLULH=URLRoot() & "db/" & "ULHAPPID" & "?act=API_EditRecord&rid=" & [VZULH App Record ID]
& "&_fid_994=" & Now()
& "&_fid_992=" & Now() & " IRM Ready for Review per " & UserToName(User())
& "&apptoken=xxxxxxxxxxxxxxxxxx";
var text URLTHREE = URLRoot() & "db/" & Dbid() & "?a=dr&rid=" & [Project ID#];
$URLGOLD
& "&rdr=" & URLEncode($URLULH)
& URLEncode("&rdr=" & URLEncode($URLTHREE))
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------- ChristineWhite5 years agoQrew Assistant CaptainGot it. Thanks so much this worked. So what you were also saying is that this button will not work in reports (like a javascript version would) Correct?
------------------------------
Christine White
------------------------------- MarkShnier__You5 years ago
Qrew Legend
right, so the button will "work" except it will land the user on the record. but the user probably expects to land back on the report. So it means that you need to COPY the button and change the URLTHREE to land on a report. So if you need the button on three reports then (yuck), three version of the button. So, not rocket science to do, just annoying to have to do)
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------