
    ,Wi                     |    S SK JrJrJrJrJrJrJr  S SKJ	r	J
r
Jr  \" S\5      r\R                  SS/S9S 5       rg)	    )	Blueprintrender_templateredirecturl_forjsonifycurrent_appg)ChallengeRecordDeploymentRecordCategoryConfigindex/GET)methodsc                     [         R                  R                  5       [        R                  R	                  SS9R                  5       [
        R                  R	                  SS9R                  5       S.n [
        R                  R	                  SS9R                  [
        R                  5      R                  S5      R                  5       n/ n[        [        S5      (       a  [        R                  (       a}  [         R                  R	                  [        R                  R                  S9R                  [         R                  R                  5       5      R                  S	5      R                  5       nU(       dX  [         R                  R                  [         R                  R                  5       5      R                  S	5      R                  5       n[!        S
U UUS9$ )u   站点主页running)statusT)enabled)total_challengesactive_deploymentstotal_categories   user)user_id   zpages/home/index.htmlstats
categoriesrecent_challenges)r
   querycountr   	filter_byr   order_by
sort_orderlimitallhasattrr	   r   id
created_atdescr   r   s      9   /Users/yu22x/Desktop/ddd_副本128/ctf/app/routes/base.pyr   r   	   s]   
 ,11779.44>>i>PVVX*00::4:HNNPE  %%///=FF~G`G`agghijnnpJ q&aff+11;;AFFII;NXo005578q##% 	 +11::?;U;U;Z;Z;\]ccdefjjl2$$.+<> >    N)flaskr   r   r   r   r   r   r	   app.models.database.modelsr
   r   r   __name__bp_indexrouter    r,   r+   <module>r3      sG    X X X 
 Wh'	eW%> &>r,   