|
|
@ -4869,7 +4869,9 @@ class BaseModelSqlv2 { |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
NcError.unprocessableEntity( |
|
|
|
NcError.unprocessableEntity( |
|
|
|
`Child record with id [${missingIds.join(', ')}] not found`, |
|
|
|
`Child record with id [${extractIdsString( |
|
|
|
|
|
|
|
missingIds, |
|
|
|
|
|
|
|
)}] not found`,
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -4933,7 +4935,9 @@ class BaseModelSqlv2 { |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
NcError.unprocessableEntity( |
|
|
|
NcError.unprocessableEntity( |
|
|
|
`Child record with id [${missingIds.join(', ')}] not found`, |
|
|
|
`Child record with id [${extractIdsString( |
|
|
|
|
|
|
|
missingIds, |
|
|
|
|
|
|
|
)}] not found`,
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -4983,7 +4987,9 @@ class BaseModelSqlv2 { |
|
|
|
|
|
|
|
|
|
|
|
if (!childRow) { |
|
|
|
if (!childRow) { |
|
|
|
NcError.unprocessableEntity( |
|
|
|
NcError.unprocessableEntity( |
|
|
|
`Child record with id [${childIds[0]}] not found`, |
|
|
|
`Child record with id [${extractIdsString( |
|
|
|
|
|
|
|
childIds, |
|
|
|
|
|
|
|
)}] not found`,
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -5109,7 +5115,9 @@ class BaseModelSqlv2 { |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
NcError.unprocessableEntity( |
|
|
|
NcError.unprocessableEntity( |
|
|
|
`Child record with id [${missingIds.join(', ')}] not found`, |
|
|
|
`Child record with id [${extractIdsString( |
|
|
|
|
|
|
|
missingIds, |
|
|
|
|
|
|
|
)}] not found`,
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -5157,7 +5165,9 @@ class BaseModelSqlv2 { |
|
|
|
); |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
NcError.unprocessableEntity( |
|
|
|
NcError.unprocessableEntity( |
|
|
|
`Child record with id [${missingIds.join(', ')}] not found`, |
|
|
|
`Child record with id [${extractIdsString( |
|
|
|
|
|
|
|
missingIds, |
|
|
|
|
|
|
|
)}] not found`,
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -5211,7 +5221,9 @@ class BaseModelSqlv2 { |
|
|
|
|
|
|
|
|
|
|
|
if (!childRow) { |
|
|
|
if (!childRow) { |
|
|
|
NcError.unprocessableEntity( |
|
|
|
NcError.unprocessableEntity( |
|
|
|
`Child record with id [${childIds[0]}] not found`, |
|
|
|
`Child record with id [${extractIdsString( |
|
|
|
|
|
|
|
childIds, |
|
|
|
|
|
|
|
)}] not found`,
|
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -5677,4 +5689,10 @@ export function getListArgs( |
|
|
|
return obj; |
|
|
|
return obj; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function extractIdsString(childIds: (string | number | Record<string, any>)[]) { |
|
|
|
|
|
|
|
return childIds |
|
|
|
|
|
|
|
.map((r) => (typeof r === 'object' ? JSON.stringify(r) : r)) |
|
|
|
|
|
|
|
.join(', '); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
export { BaseModelSqlv2 }; |
|
|
|
export { BaseModelSqlv2 }; |
|
|
|