1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- syntax = "proto3";
- message Field {
- string id = 1;
- string name = 2;
- string desc = 3;
- FieldType field_type = 4;
- bool frozen = 5;
- bool visibility = 6;
- int32 width = 7;
- bool is_primary = 8;
- }
- message FieldOrder {
- string field_id = 1;
- }
- message GridFieldChangeset {
- string grid_id = 1;
- repeated IndexField inserted_fields = 2;
- repeated FieldOrder deleted_fields = 3;
- repeated Field updated_fields = 4;
- }
- message IndexField {
- Field field = 1;
- int32 index = 2;
- }
- message GetEditFieldContextPayload {
- string grid_id = 1;
- oneof one_of_field_id { string field_id = 2; };
- FieldType field_type = 3;
- }
- message EditFieldPayload {
- string grid_id = 1;
- string field_id = 2;
- FieldType field_type = 3;
- bool create_if_not_exist = 4;
- }
- message FieldTypeOptionContext {
- string grid_id = 1;
- Field grid_field = 2;
- bytes type_option_data = 3;
- }
- message FieldTypeOptionData {
- string grid_id = 1;
- Field field = 2;
- bytes type_option_data = 3;
- }
- message RepeatedField {
- repeated Field items = 1;
- }
- message RepeatedFieldOrder {
- repeated FieldOrder items = 1;
- }
- message InsertFieldPayload {
- string grid_id = 1;
- Field field = 2;
- bytes type_option_data = 3;
- oneof one_of_start_field_id { string start_field_id = 4; };
- }
- message UpdateFieldTypeOptionPayload {
- string grid_id = 1;
- string field_id = 2;
- bytes type_option_data = 3;
- }
- message QueryFieldPayload {
- string grid_id = 1;
- RepeatedFieldOrder field_orders = 2;
- }
- message FieldChangesetPayload {
- string field_id = 1;
- string grid_id = 2;
- oneof one_of_name { string name = 3; };
- oneof one_of_desc { string desc = 4; };
- oneof one_of_field_type { FieldType field_type = 5; };
- oneof one_of_frozen { bool frozen = 6; };
- oneof one_of_visibility { bool visibility = 7; };
- oneof one_of_width { int32 width = 8; };
- oneof one_of_type_option_data { bytes type_option_data = 9; };
- }
- enum FieldType {
- RichText = 0;
- Number = 1;
- DateTime = 2;
- SingleSelect = 3;
- MultiSelect = 4;
- Checkbox = 5;
- URL = 6;
- }
|