0
我需要訪問脫水修改一些數據之前,它進行驗證(我不能修改驗證中的數據,因爲我需要訪問請求對象)。但是,我的調試語句表明POST請求甚至沒有達到我的脫水方法(GET請求確實達到了它)。這裏是我的脫水方法,裏面PostResource的:Tastypie - 脫水不叫POST?
def dehydrate(self, bundle):
print 'in dehydrate'
bundle.data['location_model'] = self.get_via_uri(bundle.data['location'], bundle.request)
return bundle
我怎麼能說在脫水後的方法?