Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
doerj-caderno-dxp-7.2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
diogo.souza
doerj-caderno-dxp-7.2
Commits
fa438c86
Commit
fa438c86
authored
May 25, 2021
by
Diogo Fellipe De Melo Souza
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Homologacao 25052021
parent
f4d8eb7f
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
42 additions
and
9 deletions
+42
-9
.gitignore
bin/main/.gitignore
+0
-2
TESTEMARCADOR.docx
bin/main/META-INF/resources/template/TESTEMARCADOR.docx
+0
-0
TemplateEstilos.docx
bin/main/META-INF/resources/template/TemplateEstilos.docx
+0
-0
CadernoUtil.class
bin/main/mprj/doerj/caderno/util/CadernoUtil.class
+0
-0
CadernoUtil.java
src/main/java/mprj/doerj/caderno/util/CadernoUtil.java
+42
-7
No files found.
bin/main/.gitignore
View file @
fa438c86
/META-INF/
/content/
/mprj/
/mprj/
bin/main/META-INF/resources/template/TESTEMARCADOR.docx
0 → 100644
View file @
fa438c86
File added
bin/main/META-INF/resources/template/TemplateEstilos.docx
0 → 100644
View file @
fa438c86
File added
bin/main/mprj/doerj/caderno/util/CadernoUtil.class
View file @
fa438c86
No preview for this file type
src/main/java/mprj/doerj/caderno/util/CadernoUtil.java
View file @
fa438c86
...
@@ -103,8 +103,8 @@ public class CadernoUtil {
...
@@ -103,8 +103,8 @@ public class CadernoUtil {
textoHtml
=
textoHtml
.
replace
(
"&ndash10;"
,
"-"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash10;"
,
"-"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash11;"
,
"-"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash11;"
,
"-"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash12;"
,
"-"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash12;"
,
"-"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash13;"
,
"
’
"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash13;"
,
"
'
"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash14;"
,
"
‘
"
);
textoHtml
=
textoHtml
.
replace
(
"&ndash14;"
,
"
'
"
);
//"<p> </p>"
//"<p> </p>"
...
@@ -297,6 +297,18 @@ public class CadernoUtil {
...
@@ -297,6 +297,18 @@ public class CadernoUtil {
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"</sup>"
,
""
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"</sup>"
,
""
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<sup>"
,
""
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<sup>"
,
""
);
i
=
0
;
i
=
0
;
}
else
if
(
tag
.
equals
(
"ol"
)){
if
(
strAcumulado
.
contains
(
"alpha"
))
{
conteudoHtml
=
conteudoHtml
.
replace
(
strAcumulado
,
"<o1>"
);
i
=
0
;
}
else
{
conteudoHtml
=
conteudoHtml
.
replace
(
strAcumulado
,
tagFechada
);
}
}
else
if
(
tag
.
equals
(
"a"
)){
}
else
if
(
tag
.
equals
(
"a"
)){
if
(
acao
.
equals
(
"excluirTags"
)){
if
(
acao
.
equals
(
"excluirTags"
)){
...
@@ -700,6 +712,7 @@ public static String tratarLista(String conteudoHtml){
...
@@ -700,6 +712,7 @@ public static String tratarLista(String conteudoHtml){
List
<
Integer
>
listaOls
=
new
ArrayList
<
Integer
>();
List
<
Integer
>
listaOls
=
new
ArrayList
<
Integer
>();
int
indiceListaAtual
=-
1
;
int
indiceListaAtual
=-
1
;
Boolean
tagOl
=
false
;
Boolean
tagOl
=
false
;
Boolean
tagO1
=
false
;
int
margem
=
0
;
int
margem
=
0
;
int
item
=
0
;
int
item
=
0
;
int
tamanhoTag
=
0
;
int
tamanhoTag
=
0
;
...
@@ -707,6 +720,7 @@ public static String tratarLista(String conteudoHtml){
...
@@ -707,6 +720,7 @@ public static String tratarLista(String conteudoHtml){
String
newTagP
=
""
;
String
newTagP
=
""
;
String
dezEspacos
=
" "
;
String
dezEspacos
=
" "
;
String
noveEspacos
=
" "
;
String
noveEspacos
=
" "
;
char
alpha
=
'a'
;
tamanhoTag
=
4
;
tamanhoTag
=
4
;
...
@@ -724,18 +738,27 @@ public static String tratarLista(String conteudoHtml){
...
@@ -724,18 +738,27 @@ public static String tratarLista(String conteudoHtml){
}
}
if
(
tagP
.
equals
(
"<ol>"
)||
tagP
.
equals
(
"<ul>"
)
)
{
if
(
tagP
.
equals
(
"<ol>"
)||
tagP
.
equals
(
"<ul>"
)
||
tagP
.
equals
(
"<o1>"
)
)
{
if
(
tagP
.
equals
(
"<ol>"
))
{
if
(
tagP
.
equals
(
"<ol>"
))
{
tagOl
=
true
;
tagOl
=
true
;
tagO1
=
false
;
item
=
1
;
item
=
1
;
indiceListaAtual
++;
indiceListaAtual
++;
listaOls
.
add
(
item
);
listaOls
.
add
(
item
);
}
else
{
}
if
(
tagP
.
equals
(
"<o1>"
))
{
tagOl
=
false
;
tagO1
=
true
;
}
if
(
tagP
.
equals
(
"<ul>"
))
{
tagOl
=
false
;
tagOl
=
false
;
tagO1
=
false
;
}
}
}
}
...
@@ -761,10 +784,21 @@ public static String tratarLista(String conteudoHtml){
...
@@ -761,10 +784,21 @@ public static String tratarLista(String conteudoHtml){
listaOls
.
set
(
indiceListaAtual
,
item
);
listaOls
.
set
(
indiceListaAtual
,
item
);
conteudoHtml
=
conteudoHtml
.
substring
(
0
,
i
)
+
marcador
+
conteudoHtml
.
substring
(
i
+
tamanhoTag
,
conteudoHtml
.
length
());
conteudoHtml
=
conteudoHtml
.
substring
(
0
,
i
)
+
marcador
+
conteudoHtml
.
substring
(
i
+
tamanhoTag
,
conteudoHtml
.
length
());
len
=
conteudoHtml
.
length
();
len
=
conteudoHtml
.
length
();
}
else
{
}
marcador
=
"\u2022 "
;
if
(
tagO1
==
true
)
{
conteudoHtml
=
conteudoHtml
.
substring
(
0
,
i
+
tamanhoTag
)
+
marcador
+
conteudoHtml
.
substring
(
i
+
tamanhoTag
,
conteudoHtml
.
length
());
newTagP
=
"<p style='margin-left:0px'>"
;
marcador
=
newTagP
+
alpha
+
". "
;
conteudoHtml
=
conteudoHtml
.
substring
(
0
,
i
)
+
marcador
+
conteudoHtml
.
substring
(
i
+
tamanhoTag
,
conteudoHtml
.
length
());
alpha
++;
len
=
conteudoHtml
.
length
();
}
if
(
tagOl
==
false
&&
tagO1
==
false
)
{
newTagP
=
"<p style='margin-left:0px'>"
;
marcador
=
newTagP
+
"\u2022 "
;
conteudoHtml
=
conteudoHtml
.
substring
(
0
,
i
)
+
marcador
+
conteudoHtml
.
substring
(
i
+
tamanhoTag
,
conteudoHtml
.
length
());
len
=
conteudoHtml
.
length
();
len
=
conteudoHtml
.
length
();
}
}
//posicaoItemOl=QTD_LISTAS;
//posicaoItemOl=QTD_LISTAS;
...
@@ -784,6 +818,7 @@ public static String tratarLista(String conteudoHtml){
...
@@ -784,6 +818,7 @@ public static String tratarLista(String conteudoHtml){
}
}
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<ol>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<ol>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<o1>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<ul>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<ul>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<li>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"<li>"
,
"<p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"</li>"
,
"</p>"
);
conteudoHtml
=
conteudoHtml
.
replaceAll
(
"</li>"
,
"</p>"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment