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
4b212884
Commit
4b212884
authored
Mar 04, 2019
by
chase
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增上传文件接口
parent
2d7c01a5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
578 additions
and
4 deletions
+578
-4
Constant.java
...api/src/main/java/pwc/taxtech/atms/constant/Constant.java
+1
-2
DidiFileUploadController.java
...pwc/taxtech/atms/controller/DidiFileUploadController.java
+42
-0
DidiFileIUploadParam.java
...taxtech/atms/dto/didiFileUpload/DidiFileIUploadParam.java
+81
-0
DidiFileUploadDetailResult.java
...h/atms/dto/didiFileUpload/DidiFileUploadDetailResult.java
+9
-0
DidiFileUploadService.java
.../pwc/taxtech/atms/service/impl/DidiFileUploadService.java
+0
-0
conf.properties
atms-api/src/main/resources/conf/conf.properties
+6
-2
conf_profile_dev.properties
atms-api/src/main/resources/conf/conf_profile_dev.properties
+5
-0
FileUploadLogMapper.java
...in/java/pwc/taxtech/atms/vat/dao/FileUploadLogMapper.java
+109
-0
FileUploadMapper.java
.../main/java/pwc/taxtech/atms/vat/dao/FileUploadMapper.java
+109
-0
FileUpload.java
...src/main/java/pwc/taxtech/atms/vat/entity/FileUpload.java
+0
-0
FileUploadExample.java
...n/java/pwc/taxtech/atms/vat/entity/FileUploadExample.java
+0
-0
FileUploadLog.java
.../main/java/pwc/taxtech/atms/vat/entity/FileUploadLog.java
+216
-0
FileUploadLogExample.java
...ava/pwc/taxtech/atms/vat/entity/FileUploadLogExample.java
+0
-0
FileUploadLogMapper.xml
...esources/pwc/taxtech/atms/vat/dao/FileUploadLogMapper.xml
+0
-0
FileUploadMapper.xml
...n/resources/pwc/taxtech/atms/vat/dao/FileUploadMapper.xml
+0
-0
No files found.
atms-api/src/main/java/pwc/taxtech/atms/constant/Constant.java
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
constant
;
package
pwc
.
taxtech
.
atms
.
constant
;
import
java.io.File
;
import
java.io.File
;
import
java.text.DecimalFormat
;
import
java.util.Locale
;
import
java.util.UUID
;
import
java.util.UUID
;
public
final
class
Constant
{
public
final
class
Constant
{
...
@@ -123,6 +121,7 @@ public final class Constant {
...
@@ -123,6 +121,7 @@ public final class Constant {
public
static
final
String
DEFAULT
=
"yyyy-MM-dd"
;
public
static
final
String
DEFAULT
=
"yyyy-MM-dd"
;
public
static
final
String
YEAR_MONTH
=
"yyyy-MM"
;
public
static
final
String
YEAR_MONTH
=
"yyyy-MM"
;
public
static
final
String
YYYYMM
=
"yyyyMM"
;
public
static
final
String
YYYYMM
=
"yyyyMM"
;
public
static
final
String
YYYYMMDD
=
"yyyyMMdd"
;
public
static
final
String
YYYY_MM_DD_HH_MM_SS
=
"yyyy-MM-dd HH:mm:ss"
;
public
static
final
String
YYYY_MM_DD_HH_MM_SS
=
"yyyy-MM-dd HH:mm:ss"
;
}
}
...
...
atms-api/src/main/java/pwc/taxtech/atms/controller/DidiFileUploadController.java
0 → 100644
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
controller
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.multipart.MultipartFile
;
import
pwc.taxtech.atms.common.message.ErrorMessage
;
import
pwc.taxtech.atms.dto.OperationResultDto
;
import
pwc.taxtech.atms.exception.ServiceException
;
import
pwc.taxtech.atms.service.impl.DidiFileUploadService
;
@RestController
@RequestMapping
(
"/api/v1/DidiFileUpload"
)
public
class
DidiFileUploadController
{
private
static
final
Logger
logger
=
LoggerFactory
.
getLogger
(
DidiFileUploadController
.
class
);
@Autowired
private
DidiFileUploadService
didiFileUploadService
;
@ResponseBody
// @ApiOperation(value = "导入模板")
@RequestMapping
(
value
=
"importTemplateGroupExcelFile"
,
method
=
RequestMethod
.
POST
)
public
OperationResultDto
uploadFile
(
@RequestParam
MultipartFile
file
)
{
try
{
if
(
null
==
file
)
{
return
OperationResultDto
.
error
(
ErrorMessage
.
NoFile
);
}
return
OperationResultDto
.
success
();
}
catch
(
ServiceException
e
)
{
return
OperationResultDto
.
error
(
e
.
getMessage
());
}
catch
(
Exception
e
)
{
logger
.
error
(
"uploadFile error."
,
e
);
}
return
OperationResultDto
.
error
(
ErrorMessage
.
SystemError
);
}
// @PostMapping("queryPage")
// public CamelPagingResultDto<DidiFileUploadDetailResult> queryPage(@RequestBody DidiFileIUploadParam param) {
// return new CamelPagingResultDto<>(revenueDetailService.queryPage(param));
// }
}
atms-api/src/main/java/pwc/taxtech/atms/dto/didiFileUpload/DidiFileIUploadParam.java
0 → 100644
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
dto
.
didiFileUpload
;
import
pwc.taxtech.atms.dto.input.CamelPagingDto
;
import
java.io.Serializable
;
import
java.util.List
;
public
class
DidiFileIUploadParam
implements
Serializable
{
private
static
final
long
serialVersionUID
=
-
1277395668299427030L
;
private
CamelPagingDto
pageInfo
;
private
List
<
String
>
uuids
;
private
List
<
String
>
bizSources
;
private
List
<
String
>
uploadDates
;
private
List
<
String
>
uploadMonths
;
private
List
<
Integer
>
uploadWeeks
;
private
List
<
Integer
>
uploadYears
;
public
List
<
String
>
getBizSources
()
{
return
bizSources
;
}
public
void
setBizSources
(
List
<
String
>
bizSources
)
{
this
.
bizSources
=
bizSources
;
}
public
List
<
String
>
getUploadDates
()
{
return
uploadDates
;
}
public
void
setUploadDates
(
List
<
String
>
uploadDates
)
{
this
.
uploadDates
=
uploadDates
;
}
public
List
<
String
>
getUploadMonths
()
{
return
uploadMonths
;
}
public
void
setUploadMonths
(
List
<
String
>
uploadMonths
)
{
this
.
uploadMonths
=
uploadMonths
;
}
public
List
<
Integer
>
getUploadWeeks
()
{
return
uploadWeeks
;
}
public
void
setUploadWeeks
(
List
<
Integer
>
uploadWeeks
)
{
this
.
uploadWeeks
=
uploadWeeks
;
}
public
List
<
Integer
>
getUploadYears
()
{
return
uploadYears
;
}
public
void
setUploadYears
(
List
<
Integer
>
uploadYears
)
{
this
.
uploadYears
=
uploadYears
;
}
public
CamelPagingDto
getPageInfo
()
{
return
pageInfo
;
}
public
void
setPageInfo
(
CamelPagingDto
pageInfo
)
{
this
.
pageInfo
=
pageInfo
;
}
public
List
<
String
>
getUuids
()
{
return
uuids
;
}
public
void
setUuids
(
List
<
String
>
uuids
)
{
this
.
uuids
=
uuids
;
}
}
atms-api/src/main/java/pwc/taxtech/atms/dto/didiFileUpload/DidiFileUploadDetailResult.java
0 → 100644
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
dto
.
didiFileUpload
;
import
pwc.taxtech.atms.vat.entity.FileUpload
;
public
class
DidiFileUploadDetailResult
extends
FileUpload
{
private
static
final
long
serialVersionUID
=
-
3050146980194769766L
;
}
atms-api/src/main/java/pwc/taxtech/atms/service/impl/DidiFileUploadService.java
0 → 100644
View file @
4b212884
This diff is collapsed.
Click to expand it.
atms-api/src/main/resources/conf/conf.properties
View file @
4b212884
...
@@ -41,4 +41,8 @@ longi_api_gl_balance=${longi_api_gl_balance}
...
@@ -41,4 +41,8 @@ longi_api_gl_balance=${longi_api_gl_balance}
#log
#log
log.level
=
${log.level}
log.level
=
${log.level}
log.debug
=
${log.debug}
log.debug
=
${log.debug}
\ No newline at end of file
env_type
=
${env_type}
file_upload_post_url
=
${file_upload_post_url}
file_upload_query_url
=
${file_upload_query_url}
\ No newline at end of file
atms-api/src/main/resources/conf/conf_profile_dev.properties
View file @
4b212884
...
@@ -38,3 +38,7 @@ longi_api_gl_balance=http://39.105.197.175:13001/ETMSSB/Erp/GLBalance/ProxyServi
...
@@ -38,3 +38,7 @@ longi_api_gl_balance=http://39.105.197.175:13001/ETMSSB/Erp/GLBalance/ProxyServi
#log
#log
log.level
=
DEBUG
log.level
=
DEBUG
log.debug
=
true
log.debug
=
true
env_type
=
dev
file_upload_post_url
=
http://47.94.233.173:11005/resource/erp_tax_system
file_upload_query_url
=
http://47.94.233.173:11006/resource/erp_tax_system
\ No newline at end of file
atms-dao/src/main/java/pwc/taxtech/atms/vat/dao/FileUploadLogMapper.java
0 → 100644
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
vat
.
dao
;
import
java.util.List
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.session.RowBounds
;
import
pwc.taxtech.atms.MyVatMapper
;
import
pwc.taxtech.atms.vat.entity.FileUploadLog
;
import
pwc.taxtech.atms.vat.entity.FileUploadLogExample
;
@Mapper
public
interface
FileUploadLogMapper
extends
MyVatMapper
{
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
long
countByExample
(
FileUploadLogExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
deleteByExample
(
FileUploadLogExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
deleteByPrimaryKey
(
String
uid
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
insert
(
FileUploadLog
record
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
insertSelective
(
FileUploadLog
record
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
List
<
FileUploadLog
>
selectByExampleWithRowbounds
(
FileUploadLogExample
example
,
RowBounds
rowBounds
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
List
<
FileUploadLog
>
selectByExample
(
FileUploadLogExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
FileUploadLog
selectByPrimaryKey
(
String
uid
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
updateByExampleSelective
(
@Param
(
"record"
)
FileUploadLog
record
,
@Param
(
"example"
)
FileUploadLogExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
updateByExample
(
@Param
(
"record"
)
FileUploadLog
record
,
@Param
(
"example"
)
FileUploadLogExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
updateByPrimaryKeySelective
(
FileUploadLog
record
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
int
updateByPrimaryKey
(
FileUploadLog
record
);
}
\ No newline at end of file
atms-dao/src/main/java/pwc/taxtech/atms/vat/dao/FileUploadMapper.java
0 → 100644
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
vat
.
dao
;
import
java.util.List
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.session.RowBounds
;
import
pwc.taxtech.atms.MyVatMapper
;
import
pwc.taxtech.atms.vat.entity.FileUpload
;
import
pwc.taxtech.atms.vat.entity.FileUploadExample
;
@Mapper
public
interface
FileUploadMapper
extends
MyVatMapper
{
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
long
countByExample
(
FileUploadExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
deleteByExample
(
FileUploadExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
deleteByPrimaryKey
(
String
uid
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
insert
(
FileUpload
record
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
insertSelective
(
FileUpload
record
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
List
<
FileUpload
>
selectByExampleWithRowbounds
(
FileUploadExample
example
,
RowBounds
rowBounds
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
List
<
FileUpload
>
selectByExample
(
FileUploadExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
FileUpload
selectByPrimaryKey
(
String
uid
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
updateByExampleSelective
(
@Param
(
"record"
)
FileUpload
record
,
@Param
(
"example"
)
FileUploadExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
updateByExample
(
@Param
(
"record"
)
FileUpload
record
,
@Param
(
"example"
)
FileUploadExample
example
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
updateByPrimaryKeySelective
(
FileUpload
record
);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload
*
* @mbg.generated
*/
int
updateByPrimaryKey
(
FileUpload
record
);
}
\ No newline at end of file
atms-dao/src/main/java/pwc/taxtech/atms/vat/entity/FileUpload.java
0 → 100644
View file @
4b212884
This diff is collapsed.
Click to expand it.
atms-dao/src/main/java/pwc/taxtech/atms/vat/entity/FileUploadExample.java
0 → 100644
View file @
4b212884
This diff is collapsed.
Click to expand it.
atms-dao/src/main/java/pwc/taxtech/atms/vat/entity/FileUploadLog.java
0 → 100644
View file @
4b212884
package
pwc
.
taxtech
.
atms
.
vat
.
entity
;
import
java.io.Serializable
;
import
pwc.taxtech.atms.entity.BaseEntity
;
/**
*
* This class was generated by MyBatis Generator.
* This class corresponds to the database table file_upload_log
*
* @mbg.generated do_not_delete_during_merge
*/
public
class
FileUploadLog
extends
BaseEntity
implements
Serializable
{
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column file_upload_log.uid
*
* @mbg.generated
*/
private
String
uid
;
/**
* Database Column Remarks:
* 请求uuid
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column file_upload_log.request_id
*
* @mbg.generated
*/
private
String
requestId
;
/**
* Database Column Remarks:
* 请求路径
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column file_upload_log.request_url
*
* @mbg.generated
*/
private
String
requestUrl
;
/**
* Database Column Remarks:
* 请求返回json
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column file_upload_log.respons_json
*
* @mbg.generated
*/
private
String
responsJson
;
/**
* Database Column Remarks:
* 文件上传表主键id
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column file_upload_log.file_upload_id
*
* @mbg.generated
*/
private
String
fileUploadId
;
/**
* This field was generated by MyBatis Generator.
* This field corresponds to the database table file_upload_log
*
* @mbg.generated
*/
private
static
final
long
serialVersionUID
=
1L
;
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column file_upload_log.uid
*
* @return the value of file_upload_log.uid
*
* @mbg.generated
*/
public
String
getUid
()
{
return
uid
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column file_upload_log.uid
*
* @param uid the value for file_upload_log.uid
*
* @mbg.generated
*/
public
void
setUid
(
String
uid
)
{
this
.
uid
=
uid
==
null
?
null
:
uid
.
trim
();
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column file_upload_log.request_id
*
* @return the value of file_upload_log.request_id
*
* @mbg.generated
*/
public
String
getRequestId
()
{
return
requestId
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column file_upload_log.request_id
*
* @param requestId the value for file_upload_log.request_id
*
* @mbg.generated
*/
public
void
setRequestId
(
String
requestId
)
{
this
.
requestId
=
requestId
==
null
?
null
:
requestId
.
trim
();
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column file_upload_log.request_url
*
* @return the value of file_upload_log.request_url
*
* @mbg.generated
*/
public
String
getRequestUrl
()
{
return
requestUrl
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column file_upload_log.request_url
*
* @param requestUrl the value for file_upload_log.request_url
*
* @mbg.generated
*/
public
void
setRequestUrl
(
String
requestUrl
)
{
this
.
requestUrl
=
requestUrl
==
null
?
null
:
requestUrl
.
trim
();
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column file_upload_log.respons_json
*
* @return the value of file_upload_log.respons_json
*
* @mbg.generated
*/
public
String
getResponsJson
()
{
return
responsJson
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column file_upload_log.respons_json
*
* @param responsJson the value for file_upload_log.respons_json
*
* @mbg.generated
*/
public
void
setResponsJson
(
String
responsJson
)
{
this
.
responsJson
=
responsJson
==
null
?
null
:
responsJson
.
trim
();
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column file_upload_log.file_upload_id
*
* @return the value of file_upload_log.file_upload_id
*
* @mbg.generated
*/
public
String
getFileUploadId
()
{
return
fileUploadId
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column file_upload_log.file_upload_id
*
* @param fileUploadId the value for file_upload_log.file_upload_id
*
* @mbg.generated
*/
public
void
setFileUploadId
(
String
fileUploadId
)
{
this
.
fileUploadId
=
fileUploadId
==
null
?
null
:
fileUploadId
.
trim
();
}
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table file_upload_log
*
* @mbg.generated
*/
@Override
public
String
toString
()
{
StringBuilder
sb
=
new
StringBuilder
();
sb
.
append
(
getClass
().
getSimpleName
());
sb
.
append
(
" ["
);
sb
.
append
(
"Hash = "
).
append
(
hashCode
());
sb
.
append
(
", uid="
).
append
(
uid
);
sb
.
append
(
", requestId="
).
append
(
requestId
);
sb
.
append
(
", requestUrl="
).
append
(
requestUrl
);
sb
.
append
(
", responsJson="
).
append
(
responsJson
);
sb
.
append
(
", fileUploadId="
).
append
(
fileUploadId
);
sb
.
append
(
"]"
);
return
sb
.
toString
();
}
}
\ No newline at end of file
atms-dao/src/main/java/pwc/taxtech/atms/vat/entity/FileUploadLogExample.java
0 → 100644
View file @
4b212884
This diff is collapsed.
Click to expand it.
atms-dao/src/main/resources/pwc/taxtech/atms/vat/dao/FileUploadLogMapper.xml
0 → 100644
View file @
4b212884
This diff is collapsed.
Click to expand it.
atms-dao/src/main/resources/pwc/taxtech/atms/vat/dao/FileUploadMapper.xml
0 → 100644
View file @
4b212884
This diff is collapsed.
Click to expand it.
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