
    Bh{                        d dl Z d dlmZmZ d dlmZ d dlmZ d dlmZm	Z	m
Z
 d dlmZ d dlmZ d dlmZ d d	lmZ d d
lmZ d dlmZ d dlmZmZ d dlmZ d dlmZ d dlm Z m!Z! d dl"m#Z# d dl$m%Z%m&Z& d dl'm(Z(  G d de	jR                        Z*y)    N)datetime	timedelta)GenericForeignKey)ContentType)
connectionmodelstransaction)title)	force_str)lazy)gettext_lazy)invalidate_cms_page_cache)clear_placeholder_cache)
EXPIRE_NOWMAX_EXPIRATION_TTL)LanguageError)PlaceholderManager)get_language_from_requestpermissions)RemovedInDjangoCMS51Warning)get_cms_settingget_site_id)get_language_objectc                   N   e Zd ZdZ ej
                   ed      ddd      Z ej                   ed      dd      Z	 ej                  eddej                  	      Z ej                  dd
      Z edd      ZdZdZdZ e       Z G d d      Zd Zd Zd8dZd Zd8dZd Zd Zd Zd Z d Z!d Z"d Z#d Z$d Z%d Z&d Z'd  Z(d! Z)d" Z* e+e)e*      Z,d8d#Z-d8d$Z.d8d%Z/d& Z0d' Z1e+d(        Z2d) Z3d8d*Z4d8d+Z5d, Z6d9d-Z7d. Z8d9d/Z9d8d0Z:d1 Z;d2 Z<d:d3Z=d8d4Z>d8d5Z?d8d6Z@d7 ZAy);PlaceholderzY

    ``Placeholders`` can be filled with plugins, which store or generate content.

    slot   TF)
max_lengthdb_indexeditablewidth)nullr    )blankr"   	on_delete)r#   r"   content_type	object_idc                       e Zd ZdZg ZdZy)Placeholder.Metacms))use_structurezCan use Structure modeN)__name__
__module____qualname__	app_labeldefault_permissionsr        K/home/dcms/DCMS/lib/python3.12/site-packages/cms/models/placeholdermodel.pyMetar(   0   s    	 Dr1   r3   c                     | j                   S N)r   selfs    r2   __str__zPlaceholder.__str__5   s    yyr1   c                     d| j                    d| j                  j                   d| j                   d| j                   dt        t        |              d}|S )N<.z id=z slot='z' object at >)r,   	__class__r+   pkr   hexid)r7   displays     r2   __repr__zPlaceholder.__repr__8   sZ     $.."9"9!:$twwiwtyykYefijlmqjrfsettuv 	 r1   Nc                 B    | j                  |      j                          y)z(Deletes all plugins from the placeholderN)get_pluginsdeleter7   languages     r2   clearzPlaceholder.clear>   s    "))+r1   c                    ddl m} ddlm} d }t	        | j
                  |      r) t        | j
                  j                  t                     } |d| j                  |t        | j                              }t        |      }|S )Nr   PageContentget_placeholder_confname)templatedefault)
