修改单据自定义字段
说明
当审批流程处于webHook且是循环等待节点类型时支持更新单据级的C级字段,目前为覆盖操作。
接口限制
10次/秒
接口地址
修改单据C级字段
/api/openapi/form/customFields/update
请求类型
PUT
请求参数
参数说明
参数名称 |
类型 |
是否必填 |
参数说明 |
formCode |
String(50) |
是 |
单据外码 |
formType |
String(20) |
是 |
单据类型 |
customObject |
customObject |
是 |
字段内容 |
值 |
名称 |
REIMBURSE |
报销单 |
PRECONSUME |
申请单 |
LOAN |
借款单 |
CONTRACT |
合同 |
customObject 说明
customObject为json字符串,每个单元又是json字符串,结构如下
参数名称 |
类型 |
是否必填 |
参数说明 |
fieldType |
String(50) |
是 |
字段类型 |
value |
Object |
是 |
字段值 |
fieldType 说明(仅限以下几种)
值 |
名称 |
SingleTextInput |
单行文本 |
MultiTextInput |
多行文本 |
NumberInput |
数字 |
AmountInput |
金额 |
DateTimeInput |
日期时间 |
CityInput |
城市 |
OptionInput |
内部选项 |
StaffInput |
员工 |
OptionMultiInput |
选项(多选) |
Hyperlink |
超链接 |
TableInput |
明细表 |
参数样例
{
"formCode": "MK23040012",
"formType":"PRECONSUME",
"customObject": {
"CF1": {
"fieldType":"SingleTextInput",
"value":"sign"
},
"singaltext_bizcode": {
"fieldType":"SingleTextInput",
"value":"SingleTextInput-bizcode"
},
"CF3": {
"fieldType":"AmountInput",
"value":{"amount": 100}
},
"amount_bizcode": {
"fieldType":"AmountInput",
"value":{"amount": 200}
},
"CF5": {
"fieldType":"DateTimeInput",
"value":{"currentTime": 1681341676486}
},
"date_bizcode": {
"fieldType":"DateTimeInput",
"value":{"currentTime": 1682091576488}
},
"CF7": {
"fieldType":"CityInput",
"value":{"location": "domestic-ZH3-ZH3_3-ZH3_3_23"}
},
"city_bizcode": {
"fieldType":"CityInput",
"value":{"location": "domestic-ZH5"}
},
"CF9": {
"fieldType":"StaffInput",
"value":["210433"]
},
"staff_bizcode": {
"fieldType":"StaffInput",
"value":["2001291"]
},
"CF11": {
"fieldType":"OptionMultiInput",
"value":[{"code":"选项4", "name":"选项4"}, {"code":"选项5", "name":"选项5"}]
},
"multi_option_bizcode": {
"fieldType":"OptionMultiInput",
"value":[{"code":"选项1", "name":"选项1"}, {"code":"选项2", "name":"选项2"}]
},
"CF13": {
"fieldType":"Hyperlink",
"value":{
"hyperlinkAddress":"https://www.maycur.com",
"hyperlinkName": "MY LINK"
}
},
"hyperlink_bizcode": {
"fieldType":"Hyperlink",
"value":{
"hyperlinkAddress":"https://www.maycur.com",
"hyperlinkName": "maycur"
}
},
"CF15": {
"fieldType":"MultiTextInput",
"value":"mutli-line1"
},
"multitext_bizcode": {
"fieldType":"MultiTextInput",
"value":"mutli-line2 \n wew"
},
"num_bizcode": {
"fieldType":"NumberInput",
"value":454
},
"CF20": {
"fieldType":"OptionInput",
"value":{
"bizCode":"RDD230419ZFTFMGW"
}
},
"option_bizcode": {
"fieldType":"OptionInput",
"value":{
"bizCode":"RDD230419Z1G79J4"
}
},
"table_bizcode": {
"fieldType": "TableInput",
"value": [
{
"singaltext_bizcode": "singaltext_value",
"multitext_bizcode": "multitext_value",
"amount_bizcode": {
"amount": 104,
"currency": "CNY"
}
}
]
}
}
}
响应参数
响应参数说明
参数名称 |
类型 |
是否必填 |
参数说明 |
code |
String |
是 |
响应码 |
message |
String |
否 |
错误信息 |
data |
String |
否 |
响应体 |
参数样例
正常响应参数示例
{
"code": "ACK",
"message": "",
"data": "",
"success":"true"
}
异常响应参数示例
{
"code": "NACK",
"message": "不在外部系统节点",
"data": "",
"success":"false"
}
修改记录
2023-04-11 新增
2023-04-19 更新支持字段类型