文档首页/ ISDP/ API参考/ API接口/ 问题管理/ 新增问题(API名称:createIssue)
更新时间:2024-04-26 GMT+08:00
分享

新增问题(API名称:createIssue)

功能介绍

该接口用于创建问题单。问题创建,按业务类型分类,在普通任务、质检任务、巡检任务、安检任务、智能安监、视频通话均可创建问题,创建的问题单可用于现场作业的管理。

相关API

接口名称

调用说明

获取Token

调用该接口获取到Token,再调用其他接口时,需要在请求消息头中添加“Authorization”,其值即为Token。

查询(上/下级)组织信息(API名称:findPagedOrgListWithDirection)

分页查询组织信息内容,含上/下级组织单元

查询条目问题单

创建问题单后,如果创建的为条目问题单,可以调用该接口查询创建的条目问题单。(条目问题单:质量检查任务在执行过程中,或者质量审核过程中创建的“问题”)

新增问题类型

新建问题时需要先选择问题类型,通过此接口创建

明文查询作业对象(API名称:plaintextQuerySignSite)

对作业对象进行查询时使用

调用流程

图1 创建问题单流程

URL

请求方式

HTTPS地址

服务架构

消息体类型

POST

https://isdp+域名/openapi/v1/openIssue/createIssue

OpenAPI

application/json

请求头

KEY

VALUE

是否必填

描述

Content-Type

application/json

Authorization

bearer ${access_token}

bearer +“ ”+5.2.1中获取的access_token的值

请求参数

参数

类型

是否必填

描述

issueInstance

String

问题实例,1 隐患,0 问题

code

String

问题编码,可以传值,如果不传值则创建后,根据后台默认规则生成

riskList

List

问题风险

issueTypeFather

String

问题大类

issueType

String

问题小类

说明:

问题大类和小类同时入参时,小类入参的形式是:大类#小类

issueLevel

String

问题级别,传枚举代码:0,1,2

issueSource

String

问题来源

issueRemark

String

问题备注

issueAttachmentList

List

附件

action

Integer

0:保存草稿

1:提交

creatorDescribe

String

问题描述

adminOrganization

String

创建人对应组织ID(由创建人关联带入,可不传)

adminOrganizationName

String

创建人对应组织名称(由创建人关联带入,可不传)

signSiteId

Long

作业对象ID

signSitecode

String

作业对象编码

signSiteName

String

作业对象名称

issueHandlerId

String

执行人

issueHandlerName

String

执行人名称

department

String

责任部门编码/ID

departmentName

String

责任部门名称

checkUserList

List

检查人清单,多个人用逗号隔开

acceptanceUserList

List

验收人,多个人用逗号隔开

supervisedUserList

List

监督人,多个人用逗号隔开

url

String

待办跳转的第三方web地址

thirdUrl

String

待办跳转的第三方app端页面地址

dueTimestamp

Long

计划完成时间戳

dealDate

Long

自动上传的处理时间

submitterAccount

String

提交人账号

isFilterReceiveStatus

Integer

1是代表问题提交执行中,0是代表问题提交到待执行,处理人需要接受。

issueHandlerAccount

String

问题处理人账号

udf1—udf20

-

-

问题扩展属性

响应参数

参数

类型

描述

stateCode

String

响应状态码:0-成功;其他-失败

errorMessage

String

响应描述

result

Object

响应结果内容

result参数:

参数

类型

描述

slaStatus

Integer

SLA状态,1:正常,2:临期,3:逾期,0--

submitPending

String

提交待处理的时间

status

Integer

问题状态(1-草稿,2-处理中 ,3-已处理待关闭,4-已关闭,5-待处理)

udf1-udf20

String

扩展属性

signSiteId

String

作业对象id

signSiteName

String

作业对象名称

signSiteCode

String

作业对象编码

issueTypeCode

String

