mirror of
https://github.com/strapi/strapi.git
synced 2026-01-06 12:13:52 +00:00
Fix PR feedback - handle type float
This commit is contained in:
parent
611dfb32eb
commit
1ee8d9b30a
@ -322,7 +322,7 @@ module.exports = function(strapi) {
|
||||
let type;
|
||||
|
||||
if (!attribute.type) {
|
||||
// Add interger value is if relation
|
||||
// Add integer value if there is a relation
|
||||
const relation = definition.associations.find((association) => {
|
||||
return association.alias === attr;
|
||||
});
|
||||
@ -346,9 +346,11 @@ module.exports = function(strapi) {
|
||||
break;
|
||||
case 'integer':
|
||||
case 'biginteger':
|
||||
type = definition.client === 'pg' ? 'integer' : 'int';
|
||||
break;
|
||||
case 'float':
|
||||
case 'decimal':
|
||||
type = definition.client === 'pg' ? 'integer' : 'int';
|
||||
type = attribute.type;
|
||||
break;
|
||||
case 'date':
|
||||
case 'time':
|
||||
|
||||
@ -1,19 +1 @@
|
||||
{
|
||||
"article": {
|
||||
"attributes": {
|
||||
"title": {
|
||||
"appearance": ""
|
||||
},
|
||||
"content": {
|
||||
"appearance": ""
|
||||
}
|
||||
}
|
||||
},
|
||||
"account": {
|
||||
"attributes": {
|
||||
"name": {
|
||||
"appearance": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
{}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user