mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-03-04 00:24:29 +08:00
完善访问链接;
This commit is contained in:
@@ -5,6 +5,7 @@ declare(strict_types=1);
|
|||||||
namespace app\model;
|
namespace app\model;
|
||||||
|
|
||||||
use think\facade\Cache;
|
use think\facade\Cache;
|
||||||
|
use think\facade\Request;
|
||||||
use think\Model;
|
use think\Model;
|
||||||
use think\model\concern\SoftDelete;
|
use think\model\concern\SoftDelete;
|
||||||
use think\Paginator;
|
use think\Paginator;
|
||||||
@@ -155,9 +156,8 @@ class Post extends Model
|
|||||||
|
|
||||||
public function getReadUrlAttr()
|
public function getReadUrlAttr()
|
||||||
{
|
{
|
||||||
$url_info = parse_url((string)url('index/Index/index')->domain('www'));
|
|
||||||
|
|
||||||
return $url_info['scheme'] . '://' . $url_info['host'] . '/index/a' . $this->getData('uid') . '.html';
|
return Request::domain() . '/index/a' . $this->getData('uid') . '.html';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getShareTextAttr()
|
public function getShareTextAttr()
|
||||||
|
|||||||
@@ -20,5 +20,4 @@ $http = (new App())->http;
|
|||||||
$response = $http->run();
|
$response = $http->run();
|
||||||
|
|
||||||
$response->send();
|
$response->send();
|
||||||
|
|
||||||
$http->end($response);
|
$http->end($response);
|
||||||
|
|||||||
Reference in New Issue
Block a user