| Line 1095... |
Line 1095... |
| 1095 |
it = Item.query.filter_by(id=item.item_id).one()
|
1095 |
it = Item.query.filter_by(id=item.item_id).one()
|
| 1096 |
message+="""<tr>
|
1096 |
message+="""<tr>
|
| 1097 |
<td style="text-align:center">"""+str(item.item_id)+"""</td>
|
1097 |
<td style="text-align:center">"""+str(item.item_id)+"""</td>
|
| 1098 |
<td style="text-align:center">"""+xstr(it.brand)+" "+xstr(it.model_name)+" "+xstr(it.model_number)+" "+xstr(it.color)+"""</td>
|
1098 |
<td style="text-align:center">"""+xstr(it.brand)+" "+xstr(it.model_name)+" "+xstr(it.model_number)+" "+xstr(it.color)+"""</td>
|
| 1099 |
<td style="text-align:center">"""+str(item.ourSellingPrice)+"""</td>
|
1099 |
<td style="text-align:center">"""+str(item.ourSellingPrice)+"""</td>
|
| 1100 |
<td style="text-align:center">"""+str(item.proposedSellingPrice)+"""</td></tr>"""
|
1100 |
<td style="text-align:center">"""+str(math.ceil(item.proposedSellingPrice))+"""</td></tr>"""
|
| 1101 |
message+="""</tbody></table><h4>Auto Increase Items</h4><table border="1" style="width: 40%;">
|
1101 |
message+="""</tbody></table><h4>Auto Increase Items</h4><table border="1" style="width: 40%;">
|
| 1102 |
<thead>
|
1102 |
<thead>
|
| 1103 |
<tr><th>Item Id</th>
|
1103 |
<tr><th>Item Id</th>
|
| 1104 |
<th>Product Name</th>
|
1104 |
<th>Product Name</th>
|
| 1105 |
<th>Old Price</th>
|
1105 |
<th>Old Price</th>
|
| Line 1110... |
Line 1110... |
| 1110 |
it = Item.query.filter_by(id=item.item_id).one()
|
1110 |
it = Item.query.filter_by(id=item.item_id).one()
|
| 1111 |
message+="""<tr>
|
1111 |
message+="""<tr>
|
| 1112 |
<td style="text-align:center">"""+str(item.item_id)+"""</td>
|
1112 |
<td style="text-align:center">"""+str(item.item_id)+"""</td>
|
| 1113 |
<td style="text-align:center">"""+xstr(it.brand)+" "+xstr(it.model_name)+" "+xstr(it.model_number)+" "+xstr(it.color)+"""</td>
|
1113 |
<td style="text-align:center">"""+xstr(it.brand)+" "+xstr(it.model_name)+" "+xstr(it.model_number)+" "+xstr(it.color)+"""</td>
|
| 1114 |
<td style="text-align:center">"""+str(item.ourSellingPrice)+"""</td>
|
1114 |
<td style="text-align:center">"""+str(item.ourSellingPrice)+"""</td>
|
| 1115 |
<td style="text-align:center">"""+str(item.proposedSellingPrice)+"""</td></tr>"""
|
1115 |
<td style="text-align:center">"""+str(math.ceil(item.ourSellingPrice+max(10,.01*item.ourSellingPrice)))+"""</td></tr>"""
|
| 1116 |
message+="""</tbody></table></body></html>"""
|
1116 |
message+="""</tbody></table></body></html>"""
|
| 1117 |
print message
|
1117 |
print message
|
| 1118 |
mailServer = smtplib.SMTP("smtp.gmail.com", 587)
|
1118 |
mailServer = smtplib.SMTP("smtp.gmail.com", 587)
|
| 1119 |
mailServer.ehlo()
|
1119 |
mailServer.ehlo()
|
| 1120 |
mailServer.starttls()
|
1120 |
mailServer.starttls()
|