cms.modelsrK   cms.utils.placeholderrM   
isinstancesourcer   get_templatestrr   r
   _)r7   rK   rM   rO   rN   s        r2   	get_labelzPlaceholder.get_labelB   se    *>dkk;/:tDKK44c:<H#FDIIRWX\XaXaRbcwr1   c                 8    ddl m}  |d| j                  |i       S )Nr   rL   extra_context)rR   rM   r   )r7   rO   rM   s      r2   get_extra_contextzPlaceholder.get_extra_contextN   s    >#OTYY"MMr1   c                 0    ddl m} |j                  |       S )Nr   )plugin_pool)cms.plugin_poolr]    get_extra_placeholder_menu_items)r7   r]   s     r2   get_extra_menu_itemsz Placeholder.get_extra_menu_itemsS   s    /;;DAAr1   c                 .   ddl m} | j                  s|j                  S 	 | j                  j                  |      S # t        $ rP t        | j                        } ||d      }|j                  |      xs |j                  || j                        cY S w xY w)zl
        Returns ``True`` if user has permission to change all models attached to this placeholder.
        r   )get_model_permission_codenamechange)	cms.utils.permissionsrb   r&   is_superuserrT   !has_placeholder_change_permissionAttributeErrortypehas_perm)r7   userrb   modelchange_perms        r2   has_change_permissionz!Placeholder.has_change_permissionX   s     	H~~ $$$	Y;;@@FF 	Y%E7xHK==-X{DKK1XX	Ys   ; ABBc                 X    t        j                  ||d      sy| j                  |      syy)ze
        Returns ``True`` if user has permission to add ``plugin_type`` to this placeholder.
        addFT)r   has_plugin_permissionrm   )r7   rj   plugin_types      r2   has_add_plugin_permissionz%Placeholder.has_add_plugin_permissionk   s-     00{EJ))$/r1   c                 |    | j                  |      sy|D ]%  }t        j                  ||j                  d      r% y y)zt
        Returns ``True`` if user has permission to add **all** plugins in ``plugins`` to this placeholder.
        Fro   T)rm   r   rp   rq   )r7   rj   pluginsplugins       r2   has_add_plugins_permissionz&Placeholder.has_add_plugins_permissionv   sD     ))$/ 	F44T6;M;MuU	 r1   c                 l    t        j                  ||j                  d      sy| j                  |      syy)zc
        Returns ``True`` if user has permission to change ``plugin`` to this placeholder.
        rc   FTr   rp   rq   rm   r7   rj   ru   s      r2   has_change_plugin_permissionz(Placeholder.has_change_plugin_permission   3     00v7I7I8T))$/r1   c                 l    t        j                  ||j                  d      sy| j                  |      syy)zc
        Returns ``True`` if user has permission to delete ``plugin`` to this placeholder.
        rE   FTrx   ry   s      r2   has_delete_plugin_permissionz(Placeholder.has_delete_plugin_permission   r{   r1   c                     t        j                  ||j                  d      sy|j                  |      sy| |k7  r| j                  |      syy)zk
        Returns ``True`` if user has permission to move ``plugin`` to the ``target_placeholder``.
        rc   FTrx   )r7   rj   ru   target_placeholders       r2   has_move_plugin_permissionz&Placeholder.has_move_plugin_permission   sL     00v7I7I8T!77=%%d.H.H.Nr1   c                 J    | j                  |      sy| j                  ||      S )c
        Returns ``True`` if user has permission to delete all plugins in this placeholder
        F)rm   has_delete_plugins_permission)r7   rj   	languagess      r2   has_clear_permissionz Placeholder.has_clear_permission   s(     ))$/11$	BBr1   c                    | j                   j                  |      j                  d      j                  dd      j	                         j                         }t        j                  }|j                         D ]  } |||d      r y y)	r   )language__inPlaceholderPlugin)rq   rq   TflatrE   F)	cmsplugin_setfilterexcludevalues_listdistinctorder_byr   rp   iterator)r7   rj   r   plugin_typeshas_permissionrq   s         r2   r   z)Placeholder.has_delete_plugins_permission   s    
 %%9%=W!4W5[T[2XZXZ 	 %::'002 	K!$X>	 r1   c                     | j                   y t        d | j                  j                  j	                         D              S )Nc              3   H   K   | ]  }|j                   t        k(  s|  y wr5   )related_modelr   ).0fs     r2   	<genexpr>z7Placeholder._get_source_remote_field.<locals>.<genexpr>   s     `!T_A_A`s   "")r&   nextrT   _meta
get_fieldsr6   s    r2   _get_source_remote_fieldz$Placeholder._get_source_remote_field   s3    >>!`t{{00;;=```r1   c                 L    | j                         }|y|j                  | |      S )NT)r   
run_checks)r7   rj   remote_fields      r2   check_sourcezPlaceholder.check_source   s,    446&&tT22r1   c                 \    | j                   r | j                   j                  j                  S y r5   )rT   r   rk   r6   s    r2   _get_attached_modelzPlaceholder._get_attached_model   s"    ;;;;$$***r1   c                 *   t        | d      s[ddlm} 	 |j                  j	                  |       j                  d      j                         j                  | _        | j                  S | j                  S # t        $ r d | _        Y | j                  S w xY w)N_pager   rJ   )placeholderspage)
hasattrcms.models.contentmodelsrK   admin_managerr   select_relatedfirstr   r   rg   )r7   rK   s     r2   page_getterzPlaceholder.page_getter   s    tW%<"(66==4=P__`fgmmott
 zztzz " "!
