From 4690fc2896f1d4a70bb30fb73e02da0fd79c4716 Mon Sep 17 00:00:00 2001 From: lef237 <lef237k5@gmail.com> Date: Fri, 24 Feb 2023 18:42:38 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=9A=E3=83=BC=E3=82=B8=E3=83=8D=E3=83=BC?= =?UTF-8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E3=81=AE=E6=9D=A1=E4=BB=B6=E5=88=86?= =?UTF-8?q?=E5=B2=90=E3=81=AE=E6=BC=8F=E3=82=8C=E3=82=92=E4=BF=AE=E6=AD=A3?= =?UTF-8?q?=E3=81=97=E3=81=9F=EF=BC=88show=E7=94=BB=E9=9D=A2=E3=81=A7?= =?UTF-8?q?=E3=83=9A=E3=83=BC=E3=82=B8=E3=83=8D=E3=83=BC=E3=82=B7=E3=83=A7?= =?UTF-8?q?=E3=83=B3=E3=81=8C=E8=A1=A8=E7=A4=BA=E3=81=95=E3=82=8C=E3=81=AA?= =?UTF-8?q?=E3=81=84=E3=82=88=E3=81=86=E3=81=AB=E3=81=97=E3=81=9F=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/javascript/components/Reports.jsx | 6 +++--- app/views/reports/show.html.slim | 4 ++-- app/views/talks/show.html.slim | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/javascript/components/Reports.jsx b/app/javascript/components/Reports.jsx index cd69196995b..fe8c13e63bb 100644 --- a/app/javascript/components/Reports.jsx +++ b/app/javascript/components/Reports.jsx @@ -8,7 +8,7 @@ import Pagination from './Pagination' import PracticeFilterDropdown from './PracticeFilterDropdown' import UnconfirmedLink from './UnconfirmedLink' -export default function Reports({ all = false, userId = '', practices = false, unchecked = false, displayUserIcon = true, companyId = '', practiceId = '' }) { +export default function Reports({ all = false, userId = '', practices = false, unchecked = false, displayUserIcon = true, companyId = '', practiceId = '', displayPagination = true }) { const per = 20 const neighbours = 4 const defaultPage = parseInt(queryString.parse(location.search).page) || 1 @@ -73,7 +73,7 @@ export default function Reports({ all = false, userId = '', practices = false, u /> )} <div className="page-content reports"> - {data.totalPages > 1 && ( + {data.totalPages > 1 && displayPagination && ( <Pagination sum={data.totalPages * per} per={per} @@ -99,7 +99,7 @@ export default function Reports({ all = false, userId = '', practices = false, u {unchecked && ( <UnconfirmedLink label={'未チェックの日報を一括で開く'} /> )} - {data.totalPages > 1 && ( + {data.totalPages > 1 && displayPagination && ( <Pagination sum={data.totalPages * per} per={per} diff --git a/app/views/reports/show.html.slim b/app/views/reports/show.html.slim index 8729a269c36..0cb18623679 100644 --- a/app/views/reports/show.html.slim +++ b/app/views/reports/show.html.slim @@ -154,7 +154,7 @@ | 提出物 .side-tabs-contents .side-tabs-contents__item#side-tabs-content-1 - = react_component('Reports', userId: @report.user.id, displayUserIcon: false) + = react_component('Reports', userId: @report.user.id, displayUserIcon: false, displayPagination: false) .side-tabs-contents__item#side-tabs-content-2.is-only-mentor .user-info = render 'users/user_secret_attributes', user: @report.user @@ -174,7 +174,7 @@ .o-empty-message__text | 提出物はまだありません。 - else - = react_component('Reports', userId: @report.user.id, displayUserIcon: false) + = react_component('Reports', userId: @report.user.id, displayUserIcon: false, displayPagination: false) - if flash[:notify_help] && flash[:celebrate_report_count] = render '/shared/modal', id: 'modal-notify-help', modal_title: '🎉 おめでとう!', auto_show: true diff --git a/app/views/talks/show.html.slim b/app/views/talks/show.html.slim index 883cf52ffdb..b38c9b497fc 100644 --- a/app/views/talks/show.html.slim +++ b/app/views/talks/show.html.slim @@ -86,4 +86,4 @@ class: 'a-button is-sm is-danger is-block' div(data-vue="UserMentorMemo" data-vue-user-id:number="#{@user.id}" data-vue-products-mode:boolean="#{true}") .side-tabs-contents__item#side-tabs-content-2 - = react_component('Reports', userId: @user.id, displayUserIcon: false) + = react_component('Reports', userId: @user.id, displayUserIcon: false, displayPagination: false)