engine/process.py
def point_location(self, message):
        """Save a point geometry derived from message.location
           and its creation time in the latest feature for
           a message/call sender. Return the proper answer"""
        lat = message.location.latitude
        long = message.location.longitude
        time = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S")

        cursor.execute(f"update {self.db}features set point = ST_GeomFromText("
                       f"'POINT({long} {lat})',4326), entr_time = '{time}'"
                       f"where id = (select max(id) from {self.db}features where user_id = {message.from_user.id})")
        connection.commit()

        return answers['POINT_MEDIA'] % (lat, long)
Save a point geometry derived from message.location
           and its creation time in the latest feature for
           a message/call sender. Return the proper answer
Save a point geometry derived from message.location
and its creation time in the latest feature for
a message/call sender. Return the proper answer
Save a point geometry derived from message . location and its creation time in the latest feature for a message / call sender . Return the proper answer
def point_location(self, message):
        lat = message.location.latitude
        long = message.location.longitude
        time = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S")
        cursor.execute(f"update {self.db}features set point = ST_GeomFromText("
                       f"'POINT({long} {lat})',4326), entr_time = '{time}'"
                       f"where id = (select max(id) from {self.db}features where user_id = {message.from_user.id})")
        connection.commit()
        return answers['POINT_MEDIA'] % (lat, long)
def point_location ( self , message ) : lat = message . location . latitude long = message . location . longitude time = datetime . datetime . now ( ) . strftime ( "%Y-%m-%d %H:%M:%S" ) cursor . execute ( f"update {self.db}features set point = ST_GeomFromText(" f"'POINT({long} {lat})',4326), entr_time = '{time}'" f"where id = (select max(id) from {self.db}features where user_id = {message.from_user.id})" ) connection . commit ( ) return answers [ 'POINT_MEDIA' ] % ( lat , long )
Save a point geometry derived from message.location
and its creation time in the latest feature for
a message/call sender.
Save a point geometry derived from message . location and its creation time in the latest feature for a message / call sender .
"""Save a point geometry derived from message.location
           and its creation time in the latest feature for
           a message/call sender. Return the proper answer"""
self
message