dingtalk.oapi.rhino.mos.exec.perform.query (条件查询执行记录详情)

条件查询执行记录详情

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
tenant_id String 必须 1 租户ID
active_condition String 可选 ACTIVE 生效条件
entity_type String 必须 CLOTHES 实体类型
perform_status_list String [] 可选 INIT,CANCEL
  • 最大列表长度:20
  • 执行状态
    workstation_codes String [] 可选 'line1-01'
  • 最大列表长度:20
  • 执行工位列表
    entity_ids Number [] 可选 1,2
  • 最大列表长度:500
  • 实体ID列表
    operation_uids Number [] 可选 1,2
  • 最大列表长度:500
  • 工序列表
    userid String 可选 1 业务参数[这里先预留],这里是用户ID,比如钉钉用户ID
    order_id Number 可选 1 订单ID

    响应参数

    名称 类型 示例值 描述
    errmsg String 工号无效 错误信息
    model OperationPerformDto [] 创建后的工段执行记录
    • └ active
    • String
    • true
    • 是否有效
    • └ batch_id
    • Number
    • 1
    • 分批ID
    • └ context
    • Json
    • {"carrierId":"1"}
    • 上下文
    • └ create_type
    • String
    • NEW
    • 创建类型,是新建的还是已存在的
    • └ device_ids
    • Number []
    • [1,2]
    • 设备ID列表
    • └ entity_id
    • Number
    • 1
    • 实例ID
    • └ entity_type
    • String
    • CLOTHES
    • 实体类型
    • └ flow_version
    • Number
    • 1
    • 排位布局版本
    • └ id
    • Number
    • 1
    • 工序执行ID
    • └ operation_type
    • String
    • TECHNOLOGY
    • 工序类型
    • └ operation_uid
    • Number
    • 1
    • 工序ID
    • └ order_id
    • Number
    • 1
    • 订单ID
    • └ perform_status
    • String
    • INIT
    • 执行状态
    • └ perform_type
    • String
    • NORMAL
    • 执行类型
    • └ priority
    • Number
    • 100
    • 优先级
    • └ process_type_code
    • String
    • SJ
    • 工序能力类型
    • └ processing_end_time
    • Date
    • 2020-02-12 10:00:00
    • 工序执行结束时间
    • └ processing_start_time
    • Date
    • 2020-02-12 10:00:00
    • 工序执行开始时间
    • └ section_code
    • String
    • F-ZZ
    • 工段
    • └ source_id
    • String
    • 1
    • 来源ID
    • └ source_type
    • String
    • MOS_SCHEDULE
    • 来源类型
    • └ tenant_id
    • String
    • 1
    • 租户ID
    • └ work_nos
    • String []
    • ["WB01","WB02"]
    • 执行人工号
    • └ workstation_code
    • String
    • line1-01
    • 执行工位
    • └ process_cost_time
    • String
    • 10.2
    • 工序执行耗时
    success Boolean true 是否成功
    errcode Number 0 错误码

    请求示例

    • JAVA
    • .NET
    • PHP
    • CURL
    • Python
    • C/C++
    • NodeJS
    DingTalkClient client = new DefaultDingTalkClient("https://oapi.dingtalk.com/topapi/rhino/mos/exec/perform/query");
    OapiRhinoMosExecPerformQueryRequest req = new OapiRhinoMosExecPerformQueryRequest();
    req.setTenantId("1");
    req.setActiveCondition("ACTIVE");
    req.setEntityType("CLOTHES");
    req.setPerformStatusList("INIT,CANCEL");
    req.setWorkstationCodes("'line1-01'");
    req.setEntityIds("1,2");
    req.setOperationUids("1,2");
    req.setUserid("1");
    req.setOrderId(1L);
    OapiRhinoMosExecPerformQueryResponse rsp = client.execute(req, access_token);
    System.out.println(rsp.getBody());

    响应示例

    • JSON示例
    {
        "errmsg":"工号无效",
        "model":[
            {
                    "active":"true",
                    "batch_id":1,
                    "context":"{\"carrierId\":\"1\"}",
                    "create_type":"NEW",
                    "device_ids":{
                        "number":[
                            [1,
                            2]
                        ]
                    },
                    "entity_id":1,
                    "entity_type":"CLOTHES",
                    "flow_version":1,
                    "id":1,
                    "operation_type":"TECHNOLOGY",
                    "operation_uid":1,
                    "order_id":1,
                    "perform_status":"INIT",
                    "perform_type":"NORMAL",
                    "priority":100,
                    "process_type_code":"SJ",
                    "processing_end_time":"2020-02-12 10:00:00",
                    "processing_start_time":"2020-02-12 10:00:00",
                    "section_code":"F-ZZ",
                    "source_id":"1",
                    "source_type":"MOS_SCHEDULE",
                    "tenant_id":"1",
                    "work_nos":{
                        "string":[
                            "[\"WB01\"",
                            "\"WB02\"]"
                        ]
                    },
                    "workstation_code":"line1-01",
                    "process_cost_time":"10.2"
            }
        ],
        "success":true,
        "errcode":0
    }

    异常示例

    • JSON示例
    {
    	"errcode":88,
    	"errmsg":"ding talk error"
    }

    错误码解释

    错误码 错误描述 解决方案

    API工具

    如何获得此API

    FAQ

    返回
    顶部