Toggle navigation
Toggle navigation
This project
Loading...
Sign in
ramster cath
/
new_xado
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
Рамиз Мирзаев
2024-08-29 14:00:17 +0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
450435efac6b6d2639a53cf2f899c91903fd41b8
450435ef
1 parent
25c39da1
Change gitignore
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
18 deletions
upload/1x_adm/controller/common/developer.php
upload/1x_adm/controller/common/developer.php
View file @
450435e
...
...
@@ -84,28 +84,29 @@ class ControllerCommonDeveloper extends Controller {
$json
=
array
();
if
(
!
$this
->
user
->
hasPermission
(
'modify'
,
'common/developer'
))
{
$json
[
'error'
]
=
$this
->
language
->
get
(
'error_permission'
);
}
else
{
// Before we delete we need to make sure there is a sass file to regenerate the css
$file
=
DIR_APPLICATION
.
'view/stylesheet/bootstrap.css'
;
if
(
is_file
(
$file
)
&&
is_file
(
DIR_APPLICATION
.
'view/stylesheet/sass/_bootstrap.scss'
))
{
unlink
(
$file
);
}
//
if (!$this->user->hasPermission('modify', 'common/developer')) {
//
$json['error'] = $this->language->get('error_permission');
//
} else {
//
// Before we delete we need to make sure there is a sass file to regenerate the css
//
$file = DIR_APPLICATION . 'view/stylesheet/bootstrap.css';
//
if (is_file($file) && is_file(DIR_APPLICATION . 'view/stylesheet/sass/_bootstrap.scss')) {
//
unlink($file);
//
}
$files
=
glob
(
DIR_CATALOG
.
'view/theme/*/stylesheet/sass/_bootstrap.scss'
);
//
$files = glob(DIR_CATALOG . 'view/theme/*/stylesheet/sass/_bootstrap.scss');
foreach
(
$files
as
$file
)
{
$file
=
substr
(
$file
,
0
,
-
21
)
.
'/bootstrap.css'
;
//
foreach ($files as $file) {
//
$file = substr($file, 0, -21) . '/bootstrap.css';
if
(
is_file
(
$file
))
{
unlink
(
$file
);
}
}
//
if (is_file($file)) {
//
unlink($file);
//
}
//
}
$json
[
'success'
]
=
sprintf
(
$this
->
language
->
get
(
'text_cache'
),
$this
->
language
->
get
(
'text_sass'
));
}
// }
$json
[
'success'
]
=
sprintf
(
$this
->
language
->
get
(
'text_cache'
),
$this
->
language
->
get
(
'text_sass'
));
$this
->
response
->
addHeader
(
'Content-Type: application/json'
);
$this
->
response
->
setOutput
(
json_encode
(
$json
));
...
...
Please
register
or
login
to post a comment