Sfoglia il codice sorgente

Add firma solo per COMMITTENTE

feature/filtro-ospedaliera
abianchi7701 2 settimane fa
parent
commit
2faef1d916
  1. BIN
      liferay-plugins-sdk-6.2/dist/portos-audit-shared-6.2.0.1.jar
  2. BIN
      liferay-plugins-sdk-6.2/dist/portos-bo-shared-6.2.0.1.jar
  3. BIN
      liferay-plugins-sdk-6.2/dist/portos-kaleo-shared-6.2.0.1.jar
  4. BIN
      liferay-plugins-sdk-6.2/dist/portos-mail-manager-shared-6.2.0.1.jar
  5. BIN
      liferay-plugins-sdk-6.2/dist/portos-report-shared-6.2.0.1.jar
  6. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/axis.jar
  7. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/commons-logging.jar
  8. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/jaxrpc.jar
  9. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/jstl-api.jar
  10. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/jstl-impl.jar
  11. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/log4j.jar
  12. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-audit-shared.jar
  13. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-bo-portlet-service.jar
  14. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-bo-shared.jar
  15. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-kaleo-shared.jar
  16. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-mail-manager-shared.jar
  17. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-report-shared.jar
  18. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/util-bridges.jar
  19. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/util-taglib.jar
  20. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/wsdl4j.jar
  21. BIN
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/xml-apis.jar
  22. 1
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/util/AsseverazioniUtil.java
  23. 51
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/util/ValidazionePraticaUtil.java
  24. 4
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/src/service.properties
  25. 572
      liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/tld/c.tld
  26. BIN
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-bo-portlet-service.jar
  27. BIN
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-bo-shared.jar
  28. BIN
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-mail-manager-shared.jar
  29. BIN
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-report-shared.jar
  30. 46
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/util/FascicoloFEUtil.java
  31. 162
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/allegati_action.jspf
  32. 2
      liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/view.jsp
  33. 4
      liferay-plugins-sdk-6.2/shared/portos-bo-shared/src/it/tref/liferay/portos/bo/shared/util/DocumentiPraticaUtil.java

BIN
liferay-plugins-sdk-6.2/dist/portos-audit-shared-6.2.0.1.jar vendored

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/dist/portos-bo-shared-6.2.0.1.jar vendored

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/dist/portos-kaleo-shared-6.2.0.1.jar vendored

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/dist/portos-mail-manager-shared-6.2.0.1.jar vendored

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/dist/portos-report-shared-6.2.0.1.jar vendored

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/axis.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/commons-logging.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/jaxrpc.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/jstl-api.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/jstl-impl.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/log4j.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-audit-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-bo-portlet-service.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-bo-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-kaleo-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-mail-manager-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/portos-report-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/util-bridges.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/util-taglib.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/wsdl4j.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/lib/xml-apis.jar

File binario non mostrato.

1
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/util/AsseverazioniUtil.java

