First, the question: ' Notifyscriptloadedandexecutewaitingjobs ' is undefined
Description: Invoking the Search service using the JavaScript object model throws an exception at run Sp.search.js: 0x800a1391-javascript run-time error: ' Notifyscriptloadedandexecutewaitingjobs ' not defined
Workaround: Introduce init.js <script type="text/javascript" src in the page ="/_layouts/15/init.js"></script>
Notifyscriptloadedandexecutewaitingjobs is defined in the Init.js, and the Sp.sod method is also, if "SP" appears. Sod undefined "This error, also introduced init.js can be
Second, question: Add Custom CustomAction, click on how to eject the modal form
<customaction id= "E5535f8e-b06c-4cd4-bcb2-ae51ae1fa2ec. Fixdocrca "
Registrationtype= "List"
Registrationid= "101"
location= "Commandui.ribbon"
Sequence= "10001"
title= "Custom Button"
<!--means open in a new form
hostwebdialog= "TRUE"
hostwebdialogheight= "420"
hostwebdialogwidth= "510" >
<CommandUIExtension>
<CommandUIDefinitions>
<commanduidefinition location= "Ribbon.documents.manage.controls._children" >
<button id= "Ribbon.Domuments.Manage.FixDocRCAButton"
alt= "Custom Button"
Sequence= "100"
Command= "Invoke_fixdocrcabuttonrequest"
labeltext= "Custom Button"
Templatealias= "O1"
Image32by32= "_layouts/15/images/placeholder32x32.png"
image16by16= "_layouts/15/images/placeholder16x16.png"/>
</CommandUIDefinition>
</CommandUIDefinitions>
<CommandUIHandlers>
<commanduihandler command= "Invoke_fixdocrcabuttonrequest"
<!--jump to post.aspx, JavaScript is not supported in SharePoint2013 commandaction
commandaction= "~appweburl/pages/post.aspx? {standardtokens}& splistitemid={itemid}& Splistid={listid}} "
<!--A document record the button is selected to be enabled - Enabledscript= "JAVASCRIPT:SP. ListOperation.Selection.getSelectedItems (). length = = 1 "
/>
</CommandUIHandlers>
</commanduiextension >
</CustomAction>
In addition, in the jump page post.aspx Placeholderadditionalpagehead should also be introduced
<webpartpages:allowframing id= "AllowFraming1" runat= "Server"/>
Indicates that the page is allowed to be displayed as a frame