add decimal support to ruby generators (#10484)

This commit is contained in:
William Cheng
2021-09-28 11:38:19 +08:00
committed by GitHub
parent d22e9fb1c1
commit 51d468e2f6
5 changed files with 5 additions and 4 deletions

View File

@@ -78,6 +78,7 @@ abstract public class AbstractRubyCodegen extends DefaultCodegen implements Code
typeMapping.put("float", "Float");
typeMapping.put("double", "Float");
typeMapping.put("number", "Float");
typeMapping.put("decimal", "Float");
typeMapping.put("date", "Date");
typeMapping.put("DateTime", "Time");
typeMapping.put("array", "Array");

View File

@@ -10,7 +10,7 @@
| **number** | **Float** | | |
| **float** | **Float** | | [optional] |
| **double** | **Float** | | [optional] |
| **decimal** | [**Decimal**](Decimal.md) | | [optional] |
| **decimal** | **Float** | | [optional] |
| **string** | **String** | | [optional] |
| **byte** | **String** | | |
| **binary** | **File** | | [optional] |

View File

@@ -85,7 +85,7 @@ module Petstore
:'number' => :'Float',
:'float' => :'Float',
:'double' => :'Float',
:'decimal' => :'Decimal',
:'decimal' => :'Float',
:'string' => :'String',
:'byte' => :'String',
:'binary' => :'File',

View File

@@ -10,7 +10,7 @@
| **number** | **Float** | | |
| **float** | **Float** | | [optional] |
| **double** | **Float** | | [optional] |
| **decimal** | [**Decimal**](Decimal.md) | | [optional] |
| **decimal** | **Float** | | [optional] |
| **string** | **String** | | [optional] |
| **byte** | **String** | | |
| **binary** | **File** | | [optional] |

View File

@@ -85,7 +85,7 @@ module Petstore
:'number' => :'Float',
:'float' => :'Float',
:'double' => :'Float',
:'decimal' => :'Decimal',
:'decimal' => :'Float',
:'string' => :'String',
:'byte' => :'String',
:'binary' => :'File',