(_ []string)
| 998 | } |
| 999 | |
| 1000 | func (p ProjectField) ExportData(_ []string) map[string]interface{} { |
| 1001 | v := map[string]interface{}{ |
| 1002 | "id": p.ID(), |
| 1003 | "name": p.Name(), |
| 1004 | "type": p.Type(), |
| 1005 | } |
| 1006 | // Emulate omitempty |
| 1007 | if opts := p.Options(); len(opts) != 0 { |
| 1008 | options := make([]map[string]interface{}, len(opts)) |
| 1009 | for i, opt := range opts { |
| 1010 | options[i] = opt.ExportData(nil) |
| 1011 | } |
| 1012 | v["options"] = options |
| 1013 | } |
| 1014 | return v |
| 1015 | } |
| 1016 | |
| 1017 | type ProjectFields struct { |
| 1018 | TotalCount int |