diff options
author | ꦌ ꦫꦶ ꦏ꧀ꦦꦿ ꦧ ꦮ ꦑ ꦩ ꦭ꧀ <erik@darapsa.co.id> | 2019-09-27 16:18:18 +0800 |
---|---|---|
committer | ꦌ ꦫꦶ ꦏ꧀ꦦꦿ ꦧ ꦮ ꦑ ꦩ ꦭ꧀ <erik@darapsa.co.id> | 2019-09-27 16:18:18 +0800 |
commit | 2950dbe8099c6ffe17f05aa59175e7c71bc97bfd (patch) | |
tree | d31924c74c4ed67100d991663a8c695e86523938 /icclient | |
parent | 8d7952b68665b0668428d65c277eb699d7523833 (diff) |
Order prototype
Diffstat (limited to 'icclient')
-rw-r--r-- | icclient/ord.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/icclient/ord.h b/icclient/ord.h new file mode 100644 index 0000000..4491ba4 --- /dev/null +++ b/icclient/ord.h @@ -0,0 +1,28 @@ +#ifndef ICCLIENT_ORD_H +#define ICCLIENT_ORD_H + +#include "product.h" + +struct icclient_item { + struct icclient_product *product; + unsigned int quantity; +}; + +struct icclient_order { + double subtotal, shipping, totalcost; + size_t nitems; + struct icclient_item *items[]; +}; + +#ifdef __cplusplus +extern "C" { +#endif + + void icclient_remove(const unsigned int *indices); + void icclient_checkout(struct ic_order *order); + +#ifdef __cplusplus +} +#endif + +#endif // ICCLIENT_ORD_H |