-
Search Results
-
Hi Alexander –
Have encountered an “unexpected” sharepoint error when trying to us addItem in a js on NewForm that you helped me with 2 yrs ago.
Im trying to capture a bunch of boolean / checkboxes, and several lookup fields on newform – and use addItem to add the data to the list, the pass the ID of the newley created list item to the Edit for for further processing.
If the code takes the path where (p==’C’) – all works fine.
If the code takes the path where (p==’N’) – sharepoint complains with the x08020005ive used console to verify that all of the getFieldValues are retruning what is expected – so im thinking i must have done something silly / incorrect when adding the field values to the data. array
Any guidance would be appreciated!!
Here is the code:
function saveAndRedir(){
var ok = spjs.dffs.check_Mandatory([“Title”]), data = {}, newItem, p = getFieldValue(“IsCross”), url;
var parm = “&”+location.search.substring(1);
if(ok){
data.Title = getFieldValue(“Title”);
data.ContentTypeId = “0x0100B025F82EDB149249B2600F0619316DAC”;
if (p==”C”) {
data.ContentTypeId = “0x0100CEF026DC41DEB74C9A05C6AE6E1B7E1E005273FFB34EEBDF4B9AB96EAB91662862″;
}
if (p==”N”) {
/* next 4 ifs are for checkboxes
if (getFieldValue(“Transport_x0020_Work”)) {
data.Transport_x0020_Work = 1;
}
if (getFieldValue(“Transformation_x0020_Work”)) {
data.Transformation_x0020_Work = 1;
}
if (getFieldValue(“New_x0020_Use_x0020__x002f__x002”)) {
data.New_x0020_Use_x0020__x002f__x002 = 1;
}
if (getFieldValue(“Maintain”)) {
data.Maintain = 1;
}/* next 4 fields are lookup fields
data.Source_x0020_Entity = getFieldValue(“Source_x0020_Entity”);
data.Source_x0020_Residency = getFieldValue(“Source_x0020_Residency”);
data.Target_x0020_Entity = getFieldValue(“Target_x0020_Entity”);
data.Target_x0020_Residency = getFieldValue(“Target_x0020_Residency”);/* Next 5 ifs are for checkboxes
if (getFieldValue(“Border_x0020_Crossing”)) {
data.Border_x0020_Crossing = 1;
}
if (getFieldValue(“Req_x0020_Has_x0020_PII_x002f_MN”)) {
data.Req_x0020_Has_x0020_PII_x002f_MN = 1;
}
if (getFieldValue(“Req_x0020_is_x0020_MNPI”)) {
data.Req_x0020_is_x0020_MNPI = 1;
}
if (getFieldValue(“Req_x0020_Reg_x0020_Requirement”)) {
data.Req_x0020_Reg_x0020_Requirement = 1;
}
if (getFieldValue(“Req_x0020__x002d__x0020_External”)) {
data.Req_x0020__x002d__x0020_External = 1;
}data.Req_x0020_Domain = getFieldValue(“Req_x0020_Domain”);
data.Req_x0020_By = getFieldValue(“Req_x0020_By”);
}newItem = spjs.utility.addItem({“listName”:_spPageContextInfo.pageListId,”data”:data});
if(newItem.success){
url = “http://sp-na.ms.com/GWM/PCELD_Deliverable/eagledatagov/Lists/Request/EditForm.aspx?ID=”+newItem.id;
if(GetUrlKeyValue(“IsDlg”)===”1″){
url += “&IsDlg=1”;
}
location.href = url;
}else{
alert(newItem.errorText);
}
}
}Topic: Found a strange bug
Found a strange but with Rules
How to replicate:
-Go to DFSS and Create a “Rule” that is based on the value of a column
-Save the form
-Go back to the list settings and DELETE the column on which the rule is based
-open DFFS and click the “Rules” linkThe Rules link functionality breaks and the browser closes DFFS and returns to the list
Thought I should report it…
I have a list that is customized with DFFS. This works fine for me, logged in as a site collection admin.
For another user, the form loads without any DFFS features, other than the “Enhanced by DFFS” menu at the bottom. There are no errors in the dev console or network trace. We’ve tested with both Edge and Chrome.
DFFS is working for the same user on a list in a separate subsite in the same site collection.
Any ideas what would cause this?
I have a form which has two multiline text fields where it is important for the users to see the previous entries. The fields are set up with ‘Append Changes to Existing Text,’ and the entries seem to be captured (in my tests I can see date stamps listed below the text boxes), but there seems to be no way to display the text.
If there’s no solution to this, I can try writing the text to another field, but I’d like to avoid that if I can.
Modern DFFS v1.0.11.0
Topic: Direct link to forms?
Hello,
In classic DFFS I was able to link directly to the forms using the NewForm.aspx and DispForm.aspx pages. I have been using those links to pull up the forms for items in a side panel in a custom web part. I tried linking to those pages for a list using modern DFFS, but the forms are the default modern SP forms. I understand the reason for this, but I was wondering if there is any way to link directly to the DFFS forms. I know I can link to the form by adding
?DFFSID=1&DFFSForm=disp
to the end of the URL for the list (specifying the item by its ID), but this has unexpected behavior when opening in a side panel. I end up with the toolbar of the list peeking over the panel for the form (so I have a panel with a panel inside of it, but it does not hide the toolbar of the list in the background).
In addition, when the DispForm.aspx is loaded directly, I can tie in to the cancel or save events and close the panel. This does not work with what I have found so far for the modern DFFS forms. I realize this is not necessarily a common case, but was just wondering if there was a way to open the form for an item directly without loading the list first.
I create List A and add a column “Entity”. I add list items and enter a string value into the “Entity” column that contains a hyphen (e.g. “Solar-Planet” or “Solar-Star”)
I create List B and add a Lookup colum “Entity” that looks up List A and Column Entity.
I create a DFFS New and Edit form for List B.
I create a new list item in List B. It creates OK
I EDIT the list item in List B and the displayed value of the lookup has removed all the characters before the hyphen. (for example if I selected “Solar-Planet” it now only shows the lookup string “Planet”. If I SAVE this form then it corrupts the lookup./Marcus
A site I partially own recently migrated from SharePoint 2013 on-prem to SharePoint 2019 on-prem. All DFFS and custom JS continued to work perfectly post-migration. The only exception seems to be the following function when used on a multivalue lookup field:
setFieldValue(‘myMultivalueLookup’,”)
I have a multivalue lookup to a list with 4k+ records. While in 2013, using the above function would execute almost immediately. Now in the 2019 environment, it takes a large amount of time to execute: 30-50 seconds for my average user. I updated DFFS to the most recent version, but the issue persists. I also tried implementing a rule to clear the field instead of using custom JS, but the execution time was the same.
I also looked at a different means of clearing multivalue lookup fields from a different blog. Despite executing quickly, that blog’s solution doesn’t behave well as it tends to modify other lookup fields in addition to the target. https://derekgusoff.wordpress.com/2013/06/06/setting-multi-valued-lookups-in-forms-with-jquery/
Any ideas or suggestions to unravel this problem?
Topic: sharepoint online
Hi Alex,
Are you familiar with the JSON formatting for list and column views? If you are, there seems to be a SharePoint limitation: when you apply JSON formatting to a rich text multiple-line field, it renders the HTML and not the rich text. Do you know how to force the HTML to display back to rich text? What I am trying to achieve is a way to either expand the row to display all the rich text or convert plain text with HTML. Either result should show the row with more height and rich text. I am just looking for a direction.
If I place the list view on a web part page, I can use your Modern CEWP and add styles. But the user must navigate from the list to the web part page, which I find a bit clumsy.
Any suggestions would be greatly appreciated.
Larry