kindScene问题类别适用的场景 UDF8-默认 UDF1-安全视频;UDF4-巡检;UDF5-质检;UDF6-视频通话;UDF7-智能安监;UDF9-任务相关

issueLevel

Integer

问题严重级别(0-一般,1-重要,2-严重)

issueSource

String

问题来源("0"-"审核问题"; "1"-"执行问题")

issueHandlerId

String

处理人id

issueHandlerName

String

处理人名称

createSupplierName

String

供应商名称

adminOrganization

String

组织单元ID

adminOrganizationName

String

组织单元名称

issueHandlerSupplierName

String

问题处理提供者名称

issueInstance

String

问题实例标识

code

String

问题编码

tenantId

Long

租户ID

createName

String

创建人名称

creationTimestamp

Long

创建时间戳

createdBy

Long

创建人ID

creationDate

Date

创建时间

lastUpdateName

String

最后更新人名称

lastUpdateBy

Long

最后更新人ID

lastUpdateDate

Date

最后更新时间

deleteFlag

Integer

删除标识0,正常,1删除

dueTimestamp

Long

要求完成时间戳

issueType

String

问题小类

issueTypeFather

String

问题大类

issueCarbonCopyList

List

问题抄送人集合

action

Integer

0:保存草稿

1:提交

issueAttachmentList

List

附件集合

riskList

List

问题风险

checkUserList

List

检查人清单,多个人用逗号隔开

acceptanceUserList

List

验收人,多个人用逗号隔开

supervisedUserList

List

监督人,多个人用逗号隔开

issueRemark

String

问题备注

creatorDescribe

String

创建人描述

department

String

责任部门ID

departmentName

String

责任部门名称

departmentPath

String

责任部门路径

orgPath

String

组织单元节点ID

region

String

行政区域

regionId

Long

行政区域ID

regionName

String

行政区域名称

regionPath

String

行政区域路径

issueAttributeModel

List

问题扩展属性

entityName

String

实体名称

issueId

Long

问题ID

lastUpdatedBy

Long

最后更新人Id

appName

String

服务名称

请求示例

{
"issueInstance":"1",
"isFilterReceiveStatus":1,
"code":"11111",
"riskList":[{"riskId":11111,"issueItemId":"11144444","issueRiskMeasuresId":12121,"issueRiskMeasures":"dfdfdfdd"}],
"issueTypeFather":"dfdfdfd",
"issueType":"dfdfdfdererere",
"signSiteId":"98908817",
"issueHandlerId":"467848",
"issueHandlerName":"呵呵",
"department":"833",
"issueLevel": 0,
"issueAttachmentList":
[
  {
    "fileId": 6525907,
    "fileName": "变更日志.xlsx",
    "fileType": "xlsx"
  }
],
"udf17":
"",
  "udf14": "",
  "udf13":
"12345689012345678901234567890123456789012345617890",
  "udf5": "",
  "udf6": "1650816000000",
  "udf10": "测试",
  "udf3":
"12345678011234567890123456789012345678901234567123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890890",
  "udf20": "",
  "udf4": "1650852785000",
  "udf1": "",
  "udf2": "",
"checkUserList":[{"userId":467848,"userName":"呵呵","userType":"1","orgId":833,"orgName":"23232","orgPath":"中国区11112223333"}],
"acceptanceUserList":[{"userId":467848,"userName":"呵呵","userType":"1","orgId":833,"orgName":"23232","orgPath":"中国区11112223333"}],
"supervisedUserList":[{"userId":467848,"userName":"呵呵","userType":"1","orgId":833,"orgName":"23232","orgPath":"中国区11112223333"}],
"creatorDescribe":
"嘿嘿dddd${number}",
"dueTimestamp":
"",
"issueRemark":
"ddddddddd",
"action": 1,
"issueSource": 5,
"submitterAccount":"18829266100",
"issueHandlerAccount":"1512948340911"
}

响应示例

