| Line 9... |
Line 9... |
| 9 |
from elixir.fields import Field
|
9 |
from elixir.fields import Field
|
| 10 |
from elixir.options import using_options, using_table_options
|
10 |
from elixir.options import using_options, using_table_options
|
| 11 |
from elixir.relationships import ManyToOne, OneToMany
|
11 |
from elixir.relationships import ManyToOne, OneToMany
|
| 12 |
from sqlalchemy.engine import create_engine
|
12 |
from sqlalchemy.engine import create_engine
|
| 13 |
from sqlalchemy.types import Integer, String, Float, DateTime, Boolean, Enum, \
|
13 |
from sqlalchemy.types import Integer, String, Float, DateTime, Boolean, Enum, \
|
| 14 |
Numeric, BigInteger
|
14 |
Numeric, BigInteger, LargeBinary
|
| 15 |
|
15 |
|
| 16 |
#===============================================================================
|
16 |
#===============================================================================
|
| 17 |
# Different entities in the model
|
17 |
# Different entities in the model
|
| 18 |
#===============================================================================
|
18 |
#===============================================================================
|
| 19 |
|
19 |
|
| Line 107... |
Line 107... |
| 107 |
pickup_timestamp = Field(DateTime)
|
107 |
pickup_timestamp = Field(DateTime)
|
| 108 |
delivery_timestamp = Field(DateTime)
|
108 |
delivery_timestamp = Field(DateTime)
|
| 109 |
outofstock_timestamp = Field(DateTime)
|
109 |
outofstock_timestamp = Field(DateTime)
|
| 110 |
lineitems = OneToMany("LineItem")
|
110 |
lineitems = OneToMany("LineItem")
|
| 111 |
transaction = ManyToOne("Transaction")
|
111 |
transaction = ManyToOne("Transaction")
|
| - |
|
112 |
insuranceDetails = OneToMany("InsuranceDetailForOrder")
|
| 112 |
jacket_number = Field(Integer)
|
113 |
jacket_number = Field(Integer)
|
| 113 |
receiver = Field(String(50))
|
114 |
receiver = Field(String(50))
|
| 114 |
batchNo = Field(Integer)
|
115 |
batchNo = Field(Integer)
|
| 115 |
serialNo = Field(Integer)
|
116 |
serialNo = Field(Integer)
|
| 116 |
doaFlag = Field(Boolean)
|
117 |
doaFlag = Field(Boolean)
|
| Line 145... |
Line 146... |
| 145 |
originalOrderId = Field(Integer)
|
146 |
originalOrderId = Field(Integer)
|
| 146 |
fulfilmentWarehouseId = Field(Integer)
|
147 |
fulfilmentWarehouseId = Field(Integer)
|
| 147 |
orderType = Field(Integer)
|
148 |
orderType = Field(Integer)
|
| 148 |
pickupStoreId = Field(Integer, default=0, server_default="0")
|
149 |
pickupStoreId = Field(Integer, default=0, server_default="0")
|
| 149 |
otg = Field(Boolean, default=0, server_default="0")
|
150 |
otg = Field(Boolean, default=0, server_default="0")
|
| - |
|
151 |
insurer = Field(Integer)
|
| - |
|
152 |
insuranceAmount = Field(Float)
|
| 150 |
using_options(shortnames=True)
|
153 |
using_options(shortnames=True)
|
| 151 |
using_table_options(mysql_engine="InnoDB")
|
154 |
using_table_options(mysql_engine="InnoDB")
|
| 152 |
|
155 |
|
| 153 |
class CodVerificationAgent(Entity):
|
156 |
class CodVerificationAgent(Entity):
|
| 154 |
orderId = Field(Integer, primary_key=True, autoincrement=True)
|
157 |
orderId = Field(Integer, primary_key=True, autoincrement=True)
|
| Line 264... |
Line 267... |
| 264 |
ip = Field(String(256))
|
267 |
ip = Field(String(256))
|
| 265 |
deniedOn = Field(DateTime)
|
268 |
deniedOn = Field(DateTime)
|
| 266 |
rechargeType = Field(Integer)
|
269 |
rechargeType = Field(Integer)
|
| 267 |
deviceNumber = Field(String(128))
|
270 |
deviceNumber = Field(String(128))
|
| 268 |
using_options(shortnames=True)
|
271 |
using_options(shortnames=True)
|
| 269 |
using_table_options(mysql_engine="InnoDB")
|
- |
|
| 270 |
|
272 |
using_table_options(mysql_engine="InnoDB")
|
| - |
|
273 |
|
| - |
|
274 |
class InsuranceDetailForOrder(Entity):
|
| - |
|
275 |
id = Field(Integer, primary_key=True, autoincrement=True)
|
| - |
|
276 |
dob = Field(String(64))
|
| - |
|
277 |
guardianName = Field(String(255))
|
| - |
|
278 |
startDate = Field(DateTime)
|
| - |
|
279 |
expiryDate = Field(DateTime)
|
| - |
|
280 |
isDeclared = Field(Boolean)
|
| - |
|
281 |
policyDoc = Field(LargeBinary)
|
| - |
|
282 |
order = ManyToOne("Order")
|
| - |
|
283 |
using_options(shortnames=True)
|
| - |
|
284 |
using_table_options(mysql_engine="InnoDB")
|
| - |
|
285 |
|
| 271 |
|
286 |
|