zz"s   AA4 4BBc                     || _         y r5   )r   )r7   values     r2   page_setterzPlaceholder.page_setter   s	    
r1   c                 6    t        | j                  |            S )zReturns a list of plugins attached to this placeholder. If language is given only plugins
        in the given language are returned.)listrD   rF   s     r2   get_plugins_listzPlaceholder.get_plugins_list   s     D$$X.//r1   c                 r    |r| j                   j                  |      S | j                   j                         S )zReturns a queryset of plugins attached to this placeholder. If language is given only plugins
        in the given language are returned.rG   )r   r   allrF   s     r2   rD   zPlaceholder.get_plugins   s6     %%,,h,??!!%%''r1   c                 @    | j                  |      j                         S )zBChecks if placeholder is empty (``False``) or populated (``True``))rD   existsrF   s     r2   has_pluginszPlaceholder.has_plugins   s    )0022r1   c                     g }t        | j                         j                  dd            D ]  }	 |j                  t	        |              |S # t
        $ r Y -w xY w)z
        Returns language objects for every language for which the placeholder
        has plugins.

        This is not cached as it's meant to be used in the frontend editor.
        rG   Tr   )setrD   r   appendr   r   )r7   r   	lang_codes      r2   get_filled_languagesz Placeholder.get_filled_languages   sk     	T--/;;JT;RS 	I  !4Y!?@	
  ! s   A	AAc                     t        | dg       S )N_plugins_cache)getattrr6   s    r2   get_cached_pluginszPlaceholder.get_cached_plugins  s    t-r22r1   c                 V    dd l }ddlm}  |j                  dt        d        |       S )Nr   )PlaceholderNoActionzBThe actions property is deprecated. Use placeholder admin instead.   )
stacklevel)warningsrR   r   warnr   )r7   r   r   s      r2   actionszPlaceholder.actions  s*    =P'	

 #$$r1   c           
          t         } j                  rt        d      st        S  fd}t	        | j
                        } ||      D ]  \  }}|j                  ||       }|t        |t        t        f      r6t        |t              r	 ||z
  }	n|}	t#        |	j%                         dz         }
n	 t#        |      }
t)        |
|      }|dk  st        c S  |S # t        $ rF t        j                  d|j                  j                  |j                  t!        |      dz         Y w xY w# t&        $ rG t        j                  d|j                  j                  |j                  t!        |      dz         Y 2w xY w)u`  
        Returns the number of seconds (from «response_timestamp») that this
        placeholder can be cached. This is derived from the plugins it contains.

        This method must return: ``EXPIRE_NOW <= int <= MAX_EXPIRATION_IN_SECONDS``

        :type request: HTTPRequest
        :type response_timestamp: datetime
        :rtype: int
        PLUGIN_CACHEc              3      K   t        d      r(j                  D ]  }|j                         }||f  yj                  |       D ]  }|j	                           yw)aA  
            The placeholder will have a cache of all the concrete plugins it
            uses already, but just in case it doesn't, we have a code-path to
            generate them anew.

            This is made extra private as an inner function to avoid any other
            process stealing our yields.
            _all_plugins_cacheNr   r   get_plugin_class_instancerD   get_plugin_instancelanginstanceru   plugin_itemr7   s       r2   inner_plugin_iteratorz?Placeholder.get_cache_expiration.<locals>.inner_plugin_iterator(  sm      t12 $ 7 7 +H%??AF"F**+ $(#3#3D#9 <K%99;;<   AA!zlPlugin %(plugin_class)s (%(pk)d) returned a naive datetime : %(value)s for get_cache_expiration(), ignoring.plugin_classr>   r   g      ?zjPlugin %(plugin_class)s (%(pk)d) returned unexpected value %(value)s for get_cache_expiration(), ignoring.r   )r   cache_placeholderr   r   r   r   get_cache_expirationrS   r   r   	TypeErrorr   r   r=   r+   r>   r   inttotal_seconds
ValueErrormin)r7   requestresponse_timestampmin_ttlr   rG   r   ru   plugin_expirationdeltattls   `          r2   r   z Placeholder.get_cache_expiration  s    %%%_^-L 	<" -Wdii@ 5h ? 6	"Hf & ; ;GXt T !(+h	-BC/:! 14F F$ .E%--/#56/0C #w'G!| "!m6	"p U % ! !( 170@0@0I0I&.kk)23D)E	 !!, " MM< -3,<,<,E,E"*++%./@%A	 s&   C1D+AD('D(+AE;:E;c                     t        d      r
t                |s"| j                  r| j                  j                  }t	        | |t        |             y )N
PAGE_CACHE)r   r   r   site_idr   r   )r7   rG   r   s      r2   clear_cachezPlaceholder.clear_cachet  s9    <(%'499ii''GhG0DEr1   c                     | j                  |      j                  |      j                  d      j                  dd      }t	        |      S )zn
        Returns a list of plugin ids matching the given language
        ordered by plugin position.
        parentpositionr>   Tr   )rD   r   r   r   r   )r7   rG   	parent_idplugin_tree_orders       r2   get_plugin_tree_orderz!Placeholder.get_plugin_tree_order}  sP     X&--Y-?HHT``aelp`q 	 %&&r1   c           
           fd} j                   rt        d      sg S t               }t        | j                        } ||      D ]  \  }}|s	|j                  ||       }|st        |t              r3|j                         |vsB|j                  |j                                b	 t        |      D ]4  }|j                         |vs|j                  |j                                6  t%        t'        |            S # t        $ rG t        j                  d|j                  j                  |j                   t#        |      dz         Y 
