新增辅助函数
This commit is contained in:
12
helpers/helpers.php
Normal file
12
helpers/helpers.php
Normal file
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
if (!function_exists('ds')) {
|
||||
function ds($data, $exit = false)
|
||||
{
|
||||
exit(json_encode([
|
||||
'code' => 19980617,
|
||||
'msg' => '测试返回',
|
||||
'data' => $data
|
||||
], JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT
|
||||
));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user