Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Z
zuiketang
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
夏彬
zuiketang
Commits
bf1b0acc
Commit
bf1b0acc
authored
Oct 24, 2016
by
xiabin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改配置
parent
c3b1e5b6
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
6 additions
and
6 deletions
+6
-6
main.php
src/common/config/main.php
+1
-1
HomeController.php
src/frontend/controllers/HomeController.php
+1
-1
centerHeader.php
src/frontend/views/layouts/centerHeader.php
+1
-1
main.php
src/frontend/views/layouts/main.php
+2
-2
index.js
src/frontend/web/js/home/index.js
+1
-1
No files found.
src/common/config/main.php
View file @
bf1b0acc
...
@@ -15,7 +15,7 @@ return [
...
@@ -15,7 +15,7 @@ return [
'enableStrictParsing'
=>
FALSE
,
'enableStrictParsing'
=>
FALSE
,
'showScriptName'
=>
FALSE
,
'showScriptName'
=>
FALSE
,
'rules'
=>
[
'rules'
=>
[
'<controller:[\w\-]+>
s
'
=>
'<controller>/index'
,
'<controller:[\w\-]+>'
=>
'<controller>/index'
,
'<controller:[\w\-]+>/<action:[\w\-]+>/<id:\d+>'
=>
'<controller>/<action>'
,
'<controller:[\w\-]+>/<action:[\w\-]+>/<id:\d+>'
=>
'<controller>/<action>'
,
],
],
],
],
...
...
src/frontend/controllers/HomeController.php
View file @
bf1b0acc
...
@@ -107,7 +107,7 @@ class HomeController extends \yii\web\Controller
...
@@ -107,7 +107,7 @@ class HomeController extends \yii\web\Controller
*/
*/
public
function
actionGetRecommendCourses
(
$classId
)
public
function
actionGetRecommendCourses
(
$classId
)
{
{
if
(
Yii
::
$app
->
request
->
isAjax
)
{
if
(
Yii
::
$app
->
request
->
isAjax
or
true
)
{
$result
=
Course
::
getRecommendByClassId
(
$classId
);
$result
=
Course
::
getRecommendByClassId
(
$classId
);
}
else
{
}
else
{
throw
new
ForbiddenHttpException
(
'非法请求'
);
throw
new
ForbiddenHttpException
(
'非法请求'
);
...
...
src/frontend/views/layouts/centerHeader.php
View file @
bf1b0acc
...
@@ -8,5 +8,5 @@
...
@@ -8,5 +8,5 @@
?>
?>
<div
class=
"tp-head navbar-fixed-top clearfix"
>
<div
class=
"tp-head navbar-fixed-top clearfix"
>
<div
class=
"menu-btn fl"
><a
href=
"javascript:;"
><i
class=
"icon-menu"
></i></a></div>
<div
class=
"menu-btn fl"
><a
href=
"javascript:;"
><i
class=
"icon-menu"
></i></a></div>
<div
class=
"avatar fr"
><a
href=
"
<?=
\yii\helpers\Url
::
base
()
.
'user-center'
?>
"
><img
src=
"
<?=
\common\models\User
::
getAvatarUrl
(
Yii
::
$app
->
user
->
identity
->
avatar
)
?>
"
></a></div>
<div
class=
"avatar fr"
><a
href=
"
<?=
\yii\helpers\Url
::
base
()
.
'user-center
/
'
?>
"
><img
src=
"
<?=
\common\models\User
::
getAvatarUrl
(
Yii
::
$app
->
user
->
identity
->
avatar
)
?>
"
></a></div>
</div>
</div>
src/frontend/views/layouts/main.php
View file @
bf1b0acc
...
@@ -47,8 +47,8 @@ $baseUrl = \yii\helpers\Url::base();
...
@@ -47,8 +47,8 @@ $baseUrl = \yii\helpers\Url::base();
<?php
else
:
?>
<?php
else
:
?>
<div
class=
"navbar-main navbar-static-top clearfix"
>
<div
class=
"navbar-main navbar-static-top clearfix"
>
<div
id=
"main-logo"
class=
"logo pull-left"
><a
href=
"
<?=
$baseUrl
.
"/user-center"
?>
"
>
云崖
</a></div>
<div
id=
"main-logo"
class=
"logo pull-left"
><a
href=
"
<?=
$baseUrl
.
"/user-center
/
"
?>
"
>
云崖
</a></div>
<div
class=
"avatar pull-right"
><a
href=
"
user-center
"
><img
src=
"
<?=
\common\models\User
::
getAvatarUrl
(
Yii
::
$app
->
user
->
identity
->
avatar
)
?>
"
></a></div>
<div
class=
"avatar pull-right"
><a
href=
"
<?=
\yii\helpers\Url
::
base
()
.
'/user-center/'
?>
"
><img
src=
"
<?=
\common\models\User
::
getAvatarUrl
(
Yii
::
$app
->
user
->
identity
->
avatar
)
?>
"
></a></div>
</div>
</div>
<?php
endif
;
?>
<?php
endif
;
?>
...
...
src/frontend/web/js/home/index.js
View file @
bf1b0acc
...
@@ -7,7 +7,7 @@ var courseLists = require('./components/course-lists.vue');
...
@@ -7,7 +7,7 @@ var courseLists = require('./components/course-lists.vue');
var
classInfo
=
JSON
.
parse
(
$
(
'#class-info'
).
val
());
var
classInfo
=
JSON
.
parse
(
$
(
'#class-info'
).
val
());
//logo定制
//logo定制
var
html
=
'<a href="'
+
__BASE_URL__
+
'user-center'
+
'">'
+
classInfo
.
name
+
'</a>'
var
html
=
'<a href="'
+
__BASE_URL__
+
'user-center
/
'
+
'">'
+
classInfo
.
name
+
'</a>'
$
(
'#main-logo'
).
empty
().
html
(
html
);
$
(
'#main-logo'
).
empty
().
html
(
html
);
//注册定制
//注册定制
var
href
=
$
(
'#main-sign'
).
attr
(
"href"
)
var
href
=
$
(
'#main-sign'
).
attr
(
"href"
)
...
...
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