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
d2a754bd
Commit
d2a754bd
authored
May 16, 2020
by
yinxiaoling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
下载去掉header验证
parent
8b2a6145
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
58 additions
and
26 deletions
+58
-26
InfoController.php
app/Http/Controllers/strategy/InfoController.php
+0
-23
StrategyTaskController.php
app/Http/Controllers/strategy/StrategyTaskController.php
+51
-0
api.php
routes/api.php
+7
-3
No files found.
app/Http/Controllers/strategy/InfoController.php
deleted
100644 → 0
View file @
8b2a6145
<?php
namespace
App\Http\Controllers\strategy
;
use
Illuminate\Http\Request
;
use
App\Http\Controllers\Controller
;
use
App\Http\Controllers\BaseController
;
use
App\Http\Requests\strategySetCreateRequest
;
class
InfoController
extends
BaseController
{
public
function
index
(
Request
$request
){
dd
(
'策略列表数据'
);
}
public
function
store
(
strategySetCreateRequest
$request
){
dd
(
'策略列表数据'
);
}
public
function
strategyDelete
(
Request
$request
){
dd
(
'策略列表数据'
);
}
}
app/Http/Controllers/strategy/StrategyTaskController.php
0 → 100644
View file @
d2a754bd
<?php
namespace
App\Http\Controllers\strategy
;
use
Illuminate\Http\Request
;
use
App\Http\Controllers\Controller
;
use
App\Models\StrategyTask
;
use
Illuminate\Foundation\Validation\ValidatesRequests
;
use
App\Http\Controllers\Tool
;
class
StrategyTaskController
extends
Controller
{
use
ValidatesRequests
;
use
Tool
;
public
function
index
(){
//搜索分页?
$projectArr
=
$this
->
getAllowProjects
(
1
);
$strategyInfo
=
StrategyTask
::
all
()
->
toArray
();
$listInfo
=
[];
foreach
(
$strategyInfo
as
$k
=>
$v
){
$projectSnTemp
=
explode
(
"#"
,
$v
[
'project_sn'
]);
$v
[
'project_name'
]
=
isset
(
$projectArr
[
$projectSnTemp
[
0
]])
?
$projectArr
[
$projectSnTemp
[
0
]]
:
''
;
if
(
isset
(
$projectSnTemp
[
1
])
&&
isset
(
$projectArr
[
$projectSnTemp
[
1
]])){
$v
[
'project_name'
]
.=
$projectArr
[
$projectSnTemp
[
1
]];
}
$v
[
'is_created_name'
]
=
$v
[
'is_created'
]
==
0
?
'未建'
:
'已建'
;
$listInfo
[]
=
$v
;
}
return
$this
->
successWithInfo
([
'data'
=>
$listInfo
]);
}
public
function
show
(
$strategy_sn
){
}
public
function
update
(
Request
$request
,
$strategy_sn
)
{
try
{
return
$this
->
successWithInfo
(
'更新成功'
);
}
catch
(
\Exception
$e
)
{
return
$this
->
errorWithInfo
(
$e
->
getMessageBag
());
}
}
}
routes/api.php
View file @
d2a754bd
...
...
@@ -26,14 +26,18 @@ Route::group(['middleware' => 'check.apikey','namespace'=>'strategy'], function
Route
::
post
(
'strategy/getCallNumberList'
,
'StrategySetController@getCallNumberList'
)
->
name
(
'strategy.getCallNumberList'
);
//主叫号码列表
Route
::
get
(
'strategy/downloadModel'
,
'StrategySetController@downloadModel'
)
->
name
(
'strategy.downloadModel'
);
//导出模板
//
Route::get('strategy/downloadModel', 'StrategySetController@downloadModel')->name('strategy.downloadModel');//导出模板
Route
::
get
(
'strategy/downloadFailExcel'
,
'StrategySetController@downloadFailExcel'
)
->
name
(
'strategy.downloadFailExcel'
);
//下载失败导入excel数据
//
Route::get('strategy/downloadFailExcel', 'StrategySetController@downloadFailExcel')->name('strategy.downloadFailExcel');//下载失败导入excel数据
Route
::
post
(
'strategy/importExcelData'
,
'StrategySetController@importExcelData'
)
->
name
(
'strategy.importExcelData'
);
//导入excel数据
Route
::
apiResource
(
'strategySet'
,
StrategySetController
::
class
);
Route
::
apiResource
(
'strategyTask'
,
StrategyTaskController
::
class
);
});
Route
::
get
(
'strategy/downloadModel'
,
'strategy\StrategySetController@downloadModel'
)
->
name
(
'strategy.downloadModel'
);
//导出模板
Route
::
get
(
'strategy/downloadFailExcel'
,
'StrategySetController@downloadFailExcel'
)
->
name
(
'strategy.downloadFailExcel'
);
//下载失败导入excel数据
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