Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
aic_duty_strategy
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
yinxiaoling
aic_duty_strategy
Commits
829dd352
Commit
829dd352
authored
May 19, 2020
by
yinxiaoling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
下载失败数据
parent
4b4112c0
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
StrategySetController.php
app/Http/Controllers/strategy/StrategySetController.php
+1
-1
CheckApiKey.php
app/Http/Middleware/CheckApiKey.php
+1
-1
StrategyService.php
app/Service/StrategyService.php
+1
-1
No files found.
app/Http/Controllers/strategy/StrategySetController.php
View file @
829dd352
...
...
@@ -156,7 +156,7 @@ class StrategySetController extends Controller
if
(
empty
(
$excelFile
)){
return
$this
->
errorWithInfo
(
'表单验证失败'
,
401
);
}
$url
=
storage_path
()
.
"
\\
import
\\
"
.
$excelFile
.
'.xlsx'
;
$url
=
storage_path
()
.
"
/import/"
.
$excelFile
.
'.xlsx'
;
try
{
if
(
file_exists
(
$url
)
==
false
){
return
$this
->
errorWithInfo
(
'文件不存在,下载失败'
,
401
);
...
...
app/Http/Middleware/CheckApiKey.php
View file @
829dd352
...
...
@@ -38,7 +38,7 @@ class CheckApiKey
$user
=
Redis
::
get
(
$rKey
);
$user
=
json_decode
(
$user
,
true
);
if
(
$api_key
!=
$user
[
'api_key'
]){
return
$this
->
errorWithInfo
(
'
key验证不通过'
,
401
,
1001
);
return
$this
->
errorWithInfo
(
'
账号已在其他地方登录'
,
401
,
1001
);
//key验证不通过
}
}
...
...
app/Service/StrategyService.php
View file @
829dd352
...
...
@@ -105,7 +105,7 @@ class StrategyService
$failDataTitle
=
[
'姓名'
,
'*手机号码'
,
'值班日期'
,
'失败原因'
];
array_unshift
(
$failData
,
$failDataTitle
);
$failExcelName
=
"导入失败数据_"
.
date
(
'YmdHis'
);
//dump($failExcelName);
$failFile
=
$this
->
storeExcelStyle
(
$failExcelName
,
$failData
,
''
,
'import'
);
//$failDataFile = $failExcelName.'.xlsx';
if
(
$failFile
){
...
...
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