예제 #1
0
func FetchPayment(endpoint string, id string) (*Payment, error) {
	var result Payment
	return &result, services.Http_get_json("http://"+endpoint+"/payment/"+id, &result)
}
예제 #2
0
func GetShipment(endpoint string, id string) (*Shipment, error) {
	var result Shipment
	return &result, services.Http_get_json("http://"+endpoint+"/shipment/"+id, &result)
}
예제 #3
0
func GetItem(endpoint string, item string) (*Item, error) {
	var result Item
	return &result, services.Http_get_json("http://"+endpoint+"/item/"+item, &result)
}
예제 #4
0
func AllItems(endpoint string) ([]*Item, error) {
	var result []*Item
	return result, services.Http_get_json("http://"+endpoint+"/items", &result)
}
예제 #5
0
func GetOrder(shopEndpoint string, orderId string) (*Order, error) {
	var result *Order
	return result, services.Http_get_json("http://"+shopEndpoint+"/order/"+orderId, &result)
}
예제 #6
0
func AllOrders(shopEndpoint string, user string) ([]*Order, error) {
	var result []*Order
	return result, services.Http_get_json("http://"+shopEndpoint+"/orders/"+user, &result)
}