Browse Source
* upstream: (2012 commits) doc fix. Changed the signature of `urlCreator` and button creators for `yii\gridview\ActionColumn` parameter adjustment. The signature for `yii\gridview\ActionColumn::urlCreator` is changed - the `$action` parameter is moved to the first Fixed the signature of Schema::findUniqueIndexes(). reverted #1598 and added a test for it Fix wrong array index in unique indexes for MySql Making accesors public Get DB unique indexes information Fixes #1610: `Html::activeCheckboxList()` and `Html::activeRadioList()` will submit an empty string if no checkbox/radio is selected Gii should keep horizontal layout Documentation at "yii\authclient" updated. Doc comments at "yii\authclient" updated. Auth clients "Choice" doc comments updated. Auth clients "Choice" widget javascript advanced. Bootstrap's dropdown encodes also trailing caret tag Auth clients "Choice" widget markup updated. Gii should keep horizontal layout extended from codeception testcase, added docs Auth clients for Facebook, GitHub, LinkedIn added. ... Conflicts: framework/yii/helpers/BaseInflector.php tests/unit/framework/helpers/InflectorTest.phptags/2.0.0-beta
Antonio Ramirez
11 years ago
1233 changed files with 102088 additions and 65082 deletions
@ -0,0 +1,4 @@ |
|||||||
|
service_name: travis-ci |
||||||
|
src_dir: framework/yii |
||||||
|
coverage_clover: tests/unit/runtime/coveralls/clover.xml |
||||||
|
json_path: tests/unit/runtime/coveralls/coveralls-upload.json |
@ -0,0 +1,23 @@ |
|||||||
|
# Autodetect text files |
||||||
|
* text=auto |
||||||
|
|
||||||
|
# ...Unless the name matches the following overriding patterns |
||||||
|
|
||||||
|
# Definitively text files |
||||||
|
*.php text |
||||||
|
*.css text |
||||||
|
*.js text |
||||||
|
*.txt text |
||||||
|
*.md text |
||||||
|
*.xml text |
||||||
|
*.json text |
||||||
|
*.bat text |
||||||
|
*.sql text |
||||||
|
*.xml text |
||||||
|
*.yml text |
||||||
|
|
||||||
|
# Ensure those won't be messed up with |
||||||
|
*.png binary |
||||||
|
*.jpg binary |
||||||
|
*.gif binary |
||||||
|
*.ttf binary |
@ -1,15 +1,33 @@ |
|||||||
language: php |
language: php |
||||||
|
|
||||||
php: |
php: |
||||||
- 5.3 |
|
||||||
- 5.4 |
- 5.4 |
||||||
- 5.5 |
- 5.5 |
||||||
|
# - hhvm # commented until composer or hhvm get fixed: https://github.com/facebook/hhvm/issues/1347 |
||||||
|
|
||||||
env: |
services: |
||||||
- DB=mysql |
- redis-server |
||||||
|
- memcached |
||||||
|
- elasticsearch |
||||||
|
- mongodb |
||||||
|
|
||||||
|
install: |
||||||
|
- composer self-update && composer --version |
||||||
|
# - composer require satooshi/php-coveralls 0.6.* --dev --prefer-dist |
||||||
|
- tests/unit/data/travis/mongodb-setup.sh |
||||||
|
- tests/unit/data/travis/apc-setup.sh |
||||||
|
- tests/unit/data/travis/memcache-setup.sh |
||||||
|
- tests/unit/data/travis/cubrid-setup.sh |
||||||
|
|
||||||
before_script: |
before_script: |
||||||
- sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database IF NOT EXISTS yiitest;'; fi" |
- echo 'elasticsearch version ' && curl http://localhost:9200/ |
||||||
- psql -U postgres -c 'drop database if exists yiitest;'; |
- mysql -e 'CREATE DATABASE yiitest;'; |
||||||
- psql -U postgres -c 'create database yiitest;'; |
- psql -U postgres -c 'CREATE DATABASE yiitest;'; |
||||||
script: phpunit |
- tests/unit/data/travis/sphinx-setup.sh |
||||||
|
- mongo yii2test --eval 'db.addUser("travis", "test");' |
||||||
|
|
||||||
|
script: |
||||||
|
- phpunit --coverage-text --coverage-clover tests/unit/runtime/coveralls/clover.xml --verbose --exclude-group mssql,oci,wincache,xcache,zenddata,vendor |
||||||
|
|
||||||
|
#after_script: |
||||||
|
# - php vendor/bin/coveralls |
||||||
|
@ -0,0 +1,26 @@ |
|||||||
|
<?php |
||||||
|
/** |
||||||
|
* @link http://www.yiiframework.com/ |
||||||
|
* @copyright Copyright (c) 2008 Yii Software LLC |
||||||
|
* @license http://www.yiiframework.com/license/ |
||||||
|
*/ |
||||||
|
|
||||||
|
namespace backend\assets; |
||||||
|
|
||||||
|
use yii\web\AssetBundle; |
||||||
|
|
||||||
|
/** |
||||||
|
* @author Qiang Xue <qiang.xue@gmail.com> |
||||||
|
* @since 2.0 |
||||||
|
*/ |
||||||
|
class AppAsset extends AssetBundle |
||||||
|
{ |
||||||
|
public $basePath = '@webroot'; |
||||||
|
public $baseUrl = '@web'; |
||||||
|
public $css = ['css/site.css']; |
||||||
|
public $js = []; |
||||||
|
public $depends = [ |
||||||
|
'yii\web\YiiAsset', |
||||||
|
'yii\bootstrap\BootstrapAsset', |
||||||
|
]; |
||||||
|
} |
@ -1,18 +0,0 @@ |
|||||||
<?php |
|
||||||
|
|
||||||
return array( |
|
||||||
'app' => array( |
|
||||||
'basePath' => '@wwwroot', |
|
||||||
'baseUrl' => '@www', |
|
||||||
'css' => array( |
|
||||||
'css/site.css', |
|
||||||
), |
|
||||||
'js' => array( |
|
||||||
|
|
||||||
), |
|
||||||
'depends' => array( |
|
||||||
'yii', |
|
||||||
'yii/bootstrap/responsive', |
|
||||||
), |
|
||||||
), |
|
||||||
); |
|
@ -1,5 +1,4 @@ |
|||||||
<?php |
<?php |
||||||
|
return [ |
||||||
return array( |
|
||||||
'adminEmail' => 'admin@example.com', |
'adminEmail' => 'admin@example.com', |
||||||
); |
]; |
||||||
|
@ -1,64 +1,64 @@ |
|||||||
<?php |
<?php |
||||||
|
use backend\assets\AppAsset; |
||||||
use yii\helpers\Html; |
use yii\helpers\Html; |
||||||
use yii\widgets\Menu; |
use yii\bootstrap\Nav; |
||||||
|
use yii\bootstrap\NavBar; |
||||||
use yii\widgets\Breadcrumbs; |
use yii\widgets\Breadcrumbs; |
||||||
use yii\debug\Toolbar; |
|
||||||
|
|
||||||
/** |
/** |
||||||
* @var $this \yii\base\View |
* @var \yii\web\View $this |
||||||
* @var $content string |
* @var string $content |
||||||
*/ |
*/ |
||||||
$this->registerAssetBundle('app'); |
AppAsset::register($this); |
||||||
?> |
?> |
||||||
<?php $this->beginPage(); ?> |
<?php $this->beginPage() ?> |
||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html lang="en"> |
<html lang="<?= Yii::$app->language ?>">
|
||||||
<head> |
<head> |
||||||
<meta charset="utf-8"/> |
<meta charset="<?= Yii::$app->charset ?>"/>
|
||||||
<title><?php echo Html::encode($this->title); ?></title>
|
<title><?= Html::encode($this->title) ?></title>
|
||||||
<?php $this->head(); ?> |
<?php $this->head() ?> |
||||||
</head> |
</head> |
||||||
<body> |
<body> |
||||||
<div class="container"> |
<?php $this->beginBody() ?> |
||||||
<?php $this->beginBody(); ?> |
<?php |
||||||
<div class="masthead"> |
NavBar::begin([ |
||||||
<h3 class="muted">My Company</h3> |
'brandLabel' => 'My Company', |
||||||
|
'brandUrl' => Yii::$app->homeUrl, |
||||||
|
'options' => [ |
||||||
|
'class' => 'navbar-inverse navbar-fixed-top', |
||||||
|
], |
||||||
|
]); |
||||||
|
$menuItems = [ |
||||||
|
['label' => 'Home', 'url' => ['/site/index']], |
||||||
|
]; |
||||||
|
if (Yii::$app->user->isGuest) { |
||||||
|
$menuItems[] = ['label' => 'Login', 'url' => ['/site/login']]; |
||||||
|
} else { |
||||||
|
$menuItems[] = ['label' => 'Logout (' . Yii::$app->user->identity->username .')' , 'url' => ['/site/logout']]; |
||||||
|
} |
||||||
|
echo Nav::widget([ |
||||||
|
'options' => ['class' => 'navbar-nav navbar-right'], |
||||||
|
'items' => $menuItems, |
||||||
|
]); |
||||||
|
NavBar::end(); |
||||||
|
?> |
||||||
|
|
||||||
<div class="navbar"> |
|
||||||
<div class="navbar-inner"> |
|
||||||
<div class="container"> |
<div class="container"> |
||||||
<?php echo Menu::widget(array( |
<?= Breadcrumbs::widget([ |
||||||
'options' => array('class' => 'nav'), |
'links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : [], |
||||||
'items' => array( |
]) ?> |
||||||
array('label' => 'Home', 'url' => array('/site/index')), |
<?= $content ?> |
||||||
Yii::$app->user->isGuest ? |
|
||||||
array('label' => 'Login', 'url' => array('/site/login')) : |
|
||||||
array('label' => 'Logout (' . Yii::$app->user->identity->username .')' , 'url' => array('/site/logout')), |
|
||||||
), |
|
||||||
)); ?> |
|
||||||
</div> |
</div> |
||||||
</div> |
|
||||||
</div> |
|
||||||
<!-- /.navbar --> |
|
||||||
</div> |
|
||||||
|
|
||||||
<?php echo Breadcrumbs::widget(array( |
|
||||||
'links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : array(), |
|
||||||
)); ?> |
|
||||||
<?php echo $content; ?> |
|
||||||
|
|
||||||
<hr> |
<footer class="footer"> |
||||||
|
<div class="container"> |
||||||
<div class="footer"> |
<p class="pull-left">© My Company <?= date('Y') ?></p>
|
||||||
<p>© My Company <?php echo date('Y'); ?></p>
|
<p class="pull-right"><?= Yii::powered() ?></p>
|
||||||
<p> |
|
||||||
<?php echo Yii::powered(); ?> |
|
||||||
Template by <a href="http://twitter.github.io/bootstrap/">Twitter Bootstrap</a> |
|
||||||
</p> |
|
||||||
</div> |
</div> |
||||||
<?php $this->endBody(); ?> |
</footer> |
||||||
</div> |
|
||||||
<?php echo Toolbar::widget(); ?> |
<?php $this->endBody() ?> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
<?php $this->endPage(); ?> |
<?php $this->endPage() ?> |
||||||
|
@ -0,0 +1,29 @@ |
|||||||
|
<?php |
||||||
|
|
||||||
|
use yii\helpers\Html; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var yii\web\View $this |
||||||
|
* @var string $name |
||||||
|
* @var string $message |
||||||
|
* @var Exception $exception |
||||||
|
*/ |
||||||
|
|
||||||
|
$this->title = $name; |
||||||
|
?> |
||||||
|
<div class="site-error"> |
||||||
|
|
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
|
|
||||||
|
<div class="alert alert-danger"> |
||||||
|
<?= nl2br(Html::encode($message)) ?> |
||||||
|
</div> |
||||||
|
|
||||||
|
<p> |
||||||
|
The above error occurred while the Web server was processing your request. |
||||||
|
</p> |
||||||
|
<p> |
||||||
|
Please contact us if you think this is a server error. Thank you. |
||||||
|
</p> |
||||||
|
|
||||||
|
</div> |
@ -1,47 +1,53 @@ |
|||||||
<?php |
<?php |
||||||
/** |
/** |
||||||
* @var yii\base\View $this |
* @var yii\web\View $this |
||||||
*/ |
*/ |
||||||
$this->title = 'Welcome'; |
$this->title = 'My Yii Application'; |
||||||
?> |
?> |
||||||
<div class="jumbotron"> |
<div class="site-index"> |
||||||
<h1>Welcome!</h1> |
|
||||||
|
|
||||||
<p class="lead">Cras justo odio, dapibus ac facilisis in, egestas eget quam. Fusce dapibus, tellus ac cursus |
<div class="jumbotron"> |
||||||
commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus.</p> |
<h1>Congratulations!</h1> |
||||||
<a class="btn btn-large btn-success" href="http://www.yiiframework.com">Get started with Yii</a> |
|
||||||
</div> |
<p class="lead">You have successfully created your Yii-powered application.</p> |
||||||
|
|
||||||
|
<p><a class="btn btn-lg btn-success" href="http://www.yiiframework.com">Get started with Yii</a></p> |
||||||
|
</div> |
||||||
|
|
||||||
<hr> |
<div class="body-content"> |
||||||
|
|
||||||
<!-- Example row of columns --> |
<div class="row"> |
||||||
<div class="row-fluid"> |
<div class="col-lg-4"> |
||||||
<div class="span4"> |
|
||||||
<h2>Heading</h2> |
<h2>Heading</h2> |
||||||
|
|
||||||
<p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et |
||||||
condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. |
dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip |
||||||
Donec sed odio dui. </p> |
ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu |
||||||
|
fugiat nulla pariatur.</p> |
||||||
|
|
||||||
<p><a class="btn" href="#">View details »</a></p> |
<p><a class="btn btn-default" href="http://www.yiiframework.com/doc/">Yii Documentation »</a></p> |
||||||
</div> |
</div> |
||||||
<div class="span4"> |
<div class="col-lg-4"> |
||||||
<h2>Heading</h2> |
<h2>Heading</h2> |
||||||
|
|
||||||
<p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et |
||||||
condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. |
dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip |
||||||
Donec sed odio dui. </p> |
ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu |
||||||
|
fugiat nulla pariatur.</p> |
||||||
|
|
||||||
<p><a class="btn" href="#">View details »</a></p> |
<p><a class="btn btn-default" href="http://www.yiiframework.com/forum/">Yii Forum »</a></p> |
||||||
</div> |
</div> |
||||||
<div class="span4"> |
<div class="col-lg-4"> |
||||||
<h2>Heading</h2> |
<h2>Heading</h2> |
||||||
|
|
||||||
<p>Donec sed odio dui. Cras justo odio, dapibus ac facilisis in, egestas eget quam. Vestibulum id ligula porta |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et |
||||||
felis euismod semper. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum |
dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip |
||||||
massa.</p> |
ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu |
||||||
|
fugiat nulla pariatur.</p> |
||||||
|
|
||||||
<p><a class="btn" href="#">View details »</a></p> |
<p><a class="btn btn-default" href="http://www.yiiframework.com/extensions/">Yii Extensions »</a></p> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
</div> |
|
||||||
|
|
||||||
|
</div> |
||||||
|
</div> |
||||||
|
@ -0,0 +1,45 @@ |
|||||||
|
body { |
||||||
|
padding-top: 70px; |
||||||
|
} |
||||||
|
|
||||||
|
.footer { |
||||||
|
border-top: 1px solid #ddd; |
||||||
|
margin-top: 30px; |
||||||
|
padding-top: 15px; |
||||||
|
padding-bottom: 30px; |
||||||
|
} |
||||||
|
|
||||||
|
.jumbotron { |
||||||
|
text-align: center; |
||||||
|
background-color: transparent; |
||||||
|
} |
||||||
|
.jumbotron .btn { |
||||||
|
font-size: 21px; |
||||||
|
padding: 14px 24px; |
||||||
|
} |
||||||
|
|
||||||
|
.not-set { |
||||||
|
color: #c55; |
||||||
|
font-style: italic; |
||||||
|
} |
||||||
|
|
||||||
|
/* add sorting icons to gridview sort links */ |
||||||
|
a.asc:after, a.desc:after { |
||||||
|
position: relative; |
||||||
|
top: 1px; |
||||||
|
display: inline-block; |
||||||
|
font-family: 'Glyphicons Halflings'; |
||||||
|
font-style: normal; |
||||||
|
font-weight: normal; |
||||||
|
line-height: 1; |
||||||
|
padding-left: 5px; |
||||||
|
} |
||||||
|
|
||||||
|
a.asc:after { content: /*"\e113"*/"\e151"; } |
||||||
|
a.desc:after { content: /*"\e114"*/"\e152"; } |
||||||
|
|
||||||
|
.sort-numerical a.asc:after { content: "\e153"; } |
||||||
|
.sort-numerical a.desc:after { content: "\e154"; } |
||||||
|
|
||||||
|
.sort-ordinal a.asc:after { content: "\e155"; } |
||||||
|
.sort-ordinal a.desc:after { content: "\e156"; } |
After Width: | Height: | Size: 1.1 KiB |
@ -1,78 +0,0 @@ |
|||||||
body { |
|
||||||
padding-top: 20px; |
|
||||||
padding-bottom: 60px; |
|
||||||
} |
|
||||||
|
|
||||||
/* Custom container */ |
|
||||||
.container { |
|
||||||
margin: 0 auto; |
|
||||||
max-width: 1000px; |
|
||||||
} |
|
||||||
|
|
||||||
.container > hr { |
|
||||||
margin: 60px 0; |
|
||||||
} |
|
||||||
|
|
||||||
/* Main marketing message and sign up button */ |
|
||||||
.jumbotron { |
|
||||||
margin: 80px 0; |
|
||||||
text-align: center; |
|
||||||
} |
|
||||||
|
|
||||||
.jumbotron h1 { |
|
||||||
font-size: 100px; |
|
||||||
line-height: 1; |
|
||||||
} |
|
||||||
|
|
||||||
.jumbotron .lead { |
|
||||||
font-size: 24px; |
|
||||||
line-height: 1.25; |
|
||||||
} |
|
||||||
|
|
||||||
.jumbotron .btn { |
|
||||||
font-size: 21px; |
|
||||||
padding: 14px 24px; |
|
||||||
} |
|
||||||
|
|
||||||
/* Supporting marketing content */ |
|
||||||
.marketing { |
|
||||||
margin: 60px 0; |
|
||||||
} |
|
||||||
|
|
||||||
.marketing p + h4 { |
|
||||||
margin-top: 28px; |
|
||||||
} |
|
||||||
|
|
||||||
/* Customize the navbar links to be fill the entire space of the .navbar */ |
|
||||||
.navbar .navbar-inner { |
|
||||||
padding: 0; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav { |
|
||||||
margin: 0; |
|
||||||
display: table; |
|
||||||
width: 100%; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li { |
|
||||||
display: table-cell; |
|
||||||
width: 1%; |
|
||||||
float: none; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li a { |
|
||||||
font-weight: bold; |
|
||||||
text-align: center; |
|
||||||
border-left: 1px solid rgba(255, 255, 255, .75); |
|
||||||
border-right: 1px solid rgba(0, 0, 0, .1); |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li:first-child a { |
|
||||||
border-left: 0; |
|
||||||
border-radius: 3px 0 0 3px; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li:last-child a { |
|
||||||
border-right: 0; |
|
||||||
border-radius: 0 3px 3px 0; |
|
||||||
} |
|
@ -1,16 +1,28 @@ |
|||||||
<?php |
<?php |
||||||
|
|
||||||
return array( |
Yii::setAlias('common', realpath(__DIR__ . '/../')); |
||||||
|
Yii::setAlias('frontend', realpath(__DIR__ . '/../../frontend')); |
||||||
|
Yii::setAlias('backend', realpath(__DIR__ . '/../../backend')); |
||||||
|
Yii::setAlias('console', realpath(__DIR__ . '/../../console')); |
||||||
|
|
||||||
|
return [ |
||||||
'adminEmail' => 'admin@example.com', |
'adminEmail' => 'admin@example.com', |
||||||
|
'supportEmail' => 'support@example.com', |
||||||
|
|
||||||
'components.cache' => array( |
'components.cache' => [ |
||||||
'class' => 'yii\caching\FileCache', |
'class' => 'yii\caching\FileCache', |
||||||
), |
], |
||||||
|
|
||||||
|
'components.mail' => [ |
||||||
|
'class' => 'yii\swiftmailer\Mailer', |
||||||
|
'viewPath' => '@common/mails', |
||||||
|
], |
||||||
|
|
||||||
'components.db' => array( |
'components.db' => [ |
||||||
'class' => 'yii\db\Connection', |
'class' => 'yii\db\Connection', |
||||||
'dsn' => 'mysql:host=localhost;dbname=yii2advanced', |
'dsn' => 'mysql:host=localhost;dbname=yii2advanced', |
||||||
'username' => 'root', |
'username' => 'root', |
||||||
'password' => '', |
'password' => '', |
||||||
), |
'charset' => 'utf8', |
||||||
); |
], |
||||||
|
]; |
||||||
|
@ -0,0 +1,24 @@ |
|||||||
|
<?php |
||||||
|
use yii\helpers\Html; |
||||||
|
use yii\mail\BaseMessage; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var \yii\web\View $this |
||||||
|
* @var BaseMessage $content |
||||||
|
*/ |
||||||
|
?> |
||||||
|
<?php $this->beginPage() ?> |
||||||
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> |
||||||
|
<html xmlns="http://www.w3.org/1999/xhtml"> |
||||||
|
<head> |
||||||
|
<meta http-equiv="Content-Type" content="text/html; charset=<?= Yii::$app->charset ?>" />
|
||||||
|
<title><?= Html::encode($this->title) ?></title>
|
||||||
|
<?php $this->head() ?> |
||||||
|
</head> |
||||||
|
<body> |
||||||
|
<?php $this->beginBody() ?> |
||||||
|
<?= $content ?> |
||||||
|
<?php $this->endBody() ?> |
||||||
|
</body> |
||||||
|
</html> |
||||||
|
<?php $this->endPage() ?> |
@ -0,0 +1,16 @@ |
|||||||
|
<?php |
||||||
|
use yii\helpers\Html; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var yii\web\View $this |
||||||
|
* @var common\models\User $user; |
||||||
|
*/ |
||||||
|
|
||||||
|
$resetLink = Yii::$app->urlManager->createAbsoluteUrl('site/reset-password', ['token' => $user->password_reset_token]); |
||||||
|
?> |
||||||
|
|
||||||
|
Hello <?= Html::encode($user->username) ?>,
|
||||||
|
|
||||||
|
Follow the link below to reset your password: |
||||||
|
|
||||||
|
<?= Html::a(Html::encode($resetLink), $resetLink) ?> |
@ -1,164 +0,0 @@ |
|||||||
{ |
|
||||||
"_readme": [ |
|
||||||
"This file locks the dependencies of your project to a known state", |
|
||||||
"Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file" |
|
||||||
], |
|
||||||
"hash": "2d1053fbaaf2044054f273a71d0ccde0", |
|
||||||
"packages": [ |
|
||||||
{ |
|
||||||
"name": "yiisoft/yii2", |
|
||||||
"version": "dev-master", |
|
||||||
"source": { |
|
||||||
"type": "git", |
|
||||||
"url": "https://github.com/yiisoft/yii2-framework.git", |
|
||||||
"reference": "3ad6334be076a80df3b2ea0b57f38bd0c6901989" |
|
||||||
}, |
|
||||||
"dist": { |
|
||||||
"type": "zip", |
|
||||||
"url": "https://api.github.com/repos/yiisoft/yii2-framework/zipball/3ad6334be076a80df3b2ea0b57f38bd0c6901989", |
|
||||||
"reference": "3ad6334be076a80df3b2ea0b57f38bd0c6901989", |
|
||||||
"shasum": "" |
|
||||||
}, |
|
||||||
"require": { |
|
||||||
"ext-mbstring": "*", |
|
||||||
"lib-pcre": "*", |
|
||||||
"php": ">=5.3.7" |
|
||||||
}, |
|
||||||
"suggest": { |
|
||||||
"ezyang/htmlpurifier": "Required by HtmlPurifier.", |
|
||||||
"michelf/php-markdown": "Required by Markdown.", |
|
||||||
"smarty/smarty": "Required by SmartyViewRenderer.", |
|
||||||
"twig/twig": "Required by TwigViewRenderer." |
|
||||||
}, |
|
||||||
"type": "library", |
|
||||||
"autoload": { |
|
||||||
"psr-0": { |
|
||||||
"yii\\": "/" |
|
||||||
} |
|
||||||
}, |
|
||||||
"notification-url": "https://packagist.org/downloads/", |
|
||||||
"license": [ |
|
||||||
"BSD-3-Clause" |
|
||||||
], |
|
||||||
"authors": [ |
|
||||||
{ |
|
||||||
"name": "Qiang Xue", |
|
||||||
"email": "qiang.xue@gmail.com", |
|
||||||
"homepage": "http://www.yiiframework.com/", |
|
||||||
"role": "Founder and project lead" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Alexander Makarov", |
|
||||||
"email": "sam@rmcreative.ru", |
|
||||||
"homepage": "http://rmcreative.ru/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Maurizio Domba", |
|
||||||
"homepage": "http://mdomba.info/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Carsten Brandt", |
|
||||||
"email": "mail@cebe.cc", |
|
||||||
"homepage": "http://cebe.cc/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Wei Zhuo", |
|
||||||
"email": "weizhuo@gmail.com", |
|
||||||
"role": "Project site maintenance and development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Sebastián Thierer", |
|
||||||
"email": "sebas@artfos.com", |
|
||||||
"role": "Component development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Jeffrey Winesett", |
|
||||||
"email": "jefftulsa@gmail.com", |
|
||||||
"role": "Documentation and marketing" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Timur Ruziev", |
|
||||||
"email": "resurtm@gmail.com", |
|
||||||
"homepage": "http://resurtm.com/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Paul Klimov", |
|
||||||
"email": "klimov.paul@gmail.com", |
|
||||||
"role": "Core framework development" |
|
||||||
} |
|
||||||
], |
|
||||||
"description": "Yii2 Web Programming Framework", |
|
||||||
"homepage": "http://www.yiiframework.com/", |
|
||||||
"keywords": [ |
|
||||||
"framework", |
|
||||||
"yii" |
|
||||||
], |
|
||||||
"time": "2013-06-02 19:19:29" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "yiisoft/yii2-composer", |
|
||||||
"version": "dev-master", |
|
||||||
"source": { |
|
||||||
"type": "git", |
|
||||||
"url": "https://github.com/yiisoft/yii2-composer.git", |
|
||||||
"reference": "7ce4060faca940b836ab88de207638940a0a0568" |
|
||||||
}, |
|
||||||
"dist": { |
|
||||||
"type": "zip", |
|
||||||
"url": "https://api.github.com/repos/yiisoft/yii2-composer/zipball/7ce4060faca940b836ab88de207638940a0a0568", |
|
||||||
"reference": "7ce4060faca940b836ab88de207638940a0a0568", |
|
||||||
"shasum": "" |
|
||||||
}, |
|
||||||
"require": { |
|
||||||
"yiisoft/yii2": "*" |
|
||||||
}, |
|
||||||
"type": "library", |
|
||||||
"autoload": { |
|
||||||
"psr-0": { |
|
||||||
"yii\\composer": "" |
|
||||||
} |
|
||||||
}, |
|
||||||
"notification-url": "https://packagist.org/downloads/", |
|
||||||
"license": [ |
|
||||||
"BSD-3-Clause" |
|
||||||
], |
|
||||||
"authors": [ |
|
||||||
{ |
|
||||||
"name": "Qiang Xue", |
|
||||||
"email": "qiang.xue@gmail.com", |
|
||||||
"homepage": "http://www.yiiframework.com/", |
|
||||||
"role": "Founder and project lead" |
|
||||||
} |
|
||||||
], |
|
||||||
"description": "The composer integration for the Yii framework", |
|
||||||
"keywords": [ |
|
||||||
"composer", |
|
||||||
"install", |
|
||||||
"update", |
|
||||||
"yii" |
|
||||||
], |
|
||||||
"time": "2013-05-23 19:12:45" |
|
||||||
} |
|
||||||
], |
|
||||||
"packages-dev": [ |
|
||||||
|
|
||||||
], |
|
||||||
"aliases": [ |
|
||||||
|
|
||||||
], |
|
||||||
"minimum-stability": "dev", |
|
||||||
"stability-flags": { |
|
||||||
"yiisoft/yii2": 20, |
|
||||||
"yiisoft/yii2-composer": 20 |
|
||||||
}, |
|
||||||
"platform": { |
|
||||||
"php": ">=5.3.0" |
|
||||||
}, |
|
||||||
"platform-dev": [ |
|
||||||
|
|
||||||
] |
|
||||||
} |
|
@ -1,5 +1,4 @@ |
|||||||
<?php |
<?php |
||||||
|
return [ |
||||||
return array( |
|
||||||
'adminEmail' => 'admin@example.com', |
'adminEmail' => 'admin@example.com', |
||||||
); |
]; |
||||||
|
@ -0,0 +1,11 @@ |
|||||||
|
<?php |
||||||
|
return [ |
||||||
|
'preload' => [ |
||||||
|
//'debug', |
||||||
|
], |
||||||
|
'modules' => [ |
||||||
|
// 'debug' => [ |
||||||
|
// 'class' => 'yii\debug\Module', |
||||||
|
// ], |
||||||
|
], |
||||||
|
]; |
@ -0,0 +1,3 @@ |
|||||||
|
<?php |
||||||
|
return [ |
||||||
|
]; |
@ -0,0 +1,14 @@ |
|||||||
|
<?php |
||||||
|
defined('YII_DEBUG') or define('YII_DEBUG', true); |
||||||
|
defined('YII_ENV') or define('YII_ENV', 'dev'); |
||||||
|
|
||||||
|
require(__DIR__ . '/../../vendor/autoload.php'); |
||||||
|
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
||||||
|
|
||||||
|
$config = yii\helpers\ArrayHelper::merge( |
||||||
|
require(__DIR__ . '/../config/main.php'), |
||||||
|
require(__DIR__ . '/../config/main-local.php') |
||||||
|
); |
||||||
|
|
||||||
|
$application = new yii\web\Application($config); |
||||||
|
$application->run(); |
@ -1,17 +0,0 @@ |
|||||||
<?php |
|
||||||
return array( |
|
||||||
'modules' => array( |
|
||||||
// 'debug' => array( |
|
||||||
// 'class' => 'yii\debug\Module', |
|
||||||
// ), |
|
||||||
), |
|
||||||
'components' => array( |
|
||||||
'log' => array( |
|
||||||
'targets' => array( |
|
||||||
// array( |
|
||||||
// 'class' => 'yii\logging\DebugTarget', |
|
||||||
// ) |
|
||||||
), |
|
||||||
), |
|
||||||
), |
|
||||||
); |
|
@ -1,3 +0,0 @@ |
|||||||
<?php |
|
||||||
return array( |
|
||||||
); |
|
@ -1,14 +0,0 @@ |
|||||||
<?php |
|
||||||
// comment out the following line to disable debug mode |
|
||||||
defined('YII_DEBUG') or define('YII_DEBUG', true); |
|
||||||
|
|
||||||
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
|
||||||
require(__DIR__ . '/../../vendor/autoload.php'); |
|
||||||
|
|
||||||
$config = yii\helpers\ArrayHelper::merge( |
|
||||||
require(__DIR__ . '/../config/main.php'), |
|
||||||
require(__DIR__ . '/../config/main-local.php') |
|
||||||
); |
|
||||||
|
|
||||||
$application = new yii\web\Application($config); |
|
||||||
$application->run(); |
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,17 +1,11 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
'modules' => array( |
'preload' => [ |
||||||
// 'debug' => array( |
//'debug', |
||||||
|
], |
||||||
|
'modules' => [ |
||||||
|
// 'debug' => [ |
||||||
// 'class' => 'yii\debug\Module', |
// 'class' => 'yii\debug\Module', |
||||||
// ), |
// ], |
||||||
), |
], |
||||||
'components' => array( |
]; |
||||||
'log' => array( |
|
||||||
'targets' => array( |
|
||||||
// array( |
|
||||||
// 'class' => 'yii\logging\DebugTarget', |
|
||||||
// ) |
|
||||||
), |
|
||||||
), |
|
||||||
), |
|
||||||
); |
|
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -0,0 +1,14 @@ |
|||||||
|
<?php |
||||||
|
defined('YII_DEBUG') or define('YII_DEBUG', true); |
||||||
|
defined('YII_ENV') or define('YII_ENV', 'dev'); |
||||||
|
|
||||||
|
require(__DIR__ . '/../../vendor/autoload.php'); |
||||||
|
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
||||||
|
|
||||||
|
$config = yii\helpers\ArrayHelper::merge( |
||||||
|
require(__DIR__ . '/../config/main.php'), |
||||||
|
require(__DIR__ . '/../config/main-local.php') |
||||||
|
); |
||||||
|
|
||||||
|
$application = new yii\web\Application($config); |
||||||
|
$application->run(); |
@ -1,15 +0,0 @@ |
|||||||
<?php |
|
||||||
|
|
||||||
// comment out the following line to disable debug mode |
|
||||||
defined('YII_DEBUG') or define('YII_DEBUG', true); |
|
||||||
|
|
||||||
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
|
||||||
require(__DIR__ . '/../../vendor/autoload.php'); |
|
||||||
|
|
||||||
$config = yii\helpers\ArrayHelper::merge( |
|
||||||
require(__DIR__ . '/../config/main.php'), |
|
||||||
require(__DIR__ . '/../config/main-local.php') |
|
||||||
); |
|
||||||
|
|
||||||
$application = new yii\web\Application($config); |
|
||||||
$application->run(); |
|
@ -0,0 +1,3 @@ |
|||||||
|
<?php |
||||||
|
return [ |
||||||
|
]; |
@ -0,0 +1,3 @@ |
|||||||
|
<?php |
||||||
|
return [ |
||||||
|
]; |
@ -0,0 +1,14 @@ |
|||||||
|
<?php |
||||||
|
defined('YII_DEBUG') or define('YII_DEBUG', false); |
||||||
|
defined('YII_ENV') or define('YII_ENV', 'prod'); |
||||||
|
|
||||||
|
require(__DIR__ . '/../../vendor/autoload.php'); |
||||||
|
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
||||||
|
|
||||||
|
$config = yii\helpers\ArrayHelper::merge( |
||||||
|
require(__DIR__ . '/../config/main.php'), |
||||||
|
require(__DIR__ . '/../config/main-local.php') |
||||||
|
); |
||||||
|
|
||||||
|
$application = new yii\web\Application($config); |
||||||
|
$application->run(); |
@ -1,3 +0,0 @@ |
|||||||
<?php |
|
||||||
return array( |
|
||||||
); |
|
@ -1,3 +0,0 @@ |
|||||||
<?php |
|
||||||
return array( |
|
||||||
); |
|
@ -1,14 +0,0 @@ |
|||||||
<?php |
|
||||||
// comment out the following line to disable debug mode |
|
||||||
defined('YII_DEBUG') or define('YII_DEBUG', false); |
|
||||||
|
|
||||||
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
|
||||||
require(__DIR__ . '/../../vendor/autoload.php'); |
|
||||||
|
|
||||||
$config = yii\helpers\ArrayHelper::merge( |
|
||||||
require(__DIR__ . '/../config/main.php'), |
|
||||||
require(__DIR__ . '/../config/main-local.php') |
|
||||||
); |
|
||||||
|
|
||||||
$application = new yii\web\Application($config); |
|
||||||
$application->run(); |
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -1,3 +1,3 @@ |
|||||||
<?php |
<?php |
||||||
return array( |
return [ |
||||||
); |
]; |
||||||
|
@ -0,0 +1,14 @@ |
|||||||
|
<?php |
||||||
|
defined('YII_DEBUG') or define('YII_DEBUG', false); |
||||||
|
defined('YII_ENV') or define('YII_ENV', 'prod'); |
||||||
|
|
||||||
|
require(__DIR__ . '/../../vendor/autoload.php'); |
||||||
|
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
||||||
|
|
||||||
|
$config = yii\helpers\ArrayHelper::merge( |
||||||
|
require(__DIR__ . '/../config/main.php'), |
||||||
|
require(__DIR__ . '/../config/main-local.php') |
||||||
|
); |
||||||
|
|
||||||
|
$application = new yii\web\Application($config); |
||||||
|
$application->run(); |
@ -1,15 +0,0 @@ |
|||||||
<?php |
|
||||||
|
|
||||||
// comment out the following line to disable debug mode |
|
||||||
defined('YII_DEBUG') or define('YII_DEBUG', false); |
|
||||||
|
|
||||||
require(__DIR__ . '/../../vendor/yiisoft/yii2/yii/Yii.php'); |
|
||||||
require(__DIR__ . '/../../vendor/autoload.php'); |
|
||||||
|
|
||||||
$config = yii\helpers\ArrayHelper::merge( |
|
||||||
require(__DIR__ . '/../config/main.php'), |
|
||||||
require(__DIR__ . '/../config/main-local.php') |
|
||||||
); |
|
||||||
|
|
||||||
$application = new yii\web\Application($config); |
|
||||||
$application->run(); |
|
@ -0,0 +1,29 @@ |
|||||||
|
<?php |
||||||
|
/** |
||||||
|
* @link http://www.yiiframework.com/ |
||||||
|
* @copyright Copyright (c) 2008 Yii Software LLC |
||||||
|
* @license http://www.yiiframework.com/license/ |
||||||
|
*/ |
||||||
|
|
||||||
|
namespace frontend\assets; |
||||||
|
|
||||||
|
use yii\web\AssetBundle; |
||||||
|
|
||||||
|
/** |
||||||
|
* @author Qiang Xue <qiang.xue@gmail.com> |
||||||
|
* @since 2.0 |
||||||
|
*/ |
||||||
|
class AppAsset extends AssetBundle |
||||||
|
{ |
||||||
|
public $basePath = '@webroot'; |
||||||
|
public $baseUrl = '@web'; |
||||||
|
public $css = [ |
||||||
|
'css/site.css', |
||||||
|
]; |
||||||
|
public $js = [ |
||||||
|
]; |
||||||
|
public $depends = [ |
||||||
|
'yii\web\YiiAsset', |
||||||
|
'yii\bootstrap\BootstrapAsset', |
||||||
|
]; |
||||||
|
} |
@ -1,18 +0,0 @@ |
|||||||
<?php |
|
||||||
|
|
||||||
return array( |
|
||||||
'app' => array( |
|
||||||
'basePath' => '@wwwroot', |
|
||||||
'baseUrl' => '@www', |
|
||||||
'css' => array( |
|
||||||
'css/site.css', |
|
||||||
), |
|
||||||
'js' => array( |
|
||||||
|
|
||||||
), |
|
||||||
'depends' => array( |
|
||||||
'yii', |
|
||||||
'yii/bootstrap/responsive', |
|
||||||
), |
|
||||||
), |
|
||||||
); |
|
@ -1,5 +1,4 @@ |
|||||||
<?php |
<?php |
||||||
|
return [ |
||||||
return array( |
|
||||||
'adminEmail' => 'admin@example.com', |
'adminEmail' => 'admin@example.com', |
||||||
); |
]; |
||||||
|
@ -1,66 +1,69 @@ |
|||||||
<?php |
<?php |
||||||
use yii\helpers\Html; |
use yii\helpers\Html; |
||||||
use yii\widgets\Menu; |
use yii\bootstrap\Nav; |
||||||
|
use yii\bootstrap\NavBar; |
||||||
use yii\widgets\Breadcrumbs; |
use yii\widgets\Breadcrumbs; |
||||||
use yii\debug\Toolbar; |
use frontend\assets\AppAsset; |
||||||
|
use frontend\widgets\Alert; |
||||||
|
|
||||||
/** |
/** |
||||||
* @var $this \yii\base\View |
* @var \yii\web\View $this |
||||||
* @var $content string |
* @var string $content |
||||||
*/ |
*/ |
||||||
$this->registerAssetBundle('app'); |
AppAsset::register($this); |
||||||
?> |
?> |
||||||
<?php $this->beginPage(); ?> |
<?php $this->beginPage() ?> |
||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html lang="en"> |
<html lang="<?= Yii::$app->language ?>">
|
||||||
<head> |
<head> |
||||||
<meta charset="utf-8"/> |
<meta charset="<?= Yii::$app->charset ?>"/>
|
||||||
<title><?php echo Html::encode($this->title); ?></title>
|
<title><?= Html::encode($this->title) ?></title>
|
||||||
<?php $this->head(); ?> |
<?php $this->head() ?> |
||||||
</head> |
</head> |
||||||
<body> |
<body> |
||||||
<div class="container"> |
<?php $this->beginBody() ?> |
||||||
<?php $this->beginBody(); ?> |
<?php |
||||||
<div class="masthead"> |
NavBar::begin([ |
||||||
<h3 class="muted">My Company</h3> |
'brandLabel' => 'My Company', |
||||||
|
'brandUrl' => Yii::$app->homeUrl, |
||||||
|
'options' => [ |
||||||
|
'class' => 'navbar-inverse navbar-fixed-top', |
||||||
|
], |
||||||
|
]); |
||||||
|
$menuItems = [ |
||||||
|
['label' => 'Home', 'url' => ['/site/index']], |
||||||
|
['label' => 'About', 'url' => ['/site/about']], |
||||||
|
['label' => 'Contact', 'url' => ['/site/contact']], |
||||||
|
]; |
||||||
|
if (Yii::$app->user->isGuest) { |
||||||
|
$menuItems[] = ['label' => 'Signup', 'url' => ['/site/signup']]; |
||||||
|
$menuItems[] = ['label' => 'Login', 'url' => ['/site/login']]; |
||||||
|
} else { |
||||||
|
$menuItems[] = ['label' => 'Logout (' . Yii::$app->user->identity->username .')' , 'url' => ['/site/logout']]; |
||||||
|
} |
||||||
|
echo Nav::widget([ |
||||||
|
'options' => ['class' => 'navbar-nav navbar-right'], |
||||||
|
'items' => $menuItems, |
||||||
|
]); |
||||||
|
NavBar::end(); |
||||||
|
?> |
||||||
|
|
||||||
<div class="navbar"> |
|
||||||
<div class="navbar-inner"> |
|
||||||
<div class="container"> |
<div class="container"> |
||||||
<?php echo Menu::widget(array( |
<?= Breadcrumbs::widget([ |
||||||
'options' => array('class' => 'nav'), |
'links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : [], |
||||||
'items' => array( |
]) ?> |
||||||
array('label' => 'Home', 'url' => array('/site/index')), |
<?= Alert::widget() ?> |
||||||
array('label' => 'About', 'url' => array('/site/about')), |
<?= $content ?> |
||||||
array('label' => 'Contact', 'url' => array('/site/contact')), |
|
||||||
Yii::$app->user->isGuest ? |
|
||||||
array('label' => 'Login', 'url' => array('/site/login')) : |
|
||||||
array('label' => 'Logout (' . Yii::$app->user->identity->username .')' , 'url' => array('/site/logout')), |
|
||||||
), |
|
||||||
)); ?> |
|
||||||
</div> |
</div> |
||||||
</div> |
|
||||||
</div> |
|
||||||
<!-- /.navbar --> |
|
||||||
</div> |
|
||||||
|
|
||||||
<?php echo Breadcrumbs::widget(array( |
|
||||||
'links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : array(), |
|
||||||
)); ?> |
|
||||||
<?php echo $content; ?> |
|
||||||
|
|
||||||
<hr> |
<footer class="footer"> |
||||||
|
<div class="container"> |
||||||
<div class="footer"> |
<p class="pull-left">© My Company <?= date('Y') ?></p>
|
||||||
<p>© My Company <?php echo date('Y'); ?></p>
|
<p class="pull-right"><?= Yii::powered() ?></p>
|
||||||
<p> |
|
||||||
<?php echo Yii::powered(); ?> |
|
||||||
Template by <a href="http://twitter.github.io/bootstrap/">Twitter Bootstrap</a> |
|
||||||
</p> |
|
||||||
</div> |
</div> |
||||||
<?php $this->endBody(); ?> |
</footer> |
||||||
</div> |
|
||||||
<?php echo Toolbar::widget(); ?> |
<?php $this->endBody() ?> |
||||||
</body> |
</body> |
||||||
</html> |
</html> |
||||||
<?php $this->endPage(); ?> |
<?php $this->endPage() ?> |
||||||
|
@ -1,16 +1,16 @@ |
|||||||
<?php |
<?php |
||||||
use yii\helpers\Html; |
use yii\helpers\Html; |
||||||
|
|
||||||
/** |
/** |
||||||
* @var yii\base\View $this |
* @var yii\web\View $this |
||||||
*/ |
*/ |
||||||
$this->title = 'About'; |
$this->title = 'About'; |
||||||
$this->params['breadcrumbs'][] = $this->title; |
$this->params['breadcrumbs'][] = $this->title; |
||||||
?> |
?> |
||||||
<h1><?php echo Html::encode($this->title); ?></h1>
|
<div class="site-about"> |
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
<p> |
|
||||||
This is the About page. You may modify the following file to customize its content: |
|
||||||
</p> |
|
||||||
|
|
||||||
<code><?php echo __FILE__; ?></code>
|
<p>This is the About page. You may modify the following file to customize its content:</p> |
||||||
|
|
||||||
|
<code><?= __FILE__ ?></code>
|
||||||
|
</div> |
||||||
|
@ -1,46 +1,39 @@ |
|||||||
<?php |
<?php |
||||||
use yii\helpers\Html; |
use yii\helpers\Html; |
||||||
use yii\widgets\ActiveForm; |
use yii\widgets\ActiveForm; |
||||||
use yii\widgets\Captcha; |
use yii\captcha\Captcha; |
||||||
|
|
||||||
/** |
/** |
||||||
* @var yii\base\View $this |
* @var yii\web\View $this |
||||||
* @var yii\widgets\ActiveForm $form |
* @var yii\widgets\ActiveForm $form |
||||||
* @var app\models\ContactForm $model |
* @var app\models\ContactForm $model |
||||||
*/ |
*/ |
||||||
$this->title = 'Contact'; |
$this->title = 'Contact'; |
||||||
$this->params['breadcrumbs'][] = $this->title; |
$this->params['breadcrumbs'][] = $this->title; |
||||||
?> |
?> |
||||||
<h1><?php echo Html::encode($this->title); ?></h1>
|
<div class="site-contact"> |
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
|
|
||||||
<?php if (Yii::$app->session->hasFlash('contactFormSubmitted')): ?> |
<p> |
||||||
<div class="alert alert-success"> |
|
||||||
Thank you for contacting us. We will respond to you as soon as possible. |
|
||||||
</div> |
|
||||||
<?php return; endif; ?> |
|
||||||
|
|
||||||
<p> |
|
||||||
If you have business inquiries or other questions, please fill out the following form to contact us. Thank you. |
If you have business inquiries or other questions, please fill out the following form to contact us. Thank you. |
||||||
</p> |
</p> |
||||||
|
|
||||||
<?php $form = ActiveForm::begin(array( |
<div class="row"> |
||||||
'options' => array('class' => 'form-horizontal'), |
<div class="col-lg-5"> |
||||||
'fieldConfig' => array('inputOptions' => array('class' => 'input-xlarge')), |
<?php $form = ActiveForm::begin(['id' => 'contact-form']); ?> |
||||||
)); ?> |
<?= $form->field($model, 'name') ?> |
||||||
<?php echo $form->field($model, 'name')->textInput(); ?> |
<?= $form->field($model, 'email') ?> |
||||||
<?php echo $form->field($model, 'email')->textInput(); ?> |
<?= $form->field($model, 'subject') ?> |
||||||
<?php echo $form->field($model, 'subject')->textInput(); ?> |
<?= $form->field($model, 'body')->textArea(['rows' => 6]) ?> |
||||||
<?php echo $form->field($model, 'body')->textArea(array('rows' => 6)); ?> |
<?= $form->field($model, 'verifyCode')->widget(Captcha::className(), [ |
||||||
<?php |
'options' => ['class' => 'form-control'], |
||||||
$field = $form->field($model, 'verifyCode'); |
'template' => '<div class="row"><div class="col-lg-3">{image}</div><div class="col-lg-6">{input}</div></div>', |
||||||
echo $field->begin() |
]) ?> |
||||||
. $field->label() |
<div class="form-group"> |
||||||
. Captcha::widget() |
<?= Html::submitButton('Submit', ['class' => 'btn btn-primary']) ?> |
||||||
. Html::activeTextInput($model, 'verifyCode', array('class' => 'input-medium')) |
</div> |
||||||
. $field->error() |
<?php ActiveForm::end(); ?> |
||||||
. $field->end(); |
|
||||||
?> |
|
||||||
<div class="form-actions"> |
|
||||||
<?php echo Html::submitButton('Submit', null, null, array('class' => 'btn btn-primary')); ?> |
|
||||||
</div> |
</div> |
||||||
<?php ActiveForm::end(); ?> |
</div> |
||||||
|
|
||||||
|
</div> |
||||||
|
@ -0,0 +1,29 @@ |
|||||||
|
<?php |
||||||
|
|
||||||
|
use yii\helpers\Html; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var yii\web\View $this |
||||||
|
* @var string $name |
||||||
|
* @var string $message |
||||||
|
* @var Exception $exception |
||||||
|
*/ |
||||||
|
|
||||||
|
$this->title = $name; |
||||||
|
?> |
||||||
|
<div class="site-error"> |
||||||
|
|
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
|
|
||||||
|
<div class="alert alert-danger"> |
||||||
|
<?= nl2br(Html::encode($message)) ?> |
||||||
|
</div> |
||||||
|
|
||||||
|
<p> |
||||||
|
The above error occurred while the Web server was processing your request. |
||||||
|
</p> |
||||||
|
<p> |
||||||
|
Please contact us if you think this is a server error. Thank you. |
||||||
|
</p> |
||||||
|
|
||||||
|
</div> |
@ -1,47 +1,53 @@ |
|||||||
<?php |
<?php |
||||||
/** |
/** |
||||||
* @var yii\base\View $this |
* @var yii\web\View $this |
||||||
*/ |
*/ |
||||||
$this->title = 'Welcome'; |
$this->title = 'My Yii Application'; |
||||||
?> |
?> |
||||||
<div class="jumbotron"> |
<div class="site-index"> |
||||||
<h1>Welcome!</h1> |
|
||||||
|
|
||||||
<p class="lead">Cras justo odio, dapibus ac facilisis in, egestas eget quam. Fusce dapibus, tellus ac cursus |
<div class="jumbotron"> |
||||||
commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus.</p> |
<h1>Congratulations!</h1> |
||||||
<a class="btn btn-large btn-success" href="http://www.yiiframework.com">Get started with Yii</a> |
|
||||||
</div> |
<p class="lead">You have successfully created your Yii-powered application.</p> |
||||||
|
|
||||||
|
<p><a class="btn btn-lg btn-success" href="http://www.yiiframework.com">Get started with Yii</a></p> |
||||||
|
</div> |
||||||
|
|
||||||
<hr> |
<div class="body-content"> |
||||||
|
|
||||||
<!-- Example row of columns --> |
<div class="row"> |
||||||
<div class="row-fluid"> |
<div class="col-lg-4"> |
||||||
<div class="span4"> |
|
||||||
<h2>Heading</h2> |
<h2>Heading</h2> |
||||||
|
|
||||||
<p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et |
||||||
condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. |
dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip |
||||||
Donec sed odio dui. </p> |
ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu |
||||||
|
fugiat nulla pariatur.</p> |
||||||
|
|
||||||
<p><a class="btn" href="#">View details »</a></p> |
<p><a class="btn btn-default" href="http://www.yiiframework.com/doc/">Yii Documentation »</a></p> |
||||||
</div> |
</div> |
||||||
<div class="span4"> |
<div class="col-lg-4"> |
||||||
<h2>Heading</h2> |
<h2>Heading</h2> |
||||||
|
|
||||||
<p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et |
||||||
condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. |
dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip |
||||||
Donec sed odio dui. </p> |
ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu |
||||||
|
fugiat nulla pariatur.</p> |
||||||
|
|
||||||
<p><a class="btn" href="#">View details »</a></p> |
<p><a class="btn btn-default" href="http://www.yiiframework.com/forum/">Yii Forum »</a></p> |
||||||
</div> |
</div> |
||||||
<div class="span4"> |
<div class="col-lg-4"> |
||||||
<h2>Heading</h2> |
<h2>Heading</h2> |
||||||
|
|
||||||
<p>Donec sed odio dui. Cras justo odio, dapibus ac facilisis in, egestas eget quam. Vestibulum id ligula porta |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et |
||||||
felis euismod semper. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum |
dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip |
||||||
massa.</p> |
ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu |
||||||
|
fugiat nulla pariatur.</p> |
||||||
|
|
||||||
<p><a class="btn" href="#">View details »</a></p> |
<p><a class="btn btn-default" href="http://www.yiiframework.com/extensions/">Yii Extensions »</a></p> |
||||||
|
</div> |
||||||
</div> |
</div> |
||||||
</div> |
|
||||||
|
|
||||||
|
</div> |
||||||
|
</div> |
||||||
|
@ -0,0 +1,28 @@ |
|||||||
|
<?php |
||||||
|
use yii\helpers\Html; |
||||||
|
use yii\widgets\ActiveForm; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var yii\web\View $this |
||||||
|
* @var yii\widgets\ActiveForm $form |
||||||
|
* @var common\models\User $model |
||||||
|
*/ |
||||||
|
$this->title = 'Request password reset'; |
||||||
|
$this->params['breadcrumbs'][] = $this->title; |
||||||
|
?> |
||||||
|
<div class="site-request-password-reset"> |
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
|
|
||||||
|
<p>Please fill out your email. A link to reset password will be sent there.</p> |
||||||
|
|
||||||
|
<div class="row"> |
||||||
|
<div class="col-lg-5"> |
||||||
|
<?php $form = ActiveForm::begin(['id' => 'request-password-reset-form']); ?> |
||||||
|
<?= $form->field($model, 'email') ?> |
||||||
|
<div class="form-group"> |
||||||
|
<?= Html::submitButton('Send', ['class' => 'btn btn-primary']) ?> |
||||||
|
</div> |
||||||
|
<?php ActiveForm::end(); ?> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</div> |
@ -0,0 +1,28 @@ |
|||||||
|
<?php |
||||||
|
use yii\helpers\Html; |
||||||
|
use yii\widgets\ActiveForm; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var yii\web\View $this |
||||||
|
* @var yii\widgets\ActiveForm $form |
||||||
|
* @var common\models\User $model |
||||||
|
*/ |
||||||
|
$this->title = 'Reset password'; |
||||||
|
$this->params['breadcrumbs'][] = $this->title; |
||||||
|
?> |
||||||
|
<div class="site-reset-password"> |
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
|
|
||||||
|
<p>Please choose your new password:</p> |
||||||
|
|
||||||
|
<div class="row"> |
||||||
|
<div class="col-lg-5"> |
||||||
|
<?php $form = ActiveForm::begin(['id' => 'reset-password-form']); ?> |
||||||
|
<?= $form->field($model, 'password')->passwordInput() ?> |
||||||
|
<div class="form-group"> |
||||||
|
<?= Html::submitButton('Save', ['class' => 'btn btn-primary']) ?> |
||||||
|
</div> |
||||||
|
<?php ActiveForm::end(); ?> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</div> |
@ -0,0 +1,30 @@ |
|||||||
|
<?php |
||||||
|
use yii\helpers\Html; |
||||||
|
use yii\widgets\ActiveForm; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var yii\web\View $this |
||||||
|
* @var yii\widgets\ActiveForm $form |
||||||
|
* @var common\models\User $model |
||||||
|
*/ |
||||||
|
$this->title = 'Signup'; |
||||||
|
$this->params['breadcrumbs'][] = $this->title; |
||||||
|
?> |
||||||
|
<div class="site-signup"> |
||||||
|
<h1><?= Html::encode($this->title) ?></h1>
|
||||||
|
|
||||||
|
<p>Please fill out the following fields to signup:</p> |
||||||
|
|
||||||
|
<div class="row"> |
||||||
|
<div class="col-lg-5"> |
||||||
|
<?php $form = ActiveForm::begin(['id' => 'form-signup']); ?> |
||||||
|
<?= $form->field($model, 'username') ?> |
||||||
|
<?= $form->field($model, 'email') ?> |
||||||
|
<?= $form->field($model, 'password')->passwordInput() ?> |
||||||
|
<div class="form-group"> |
||||||
|
<?= Html::submitButton('Signup', ['class' => 'btn btn-primary']) ?> |
||||||
|
</div> |
||||||
|
<?php ActiveForm::end(); ?> |
||||||
|
</div> |
||||||
|
</div> |
||||||
|
</div> |
@ -0,0 +1,45 @@ |
|||||||
|
body { |
||||||
|
padding-top: 70px; |
||||||
|
} |
||||||
|
|
||||||
|
.footer { |
||||||
|
border-top: 1px solid #ddd; |
||||||
|
margin-top: 30px; |
||||||
|
padding-top: 15px; |
||||||
|
padding-bottom: 30px; |
||||||
|
} |
||||||
|
|
||||||
|
.jumbotron { |
||||||
|
text-align: center; |
||||||
|
background-color: transparent; |
||||||
|
} |
||||||
|
.jumbotron .btn { |
||||||
|
font-size: 21px; |
||||||
|
padding: 14px 24px; |
||||||
|
} |
||||||
|
|
||||||
|
.not-set { |
||||||
|
color: #c55; |
||||||
|
font-style: italic; |
||||||
|
} |
||||||
|
|
||||||
|
/* add sorting icons to gridview sort links */ |
||||||
|
a.asc:after, a.desc:after { |
||||||
|
position: relative; |
||||||
|
top: 1px; |
||||||
|
display: inline-block; |
||||||
|
font-family: 'Glyphicons Halflings'; |
||||||
|
font-style: normal; |
||||||
|
font-weight: normal; |
||||||
|
line-height: 1; |
||||||
|
padding-left: 5px; |
||||||
|
} |
||||||
|
|
||||||
|
a.asc:after { content: /*"\e113"*/"\e151"; } |
||||||
|
a.desc:after { content: /*"\e114"*/"\e152"; } |
||||||
|
|
||||||
|
.sort-numerical a.asc:after { content: "\e153"; } |
||||||
|
.sort-numerical a.desc:after { content: "\e154"; } |
||||||
|
|
||||||
|
.sort-ordinal a.asc:after { content: "\e155"; } |
||||||
|
.sort-ordinal a.desc:after { content: "\e156"; } |
After Width: | Height: | Size: 1.1 KiB |
@ -0,0 +1,66 @@ |
|||||||
|
<?php |
||||||
|
/** |
||||||
|
* @link http://www.yiiframework.com/ |
||||||
|
* @copyright Copyright (c) 2008 Yii Software LLC |
||||||
|
* @license http://www.yiiframework.com/license/ |
||||||
|
*/ |
||||||
|
|
||||||
|
namespace frontend\widgets; |
||||||
|
|
||||||
|
/** |
||||||
|
* Alert widget renders a message from session flash. All flash messages are displayed |
||||||
|
* in the sequence they were assigned using setFlash. You can set message as following: |
||||||
|
* |
||||||
|
* - \Yii::$app->getSession()->setFlash('error', 'This is the message'); |
||||||
|
* - \Yii::$app->getSession()->setFlash('success', 'This is the message'); |
||||||
|
* - \Yii::$app->getSession()->setFlash('info', 'This is the message'); |
||||||
|
* |
||||||
|
* @author Kartik Visweswaran <kartikv2@gmail.com> |
||||||
|
* @author Alexander Makarov <sam@rmcerative.ru> |
||||||
|
*/ |
||||||
|
class Alert extends \yii\bootstrap\Widget |
||||||
|
{ |
||||||
|
/** |
||||||
|
* @var array the alert types configuration for the flash messages. |
||||||
|
* This array is setup as $key => $value, where: |
||||||
|
* - $key is the name of the session flash variable |
||||||
|
* - $value is the bootstrap alert type (i.e. danger, success, info, warning) |
||||||
|
*/ |
||||||
|
public $alertTypes = [ |
||||||
|
'error' => 'danger', |
||||||
|
'danger' => 'danger', |
||||||
|
'success' => 'success', |
||||||
|
'info' => 'info', |
||||||
|
'warning' => 'warning' |
||||||
|
]; |
||||||
|
|
||||||
|
/** |
||||||
|
* @var array the options for rendering the close button tag. |
||||||
|
*/ |
||||||
|
public $closeButton = []; |
||||||
|
|
||||||
|
public function init() |
||||||
|
{ |
||||||
|
parent::init(); |
||||||
|
|
||||||
|
$session = \Yii::$app->getSession(); |
||||||
|
$flashes = $session->getAllFlashes(); |
||||||
|
$appendCss = isset($this->options['class']) ? ' ' . $this->options['class'] : ''; |
||||||
|
|
||||||
|
foreach ($flashes as $type => $message) { |
||||||
|
/* initialize css class for each alert box */ |
||||||
|
$this->options['class'] = 'alert-' . $this->alertTypes[$type] . $appendCss; |
||||||
|
|
||||||
|
/* assign unique id to each alert box */ |
||||||
|
$this->options['id'] = $this->getId() . '-' . $type; |
||||||
|
|
||||||
|
echo \yii\bootstrap\Alert::widget([ |
||||||
|
'body' => $message, |
||||||
|
'closeButton' => $this->closeButton, |
||||||
|
'options' => $this->options |
||||||
|
]); |
||||||
|
|
||||||
|
$session->removeFlash($type); |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -1,78 +0,0 @@ |
|||||||
body { |
|
||||||
padding-top: 20px; |
|
||||||
padding-bottom: 60px; |
|
||||||
} |
|
||||||
|
|
||||||
/* Custom container */ |
|
||||||
.container { |
|
||||||
margin: 0 auto; |
|
||||||
max-width: 1000px; |
|
||||||
} |
|
||||||
|
|
||||||
.container > hr { |
|
||||||
margin: 60px 0; |
|
||||||
} |
|
||||||
|
|
||||||
/* Main marketing message and sign up button */ |
|
||||||
.jumbotron { |
|
||||||
margin: 80px 0; |
|
||||||
text-align: center; |
|
||||||
} |
|
||||||
|
|
||||||
.jumbotron h1 { |
|
||||||
font-size: 100px; |
|
||||||
line-height: 1; |
|
||||||
} |
|
||||||
|
|
||||||
.jumbotron .lead { |
|
||||||
font-size: 24px; |
|
||||||
line-height: 1.25; |
|
||||||
} |
|
||||||
|
|
||||||
.jumbotron .btn { |
|
||||||
font-size: 21px; |
|
||||||
padding: 14px 24px; |
|
||||||
} |
|
||||||
|
|
||||||
/* Supporting marketing content */ |
|
||||||
.marketing { |
|
||||||
margin: 60px 0; |
|
||||||
} |
|
||||||
|
|
||||||
.marketing p + h4 { |
|
||||||
margin-top: 28px; |
|
||||||
} |
|
||||||
|
|
||||||
/* Customize the navbar links to be fill the entire space of the .navbar */ |
|
||||||
.navbar .navbar-inner { |
|
||||||
padding: 0; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav { |
|
||||||
margin: 0; |
|
||||||
display: table; |
|
||||||
width: 100%; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li { |
|
||||||
display: table-cell; |
|
||||||
width: 1%; |
|
||||||
float: none; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li a { |
|
||||||
font-weight: bold; |
|
||||||
text-align: center; |
|
||||||
border-left: 1px solid rgba(255, 255, 255, .75); |
|
||||||
border-right: 1px solid rgba(0, 0, 0, .1); |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li:first-child a { |
|
||||||
border-left: 0; |
|
||||||
border-radius: 3px 0 0 3px; |
|
||||||
} |
|
||||||
|
|
||||||
.navbar .nav li:last-child a { |
|
||||||
border-right: 0; |
|
||||||
border-radius: 0 3px 3px 0; |
|
||||||
} |
|
@ -0,0 +1,29 @@ |
|||||||
|
<?php |
||||||
|
/** |
||||||
|
* @link http://www.yiiframework.com/ |
||||||
|
* @copyright Copyright (c) 2008 Yii Software LLC |
||||||
|
* @license http://www.yiiframework.com/license/ |
||||||
|
*/ |
||||||
|
|
||||||
|
namespace app\assets; |
||||||
|
|
||||||
|
use yii\web\AssetBundle; |
||||||
|
|
||||||
|
/** |
||||||
|
* @author Qiang Xue <qiang.xue@gmail.com> |
||||||
|
* @since 2.0 |
||||||
|
*/ |
||||||
|
class AppAsset extends AssetBundle |
||||||
|
{ |
||||||
|
public $basePath = '@webroot'; |
||||||
|
public $baseUrl = '@web'; |
||||||
|
public $css = [ |
||||||
|
'css/site.css', |
||||||
|
]; |
||||||
|
public $js = [ |
||||||
|
]; |
||||||
|
public $depends = [ |
||||||
|
'yii\web\YiiAsset', |
||||||
|
'yii\bootstrap\BootstrapAsset', |
||||||
|
]; |
||||||
|
} |
@ -0,0 +1,18 @@ |
|||||||
|
paths: |
||||||
|
tests: tests |
||||||
|
log: tests/_log |
||||||
|
data: tests/_data |
||||||
|
helpers: tests/_helpers |
||||||
|
settings: |
||||||
|
bootstrap: _bootstrap.php |
||||||
|
suite_class: \PHPUnit_Framework_TestSuite |
||||||
|
memory_limit: 1024M |
||||||
|
log: true |
||||||
|
colors: true |
||||||
|
modules: |
||||||
|
config: |
||||||
|
Db: |
||||||
|
dsn: '' |
||||||
|
user: '' |
||||||
|
password: '' |
||||||
|
dump: tests/_data/dump.sql |
@ -1,164 +0,0 @@ |
|||||||
{ |
|
||||||
"_readme": [ |
|
||||||
"This file locks the dependencies of your project to a known state", |
|
||||||
"Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file" |
|
||||||
], |
|
||||||
"hash": "91ba258de768b93025f86071f3bb4b84", |
|
||||||
"packages": [ |
|
||||||
{ |
|
||||||
"name": "yiisoft/yii2", |
|
||||||
"version": "dev-master", |
|
||||||
"source": { |
|
||||||
"type": "git", |
|
||||||
"url": "https://github.com/yiisoft/yii2-framework.git", |
|
||||||
"reference": "3ad6334be076a80df3b2ea0b57f38bd0c6901989" |
|
||||||
}, |
|
||||||
"dist": { |
|
||||||
"type": "zip", |
|
||||||
"url": "https://api.github.com/repos/yiisoft/yii2-framework/zipball/3ad6334be076a80df3b2ea0b57f38bd0c6901989", |
|
||||||
"reference": "3ad6334be076a80df3b2ea0b57f38bd0c6901989", |
|
||||||
"shasum": "" |
|
||||||
}, |
|
||||||
"require": { |
|
||||||
"ext-mbstring": "*", |
|
||||||
"lib-pcre": "*", |
|
||||||
"php": ">=5.3.7" |
|
||||||
}, |
|
||||||
"suggest": { |
|
||||||
"ezyang/htmlpurifier": "Required by HtmlPurifier.", |
|
||||||
"michelf/php-markdown": "Required by Markdown.", |
|
||||||
"smarty/smarty": "Required by SmartyViewRenderer.", |
|
||||||
"twig/twig": "Required by TwigViewRenderer." |
|
||||||
}, |
|
||||||
"type": "library", |
|
||||||
"autoload": { |
|
||||||
"psr-0": { |
|
||||||
"yii\\": "/" |
|
||||||
} |
|
||||||
}, |
|
||||||
"notification-url": "https://packagist.org/downloads/", |
|
||||||
"license": [ |
|
||||||
"BSD-3-Clause" |
|
||||||
], |
|
||||||
"authors": [ |
|
||||||
{ |
|
||||||
"name": "Qiang Xue", |
|
||||||
"email": "qiang.xue@gmail.com", |
|
||||||
"homepage": "http://www.yiiframework.com/", |
|
||||||
"role": "Founder and project lead" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Alexander Makarov", |
|
||||||
"email": "sam@rmcreative.ru", |
|
||||||
"homepage": "http://rmcreative.ru/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Maurizio Domba", |
|
||||||
"homepage": "http://mdomba.info/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Carsten Brandt", |
|
||||||
"email": "mail@cebe.cc", |
|
||||||
"homepage": "http://cebe.cc/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Wei Zhuo", |
|
||||||
"email": "weizhuo@gmail.com", |
|
||||||
"role": "Project site maintenance and development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Sebastián Thierer", |
|
||||||
"email": "sebas@artfos.com", |
|
||||||
"role": "Component development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Jeffrey Winesett", |
|
||||||
"email": "jefftulsa@gmail.com", |
|
||||||
"role": "Documentation and marketing" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Timur Ruziev", |
|
||||||
"email": "resurtm@gmail.com", |
|
||||||
"homepage": "http://resurtm.com/", |
|
||||||
"role": "Core framework development" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "Paul Klimov", |
|
||||||
"email": "klimov.paul@gmail.com", |
|
||||||
"role": "Core framework development" |
|
||||||
} |
|
||||||
], |
|
||||||
"description": "Yii2 Web Programming Framework", |
|
||||||
"homepage": "http://www.yiiframework.com/", |
|
||||||
"keywords": [ |
|
||||||
"framework", |
|
||||||
"yii" |
|
||||||
], |
|
||||||
"time": "2013-06-02 19:19:29" |
|
||||||
}, |
|
||||||
{ |
|
||||||
"name": "yiisoft/yii2-composer", |
|
||||||
"version": "dev-master", |
|
||||||
"source": { |
|
||||||
"type": "git", |
|
||||||
"url": "https://github.com/yiisoft/yii2-composer.git", |
|
||||||
"reference": "7ce4060faca940b836ab88de207638940a0a0568" |
|
||||||
}, |
|
||||||
"dist": { |
|
||||||
"type": "zip", |
|
||||||
"url": "https://api.github.com/repos/yiisoft/yii2-composer/zipball/7ce4060faca940b836ab88de207638940a0a0568", |
|
||||||
"reference": "7ce4060faca940b836ab88de207638940a0a0568", |
|
||||||
"shasum": "" |
|
||||||
}, |
|
||||||
"require": { |
|
||||||
"yiisoft/yii2": "*" |
|
||||||
}, |
|
||||||
"type": "library", |
|
||||||
"autoload": { |
|
||||||
"psr-0": { |
|
||||||
"yii\\composer": "" |
|
||||||
} |
|
||||||
}, |
|
||||||
"notification-url": "https://packagist.org/downloads/", |
|
||||||
"license": [ |
|
||||||
"BSD-3-Clause" |
|
||||||
], |
|
||||||
"authors": [ |
|
||||||
{ |
|
||||||
"name": "Qiang Xue", |
|
||||||
"email": "qiang.xue@gmail.com", |
|
||||||
"homepage": "http://www.yiiframework.com/", |
|
||||||
"role": "Founder and project lead" |
|
||||||
} |
|
||||||
], |
|
||||||
"description": "The composer integration for the Yii framework", |
|
||||||
"keywords": [ |
|
||||||
"composer", |
|
||||||
"install", |
|
||||||
"update", |
|
||||||
"yii" |
|
||||||
], |
|
||||||
"time": "2013-05-23 19:12:45" |
|
||||||
} |
|
||||||
], |
|
||||||
"packages-dev": [ |
|
||||||
|
|
||||||
], |
|
||||||
"aliases": [ |
|
||||||
|
|
||||||
], |
|
||||||
"minimum-stability": "dev", |
|
||||||
"stability-flags": { |
|
||||||
"yiisoft/yii2": 20, |
|
||||||
"yiisoft/yii2-composer": 20 |
|
||||||
}, |
|
||||||
"platform": { |
|
||||||
"php": ">=5.3.0" |
|
||||||
}, |
|
||||||
"platform-dev": [ |
|
||||||
|
|
||||||
] |
|
||||||
} |
|
@ -1,18 +0,0 @@ |
|||||||
<?php |
|
||||||
|
|
||||||
return array( |
|
||||||
'app' => array( |
|
||||||
'basePath' => '@wwwroot', |
|
||||||
'baseUrl' => '@www', |
|
||||||
'css' => array( |
|
||||||
'css/site.css', |
|
||||||
), |
|
||||||
'js' => array( |
|
||||||
|
|
||||||
), |
|
||||||
'depends' => array( |
|
||||||
'yii', |
|
||||||
'yii/bootstrap/responsive', |
|
||||||
), |
|
||||||
), |
|
||||||
); |
|
@ -0,0 +1,11 @@ |
|||||||
|
<?php |
||||||
|
|
||||||
|
// configuration adjustments for codeception acceptance tests. Will be merged with web.php config. |
||||||
|
|
||||||
|
return [ |
||||||
|
'components' => [ |
||||||
|
'db' => [ |
||||||
|
'dsn' => 'mysql:host=localhost;dbname=yii2basic_acceptance', |
||||||
|
], |
||||||
|
], |
||||||
|
]; |
@ -0,0 +1,11 @@ |
|||||||
|
<?php |
||||||
|
|
||||||
|
// configuration adjustments for codeception functional tests. Will be merged with web.php config. |
||||||
|
|
||||||
|
return [ |
||||||
|
'components' => [ |
||||||
|
'db' => [ |
||||||
|
'dsn' => 'mysql:host=localhost;dbname=yii2basic_functional', |
||||||
|
], |
||||||
|
], |
||||||
|
]; |
@ -0,0 +1,15 @@ |
|||||||
|
<?php |
||||||
|
|
||||||
|
// configuration adjustments for codeception unit tests. Will be merged with web.php config. |
||||||
|
|
||||||
|
return [ |
||||||
|
'components' => [ |
||||||
|
'fixture' => [ |
||||||
|
'class' => 'yii\test\DbFixtureManager', |
||||||
|
'basePath' => '@tests/unit/fixtures', |
||||||
|
], |
||||||
|
'db' => [ |
||||||
|
'dsn' => 'mysql:host=localhost;dbname=yii2basic_unit', |
||||||
|
], |
||||||
|
], |
||||||
|
]; |
@ -1,26 +1,24 @@ |
|||||||
<?php |
<?php |
||||||
$params = require(__DIR__ . '/params.php'); |
$params = require(__DIR__ . '/params.php'); |
||||||
return array( |
return [ |
||||||
'id' => 'bootstrap-console', |
'id' => 'basic-console', |
||||||
'basePath' => dirname(__DIR__), |
'basePath' => dirname(__DIR__), |
||||||
'preload' => array('log'), |
'preload' => ['log'], |
||||||
'controllerPath' => dirname(__DIR__) . '/commands', |
'controllerPath' => dirname(__DIR__) . '/commands', |
||||||
'controllerNamespace' => 'app\commands', |
'controllerNamespace' => 'app\commands', |
||||||
'modules' => array( |
'extensions' => require(__DIR__ . '/../vendor/yiisoft/extensions.php'), |
||||||
), |
'components' => [ |
||||||
'components' => array( |
'cache' => [ |
||||||
'cache' => array( |
|
||||||
'class' => 'yii\caching\FileCache', |
'class' => 'yii\caching\FileCache', |
||||||
), |
], |
||||||
'log' => array( |
'log' => [ |
||||||
'class' => 'yii\logging\Router', |
'targets' => [ |
||||||
'targets' => array( |
[ |
||||||
array( |
'class' => 'yii\log\FileTarget', |
||||||
'class' => 'yii\logging\FileTarget', |
'levels' => ['error', 'warning'], |
||||||
'levels' => array('error', 'warning'), |
], |
||||||
), |
], |
||||||
), |
], |
||||||
), |
], |
||||||
), |
|
||||||
'params' => $params, |
'params' => $params, |
||||||
); |
]; |
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue