Files
kiri-core/System/Core/Number.php
T

23 lines
355 B
PHP
Raw Normal View History

2021-03-24 01:24:02 +08:00
<?php
namespace Snowflake\Core;
2021-03-24 01:25:38 +08:00
class Number
2021-03-24 01:24:02 +08:00
{
/**
* @param int $userId
* @return string
*/
public static function order(int $userId): string
{
$explode = current(explode(' ', str_replace('0.', '', microtime())));
return 'No.' . sprintf('%09d', $userId) . '.' . date('Ymd.His') . '.' . $explode;
}
}