Changeset 24790 for trunk/wp-admin/revision.php
- Timestamp:
- 07/24/2013 06:08:14 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/revision.php
r24763 r24790 32 32 break; 33 33 34 // Revisions disabled (previously checked autosave gs && ! wp_is_post_autosave( $revision ))34 // Revisions disabled (previously checked autosaves && ! wp_is_post_autosave( $revision )) 35 35 if ( ! wp_revisions_enabled( $post ) ) { 36 36 $redirect = 'edit.php?post_type=' . $post->post_type; … … 134 134 <div class="author-card"> 135 135 <# if ( 'undefined' !== typeof data && 'undefined' !== typeof data.author ) { #> 136 {{{ data.author.avatar }}} 137 <div class="author-info"> 138 139 <span class="byline"><?php printf( __( 'Revision by %s' ), 140 '<span class="author-name">{{ data.author.name }}</span>' ); ?></span> 141 <span class="time-ago">{{ data.timeAgo }}</span> 142 <span class="date">({{ data.dateShort }})</span> 143 </div> 136 <div class="author-card<# if ( data.autosave ) { #> autosave<# } #>"> 137 {{{ data.author.avatar }}} 138 <div class="author-info"> 139 <# if ( data.autosave ) { #> 140 <span class="byline"><?php printf( __( 'Autosave by %s' ), 141 '<span class="author-name">{{ data.author.name }}</span>' ); ?></span> 142 <# } else if ( data.current ) { #> 143 <span class="byline"><?php printf( __( 'Current Revision by %s' ), 144 '<span class="author-name">{{ data.author.name }}</span>' ); ?></span> 145 <# } else { #> 146 <span class="byline"><?php printf( __( 'Revision by %s' ), 147 '<span class="author-name">{{ data.author.name }}</span>' ); ?></span> 148 <# } #> 149 <span class="time-ago">{{ data.timeAgo }}</span> 150 <span class="date">({{ data.dateShort }})</span> 151 </div> 152 </div> 144 153 <# } #> 145 154 </div> … … 167 176 <strong><?php _ex( 'From:', 'Followed by post revision info' ); ?></strong> 168 177 <# if ( 'undefined' !== typeof data.from ) { #> 169 <div class="author-card ">178 <div class="author-card<# if ( data.from.attributes.autosave ) { #> autosave<# } #>"> 170 179 {{{ data.from.attributes.author.avatar }}} 171 180 <div class="author-info"> 181 <# if ( data.from.attributes.autosave ) { #> 182 <span class="byline"><?php printf( __( 'Autosave by %s' ), 183 '<span class="author-name">{{ data.from.attributes.author.name }}</span>' ); ?></span> 184 <# } else if ( data.from.attributes.current ) { #> 185 <span class="byline"><?php printf( __( 'Current Revision by %s' ), 186 '<span class="author-name">{{ data.from.attributes.author.name }}</span>' ); ?></span> 187 <# } else { #> 172 188 <span class="byline"><?php printf( __( 'Revision by %s' ), 173 189 '<span class="author-name">{{ data.from.attributes.author.name }}</span>' ); ?></span> 190 <# } #> 174 191 <span class="time-ago">{{ data.from.attributes.timeAgo }}</span> 175 192 <span class="date">({{ data.from.attributes.dateShort }})</span> … … 184 201 <strong><?php _ex( 'To:', 'Followed by post revision info' ); ?></strong> 185 202 <# if ( 'undefined' !== typeof data.to ) { #> 186 <div class="author-card ">203 <div class="author-card<# if ( data.to.attributes.autosave ) { #> autosave<# } #>"> 187 204 {{{ data.to.attributes.author.avatar }}} 188 205 <div class="author-info"> 206 <# if ( data.to.attributes.autosave ) { #> 207 <span class="byline"><?php printf( __( 'Autosave by %s' ), 208 '<span class="author-name">{{ data.to.attributes.author.name }}</span>' ); ?></span> 209 <# } else if ( data.to.attributes.current ) { #> 210 <span class="byline"><?php printf( __( 'Current Revision by %s' ), 211 '<span class="author-name">{{ data.to.attributes.author.name }}</span>' ); ?></span> 212 <# } else { #> 189 213 <span class="byline"><?php printf( __( 'Revision by %s' ), 190 214 '<span class="author-name">{{ data.to.attributes.author.name }}</span>' ); ?></span> 215 <# } #> 191 216 <span class="time-ago">{{ data.to.attributes.timeAgo }}</span> 192 217 <span class="date">({{ data.to.attributes.dateShort }})</span> 193 218 </div> 194 219 <# } #> 220 <# if ( data.to.attributes.restoreUrl ) { #> 195 221 <input 196 222 <# if ( data.to.attributes.current ) { #> 197 223 disabled="disabled" 198 224 <# } #> 199 type="button" class="restore-revision button button-primary" data-restore-link="{{{ data.restoreLink }}}" value="<?php esc_attr_e( 'Restore This Revision' ); ?>" /> 225 <# if ( data.to.attributes.autosave ) { #> 226 type="button" class="restore-revision button button-primary" value="<?php esc_attr_e( 'Restore This Autosave' ); ?>" /> 227 <# } else { #> 228 type="button" class="restore-revision button button-primary" value="<?php esc_attr_e( 'Restore This Revision' ); ?>" /> 229 <# } #> 230 <# } #> 200 231 </div> 201 232 </div>
Note: See TracChangeset
for help on using the changeset viewer.