def index(self): #look at cookie cookie = request.cookies.get("FCS_GFB_Cookie") if(cookie == None): return "{\"success\":\"false\", \"message\":\"You must be logged in to see this page\"}" else: creds = Cookie.decryptCookie(cookie) if(creds.get('role') == '2'): return render('/tools/coordDash.mako') elif (creds.get('role') == '1'): return render('/tools/adminDash.mako') else: return "{\"success\":\"false\", \"message\":\"You must be a coordinator or administrator to see this page\"}"
def index(self): #look at cookie cookie = request.cookies.get("FCS_GFB_Cookie") if (cookie == None): return "{\"success\":\"false\", \"message\":\"You must be logged in to see this page\"}" else: creds = Cookie.decryptCookie(cookie) if (creds.get('role') == '2'): return render('/tools/coordDash.mako') elif (creds.get('role') == '1'): return render('/tools/adminDash.mako') else: return "{\"success\":\"false\", \"message\":\"You must be a coordinator or administrator to see this page\"}"
def me(self): if (request.method == "GET"): cookie = request.cookies.get("GFB_Cookie") if(cookie == None): return '' else: decode = Cookie.decryptCookie(cookie) return json.dumps(decode) else: #open host site cookie = request.cookies.get("GFB_Cookie") if(cookie == None): return '' else: encode = {} decode = Cookie.decryptCookie(cookie) encode['role'] = decode['role'] encode['user_name'] = decode['user_name'] encode['email'] = decode['email'] if (request.params['changed'] == 'true'): encode['host_site'] = request.params['siteID'] else: encode['host_site'] = '' cookie = Cookie(encode['user_name'],encode['email'], encode['role'], encode['host_site']) response.delete_cookie('GFB_Cookie') response.set_cookie("GFB_Cookie", cookie.encryptCookie(), max_age=180*24*3600) return render('/tools/distOrders.mako')
def me(self): if (request.method == "GET"): cookie = request.cookies.get("GFB_Cookie") if (cookie == None): return '' else: decode = Cookie.decryptCookie(cookie) return json.dumps(decode) else: #open host site cookie = request.cookies.get("GFB_Cookie") if (cookie == None): return '' else: encode = {} decode = Cookie.decryptCookie(cookie) encode['role'] = decode['role'] encode['user_name'] = decode['user_name'] encode['email'] = decode['email'] if (request.params['changed'] == 'true'): encode['host_site'] = request.params['siteID'] else: encode['host_site'] = '' cookie = Cookie(encode['user_name'], encode['email'], encode['role'], encode['host_site']) response.delete_cookie('GFB_Cookie') response.set_cookie("GFB_Cookie", cookie.encryptCookie(), max_age=180 * 24 * 3600) return render('/tools/distOrders.mako')
def editprofile(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: return render('/tools/editProfile.mako')
def changepassword(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: return render('/tools/changePassword.mako')
def changepassword(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: return render('/tools/changePassword.mako')
def dashboard(self): cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) return render('/tools/dashboard.mako')
def dashboard(self): cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) return render('/tools/dashboard.mako')
def editprofile(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: return render('/tools/editProfile.mako')
def document(self): """Render the error document""" request = self._py_object.request resp = request.environ.get('pylons.original_response') content = literal(resp.body) or cgi.escape(request.GET.get('message', '')) page = error_document_template % \ dict(prefix=request.environ.get('SCRIPT_NAME', ''), code=cgi.escape(request.GET.get('code', str(resp.status_int))), message=content) return render('/404.mako')
def cashsales(self): cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if (creds.get('role') == '1') or (creds.get('role') == '2') or (creds.get('role') == '3'): return render('/tools/cashSales.mako') else: response.status_int = 404 return
def manageHS(self): cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if(creds.get('role') == '3' or creds.get('role') == '2' or creds.get('role') == '1'): return render("/tools/manageHS.mako"); else: response.status_int = 404 return
def manageAccounts(self): cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if (creds.get('role') == '2') or (creds.get('role') == '1'): return render('/tools/manageAccounts.mako') else: response.status_int = 404 return
def masterCustList(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if (creds.get('role') == '2') or (creds.get('role') == '1'): return render('/tools/masterCustList.mako') else: response.status_int = 404 return
def manageHS(self): cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if (creds.get('role') == '3' or creds.get('role') == '2' or creds.get('role') == '1'): return render("/tools/manageHS.mako") else: response.status_int = 404 return
def masterCustList(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if (creds.get('role') == '2') or (creds.get('role') == '1'): return render('/tools/masterCustList.mako') else: response.status_int = 404 return
def distribution(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if(cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if ((creds.get('role') == '3') or (creds.get('role') == '2') or (creds.get('role') == '1')) : return render('/tools/distOrders.mako') else: response.status_int = 404 return
def distribution(self): #look at cookie cookie = request.cookies.get("GFB_Cookie") if (cookie == None): response.status_int = 404 return else: creds = Cookie.decryptCookie(cookie) if ((creds.get('role') == '3') or (creds.get('role') == '2') or (creds.get('role') == '1')): return render('/tools/distOrders.mako') else: response.status_int = 404 return
def buy(self): return render("/shop/newOrder.mako")
def login(self): return render('/login.mako')
def info(self): return render('info/info.mako')
def managesamples(self): return render('tools/sampleBoxes.mako')
def confirm(self): return render('/tools/confirmOrder.php')
def yourdonations(self): return render('tools/yourDonations.mako')
def completeorder(self): return render("/shop/completedOrder.mako")
def contact(self): return render('/contact/contact.mako')
def home(self): return render("/shop/home.mako")
def index(self): return render('/index.mako')
def pickupdates(self): return render('tools/pickupDates.mako')
def index(self): return render('/tools/cashSales.mako')
def yourorders(self): return render('tools/yourOrders.mako')
def index(self): return render('/index.mako');
def home(self): return render("/shop/home.mako");
def donate(self): return render('/donate/donate.mako')
def newOrder(self): return render("/shop/newOrder.mako");
def signup(self): return render('signup.mako')