{"action":"created","issue":{"url":"https://api.github.com/repos/joomla/joomla-cms/issues/14446","repository_url":"https://api.github.com/repos/joomla/joomla-cms","labels_url":"https://api.github.com/repos/joomla/joomla-cms/issues/14446/labels{/name}","comments_url":"https://api.github.com/repos/joomla/joomla-cms/issues/14446/comments","events_url":"https://api.github.com/repos/joomla/joomla-cms/issues/14446/events","html_url":"https://github.com/joomla/joomla-cms/pull/14446","id":213276900,"number":14446,"title":"Mod Latest Articles - Admin","user":{"login":"brianteeman","id":1296369,"avatar_url":"https://avatars0.githubusercontent.com/u/1296369?v=3","gravatar_id":"","url":"https://api.github.com/users/brianteeman","html_url":"https://github.com/brianteeman","followers_url":"https://api.github.com/users/brianteeman/followers","following_url":"https://api.github.com/users/brianteeman/following{/other_user}","gists_url":"https://api.github.com/users/brianteeman/gists{/gist_id}","starred_url":"https://api.github.com/users/brianteeman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brianteeman/subscriptions","organizations_url":"https://api.github.com/users/brianteeman/orgs","repos_url":"https://api.github.com/users/brianteeman/repos","events_url":"https://api.github.com/users/brianteeman/events{/privacy}","received_events_url":"https://api.github.com/users/brianteeman/received_events","type":"User","site_admin":false},"labels":[{"id":60721348,"url":"https://api.github.com/repos/joomla/joomla-cms/labels/PR-staging","name":"PR-staging","color":"c7def8","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2017-03-10T08:35:10Z","updated_at":"2017-03-11T12:58:43Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/joomla/joomla-cms/pulls/14446","html_url":"https://github.com/joomla/joomla-cms/pull/14446","diff_url":"https://github.com/joomla/joomla-cms/pull/14446.diff","patch_url":"https://github.com/joomla/joomla-cms/pull/14446.patch"},"body":"the admin module mod_latest displays a list of the most rrecent articles added to the site but it only shows if the article is published or not. It doesnt display if the article is pending or expired.\r\n\r\nthis PR resolves that and the module will now correctly display if the article is\r\npublished, unpublished, pending or expired\r\n\r\n### Test Instructions\r\nCreate 4 articles\r\n1. Published\r\n2. Unpublished\r\n3. Published but Pending (published in the future)\r\n4. Published but Expired (published but now after the end date)\r\n\r\nBefore the PR the admin module on the control panel will just display published/unpublished\r\n\r\nAfter the PR the admin module will display the correct icons (the ones you see in the article manager)\r\n\r\n### Before\r\n\r\n<img width=\"465\" alt=\"screenshotr09-58-43\" src=\"https://cloud.githubusercontent.com/assets/1296369/23790778/78505f62-0578-11e7-8426-6285aed65bfb.png\">\r\n\r\n### After\r\n\r\n<img width=\"494\" alt=\"screenshotr10-00-05\" src=\"https://cloud.githubusercontent.com/assets/1296369/23790773/74e00738-0578-11e7-9c16-4693eed3e1b6.png\">\r\n"},"comment":{"url":"https://api.github.com/repos/joomla/joomla-cms/issues/comments/285865109","html_url":"https://github.com/joomla/joomla-cms/pull/14446#issuecomment-285865109","issue_url":"https://api.github.com/repos/joomla/joomla-cms/issues/14446","id":285865109,"user":{"login":"joomdonation","id":977664,"avatar_url":"https://avatars1.githubusercontent.com/u/977664?v=3","gravatar_id":"","url":"https://api.github.com/users/joomdonation","html_url":"https://github.com/joomdonation","followers_url":"https://api.github.com/users/joomdonation/followers","following_url":"https://api.github.com/users/joomdonation/following{/other_user}","gists_url":"https://api.github.com/users/joomdonation/gists{/gist_id}","starred_url":"https://api.github.com/users/joomdonation/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joomdonation/subscriptions","organizations_url":"https://api.github.com/users/joomdonation/orgs","repos_url":"https://api.github.com/users/joomdonation/repos","events_url":"https://api.github.com/users/joomdonation/events{/privacy}","received_events_url":"https://api.github.com/users/joomdonation/received_events","type":"User","site_admin":false},"created_at":"2017-03-11T12:58:43Z","updated_at":"2017-03-11T12:58:43Z","body":"@brianteeman I can see the error, too, both from testing and reading the code as @wilsonge described . Just change the code from:\r\n\r\n```php\r\n<?php echo JHtml::_('jgrid.published', $item->state, $i, 'articles.', $canChange, 'cb', $item->publish_up, $item->publish_down); ?>\r\n```\r\nTo:\r\n```php\r\n<?php echo JHtml::_('jgrid.published', $item->state, $i, 'articles.', false, 'cb', $item->publish_up, $item->publish_down); ?>\r\n```\r\nand it should be OK. Please don't add an unnecessary command **$canChange = false;**\r\n\r\n\r\n"}}
{"actor":{"display_login":"joomdonation"}}