Skip to content

Commit

Permalink
'加个说明'
Browse files Browse the repository at this point in the history
  • Loading branch information
yidashi committed Feb 6, 2017
1 parent 16af344 commit b50b407
Show file tree
Hide file tree
Showing 7 changed files with 61 additions and 102 deletions.
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ BACKEND_PRETTY_URL = false
SITE_URL = http:https://localhost:8080
FRONTEND_URL = http:https://localhost:8080
BACKEND_URL = http:https://localhost:8080/admin
// 上传文件访问地址
// 文件访问地址
STORAGE_URL = http:https://localhost:8080/storage

# 搜索驱动(xunsearch需要安装xunsearch服务端)
Expand Down
4 changes: 4 additions & 0 deletions common/modules/user/models/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,10 @@ public function getAvatar($width = 96, $height = 0)
return $this->getDefaultAvatar($width, $height);
}

public function getSignature()
{
return $this->profile->signature;
}
public static function getDefaultAvatar($width, $height)
{
// list ($basePath, $baseUrl) = \Yii::$app->getAssetManager()->publish("@common/widgets/upload/assets/avatars");
Expand Down
4 changes: 2 additions & 2 deletions common/widgets/upload/MultipleWidget.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public function init()
$this->value = [];
if ($attachments) {
foreach ($attachments as $attachment) {
$value = $this->formartAttachment($attachment);
$value = $this->formatAttachment($attachment);
if ($value) {
$this->value[] = $value;
}
Expand All @@ -112,7 +112,7 @@ public function init()

}

protected function formartAttachment($attachment)
protected function formatAttachment($attachment)
{
if (is_string($attachment) && !empty($attachment)) {
return [
Expand Down
4 changes: 1 addition & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@
"bower-asset/blueimp-file-upload" : "*",
"bower-asset/font-awesome": "^4.0",
"bower-asset/editor.md": "*",
"creocoder/yii2-flysystem": "*",
"nikic/php-parser": "1.4.1",
"cebe/markdown-latex": "^1.1"
"creocoder/yii2-flysystem": "*"
},
"require-dev": {
"yiisoft/yii2-debug": "*",
Expand Down
Loading

0 comments on commit b50b407

Please sign in to comment.