@ -137,6 +137,7 @@ public class AsseverazioniUtil {
put(DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_A15,
Arrays.asList(TipoSoggettoUtil.GEOLOGO, TipoSoggettoUtil.DIRETTORE_LAVORI));
put(DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_A29, Arrays.asList(TipoSoggettoUtil.DIRETTORE_LAVORI));
put(DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_DELEGA, Arrays.asList(TipoSoggettoUtil.COMMITTENTE));
// Domanda
put(ASSEVERAZIONI_DOMANDA, Arrays.asList(TipoSoggettoUtil.COMMITTENTE, TipoSoggettoUtil.DIRETTORE_LAVORI,
TipoSoggettoUtil.PROGETTISTA, TipoSoggettoUtil.DITTA, TipoSoggettoUtil.GEOLOGO, TipoSoggettoUtil.COLLAUDATORE));

51
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/service/it/tref/liferay/portos/bo/util/ValidazionePraticaUtil.java

@ -37,6 +37,7 @@ import java.util.Set;
import javax.servlet.http.HttpServletResponse;
import org.apache.commons.lang.StringUtils;
import org.apache.http.HttpResponse;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.mime.HttpMultipartMode;
@ -418,7 +419,7 @@ public class ValidazionePraticaUtil {
public static List<String> notCompletedSection(String section, long dettPraticaId) throws PortalException,
SystemException {
_log.info("Inizio controllo allegati");
switch (section) {
case SezioniUtil.SEZIONE_DETTAGLI_PRINCIPALI:
return notCompletedDettagliPrincipali(dettPraticaId);
@ -938,7 +939,7 @@ public class ValidazionePraticaUtil {
}
private static List<String> notCompletedSezioniAllegati(long dettPraticaId) throws PortalException, SystemException {
_log.info("Inizio controllo allegati");
DettPratica dettPratica = DettPraticaServiceUtil.getDettPratica(dettPraticaId);
long intPraticaId = dettPratica.getIntPraticaId();
IntPratica intPratica = IntPraticaLocalServiceUtil.getIntPratica(intPraticaId);
@ -946,9 +947,11 @@ public class ValidazionePraticaUtil {
List<String> tipologiaAllegati = DocumentiPraticaUtil.getDocObbligatoriDomanda(intPratica.getTipoProcedura());
Set<String> firmeTotali = new HashSet<>();
for (String codiceDoc : tipologiaAllegati) {
_log.info("Tipologia di allegato obbligatorio ---> "+ codiceDoc);
if (isDocPraticaRequired(dettPratica, codiceDoc)) {
List<DocPratica> docs = DocPraticaLocalServiceUtil.getValidTmpByIntPratica_Tipologia(intPraticaId,
codiceDoc, QueryUtil.ALL_POS, QueryUtil.ALL_POS);
_log.info("la lista di docs e' vuota ?" + docs.isEmpty());
if (docs.isEmpty()) {
// Ci dev'essere almeno un allegato per ogni tipologia obbligatoria
notCompleted.add("Nessun Allegato per " + codiceDoc + " - "
@ -956,7 +959,8 @@ public class ValidazionePraticaUtil {
}
for (DocPratica doc : docs) {
// Se il documento proviene da una dett precedente non viene controllato perche si presuppone che
// sia stata già verificato
// sia stata già  verificato
_log.info("il documento in analisi e' di tipo: "+ codiceDoc );
if (!doc.getClassName().equalsIgnoreCase(DettPratica.class.getName())
|| doc.getClassPk() != dettPraticaId) {
continue;
@ -991,13 +995,15 @@ public class ValidazionePraticaUtil {
notCompleted.add("A17 firme obbligatorie mancanti");
}
} else if (codiceDoc.equalsIgnoreCase(DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_DELEGA)) {
_log.info("siamo nel controllo validita a98");
if (!isA98Valid(dettPratica, intPraticaId, signatures)) {
notCompleted.add("Allegato Delega firme obbligatorie mancanti");
notCompleted.add("Allegato Delega firma obbligatoria dell' committente mancante");
}
} else if (codiceDoc.equalsIgnoreCase(DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_A29)) {
if (!signatures.contains(dettPratica.getUserName().toLowerCase())) {
List<String> firmeCommittenti = getSignaturePerSubject(intPraticaId, signatures,
TipoSoggettoUtil.COMMITTENTE, doc.getClassPk());
if (firmeCommittenti.isEmpty()) {
notCompleted.add("A29 firma del titolare digitale o del committente richiesta");
}
@ -1007,6 +1013,7 @@ public class ValidazionePraticaUtil {
notCompleted.add(codiceDoc + " non firmato");
} else if (!isAllRequiredValid(codiceDoc, intPraticaId, signatures,
TipoSoggettoUtil.getAllSubjects(), doc)) {
_log.info("non siamo entrati nel controllo validita a98");
notCompleted.add(codiceDoc + " firme obbligatorie mancanti");
}
}
@ -1175,19 +1182,43 @@ public class ValidazionePraticaUtil {
// Allegato Delega richiesto se il titolare Digitale pratica non è fra i committenti
public static boolean isA98Required(DettPratica dettPratica) throws SystemException, PortalException {
if (IntPraticaLocalServiceUtil.getIntPratica(dettPratica.getIntPraticaId()).isPraticaOspedaliera()) {
_log.info("Is ospedaliera");
return true;
}
_log.info("Is not ospedaliera");
return !SoggettiUtil.isTitolareInCommittenti(dettPratica.getIntPraticaId());
}
public static boolean isA98Valid(DettPratica dettPratica, long intPraticaId, List<String> signatures)
throws SystemException, PortalException {
if (SoggettiUtil.isTitolareInCommittenti(intPraticaId)) {
return true;
} else {
return !signatures.isEmpty();
}
if (IntPraticaLocalServiceUtil.getIntPratica(intPraticaId).isPraticaOspedaliera()) {
_log.info("la pratica e' ospedaliera" );
List<Soggetto> committenti = SoggettoLocalServiceUtil.getValidTmpByDettPratica_TipologiaSoggetto(dettPratica.getDettPraticaId(),
TipoSoggettoUtil.COMMITTENTE);
for (Soggetto committente : committenti) {
_log.info("Committente ---> "+ committente );
for (String signature : signatures) {
_log.info("Signature ---> "+ signature);
if(StringUtils.equals(signature,committente.getCodiceFiscale())){
_log.info("Everything went well");
return true;
}
}
}
}
_log.info("Everything imploded");
return !signatures.isEmpty();
}
public static boolean isAllRequiredValid(String codiceDoc, long intPraticaId, List<String> signatures,
List<String> tipologiaSoggetti, DocPratica docPratica) throws SystemException, PortalException {

4
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=2985
build.date=1722424256719
build.number=3004
build.date=1741363123588
build.auto.upgrade=true
##

572
liferay-plugins-sdk-6.2/portlets/portos-bo-portlet/docroot/WEB-INF/tld/c.tld

@ -1,572 +0,0 @@
<?xml version="1.0" encoding="UTF-8" ?>
<taglib xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-jsptaglibrary_2_1.xsd"
version="2.1">
<description>JSTL 1.2 core library</description>
<display-name>JSTL core</display-name>
<tlib-version>1.2</tlib-version>
<short-name>c</short-name>
<uri>http://java.sun.com/jsp/jstl/core</uri>
<validator>
<description>
Provides core validation features for JSTL tags.
</description>
<validator-class>
org.apache.taglibs.standard.tlv.JstlCoreTLV
</validator-class>
</validator>
<tag>
<description>
Catches any Throwable that occurs in its body and optionally
exposes it.
</description>
<name>catch</name>
<tag-class>org.apache.taglibs.standard.tag.common.core.CatchTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
Name of the exported scoped variable for the
exception thrown from a nested action. The type of the
scoped variable is the type of the exception thrown.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Simple conditional tag that establishes a context for
mutually exclusive conditional operations, marked by
&lt;when&gt; and &lt;otherwise&gt;
</description>
<name>choose</name>
<tag-class>com.liferay.taglib.core.ChooseTag</tag-class>
<body-content>JSP</body-content>
</tag>
<tag>
<description>
Simple conditional tag, which evalutes its body if the
supplied condition is true and optionally exposes a Boolean
scripting variable representing the evaluation of this condition
</description>
<name>if</name>
<tag-class>com.liferay.taglib.core.IfTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
The test condition that determines whether or
not the body content should be processed.
</description>
<name>test</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
<type>boolean</type>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
resulting value of the test condition. The type
of the scoped variable is Boolean.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Scope for var.
</description>
<name>scope</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Retrieves an absolute or relative URL and exposes its contents
to either the page, a String in 'var', or a Reader in 'varReader'.
</description>
<name>import</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.ImportTag</tag-class>
<tei-class>org.apache.taglibs.standard.tei.ImportTEI</tei-class>
<body-content>JSP</body-content>
<attribute>
<description>
The URL of the resource to import.
</description>
<name>url</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
resource's content. The type of the scoped
variable is String.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Scope for var.
</description>
<name>scope</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
resource's content. The type of the scoped
variable is Reader.
</description>
<name>varReader</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the context when accessing a relative
URL resource that belongs to a foreign
context.
</description>
<name>context</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Character encoding of the content at the input
resource.
</description>
<name>charEncoding</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
The basic iteration tag, accepting many different
collection types and supporting subsetting and other
functionality
</description>
<name>forEach</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.ForEachTag</tag-class>
<tei-class>org.apache.taglibs.standard.tei.ForEachTEI</tei-class>
<body-content>JSP</body-content>
<attribute>
<description>
Collection of items to iterate over.
</description>
<name>items</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>java.lang.Object</type>
<deferred-value>
<type>java.lang.Object</type>
</deferred-value>
</attribute>
<attribute>
<description>
If items specified:
Iteration begins at the item located at the
specified index. First item of the collection has
index 0.
If items not specified:
Iteration begins with index set at the value
specified.
</description>
<name>begin</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>int</type>
</attribute>
<attribute>
<description>
If items specified:
Iteration ends at the item located at the
specified index (inclusive).
If items not specified:
Iteration ends when index reaches the value
specified.
</description>
<name>end</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>int</type>
</attribute>
<attribute>
<description>
Iteration will only process every step items of
the collection, starting with the first one.
</description>
<name>step</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>int</type>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
current item of the iteration. This scoped
variable has nested visibility. Its type depends
on the object of the underlying collection.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
status of the iteration. Object exported is of type
javax.servlet.jsp.jstl.core.LoopTagStatus. This scoped variable has nested
visibility.
</description>
<name>varStatus</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Iterates over tokens, separated by the supplied delimeters
</description>
<name>forTokens</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.ForTokensTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
String of tokens to iterate over.
</description>
<name>items</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
<type>java.lang.String</type>
<deferred-value>
<type>java.lang.String</type>
</deferred-value>
</attribute>
<attribute>
<description>
The set of delimiters (the characters that
separate the tokens in the string).
</description>
<name>delims</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
<type>java.lang.String</type>
</attribute>
<attribute>
<description>
Iteration begins at the token located at the
specified index. First token has index 0.
</description>
<name>begin</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>int</type>
</attribute>
<attribute>
<description>
Iteration ends at the token located at the
specified index (inclusive).
</description>
<name>end</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>int</type>
</attribute>
<attribute>
<description>
Iteration will only process every step tokens
of the string, starting with the first one.
</description>
<name>step</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>int</type>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
current item of the iteration. This scoped
variable has nested visibility.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the exported scoped variable for the
status of the iteration. Object exported is of
type
javax.servlet.jsp.jstl.core.LoopTag
Status. This scoped variable has nested
visibility.
</description>
<name>varStatus</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Like &lt;%= ... &gt;, but for expressions.
</description>
<name>out</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.OutTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
Expression to be evaluated.
</description>
<name>value</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Default value if the resulting value is null.
</description>
<name>default</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Determines whether characters &lt;,&gt;,&amp;,'," in the
resulting string should be converted to their
corresponding character entity codes. Default value is
true.
</description>
<name>escapeXml</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Subtag of &lt;choose&gt; that follows &lt;when&gt; tags
and runs only if all of the prior conditions evaluated to
'false'
</description>
<name>otherwise</name>
<tag-class>com.liferay.taglib.core.OtherwiseTag</tag-class>
<body-content>JSP</body-content>
</tag>
<tag>
<description>
Adds a parameter to a containing 'import' tag's URL.
</description>
<name>param</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.ParamTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
Name of the query string parameter.
</description>
<name>name</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Value of the parameter.
</description>
<name>value</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Redirects to a new URL.
</description>
<name>redirect</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.RedirectTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
The URL of the resource to redirect to.
</description>
<name>url</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the context when redirecting to a relative URL
resource that belongs to a foreign context.
</description>
<name>context</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Removes a scoped variable (from a particular scope, if specified).
</description>
<name>remove</name>
<tag-class>org.apache.taglibs.standard.tag.common.core.RemoveTag</tag-class>
<body-content>empty</body-content>
<attribute>
<description>
Name of the scoped variable to be removed.
</description>
<name>var</name>
<required>true</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Scope for var.
</description>
<name>scope</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Sets the result of an expression evaluation in a 'scope'
</description>
<name>set</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.SetTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
Name of the exported scoped variable to hold the value
specified in the action. The type of the scoped variable is
whatever type the value expression evaluates to.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Expression to be evaluated.
</description>
<name>value</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<deferred-value>
<type>java.lang.Object</type>
</deferred-value>
</attribute>
<attribute>
<description>
Target object whose property will be set. Must evaluate to
a JavaBeans object with setter property property, or to a
java.util.Map object.
</description>
<name>target</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the property to be set in the target object.
</description>
<name>property</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Scope for var.
</description>
<name>scope</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Creates a URL with optional query parameters.
</description>
<name>url</name>
<tag-class>org.apache.taglibs.standard.tag.rt.core.UrlTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
Name of the exported scoped variable for the
processed url. The type of the scoped variable is
String.
</description>
<name>var</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
Scope for var.
</description>
<name>scope</name>
<required>false</required>
<rtexprvalue>false</rtexprvalue>
</attribute>
<attribute>
<description>
URL to be processed.
</description>
<name>value</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
<attribute>
<description>
Name of the context when specifying a relative URL
resource that belongs to a foreign context.
</description>
<name>context</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
</attribute>
</tag>
<tag>
<description>
Subtag of &lt;choose&gt; that includes its body if its
condition evalutes to 'true'
</description>
<name>when</name>
<tag-class>com.liferay.taglib.core.WhenTag</tag-class>
<body-content>JSP</body-content>
<attribute>
<description>
The test condition that determines whether or not the
body content should be processed.
</description>
<name>test</name>
<required>true</required>
<rtexprvalue>true</rtexprvalue>
<type>boolean</type>
</attribute>
</tag>
</taglib>

BIN
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-bo-portlet-service.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-bo-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-mail-manager-shared.jar

File binario non mostrato.

BIN
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/lib/portos-report-shared.jar

File binario non mostrato.

46
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/WEB-INF/src/it/tref/liferay/portos/fe/util/FascicoloFEUtil.java

@ -1,9 +1,28 @@
package it.tref.liferay.portos.fe.util;
import com.liferay.portal.kernel.log.Log;
import com.liferay.portal.kernel.log.LogFactoryUtil;
import com.liferay.portal.model.User;
import com.liferay.portal.service.ServiceContext;
import com.liferay.portal.service.ServiceContextFactory;
import com.liferay.portal.service.UserLocalServiceUtil;
import it.tref.liferay.portos.bo.model.DettPratica;
import it.tref.liferay.portos.bo.model.IntPratica;
import it.tref.liferay.portos.bo.model.Soggetto;
import it.tref.liferay.portos.bo.service.DettPraticaLocalServiceUtil;
import it.tref.liferay.portos.bo.service.IntPraticaLocalServiceUtil;
import it.tref.liferay.portos.bo.service.SoggettoLocalServiceUtil;
import it.tref.liferay.portos.bo.shared.util.Constants;
import it.tref.liferay.portos.bo.shared.util.DocumentiPraticaUtil;
import it.tref.liferay.portos.bo.shared.util.TipoSoggettoUtil;
import java.util.List;
import javax.portlet.RenderRequest;
public class FascicoloFEUtil {
private static final Log _log = LogFactoryUtil.getLog(FascicoloFEUtil.class);
public static boolean isDestinazioneEnabled(boolean destinazioneClasse, boolean disabledInput,
boolean enabledByIntegrazione, boolean alertClassi, boolean isPraticaOspedaliera){
@ -23,6 +42,31 @@ public class FascicoloFEUtil {
}
}
public static boolean isA98PraticaOspidaliera(String codiceDoc, long intPraticaId, long userId){
_log.info("isA98PraticaOspidaliera method");
try {
User user = UserLocalServiceUtil.getUser(userId);
IntPratica intpratica = IntPraticaLocalServiceUtil.getIntPratica(intPraticaId);
if (DocumentiPraticaUtil.TIPOLOGIA_ALLEGATO_DELEGA.equals(codiceDoc) &&
intpratica.isPraticaOspedaliera()){
DettPratica dettPratica = DettPraticaLocalServiceUtil.getLastEditableByIntPratica(intPraticaId);
if (dettPratica==null){
dettPratica= DettPraticaLocalServiceUtil.getLastCompletedByIntPratica(intPraticaId);
}
List<Soggetto> committenti = SoggettoLocalServiceUtil.getValidTmpByDettPratica_TipologiaSoggetto(dettPratica.getDettPraticaId(),
TipoSoggettoUtil.COMMITTENTE);
for (Soggetto committente : committenti) {
if(committente.getCodiceFiscale().equals(user.getScreenName())){
return true; //è il committente
}
}
return false; //non è il committente
}
} catch (Exception e) {
_log.error(e,e);
}
return true; //è un altro documento
}
}

162
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/allegati_action.jspf

@ -12,96 +12,100 @@ boolean canSignGeoDocsAll = comingFromGeologica && hasDelegaFirma;
<liferay-ui:icon-menu icon="" showExpanded="<%=true %>" showWhenSingleIcon="<%=true%>">
<c:if test="<%= docPratica.getClassPk()==classPk && hasDelegaFirma && (!disabledInput || canSignGeoDocsAll)%>">
<%
if (firme.firmaIsPresent(user.getScreenName())) {
if (firme.firmaIsAnnullabile(user.getScreenName())) {
if(FascicoloFEUtil.isA98PraticaOspidaliera(codiceDoc, intPraticaId, themeDisplay.getUserId())){
if (firme.firmaIsPresent(user.getScreenName())) {
if (firme.firmaIsAnnullabile(user.getScreenName())) {
%>
<portlet:actionURL name="rimuoviFirma" var="rimuoviFirmaURL">
<portlet:param name="docPraticaId" value="<%= String.valueOf(docPraticaId) %>" />
<portlet:param name="comingFrom" value="<%= comingFrom %>" />
</portlet:actionURL>
<div title="Rimuovi firma" class="tooltip-info">
<liferay-ui:icon id='<%="remove_" + docPraticaId %>' linkCssClass="btn btn-danger" iconCssClass="fa fa-close" message="Rimuovi firma" url="javascript:void(0)"/>
</div>
<portlet:actionURL name="rimuoviFirma" var="rimuoviFirmaURL">
<portlet:param name="docPraticaId" value="<%= String.valueOf(docPraticaId) %>" />
<portlet:param name="comingFrom" value="<%= comingFrom %>" />
</portlet:actionURL>
<aui:script use="aui-base,aui-io-request">
A.one('<%="#"+renderResponse.getNamespace()+"remove_"+docPraticaId %>').on(
'click',
function(event) {
event.preventDefault();
Loading.start();
A.io.request(
'<%=rimuoviFirmaURL%>',
{
on: {
failure: function() {
alert('impossibile rimuovere la firma!');
},
success: function(event, id, obj) {
window.parent.Liferay.fire('allegati-<%=comingFrom%>-open');
if( "<%= comingFrom %>" == "page_allegati" || "<%= comingFrom %>" == "page_geologica"){
<%=refreshAll%>
}else{
Liferay.fire('allegati-"+comingFrom+"-open');
Liferay.Portlet.refresh("#p_p_id<portlet:namespace/>");
<div title="Rimuovi firma" class="tooltip-info">
<liferay-ui:icon id='<%="remove_" + docPraticaId %>' linkCssClass="btn btn-danger" iconCssClass="fa fa-close" message="Rimuovi firma" url="javascript:void(0)"/>
</div>
<aui:script use="aui-base,aui-io-request">
A.one('<%="#"+renderResponse.getNamespace()+"remove_"+docPraticaId %>').on(
'click',
function(event) {
event.preventDefault();
Loading.start();
A.io.request(
'<%=rimuoviFirmaURL%>',
{
on: {
failure: function() {
alert('impossibile rimuovere la firma!');
},
success: function(event, id, obj) {
window.parent.Liferay.fire('allegati-<%=comingFrom%>-open');
if( "<%= comingFrom %>" == "page_allegati" || "<%= comingFrom %>" == "page_geologica"){
<%=refreshAll%>
}else{
Liferay.fire('allegati-"+comingFrom+"-open');
Liferay.Portlet.refresh("#p_p_id<portlet:namespace/>");
}
},
complete : function(){
Loading.end();
}
},
complete : function(){
Loading.end();
}
}
}
);
}
);
</aui:script>
<%
);
}
);
</aui:script>
<%
}
} else {
%>
<portlet:actionURL name="aggiungiFirma" var="aggiungiFirmaURL">
<portlet:param name="docPraticaId" value="<%=String.valueOf(docPraticaId) %>" />
<portlet:param name="comingFrom" value="<%=comingFrom %>" />
</portlet:actionURL>
<div title='<%= LanguageUtil.get(pageContext, "label.firma-doc") %>' class="tooltip-info">
<liferay-ui:icon id='<%="add_"+docPraticaId %>' linkCssClass="btn btn-success" iconCssClass="fa fa-pencil" message="Firma documento" url="javascript:void(0)" />
</div>
<aui:script use="aui-base,aui-io-request">
A.one('<%="#"+renderResponse.getNamespace()+"add_"+docPraticaId %>').on(
'click',
function(event) {
event.preventDefault();
Loading.start();
A.io.request(
'<%=aggiungiFirmaURL%>',
{
on: {
failure: function() {
alert('impossibile rimuovere la firma!');
},
success: function(event, id, obj) {
window.parent.Liferay.fire('allegati-<%=comingFrom%>-open');
if( "<%= comingFrom %>" == "page_allegati" || "<%= comingFrom %>" == "page_geologica"){
<%=refreshAll%>
}else{
Liferay.fire('allegati-"+comingFrom+"-open');
Liferay.Portlet.refresh("#p_p_id<portlet:namespace/>");
<portlet:actionURL name="aggiungiFirma" var="aggiungiFirmaURL">
<portlet:param name="docPraticaId" value="<%=String.valueOf(docPraticaId) %>" />
<portlet:param name="comingFrom" value="<%=comingFrom %>" />
</portlet:actionURL>
<div title='<%= LanguageUtil.get(pageContext, "label.firma-doc") %>' class="tooltip-info">
<liferay-ui:icon id='<%="add_"+docPraticaId %>' linkCssClass="btn btn-success" iconCssClass="fa fa-pencil" message="Firma documento" url="javascript:void(0)" />
</div>
<aui:script use="aui-base,aui-io-request">
A.one('<%="#"+renderResponse.getNamespace()+"add_"+docPraticaId %>').on(
'click',
function(event) {
event.preventDefault();
Loading.start();
A.io.request(
'<%=aggiungiFirmaURL%>',
{
on: {
failure: function() {
alert('impossibile rimuovere la firma!');
},
success: function(event, id, obj) {
window.parent.Liferay.fire('allegati-<%=comingFrom%>-open');
if( "<%= comingFrom %>" == "page_allegati" || "<%= comingFrom %>" == "page_geologica"){
<%=refreshAll%>
}else{
Liferay.fire('allegati-"+comingFrom+"-open');
Liferay.Portlet.refresh("#p_p_id<portlet:namespace/>");
}
},
complete : function(){
Loading.end();
}
},
complete : function(){
Loading.end();
}
}
}
);
}
);
</aui:script>
<%
);
}
);
</aui:script>
<%
}
}
%>
</c:if>

2
liferay-plugins-sdk-6.2/portlets/portos-fe-portlet/docroot/html/allegatipratica/view.jsp

@ -30,6 +30,7 @@
<%@page import="it.tref.liferay.portos.bo.model.DettPratica"%>
<%@page import="com.liferay.portal.kernel.portlet.LiferayWindowState"%>
<%@page import="java.util.ArrayList"%>
<%@page import="it.tref.liferay.portos.fe.util.FascicoloFEUtil"%>
<%@ include file="/html/soggettipratica/init.jsp"%>
<%
String comingFrom = ParamUtil.getString(request, "comingFrom", GetterUtil.getString(PortalUtil
@ -102,6 +103,7 @@ if (Validator.isNotNull(request.getParameter("disabled"))) {
} else if (comingFromCollaudo) {
disabledInput = disabled;
}
%>
<c:if test="<%= isDettPratica %>">
<liferay-util:include page="/html/fascicolofe/navigator/header.jsp" servletContext="<%=application%>">

4
liferay-plugins-sdk-6.2/shared/portos-bo-shared/src/it/tref/liferay/portos/bo/shared/util/DocumentiPraticaUtil.java

@ -104,11 +104,15 @@ public class DocumentiPraticaUtil {
TIPOLOGIA_ALLEGATO_A13, TIPOLOGIA_ALLEGATO_A17, TIPOLOGIA_ALLEGATO_DELEGA);
private static final List<String> DOC_OBBLIGATORI_DOMANDA_C = Arrays.asList(TIPOLOGIA_ALLEGATO_A03,
TIPOLOGIA_ALLEGATO_A29);
private static final List<String> DOC_OBBLIGATORI_DOMANDA_H = Arrays.asList(TIPOLOGIA_ALLEGATO_DELEGA);
public static List<String> getDocObbligatoriDomanda(String tipoProcedura) {
if (tipoProcedura.equalsIgnoreCase(Constants.PROCEDURA_C)) {
return DOC_OBBLIGATORI_DOMANDA_C;
} else if(tipoProcedura.equalsIgnoreCase(Constants.PROCEDURA_H)) {
return DOC_OBBLIGATORI_DOMANDA_H;
} else {
return DOC_OBBLIGATORI_DOMANDA;
}

Caricamento…
Annulla
Salva