我有关于任务队列的问题..
这是我的任务队列的代码:
taskqueue.add(url='/taskaddroom', params={'code': self.request.get('code'),
'room_type': self.request.get('room_type'),
'start_date': self.request.get('start_date'),
'end_date': self.request.get('end_date'),
'net_price': self.request.get('net_price'),
'num_person': self.request.get('num_person'),
'max_adult': self.request.get('max_adult'),
'max_children': self.request.get('room_type'),
'num_slots': self.request.get('num_slots')})
这是我的处理程序的代码:
class TaskAddRoom(webapp2.RequestHandler):
def post(self):
code = self.request.get('code'),
room_type = self.request.get('room_type'),
start_date = self.request.get('start_date'),
end_date = self.request.get('end_date'),
net_price = self.request.get('net_price'),
num_person = self.request.get('num_person'),
max_adult = self.request.get('max_adult'),
max_children = self.request.get('max_children')
slots = self.request.get('num_slots')
for a in slots:
add = AddRooms(code, room_type, start_date, end_date, net_price, num_person, max_adult, max_children)
result = add.addrooms()
我的问题是 TaskAddRooms 类它不起作用..并且没有给我错误的迹象......
谢谢..