Skip to content

Commit 0eb2b4d

Browse files
authored
Merge pull request #2475 from tekdi/release-1.13.0-prod-register
Release 1.13.0 prod register
2 parents 3580184 + d1356fb commit 0eb2b4d

File tree

5 files changed

+18
-12
lines changed

5 files changed

+18
-12
lines changed

apps/learner-web-app/src/app/landing/page.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ export default function LandingPage() {
5151
const programsData = res?.result || [];
5252
const visiblePrograms = programsData?.filter(
5353
(program: any) =>
54-
program?.params?.uiConfig?.showProgram === true ||
55-
program?.params?.uiConfig?.sso?.length > 0
54+
program?.params?.uiConfig?.showProgram === true
55+
// program?.params?.uiConfig?.sso?.length > 0
5656
);
5757
setPrograms(visiblePrograms || []);
5858
} catch (error) {
@@ -460,7 +460,7 @@ export default function LandingPage() {
460460
</Box>
461461
) : (
462462
<Grid container spacing={4}>
463-
{programs.slice(0, 3).map((program, index) => (
463+
{programs?.map((program, index) => (
464464
<Grid item xs={12} md={4} key={program.tenantId || index}>
465465
<Card
466466
sx={{

libs/shared-lib-v2/src/lib/context/locales/en.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -444,7 +444,7 @@
444444
"TO_GET_ACCESS_TO_PRAGYANPATH": "to get access to Pragyanpath",
445445
"LOGIN": "Log in",
446446
"FOR_PRATHAM_EMPLOYEES": "For Pratham Employees",
447-
"ACCESS_PRAGYANPATH": "Access Pragyapath",
447+
"ACCESS_PRAGYANPATH": "Access Pragyanpath",
448448
"ABOUT_PRATHAM": "About Pratham",
449449
"ABOUT_PRATHAM_LEARNING_PLATFORM": "About Pratham Learning Platform",
450450
"OUR_PROGRAMS": "Our Programs",

mfes/scp-teacher-repo/src/components/UserRegistration/RegistrationPieChart.tsx

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,8 @@ const RegistrationPieChart: React.FC<RegistrationPieChartProps> = ({ locationFil
3333
{ name: t('USER_REGISTRATION.MAY_JOIN_UPCOMING_YEAR'), value: counts.mayJoin, color: '#FFD700' },
3434
];
3535

36-
const hasLocationFilters =
37-
Boolean(locationFilters.states?.length) &&
38-
Boolean(locationFilters.districts?.length) &&
39-
Boolean(locationFilters.blocks?.length) &&
40-
Boolean(locationFilters.villages?.length);
36+
// Only require states to be selected, other levels are optional
37+
const hasLocationFilters = Boolean(locationFilters.states?.length);
4138

4239
const buildFilters = (overrides: Record<string, any> = {}) => {
4340
const filters: Record<string, any> = {

mfes/scp-teacher-repo/src/components/assessment/AnswerSheet.tsx

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ export interface AnswerSheetProps {
4040
onApprove: () => void;
4141
onScoreEdit: (question: ScoreDetail) => void;
4242
isApproved?: boolean;
43+
isLoading?: boolean;
4344
questionNumberingMap?: Record<string, string>;
4445
sectionMapping?: Record<string, string>;
4546
}
@@ -214,7 +215,7 @@ const AISuggestion: React.FC<AISuggestionProps> = React.memo(
214215
}
215216

216217
// Function to truncate text to 25 words with better handling for Hindi text
217-
const truncateText = (text: string, maxWords: number = 25) => {
218+
const truncateText = (text: string, maxWords = 25) => {
218219
if (!text || text.trim() === '') {
219220
return text;
220221
}
@@ -497,10 +498,11 @@ ScoreSummary.displayName = 'ScoreSummary';
497498
interface ApproveButtonProps {
498499
onApprove: () => void;
499500
isApproved: boolean;
501+
isLoading?: boolean;
500502
}
501503

502504
const ApproveButton: React.FC<ApproveButtonProps> = React.memo(
503-
({ onApprove, isApproved }) => {
505+
({ onApprove, isApproved, isLoading = false }) => {
504506
if (isApproved) return null;
505507

506508
return (
@@ -509,6 +511,7 @@ const ApproveButton: React.FC<ApproveButtonProps> = React.memo(
509511
variant="contained"
510512
fullWidth
511513
onClick={onApprove}
514+
disabled={isLoading}
512515
sx={{
513516
bgcolor: '#FDBE16',
514517
color: '#4D4639',
@@ -525,6 +528,10 @@ const ApproveButton: React.FC<ApproveButtonProps> = React.memo(
525528
transform: 'translateY(-2px)',
526529
boxShadow: '0 4px 8px rgba(253, 190, 22, 0.3)',
527530
},
531+
'&:disabled': {
532+
bgcolor: '#E0E0E0',
533+
color: '#9E9E9E',
534+
},
528535
}}
529536
>
530537
Approve Marks & Notify Learner
@@ -717,6 +724,7 @@ const AnswerSheet: React.FC<AnswerSheetProps> = ({
717724
onApprove,
718725
onScoreEdit,
719726
isApproved = false,
727+
isLoading = false,
720728
questionNumberingMap = {},
721729
sectionMapping = {},
722730
}) => {
@@ -737,7 +745,7 @@ const AnswerSheet: React.FC<AnswerSheetProps> = ({
737745
/>
738746

739747
{/* Approve Button */}
740-
<ApproveButton onApprove={onApprove} isApproved={isApproved} />
748+
<ApproveButton onApprove={onApprove} isApproved={isApproved} isLoading={isLoading} />
741749

742750
{/* Questions List */}
743751
<QuestionsList

mfes/scp-teacher-repo/src/pages/ai-assessments/[assessmentId]/[userId]/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1372,6 +1372,7 @@ const AssessmentDetails = () => {
13721372
onApprove={handleApproveClick}
13731373
onScoreEdit={handleScoreClick}
13741374
isApproved={assessmentData?.status === 'Approved'}
1375+
isLoading={editLoading}
13751376
questionNumberingMap={questionNumberingMap}
13761377
sectionMapping={sectionMapping}
13771378
/>

0 commit comments

Comments
 (0)