Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hp-smart
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
platform
hp-smart
Commits
e2d5601a
Commit
e2d5601a
authored
Mar 22, 2024
by
liulei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
APP文件上传
parent
1f338b73
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
1 deletions
+5
-1
ServiceHPMT002.java
.../java/com/baosight/hpjx/hp/mt/service/ServiceHPMT002.java
+1
-0
UploadUtils.java
...main/java/com/baosight/hpjx/hp/mt/untils/UploadUtils.java
+3
-0
ServiceHPPZ015.java
.../java/com/baosight/hpjx/hp/pz/service/ServiceHPPZ015.java
+1
-1
No files found.
src/main/java/com/baosight/hpjx/hp/mt/service/ServiceHPMT002.java
View file @
e2d5601a
...
...
@@ -398,6 +398,7 @@ public class ServiceHPMT002 extends ServiceBase {
try
{
CommonsMultipartFile
multipartFile
=
Base64ToMultipartFile
.
base64toMultipartFile
(
files
);
System
.
out
.
println
(
"--------------------------------转换Base64成功"
);
JSONObject
upload
=
UploadUtils
.
upload
(
multipartFile
);
inInfo
.
set
(
"id"
,
upload
.
getString
(
"docId"
));
inInfo
.
setMsg
(
"上传成功!"
);
...
...
src/main/java/com/baosight/hpjx/hp/mt/untils/UploadUtils.java
View file @
e2d5601a
...
...
@@ -45,10 +45,12 @@ public class UploadUtils {
filePath
=
multipartFile
.
getOriginalFilename
();
Long
docSize
=
multipartFile
.
getSize
();
String
chgName
=
transformFileName
(
filePath
);
System
.
out
.
println
(
"----------------------------------解析Path"
);
String
attachmentName
;
Map
<
String
,
String
>
pathMap
=
getRealPath
(
"A"
);
msg
=
(
String
)
pathMap
.
get
(
"dirId"
);
category
=
(
String
)
pathMap
.
get
(
"path"
);
System
.
out
.
println
(
"----------------------------------获取dirId成功"
);
checkInvalidPath
(
category
);
File
dir
=
new
File
(
category
);
if
(!
dir
.
exists
())
{
...
...
@@ -120,6 +122,7 @@ public class UploadUtils {
Map
hashMap
=
new
HashMap
();
hashMap
.
put
(
"fkey"
,
"docRootDir"
);
List
<
Map
>
query
=
DaoBase
.
getInstance
().
query
(
"EDCC03.query"
,
hashMap
);
System
.
out
.
println
(
"----------------------------------获取path地址"
);
if
(
query
.
get
(
0
).
get
(
"fvalue"
)!=
null
)
{
ROOT_PATH
=
(
String
)
query
.
get
(
0
).
get
(
"fvalue"
);
}
...
...
src/main/java/com/baosight/hpjx/hp/pz/service/ServiceHPPZ015.java
View file @
e2d5601a
...
...
@@ -96,7 +96,7 @@ public class ServiceHPPZ015 extends ServiceBase {
HPPZ015
.
setProjCode
(
hpsc001
.
getProjCode
());
HPPZ015
.
setTemplateName
(
inInfo
.
getString
(
"templateName"
));
HPPZ015
.
setCreatedBy
(
UserSession
.
getUserId
());
HPPZ015
.
setCompanyCode
(
UserSession
.
getUserId
());
HPPZ015
.
setCompanyCode
(
UserSession
Utils
.
getCompanyCode
());
HPPZ015
.
setCreatedName
(
UserSession
.
getUserId
()+
"-"
+
UserSession
.
getLoginCName
());
HPPZ015
.
setCreatedTime
(
sdf
.
format
(
new
Date
()));
HPPZ015
.
setUpdatedBy
(
null
);
...
...
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