• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 1.2.0
    • 1.1.0
    • None
    • 4.2 M1

      When unpublish action is applied on a content, it breaks cache. As a result, "Publish" button cannot be updated in "PRODUCTION" mode

          [FRONTEDIT-80] Unpublish action on contents break cache

          Raphaël Franchet added a comment - Doc was modified here https://docs.ametys.org/fr/ametys-v4/manuel-de-parametrage-et-d-integration/integration-graphique/definition-de-gabarit/ecriture-d-un-gabarit.html

          Pierre Gros (Inactive) added a comment - - edited

          New templates have been added in page.xsl to help add code around contents/services that needs not to be cached.

          For an example I used them directly in cms/skins/[skin]/templates/[template]/stylesheets/template.xsl but it may be better to use it in another import.

          Note that these templates are used for contents, services and wrapper, so you should always check if there is a content-id.

           

          Here are the new templates (before/after a zone and before/after a zone-item)

               <xsl:template name="zone-before">
                  <xsl:param name="count"/>
                  <xsl:param name="zone-name"/>
                  <xsl:param name="level"/>
                  <xsl:param name="inherited"/>
          
               </xsl:template>
              
               <xsl:template name="zone-after">
                  <xsl:param name="count"/>
                  <xsl:param name="zone-name"/>
                  <xsl:param name="level"/>
                  <xsl:param name="inherited"/>
          
               </xsl:template>
              
               <xsl:template name="zone-item-before">
                  <xsl:param name="position"/>
                  <xsl:param name="count"/>
                  <xsl:param name="zone-name"/>
                  <xsl:param name="level"/>
                  <xsl:param name="inherited"/>
                  <xsl:param name="id"/>
                  <xsl:param name="type"/>
                  <xsl:param name="content-id"/>
                  <xsl:param name="service"/>
                  <xsl:param name="content-type"/>
          
               </xsl:template>
          
               <xsl:template name="zone-item-after">
                  <xsl:param name="position"/>
                  <xsl:param name="count"/>
                  <xsl:param name="zone-name"/>
                  <xsl:param name="level"/>
                  <xsl:param name="inherited"/>
                  <xsl:param name="id"/>
                  <xsl:param name="type"/>
                  <xsl:param name="content-id"/>
                  <xsl:param name="service"/>
                  <xsl:param name="content-type"/>
          
               </xsl:template>
          

          Pierre Gros (Inactive) added a comment - - edited New templates have been added in page.xsl to help add code around contents/services that needs not to be cached. For an example I used them directly in cms/skins/ [skin] /templates/ [template] /stylesheets/template.xsl but it may be better to use it in another import. Note that these templates are used for contents, services and wrapper, so you should always check if there is a content-id.   Here are the new templates (before/after a zone and before/after a zone-item)      <xsl:template name= "zone-before" >         <xsl:param name= "count" />         <xsl:param name= "zone-name" />         <xsl:param name= "level" />         <xsl:param name= "inherited" />      </xsl:template>           <xsl:template name= "zone-after" >         <xsl:param name= "count" />         <xsl:param name= "zone-name" />         <xsl:param name= "level" />         <xsl:param name= "inherited" />      </xsl:template>           <xsl:template name= "zone-item-before" >         <xsl:param name= "position" />         <xsl:param name= "count" />         <xsl:param name= "zone-name" />         <xsl:param name= "level" />         <xsl:param name= "inherited" />         <xsl:param name= "id" />         <xsl:param name= "type" />         <xsl:param name= "content-id" />         <xsl:param name= "service" />         <xsl:param name= "content-type" />      </xsl:template>      <xsl:template name= "zone-item-after" >         <xsl:param name= "position" />         <xsl:param name= "count" />         <xsl:param name= "zone-name" />         <xsl:param name= "level" />         <xsl:param name= "inherited" />         <xsl:param name= "id" />         <xsl:param name= "type" />         <xsl:param name= "content-id" />         <xsl:param name= "service" />         <xsl:param name= "content-type" />      </xsl:template>

          cf FRONTEDIT-78 : if a button can change, it MUST not be in the content view as it is cached.

          The button must be in the skin.

          https://docs.ametys.org/fr/plugins/front-edition/v1/manuel-d-integration.html#N10375

          Pierre Gros (Inactive) added a comment - cf FRONTEDIT-78 : if a button can change, it MUST not be in the content view as it is cached. The button must be in the skin. https://docs.ametys.org/fr/plugins/front-edition/v1/manuel-d-integration.html#N10375

            raphael Raphaël Franchet
            dcartier David Cartier-Michaud
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: