Forum Replies Created
-
AuthorPosts
-
The configuration for Modern DFFS is stored in a list in each site. The list is hidden, but you can access it on this URL:
/sites/your_site/lists/DFFSConfigurationList
If you include this list (with contents) in your package, DFFS will load the config as soon as the Modern DFFS App is installed in the App Catalog.
Alexander
January 8, 2024 at 16:16 in reply to: vLookup configuration for Add new item does not write value to child list column #37385Hi,
I have confirmed the bug and started work on it during the weekend, but was not able to finish it. I hope to get a new version out later this week.Alexander
Thanks for the clarification. I have started work on it during the weekend, but found some other issues I need to figure out. I hope to get a new version out later this week.
Alexander
This error is the one fixed in v45 – it was introduced in v37.
Alexander
Add something like this to your custom js:
var arrOfFields = ["Q1_x0020_Status", "Q2_x0020_Status"]; arrOfFields.forEach(fin => { jQuery("#dffs_" + fin + " select").on("change", function(){ triggerChangeChoiceFields(); }); }); function triggerChangeChoiceFields(){ var hasFail = false; arrOfFields.forEach(fin => { if(getFieldValue(fin) === "Fail"){ hasFail = true; } }); if(hasFail){ // Do your custom action here - for example call a rule that is set up with "Not trigger (must be triggered manually)" spjs.dffs.triggerRule(["customTrigger"]); } }
This code triggers a rule called customTrigger – set up with the trigger “No trigger (must be triggered manually)”.
Let me know how this works out.
Alexander
- This reply was modified 11 months, 3 weeks ago by Alexander Bautz. Reason: Fixed code snippet format
If you use code to hide fields in a row with side-by-side fields there is unfortunately no built in functionality to hide the “outer” row when all fields in the row have been hidden by rules.
The only way to do this is to use custom js – for example on an interval – to check if all fields have been hidden and then hide the outer row.
Alexander
Hi,
I need some clarifications: are you trying to copy from a multilookup field in the parent to a multilookup field in the child and only the first item is transferred, or are you trying to transfer values from multiple different lookup fields and only the value in the first field is transferred?Alexander
January 1, 2024 at 15:50 in reply to: Revert multiple lookup field back to default side by side #37363In DFFS this setting is found in the Misc tab > Multi lookup columns > Arrange multi lookup columns vertically.
Alexander
Hi,
I tested it and it seems to works as expected. Please note that the modern DFFS solution is a list view command set extension and only loads when the command bar is visible (edit > Show command bar).Alexander
December 18, 2023 at 19:59 in reply to: Dialogue/Pop-Up on save if user is missing a required field #37346I think there is a built in check in the browser that prevents the function to run in the form has not been modified – try changing at least one field and see if the code runs when you try to exit.
Alexander
December 18, 2023 at 19:57 in reply to: Dialogue/Pop-Up on save if user is missing a required field #37345The code to tap into the PreSaveItem function worked in my test, but you must ensure you run the originalPreSaveItem and not use “return” in the code above the call to this function.
Alexander
December 18, 2023 at 10:41 in reply to: Dialogue/Pop-Up on save if user is missing a required field #37342Sure, just add this to your custom js:
// Set this to false first var hasSaved = false; window.addEventListener("beforeunload", (event) => { if(!hasSaved){ event.preventDefault(); event.returnValue = true; } });
Now add this to the top of your dffs_PreSaveAction function:
// Set the variable to true to to disable the warning when the form is saved hasSaved = true;
Alexander
December 17, 2023 at 14:40 in reply to: Dialogue/Pop-Up on save if user is missing a required field #37340The PreSaveAction function will never run if the form has empty fields, but you can tap into the PreSaveItem function like this to run your custom code:
var originalPreSaveItem = PreSaveItem; PreSaveItem = function(){ // run custom function here // trigger original PreSaveItem originalPreSaveItem(); }
Alexander
Thanks for the feedback – I’m glad you figured it out.
Alexander
Is the problem that you try to edit the item and get a save conflict because of the workflow updating the item after the user opened it for edit?
If you are using a SharePoint Designer Workflow (not PowerAutomate FLOW) you can try the rule trigger “Workflow status” – read about it by clicking the orange question mark to the right of the trigger-select to open the contextual help.
Set this thread for an example of a custom function you can have this rule trigger: https://spjsblog.com/forums/topic/check-out-feature-triggering-workflows/#post-26487
Alexander
-
AuthorPosts