Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
taskonsite-архив-перенесен
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dmitry Korolev
taskonsite-архив-перенесен
Commits
7023157c
Commit
7023157c
authored
Oct 25, 2016
by
Олег Гиммельшпах
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
7aef4e97
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
5 deletions
+3
-5
backend/config/main.php
backend/config/main.php
+0
-2
common/modules/bids/controllers/BidAdminController.php
common/modules/bids/controllers/BidAdminController.php
+2
-2
common/modules/bids/models/BidFile.php
common/modules/bids/models/BidFile.php
+1
-1
No files found.
backend/config/main.php
View file @
7023157c
...
@@ -130,8 +130,6 @@ return [
...
@@ -130,8 +130,6 @@ return [
'showScriptName'
=>
false
,
'showScriptName'
=>
false
,
'enableStrictParsing'
=>
true
,
'enableStrictParsing'
=>
true
,
'rules'
=>
[
'rules'
=>
[
'bids/bod-admin/download/<file>'
=>
'bids/bod-admin/download'
,
'<module_id>/settings/manage'
=>
'settings/manage'
,
'<module_id>/settings/manage'
=>
'settings/manage'
,
'<module_id>/settings/create'
=>
'settings/create'
,
'<module_id>/settings/create'
=>
'settings/create'
,
'<module_id>/settings/update/<id>'
=>
'settings/update'
,
'<module_id>/settings/update/<id>'
=>
'settings/update'
,
...
...
common/modules/bids/controllers/BidAdminController.php
View file @
7023157c
...
@@ -110,9 +110,9 @@ class BidAdminController extends AdminController
...
@@ -110,9 +110,9 @@ class BidAdminController extends AdminController
return
$this
->
redirect
([
'/bids/bid-admin/manage'
]);
return
$this
->
redirect
([
'/bids/bid-admin/manage'
]);
}
}
public
function
actionDownload
(
$
file
)
public
function
actionDownload
(
$
id
)
{
{
$model
=
BidFile
::
find
()
->
where
([
'filename'
=>
$file
])
->
one
(
);
$model
=
BidFile
::
find
One
(
$id
);
if
(
$model
)
{
if
(
$model
)
{
return
Yii
::
$app
->
response
->
sendFile
(
BidFile
::
path
()
.
$model
->
filename
,
$model
->
filename
);
return
Yii
::
$app
->
response
->
sendFile
(
BidFile
::
path
()
.
$model
->
filename
,
$model
->
filename
);
...
...
common/modules/bids/models/BidFile.php
View file @
7023157c
...
@@ -81,7 +81,7 @@ class BidFile extends \common\components\ActiveRecordModel
...
@@ -81,7 +81,7 @@ class BidFile extends \common\components\ActiveRecordModel
public
function
getUrl
()
public
function
getUrl
()
{
{
return
Yii
::
$app
->
params
[
'backUrl'
]
.
'/bids/bid-admin/download/'
.
$this
->
filename
;
return
Yii
::
$app
->
params
[
'backUrl'
]
.
'/bids/bid-admin/download/'
.
$this
->
id
;
}
}
public
static
function
path
()
public
static
function
path
()
...
...
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