跳至內容
選單
此問題已被標幟
3198 瀏覽次數

Hello,


I'm trying to edit the main.py controller file to make some sites available only after the user login.


For example, i have two sites:


www.mysite.com/site1

www.mysite.com/site2


I want to be able to view site1 without login and site2 private, only after the user logged in.


In the main.py i'm trying to add a new method:


@http.route('/site2',type='http',auth='user',website=True)

    def site2(self,**kw):

    // i don't know what put here


Someone can help me with the information i have to put to get what i want?


Thanks for your help

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
4
5月 25
5185
2
1月 25
2318
4
1月 25
4455
0
11月 24
1706
1
11月 24
2532