w xY w)z1
        Returns a list of VARY headers.
        c              3      K   t        d      r(j                  D ]  }|j                         }||f  yj                  |       D ]  }|j	                           yw)z9See note in get_cache_expiration.inner_plugin_iterator().r   Nr   r   s       r2   r   z<Placeholder.get_vary_cache_on.<locals>.inner_plugin_iterator  sk     t12 $ 7 7 +H%??AF"F**+ $(#3#3D#9 <K%99;;<r   r   zgPlugin %(plugin_class)s (%(pk)d) returned unexpected value %(value)s for get_vary_cache_on(), ignoring.r   )r   r   r   r   r   get_vary_cache_onrS   rV   lowerro   iterr   r   r   r=   r+   r>   r   sortedr   )	r7   r   r   	vary_listrG   r   ru   vary_onvary_on_items	   `        r2   r   zPlaceholder.get_vary_cache_on  s6   
	< %%_^-LIE	,Wdii@ 5h ? 	Hf..w$GG'3'==?)3MM'--/2(,W @'--/y@%MM,*<*<*>?@	6 d9o&& ! 
MM9 -3,<,<,E,E"*++%.w%7	
s   + D!DAEEc                 H    ddl m}  || j                  |      |||      }|S )Nr   )copy_plugins_to_placeholder)rt   placeholderrG   root_plugin)cms.utils.pluginsr   r   )r7   r   rG   r   r   new_pluginss         r2   copy_pluginszPlaceholder.copy_plugins  s.    A1))(3*#	
 r1   c                 6   | j                  |j                        xs d}|j                  |z
  dk  }|r8| j                  |j                  |j                  ||j                  z
  dz          |j	                          |r| j                  |j                         |S )a  
        .. versionadded:: 4.0

        Adds a plugin to the placeholder. The plugin's position field must be set to the target
        position. Positions are enumerated from the start of the palceholder's plugin tree (1) to
        the last plugin (*n*, where *n* is the number of plugins in the placeholder).

        :param instance: Plugin to add. It's position parameter needs to be set.
        :type instance: :class:`cms.models.pluginmodel.CMSPlugin` instance

        .. note::
            As of version 4 of django CMS the position counter does not re-start at 1 for the first
            child plugin. The ``position`` field  and ``language`` field are unique for a placeholder.

        Example::

            new_child = MyCoolPlugin()
            new_child.position = (
                parent_plugin.position + 1
            )  # add as first child: directly after parent
            parent_plugin.placeholder.add(new_child)

        r      r   startoffset)get_last_plugin_positionrG   r   _shift_plugin_positionssave_recalculate_plugin_positions)r7   r   last_positionneeds_shifts       r2   
add_pluginzPlaceholder.add_plugin  s    0 55h6G6GHMA  ((=8A=((!!''$x'8'881< )  	 ..x/@/@Ar1   c                    |r| j                  ||||      S | j                  |j                        }| j                  |j                        }|j	                         }|j
                  |j
                  |z   f}||j
                  k  r|j                  |      j                  |      j                  t        j                  d      |j
                  z          |j                  |d         j                  t        j                  d      |j
                  z
         n|j                  ||z         j                  |      j                  t        j                  d      |j
                  z
         |j                  |j
                        j                  t        j                  d      |j
                  z          |j                  |k7  r|j                  |       | j                  |j                         y	)
