Plugin Directory

Changeset 1447443


Ignore:
Timestamp:
07/01/2016 08:23:48 PM (10 years ago)
Author:
farne
Message:

New version 1.2.7. Better category and tag handling

Location:
post-status-scheduler/trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • post-status-scheduler/trunk/classes/scheduler.php

    r1038771 r1447443  
    537537
    538538
    539         // Categories
     539        // Categories and tags
    540540        if( count( $categories ) > 0 ) {
    541541
    542           echo '<input type="checkbox" name="scheduler[category-check]" id="scheduler-category" ' . $scheduler_check_category_checked . ' /> ' . __( 'Change categories', 'post-status-scheduler' ) . '<br />'
     542          echo '<input type="checkbox" name="scheduler[category-check]" id="scheduler-category" ' . $scheduler_check_category_checked . ' /> ' . __( 'Change categories and tags', 'post-status-scheduler' ) . '<br />'
    543543          .'<div id="scheduler-category-box" ' . $scheduler_check_category_show . '>';
    544544          echo __( 'The post will have the following categories on scheduled time', POST_STATUS_SCHEDULER_TEXTDOMAIN );
     
    569569          }
    570570
     571          // Get the options set for categories and tags
     572          $categories_and_tags = !empty( $this->options['categories_and_tags'] ) ? $this->options['categories_and_tags'] : 'both';
     573
    571574          // Loop categories and check if selected
    572           foreach( $categories as $category ) {
    573 
    574             if( is_array( $event->category ) ) {
    575 
    576               $selected = in_array( $category->term_id.'_'.$category->taxonomy, $event->category ) ? ' selected="selected" ' : '';
    577            
    578             } else {
    579 
    580               $selected = in_array( $category->term_id.'_'.$category->taxonomy, $post_categories ) ? ' selected="selected" ' : '';
     575          if( $categories_and_tags == 'both' || $categories_and_tags == 'categories' ) {
     576            echo sprintf( '<optgroup label="%s">', __('Categories', 'post-status-scheduler'));
     577            foreach ($categories['categories'] as $category) {
     578
     579              if (is_array($event->category)) {
     580
     581                $selected = in_array($category->term_id . '_' . $category->taxonomy, $event->category) ? ' selected="selected" ' : '';
     582
     583              } else {
     584
     585                $selected = in_array($category->term_id . '_' . $category->taxonomy, $post_categories) ? ' selected="selected" ' : '';
     586
     587              }
     588
     589              echo sprintf('<option value="%s"%s>%s</option>', $category->term_id . '_' . $category->taxonomy, $selected, $category->name);
    581590
    582591            }
    583 
    584             echo sprintf( '<option value="%s"%s>%s</option>', $category->term_id.'_'.$category->taxonomy, $selected, $category->name );
    585 
     592            echo '</optgroup>';
     593
     594          }
     595
     596
     597          if( $categories_and_tags == 'both' || $categories_and_tags == 'tags' ) {
     598            echo sprintf( '<optgroup label="%s">', __('Tags', 'post-status-scheduler'));
     599            foreach ($categories['tags'] as $category) {
     600
     601              if (is_array($event->category)) {
     602
     603                $selected = in_array($category->term_id . '_' . $category->taxonomy, $event->category) ? ' selected="selected" ' : '';
     604
     605              } else {
     606
     607                $selected = in_array($category->term_id . '_' . $category->taxonomy, $post_categories) ? ' selected="selected" ' : '';
     608
     609              }
     610
     611              echo sprintf('<option value="%s"%s>%s</option>', $category->term_id . '_' . $category->taxonomy, $selected, $category->name);
     612
     613            }
     614            echo '</optgroup>';
    586615          }
    587616
  • post-status-scheduler/trunk/classes/settings.php

    r1025691 r1447443  
    110110      );
    111111
     112      add_settings_field(
     113        'categories_and_tags', // ID
     114        __('Enable showing of both categories and tags or just one of them', 'post-status-scheduler'), // Title
     115        array( $this, 'categories_and_tags_callback' ), // Callback
     116        'post-status-scheduler', // Page
     117        'posttypes' // Section
     118      );
     119
    112120
    113121      /* SECTION NOTIFICATION EMAIL */
     
    185193      }
    186194
     195      if( isset( $input['categories_and_tags'] ) ) {
     196
     197        $new_input['categories_and_tags'] = $input['categories_and_tags'];
     198
     199      }
     200
    187201      if( isset( $input['notification_email_enabled'] ) ) {
    188202
    189203        $new_input['notification_email_enabled'] = true;
    190204
    191       } else {
    192 
    193         $new_input['notification_email_enabled'] = false;       
    194 
    195205      }
    196206
     
    198208
    199209        $new_input['extra_column_enabled'] = true;
    200 
    201       } else {
    202 
    203         $new_input['extra_column_enabled'] = false;       
    204210
    205211      }
     
    319325
    320326
     327    public function categories_and_tags_callback() {
     328      $options = self::get_options();
     329      $enabled = !empty( $options['categories_and_tags'] ) ? $options['categories_and_tags'] : 'both';
     330      ?>
     331
     332
     333
     334      <input type="radio" id="categories_and_tags_both" name="post_status_scheduler[categories_and_tags]" value="both" <?php checked( $enabled, 'both' ); ?> />
     335      <label for="categories_and_tags_both"><?php _e( 'Both', 'post-status-scheduler' ); ?></label><br />
     336
     337      <input type="radio" id="categories_and_tags_categories" name="post_status_scheduler[categories_and_tags]" value="categories" <?php checked( $enabled, 'categories' ); ?> />
     338      <label for="categories_and_tags_categories"><?php _e( 'Categories', 'post-status-scheduler' ); ?></label><br />
     339
     340      <input type="radio" id="categories_and_tags_tags" name="post_status_scheduler[categories_and_tags]" value="tags" <?php checked( $enabled, 'tags' ); ?> />
     341      <label for="categories_and_tags_tags"><?php _e( 'Tags', 'post-status-scheduler' ); ?></label>
     342      <?php
     343    }
     344
     345
    321346    /**
    322347     * notification_email_enabled_callback
     
    327352
    328353      $options = self::get_options();
    329       $enabled = !empty( $options['notification_email_enabled'] ) ? $options['notification_email_enabled'] : '';
     354      $enabled = !empty( $options['notification_email_enabled'] ) && $options['notification_email_enabled'] == true ? $options['notification_email_enabled'] : false;
    330355      ?>
    331356
     
    344369
    345370      $options = self::get_options();
    346       $enabled = !empty( $options['extra_column_enabled'] ) ? $options['extra_column_enabled'] : '';
     371      $enabled = !empty( $options['extra_column_enabled'] ) && $options['extra_column_enabled'] == true ? $options['extra_column_enabled'] : false;
    347372      ?>
    348373
  • post-status-scheduler/trunk/classes/taxonomy.php

    r960367 r1447443  
    9999     
    100100      $all_taxonomies = self::enum( $post_id );
     101            $options = Settings::get_options();
     102            $categories_and_tags = !empty( $options['categories_and_tags'] ) ? $options['categories_and_tags'] : 'both';
    101103
    102104      // Loop all taxonomies and reset terms
    103105      if( count( $all_taxonomies ) > 0 ) {
    104106        foreach( $all_taxonomies as $taxonomy ) {
    105          
    106             self::set_terms( $post_id, '', $taxonomy );
     107
     108                    // We need to check what types of terms to remove
     109                    if( $categories_and_tags == 'both' ) {
     110
     111                        self::set_terms( $post_id, '', $taxonomy );
     112
     113                    } elseif( $categories_and_tags == 'tags' ) {
     114
     115                        if( ! is_taxonomy_hierarchical( $taxonomy ) ) {
     116                            self::set_terms( $post_id, '', $taxonomy );
     117                        }
     118
     119                    } elseif( $categories_and_tags == 'categories' ) {
     120
     121                        if( is_taxonomy_hierarchical( $taxonomy ) ) {
     122                            self::set_terms( $post_id, '', $taxonomy );
     123                        }
     124
     125                    }
    107126
    108127        }
     
    121140     */
    122141    public static function get_posttype_terms( $post_type ) {
    123 
    124       $taxonomies = get_object_taxonomies( $post_type );
    125 
     142      $all_taxonomies = get_object_taxonomies( $post_type );
     143            $tag_taxonomies = array();
     144            $cat_taxonomies = array();
     145
     146            if( count($all_taxonomies) > 0 ) {
     147                foreach( $all_taxonomies as $taxonomy ) {
     148                    if( ! is_taxonomy_hierarchical($taxonomy) ) {
     149                        $tag_taxonomies []= $taxonomy;
     150                    } else {
     151                        $cat_taxonomies []= $taxonomy;
     152                    }
     153                }
     154            }
     155
     156            // Get categories
    126157      $args = array(
    127158        'type'                     => $post_type,
     
    129160        'order'                    => 'ASC',
    130161        'hide_empty'               => false,
    131         'taxonomy'                 => $taxonomies,
     162        'taxonomy'                 => $cat_taxonomies
    132163      );
    133 
    134164      $tmp_categories = get_categories( $args );
    135165      $categories = array();
     
    141171            }
    142172
    143       return $categories;
     173            // Get categories
     174            $args = array(
     175                'type'                     => $post_type,
     176                'orderby'                  => 'name',
     177                'order'                    => 'ASC',
     178                'hide_empty'               => false,
     179                'taxonomy'                 => $tag_taxonomies
     180            );
     181            $tmp_tags = get_categories( $args );
     182            $tags = array();
     183
     184            foreach( $tmp_tags as $tag ) {
     185                if ($tag->cat_name != 'uncategorized') {
     186                    array_push( $tags, $tag );
     187                }
     188            }
     189
     190      return array(
     191                'categories'    => $categories,
     192                'tags'              => $tags
     193            );
    144194
    145195    }
     
    159209
    160210      $result = array();
    161      
     211
    162212      if( count( $chosen_terms ) > 0 ) {
    163213
    164214        foreach( $chosen_terms as $term ) {
    165215
    166           foreach( $all_terms as $object ) {
     216          foreach( $all_terms['categories'] as $object ) {
    167217
    168218            if( $term->term_id == $object->term_id ) {
     
    174224          }
    175225
     226                    foreach( $all_terms['tags'] as $object ) {
     227
     228                        if( $term->term_id == $object->term_id ) {
     229
     230                            $result []= $term->term_id . '_' . $object->taxonomy;
     231
     232                        }
     233
     234                    }
     235
    176236        }
    177237
  • post-status-scheduler/trunk/languages/post-status-scheduler-sv_SE.pot

    r1013039 r1447443  
    22msgstr ""
    33"Project-Id-Version: post-status-scheduler\n"
    4 "POT-Creation-Date: 2014-10-23 15:58+0100\n"
    5 "PO-Revision-Date: 2014-10-23 16:00+0100\n"
     4"POT-Creation-Date: 2016-07-01 21:50+0200\n"
     5"PO-Revision-Date: 2016-07-01 21:55+0200\n"
    66"Last-Translator: Andeas Färnstrand <andreas@farnstranddev.se>\n"
    7 "Language-Team:  <andreas@farnstranddev.se>\n"
    8 "Language: English\n"
     7"Language-Team: andreas@farnstranddev.se\n"
     8"Language: sv\n"
    99"MIME-Version: 1.0\n"
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "X-Generator: Poedit 1.5.4\n"
     12"X-Generator: Poedit 1.8.8\n"
    1313"X-Poedit-KeywordsList: __;_e\n"
    14 "X-Poedit-Basepath: ../\n"
     14"X-Poedit-Basepath: ..\n"
    1515"X-Poedit-SearchPath-0: .\n"
    1616
     
    3131msgstr "Hälsningar"
    3232
    33 #: classes/scheduler.php:503
     33#: classes/scheduler.php:517
    3434msgid "Schedule Status Change"
    3535msgstr "Schemalägg statusändring"
    3636
    37 #: classes/scheduler.php:505
     37#: classes/scheduler.php:519
    3838msgid "Date"
    3939msgstr "Datum"
    4040
    41 #: classes/scheduler.php:507
     41#: classes/scheduler.php:521
    4242msgid "Time"
    4343msgstr "Tid"
    4444
    45 #: classes/scheduler.php:511
     45#: classes/scheduler.php:525
    4646msgid "Change status"
    4747msgstr "Ändra status"
    4848
    49 #: classes/scheduler.php:513
     49#: classes/scheduler.php:527
    5050msgid "Set status to"
    5151msgstr "Ändra status till"
    5252
    53 #: classes/scheduler.php:528
    54 msgid "Change categories"
    55 msgstr "Ändra kategorier"
     53#: classes/scheduler.php:542
     54msgid "Change categories and tags"
     55msgstr "Ändra kategorier och taggar"
    5656
    57 #: classes/scheduler.php:530
     57#: classes/scheduler.php:544
    5858msgid "The post will have the following categories on scheduled time"
    5959msgstr "Följande kategorier kommer att sättas vid schemalagd tid"
    6060
    61 #: classes/scheduler.php:580
     61#: classes/scheduler.php:576 classes/settings.php:338
     62msgid "Categories"
     63msgstr "Kategorier"
     64
     65#: classes/scheduler.php:598 classes/settings.php:341
     66msgid "Tags"
     67msgstr "Taggar"
     68
     69#: classes/scheduler.php:623
    6270msgid "Remove postmeta"
    6371msgstr "Ta bort postmeta"
    6472
    65 #: classes/scheduler.php:608
     73#: classes/scheduler.php:651
    6674msgid "Send email notification on change"
    6775msgstr "Skicka epostnotifiering vid ändring"
    6876
    69 #: classes/scheduler.php:633
     77#: classes/scheduler.php:676
    7078msgid "Scheduled date"
    7179msgstr "Schemalagt datum"
    7280
    73 #: classes/scheduler.php:839
     81#: classes/scheduler.php:882
    7482msgid "Draft"
    7583msgstr "Utkast"
    7684
    77 #: classes/scheduler.php:840
     85#: classes/scheduler.php:883
    7886msgid "Pending"
    7987msgstr "Väntar på granskning"
    8088
    81 #: classes/scheduler.php:841
     89#: classes/scheduler.php:884
    8290msgid "Private"
    8391msgstr "Privat"
    8492
    85 #: classes/scheduler.php:842
     93#: classes/scheduler.php:885
    8694msgid "Trashbin"
    8795msgstr "Papperskorg"
    8896
    89 #: classes/scheduler.php:843
     97#: classes/scheduler.php:886
    9098msgid "Delete (forced)"
    9199msgstr "Radera (tvingad)"
     
    107115msgstr "Märk de metafält som skall vara valbara för borttagning"
    108116
    109 #: classes/settings.php:119
     117#: classes/settings.php:114
     118msgid "Enable showing of both categories and tags or just one of them"
     119msgstr "Aktivera visning av både kategorier och taggar eller bara en av dem"
     120
     121#: classes/settings.php:125
    110122msgid "Notification"
    111123msgstr "Notifikation"
    112124
    113 #: classes/settings.php:126
     125#: classes/settings.php:132
    114126msgid "Enable email notification option"
    115127msgstr "Aktivera epostnotifiering"
    116128
    117 #: classes/settings.php:190
     129#: classes/settings.php:143
     130msgid "Extra column"
     131msgstr "Extra kolumn"
     132
     133#: classes/settings.php:150
     134msgid "Enable extra column on posttype edit page"
     135msgstr "Aktivera extrakolumn på posttypens listsida"
     136
     137#: classes/settings.php:223
    118138msgid "Enter your settings below:"
    119139msgstr "Ange inställningar nedan:"
    120140
    121 #: classes/settings.php:199
    122 msgid "Email notification settings:"
    123 msgstr "Inställningar för epostnotifiering"
     141#: classes/settings.php:233
     142msgid ""
     143"Enabling this option makes it possible to send an email notification to the "
     144"post author on a scheduled change execution."
     145msgstr ""
     146"Aktivering av detta alternativ gör det möjligt att skicka en "
     147"epostnotifiering till inläggsförfattaren när en schemalagd ändring "
     148"inträffar."
     149
     150#: classes/settings.php:243
     151msgid ""
     152"Settings for adding extra column \"Scheduled date\" on edit page. This "
     153"column will only be displayed on posttypes that are allowed for scheduling"
     154msgstr ""
     155"Inställningar för att lägga till en extrakolumn \"Schemalagt datum\" på "
     156"listsida. Kolumnen visas bara på posttyper som är tillåtna för "
     157"schemaläggning"
     158
     159#: classes/settings.php:335
     160msgid "Both"
     161msgstr "Bägge"
     162
     163#~ msgid "Change categories"
     164#~ msgstr "Ändra kategorier"
     165
     166#~ msgid "Email notification settings:"
     167#~ msgstr "Inställningar för epostnotifiering"
    124168
    125169#~ msgid "Post Types"
  • post-status-scheduler/trunk/languages/post-status-scheduler.pot

    r1013039 r1447443  
    22msgstr ""
    33"Project-Id-Version: post-status-scheduler\n"
    4 "POT-Creation-Date: 2014-10-23 15:50+0100\n"
    5 "PO-Revision-Date: 2014-10-23 15:51+0100\n"
     4"POT-Creation-Date: 2016-07-01 21:55+0200\n"
     5"PO-Revision-Date: 2016-07-01 21:56+0200\n"
    66"Last-Translator: Andeas Färnstrand <andreas@farnstranddev.se>\n"
    7 "Language-Team:  <andreas@farnstranddev.se>\n"
    8 "Language: English\n"
     7"Language-Team: andreas@farnstranddev.se\n"
     8"Language: en\n"
    99"MIME-Version: 1.0\n"
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "X-Generator: Poedit 1.5.4\n"
     12"X-Generator: Poedit 1.8.8\n"
    1313"X-Poedit-KeywordsList: __;_e\n"
    14 "X-Poedit-Basepath: ../\n"
     14"X-Poedit-Basepath: ..\n"
    1515"X-Poedit-SearchPath-0: .\n"
    1616
    17 #: classes/scheduler.php:503
     17#: classes/email.php:25
     18msgid "Post Status Scheduler update"
     19msgstr ""
     20
     21#: classes/email.php:33
     22msgid "A scheduled update has been executed at"
     23msgstr ""
     24
     25#: classes/email.php:33
     26msgid "on your post"
     27msgstr ""
     28
     29#: classes/email.php:34
     30msgid "Regards"
     31msgstr ""
     32
     33#: classes/scheduler.php:517
    1834msgid "Schedule Status Change"
    1935msgstr ""
    2036
    21 #: classes/scheduler.php:505
     37#: classes/scheduler.php:519
    2238msgid "Date"
    2339msgstr ""
    2440
    25 #: classes/scheduler.php:507
     41#: classes/scheduler.php:521
    2642msgid "Time"
    2743msgstr ""
    2844
    29 #: classes/scheduler.php:511
     45#: classes/scheduler.php:525
    3046msgid "Change status"
    3147msgstr ""
    3248
    33 #: classes/scheduler.php:513
     49#: classes/scheduler.php:527
    3450msgid "Set status to"
    3551msgstr ""
    3652
    37 #: classes/scheduler.php:528
    38 msgid "Change categories"
     53#: classes/scheduler.php:542
     54msgid "Change categories and tags"
    3955msgstr ""
    4056
    41 #: classes/scheduler.php:530
     57#: classes/scheduler.php:544
    4258msgid "The post will have the following categories on scheduled time"
    4359msgstr ""
    4460
    45 #: classes/scheduler.php:580
     61#: classes/scheduler.php:576 classes/settings.php:338
     62msgid "Categories"
     63msgstr ""
     64
     65#: classes/scheduler.php:598 classes/settings.php:341
     66msgid "Tags"
     67msgstr ""
     68
     69#: classes/scheduler.php:623
    4670msgid "Remove postmeta"
    4771msgstr ""
    4872
    49 #: classes/scheduler.php:608
     73#: classes/scheduler.php:651
    5074msgid "Send email notification on change"
    5175msgstr ""
    5276
    53 #: classes/scheduler.php:633
     77#: classes/scheduler.php:676
    5478msgid "Scheduled date"
    5579msgstr ""
    5680
    57 #: classes/scheduler.php:839
     81#: classes/scheduler.php:882
    5882msgid "Draft"
    5983msgstr ""
    6084
    61 #: classes/scheduler.php:840
     85#: classes/scheduler.php:883
    6286msgid "Pending"
    6387msgstr ""
    6488
    65 #: classes/scheduler.php:841
     89#: classes/scheduler.php:884
    6690msgid "Private"
    6791msgstr ""
    6892
    69 #: classes/scheduler.php:842
     93#: classes/scheduler.php:885
    7094msgid "Trashbin"
    7195msgstr ""
    7296
    73 #: classes/scheduler.php:843
     97#: classes/scheduler.php:886
    7498msgid "Delete (forced)"
    7599msgstr ""
     
    91115msgstr ""
    92116
    93 #: classes/settings.php:119
     117#: classes/settings.php:114
     118msgid "Enable showing of both categories and tags or just one of them"
     119msgstr ""
     120
     121#: classes/settings.php:125
    94122msgid "Notification"
    95123msgstr ""
    96124
    97 #: classes/settings.php:126
     125#: classes/settings.php:132
    98126msgid "Enable email notification option"
    99127msgstr ""
    100128
    101 #: classes/settings.php:190
     129#: classes/settings.php:143
     130msgid "Extra column"
     131msgstr ""
     132
     133#: classes/settings.php:150
     134msgid "Enable extra column on posttype edit page"
     135msgstr ""
     136
     137#: classes/settings.php:223
    102138msgid "Enter your settings below:"
    103139msgstr ""
    104140
    105 #: classes/settings.php:199
    106 msgid "Email notification settings:"
     141#: classes/settings.php:233
     142msgid ""
     143"Enabling this option makes it possible to send an email notification to the "
     144"post author on a scheduled change execution."
    107145msgstr ""
     146
     147#: classes/settings.php:243
     148msgid ""
     149"Settings for adding extra column \"Scheduled date\" on edit page. This "
     150"column will only be displayed on posttypes that are allowed for scheduling"
     151msgstr ""
     152
     153#: classes/settings.php:335
     154msgid "Both"
     155msgstr ""
  • post-status-scheduler/trunk/post-status-scheduler.php

    r1044467 r1447443  
    4242        if( !defined( 'POST_STATUS_SCHEDULER_TEXTDOMAIN' ) )         define( 'POST_STATUS_SCHEDULER_TEXTDOMAIN', 'post-status-scheduler' );
    4343    if( !defined( 'POST_STATUS_SCHEDULER_TEXTDOMAIN_PATH' ) )    define( 'POST_STATUS_SCHEDULER_TEXTDOMAIN_PATH', dirname( plugin_basename( __FILE__) ) .'/languages' );
    44     if( !defined( 'POST_STATUS_SCHEDULER_VERSION' ) )            define( 'POST_STATUS_SCHEDULER_VERSION', '1.0.5' );
     44    if( !defined( 'POST_STATUS_SCHEDULER_VERSION' ) )            define( 'POST_STATUS_SCHEDULER_VERSION', '1.2.7' );
    4545
    4646    // Create a new scheduler instance
  • post-status-scheduler/trunk/readme.txt

    r1050129 r1447443  
    11=== Post Status Scheduler ===
    22Contributors: farne
    3 Tags: posts, categories, postmeta, poststatus, change, schedule, scheduling
     3Tags: posts, pages, categories, tags, postmeta, poststatus, change, schedule, scheduling
    44Requires at least: 3.9
    5 Tested up to: 4.1
    6 Stable tag: 1.0.5
     5Tested up to: 4.5.3
     6Stable tag: 1.2.7
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    4848= What Translations are included? =
    4949
     50* English
    5051* Swedish
    5152
    5253== Changelog ==
     54
     55= 1.2.5 =
     56* Add option on settings page to show just tags or categories when scheduling.
     57* Add optgroups for categories and tags in dropdown.
     58* Fixed bug where email and extra column option where always checked on the first save.
    5359
    5460= 1.0.5 =
     
    8591== Upgrade Notice ==
    8692
     93= 1.2.7 =
     94* It is now possible to display either both categories and tags or just one of them in the dropdown when scheduling a change.
     95* There is now optgroups in dropdown to make it easier to separate the terms.
     96
    8797= 1.0.5 =
    8898* If you have problems with picking a month in the datepicker, 1.0.5 will fix this issue. It was a problem with multiple datepickers included from other plugins on the same page. Mainly ACF it seems. The theme of the datepicker is still overridden. The functionality however is ok.
Note: See TracChangeset for help on using the changeset viewer.