I need a popup window (where I am getting) and we select checkboxes in the popup window. The place I stuck is I need the count of checkboxes from a popup to a parent page. The count is happening but when we click save in popup the whole parent window is getting reload. What I need is, I need to reload only the button I used to display popup onclick. Here I am using AJAX to execute. Please find the code snippets and let me know if u need anything.Thanks!
Here are the code snippets attached
POPUP
<h:form id='popup'>
<h:panelGrid columns="6" cellspacing="15">
<h:selectManyCheckbox value = "#{repricing.rowOneSelectedCompetitors}" id="input">
<f:selectItems value="#{competitor.competitorList}" var="competitor_name"
itemValue="#{competitor_name}"/>
</h:selectManyCheckbox>
</h:outputLabel>
</h:panelGrid>
<h:panelGroup style="display:block; text-align:center">
<h:commandButton type="reset" value="Restore to Default"></h:commandButton>
<h:commandButton value="save" type="submit">
<f:ajax execute="input" render="output" ></f:ajax>
</h:commandButton>
</h:panelGroup>
</h:form>
Parent Page
<div class="col-md-12 padding">
<span>
<input id= "output" type="button" value=" selected Competitors" style="width: auto; float: none; display: inline-block; padding: 0 6px; margin-right: 15px;" class="btn btn-default" data-toggle="modal" data-target="#addModal1"></input>
</span>
</div>
<f:ajax execute="input" render=":myform:output"/>