<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to extend Form submit button? in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/how-to-extend-form-submit-button/m-p/95236#M28051</link>
    <description>&lt;P&gt;I have the follow code which creates a button that will display a dialog to create a node. I want to extend the logic before submitting and after submitting.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Before submitting&lt;/STRONG&gt;: I want to check some existing nodes' properties if there are any duplicates. Prevent creation of the new node if there are duplicates.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;After submitting&lt;/STRONG&gt;: I want to fire an Aikau topic to refresh a certain widget or refresh the page.&lt;/P&gt;&lt;P&gt;I'm not sure where to start to extend the submit function. I've checked the FormProcessor but i'm not sure if that's the right place.&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;function &lt;/SPAN&gt;getListCreateButton() {&lt;BR /&gt;  &lt;SPAN&gt;return &lt;/SPAN&gt;{&lt;BR /&gt;    &lt;SPAN&gt;name&lt;/SPAN&gt;: &lt;SPAN&gt;"alfresco/buttons/AlfButton"&lt;/SPAN&gt;,&lt;BR /&gt;    &lt;SPAN&gt;config&lt;/SPAN&gt;: {&lt;BR /&gt;      &lt;SPAN&gt;style&lt;/SPAN&gt;: {&lt;BR /&gt;        &lt;SPAN&gt;marginTop&lt;/SPAN&gt;: &lt;SPAN&gt;"5px"&lt;/SPAN&gt;,&lt;BR /&gt;        &lt;SPAN&gt;marginBottom&lt;/SPAN&gt;: &lt;SPAN&gt;"5px"&lt;BR /&gt;&lt;/SPAN&gt;      },&lt;BR /&gt;      &lt;SPAN&gt;label&lt;/SPAN&gt;: "test",&lt;BR /&gt;      &lt;SPAN&gt;additionalCssClasses&lt;/SPAN&gt;: &lt;SPAN&gt;"call-to-action"&lt;/SPAN&gt;,&lt;BR /&gt;      &lt;SPAN&gt;publishTopic&lt;/SPAN&gt;: &lt;SPAN&gt;"ALF_FORM_REQUEST"&lt;/SPAN&gt;,&lt;BR /&gt;      &lt;SPAN&gt;publishPayload&lt;/SPAN&gt;: {&lt;BR /&gt;        &lt;SPAN&gt;formConfig&lt;/SPAN&gt;: {&lt;BR /&gt;          &lt;SPAN&gt;useDialog&lt;/SPAN&gt;: &lt;SPAN&gt;true&lt;/SPAN&gt;,&lt;BR /&gt;          &lt;SPAN&gt;formId&lt;/SPAN&gt;: &lt;SPAN&gt;"NEW_LIST_ITEM_DIALOG"&lt;/SPAN&gt;,&lt;BR /&gt;          &lt;SPAN&gt;dialogTitle&lt;/SPAN&gt;: "test"&lt;BR /&gt;        },&lt;BR /&gt;        &lt;SPAN&gt;alfDestination&lt;/SPAN&gt;: getListDestination(),&lt;BR /&gt;        &lt;SPAN&gt;itemId&lt;/SPAN&gt;: &lt;SPAN&gt;"rlarchive:aListItem"&lt;/SPAN&gt;,&lt;BR /&gt;        &lt;SPAN&gt;itemKind&lt;/SPAN&gt;: &lt;SPAN&gt;"type"&lt;/SPAN&gt;,&lt;BR /&gt;        &lt;SPAN&gt;mode&lt;/SPAN&gt;: &lt;SPAN&gt;"create"&lt;BR /&gt;&lt;/SPAN&gt;      }&lt;BR /&gt;    }&lt;BR /&gt;  }&lt;BR /&gt;&amp;nbsp;&lt;/PRE&gt;</description>
    <pubDate>Mon, 09 Mar 2020 15:54:01 GMT</pubDate>
    <dc:creator>phivuu-2</dc:creator>
    <dc:date>2020-03-09T15:54:01Z</dc:date>
    <item>
      <title>How to extend Form submit button?</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-to-extend-form-submit-button/m-p/95236#M28051</link>
      <description>&lt;P&gt;I have the follow code which creates a button that will display a dialog to create a node. I want to extend the logic before submitting and after submitting.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Before submitting&lt;/STRONG&gt;: I want to check some existing nodes' properties if there are any duplicates. Prevent creation of the new node if there are duplicates.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;After submitting&lt;/STRONG&gt;: I want to fire an Aikau topic to refresh a certain widget or refresh the page.&lt;/P&gt;&lt;P&gt;I'm not sure where to start to extend the submit function. I've checked the FormProcessor but i'm not sure if that's the right place.&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;function &lt;/SPAN&gt;getListCreateButton() {&lt;BR /&gt;  &lt;SPAN&gt;return &lt;/SPAN&gt;{&lt;BR /&gt;    &lt;SPAN&gt;name&lt;/SPAN&gt;: &lt;SPAN&gt;"alfresco/buttons/AlfButton"&lt;/SPAN&gt;,&lt;BR /&gt;    &lt;SPAN&gt;config&lt;/SPAN&gt;: {&lt;BR /&gt;      &lt;SPAN&gt;style&lt;/SPAN&gt;: {&lt;BR /&gt;        &lt;SPAN&gt;marginTop&lt;/SPAN&gt;: &lt;SPAN&gt;"5px"&lt;/SPAN&gt;,&lt;BR /&gt;        &lt;SPAN&gt;marginBottom&lt;/SPAN&gt;: &lt;SPAN&gt;"5px"&lt;BR /&gt;&lt;/SPAN&gt;      },&lt;BR /&gt;      &lt;SPAN&gt;label&lt;/SPAN&gt;: "test",&lt;BR /&gt;      &lt;SPAN&gt;additionalCssClasses&lt;/SPAN&gt;: &lt;SPAN&gt;"call-to-action"&lt;/SPAN&gt;,&lt;BR /&gt;      &lt;SPAN&gt;publishTopic&lt;/SPAN&gt;: &lt;SPAN&gt;"ALF_FORM_REQUEST"&lt;/SPAN&gt;,&lt;BR /&gt;      &lt;SPAN&gt;publishPayload&lt;/SPAN&gt;: {&lt;BR /&gt;        &lt;SPAN&gt;formConfig&lt;/SPAN&gt;: {&lt;BR /&gt;          &lt;SPAN&gt;useDialog&lt;/SPAN&gt;: &lt;SPAN&gt;true&lt;/SPAN&gt;,&lt;BR /&gt;          &lt;SPAN&gt;formId&lt;/SPAN&gt;: &lt;SPAN&gt;"NEW_LIST_ITEM_DIALOG"&lt;/SPAN&gt;,&lt;BR /&gt;          &lt;SPAN&gt;dialogTitle&lt;/SPAN&gt;: "test"&lt;BR /&gt;        },&lt;BR /&gt;        &lt;SPAN&gt;alfDestination&lt;/SPAN&gt;: getListDestination(),&lt;BR /&gt;        &lt;SPAN&gt;itemId&lt;/SPAN&gt;: &lt;SPAN&gt;"rlarchive:aListItem"&lt;/SPAN&gt;,&lt;BR /&gt;        &lt;SPAN&gt;itemKind&lt;/SPAN&gt;: &lt;SPAN&gt;"type"&lt;/SPAN&gt;,&lt;BR /&gt;        &lt;SPAN&gt;mode&lt;/SPAN&gt;: &lt;SPAN&gt;"create"&lt;BR /&gt;&lt;/SPAN&gt;      }&lt;BR /&gt;    }&lt;BR /&gt;  }&lt;BR /&gt;&amp;nbsp;&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Mar 2020 15:54:01 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-to-extend-form-submit-button/m-p/95236#M28051</guid>
      <dc:creator>phivuu-2</dc:creator>
      <dc:date>2020-03-09T15:54:01Z</dc:date>
    </item>
  </channel>
</rss>

