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
51d7c875
Commit
51d7c875
authored
Oct 17, 2016
by
杨培
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
f16822b1
1b0cd735
Changes
12
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
185 additions
and
14 deletions
+185
-14
AppAsset.php
src/backend/assets/AppAsset.php
+0
-1
main-local.php
src/environments/prod/backend/config/main-local.php
+5
-1
index-test.php
src/environments/prod/backend/web/index-test.php
+25
-0
index.php
src/environments/prod/backend/web/index.php
+8
-2
main-local.php
src/environments/prod/common/config/main-local.php
+42
-3
params-local.php
src/environments/prod/common/config/params-local.php
+36
-0
main-local.php
src/environments/prod/console/config/main-local.php
+1
-0
main-local.php
src/environments/prod/frontend/config/main-local.php
+15
-3
index-test.php
src/environments/prod/frontend/web/index-test.php
+24
-0
index.php
src/environments/prod/frontend/web/index.php
+6
-0
video.php
src/frontend/views/home/video.php
+18
-0
video-play.vue
src/frontend/web/js/home/components/video-play.vue
+5
-4
No files found.
src/backend/assets/AppAsset.php
View file @
51d7c875
...
...
@@ -12,7 +12,6 @@ class AppAsset extends AssetBundle
public
$basePath
=
'@webroot'
;
public
$baseUrl
=
'@web'
;
public
$css
=
[
'css/site.css'
,
];
public
$js
=
[
];
...
...
src/environments/prod/backend/config/main-local.php
View file @
51d7c875
<?php
return
[
$config
=
[
'components'
=>
[
'request'
=>
[
// !!! insert a secret key in the following (if it is empty) - this is required by cookie validation
...
...
@@ -7,3 +8,6 @@ return [
],
],
];
return
$config
;
src/environments/prod/backend/web/index-test.php
0 → 100644
View file @
51d7c875
<?php
// NOTE: Make sure this file is not accessible when deployed to production
if
(
!
in_array
(
@
$_SERVER
[
'REMOTE_ADDR'
],
[
'127.0.0.1'
,
'::1'
]))
{
die
(
'You are not allowed to access this file.'
);
}
if
(
!
function_exists
(
'fnmatch'
))
{
function
fnmatch
(
$pattern
,
$string
)
{
return
preg_match
(
"#^"
.
strtr
(
preg_quote
(
$pattern
,
'#'
),
array
(
'\*'
=>
'.*'
,
'\?'
=>
'.'
))
.
"$#i"
,
$string
);
}
// end
}
// end if
defined
(
'YII_DEBUG'
)
or
define
(
'YII_DEBUG'
,
true
);
defined
(
'YII_ENV'
)
or
define
(
'YII_ENV'
,
'test'
);
require
(
__DIR__
.
'/../../vendor/autoload.php'
);
require
(
__DIR__
.
'/../../vendor/yiisoft/yii2/Yii.php'
);
require
(
__DIR__
.
'/../../common/config/bootstrap.php'
);
require
(
__DIR__
.
'/../config/bootstrap.php'
);
$config
=
require
(
__DIR__
.
'/../../tests/codeception/config/backend/acceptance.php'
);
(
new
yii\web\Application
(
$config
))
->
run
();
src/environments/prod/backend/web/index.php
View file @
51d7c875
<?php
defined
(
'YII_DEBUG'
)
or
define
(
'YII_DEBUG'
,
false
);
defined
(
'YII_ENV'
)
or
define
(
'YII_ENV'
,
'prod'
);
defined
(
'YII_DEBUG'
)
or
define
(
'YII_DEBUG'
,
true
);
defined
(
'YII_ENV'
)
or
define
(
'YII_ENV'
,
'dev'
);
if
(
!
function_exists
(
'fnmatch'
))
{
function
fnmatch
(
$pattern
,
$string
)
{
return
preg_match
(
"#^"
.
strtr
(
preg_quote
(
$pattern
,
'#'
),
array
(
'\*'
=>
'.*'
,
'\?'
=>
'.'
))
.
"$#i"
,
$string
);
}
// end
}
// end if
require
(
__DIR__
.
'/../../vendor/autoload.php'
);
require
(
__DIR__
.
'/../../vendor/yiisoft/yii2/Yii.php'
);
require
(
__DIR__
.
'/../../common/config/bootstrap.php'
);
...
...
src/environments/prod/common/config/main-local.php
View file @
51d7c875
<?php
return
[
'components'
=>
[
'cache'
=>
[
'class'
=>
'yii\redis\Cache'
,
'redis'
=>
[
'hostname'
=>
'192.168.1.12'
,
'port'
=>
6380
,
'database'
=>
2
,
]
],
'db'
=>
[
'class'
=>
'yii\db\Connection'
,
'dsn'
=>
'mysql:host=
localhost;dbname=yii2advanced
'
,
'username'
=>
'
root
'
,
'password'
=>
''
,
'dsn'
=>
'mysql:host=
192.168.1.7;port:3305;dbname=pp_c
'
,
'username'
=>
'
pp_c
'
,
'password'
=>
'
nF@V5LK#ilb!NEvZ@1Ze#rWm#H
'
,
'charset'
=>
'utf8'
,
],
'redis'
=>
[
'class'
=>
'yii\redis\Connection'
,
'hostname'
=>
'192.168.1.21'
,
'port'
=>
6380
,
'database'
=>
2
,
],
'mailer'
=>
[
'class'
=>
'yii\swiftmailer\Mailer'
,
'viewPath'
=>
'@common/mail'
,
// send all mails to a file by default. You have to set
// 'useFileTransport' to false and configure a transport
// for the mailer to send real emails.
'useFileTransport'
=>
TRUE
,
],
'qiniu'
=>
[
'class'
=>
'common\components\Qiniu'
,
'accessKey'
=>
'n85SCPB9uO2v32az-3TRFsZCXwJu7YddyzLRYXg-'
,
'secretKey'
=>
'KDl3b7aLpj7n9YZ07lHGivVY4c_Q-0QSM0TZ_-XS'
,
'storages'
=>
[
'public'
=>
[
'bucket'
=>
'pp-classroom'
,
'fsizeLimit'
=>
pow
(
1024
,
2
)
*
5
,
//5MB
'mimeLimit'
=>
'image/jpeg;image/png;image/gif'
,
'url'
=>
'http://dev.qdn.pp.cc/'
],
'video'
=>
[
'bucket'
=>
'pp-classroom-private'
,
'fsizeLimit'
=>
pow
(
1024
,
3
)
*
2
,
//2GB
'mimeLimit'
=>
'video/*;flv-application/octet-stream'
,
'url'
=>
'http://oe9d6dr84.bkt.clouddn.com/'
]
]
]
],
];
src/environments/prod/common/config/params-local.php
View file @
51d7c875
<?php
return
[
'adminEmail'
=>
'admin@example.com'
,
'supportEmail'
=>
'support@example.com'
,
'user.passwordResetTokenExpire'
=>
3600
,
'captchaId'
=>
'4d6ad870bf63a30be3d22c92925b04ca'
,
'privateKey'
=>
'a2ca5e5139d1f43ac4e1cd248f3e52e4'
,
'msg.host'
=>
'http://114.55.132.75:7893/sms.aspx'
,
'msg.userid'
=>
'78'
,
'msg.account'
=>
'276147613x'
,
'msg.password'
=>
'276147613'
,
'msg.signature'
=>
'【最课堂】'
,
'alipay'
=>
[
'partner'
=>
'2088701843067550'
,
'seller_id'
=>
'2088701843067550'
,
'key'
=>
'12vr33u4g314hytde3g81oao9dfdarm6'
,
'notify_url'
=>
'http://c.pp.cc/pay/alipay-notify'
,
'return_url'
=>
'http://商户网址/create_direct_pay_by_user-PHP-UTF-8/return_url.php'
,
'sign_type'
=>
strtoupper
(
'MD5'
),
'input_charset'
=>
strtolower
(
'utf-8'
),
'cacert'
=>
getcwd
()
.
'\\cacert.pem'
,
'transport'
=>
'http'
,
'payment_type'
=>
'1'
,
'service'
=>
'create_direct_pay_by_user'
,
],
// 'weixinpay'=>[
// 'appid'=>'wx180521eb22e9d7af',
// 'mchid'=>'1295461001',
// 'key'=>'ejg0l9phOAkp021qB54shz0Q8Tiscwzy',
// 'appsecret'=>'f20293c9548c469fb8b855fc98c4ef3c',
//
// ]
'weixinpay'
=>
[
'appid'
=>
'wx5714a24a60083b2a'
,
'mchid'
=>
'1399794002'
,
'key'
=>
'8934e7d15453e97507ef794cf7b0519d'
,
'appsecret'
=>
'7c18222c6ec31efa65d21606a629585d'
,
]
];
src/environments/prod/console/config/main-local.php
View file @
51d7c875
<?php
return
[
];
src/environments/prod/frontend/config/main-local.php
View file @
51d7c875
<?php
return
[
$config
=
[
'components'
=>
[
'request'
=>
[
// !!! insert a secret key in the following (if it is empty) - this is required by cookie validation
'cookieValidationKey'
=>
''
,
'cookieValidationKey'
=>
'1o1zEUf8jdBvsnZy_JygPUO5_sZ7zBci'
,
],
'session'
=>
[
'timeout'
=>
3600
,
'name'
=>
'zuiektang-frontend'
,
'class'
=>
'yii\redis\Session'
,
'redis'
=>
[
'hostname'
=>
'192.168.1.21'
,
'port'
=>
6380
,
'database'
=>
2
,
]
],
],
];
return
$config
;
src/environments/prod/frontend/web/index-test.php
0 → 100644
View file @
51d7c875
<?php
// NOTE: Make sure this file is not accessible when deployed to production
if
(
!
in_array
(
@
$_SERVER
[
'REMOTE_ADDR'
],
[
'127.0.0.1'
,
'::1'
]))
{
die
(
'You are not allowed to access this file.'
);
}
if
(
!
function_exists
(
'fnmatch'
))
{
function
fnmatch
(
$pattern
,
$string
)
{
return
preg_match
(
"#^"
.
strtr
(
preg_quote
(
$pattern
,
'#'
),
array
(
'\*'
=>
'.*'
,
'\?'
=>
'.'
))
.
"$#i"
,
$string
);
}
// end
}
// end if
defined
(
'YII_DEBUG'
)
or
define
(
'YII_DEBUG'
,
true
);
defined
(
'YII_ENV'
)
or
define
(
'YII_ENV'
,
'test'
);
require
(
__DIR__
.
'/../../vendor/autoload.php'
);
require
(
__DIR__
.
'/../../vendor/yiisoft/yii2/Yii.php'
);
require
(
__DIR__
.
'/../../common/config/bootstrap.php'
);
require
(
__DIR__
.
'/../config/bootstrap.php'
);
$config
=
require
(
__DIR__
.
'/../../tests/codeception/config/frontend/acceptance.php'
);
(
new
yii\web\Application
(
$config
))
->
run
();
src/environments/prod/frontend/web/index.php
View file @
51d7c875
<?php
defined
(
'YII_DEBUG'
)
or
define
(
'YII_DEBUG'
,
false
);
defined
(
'YII_ENV'
)
or
define
(
'YII_ENV'
,
'prod'
);
if
(
!
function_exists
(
'fnmatch'
))
{
function
fnmatch
(
$pattern
,
$string
)
{
return
preg_match
(
"#^"
.
strtr
(
preg_quote
(
$pattern
,
'#'
),
array
(
'\*'
=>
'.*'
,
'\?'
=>
'.'
))
.
"$#i"
,
$string
);
}
// end
}
// end if
require
(
__DIR__
.
'/../../vendor/autoload.php'
);
require
(
__DIR__
.
'/../../vendor/yiisoft/yii2/Yii.php'
);
require
(
__DIR__
.
'/../../common/config/bootstrap.php'
);
...
...
src/frontend/views/home/video.php
View file @
51d7c875
...
...
@@ -6,6 +6,24 @@
* Time: 下午5:39
*/
$this
->
title
=
"视频播放"
;
\backend\assets\AppAsset
::
register
(
$this
);
$js
=
<<<JS
window._bd_share_config = {
"common": {
"bdSnsKey": {},
"bdText": "",
"bdMini": "1",
"bdMiniList": ["qzone", "tsina", "weixin"],
"bdPic": "",
"bdStyle": "2",
"bdSize": "24"
}, "share": {}
};
with (document)0[(getElementsByTagName('head')[0] || body).appendChild(createElement('script')).src = 'http://bdimg.share.baidu.com/static/api/js/share.js?v=89860593.js?cdnversion=' + ~(-new Date() / 36e5)];
JS;
$this
->
registerJs
(
$js
);
\frontend\assets\AppAsset
::
addCss
(
$this
,
'@web/assets/css/main.css'
);
\frontend\assets\AppAsset
::
addScript
(
$this
,
'@web/assets/home_video.js'
);
\frontend\assets\AppAsset
::
addCss
(
$this
,
'@web/assets/css/home_video.css'
);
...
...
src/frontend/web/js/home/components/video-play.vue
View file @
51d7c875
...
...
@@ -2,10 +2,10 @@
<div
class=
"container"
>
<div
class=
"cnt-tit"
>
<h3>
{{
coursewareInfo
.
courseName
}}
</h3>
<div
class=
"tit-share hidden-xs"
>
<a
href=
"javascript:;"
class=
"wechat post-icons"
></a>
<a
href=
"javascript:;"
class=
"weibo post-icons"
></a>
<a
href=
"javascript:;"
class=
"qzone post-icons"
></a>
<div
class=
"tit-share hidden-xs
bdsharebuttonbox
"
>
<a
href=
"javascript:;"
class=
"wechat post-icons
bds_weixin"
data-cmd=
"weixin"
title=
"分享到微信
"
></a>
<a
href=
"javascript:;"
class=
"weibo post-icons
bds_tsina"
data-cmd=
"tsina"
title=
"分享到新浪微博
"
></a>
<a
href=
"javascript:;"
class=
"qzone post-icons
bds_qzone"
data-cmd=
"qzone"
title=
"分享到QQ空间
"
></a>
</div>
</div>
...
...
@@ -109,3 +109,4 @@
}
}
</
script
>
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