a  
        .. versionadded:: 4.0

        Moves a plugin within the placeholder (``target_placeholder=None``) or to another placeholder.

        :param plugin: Plugin to move
        :type plugin: :class:`cms.models.pluginmodel.CMSPlugin` instance
        :param int target_position: The plugin's new position
        :param  target_placeholder: Placeholder to move plugin to (or ``None``)
        :type target_placeholder: :class:`cms.models.placeholdermodel.Placeholder` instance
        :param target_plugin: New parent plugin (or ``None``). The target plugin must be in the same placeholder
           or in the ``target_placeholder`` if one is given.
        :type target_plugin: :class:`cms.models.pluginmodel.CMSPlugin` instance

        The ``target_position`` is enumerated from the start of the palceholder's plugin tree (1) to
        the last plugin (*n*, where *n* is the number of plugins in the placeholder).
        )ru   target_positionr   target_pluginposition__gte)position__ranger   r   r  )position__lter   N)_move_plugin_to_placeholderrD   rG   get_last_plugin_get_descendants_countr   r   r   updater   Fr   r	  )	r7   ru   r  r   r  target_treelast_pluginsource_plugin_desc_countsource_plugin_ranges	            r2   move_pluginzPlaceholder.move_plugin  s   & 33 /#5+	 4   &&v7**6??;#)#@#@#B %BZ0Z[V__,
 o>FFWjFkss ((:.1E1EE t  -@-CDKK*-0D0DD L  ""C[1["\dd$7 e  fvxx
3k6J6JJfL
 V__=DD*-0D0DD E  ==M) MMM/ 	**6??;r1   c                    | j                  |j                        }|j                  |j                        }|j                         }|r|j                  }|j                  }	dt	        |      z   }
t        ||	|
z         |j                  z
  dz   }t        |	|z
  dz   |j                  |z   |z
  |
z   dz         }|j                  |j                  ||       n|j                  }| j                  |j                  |j                  |       |j                  ||       |j                  |       | j                  |j                         |j                  |j                         y )Nr  r  )r   r   )r   )	r  rG   get_descendantsr   lenmaxr  r  r	  )r7   ru   r  r   r  source_last_plugintarget_last_pluginplugin_descendantssource_lengthtarget_lengthplugins_to_move_countsource_offsettarget_offsets                r2   r  z'Placeholder._move_plugin_to_placeholder=  sl   !11&//B/??P#335.77M.77M$%,>(?$?! !!$99	 //"    /!3-//ADYY\]]	M 66%$ 7  /77M 	$$OO//  	% 	
 	]8JK!!.@!A**6??;88Ir1   c                    t        j                         5  | j                  |j                        j	                         }|j                         }|j                  g|z   }| j                  j                  |      j                          |j                  t        |      z   }||k  rC| j                  |j                  |j                  |       | j                  |j                         ddd       y# 1 sw Y   yxY w)a  
        .. versionadded:: 4.0

        Removes a plugin and its descendants from the placeholder and database.

        :param instance: Plugin to add. It's position parameter needs to be set.
        :type instance: :class:`cms.models.pluginmodel.CMSPlugin` instance
        r   )pk__inr  N)r	   atomicrD   rG   count_get_descendants_idsr>   r   r   rE   r   r!  r  r	  )r7   r   rt   descendants	to_deleter
  s         r2   delete_pluginzPlaceholder.delete_plugins  s     ! 	F&&0A0A&BHHJG"779K!3I%%Y%7>>@$--K0@@Mw&,,%%"++" - 
 2283D3DE	F 	F 	Fs   CC33C<c                 @    | j                  |      j                         S r5   )rD   lastrF   s     r2   r  zPlaceholder.get_last_plugin  s    )..00r1   c                     |dk(  r| j                  ||      }n| j                  ||      }|r||j                  dz   S |dk(  r	|xs ddz   S |xs dS )a  
        .. versionadded:: 4.0

        Helper to calculate plugin positions correctly.

        :param str language: language for which the position is to be calculated
        :param parent: Parent plugin or ``None`` (if position is on top level)
        :type parent: :class:`cms.models.pluginmodel.CMSPlugin` instance
        :param str insert_order: Either ``"first"`` (default) or ``"last"``
        r   r   r  r4  r   )get_first_plugin_positionr  r   )r7   rG   r   insert_orderr   s        r2   get_next_plugin_positionz$Placeholder.get_next_plugin_position  sn     7"55hv5NH44Xf4MHh&??Q&&6!MQ&&}1r1   c                     | j                  |      }|r|j                  |      }|j                  dd      j                         S )Nr   r   Tr   )rD   r   r   r   r7   rG   r   trees       r2   r6  z%Placeholder.get_first_plugin_position  sD    );;f;-D
