Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
traffic-front
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangxiaoming
traffic-front
Commits
960de1e3
Commit
960de1e3
authored
Jul 31, 2018
by
neo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[bugfix] fixed bb inprove function for char index
parent
a80484ee
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
1 deletion
+17
-1
BBParasBo.java
.../src/main/java/pwc/taxtech/atms/dto/vatdto/BBParasBo.java
+17
-1
No files found.
atms-api/src/main/java/pwc/taxtech/atms/dto/vatdto/BBParasBo.java
View file @
960de1e3
package
pwc
.
taxtech
.
atms
.
dto
.
vatdto
;
import
com.sun.xml.internal.ws.util.ASCIIUtility
;
import
lombok.Getter
;
import
org.apache.poi.ss.formula.OperationEvaluationContext
;
import
org.apache.poi.ss.formula.eval.EvaluationException
;
...
...
@@ -18,7 +19,22 @@ public class BBParasBo {
public
BBParasBo
(
ValueEval
[]
args
,
OperationEvaluationContext
ec
)
throws
EvaluationException
{
reportCode
=
resolverString
(
args
,
ec
,
0
);
columnIndex
=
resolverInteger
(
args
,
ec
,
1
);
try
{
columnIndex
=
resolverInteger
(
args
,
ec
,
1
);
}
catch
(
Exception
e
)
{
String
columnStr
=
resolverString
(
args
,
ec
,
1
);
int
rtn
=
0
;
columnStr
=
columnStr
.
toLowerCase
();
char
[]
excelCol
=
columnStr
.
toCharArray
();
for
(
int
i
=
columnStr
.
length
()
-
1
;
i
>=
0
;
i
--)
{
if
(
excelCol
[
i
]
>=
'A'
&&
excelCol
[
i
]
<=
'Z'
)
{
rtn
+=
((
int
)
Math
.
pow
(
26
,
excelCol
.
length
-
1
-
i
)
*
(
excelCol
[
i
]
-
64
));
}
else
{
rtn
=
-
1
;
}
}
columnIndex
=
rtn
;
}
rowIndex
=
resolverInteger
(
args
,
ec
,
2
);
period
=
args
.
length
>=
4
?
resolverInteger
(
args
,
ec
,
3
)
:
0
;
year
=
args
.
length
==
5
?
resolverInteger
(
args
,
ec
,
4
)
:
0
;
...
...
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