github.com/youyuanwu/go-swagger@v0.19.0/fixtures/goparsing/classification/models/order.go (about) 1 // Copyright 2015 go-swagger maintainers 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 15 package models 16 17 import "github.com/go-swagger/go-swagger/fixtures/goparsing/classification/transitive/mods" 18 19 // StoreOrder represents an order in this application. 20 // 21 // An order can either be created, processed or completed. 22 // 23 // swagger:model order 24 type StoreOrder struct { 25 // the id for this order 26 // 27 // required: true 28 // min: 1 29 ID int64 `json:"id"` 30 31 // the name for this user 32 // 33 // required: true 34 // min length: 3 35 UserID int64 `json:"userId"` 36 37 // the category of this user 38 // 39 // required: true 40 // default: bar 41 // enum: foo,bar,none 42 Category string `json:"category"` 43 44 // the items for this order 45 Items []struct { 46 ID int32 `json:"id"` 47 Pet mods.Pet `json:"pet"` 48 Quantity int16 `json:"quantity"` 49 } `json:"items"` 50 }