1
我有我認爲我需要在谷歌應用程序引擎中的模型。我基本上建立了分類廣告系統。我有數據模型...現在在Google App Engine中使用Python
這是我到目前爲止有:
class Cities(db.Model):
name = db.StringProperty()
connectors = db.ListProperty()
catList = db.ListProperty()
class Listings(db.model):
title = db.StringProperty()
category = db.CategoryProperty()
city = db.StringProperty()
editURL = db.LinkProperty()
email = db.EmailProperty()
phone = db.PhoneNumber()
user = db.UserProperty()
date = db.DateTimeProperty(auto_now_add=True)
content = db.TextProperty()
picture = db.BlobProperty()
location = db.StringProperty()
有什麼明顯的錯誤與那些?另外,我將這些文件放在一個名爲dbmodels.py的文件中,與Google App引擎的所有其他文件位於同一個目錄中。有沒有辦法將這些文件導入到需要使用的特定文件中?
最後,我有一個我想要表示的城市的列表。我怎樣才能把它變成谷歌應用程序引擎?建立一個可以創建我自己的城市的儀表板是正確的嗎?
謝謝大家提前!
3,你可以從應用程序的儀表板做簡單的數據存儲管理,這在這種情況下可能是有用的。還有一種方法可以從API中運行批量上傳數據,但如果您稍後想要編輯某些內容,則無用。 – 2010-12-07 18:17:23