diff --git a/liferay-plugins-sdk-6.2/portlets/portos-accesso-atti-portlet/docroot/html/accesso_atti_fe/visualizza-atto.jsp b/liferay-plugins-sdk-6.2/portlets/portos-accesso-atti-portlet/docroot/html/accesso_atti_fe/visualizza-atto.jsp index 722caa8c..561542f2 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-accesso-atti-portlet/docroot/html/accesso_atti_fe/visualizza-atto.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-accesso-atti-portlet/docroot/html/accesso_atti_fe/visualizza-atto.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.portlet.LiferayWindowState"%> <%@page import="it.tref.liferay.portos.bo.shared.util.PortletKeys"%> @@ -222,7 +223,7 @@ RichiestaAccessoAtti accettoAtti = RichiestaAccessoAttiLocalServiceUtil.getRichi
- <%=BeanPropertiesUtil.getString(dettPratica, "descLongIntervento") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "descLongIntervento")) %>
diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/portlet.xml b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/portlet.xml index a357fb25..ef2ad7b9 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/portlet.xml +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/portlet.xml @@ -369,6 +369,7 @@ text/html view + content.portos-administration.Language Amministrazione Paesaggistica Amministrazione Paesaggistica diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalService.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalService.java index 85a929a2..c48746a8 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalService.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalService.java @@ -414,6 +414,10 @@ public interface DocPraticaLocalService extends BaseLocalService, long intPraticaId, java.lang.String tipologia, int start, int end) throws com.liferay.portal.kernel.exception.SystemException; + public java.util.List findByIntPratica_Tipologie( + long intPraticaId, java.util.List tipologie) + throws com.liferay.portal.kernel.exception.SystemException; + public java.util.List findByIntPratica_ClassPk_Tipologia( long intPraticaId, long classPk, java.lang.String tipologia, int start, int end) throws com.liferay.portal.kernel.exception.SystemException; diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceClp.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceClp.java index f60758a7..d2bfb180 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceClp.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceClp.java @@ -239,105 +239,109 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { "long", "java.lang.String", "int", "int" }; - _methodName44 = "findByIntPratica_ClassPk_Tipologia"; + _methodName44 = "findByIntPratica_Tipologie"; - _methodParameterTypes44 = new String[] { + _methodParameterTypes44 = new String[] { "long", "java.util.List" }; + + _methodName45 = "findByIntPratica_ClassPk_Tipologia"; + + _methodParameterTypes45 = new String[] { "long", "long", "java.lang.String", "int", "int" }; - _methodName45 = "findByIntPratica_ClassPk_Tipologie"; + _methodName46 = "findByIntPratica_ClassPk_Tipologie"; - _methodParameterTypes45 = new String[] { "long", "long", "java.util.List" }; + _methodParameterTypes46 = new String[] { "long", "long", "java.util.List" }; - _methodName46 = "findByIntPratica_ClassPkEqual_Tipologie"; + _methodName47 = "findByIntPratica_ClassPkEqual_Tipologie"; - _methodParameterTypes46 = new String[] { "long", "long", "java.util.List" }; + _methodParameterTypes47 = new String[] { "long", "long", "java.util.List" }; - _methodName47 = "fetchByC_Group_DlFileEntry_Version"; + _methodName48 = "fetchByC_Group_DlFileEntry_Version"; - _methodParameterTypes47 = new String[] { "long", "java.lang.String" }; + _methodParameterTypes48 = new String[] { "long", "java.lang.String" }; - _methodName48 = "findDistinctDlFileEntryId"; + _methodName49 = "findDistinctDlFileEntryId"; - _methodParameterTypes48 = new String[] { + _methodParameterTypes49 = new String[] { "long", "java.lang.String", "int", "int" }; - _methodName49 = "findDistinctDlFileEntryId"; + _methodName50 = "findDistinctDlFileEntryId"; - _methodParameterTypes49 = new String[] { + _methodParameterTypes50 = new String[] { "long[][]", "java.lang.String", "int", "int" }; - _methodName50 = "getValidByIntPratica"; + _methodName51 = "getValidByIntPratica"; - _methodParameterTypes50 = new String[] { "long" }; + _methodParameterTypes51 = new String[] { "long" }; - _methodName51 = "getValidByIntPratica_Tipologia"; + _methodName52 = "getValidByIntPratica_Tipologia"; - _methodParameterTypes51 = new String[] { + _methodParameterTypes52 = new String[] { "long", "java.lang.String", "int", "int" }; - _methodName52 = "countValidTmpByIntPratica_Tipologia"; + _methodName53 = "countValidTmpByIntPratica_Tipologia"; - _methodParameterTypes52 = new String[] { "long", "java.lang.String" }; + _methodParameterTypes53 = new String[] { "long", "java.lang.String" }; - _methodName53 = "getValidTmpByIntPratica"; + _methodName54 = "getValidTmpByIntPratica"; - _methodParameterTypes53 = new String[] { "long", "int", "int" }; + _methodParameterTypes54 = new String[] { "long", "int", "int" }; - _methodName54 = "getValidTmpByIntPratica_Tipologia"; + _methodName55 = "getValidTmpByIntPratica_Tipologia"; - _methodParameterTypes54 = new String[] { + _methodParameterTypes55 = new String[] { "long", "java.lang.String", "int", "int" }; - _methodName55 = "getValidTmpByIntPratica_DettPratica_Tipologia"; + _methodName56 = "getValidTmpByIntPratica_DettPratica_Tipologia"; - _methodParameterTypes55 = new String[] { + _methodParameterTypes56 = new String[] { "long", "long", "java.lang.String", "int", "int" }; - _methodName56 = "getValidTmpByIntPratica_Tipologie"; + _methodName57 = "getValidTmpByIntPratica_Tipologie"; - _methodParameterTypes56 = new String[] { + _methodParameterTypes57 = new String[] { "long", "java.lang.String[][]", "int", "int" }; - _methodName57 = "countValidTmpByIntPratica_Tipologie"; + _methodName58 = "countValidTmpByIntPratica_Tipologie"; - _methodParameterTypes57 = new String[] { "long", "java.lang.String[][]" }; + _methodParameterTypes58 = new String[] { "long", "java.lang.String[][]" }; - _methodName58 = "getInvalidByIntPratica"; + _methodName59 = "getInvalidByIntPratica"; - _methodParameterTypes58 = new String[] { "long" }; + _methodParameterTypes59 = new String[] { "long" }; - _methodName59 = "getInvalidTmpByIntPratica"; + _methodName60 = "getInvalidTmpByIntPratica"; - _methodParameterTypes59 = new String[] { "long" }; + _methodParameterTypes60 = new String[] { "long" }; - _methodName60 = "getValidUntilClassPkByIntPratica"; + _methodName61 = "getValidUntilClassPkByIntPratica"; - _methodParameterTypes60 = new String[] { + _methodParameterTypes61 = new String[] { "long", "long", "java.lang.String", "int", "int" }; - _methodName61 = "completeInvalidation"; + _methodName62 = "completeInvalidation"; - _methodParameterTypes61 = new String[] { "long" }; + _methodParameterTypes62 = new String[] { "long" }; - _methodName62 = "addDocPraticaAnnullamento"; + _methodName63 = "addDocPraticaAnnullamento"; - _methodParameterTypes62 = new String[] { + _methodParameterTypes63 = new String[] { "long", "java.lang.String", "long", "long", "long", "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", "com.liferay.portal.service.ServiceContext" }; - _methodName63 = "findByIntPratica_ClassPk_TipologiaNew"; + _methodName64 = "findByIntPratica_ClassPk_TipologiaNew"; - _methodParameterTypes63 = new String[] { + _methodParameterTypes64 = new String[] { "long", "long", "java.lang.String", "int", "int" }; } @@ -1807,6 +1811,40 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { return (java.util.List)ClpSerializer.translateOutput(returnObj); } + @Override + public java.util.List findByIntPratica_Tipologie( + long intPraticaId, java.util.List tipologie) + throws com.liferay.portal.kernel.exception.SystemException { + Object returnObj = null; + + try { + returnObj = _invokableLocalService.invokeMethod(_methodName44, + _methodParameterTypes44, + new Object[] { + intPraticaId, + + ClpSerializer.translateInput(tipologie) + }); + } + catch (Throwable t) { + t = ClpSerializer.translateThrowable(t); + + if (t instanceof com.liferay.portal.kernel.exception.SystemException) { + throw (com.liferay.portal.kernel.exception.SystemException)t; + } + + if (t instanceof RuntimeException) { + throw (RuntimeException)t; + } + else { + throw new RuntimeException(t.getClass().getName() + + " is not a valid exception"); + } + } + + return (java.util.List)ClpSerializer.translateOutput(returnObj); + } + @Override public java.util.List findByIntPratica_ClassPk_Tipologia( long intPraticaId, long classPk, java.lang.String tipologia, int start, @@ -1814,8 +1852,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName44, - _methodParameterTypes44, + returnObj = _invokableLocalService.invokeMethod(_methodName45, + _methodParameterTypes45, new Object[] { intPraticaId, @@ -1855,8 +1893,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName45, - _methodParameterTypes45, + returnObj = _invokableLocalService.invokeMethod(_methodName46, + _methodParameterTypes46, new Object[] { intPraticaId, @@ -1892,8 +1930,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName46, - _methodParameterTypes46, + returnObj = _invokableLocalService.invokeMethod(_methodName47, + _methodParameterTypes47, new Object[] { intPraticaId, @@ -1928,8 +1966,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName47, - _methodParameterTypes47, + returnObj = _invokableLocalService.invokeMethod(_methodName48, + _methodParameterTypes48, new Object[] { dlFileEntryId, @@ -1962,8 +2000,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName48, - _methodParameterTypes48, + returnObj = _invokableLocalService.invokeMethod(_methodName49, + _methodParameterTypes49, new Object[] { classPk, @@ -2000,8 +2038,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName49, - _methodParameterTypes49, + returnObj = _invokableLocalService.invokeMethod(_methodName50, + _methodParameterTypes50, new Object[] { ClpSerializer.translateInput(classPks), @@ -2038,8 +2076,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName50, - _methodParameterTypes50, new Object[] { intPraticaId }); + returnObj = _invokableLocalService.invokeMethod(_methodName51, + _methodParameterTypes51, new Object[] { intPraticaId }); } catch (Throwable t) { t = ClpSerializer.translateThrowable(t); @@ -2067,8 +2105,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName51, - _methodParameterTypes51, + returnObj = _invokableLocalService.invokeMethod(_methodName52, + _methodParameterTypes52, new Object[] { intPraticaId, @@ -2105,8 +2143,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName52, - _methodParameterTypes52, + returnObj = _invokableLocalService.invokeMethod(_methodName53, + _methodParameterTypes53, new Object[] { intPraticaId, @@ -2139,8 +2177,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName53, - _methodParameterTypes53, + returnObj = _invokableLocalService.invokeMethod(_methodName54, + _methodParameterTypes54, new Object[] { intPraticaId, start, end }); } catch (Throwable t) { @@ -2169,8 +2207,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName54, - _methodParameterTypes54, + returnObj = _invokableLocalService.invokeMethod(_methodName55, + _methodParameterTypes55, new Object[] { intPraticaId, @@ -2208,8 +2246,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName55, - _methodParameterTypes55, + returnObj = _invokableLocalService.invokeMethod(_methodName56, + _methodParameterTypes56, new Object[] { intPraticaId, @@ -2248,8 +2286,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName56, - _methodParameterTypes56, + returnObj = _invokableLocalService.invokeMethod(_methodName57, + _methodParameterTypes57, new Object[] { intPraticaId, @@ -2286,8 +2324,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName57, - _methodParameterTypes57, + returnObj = _invokableLocalService.invokeMethod(_methodName58, + _methodParameterTypes58, new Object[] { intPraticaId, @@ -2320,8 +2358,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName58, - _methodParameterTypes58, new Object[] { intPraticaId }); + returnObj = _invokableLocalService.invokeMethod(_methodName59, + _methodParameterTypes59, new Object[] { intPraticaId }); } catch (Throwable t) { t = ClpSerializer.translateThrowable(t); @@ -2349,8 +2387,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName59, - _methodParameterTypes59, new Object[] { intPraticaId }); + returnObj = _invokableLocalService.invokeMethod(_methodName60, + _methodParameterTypes60, new Object[] { intPraticaId }); } catch (Throwable t) { t = ClpSerializer.translateThrowable(t); @@ -2378,8 +2416,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName60, - _methodParameterTypes60, + returnObj = _invokableLocalService.invokeMethod(_methodName61, + _methodParameterTypes61, new Object[] { intPraticaId, @@ -2415,8 +2453,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { public void completeInvalidation(long intPraticaId) throws com.liferay.portal.kernel.exception.SystemException { try { - _invokableLocalService.invokeMethod(_methodName61, - _methodParameterTypes61, new Object[] { intPraticaId }); + _invokableLocalService.invokeMethod(_methodName62, + _methodParameterTypes62, new Object[] { intPraticaId }); } catch (Throwable t) { t = ClpSerializer.translateThrowable(t); @@ -2447,8 +2485,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName62, - _methodParameterTypes62, + returnObj = _invokableLocalService.invokeMethod(_methodName63, + _methodParameterTypes63, new Object[] { userId, @@ -2501,8 +2539,8 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { Object returnObj = null; try { - returnObj = _invokableLocalService.invokeMethod(_methodName63, - _methodParameterTypes63, + returnObj = _invokableLocalService.invokeMethod(_methodName64, + _methodParameterTypes64, new Object[] { intPraticaId, @@ -2661,4 +2699,6 @@ public class DocPraticaLocalServiceClp implements DocPraticaLocalService { private String[] _methodParameterTypes62; private String _methodName63; private String[] _methodParameterTypes63; + private String _methodName64; + private String[] _methodParameterTypes64; } \ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceUtil.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceUtil.java index 6d3c7c7d..f075cba8 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceUtil.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceUtil.java @@ -496,6 +496,12 @@ public class DocPraticaLocalServiceUtil { end); } + public static java.util.List findByIntPratica_Tipologie( + long intPraticaId, java.util.List tipologie) + throws com.liferay.portal.kernel.exception.SystemException { + return getService().findByIntPratica_Tipologie(intPraticaId, tipologie); + } + public static java.util.List findByIntPratica_ClassPk_Tipologia( long intPraticaId, long classPk, java.lang.String tipologia, int start, int end) throws com.liferay.portal.kernel.exception.SystemException { diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceWrapper.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceWrapper.java index 7eec70ea..8eee5edf 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceWrapper.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/service/DocPraticaLocalServiceWrapper.java @@ -533,6 +533,14 @@ public class DocPraticaLocalServiceWrapper implements DocPraticaLocalService, tipologia, start, end); } + @Override + public java.util.List findByIntPratica_Tipologie( + long intPraticaId, java.util.List tipologie) + throws com.liferay.portal.kernel.exception.SystemException { + return _docPraticaLocalService.findByIntPratica_Tipologie(intPraticaId, + tipologie); + } + @Override public java.util.List findByIntPratica_ClassPk_Tipologia( long intPraticaId, long classPk, java.lang.String tipologia, int start, diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/Portal.properties b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/Portal.properties index 85502fb4..50d68d4a 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/Portal.properties +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/Portal.properties @@ -1262,6 +1262,8 @@ label.admingeniocivile.avviso.documento.integrazioneaccettata = Vidimazione Inte label.admingeniocivile.avviso.documento.avvisomanuale = Avviso Manuale label.admingeniocivile.avviso.documento.cambioistruttore = Cambio Istruttore +label.admingeniocivile.ricercaavvisi.link.avviso = Scarica il documento di avviso: + ## Asseverazioni/Deleghe ## verifica-delega = Verifica Completezza concludi-delega = Concludi Delega diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/portos-administration/Language.properties b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/portos-administration/Language.properties new file mode 100644 index 00000000..198b459d --- /dev/null +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/content/portos-administration/Language.properties @@ -0,0 +1,3 @@ +javax.portlet.title = Amministrazione Paesaggistica +javax.portlet.description = Strumenti specifici per l'amministrazione del portale Paesaggistica.
\ + Utilizzare con cautela. diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/mwg/sismica/bo/util/SismicaUtil.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/mwg/sismica/bo/util/SismicaUtil.java index 17cc14f1..7c40990c 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/mwg/sismica/bo/util/SismicaUtil.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/mwg/sismica/bo/util/SismicaUtil.java @@ -718,6 +718,7 @@ public class SismicaUtil { } catch (SystemException e) {} int start = 0; List pratiche = null; + String className = ControlloPratica.class.getName(); do { try { pratiche = IntPraticaLocalServiceUtil.getIntPraticas(start, start + SLICE); @@ -750,9 +751,25 @@ public class SismicaUtil { Map workflowContext = new HashMap(); esitoLog(esito, "id: " + pratica.getIntPraticaId() + ", numero: " + pratica.getNumeroProgetto()); try { - WorkflowHandlerRegistryUtil.startWorkflowInstance(last.getCompanyId(), last.getGroupId(), - last.getUserId(), ControlloPratica.class.getName(), last.getPrimaryKey(), last, - serviceContext, workflowContext); + long groupId = last.getGroupId(); + long classPK = last.getPrimaryKey(); + WorkflowInstanceLink workflowInstanceLink = WorkflowInstanceLinkLocalServiceUtil + .fetchWorkflowInstanceLink(companyId, groupId, className, classPK); + if (workflowInstanceLink != null) { + WorkflowInstance workflowInstance; + try { + workflowInstance = WorkflowInstanceManagerUtil.getWorkflowInstance(companyId, + workflowInstanceLink.getWorkflowInstanceId()); + } catch (Exception e) { + workflowInstance = null; + } + if (Validator.isNull(workflowInstance) || !workflowInstance.isComplete()) { + WorkflowInstanceLinkLocalServiceUtil.deleteWorkflowInstanceLink(companyId, groupId, + className, classPK); + } + } + WorkflowHandlerRegistryUtil.startWorkflowInstance(companyId, groupId, last.getUserId(), + className, classPK, last, serviceContext, workflowContext); } catch (PortalException | SystemException e) { esitoLog(esito, "Errore " + e.getMessage()); } diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/model/listener/KaleoInstanceTokenModelListener.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/model/listener/KaleoInstanceTokenModelListener.java index bf3ad4fa..d3200af7 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/model/listener/KaleoInstanceTokenModelListener.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/model/listener/KaleoInstanceTokenModelListener.java @@ -67,7 +67,7 @@ public class KaleoInstanceTokenModelListener extends BaseModelListener)arguments[1]); + } + + if (_methodName201.equals(name) && + Arrays.deepEquals(_methodParameterTypes201, parameterTypes)) { return DocPraticaLocalServiceUtil.findByIntPratica_ClassPk_Tipologia(((Long)arguments[0]).longValue(), ((Long)arguments[1]).longValue(), (java.lang.String)arguments[2], @@ -655,78 +665,78 @@ public class DocPraticaLocalServiceClpInvoker { ((Integer)arguments[4]).intValue()); } - if (_methodName201.equals(name) && - Arrays.deepEquals(_methodParameterTypes201, parameterTypes)) { + if (_methodName202.equals(name) && + Arrays.deepEquals(_methodParameterTypes202, parameterTypes)) { return DocPraticaLocalServiceUtil.findByIntPratica_ClassPk_Tipologie(((Long)arguments[0]).longValue(), ((Long)arguments[1]).longValue(), (java.util.List)arguments[2]); } - if (_methodName202.equals(name) && - Arrays.deepEquals(_methodParameterTypes202, parameterTypes)) { + if (_methodName203.equals(name) && + Arrays.deepEquals(_methodParameterTypes203, parameterTypes)) { return DocPraticaLocalServiceUtil.findByIntPratica_ClassPkEqual_Tipologie(((Long)arguments[0]).longValue(), ((Long)arguments[1]).longValue(), (java.util.List)arguments[2]); } - if (_methodName203.equals(name) && - Arrays.deepEquals(_methodParameterTypes203, parameterTypes)) { + if (_methodName204.equals(name) && + Arrays.deepEquals(_methodParameterTypes204, parameterTypes)) { return DocPraticaLocalServiceUtil.fetchByC_Group_DlFileEntry_Version(((Long)arguments[0]).longValue(), (java.lang.String)arguments[1]); } - if (_methodName204.equals(name) && - Arrays.deepEquals(_methodParameterTypes204, parameterTypes)) { + if (_methodName205.equals(name) && + Arrays.deepEquals(_methodParameterTypes205, parameterTypes)) { return DocPraticaLocalServiceUtil.findDistinctDlFileEntryId(((Long)arguments[0]).longValue(), (java.lang.String)arguments[1], ((Integer)arguments[2]).intValue(), ((Integer)arguments[3]).intValue()); } - if (_methodName205.equals(name) && - Arrays.deepEquals(_methodParameterTypes205, parameterTypes)) { + if (_methodName206.equals(name) && + Arrays.deepEquals(_methodParameterTypes206, parameterTypes)) { return DocPraticaLocalServiceUtil.findDistinctDlFileEntryId((long[])arguments[0], (java.lang.String)arguments[1], ((Integer)arguments[2]).intValue(), ((Integer)arguments[3]).intValue()); } - if (_methodName206.equals(name) && - Arrays.deepEquals(_methodParameterTypes206, parameterTypes)) { + if (_methodName207.equals(name) && + Arrays.deepEquals(_methodParameterTypes207, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidByIntPratica(((Long)arguments[0]).longValue()); } - if (_methodName207.equals(name) && - Arrays.deepEquals(_methodParameterTypes207, parameterTypes)) { + if (_methodName208.equals(name) && + Arrays.deepEquals(_methodParameterTypes208, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidByIntPratica_Tipologia(((Long)arguments[0]).longValue(), (java.lang.String)arguments[1], ((Integer)arguments[2]).intValue(), ((Integer)arguments[3]).intValue()); } - if (_methodName208.equals(name) && - Arrays.deepEquals(_methodParameterTypes208, parameterTypes)) { + if (_methodName209.equals(name) && + Arrays.deepEquals(_methodParameterTypes209, parameterTypes)) { return DocPraticaLocalServiceUtil.countValidTmpByIntPratica_Tipologia(((Long)arguments[0]).longValue(), (java.lang.String)arguments[1]); } - if (_methodName209.equals(name) && - Arrays.deepEquals(_methodParameterTypes209, parameterTypes)) { + if (_methodName210.equals(name) && + Arrays.deepEquals(_methodParameterTypes210, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidTmpByIntPratica(((Long)arguments[0]).longValue(), ((Integer)arguments[1]).intValue(), ((Integer)arguments[2]).intValue()); } - if (_methodName210.equals(name) && - Arrays.deepEquals(_methodParameterTypes210, parameterTypes)) { + if (_methodName211.equals(name) && + Arrays.deepEquals(_methodParameterTypes211, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidTmpByIntPratica_Tipologia(((Long)arguments[0]).longValue(), (java.lang.String)arguments[1], ((Integer)arguments[2]).intValue(), ((Integer)arguments[3]).intValue()); } - if (_methodName211.equals(name) && - Arrays.deepEquals(_methodParameterTypes211, parameterTypes)) { + if (_methodName212.equals(name) && + Arrays.deepEquals(_methodParameterTypes212, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidTmpByIntPratica_DettPratica_Tipologia(((Long)arguments[0]).longValue(), ((Long)arguments[1]).longValue(), (java.lang.String)arguments[2], @@ -734,32 +744,32 @@ public class DocPraticaLocalServiceClpInvoker { ((Integer)arguments[4]).intValue()); } - if (_methodName212.equals(name) && - Arrays.deepEquals(_methodParameterTypes212, parameterTypes)) { + if (_methodName213.equals(name) && + Arrays.deepEquals(_methodParameterTypes213, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidTmpByIntPratica_Tipologie(((Long)arguments[0]).longValue(), (java.lang.String[])arguments[1], ((Integer)arguments[2]).intValue(), ((Integer)arguments[3]).intValue()); } - if (_methodName213.equals(name) && - Arrays.deepEquals(_methodParameterTypes213, parameterTypes)) { + if (_methodName214.equals(name) && + Arrays.deepEquals(_methodParameterTypes214, parameterTypes)) { return DocPraticaLocalServiceUtil.countValidTmpByIntPratica_Tipologie(((Long)arguments[0]).longValue(), (java.lang.String[])arguments[1]); } - if (_methodName215.equals(name) && - Arrays.deepEquals(_methodParameterTypes215, parameterTypes)) { - return DocPraticaLocalServiceUtil.getInvalidByIntPratica(((Long)arguments[0]).longValue()); - } - if (_methodName216.equals(name) && Arrays.deepEquals(_methodParameterTypes216, parameterTypes)) { - return DocPraticaLocalServiceUtil.getInvalidTmpByIntPratica(((Long)arguments[0]).longValue()); + return DocPraticaLocalServiceUtil.getInvalidByIntPratica(((Long)arguments[0]).longValue()); } if (_methodName217.equals(name) && Arrays.deepEquals(_methodParameterTypes217, parameterTypes)) { + return DocPraticaLocalServiceUtil.getInvalidTmpByIntPratica(((Long)arguments[0]).longValue()); + } + + if (_methodName218.equals(name) && + Arrays.deepEquals(_methodParameterTypes218, parameterTypes)) { return DocPraticaLocalServiceUtil.getValidUntilClassPkByIntPratica(((Long)arguments[0]).longValue(), ((Long)arguments[1]).longValue(), (java.lang.String)arguments[2], @@ -767,15 +777,15 @@ public class DocPraticaLocalServiceClpInvoker { ((Integer)arguments[4]).intValue()); } - if (_methodName218.equals(name) && - Arrays.deepEquals(_methodParameterTypes218, parameterTypes)) { + if (_methodName219.equals(name) && + Arrays.deepEquals(_methodParameterTypes219, parameterTypes)) { DocPraticaLocalServiceUtil.completeInvalidation(((Long)arguments[0]).longValue()); return null; } - if (_methodName219.equals(name) && - Arrays.deepEquals(_methodParameterTypes219, parameterTypes)) { + if (_methodName220.equals(name) && + Arrays.deepEquals(_methodParameterTypes220, parameterTypes)) { return DocPraticaLocalServiceUtil.addDocPraticaAnnullamento(((Long)arguments[0]).longValue(), (java.lang.String)arguments[1], ((Long)arguments[2]).longValue(), @@ -786,8 +796,8 @@ public class DocPraticaLocalServiceClpInvoker { (com.liferay.portal.service.ServiceContext)arguments[9]); } - if (_methodName220.equals(name) && - Arrays.deepEquals(_methodParameterTypes220, parameterTypes)) { + if (_methodName221.equals(name) && + Arrays.deepEquals(_methodParameterTypes221, parameterTypes)) { return DocPraticaLocalServiceUtil.findByIntPratica_ClassPk_TipologiaNew(((Long)arguments[0]).longValue(), ((Long)arguments[1]).longValue(), (java.lang.String)arguments[2], @@ -916,8 +926,8 @@ public class DocPraticaLocalServiceClpInvoker { private String[] _methodParameterTypes212; private String _methodName213; private String[] _methodParameterTypes213; - private String _methodName215; - private String[] _methodParameterTypes215; + private String _methodName214; + private String[] _methodParameterTypes214; private String _methodName216; private String[] _methodParameterTypes216; private String _methodName217; @@ -928,4 +938,6 @@ public class DocPraticaLocalServiceClpInvoker { private String[] _methodParameterTypes219; private String _methodName220; private String[] _methodParameterTypes220; + private String _methodName221; + private String[] _methodParameterTypes221; } \ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/AvvisoLocalServiceImpl.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/AvvisoLocalServiceImpl.java index 9274d294..948ae609 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/AvvisoLocalServiceImpl.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/AvvisoLocalServiceImpl.java @@ -201,6 +201,9 @@ public class AvvisoLocalServiceImpl extends AvvisoLocalServiceBaseImpl { Long fileEntryIdBase, long fileEntryIdFirma, String jsonParameters, long controlloPraticaId, ServiceContext serviceContext) throws SystemException, PortalException { + if ((fileEntryIdTemplate == 0) && (fileEntryIdBase == null)) { + throw new SystemException("No template"); + } _log.info("addAvviso: intPraticaId=" + intPraticaId + ", descLong=\"" + descLong + "\", dtAvviso=" + dtAvviso + ", tipoAvviso=\"" + tipoAvviso + "\", tipoDocumento=\"" + tipoDocumento + "\", fileEntryIdTemplate=" + fileEntryIdTemplate + ", classPk=" + classPk + ", className=\"" + className diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/DocPraticaLocalServiceImpl.java b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/DocPraticaLocalServiceImpl.java index 2a1f500e..49b9a112 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/DocPraticaLocalServiceImpl.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/bo/service/impl/DocPraticaLocalServiceImpl.java @@ -379,7 +379,18 @@ public class DocPraticaLocalServiceImpl extends DocPraticaLocalServiceBaseImpl { dynamicQuery.add(RestrictionsFactoryUtil.eq("intPraticaId", intPraticaId)); dynamicQuery.add(PropertyFactoryUtil.forName("tipologia").eq(tipologia)); dynamicQuery.addOrder(OrderFactoryUtil.desc("classPk")); - return soggettoPersistence.findWithDynamicQuery(dynamicQuery, start, end); + return docPraticaPersistence.findWithDynamicQuery(dynamicQuery, start, end); + } + + @SuppressWarnings("unchecked") + public List findByIntPratica_Tipologie(long intPraticaId, List tipologie) + throws SystemException { + + DynamicQuery dynamicQuery = dynamicQuery(); + dynamicQuery.add(RestrictionsFactoryUtil.eq("intPraticaId", intPraticaId)); + dynamicQuery.add(PropertyFactoryUtil.forName("tipologia").in(tipologie)); + dynamicQuery.addOrder(OrderFactoryUtil.desc("classPk")); + return docPraticaPersistence.findWithDynamicQuery(dynamicQuery); } @SuppressWarnings("unchecked") @@ -518,8 +529,9 @@ public class DocPraticaLocalServiceImpl extends DocPraticaLocalServiceBaseImpl { @SuppressWarnings("unchecked") @Override - public List getValidTmpByIntPratica_Tipologie(long intPraticaId, String[] tipologie, int start, int end) - throws SystemException { + public List + getValidTmpByIntPratica_Tipologie(long intPraticaId, String[] tipologie, int start, int end) + throws SystemException { DynamicQuery dynamicQuery = createvalidTmpQueryByIntPratica(intPraticaId); dynamicQuery.add(RestrictionsFactoryUtil.in("tipologia", tipologie)); diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/service.properties b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/service.properties index 17f41f6b..a5b66dda 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/service.properties +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/service.properties @@ -13,8 +13,8 @@ ## build.namespace=portos_bo - build.number=3605 - build.date=1644937328845 + build.number=3606 + build.date=1651494929385 build.auto.upgrade=true ## diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/allegati_manuali/edit_allegato_manuale.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/allegati_manuali/edit_allegato_manuale.jsp index b9ca9332..4c4e304a 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/allegati_manuali/edit_allegato_manuale.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/allegati_manuali/edit_allegato_manuale.jsp @@ -29,6 +29,8 @@ long territorioGroupId = territorio.getGroupId(); + 'pdf' diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_desc_edificio.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_desc_edificio.jsp index 61c658f1..7e71f9df 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_desc_edificio.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_desc_edificio.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> <%@ include file="/html/fascicolo/init.jsp" %> @@ -214,7 +215,7 @@
<%= LanguageUtil.get(pageContext, "dcc-strutture-ele-misto-altro") %> - <%=BeanPropertiesUtil.getString(dettPratica, "dccStruttureEleAltroDescrizione") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "dccStruttureEleAltroDescrizione")) %>
@@ -247,7 +248,7 @@
<%= LanguageUtil.get(pageContext, "dcc-orizzontamenti-altro") %> - <%=BeanPropertiesUtil.getString(dettPratica, "dccOrizzontamentiAltroDescrizione") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "dccOrizzontamentiAltroDescrizione")) %>
@@ -317,7 +318,7 @@
<%= LanguageUtil.get(pageContext, "dcc-elem-non-strut-altro") %> - <%=BeanPropertiesUtil.getString(dettPratica, "dccElemNonStrutAltroDescrizione") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "dccElemNonStrutAltroDescrizione")) %>
@@ -362,7 +363,7 @@
<%= LanguageUtil.get(pageContext, "dcc-opere-di-rinforzo-altro") %> - <%=BeanPropertiesUtil.getString(dettPratica, "dccOpereDiRinforzoAltroDescrizione") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "dccOpereDiRinforzoAltroDescrizione")) %>
@@ -450,7 +451,7 @@
<%= LanguageUtil.get(pageContext, "de-inf-altro") %> - <%=BeanPropertiesUtil.getString(dettPratica, "deInfAltroDesc") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "deInfAltroDesc")) %>
diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_dettagli_principali.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_dettagli_principali.jsp index 2414f27f..92bb9bc2 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_dettagli_principali.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_dettagli_principali.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page import="it.mwg.sismica.bo.shared.util.Generics"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> @@ -98,7 +99,7 @@ String hide10 = (intPratica.getTipoProcedura().equals(Constants.PROCEDURA_Q10) | <%= LanguageUtil.get(pageContext, "interv-fin-pub") %>
- <%=BeanPropertiesUtil.getString(dettPratica, "intervFinPubDesc") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "intervFinPubDesc")) %>
@@ -185,7 +186,7 @@ String hide10 = (intPratica.getTipoProcedura().equals(Constants.PROCEDURA_Q10) |
- <%= dettPratica.getDescLongIntervento() %> + <%= HtmlUtil.escape(dettPratica.getDescLongIntervento()) %>
@@ -380,7 +381,7 @@ String hide10 = (intPratica.getTipoProcedura().equals(Constants.PROCEDURA_Q10) | <%=LanguageUtil.get(pageContext, "tc-altri-interventi") %> - : <%= dettPratica.getTcAltriInterventiDesc() %> + : <%= HtmlUtil.escape(dettPratica.getTcAltriInterventiDesc()) %>
@@ -448,7 +449,7 @@ String hide10 = (intPratica.getTipoProcedura().equals(Constants.PROCEDURA_Q10) | <%= LanguageUtil.get(pageContext, "tc-altro") %>
- <%= BeanPropertiesUtil.getString(dettPratica, "tcAltroDescrizione") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "tcAltroDescrizione")) %>
diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_riepilogo.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_riepilogo.jsp index 463758ab..60edb7f9 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_riepilogo.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/page_riepilogo.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> <%@page import="com.liferay.portal.model.User"%> @@ -128,7 +129,7 @@ String hide10 = (intPratica.getTipoProcedura().equals(Constants.PROCEDURA_Q10) |
- <%= BeanPropertiesUtil.getString(dettPratica, "descLongIntervento") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "descLongIntervento")) %>
diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_collaudo.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_collaudo.jsp index 2ff9fc7c..5f51a51d 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_collaudo.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_collaudo.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="it.tref.liferay.portos.bo.shared.util.TipoSoggettoUtil"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> @@ -73,7 +74,7 @@ <%= LanguageUtil.get(pageContext, "col-desc-interv") %>
- <%=BeanPropertiesUtil.getString(dettPratica, "descLongIntervento") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "descLongIntervento")) %>

diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_fine-lavori.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_fine-lavori.jsp index 03d43ff0..f3377602 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_fine-lavori.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/navigator/view_dettagli_fine-lavori.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="it.tref.liferay.portos.bo.shared.util.TipoSoggettoUtil"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> @@ -74,7 +75,7 @@ <%= LanguageUtil.get(pageContext, "fl-desc-interv") %>
- <%=BeanPropertiesUtil.getString(dettPratica, "descLongIntervento") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "descLongIntervento")) %>

diff --git a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/view.jsp b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/view.jsp index 1291bdf3..4c7b358b 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/view.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/html/fascicolo/view.jsp @@ -330,7 +330,7 @@ String keywords = StringPool.BLANK; <%= LanguageUtil.get(pageContext, "label_procedura_" + intPratica.getTipoProcedura()) + ") " + LanguageUtil.get(pageContext, "tipo_procedura_" + intPratica.getTipoProcedura()) %>

- <%= lastDettPratica == null ? StringPool.BLANK : lastDettPratica.getDescLongIntervento() %> + <%= lastDettPratica == null ? StringPool.BLANK : HtmlUtil.escape(lastDettPratica.getDescLongIntervento()) %> diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/mwg/sismica/fe/servlet/Instrumentation.java b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/mwg/sismica/fe/servlet/Instrumentation.java new file mode 100644 index 00000000..957ad4bc --- /dev/null +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/mwg/sismica/fe/servlet/Instrumentation.java @@ -0,0 +1,94 @@ +package it.mwg.sismica.fe.servlet; + +import it.tref.liferay.portos.bo.service.AvvisoLocalServiceUtil; + +import java.io.IOException; +import java.lang.management.ManagementFactory; +import java.util.Date; +import java.util.Iterator; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import com.liferay.portal.kernel.exception.SystemException; +import com.liferay.portal.kernel.json.JSONFactoryUtil; +import com.liferay.portal.kernel.json.JSONObject; +import com.liferay.portal.kernel.servlet.ServletResponseUtil; +import com.liferay.portal.kernel.util.ContentTypes; +import com.liferay.portal.kernel.util.ParamUtil; +import com.liferay.portal.kernel.util.StringPool; +import com.liferay.portal.util.PortalUtil; + +public class Instrumentation extends HttpServlet { + + private static final long serialVersionUID = 5542429846030601941L; + + @Override + protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { + + process(request, response); + } + + @Override + protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, + IOException { + + process(request, response); + } + + private void process(HttpServletRequest request, HttpServletResponse response) throws IOException { + + switch (request.getPathInfo()) { + case "/status": + status(response, ParamUtil.getString(request, "fmt", StringPool.BLANK).toLowerCase()); + break; + default: + response.sendError(HttpServletResponse.SC_NOT_FOUND); + } + } + + private void status(HttpServletResponse response, String mode) throws IOException { + + JSONObject json = JSONFactoryUtil.createJSONObject(); + long time = new Date().getTime() / 1000; + Runtime runtime = Runtime.getRuntime(); + json.put("status", "OK"); + json.put("cpus", runtime.availableProcessors()); + json.put("freeMemory", runtime.freeMemory()); + json.put("maxMemory", runtime.maxMemory()); + json.put("totalMemory", runtime.totalMemory()); + json.put("threads", ManagementFactory.getThreadMXBean().getThreadCount()); + json.put("time", time); + json.put("uptime", time - PortalUtil.getUptime().getTime() / 1000); + try { + AvvisoLocalServiceUtil.countAvvisiInvioSignal(); + } catch (SystemException e) { + json.put("status", "KO"); + } + switch (mode) { + case FMT_JSON: + response.setContentType(ContentTypes.APPLICATION_JSON); + ServletResponseUtil.write(response, json.toString()); + break; + case FMT_TEXT: + response.setContentType(ContentTypes.TEXT_PLAIN); + StringBuilder sb = new StringBuilder(); + Iterator keys = json.keys(); + while (keys.hasNext()) { + String key = keys.next(); + String value = json.getString(key); + sb.append('X').append(key.toUpperCase()).append('=').append(value).append('\n'); + } + ServletResponseUtil.write(response, sb.toString()); + break; + default: + response.setContentType(ContentTypes.TEXT_PLAIN); + ServletResponseUtil.write(response, json.getString("status")); + } + } + + private static final String FMT_JSON = "json"; + private static final String FMT_TEXT = "text"; +} diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/mwg/sismica/fe/servlet/SorgentiServlet.java b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/mwg/sismica/fe/servlet/SorgentiServlet.java deleted file mode 100644 index 3c6b170d..00000000 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/mwg/sismica/fe/servlet/SorgentiServlet.java +++ /dev/null @@ -1,220 +0,0 @@ -package it.mwg.sismica.fe.servlet; - -import it.tref.liferay.portos.bo.shared.util.Constants; -import it.tref.liferay.portos.mailmanager.shared.messaging.util.DestinationNames; -import it.tref.liferay.portos.mailmanager.shared.util.MailManagerConstants; - -import java.io.File; -import java.io.FileWriter; -import java.io.IOException; -import java.nio.file.Files; -import java.text.SimpleDateFormat; -import java.util.Arrays; -import java.util.Calendar; -import java.util.Comparator; -import java.util.Date; - -import javax.mail.internet.AddressException; -import javax.mail.internet.InternetAddress; -import javax.servlet.ServletException; -import javax.servlet.http.HttpServlet; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; - -import org.apache.commons.io.FileUtils; -import org.apache.commons.io.FilenameUtils; - -import com.liferay.portal.kernel.exception.PortalException; -import com.liferay.portal.kernel.exception.SystemException; -import com.liferay.portal.kernel.mail.MailMessage; -import com.liferay.portal.kernel.messaging.Message; -import com.liferay.portal.kernel.messaging.MessageBusUtil; -import com.liferay.portal.kernel.servlet.HttpHeaders; -import com.liferay.portal.kernel.util.CharPool; -import com.liferay.portal.kernel.util.ContentTypes; -import com.liferay.portal.kernel.util.DigesterUtil; -import com.liferay.portal.kernel.util.ParamUtil; -import com.liferay.portal.kernel.util.PropsUtil; -import com.liferay.portal.kernel.util.StringPool; -import com.liferay.portal.kernel.util.StringUtil; -import com.liferay.portal.kernel.util.Validator; -import com.liferay.portal.model.Company; -import com.liferay.portal.model.Role; -import com.liferay.portal.model.RoleConstants; -import com.liferay.portal.model.User; -import com.liferay.portal.service.RoleLocalServiceUtil; -import com.liferay.portal.service.ServiceContext; -import com.liferay.portal.service.ServiceContextFactory; -import com.liferay.portal.service.UserLocalServiceUtil; -import com.liferay.portal.util.PortalUtil; - -public class SorgentiServlet extends HttpServlet { - private static final long serialVersionUID = 5549374841236285035L; - - private static final int VALIDITA = 3; - private static final String FOLDER = "condivisi"; - private static final String URI = "/portos-fe-portlet/sorgenti-paesaggistica/"; - - @Override - protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - - String pathInfo = request.getPathInfo(); - if (Validator.isNull(pathInfo) || pathInfo.equals(StringPool.FORWARD_SLASH)) { - request.getRequestDispatcher("/html/sorgenti/form.jsp").forward(request, response); - } else { - String[] parti = StringUtil.split(pathInfo, CharPool.FORWARD_SLASH); - if (parti.length == 4) { - registra(request, "Scaricamento - " + parti[1] + StringPool.FORWARD_SLASH + parti[2] - + StringPool.FORWARD_SLASH + parti[3]); - String path = parti[1]; - File file = new File(PropsUtil.get("liferay.home") + File.separator + FOLDER + File.separator - + parti[3]); - if (file.exists() && !file.isDirectory() && pathValido(request, path)) { - String contentType = probeContentType(file); - response.setContentType(contentType); - response.setContentLength((int) file.length()); - response.setHeader(HttpHeaders.CONTENT_DISPOSITION, "attachment; filename=\"" + file.getName() - + StringPool.QUOTE); - FileUtils.copyFile(file, response.getOutputStream()); - } else { - response.sendError(HttpServletResponse.SC_NOT_FOUND, request.getRequestURI()); - } - } else { - response.sendError(HttpServletResponse.SC_NOT_FOUND, request.getRequestURI()); - } - } - } - - @Override - protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, - IOException { - - String pathInfo = request.getPathInfo(); - if (Validator.isNotNull(pathInfo) && pathInfo.equals("/richiedi")) { - try { - if (inviaMail(request, response)) { - request.getRequestDispatcher("/html/sorgenti/invio_ok.jsp").forward(request, response); - } else { - request.getRequestDispatcher("/html/sorgenti/invio_ko.jsp").forward(request, response); - } - } catch (AddressException | PortalException | SystemException e) { - request.getRequestDispatcher("/html/sorgenti/invio_ko.jsp").forward(request, response); - e.printStackTrace(); - } - } else { - response.sendError(HttpServletResponse.SC_NOT_FOUND, request.getRequestURI()); - } - } - - private static boolean pathValido(HttpServletRequest request, String path) { - - Calendar calendar = Calendar.getInstance(); - calendar.setTime(new Date()); - for (int i = 0; i <= VALIDITA; i++) { - if (path.equals(getLink(request, calendar.getTime()))) { - return true; - } - calendar.add(Calendar.DAY_OF_MONTH, -1); - } - return false; - } - - private static String getSeed(HttpServletRequest request) { - - String seed = null; - try { - Company company = PortalUtil.getCompany(request); - seed = (String) company.getExpandoBridge().getAttribute(Constants.COMPANY_CUSTOM_FIELD_LINK_SEED, false); - } catch (PortalException | SystemException e) { - } - return seed; - } - - private static boolean inviaMail(HttpServletRequest request, HttpServletResponse response) throws AddressException, - PortalException, SystemException, IOException { - - Date date = new Date(); - Calendar calendar = Calendar.getInstance(); - calendar.setTime(date); - calendar.add(Calendar.DAY_OF_MONTH, VALIDITA); - String nome = ParamUtil.getString(request, "nome"); - String cognome = ParamUtil.getString(request, "cognome"); - String email = ParamUtil.getString(request, "email"); - String link = getLink(request, date); - String digest = digest(request, email); - String scadenza = new SimpleDateFormat("dd/MM/yyyy").format(calendar.getTime()); - String testo = "Gentile " + nome + StringPool.SPACE + cognome - + ".

Puoi scaricare i sorgenti di Paesaggistica Sicilia da qui:
"; - File[] lista = new File(PropsUtil.get("liferay.home") + File.separator + FOLDER).listFiles(); - Arrays.sort(lista, new Comparator() { - @Override - public int compare(File f1, File f2) { - return f1.getName().compareTo(f2.getName()); - } - }); - for (File file : lista) { - testo += "" + file.getName() + ".
"; - } - if (lista.length > 1) { - testo += "
I link saranno validi"; - } else { - testo += "
Il link sarà valido"; - } - testo += " fino a tutto il giorno " + scadenza - + ".

È possibile in ogni momento richiedere un nuovo link da questa pagina."; - InternetAddress from = new InternetAddress("noreply-Sismica@lavoripubblici.sicilia.it", true); - InternetAddress[] to = { new InternetAddress(email, true) }; - MailMessage mail = new MailMessage(from, "Sorgenti del portale Sismica Sicilia", testo, true); - mail.setTo(to); - ServiceContext serviceContext = ServiceContextFactory.getInstance(request); - Role role = RoleLocalServiceUtil.getRole(serviceContext.getCompanyId(), RoleConstants.ADMINISTRATOR); - User user = UserLocalServiceUtil.getRoleUsers(role.getRoleId(), 0, 1).get(0); - serviceContext.setUserId(user.getUserId()); - Message message = new Message(); - message.put("serviceContext", serviceContext); - message.put("mode", MailManagerConstants.MESSAGING_SEND_MODE_ASYNC); - message.setPayload(mail); - MessageBusUtil.sendMessage(DestinationNames.SEND_MAIL, message); - registra(request, "Richiesta - nome: " + nome + ", cognome: " + cognome + ", email: " + email + ", cartella: " - + link + StringPool.FORWARD_SLASH + digest); - return true; - } - - private static String getLink(HttpServletRequest request, Date date) { - - return digest(request, new SimpleDateFormat("dd/MM/yyyy").format(date)); - } - - private static String digest(HttpServletRequest request, String text) { - - return DigesterUtil.digestHex("md5", getSeed(request) + text); - } - - private static void registra(HttpServletRequest request, String text) throws IOException { - - FileWriter writer = new FileWriter(PropsUtil.get("liferay.home") + "/logs/sorgenti.log", true); - writer.write(new SimpleDateFormat("yyyy-MM-dd hh:mm:ss").format(new Date()) + " [" + request.getRemoteAddr() - + "] " + text + StringPool.NEW_LINE); - writer.close(); - } - - // La macchina di produzione non ha il supporto per mime, aggiriamo per i casi che ci interessano - private static String probeContentType(File file) { - - try { - String extension = FilenameUtils.getExtension(file.getName()).toLowerCase(); - switch (extension) { - case "pdf": - return ContentTypes.APPLICATION_PDF; - case "zip": - return ContentTypes.APPLICATION_ZIP; - default: - return Files.probeContentType(file.toPath()); - } - } catch (IOException e) { - return ContentTypes.APPLICATION_OCTET_STREAM; - } - } -} diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/AllegatiPraticaPortlet.java b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/AllegatiPraticaPortlet.java index 02e39c84..d730e560 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/AllegatiPraticaPortlet.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/AllegatiPraticaPortlet.java @@ -2,6 +2,7 @@ package it.tref.liferay.portos.fe.portlet; import it.mwg.sismica.bo.shared.util.DocumentiPraticaUtil; import it.tref.liferay.portos.bo.model.DocPratica; +import it.tref.liferay.portos.bo.service.ConfigurazioneLocalServiceUtil; import it.tref.liferay.portos.bo.service.DocPraticaLocalServiceUtil; import it.tref.liferay.portos.bo.service.DocPraticaServiceUtil; import it.tref.liferay.portos.bo.shared.bean.FirmeBean; @@ -230,12 +231,12 @@ public class AllegatiPraticaPortlet extends MVCPortlet { String id = resourceRequest.getResourceID(); try { - if ("downloadAllDocPratica".equals(id) || "downloadAllDocPraticas".equals(id)) { + if ("downloadAllDocPratica".equals(id)) { long intPraticaId = ParamUtil.getLong(resourceRequest, "intPraticaId"); long classPk = ParamUtil.getLong(resourceRequest, "classPk"); String comingFrom = ParamUtil.getString(resourceRequest, "comingFrom"); String type = ParamUtil.getString(resourceRequest, "type"); - List docs = new ArrayList<>(); + List docs; if (Validator.isNull(comingFrom)) { docs = DocPraticaLocalServiceUtil.findByClassPk(classPk); } else if ("page_in_allegati".equals(comingFrom) || "page_va_allegati".equals(comingFrom)) { @@ -243,7 +244,7 @@ public class AllegatiPraticaPortlet extends MVCPortlet { docs = DocPraticaLocalServiceUtil.findByIntPratica_ClassPkEqual_Tipologie(intPraticaId, classPk, tipologieAllegati); } else { - List tipologieAllegati = new ArrayList(); + List tipologieAllegati; if ("page_geologica".equals(comingFrom) || "ag".equals(type)) { tipologieAllegati = DocumentiPraticaUtil.getDocGeologo(); } else if ("page_allegati".equals(comingFrom) || "ad".equals(type)) { @@ -252,9 +253,10 @@ public class AllegatiPraticaPortlet extends MVCPortlet { tipologieAllegati = DocumentiPraticaUtil.getDocFineLavori(); } else if ("page_collaudo".equals(comingFrom)) { tipologieAllegati = DocumentiPraticaUtil.getDocCollaudo(); + } else { + tipologieAllegati = new ArrayList(); } - docs = DocPraticaLocalServiceUtil.findByIntPratica_ClassPk_Tipologie(intPraticaId, classPk, - tipologieAllegati); + docs = DocPraticaLocalServiceUtil.findByIntPratica_Tipologie(intPraticaId, tipologieAllegati); } ZipWriter zipWriter = ZipWriterFactoryUtil.getZipWriter(); for (DocPratica doc : docs) { @@ -269,6 +271,9 @@ public class AllegatiPraticaPortlet extends MVCPortlet { String s = new String(fileEntry.getTitle().getBytes(StandardCharsets.UTF_8)); byte[] b = s.getBytes(StandardCharsets.ISO_8859_1); String name = new String(b, StandardCharsets.ISO_8859_1); + if (doc.isRimosso()) { + name = "rimossi_" + doc.getClassPk() + '/' + name; + } zipWriter.addEntry(name, inputStream); } finally { if (inputStream != null) { @@ -279,10 +284,15 @@ public class AllegatiPraticaPortlet extends MVCPortlet { resourceResponse.reset(); File file = zipWriter.getFile(); byte[] data = Files.readAllBytes(file.toPath()); + file.delete(); resourceResponse.setContentType(ContentTypes.APPLICATION_ZIP); - resourceResponse.addProperty(HttpHeaders.CACHE_CONTROL, "max-age=3600, must-revalidate"); + if (ConfigurazioneLocalServiceUtil.isProduction()) { + resourceResponse.addProperty(HttpHeaders.CACHE_CONTROL, "max-age=3600, must-revalidate"); + } else { + resourceResponse.addProperty(HttpHeaders.CACHE_CONTROL, "no-store"); + } resourceResponse.addProperty(HttpHeaders.CONTENT_DISPOSITION, - "attachment; filename=\"" + file.getName() + StringPool.QUOTE); + "attachment; filename=\"" + file.getName() + '"'); resourceResponse.setContentLength(data.length); resourceResponse.getPortletOutputStream().write(data); resourceResponse.getPortletOutputStream().flush(); diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/FascicoloFePortlet.java b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/FascicoloFePortlet.java index 34daf6c1..e449381f 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/FascicoloFePortlet.java +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/portlet/FascicoloFePortlet.java @@ -1321,11 +1321,11 @@ public class FascicoloFePortlet extends MVCPortlet { // ADT: BUG FE ID=30 - CALCOLO IMPORTO, controllo non effettuato se spese esente boolean esenteSpeseIstruttoria = DettPraticaLocalServiceUtil.getDettPratica(dettPraticaId) .isNormEsenteSpese(); - if (esenteSpeseIstruttoria || (totale != 0)) { + if (esenteSpeseIstruttoria || (totale != 0) || aggiorna) { DettPraticaServiceUtil.pagaInvia(dettPraticaId, request, response); } else { _log.error("pagaInvia - Riscontrato errore di congruenza pagamenti per dettPraticaId = " - + dettPraticaId); + + dettPraticaId + ", totale = " + totale); throw new PortalException("Compilare sezione Spese Istruttoria"); } } else { diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/web.xml b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/web.xml index 4c63ef09..fe6c9ee4 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/web.xml +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/web.xml @@ -2,11 +2,11 @@ - SorgentiServlet - it.mwg.sismica.fe.servlet.SorgentiServlet + Instrumentation + it.mwg.sismica.fe.servlet.Instrumentation - SorgentiServlet - /sorgenti-paesaggistica/* + Instrumentation + /instrumentation/* \ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/view_accordion.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/view_accordion.jsp index 40f4e231..0205fc59 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/view_accordion.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/view_accordion.jsp @@ -1,3 +1,4 @@ +<%@page import="java.util.ArrayList"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.dao.orm.QueryUtil"%> <%@page import="com.liferay.portal.kernel.portlet.LiferayWindowState"%> @@ -50,13 +51,13 @@ if ("allegati_geologici".equals(tipoAllegati)) { tipologiaAllegati = DocumentiPraticaUtil.getDocCollaudo(); type = "acl"; } else { - tipologiaAllegati = DocumentiPraticaUtil.getDocDomanda(); + tipologiaAllegati = new ArrayList(DocumentiPraticaUtil.getDocDomanda()); //BUG BO ID=9 (ANNULLA ISTANZA) tipologiaAllegati.add(DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_ANNULLAMENTO_FASCICOLO); type = "ad"; } %> - + diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/fascicolo_action.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/fascicolo_action.jsp index e3c85b4e..3eed818c 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/fascicolo_action.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/fascicolo_action.jsp @@ -41,7 +41,8 @@ String randomId = StringUtil.randomId() + StringPool.UNDERLINE + intPratica.getI + && intPratica.getStatus() != WorkflowConstants.STATUS_INCOMPLETE && !intPratica.getSospesa() + && IntPraticaLocalServiceUtil.getTipiProcedure().containsKey(intPratica.getTipoProcedura()) %>"> diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/navigator/domanda/page_dettagli_principali.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/navigator/domanda/page_dettagli_principali.jsp index fa8de951..cbce2ff8 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/navigator/domanda/page_dettagli_principali.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/navigator/domanda/page_dettagli_principali.jsp @@ -1,6 +1,6 @@ +<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="it.tref.liferay.portos.bo.service.DiocesiLocalServiceUtil"%> <%@page import="it.tref.liferay.portos.bo.model.Diocesi"%> -<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="it.tref.liferay.portos.bo.shared.util.ConfigurazioneConstants"%> <%@page import="it.tref.liferay.portos.bo.service.ConfigurazioneLocalServiceUtil"%> <%@page import="it.tref.liferay.portos.bo.shared.util.PortletKeys"%> @@ -56,6 +56,8 @@ String hide10 = intPratica.getTipoProcedura().equalsIgnoreCase(Constants.PROCEDU || intPratica.getTipoProcedura().equalsIgnoreCase(Constants.PROCEDURA_P10) ? "hideSection" : ""; boolean showDiocesi = intPratica.getTipoProcedura().equalsIgnoreCase(Constants.PROCEDURA_Q1) || intPratica.getTipoProcedura().equalsIgnoreCase(Constants.PROCEDURA_Q2); +String originMappe = ConfigurazioneLocalServiceUtil.isProduction() ? + PortalUtil.getPortalURL(request) : "https://paesaggistica.sicilia.it"; %> @@ -288,42 +290,45 @@ document.addEventListener('DOMContentLoaded', function(event) { window.addEventListener('message', messageListener, false); }); function messageListener(event) { - try { - var data = JSON.parse(event.data); - } catch (e) { - return; - } - var trasferiti = []; - var lat = ''; - var lng = ''; - var name = ''; - for (key in data) { - var el = null; - switch (key) { - case 'latitudine': - lat = data[key]; - break; - case 'longitudine': - lng = data[key]; - break; - case 'paesaggioLocale': - case 'livelloDiTutela': - case 'vincoli': - data[key] = duplicati(data[key]); - // Fall through - default: - el = document.getElementById('input_' + key); + if (event.origin == '<%= originMappe %>') { + try { + var data = JSON.parse(event.data); + } catch (e) { + return; } - if (null !== el) { - el.value = data[key]; - trasferiti.push(key); + var lat = ''; + var lng = ''; + for (key in data) { + var name = ''; + switch (key) { + case 'latitudine': + lat = data[key]; + break; + case 'longitudine': + lng = data[key]; + break; + case 'paesaggioLocale': + name = 'input_contestoPaesaggistico'; + data[key] = duplicati(data[key]); + break; + case 'livelloDiTutela': + case 'vincoli': + data[key] = duplicati(data[key]); + // Fall through + default: + name = 'input_' + key; + } + if (name !== '') { + var el = document.getElementById('' + name); + if (null !== el) { + el.value = data[key]; + } + } + } + if (lat.length > 0 && lng.length > 0) { + var el = document.getElementById('localizzazioneGeografica'); + el.value = lat + '|' + lng + '|8'; } - } - var el = document.getElementById('localizzazioneGeografica'); - el.value = lat + '|' + lng + '|8'; - trasferiti.push('localizzazioneGeografica'); - if (trasferiti.length > 0) { - console.log('Trasferiti correttamente: ' + trasferiti.join(', ')); } } diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_columns_generic.jspf b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_columns_generic.jspf index 54c284b6..51a4f351 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_columns_generic.jspf +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_columns_generic.jspf @@ -307,7 +307,7 @@ if (lastDettPratica == null) { <%= LanguageUtil.get(pageContext, "label_procedura_" + intPratica.getTipoProcedura()) + ") " + LanguageUtil.get(pageContext, "tipo_procedura_" + intPratica.getTipoProcedura()) %>

- <%= lastDettPratica.getDescLongIntervento() %> + <%= HtmlUtil.escape(lastDettPratica.getDescLongIntervento()) %> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> <%@page import="com.liferay.portal.kernel.servlet.ServletContextPool"%> @@ -190,7 +191,7 @@ String hide10 = (intPratica.getTipoProcedura().equalsIgnoreCase(Constants.PROCED
- <%= BeanPropertiesUtil.getString(dettPratica, "descLongIntervento") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "descLongIntervento")) %>
diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_riepilogo.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_riepilogo.jsp index 2d0eb227..d47a67c8 100644 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_riepilogo.jsp +++ b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/fascicolofe/view_fascicolo_riepilogo.jsp @@ -1,3 +1,4 @@ +<%@page import="com.liferay.portal.kernel.util.HtmlUtil"%> <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="com.liferay.portal.kernel.bean.BeanPropertiesUtil"%> <%@page import="com.liferay.portal.kernel.servlet.ServletContextPool"%> @@ -197,7 +198,7 @@ String hide10 = (intPratica.getTipoProcedura().equals(Constants.PROCEDURA_Q10)
- <%= BeanPropertiesUtil.getString(dettPratica, "descLongIntervento") %> + <%= HtmlUtil.escape(BeanPropertiesUtil.getString(dettPratica, "descLongIntervento")) %>
diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/footer.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/footer.jsp deleted file mode 100644 index f26d9923..00000000 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/footer.jsp +++ /dev/null @@ -1,6 +0,0 @@ -<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> - - - - - \ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/form.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/form.jsp deleted file mode 100644 index e708ea37..00000000 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/form.jsp +++ /dev/null @@ -1,33 +0,0 @@ -<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> -<%@ include file="/html/sorgenti/header.jsp"%> -
-
-

Sorgenti del portale Paesaggistica Sicilia

-
Compila il form sottostante e riceverai per email il collegamento per scaricare - i sorgenti del portale Paesaggistica.
-
-
-
-
-
- - - - - - - - - - - - - - - - -
Nome
Cognome
E-mail
-
-
-
-<%@ include file="/html/sorgenti/footer.jsp"%> diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/header.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/header.jsp deleted file mode 100644 index 62775c2a..00000000 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/header.jsp +++ /dev/null @@ -1,22 +0,0 @@ -<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> -<%@page import="com.liferay.portal.kernel.util.ParamUtil" %> - - - -Sorgenti del portale Paesaggistica Sicilia - - - - - -
-
-
- Regione Siciliana -
-
- -
-
-
\ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/invio_ko.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/invio_ko.jsp deleted file mode 100644 index 944329c1..00000000 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/invio_ko.jsp +++ /dev/null @@ -1,10 +0,0 @@ -<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> -<%@ include file="/html/sorgenti/header.jsp"%> -
-
- Si è verificato un errore durante l'inzio di una mail all'indirizzo - <%= ParamUtil.getString(request, "email") %>

- Ti invitiamo a riprovare tra qualche minuto. -
-
-<%@ include file="/html/sorgenti/footer.jsp"%> \ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/invio_ok.jsp b/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/invio_ok.jsp deleted file mode 100644 index 3c6562c8..00000000 --- a/liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/sorgenti/invio_ok.jsp +++ /dev/null @@ -1,10 +0,0 @@ -<%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> -<%@ include file="/html/sorgenti/header.jsp"%> -
-
- È stata inviata una mail all'indirizzo - <%= ParamUtil.getString(request, "email") %> - contente l'indirizzo per scaricare i sorgenti del portale Paesaggistica di Regione Siciliana -
-
-<%@ include file="/html/sorgenti/footer.jsp"%> \ No newline at end of file diff --git a/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/.project b/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/.project index 44a59678..bcb5181d 100644 --- a/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/.project +++ b/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/.project @@ -34,4 +34,15 @@ org.eclipse.wst.jsdt.core.jsNature org.apache.ivyde.eclipse.ivynature + + + 1647533317507 + + 30 + + org.eclipse.core.resources.regexFilterMatcher + node_modules|.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__ + + + diff --git a/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/docroot/WEB-INF/src/it/mwg/sicilia/sue/api/v1/command/impl/GetSourceCode.java b/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/docroot/WEB-INF/src/it/mwg/sicilia/sue/api/v1/command/impl/GetSourceCode.java index 7d5f70b6..e3c25391 100644 --- a/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/docroot/WEB-INF/src/it/mwg/sicilia/sue/api/v1/command/impl/GetSourceCode.java +++ b/liferay-plugins-sdk-6.2/portlets/sicilia-sue-connector-portlet/docroot/WEB-INF/src/it/mwg/sicilia/sue/api/v1/command/impl/GetSourceCode.java @@ -112,7 +112,9 @@ public class GetSourceCode extends Command { String fileName = sourceUri.relativize(inputFile.toURI()).getPath(); zipWriter.addEntry(fileName, output); } - byte[] bytes = Files.readAllBytes(zipWriter.getFile().toPath()); + File file = zipWriter.getFile(); + byte[] bytes = Files.readAllBytes(file.toPath()); + file.delete(); response.setContentType(ContentTypes.APPLICATION_ZIP); response.addHeader(HttpHeaders.CONTENT_DISPOSITION, "attachment; filename=\"sourceCode.zip\""); response.setContentLength(bytes.length); diff --git a/liferay-plugins-sdk-6.2/shared/portos-bo-shared/src/it/mwg/sismica/bo/shared/util/DocumentiPraticaUtil.java b/liferay-plugins-sdk-6.2/shared/portos-bo-shared/src/it/mwg/sismica/bo/shared/util/DocumentiPraticaUtil.java index 6f5fc4a0..52080193 100644 --- a/liferay-plugins-sdk-6.2/shared/portos-bo-shared/src/it/mwg/sismica/bo/shared/util/DocumentiPraticaUtil.java +++ b/liferay-plugins-sdk-6.2/shared/portos-bo-shared/src/it/mwg/sismica/bo/shared/util/DocumentiPraticaUtil.java @@ -73,12 +73,12 @@ public class DocumentiPraticaUtil { public static final String TIPOLOGIA_ALLEGATO_VARIAZIONE_SOGGETTO = "VS"; public static final String TIPOLOGIA_ALLEGATO_ANNULLAMENTO_FASCICOLO = "AI"; - private static final List docDomanda = new ArrayList(); - private static final Map tipiDocDomanda = new LinkedHashMap(); + private static final List DOC_DOMANDA = new ArrayList(); + private static final Map TIPI_DOC_DOMANDA = new LinkedHashMap(); private static void addDocDomanda(String tipo) { - docDomanda.add(tipo); - tipiDocDomanda.put(tipo, LanguageUtil.get(LocaleUtil.ITALIAN, "label-documenti-tipologia-" + tipo)); + DOC_DOMANDA.add(tipo); + TIPI_DOC_DOMANDA.put(tipo, LanguageUtil.get(LocaleUtil.ITALIAN, "label-documenti-tipologia-" + tipo)); } static { @@ -108,11 +108,11 @@ public class DocumentiPraticaUtil { } public static List getDocDomanda() { - return docDomanda; + return DOC_DOMANDA; } public static Map getTipiDocDomanda() { - return tipiDocDomanda; + return TIPI_DOC_DOMANDA; } public static List getDocObbligatori() { diff --git a/liferay-plugins-sdk-6.2/z.zip b/liferay-plugins-sdk-6.2/z.zip new file mode 100644 index 00000000..5c9e13c3 Binary files /dev/null and b/liferay-plugins-sdk-6.2/z.zip differ