Subversion Repositories SmartDukaan

Rev

Rev 23104 | Rev 23153 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 23104 Rev 23120
Line 5585... Line 5585...
5585
        pendingRechargeCommissions.approvedAmountInPaise += int(round(recharge_order.totalAmount*commissions))
5585
        pendingRechargeCommissions.approvedAmountInPaise += int(round(recharge_order.totalAmount*commissions))
5586
        #Add amount to wallet if PendingRechargeCommissions are greater than Rs. 10
5586
        #Add amount to wallet if PendingRechargeCommissions are greater than Rs. 10
5587
        if pendingRechargeCommissions.approvedAmountInPaise > 1000:
5587
        if pendingRechargeCommissions.approvedAmountInPaise > 1000:
5588
            commission_amount = int(pendingRechargeCommissions.approvedAmountInPaise/100)
5588
            commission_amount = int(pendingRechargeCommissions.approvedAmountInPaise/100)
5589
            pendingRechargeCommissions.approvedAmountInPaise = pendingRechargeCommissions.approvedAmountInPaise%100
5589
            pendingRechargeCommissions.approvedAmountInPaise = pendingRechargeCommissions.approvedAmountInPaise%100
5590
            add_amount_in_wallet(recharge_order.userId, commission_amount, None, WalletReferenceType.CASHBACK, True, "Cashback for Recharge commissions", False)
5590
            add_amount_in_wallet(recharge_order.userId, commission_amount, str(datetime.datetime.now()), WalletReferenceType.RECHARGE_COMMISSIONS, True, "Cashback for Recharge commissions", False)
5591
        session.commit()
5591
        session.commit()
5592
        gvs = allocate_gift_voucher(recharge_order)
5592
        gvs = allocate_gift_voucher(recharge_order)
5593
        enqueue_recharge_info_email(recharge_order, gvs)
5593
        enqueue_recharge_info_email(recharge_order, gvs)
5594
        return True
5594
        return True
5595
    
5595
    
Line 11239... Line 11239...
11239
        if addressMapping is not None:
11239
        if addressMapping is not None:
11240
            buyerInfo.addressId = addressMapping.id
11240
            buyerInfo.addressId = addressMapping.id
11241
            buyerInfo.buyerAddress = to_t_warehouse_address(addressMapping)
11241
            buyerInfo.buyerAddress = to_t_warehouse_address(addressMapping)
11242
        else:
11242
        else:
11243
            return None
11243
            return None
-
 
11244
        print buyerInfo
11244
        return buyerInfo
11245
        return buyerInfo
11245
 
11246
 
11246
 
11247
 
11247
def get_cost_detail_for_logistics_txn_id(logisticsTxnId):
11248
def get_cost_detail_for_logistics_txn_id(logisticsTxnId):
11248
    logisticCostDetail= ShipmentLogisticsCostDetail.get_by(logisticsTransactionId=logisticsTxnId)
11249
    logisticCostDetail= ShipmentLogisticsCostDetail.get_by(logisticsTransactionId=logisticsTxnId)