Subversion Repositories SmartDukaan

Rev

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

Rev 15142 Rev 15145
Line 617... Line 617...
617
            self.callHistory.call_type=self.callType
617
            self.callHistory.call_type=self.callType
618
            self.callHistory.duration_sec = int(jsonReq.get("callduration"))
618
            self.callHistory.duration_sec = int(jsonReq.get("callduration"))
619
            self.callHistory.disposition_description = jsonReq.get('calldispositiondescritption')
619
            self.callHistory.disposition_description = jsonReq.get('calldispositiondescritption')
620
            self.callHistory.call_time = datetime.strptime(jsonReq.get("calltime"), '%d/%m/%Y %H:%M:%S')
620
            self.callHistory.call_time = datetime.strptime(jsonReq.get("calltime"), '%d/%m/%Y %H:%M:%S')
621
            self.callHistory.mobile_number = jsonReq.get('number')
621
            self.callHistory.mobile_number = jsonReq.get('number')
622
            self.callHistory.sms_verified = 0
622
            self.callHistory.sms_verified = int(jsonReq.get("verified"))
623
            
623
            
624
            dispositionMap = {  'call_later':callLater,
624
            dispositionMap = {  'call_later':callLater,
625
                        'ringing_no_answer':callLater,
625
                        'ringing_no_answer':callLater,
626
                        'not_reachable':callLater,
626
                        'not_reachable':callLater,
627
                        'switch_off':callLater,
627
                        'switch_off':callLater,
Line 712... Line 712...
712
        if self.callHistory.disposition_description is None:
712
        if self.callHistory.disposition_description is None:
713
            self.callHistory.disposition_description = 'Retailer already user' 
713
            self.callHistory.disposition_description = 'Retailer already user' 
714
        session.commit()
714
        session.commit()
715
        return True
715
        return True
716
    def verifiedLinkSent(self,):
716
    def verifiedLinkSent(self,):
717
        self.retailer.status = 'retry' if self.callType == 'fresh' else 'fretry'
717
        self.retailer.status = self.callDisposition
-
 
718
        if self.callHistory.disposition_description is None:
-
 
719
            self.callHistory.disposition_description = 'User is verified, app link sent'
718
        
720
        
719
 
721
 
720
def todict(obj, classkey=None):
722
def todict(obj, classkey=None):
721
    if isinstance(obj, dict):
723
    if isinstance(obj, dict):
722
        data = {}
724
        data = {}