* add project api test.

This commit is contained in:
王怡栋
2021-10-19 15:09:10 +08:00
parent 7dae5e88f5
commit 82fbee89e3
4 changed files with 104 additions and 1 deletions
+18
View File
@@ -0,0 +1,18 @@
#!/usr/bin/env php
<?php
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
/**
title=获取项目列表;
cid=1
pid=1
获取条目的project和type字段 >> 0,project
*/
global $token;
$projects = $rest->get('/projects', array("Token" => $token));
$project = array(reset($projects->body->projects));
r($project) && p('project,type', ',') && e('0,project'); // 获取条目的project和type字段