6<<>>r1   c                     || j                  |      }n!|j                  | k(  r|j                         }ny |j                  dd      j	                         S )Nr   Tr   )rD   r   r   r   r4  r:  s       r2   r  z$Placeholder.get_last_plugin_position  sU    >##H-D4'))+D
6;;==r1   c                     || j                  |      xs d}| j                  |      j                  |      j                  t	        j
                  d      |z          y )Nr   r  r   r  )r  rD   r   r  r   r  )r7   rG   r  r  s       r2   r  z#Placeholder._shift_plugin_positions  sV    >228<AF")))>EEvxxXbOcflOlEmr1   c                    ddl m}m}m}  |d      } |d      }|dv rcd}|j	                  t
        j                  j                  |j                  j                              }|j                  || j                  |g       y
|dk(  rcd}|j	                  t
        j                  j                  |j                  j                              }|j                  || j                  |g       y
|dk(  rcd}|j	                  t
        j                  j                  |j                  j                              }|j                  || j                  |g       y
t        t
        j                   d	      )a@  Closes gaps in the plugin tree by re-calculating the positions of all plugins.
        IMPORTANT: This method requires any gap to be large enough to be able to
        contain all missing plugin positions. Ensure to have shifted out plugins after the
        gaps far enough using the ``_shift_plugin_positions`` method.r   )	CMSPlugin_get_database_cursor_get_database_vendorwrite)sqlite
postgresqlzUPDATE {0} SET position = subquery.new_pos FROM (  SELECT  ID, ROW_NUMBER() OVER (ORDER BY position, id) AS new_pos   FROM {0} WHERE placeholder_id=%s AND language=%s ) subquery WHERE {0}.id=subquery.idmysqlzUPDATE {0} SET position = (SELECT COUNT(*)+1 FROM (SELECT * FROM {0}) t WHERE placeholder_id={0}.placeholder_id AND language={0}.language AND {0}.position > t.position) WHERE placeholder_id=%s AND language=%soraclez is not supported by django-cmsN)cms.models.pluginmodelr?  r@  rA  formatr   ops
quote_namer   db_tableexecuter>   RuntimeErrorvendor)r7   rG   r?  r@  rA  cursor	db_vendorsqls           r2   r	  z)Placeholder._recalculate_plugin_positions  s3   	
 	
 &g.(1	00+  **Z^^66y7O7OPQCNN3( 34'!<  **Z^^66y7O7OPQCNN3( 34("<  **Z^^66y7O7OPQCNN3( 34*"3"3!44STUUr1   r5   )NN)Nr   )Br+   r,   r-   __doc__r   	CharFieldrW   r   PositiveSmallIntegerFielddefault_width
ForeignKeyr   SET_NULLr%   PositiveIntegerFieldr&   r   rT   r   	is_staticis_editabler   objectsr3   r8   rB   rH   rX   r[   r`   rm   rr   rv   rz   r}   r   r   r   r   r   r   r   r   propertyr   r   rD   r   r   r   r   r   r   r   r   r   r  r  r  r2  r  r8  r6  r  r  r	  r0   r1   r2   r   r      s    6AfI#uUD4F44QwZdUZ[M$6$$//	L ,++$TBI~{;FIK "GE E
,
N
B
Y&	
		C*a
3
	
 K-D0
(3 3 
% 
%]~F'/'b	+ZK<Z4JlF41.?>n2Vr1   r   )+r   r   r   "django.contrib.contenttypes.fieldsr   "django.contrib.contenttypes.modelsr   	django.dbr   r   r	   django.template.defaultfiltersr
   django.utils.encodingr   django.utils.functionalr   django.utils.translationr   rW   	cms.cacher   cms.cache.placeholderr   cms.constantsr   r   cms.exceptionsr   cms.models.managersr   	cms.utilsr   r   cms.utils.compat.warningsr   cms.utils.confr   r   cms.utils.i18nr   Modelr   r0   r1   r2   <module>rn     sR     ( @ : 5 5 0 + ( 6 / 9 8 ( 2 < A 7 .XV&,, XVr1   