跟进时间

This commit is contained in:
2025-03-20 10:01:21 +08:00
parent 7fb921dc9f
commit cd580fea23
3 changed files with 11 additions and 6 deletions
+8 -4
View File
@@ -37,16 +37,20 @@ class Follow extends Model
*/
public $timestamps = true;
protected $dates = ['created_at', 'updated_at', 'follow_time'];
protected $casts = [
// 'updated_at' => 'datetime:Y-m-d H:i:s', // 指定序列化格式
// 'created_at' => 'datetime:Y-m-d H:i:s', // 指定序列化格式
'updated_at' => 'timestamp', // 指定序列化格式
'created_at' => 'timestamp', // 指定序列化格式
'updated_at' => 'datetime:Y-m-d H:i:s', // 指定序列化格式
'created_at' => 'datetime:Y-m-d H:i:s', // 指定序列化格式
'follow_time' => 'datetime:Y-m-d H:i:s', // 指定序列化格式
// 'updated_at' => 'timestamp', // 指定序列化格式
// 'created_at' => 'timestamp', // 指定序列化格式
];
public static function getFollow($follow,$domain = 'https://vehicle-album.oss-cn-beijing.aliyuncs.com')
{
$follow['type_txt'] = Constants::FOLLOW[$follow['type']];
$follow['firstFollowtime'] = $follow['follow_time'];
$follow['oss_picture'] = $domain.'/'.$follow['picture'];
$follow = Util::formatDate($follow);
return $follow;