Skip to main content

I am getting the error for unsaved changes but I haven’t made any changes yet. Any ideas?


Parent XML:


<skuidpage unsavedchangeswarning="yes" personalizationmode="server" showsidebar="false" showheader="false" theme="Lightning Design" cachepage="false"> <models> <model id="CurrentUser" limit="1" query="true" createrowifnonefound="false" adapter="" type="" sobject="User" processonclient="true" doclone=""> <fields> <field id="Name"/> <field id="SmallPhotoUrl"/> </fields> <conditions> <condition type="userinfo" value="" field="Id" operator="=" enclosevalueinquotes="true" userinfotype="userid"/> </conditions> <actions/> </model> </models> <components> <grid uniqueid="sk-2ueomI-342"> <divisions> <division behavior="flex" minwidth="100px" ratio="1" verticalalign="top"> <components> <pageregion uniqueid="sk-2uempF-338"> <styles> <styleitem type="background" bgtype="none"/> </styles> </pageregion> </components> </division> </divisions> <styles> <styleitem type="background" bgtype="none"/> </styles> </grid> </components> <resources> <labels/> <javascript/> <css> <cssitem location="inline" name="hidetablefooter" cachelocation="false">.hidetablefooter .nx-list-footer { display:none; }</cssitem> </css> </resources> <styles> <styleitem type="background" bgtype="none"/> </styles> <pageregioncontents> <pageregioncontent uniqueid="__header"> <components> <skuidheader sticky="true"> <components> <grid uniqueid="sk-2uXr6L-48"> <divisions> <division behavior="fit" verticalalign="top"> <components/> </division> <division behavior="flex" verticalalign="center" ratio="1" minwidth="100px"> <components> <navigation uniqueid="sk-2ule3F-82"> <navigationitems> <navigationitem label="Home"> <actions> <action type="redirect" window="self" url="/home/home.jsp"/> </actions> </navigationitem> <navigationitem label="People"> <actions> <action type="redirect" window="self"/> </actions> <navigationitems> <navigationitem label="Accounts"> <actions> <action type="redirect" window="self" url="/001/o"/> </actions> </navigationitem> <navigationitem label="Contacts"> <actions> <action type="redirect" window="self" url="/003/o"/> </actions> </navigationitem> <navigationitem label="Leads"> <actions> <action type="redirect" window="self" url="/00Q/o"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="For Clients"> <actions> <action type="redirect" window="self"/> </actions> <navigationitems> <navigationitem label="Cases"> <actions> <action type="redirect" window="self" url="/500/o"/> </actions> </navigationitem> <navigationitem label="Engagement Plan Summaries"> <actions> <action type="redirect" window="self" url="/a29/o"/> </actions> </navigationitem> <navigationitem label="Engagement Plans"> <actions> <action type="redirect" window="self" url="/a2A/o"/> </actions> </navigationitem> <navigationitem label="Contract Change Requests"> <actions> <action type="redirect" window="self" url="/a0j/o"/> </actions> </navigationitem> <navigationitem label="Client Fact Sheet"> <actions> <action type="redirect" window="self" url="/a0i/o"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="Sales"> <actions> <action type="redirect" window="self"/> </actions> <navigationitems> <navigationitem label="Opportunities"> <actions> <action type="redirect" window="self" url="/006/o"/> </actions> </navigationitem> <navigationitem label="Dashboards"> <actions> <action type="redirect" window="self" url="/01Z/o"/> </actions> </navigationitem> <navigationitem label="Reports"> <actions> <action type="redirect" window="self" url="/00O/o"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="Marketing"> <actions> <action type="redirect" window="self"/> </actions> <navigationitems> <navigationitem label="Campaigns"> <actions> <action type="redirect" window="self" url="/701/o"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="Admin"> <actions> <action type="redirect" window="self"/> </actions> <navigationitems> <navigationitem label="Contract History"> <actions> <action type="redirect" window="self" url="/a2b/o"/> </actions> </navigationitem> <navigationitem label="Pages"> <actions> <action type="redirect" window="self" url="/a1A/o"/> </actions> </navigationitem> <navigationitem label="Page Assignments"> <actions> <action type="redirect" window="self" url="/a18/o"/> </actions> </navigationitem> <navigationitem label="Products"> <actions> <action type="redirect" window="self" url="/01t/o"/> </actions> </navigationitem> <navigationitem label="Welcome Letters"> <actions/> <navigationitems> <navigationitem label="Content"> <actions> <action type="redirect" window="self" url="/a2d/o"/> </actions> </navigationitem> <navigationitem label="Queue"> <actions> <action type="redirect" window="self" url="/a2c/o"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="Help &amp;amp; Training"> <actions> <action type="redirect" window="self" url="https://help.salesforce.com/hthome?siteLang=en_US"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="Certification"> <actions> <action type="redirect" window="self" url="https://cs12.salesforce.com/servlet/servlet.Integration?lid=01r30000001HFjX&amp;amp;ic=1"/> </actions> <navigationitems> <navigationitem label="Brainshark Learning"> <actions> <action type="redirect" window="self" url="https://na1.salesforce.com/servlet/servlet.Integration?lid=01r30000001HFjX&amp;amp;ic=1"/> </actions> </navigationitem> </navigationitems> </navigationitem> <navigationitem label="Show All Tabs"> <actions> <action type="redirect" window="self" url="/home/showAllTabs.jsp"/> </actions> </navigationitem> </navigationitems> <styles> <styleitem property="padding" value="0"/> </styles> </navigation> </components> </division> </divisions> <styles> <styleitem type="background" bgtype="color"> <styles> <styleitem property="background-color" value="white"/> </styles> </styleitem> </styles> </grid> <grid uniqueid="sk-2uYIRV-65"> <divisions> <division behavior="fit" verticalalign="center"> <components> <image source="staticresource" uniqueid="sk-2uZA6u-102" resource="SDLogo"> <styles> <styleitem type="itemsize"/> <styleitem type="border"/> </styles> </image> </components> </division> <division behavior="flex" verticalalign="center" ratio="1" minwidth="100px"> <components> <search uniqueid="sk-2ua3RC-127" soslfields="All Fields"> <objects> <object id="Account" icon="sk-icon-account-profile" displaytemplate="{{Name}}"> <fields> <field id="Name"/> </fields> <resultactions/> </object> <object id="Contact" icon="sk-icon-contact" displaytemplate="{{Name}}: {{Title}} at {{Account.Name}}"> <fields> <field id="Name"/> <field id="X3x3_Research_1x1__c"/> <field id="Account.Name"/> <field id="Title"/> </fields> </object> <object id="Opportunity" displaytemplate="{{Name}}"> <fields> <field id="Name"/> <field id="Account.Name"/> </fields> </object> <object id="Lead" displaytemplate="{{Name}}"/> <object id="Contract" displaytemplate="{{ContractNumber}}"> <fields> <field id="ContractNumber"/> </fields> </object> <object id="EngagementPlan__c" displaytemplate="{{Name}}"> <fields> <field id="Name"/> </fields> </object> <object id="Report" displaytemplate="{{Name}}"> <fields> <field id="Name"/> </fields> </object> <object id="Dashboard" displaytemplate="{{DeveloperName}}"> <fields> <field id="Title"/> <field id="DeveloperName"/> </fields> </object> </objects> <selectactions> <action type="redirect" window="self" url="/{{Id}}"/> </selectactions> <resultactions/> </search> </components> </division> <division behavior="fit" verticalalign="center"> <components> <navigation uniqueid="sk-2ubdeE-209" source="sfapps" type="dropdown"> <navigationitems/> </navigation> </components> </division> <division behavior="fit" verticalalign="center"> <components> <navigation uniqueid="sk-2ucU7o-234" source="sfusermenu" type="dropdown" label="{{$User.name}}"> <navigationitems/> </navigation> </components> </division> <division behavior="fit" verticalalign="center"> <components> <image source="url" uniqueid="sk-2ud2Ad-278" url="{{$Model.CurrentUser.data.0.SmallPhotoUrl}}"> <styles> <styleitem type="itemsize" width="custom" height="custom"> <styles> <styleitem property="width" value="30px"/> <styleitem property="height" value="30px"/> </styles> </styleitem> <styleitem type="border"/> <styleitem property="overflow" value="hidden"/> <styleitem property="border-radius" value="40px"/> <styleitem property="border" value="1px solid rgba(255,255,255,0.4)"/> </styles> <renderconditions logictype="and"/> </image> </components> </division> </divisions> <styles> <styleitem type="background" bgtype="color"> <styles> <styleitem property="background-color" value="white"/> </styles> </styleitem> </styles> </grid> </components> <styles> <styleitem type="background" bgtype="color"> <styles> <styleitem property="background-color" value="white"/> </styles> </styleitem> <styleitem type="border"/> </styles> </skuidheader> </components> </pageregioncontent> </pageregioncontents> </skuidpage> 

Child XML



    

In your child page you have two models that create new rows on page load. See below:






The new row acts like a change - which triggers the unsaved changes warning you have established for the page. You can either turn off the unsaved changes warning for the page as a whole, or uncheck the box in the advanced tab of the model that says: “Prevent users from leaving page is THIS model has unsaved changes.” This model specific override is a new feature introduced in Banzai…


Good find.  This was obviously built based off the template you guys have that was created before the AF was available.  I don’t see these models referenced anywhere except in a couple of snippets.  

I found I could delete those models and just add an action to the LineItems model to query the opportunity for fresh data.

Because of the vast improvements you guys have made in the last 2 releases, that page repository could be juiced up now (remove snippets and use AF).


We would love to do that… 


Reply