{
"stateCode": "0",
    "errorMessage": null,
    "result": {
        "slaStatus": 1,
        "submitPending": 0,
        "status": 2,
        "udf1": "",
        "udf2": "",
        "udf3": "12345678011234567890123456789012345678901234567123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890890",
        "udf4": "1650852785000",
        "udf6": "1650816000000",
        "udf5": "",
        "udf7": null,
        "udf8": null,
        "udf9": null,
        "udf10": "测试",
        "udf12": null,
        "udf11": null,
        "udf13": "12345689012345678901234567890123456789012345617890",
        "udf14": "",
        "udf15": null,
        "udf16": null,
        "udf18": null,
        "udf17": "",
        "udf19": null,
        "udf20": "",
        "signSiteId": 98908817,
        "signSiteName": "jmeter440225166+1",
        "signSiteCode": "jmeter440225166+1",
        "issueTypeCode": "UDF8",
        "issueLevel": 0,
        "issueSource": "5",
        "issueHandlerId": "467848;",
        "issueHandlerName": "呵呵;",
        "createSupplierName": "XX供应商",
        "adminOrganization": "830",
        "adminOrganizationName": "XX作业系统测试❤",
        "issueHandlerSupplierName": "--",
        "issueInstance": "1",
        "code": "Issue20220616146917",
        "tenantId": 886,
        "createName": "霍XX原lichao",
        "creationTimestamp": 1655361285462,
        "createdBy": 25773,
        "creationDate": "2022-06-16 14:34:45",
        "lastUpdateName": "霍XX原lichao",
        "lastUpdateBy": 25773,
        "lastUpdateDate": "2022-06-16 14:34:45",
        "deleteFlag": 0,
        "dueTimestamp": null,
        "issueType": "dfdfdfdererere",
        "issueTypeFather": "dfdfdfd",
        "issueCarbonCopyList": [],
        "action": 1,
        "issueAttachmentList": [
            {
                "fileId": 6525907,
                "fileName": "变更日志.xlsx",
                "fileType": "xlsx"
            }
        ],
        "riskList": [
            {
                "riskId": "11111",
                "issueItemId": "11144444",
                "issueRiskMeasuresId": "12121",
                "issueRiskMeasures": "dfdfdfdd"
            }
        ],
        "checkUserList": [
            {
                "userId": 467848,
                "userName": "呵呵",
                "userType": 1,
                "orgId": 833,
                "orgName": "23232",
                "orgPath": "中国区11112223333"
            }
        ],
        "acceptanceUserList": [
            {
                "userId": 467848,
                "userName": "呵呵",
                "userType": 1,
                "orgId": 833,
                "orgName": "23232",
                "orgPath": "中国区11112223333"
            }
        ],
        "supervisedUserList": [
            {
                "userId": 467848,
                "userName": "呵呵",
                "userType": 1,
                "orgId": 833,
                "orgName": "23232",
                "orgPath": "中国区11112223333"
            }
        ],
        "issueRemark": "ddddddddd",
        "creatorDescribe": "嘿嘿dddd${number}",
        "department": "833",
        "departmentName": null,
        "departmentPath": "",
        "orgPath": "-1.830",
        "region": "中国->XX省->XX市",
        "regionId": 151881,
        "regionName": "XX市",
        "regionPath": "58982,126553,151881",
        "issueAttributeModel": {
            "udf17": "",
            "udf14": "",
            "udf13": "12345689012345678901234567890123456789012345617890",
            "udf5": "",
            "udf6": "1650816000000",
            "udf10": "测试",
            "udf3": "12345678011234567890123456789012345678901234567123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890890",
            "udf20": "",
            "udf4": "1650852785000",
            "udf1": "",
            "udf2": ""
        },
        "entityName": "taskIssue",
        "issueId": 306290,
        "lastUpdatedBy": 25773,
        "appName": "isdp-qc-server",
        "affectedRows": 1
    }
}

状态码

状态码请参见状态码

错误码

错误码请参见错误码

相关文档