Skip to content
Snippets Groups Projects
Commit 56a05f32 authored by godzie44's avatar godzie44 Committed by Derevtsov Konstantin
Browse files

feature(tarantool): add nullable fields in schema module

parent 78750d2c
No related branches found
No related tags found
1 merge request!113feature(tarantool): add nullable fields in schema module
......@@ -125,6 +125,7 @@ fn insert_new_space(
let mut field_format = Map::<String, Value>::new();
field_format.insert("name".to_string(), Value::String(ft.name.clone()));
field_format.insert("type".to_string(), Value::String(ft.field_type.to_string()));
field_format.insert("is_nullable".to_string(), Value::Bool(ft.is_nullable));
space_format.push(Value::Object(field_format));
}
}
......
......@@ -149,6 +149,7 @@ pub struct SpaceFieldFormat {
pub name: String,
#[serde(alias = "type")]
pub field_type: SpaceFieldType,
pub is_nullable: bool,
}
impl SpaceFieldFormat {
......@@ -156,6 +157,7 @@ impl SpaceFieldFormat {
SpaceFieldFormat {
name: name.to_string(),
field_type: ft,
is_nullable: false,
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment