@@ -135,140 +135,3 @@ GET /server/analysis/api/orgs/<org_sid>/teams/<team_name>/repos/<repo_id>/projec
135135 "status_code" : 200
136136}
137137```
138-
139- ## 查看每次扫描的问题列表
140- ```
141- GET /server/analysis/api/orgs/<org_sid>/teams/<team_name>/repos/<repo_id>/projects/<project_id>/codelint/scans/<scan_id>/issues/
142- ```
143- #### 参数
144- | 参数 | 类型 | 描述 |
145- | --- | --- | --- |
146- | state | str | 问题状态, 1为未处理,2为已处理,3为关闭,可多选,格式为1,2,3 |
147- | severity | str | 严重程度, 1为致命,2为错误,3为警告,4为提示,可多选,格式为1,2,3,4 |
148- | resolution | str | 解决方式, 0为无,1为修复,2为无需修复,3为误报,4为重复单过滤,5为路径过滤,6为规则移除 |
149- | author | str | 问题责任人 |
150- | scan_open_id | int | 发现问题的扫描编号 |
151- | scan_fix_id | int | 修复问题的扫描编号 |
152- | ci_time_gte | str | 修复问题的起始时间 |
153- | ci_time_lte | str | 修复问题的结束时间 |
154- | file_path | str | 文件路径 |
155- | checkrule_display_name | str | 检查规则名 |
156- | checkpackage | int | 问题所属的规则包 |
157-
158- #### 返回结果
159- ``` JSON
160- {
161- "data" : {
162- "count" : 1 ,
163- "next" : null ,
164- "previous" : null ,
165- "results" : [
166- {
167- "id" : 1 ,
168- "repo_id" : 1 ,
169- "project_id" : 1 ,
170- "scan_time" : " 2021-03-11T20:46:44.171607+08:00" ,
171- "file_path" : " test/demo.py" ,
172- "scm_url" : " " ,
173- "real_file_path" : " " ,
174- "line" : 21 ,
175- "column" : 68 ,
176- "checkrule_gid" : 1 ,
177- "checkrule_real_name" : " xxx" ,
178- "checkrule_display_name" : " xxx" ,
179- "checkrule_rule_title" : " xxx" ,
180- "checktool_name" : " xxx" ,
181- "category" : 7 ,
182- "msg" : " xxx" ,
183- "state" : 1 ,
184- "resolution" : null ,
185- "author" : " author" ,
186- "scan_open_id" : 1 ,
187- "scan_fix_id" : null ,
188- "issuedetail_uuid" : " 26d7ba88-8268-11eb-a304-5254005e71ca" ,
189- "scan_revision" : " scan_revision" ,
190- "real_revision" : " " ,
191- "severity" : 2 ,
192- "language" : " python" ,
193- "revision" : " revision" ,
194- "ci_time" : " 2019-07-01T10:28:19+08:00" ,
195- "file_owners" : null ,
196- "created_time" : " 2021-03-11T20:49:00.539537+08:00" ,
197- "fixed_time" : null
198- }
199- ]
200- },
201- "code" : 0 ,
202- "msg" : " xxx" ,
203- "status_code" : 200
204- }
205- ```
206-
207-
208- ## 查看指定CR扫描的问题列表
209- ```
210- GET /server/analysis/api/orgs/<org_sid>/teams/<team_name>/repos/<repo_id>/projects/<project_id>/codelint/crscans/<scan_id>/issues/
211- ```
212- #### 参数
213- | 参数 | 类型 | 描述 |
214- | --- | --- | --- |
215- | state | str | 问题状态, 1为未处理,2为已处理,3为关闭,可多选,格式为1,2,3 |
216- | severity | str | 严重程度, 1为致命,2为错误,3为警告,4为提示,可多选,格式为1,2,3,4 |
217- | resolution | str | 解决方式, 0为无,1为修复,2为无需修复,3为误报,4为重复单过滤,5为路径过滤,6为规则移除 |
218- | author | str | 问题责任人 |
219- | scan_open_id | int | 发现问题的扫描编号 |
220- | scan_fix_id | int | 修复问题的扫描编号 |
221- | ci_time_gte | str | 修复问题的起始时间 |
222- | ci_time_lte | str | 修复问题的结束时间 |
223- | file_path | str | 文件路径 |
224- | checkrule_display_name | str | 检查规则名 |
225- | checkpackage | int | 问题所属的规则包 |
226-
227- #### 返回结果
228- ``` JSON
229- {
230- "data" : {
231- "count" : 1 ,
232- "next" : null ,
233- "previous" : null ,
234- "results" : [
235- {
236- "id" : 1 ,
237- "repo_id" : 1 ,
238- "project_id" : 1 ,
239- "scan_time" : " 2021-03-11T20:46:44.171607+08:00" ,
240- "file_path" : " test/demo.py" ,
241- "scm_url" : " " ,
242- "real_file_path" : " " ,
243- "line" : 21 ,
244- "column" : 68 ,
245- "checkrule_gid" : 1 ,
246- "checkrule_real_name" : " xxx" ,
247- "checkrule_display_name" : " xxx" ,
248- "checkrule_rule_title" : " xxx" ,
249- "checktool_name" : " xxx" ,
250- "category" : 7 ,
251- "msg" : " xxx" ,
252- "state" : 1 ,
253- "resolution" : null ,
254- "author" : " author" ,
255- "scan_open_id" : 1 ,
256- "scan_fix_id" : null ,
257- "issuedetail_uuid" : " 26d7ba88-8268-11eb-a304-5254005e71ca" ,
258- "scan_revision" : " scan_revision" ,
259- "real_revision" : " " ,
260- "severity" : 2 ,
261- "language" : " python" ,
262- "revision" : " revision" ,
263- "ci_time" : " 2019-07-01T10:28:19+08:00" ,
264- "file_owners" : null ,
265- "created_time" : " 2021-03-11T20:49:00.539537+08:00" ,
266- "fixed_time" : null
267- }
268- ]
269- },
270- "code" : 0 ,
271- "msg" : " xxx" ,
272- "status_code" : 200
273- }
274- ```
0 commit comments