@ -1,25 +1,3 @@
<%@page import="com.liferay.portal.service.UserLocalServiceUtil"%>
<%@page import="com.liferay.portal.model.User"%>
<%@page import="com.liferay.portal.kernel.portlet.LiferayWindowState"%>
<%@page import="javax.portlet.PortletMode"%>
<%@page import="com.liferay.portal.util.PortletKeys"%>
<%@page import="javax.portlet.PortletRequest"%>
<%@page import="javax.portlet.PortletURL"%>
<%@page import="com.liferay.portal.model.Group"%>
<%@page import="com.liferay.portlet.PortletURLFactoryUtil"%>
<%@page import="com.liferay.portal.service.LayoutLocalServiceUtil"%>
<%@page import="com.liferay.portal.model.GroupConstants"%>
<%@page import="com.liferay.portal.service.GroupLocalServiceUtil"%>
<%@page import="it.tref.liferay.portos.bo.model.ControlloPratica"%>
<%@page import="it.tref.liferay.portos.bo.service.ControlloPraticaLocalServiceUtil"%>
<%@page import="com.liferay.portal.service.WorkflowInstanceLinkLocalServiceUtil"%>
<%@page import="com.liferay.portal.model.WorkflowInstanceLink"%>
<%@page import="com.liferay.portal.kernel.workflow.WorkflowTask"%>
<%@page import="it.tref.liferay.portos.bo.service.DettPraticaLocalServiceUtil"%>
<%@page import="it.tref.liferay.portos.bo.model.DettPratica"%>
<%@page import="it.tref.liferay.portos.bo.util.SoggettiUtil"%>
<%@page import="it.tref.liferay.portos.bo.service.SoggettoLocalServiceUtil"%>
<%@page import="com.liferay.portal.kernel.language.LanguageUtil"%>
<%@page import="com.liferay.portal.kernel.util.DateFormatFactoryUtil"%>
<%@page import="com.liferay.portal.kernel.util.DateFormatFactoryUtil"%>
<%@page import="java.util.Date"%>
<%@page import="java.util.Date"%>
<%@page import="com.liferay.portal.util.PortalUtil"%>
<%@page import="com.liferay.portal.util.PortalUtil"%>
@ -88,475 +66,282 @@
<aui:row style="margin-top: 10px" id="praticaAdminDiv">
<aui:row style="margin-top: 10px" id="praticaAdminDiv">
<aui:row id="praticaRecapDiv">
<aui:row id="praticaRecapDiv">
<aui:row>
<aui:row>
<liferay-security:doAsURL
doAsUserId="<%= intPratica.getUserId() %>"
var="impersonateUserURL">
</liferay-security:doAsURL>
<aui:col span="3">
<aui:col span="3">
<p style="font-size: 30px; margin: 20px 0;">
<p style="font-size: 30px; margin: 20px 0;">
<b>Pratica:</b> <%= intPraticaId %>
<b>Pratica:</b> <%= intPraticaId %>
<liferay-ui:icon
image="impersonate_user"
target="_blank"
url="<%= impersonateUserURL %>">
</liferay-ui:icon>
</p>
</p>
</aui:col>
</aui:col>
</aui:row>
</aui:row>
<aui:row>
<aui:row>
<div class="module-group">
<aui:col span="2">
<liferay-ui:panel title="DETTAGLI" collapsible="false" extended="true">
<p><b>Numero Progetto:</b> <%= intPratica.getNumeroProgetto() %></p>
<aui:row>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><b>Numero Progetto:</b> <%= intPratica.getNumeroProgetto() %></p>
<p><b>Username:</b> <%= intPratica.getUserName() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><b>Username:</b> <%= intPratica.getUserName() %></p>
<p><b>Tipo Pratica:</b> <%= intPratica.getTipoPratica() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><b>Tipo Pratica:</b> <%= intPratica.getTipoPratica() %></p>
<p><b>ID Territorio:</b> <%= intPratica.getTerritorioId() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
</aui:row>
<p><b>ID Territorio:</b> <%= intPratica.getTerritorioId() %></p>
<aui:row>
</aui:col>
<aui:col span="2">
</aui:row>
<p><b>Tipo Procedura:</b> <%= intPratica.getTipoProcedura() %></p>
<aui:row>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><b>Tipo Procedura:</b> <%= intPratica.getTipoProcedura() %></p>
<p><b>Stato Pratica:</b> <%= intPratica.getStatoPratica() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><b>Stato Pratica:</b> <%= intPratica.getStatoPratica() %></p>
<p><b>Validata:</b> <%= intPratica.getValidata() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><b>Validata:</b> <%= intPratica.getValidata() %></p>
<p><b>Esito Controllo:</b> <%= intPratica.getEsitoControllo() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
</aui:row>
<p><b>Esito Controllo:</b> <%= intPratica.getEsitoControllo() %></p>
<aui:row>
</aui:col>
<aui:col span="2">
</aui:row>
<p><b>Status:</b> <%= intPratica.getStatus() %></p>
<aui:row>
</aui:col>
<aui:col span="2">
</aui:row>
<p><b>Status:</b> <%= intPratica.getStatus() %></p>
<%
</aui:col>
Date dataInizioLavoriOpera = AdvancedOperationUtil.fetchDataInizioLavoriOpera(intPratica);
</aui:row>
if(Validator.isNotNull(dataInizioLavoriOpera)){
<%
%>
Date dataInizioLavoriOpera = AdvancedOperationUtil.fetchDataInizioLavoriOpera(intPratica);
<aui:row>
if(Validator.isNotNull(dataInizioLavoriOpera)){
<liferay-portlet:actionURL
%>
name="cambiaDataInizioLavori"
<aui:row>
var="cambiaDataInizioLavoriURL" >
<liferay-portlet:actionURL
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
name="cambiaDataInizioLavori"
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
var="cambiaDataInizioLavoriURL" >
</liferay-portlet:actionURL>
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<%
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
String functionDataInizio = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"cambiaDataInizioLavori','Sei sicuro di voler modificare la DATA di INIZIO LAVORI?')";
</liferay-portlet:actionURL>
%>
<%
<aui:form action="<%= cambiaDataInizioLavoriURL %>" method="post" name="cambiaDataInizioLavori">
String functionDataInizio = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"cambiaDataInizioLavori','Sei sicuro di voler modificare la DATA di INIZIO LAVORI?')";
<div style="display:flex;">
%>
<aui:input
<aui:form action="<%= cambiaDataInizioLavoriURL %>" method="post" name="cambiaDataInizioLavori">
name="dataInizioLavoriOperaInput"
<div style="display:flex;">
label="Data inizio Lavori Opera"
<p><b>Data inizio Lavori Opera:</b></p>
inlineLabel="left"
<aui:input
type="date"
name="dataInizioLavoriOperaInput"
value='<%= DateFormatFactoryUtil.getSimpleDateFormat("yyyy-MM-dd").format(dataInizioLavoriOpera) %>'>
label=""
</aui:input>
inlineLabel="left"
<div>
type="date"
value='<%= DateFormatFactoryUtil.getSimpleDateFormat("yyyy-MM-dd").format(dataInizioLavoriOpera) %>'>
</aui:input>
<div>
<aui:button
name="cambiaDataInizioLavoriBtn"
cssClass="btn-primary"
type="button"
value="Cambia"
onClick='<%= functionDataInizio %>'/>
</div>
</div>
</aui:form>
</aui:row>
<% } %>
<aui:row>
<div style="display:flex;">
<% if(AdvancedOperationUtil.hasDettPratica(intPraticaId)){
boolean normLavoriInProprioFlag = AdvancedOperationUtil.getNormLavoriInProprioFlag(intPraticaId);
%>
<div style="margin-right: 50px;">
<liferay-portlet:actionURL
name="fixNormLavoriInProprio"
var="fixNormLavoriInProprioURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="normLavoriInProprioFlag" value="<%= String.valueOf(normLavoriInProprioFlag) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionLavori = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"fixLavoriInEconomia','Sei sicuro di voler cambiare i flag LAVORI IN ECONOMIA di questa pratica?')";
%>
<aui:form action="<%= fixNormLavoriInProprioURL %>" method="post" name="fixLavoriInEconomia">
<aui:button
name="normLavoriInProprioBtn"
cssClass="btn-primary"
type="button"
value="<%= AdvancedOperationUtil.getLavoriInEconomiaBtnLabel(normLavoriInProprioFlag) %>"
onClick='<%= functionLavori %>'/>
</aui:form>
</div>
<% } %>
<% if(AdvancedOperationUtil.hasDettPratica(intPraticaId)){
boolean collaudoStaticoFlag = AdvancedOperationUtil.getCollaudoStaticoFlag(intPraticaId);
%>
<div style="margin-right: 50px;">
<liferay-portlet:actionURL
name="fixCollaudoStatico"
var="fixCollaudoStaticoURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="collaudoStaticoFlag" value="<%= String.valueOf(collaudoStaticoFlag) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionCollaudoStatico = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"fixCollaudoStatico','Sei sicuro di voler cambiare i flag COLLAUDO STATICO di questa pratica?')";
%>
<aui:form action="<%= fixCollaudoStaticoURL %>" method="post" name="fixCollaudoStatico">
<aui:button
name="fixCollaudoStaticoBtn"
cssClass="btn-primary"
type="button"
value="<%= AdvancedOperationUtil.getCollaudoStaticoBtnLabel(collaudoStaticoFlag) %>"
onClick='<%= functionCollaudoStatico %>'/>
</aui:form>
</div>
<% } %>
<% if(AdvancedOperationUtil.isStatoPraticaIN(intPratica)){ %>
<div style="margin-right: 50px;">
<liferay-portlet:actionURL
name="fixStatusPratica"
var="fixStatusPraticaURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionStatus = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"fixStatusPratica','Sei sicuro di voler modificare lo status di questa pratica?')";
%>
<aui:form action="<%= fixStatusPraticaURL %>" method="post" name="fixStatusPratica">
<aui:button
type="button"
cssClass="btn-primary"
name="fixStatusPraticaBtn"
onClick='<%= functionStatus %>'
value="Fixa lo STATUS"
>
</aui:button>
</aui:form>
</div>
<% } %>
<% if(AdvancedOperationUtil.hasControlloPratica_ProceduraC(intPratica) &&
AdvancedOperationUtil.isNotWorkflowManuallyStarted(intPratica)){ %>
<div style="margin-right: 50px;">
<liferay-portlet:actionURL
name="deleteControlloPratica"
var="deleteControlloPraticaURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionControlloPratica = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"deleteControlloPratica','Sei sicuro di voler eliminare questo ControlloPratica ed il relativo WorkFlow?')";
%>
<aui:form action="<%= deleteControlloPraticaURL %>" method="post" name="deleteControlloPratica">
<aui:button
type="button"
cssClass="btn-primary"
name="deleteControlloPraticaBtn"
onClick='<%= functionControlloPratica %>'
value="Elimina WorkFlow"
>
</aui:button>
</aui:form>
</div>
<% } %>
<% if(AdvancedOperationUtil.isPraticaAnnullata(intPratica)){ %>
<div style="margin-right: 50px;">
<liferay-portlet:actionURL
name="ripristinaPraticaVidimata"
var="ripristinaPraticaVidimataURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionRipristinaVidimata = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"ripristinaPraticaVidimata','Sei sicuro di voler ripristinare questa pratica come VIDIMATA?')";
%>
<aui:form action="<%= ripristinaPraticaVidimataURL %>" method="post" name="ripristinaPraticaVidimata">
<aui:button
type="button"
cssClass="btn-primary"
name="ripristinaPraticaVidimataBtn"
onClick='<%= functionRipristinaVidimata %>'
value="Ripristina come VIDIMATA"
>
</aui:button>
</aui:form>
</div>
<div style="margin-right: 50px;">
<liferay-portlet:actionURL
name="ripristinaPraticaConforme"
var="ripristinaPraticaConformeURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionRipristinaConforme = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"ripristinaPraticaConforme','Sei sicuro di voler ripristinare questa pratica come AUTORIZZATA/CONFORME?')";
%>
<aui:form action="<%= ripristinaPraticaConformeURL %>" method="post" name="ripristinaPraticaConforme">
<aui:button
type="button"
cssClass="btn-primary"
name="ripristinaPraticaConformeBtn"
onClick='<%= functionRipristinaConforme %>'
value="Ripristina come AUTORIZZATA/CONFORME"
>
</aui:button>
</aui:form>
</div>
<% } %>
</div>
</aui:row>
</liferay-ui:panel>
</div>
<div class="module-group">
<liferay-ui:panel title="REINDICIZZAZIONE" extended="true" collapsible="false">
<aui:row>
<liferay-portlet:actionURL
name="reindexPratica"
var="reindexPraticaURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
String functionReindex = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"reindexPratica','Sei sicuro di voler reindicizzare questa pratica?')";
%>
<aui:form action="<%= reindexPraticaURL %>" method="post" name="reindexPratica">
<aui:button
<aui:button
type="button"
name="cambiaDataInizioLavoriBtn"
cssClass="btn-primary"
cssClass="btn-primary"
name="reindexPraticaBtn"
type="button"
onClick='<%= functionReindex %>'
value="Cambia"
value="Reindicizza Pratica"
onClick='<%= functionDataInizio %>'/>
>
</aui:button>
</aui:form>
</aui:row>
</liferay-ui:panel>
</div>
<div class="module-group">
<liferay-ui:panel title="IMPERSONAMENTO" extended="true" collapsible="false">
<aui:row>
<div style="display:flex;">
<liferay-security:doAsURL
doAsUserId="<%= intPratica.getUserId() %>"
var="impersonateUserURL">
</liferay-security:doAsURL>
<div style=" margin-right: 15px;">
<p><b>Impersona titolare:</b></p>
</div>
<liferay-ui:icon
image="impersonate_user"
target="_blank"
url="<%= impersonateUserURL %>">
</liferay-ui:icon>
</div>
</div>
</aui:row>
</div>
<% if(SoggettoLocalServiceUtil.countByIntPratica(intPraticaId) > 1){ %>
</aui:form>
<aui:row>
</aui:row>
<div style="display:flex;">
<% } %>
<div style=" margin-right: 15px;">
<aui:row>
<p><b>Impersona soggetti:</b></p>
<% if(AdvancedOperationUtil.hasDettPratica(intPraticaId)){
</div>
boolean normLavoriInProprioFlag = AdvancedOperationUtil.getNormLavoriInProprioFlag(intPraticaId);
<liferay-ui:icon
%>
id="impersonaSoggettiBtn"
<aui:col span="3">
image="team_icon"
<liferay-portlet:actionURL
message="Visualizza Soggetti"
name="fixNormLavoriInProprio"
target="_blank"
var="fixNormLavoriInProprioURL" >
>
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
</liferay-ui:icon>
<liferay-portlet:param name="normLavoriInProprioFlag" value="<%= String.valueOf(normLavoriInProprioFlag) %>"/>
</div>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</aui:row>
</liferay-portlet:actionURL>
<aui:row>
<div id="sc-soggetti-da-impersonare" class="hide">
<liferay-ui:search-container emptyResultsMessage="Nessun soggetto disponibile">
<liferay-ui:search-container-results
results="<%= SoggettoLocalServiceUtil.findByIntPratica(intPraticaId) %>"
total="<%= SoggettoLocalServiceUtil.countByIntPratica(intPraticaId) %>"
/>
<liferay-ui:search-container-row className="it.tref.liferay.portos.bo.model.Soggetto" modelVar="soggetto">
<liferay-security:doAsURL
doAsUserId="<%= soggetto.getUserId() %>"
var="impersonateSoggettoURL">
</liferay-security:doAsURL>
<liferay-ui:search-container-column-text name="RUOLO">
<%= soggetto.getFullTipologiaSoggetto() %>
</liferay-ui:search-container-column-text>
<liferay-ui:search-container-column-text name="DENOMINAZIONE">
<%= soggetto.getDescrizioneCompleta() %>
</liferay-ui:search-container-column-text>
<liferay-ui:search-container-column-text name="AGGIUNTO DA">
<%
DettPratica adding = DettPraticaLocalServiceUtil.fetchDettPratica(soggetto.getDettPraticaId());
if (adding != null) {
out.print(adding.getFullDescription());
}
%>
</liferay-ui:search-container-column-text>
<liferay-ui:search-container-column-text name="IMPERSONA" cssClass="text-center text-nowrap">
<liferay-ui:icon
image="impersonate_user"
message="Impersona Soggetto"
target="_blank"
url="<%= impersonateSoggettoURL %>"
>
</liferay-ui:icon>
</liferay-ui:search-container-column-text>
</liferay-ui:search-container-row>
<liferay-ui:search-iterator paginate="false" />
</liferay-ui:search-container>
</div>
</aui:row>
<% } %>
</liferay-ui:panel>
</div>
<div class="module-group">
<%
<%
List<WorkflowTask> listaTask = AdvancedOperationUtil.getListaTask(intPratica);
String functionLavori = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"fixLavoriInEconomia','Sei sicuro di voler cambiare i flag LAVORI IN ECONOMIA di questa pratica?')";
if(Validator.isNotNull(listaTask) && !listaTask.isEmpty()){
%>
%>
<liferay-ui:panel title="GESTIONE ATTIVITÀ" extended="true" collapsible="false">
<aui:form action="<%= fixNormLavoriInProprioURL %>" method="post" name="fixLavoriInEconomia">
<aui:row>
<aui:button
<div style="display:flex;">
name="normLavoriInProprioBtn"
<div style=" margin-right: 15px;">
cssClass="btn-primary"
<p><b>Gestisci ultima attività:</b></p>
type="button"
</div>
value="<%= AdvancedOperationUtil.getLavoriInEconomiaBtnLabel(normLavoriInProprioFlag) %>"
<%
onClick='<%= functionLavori %>'/>
Group controlPanelGroup = GroupLocalServiceUtil.getGroup(company.getCompanyId(), GroupConstants.CONTROL_PANEL);
</aui:form>
long controlPanelPlid = LayoutLocalServiceUtil.getDefaultPlid(controlPanelGroup.getGroupId(),true);
</aui:col>
PortletURL workflowTaskURL = PortletURLFactoryUtil.create(request, PortletKeys.MY_WORKFLOW_TASKS,
<% } %>
controlPanelPlid, PortletRequest.RENDER_PHASE);
workflowTaskURL.setParameter("struts_action", "/my_workflow_tasks/edit_workflow_task");
workflowTaskURL.setParameter("workflowTaskId", String.valueOf(listaTask.get(0).getWorkflowTaskId()));
workflowTaskURL.setPortletMode(PortletMode.VIEW);
workflowTaskURL.setWindowState(LiferayWindowState.POP_UP);
%>
<div title='<%= LanguageUtil.get(pageContext,"workflow-action-manage") %>' class="tooltip-info">
<liferay-ui:icon
useDialog="true"
image="action_right"
message="Gestisci Attività"
url='<%= workflowTaskURL.toString() + "&controlPanelCategory=my" %>'
/>
</div>
</div>
</aui:row>
<%
if(intPratica.getStatusByUserId() != 0L ){
User tecnico = UserLocalServiceUtil.fetchUser(intPratica.getStatusByUserId());
if (Validator.isNotNull(tecnico)) {
%>
<% if(AdvancedOperationUtil.hasDettPratica(intPraticaId)){
<aui:row>
boolean collaudoStaticoFlag = AdvancedOperationUtil.getCollaudoStaticoFlag(intPraticaId);
<div style="display:flex;">
%>
<liferay-security:doAsURL
<aui:col span="3">
doAsUserId="<%= tecnico.getUserId() %>"
<liferay-portlet:actionURL
var="impersonateIstruttoreURL">
name="fixCollaudoStatico"
</liferay-security:doAsURL>
var="fixCollaudoStaticoURL" >
<div style=" margin-right: 15px;">
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<p><b>Impersona Istruttore:</b></p>
<liferay-portlet:param name="collaudoStaticoFlag" value="<%= String.valueOf(collaudoStaticoFlag) %>"/>
</div>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
<liferay-ui:icon
</liferay-portlet:actionURL>
image="impersonate_user"
target="_blank"
message="Impersona Istruttore"
url="<%= impersonateIstruttoreURL %>">
</liferay-ui:icon>
</div>
</aui:row>
<%
}
}
%>
</liferay-ui:panel>
<%
<%
}
String functionCollaudoStatico = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"fixCollaudoStatico','Sei sicuro di voler cambiare i flag COLLAUDO STATICO di questa pratica?')";
%>
%>
</div>
<aui:form action="<%= fixCollaudoStaticoURL %>" method="post" name="fixCollaudoStatico">
</aui:row>
<aui:button
<aui:row id="docPraticaDiv">
name="fixCollaudoStaticoBtn"
<div class="module-group">
cssClass="btn-primary"
<liferay-ui:panel title="DOCUMENTI ORFANI" collapsible="false" extended="true">
type="button"
value="<%= AdvancedOperationUtil.getCollaudoStaticoBtnLabel(collaudoStaticoFlag) %>"
onClick='<%= functionCollaudoStatico %>'/>
</aui:form>
</aui:col>
<% } %>
<% if(AdvancedOperationUtil.isStatoPraticaIN(intPratica)){ %>
<aui:col span="3">
<liferay-portlet:actionURL
name="fixStatusPratica"
var="fixStatusPraticaURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
<%
List<DocPratica> docPraticaList = DocPraticaLocalServiceUtil.findByIntPratica(intPraticaId);
String functionStatus = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"fixStatusPratica','Sei sicuro di voler modificare lo status di questa pratica?')";
%>
%>
<h2>Documenti Totali: <%= docPraticaList.size() %></h2>
<aui:form action="<%= fixStatusPraticaURL %>" method="post" name="fixStatusPratica">
<aui:button
type="button"
cssClass="btn-primary"
name="fixStatusPraticaBtn"
onClick='<%= functionStatus %>'
value="Fixa lo STATUS"
>
</aui:button>
</aui:form>
</aui:col>
<% } %>
<% if(AdvancedOperationUtil.isPraticaAnnullata(intPratica)){ %>
<aui:col span="3">
<liferay-portlet:actionURL
name="ripristinaPraticaVidimata"
var="ripristinaPraticaVidimataURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<%
<%
List<DocPratica> docPraticaOrfaniList = AdvancedOperationUtil.getDocPraticaOrfani(intPraticaId);
String functionRipristinaVidimata = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"ripristinaPraticaVidimata','Sei sicuro di voler ripristinare questa pratica come VIDIMATA?')";
if(!docPraticaOrfaniList.isEmpty()){
%>
%>
<liferay-portlet:actionURL
<aui:form action="<%= ripristinaPraticaVidimataURL %>" method="post" name="ripristinaPraticaVidimata">
name="deleteDocPratica"
<aui:button
var="deleteDocPraticaURL" >
type="button"
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
cssClass="btn-primary"
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
name="ripristinaPraticaVidimataBtn"
</liferay-portlet:actionURL>
onClick='<%= functionRipristinaVidimata %>'
<aui:row>
value="Ripristina come VIDIMATA"
<h2>Documenti orfani di DettPratica: <%= docPraticaOrfaniList.size() %></h2>
>
<aui:row>
</aui:button>
<aui:col span="2">
</aui:form>
<h3>DlFileEntryId</h3>
</aui:col>
</aui:col>
<aui:col span="3">
<aui:col span="2">
<liferay-portlet:actionURL
<h3>docPraticaId</h3>
name="ripristinaPraticaConforme"
</aui:col>
var="ripristinaPraticaConformeURL" >
<aui:col span="2">
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<h3>dettPraticaId</h3>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</aui:col>
</liferay-portlet:actionURL>
<aui:col span="6">
<%
<h3>FileName</h3>
String functionRipristinaConforme = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"ripristinaPraticaConforme','Sei sicuro di voler ripristinare questa pratica come AUTORIZZATA/CONFORME?')";
</aui:col>
%>
</aui:row>
<aui:form action="<%= ripristinaPraticaConformeURL %>" method="post" name="ripristinaPraticaConforme">
<aui:button
type="button"
cssClass="btn-primary"
name="ripristinaPraticaConformeBtn"
onClick='<%= functionRipristinaConforme %>'
value="Ripristina come AUTORIZZATA/CONFORME"
>
</aui:button>
</aui:form>
</aui:col>
<% } %>
</aui:row>
</aui:row>
<aui:row id="docPraticaDiv">
<%
List<DocPratica> docPraticaList = DocPraticaLocalServiceUtil.findByIntPratica(intPraticaId);
%>
<h2>Documenti Totali: <%= docPraticaList.size() %></h2>
<%
List<DocPratica> docPraticaOrfaniList = AdvancedOperationUtil.getDocPraticaOrfani(intPraticaId);
if(!docPraticaOrfaniList.isEmpty()){
%>
<liferay-portlet:actionURL
name="deleteDocPratica"
var="deleteDocPraticaURL" >
<liferay-portlet:param name="intPraticaId" value="<%= String.valueOf(intPraticaId) %>"/>
<liferay-portlet:param name="mvcPath" value="/html/view.jsp"/>
</liferay-portlet:actionURL>
<aui:row>
<h2>Documenti orfani di DettPratica: <%= docPraticaOrfaniList.size() %></h2>
<aui:row>
<aui:col span="2">
<h3>DlFileEntryId</h3>
</aui:col>
<aui:col span="2">
<h3>docPraticaId</h3>
</aui:col>
<aui:col span="2">
<h3>dettPraticaId</h3>
</aui:col>
<aui:col span="6">
<h3>FileName</h3>
</aui:col>
</aui:row>
<%
<%
for(DocPratica docPratica : docPraticaOrfaniList){
for(DocPratica docPratica : docPraticaOrfaniList){
if(Validator.isNotNull(docPratica)){
if(Validator.isNotNull(docPratica)){
%>
%>
<aui:row>
<aui:row>
<aui:col span="2">
<aui:col span="2">
<p><%= docPratica.getDlFileEntryId() %></p>
<p><%= docPratica.getDlFileEntryId() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><%= docPratica.getDocPraticaId() %></p>
<p><%= docPratica.getDocPraticaId() %></p>
</aui:col>
</aui:col>
<aui:col span="2">
<aui:col span="2">
<p><%= docPratica.getClassPk() %></p>
<p><%= docPratica.getClassPk() %></p>
</aui:col>
</aui:col>
<aui:col span="6">
<aui:col span="6">
<p><%= docPratica.getFileName() %></p>
<p><%= docPratica.getFileName() %></p>
</aui:col>
</aui:col>
</aui:row>
<%
}
}
%>
<%
String functionEliminaDoc = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"deleteDocPratica','Sei sicuro di voler eliminare tutti i documenti?')";
%>
<aui:form action="<%= deleteDocPraticaURL %>" method="post" name="deleteDocPratica">
<aui:button-row>
<aui:button
type="button"
name="deleteDocPraticaBtn"
cssClass="btn-primary"
onClick='<%= functionEliminaDoc %>'
value="Elimina tutti">
</aui:button>
</aui:button-row>
</aui:form>
</aui:row>
</aui:row>
</liferay-ui:panel>
</div>
<%
<%
}
}
}
%>
%>
</aui:row>
<%
String functionEliminaDoc = "javascript:"+renderResponse.getNamespace()+"openConfirmationDialog('"+renderResponse.getNamespace()+"deleteDocPratica','Sei sicuro di voler eliminare tutti i documenti?')";
%>
<aui:form action="<%= deleteDocPraticaURL %>" method="post" name="deleteDocPratica">
<aui:button-row>
<aui:button
type="button"
name="deleteDocPraticaBtn"
cssClass="btn-primary"
onClick='<%= functionEliminaDoc %>'
value="Elimina tutti">
</aui:button>
</aui:button-row>
</aui:form>
</aui:row>
<%
}
%>
</aui:row>
</aui:row>
</aui:row>
</aui:row>
<% } %>
<% } %>
@ -572,18 +357,6 @@
<aui:script use="event-valuechange,aui-modal,aui-io-request">
<aui:script use="event-valuechange,aui-modal,aui-io-request">
<% if(Validator.isNotNull(intPratica)){ %>
A.one('#impersonaSoggettiBtn').on('click', function(){
var soggettoDiv = A.one('#sc-soggetti-da-impersonare');
if(soggettoDiv.hasClass('hide')){
soggettoDiv.show();
} else {
soggettoDiv.hide();
}
});
<% } %>
A.one('#<portlet:namespace />intPraticaId').on('valuechange', function(e){
A.one('#<portlet:namespace />intPraticaId').on('valuechange', function(e){
if(e.newVal <= 0 ){
if(e.newVal <= 0 ){
A.one('#<portlet:namespace />numeroProgetto').attr('disabled', false);
A.one('#<portlet:namespace />numeroProgetto').attr('disabled', false);