def get(self): identificador = self.get_argument("id", "") if identificador != "": tag = Tag() eliminar_asociaciones = tag.RemoveTagsAsociationByTagId( identificador) if "success" in eliminar_asociaciones: tag.id = identificador eliminar_tag = tag.Remove() self.write(json_util.dumps(eliminar_tag)) else: self.write(json_util.dumps(eliminar_asociaciones)) else: self.write( json_util.dumps( {"error": "identificador del tag no debe estar vacío"}))
def get(self): tag_id = self.get_argument("tag_id", "") if tag_id != "": tag = Tag() res = tag.RemoveTagsAsociationByTagId(tag_id) self.write(json_util.dumps(res)) else: self.write( json_util.dumps({"error": "Identificador del tag viene vacío"}))