Skip to content

Commit

Permalink
update to 2.0.8
Browse files Browse the repository at this point in the history
  • Loading branch information
yidashi committed Jun 16, 2016
1 parent 323a382 commit 3d971c9
Show file tree
Hide file tree
Showing 4,198 changed files with 161,320 additions and 121,825 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@
"yidashi/yii2-bootstrap-markdown": "^1.0",
"mihaildev/yii2-elfinder": "^1.0",
"trntv/yii2-datetime-widget": "^1.0.0",
"qiniu/php-sdk": "^7.0"
"qiniu/php-sdk": "^7.0",
"omnilight/yii2-scheduling": "*"
},
"require-dev": {
"yiisoft/yii2-codeception": "*",
Expand Down
713 changes: 427 additions & 286 deletions composer.lock

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions console/config/schedule.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php
/**
* Created by PhpStorm.
* User: yidashi
* Date: 16/6/16
* Time: 下午9:57
*/
2 changes: 1 addition & 1 deletion frontend/models/RewardForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public function attributeLabels()
public function attributeHints()
{
return [
'money' => '(帐号余额:' . \Yii::$app->user->identity->profile->money . ')'
'money' => '(帐号余额:' . \Yii::$app->user->isGuest ? 0 : \Yii::$app->user->identity->profile->money . ')'
];
}

Expand Down
4 changes: 2 additions & 2 deletions frontend/themes/basic/article/view.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
</div>
<ul class="tag-list list-inline">
<?php foreach($model->tags as $tag): ?>
<li><a class="label label-<?= $tag->level ?>" href="<?= Url::to(['article/tag', 'name' => $tag->name])?>"><?= $tag->name ?></a></li>
<li><a class="label label-<?= $tag->level ?>" href="<?= Url::to(['article/tag', 'name' => $tag->name])?>"><?= $tag->name ?></a></li>
<?php endforeach; ?>
</ul>
<!--内容-->
Expand All @@ -56,7 +56,7 @@
<div class="panel-body">
<ul class="post-list">
<?php foreach ($hots as $item):?>
<li><?=Html::a($item->title, ['/article/view', 'id' => $item->id])?></li>
<li><?=Html::a($item->title, ['/article/view', 'id' => $item->id])?></li>
<?php endforeach;?>
</ul>
</div>
Expand Down
1 change: 1 addition & 0 deletions frontend/themes/basic/layouts/main.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
<title><?= Html::encode($this->title) ?></title>
<?php $this->registerMetaTag(['name' => 'keywords', 'content' => Yii::$app->config->get('SEO_SITE_KEYWORDS')]);?>
<?php $this->registerMetaTag(['name' => 'description', 'content' => Yii::$app->config->get('SEO_SITE_DESCRIPTION')]);?>
<script>var SITE_URL = '<?= Yii::$app->request->hostInfo . Yii::$app->request->baseUrl ?>';</script>
<?php $this->head() ?>
</head>
<body>
Expand Down
12 changes: 4 additions & 8 deletions frontend/widgets/reward/RewardWidget.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,9 @@ class RewardWidget extends Widget

public function run()
{
if (Yii::$app->user->isGuest) {
Yii::$app->user->loginRequired();
} else {
$model = new RewardForm();
$model->money = Yii::$app->user->identity->profile->money;
$model->article_id = $this->articleId;
return $this->render('index', ['model' => $model]);
}
$model = new RewardForm();
$model->money = Yii::$app->user->isGuest ? 0 : Yii::$app->user->identity->profile->money;
$model->article_id = $this->articleId;
return $this->render('index', ['model' => $model]);
}
}
7 changes: 6 additions & 1 deletion frontend/widgets/reward/views/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,12 @@
<?= $form->field($model, 'comment')?>
<div class="clearfix">
<div class="pull-right">
<?= Html::button('取消打赏', ['class' => 'btn btn-default', 'data-dismiss' => 'modal']) . ' ' . Html::submitButton('确认打赏', ['class' => 'btn btn-primary'])?>
<?= Html::button('取消打赏', ['class' => 'btn btn-default', 'data-dismiss' => 'modal'])?>
<?php if(Yii::$app->user->isGuest) : ?>
<?= Html::a('登录', ['/site/login'], ['class' => 'btn btn-primary']) ?>
<?php else: ?>
<?= Html::submitButton('确认打赏', ['class' => 'btn btn-primary'])?>
<?php endif; ?>
</div>
</div>
<?php \yii\widgets\ActiveForm::end()?>
Expand Down
1 change: 1 addition & 0 deletions vendor/almasaeed2010/adminlte/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*.log
*.zip
.idea
.sass-cache/
/nbproject/
/nbproject/private/
/node_modules/
Expand Down
2 changes: 1 addition & 1 deletion vendor/almasaeed2010/adminlte/LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2014-2015 almasaeed2010
Copyright (c) 2014-2016 Abdullah Almsaeed

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
9 changes: 8 additions & 1 deletion vendor/almasaeed2010/adminlte/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
**I apologize to everyone for my slow rate of response and development recently.** This is my final semester and I am very busy. Although I usually work on AdminLTE a few hours a week, there are weeks full of exams and assignments. Thanks for your understanding.
Introduction
============

Expand Down Expand Up @@ -38,6 +39,12 @@ git clone https://github.com/YOUR_USERNAME/AdminLTE.git
bower install admin-lte
```

**npm**

```
npm install --save admin-lte
```

**Composer**

```
Expand Down Expand Up @@ -86,7 +93,7 @@ Todo List
- Right to left support
- ~~Custom pace style~~ (Done v2.3.1)

Legacy Realeases
Legacy Releases
----------------
AdminLTE 1.x can be easily upgraded to 2.x using [this guide](https://almsaeedstudio.com/themes/AdminLTE/documentation/index.html#upgrade), but if you intend to keep using AdminLTE 1.x, you can download the latest release from the [releases](https://github.com/almasaeed2010/AdminLTE/releases) section above.

Expand Down
Loading

0 comments on commit 3d971c9

Please sign in to comment.