# Path: model/user.py
# def check(name,info):
# def get_by_id(id):
# def fav_pages(user_id=None,show_private=False,per=5):
# def favs_of_page(page=1,per=5,user_id=0,show_private=False):
# def parse_data(name,info):
# def new_oauth_user(name,info):
# def update_oauth_userid(name,id,oauth_id):
# def update_access_token(name,id,token):
# def exist_oauth_user(name,info):
# def login_oauth_user(name,info):
# 
# Path: config/setting.py



import web
import math
from base import base
from model import user
from config.setting import render
        super(people,self).GET()

        # get current user
        cur_user = self.cur_user

        # get page user
        the_user = user.get_by_id(user_id)

        if not the_user:
            web.notfound()
            return "user not found"

        # set private
        if not cur_user or the_user.id == cur_user.id:
            show_private = 1
        else:
            show_private = 0

        # get page from url
        try:
            page = int(web.input(page=1)["page"])
        except Exception:
            page = 1

        if page < 1:
            page = 1

        per = 5

        # get favs

# Path: model/user.py
# def check(name,info):
# def get_by_id(id):
# def fav_pages(user_id=None,show_private=False,per=5):
# def favs_of_page(page=1,per=5,user_id=0,show_private=False):
# def parse_data(name,info):
# def new_oauth_user(name,info):
# def update_oauth_userid(name,id,oauth_id):
# def update_access_token(name,id,token):
# def exist_oauth_user(name,info):
# def login_oauth_user(name,info):
# 
# Path: config/setting.py



# Path: controller/page/people.py
import web
import math
from base import base
from model import user
from config.setting import render

        super(people,self).GET()

        # get current user
        cur_user = self.cur_user

        # get page user
        the_user = user.get_by_id(user_id)

        if not the_user:
            web.notfound()
            return "user not found"

        # set private
        if not cur_user or the_user.id == cur_user.id:
            show_private = 1
        else:
            show_private = 0

        # get page from url
        try:
            page = int(web.input(page=1)["page"])
        except Exception:
            page = 1

        if page < 1:
            page = 1

        per = 5

        # get favs

        favs = user.favs_of_page(page=page,per=per,user_id=user_id,show_private=show_private)