Forum Replies Created
-
AuthorPosts
-
It seems that adding the redirect line at the END of Custom JS did the trick.
function dffs_PreSaveAction(){ if(!confirm("You are about to submit an incident report.\nWhen this report is submitted, an approval process is triggered. Please make sure that:\n\n- All email addresses are correct\n- All other information is correct")){ return true; } } jQuery("input[id$='_diidIOSaveItem']").val("Submit Incident Report"); spjs.dffs.redirect("https://xxx/Pages/IAR.aspx",false);
In relation to new form links, I wasn’t using the additional ‘source=’ url, but the above seems to have fixed my problem.
Thanks Alexander.
- This reply was modified 5 years, 8 months ago by Maciek Grischke.
I think I figured it out. Other rules were taking over and I changed their “Validate on” trigger and it seems to be doing what I want.
I have 150 fields/elements and some 25 rules. It was not easy to get it sorted. Hopefully this is it.
I got it sorted via column validation using the following formula:
=ISNUMBER(VALUE(TRIM(CLEAN([Column Name]))))
but the column needs to be in a Text format, not a number format. I then use Flow to convert it back to a proper number.
I wonder if there’s a way of using DFFS. No worries if not.
Yes, the scrolling was still happening without the DFFS.
I currently have this Custom JS:
function dffs_PreSaveAction(){ if(!confirm("You are about to submit an incident report.\n\nWhen this report is submitted, an approval process is triggered. Please make sure that:\n\n- All email addresses are correct\n- All other information is correct")){ return false; } } jQuery("input[id$='_diidIOSaveItem']").val("Submit Changes"); jQuery("input[id$='_diidIOGoBack']").val("Cancel Changes"); spjs.dffs.redirect("https://xxx.sharepoint.com/Pages/IAR.aspx",false);
What does the
return false;
do?
Your code is set to
return true;
Just checking what the difference between false and true is.
Using
.../Sites/YourSite/Lists/YourList/NewForm.aspx?Source=https://xxx/Pages/IAR.aspx
is also playing up and sometimes take the user back to the list, I did try it. Weird..
- This reply was modified 5 years, 8 months ago by Maciek Grischke.
- This reply was modified 5 years, 8 months ago by Maciek Grischke.
Hello,
I uninstalled DFFS, I even duplicated the list and started from fresh and the same thing is happening 🙁
There are over 100 fields though.
Is there anything I can try to fix this?
I mainly want to use the dialog option so that users are not redirected to the list, but to the filtered page. Unfortunately, for some reason, the below code:
spjs.dffs.redirect("https://xxx/Pages/IAR.aspx",false);
doesn’t always work and occasionally takes users back to the actual list. I need to be 100% sure that this never happens. Any reason for the above code not to apply properly every time?
- This reply was modified 5 years, 9 months ago by Maciek Grischke.
Hello,
it’s the form, when you start typing the form moves to the first field. It will go back to where I’m typing as soon as the drop-down list with names narrows the result to 3 users.
I just noticed this does not happen in Firefox, but we use Chrome on our servers.
- This reply was modified 5 years, 9 months ago by Maciek Grischke.
Alexander, they are set to both.
For now, I’ve added a rule to clear the first two options, so the user must click on them again to trigger the other fields.
I think what I want can’t be achieved simply, but I found another way by adding an additional column.
I do have another issue. I copied the config from NewForm to EditForm, and a few first fields don’t show up until I trigger the first “choice” option:
Field 1 (Rule 1)
Option 1 or Option 2Field 2 (Rule 2)
Option 1 or Option 2Any fields here (i.e., 3-9) are not showing up until I trigger Field1/Rule1
Trigger: Field 10 (Rule 10)
Linked rules and functions
Rule1 Option1 AND Rule2 Option1Any ideas why?
Thanks Alexander, this worked great!
-
AuthorPosts