创建科目表明细
接口描述
此接口用于创建科目表明细
接口权限
本接口需要集团权限
请求URI
/api/openapi/accountSet/detail
请求方式
POST
请求体示例
{
"accountSetCode": "accountSet001",
"accountCode": "account001",
"accountName": "科目表明细1",
"balanceDirection": "CR",
"accountType": "ASSET",
"reportType": "AR",
"isEnabled": true,
"sequence": 1
}
请求体字段
字段名 | 类型 | 必填 | 主键 | 约束 | 说明 |
---|---|---|---|---|---|
accountSetCode | String | ○ | ○ | 最大35文字 | 科目表编码 |
accountCode | String | ○ | ○ | 最大35文字 | 科目编码 |
accountName | String | ○ | 最大100文字 | 科目名称 | |
balanceDirection | String | ○ | 余额方向 貸方:CR 借方:DR | ||
accountType | String | ○ | 科目类型 資産:ASSET 負債:LIABILITY 資本:OWNERS_EQUITY 收益:PROFIT_AND_LOSS 費用:COST | ||
reportType | String | 报表类型 应收类:AR 应付类:AP | |||
isEnabled | Boolean | 状态 有效:true(默认) 无效:false | |||
sequence | int | 最大10文字 | 序号 |
接口返回示例
成功
{
"message": "success",
"key": "account001"
}
失败示例
{
"message": "缺少必填项:accountSetCode",
"errorCode": "120003"
}
字段说明
字段名称 | 类型 | 说明 |
---|---|---|
message | String | 返回信息说明 |
errorCode | String | 返回错误码 |
key | String | 科目编码 |
错误代码
errorCode | message | description |
---|---|---|
120001 | 当前操作需要租户权限 | |
120003 | 缺少必填项:{0} | |
0013 | 参数:{0},最大长度{1} | |
spd.18530.001 | 参数:{0},只能输入字母、数字、下划线、中划线 | |
spd.18530.002 | 余额方向编码:{0}不存在 | |
spd.18530.003 | 科目类型编码:{0}不存在 | |
spd.18530.004 | 报表类型编码:{0}不存在 | |
spd.18530.005 | 科目表编码:{0} 不存在或已失效 | |
spd.18530.006 | 科目编码:{0}已存在 | |
spd.18530.901 | 参数:{0},只能输入字符:字母,数字,_,- | |
spd.18530.008 | 科目明细序号只允许为正整数并且不能超过10位 |
更新科目表明细 →