diff --git a/src/assets/languages/en.json b/src/assets/languages/en.json index bfc2ec19a208ccb8cb7053461c6998392eb4e095..2ecd612963a662fb9426876e8f4ef25e459ca318 100644 --- a/src/assets/languages/en.json +++ b/src/assets/languages/en.json @@ -1542,7 +1542,7 @@ "userName": "Please enter your name", "reminderBefore": "Please select reminder", "addMultipleSlots": "Event time is not editable. Some users have signed up the event", - "participantsReq": "Partcipants are required", + "participantsReq": "Participants are required", "scheduleDateErr": "Schedule time can't be greater than event start time", "scheduleDateInvalid": "Schedule time should be greater than current time of selected timezone" }, diff --git a/src/componets/SignupEventComponents/SignupEventHistory/SignupEventHistoryLeftPanel/SignupEventHistoryLeftPanel.js b/src/componets/SignupEventComponents/SignupEventHistory/SignupEventHistoryLeftPanel/SignupEventHistoryLeftPanel.js index 54fcc8faf5231ef27da938ddb8c20d59b08fee7f..3e30fb822edb1f65140614792d885beb8287ab3a 100644 --- a/src/componets/SignupEventComponents/SignupEventHistory/SignupEventHistoryLeftPanel/SignupEventHistoryLeftPanel.js +++ b/src/componets/SignupEventComponents/SignupEventHistory/SignupEventHistoryLeftPanel/SignupEventHistoryLeftPanel.js @@ -100,11 +100,11 @@ class SignupEventHistoryLeftPanel extends React.Component { { diff --git a/src/componets/SignupEventComponents/SignupEventInvitation/SignupEventInvitationMiddlePanel/SignupEventInvitationMiddlePanel.js b/src/componets/SignupEventComponents/SignupEventInvitation/SignupEventInvitationMiddlePanel/SignupEventInvitationMiddlePanel.js index 48e9556403131cc226af2da97bb741534a3cdd2d..e8580b190fc9d97cfa96fd408e1ff2c3d856f205 100644 --- a/src/componets/SignupEventComponents/SignupEventInvitation/SignupEventInvitationMiddlePanel/SignupEventInvitationMiddlePanel.js +++ b/src/componets/SignupEventComponents/SignupEventInvitation/SignupEventInvitationMiddlePanel/SignupEventInvitationMiddlePanel.js @@ -29,10 +29,16 @@ class SignupEventInvitationMiddlePanel extends React.Component {
{t('eventSignup.eventSignupHistory.signupDetails')}
- {currentEventInvitation.isEditable && - + {currentEventInvitation.isEditable ? + !isShowEdit ? + + : + + : null }
@@ -104,7 +110,9 @@ class SignupEventInvitationMiddlePanel extends React.Component {
{t('eventSignup.eventSignupInvitation.notes')}
-
{currentEventInvitation.note}
+ {!isShowEdit && +
{currentEventInvitation.note}
+ }
diff --git a/src/layouts/EventSignupNew/EventSignupNew.js b/src/layouts/EventSignupNew/EventSignupNew.js index 9334d358e84167c7a8c47b0f8ecbf03a54e73dc8..b00b716eac788c50a3b2e5429314c2ccb4756eaf 100644 --- a/src/layouts/EventSignupNew/EventSignupNew.js +++ b/src/layouts/EventSignupNew/EventSignupNew.js @@ -639,17 +639,17 @@ class EventSignupNew extends Component { usersArr.push(data); this.setState({ inviteUsers: usersArr }, this.toggleParticipents); } else if (type == "groups") { - // let groupArr = this.state.inviteGroups; - // groupArr.push(data); - // this.setState({ inviteGroups: groupArr }, this.toggleParticipents); - - this.setState({ - inviteGroups: [], - }, () => { - let groupArr = this.state.inviteGroups; - groupArr.push(data); - this.setState({ inviteGroups: groupArr }, this.toggleParticipents); - }) + let groupArr = this.state.inviteGroups; + groupArr.push(data); + this.setState({ inviteGroups: groupArr }, this.toggleParticipents); + + // this.setState({ + // inviteGroups: [], + // }, () => { + // let groupArr = this.state.inviteGroups; + // groupArr.push(data); + // this.setState({ inviteGroups: groupArr }, this.toggleParticipents); + // }) } }; removeParticipents = (type, val) => { @@ -765,7 +765,7 @@ class EventSignupNew extends Component { } ]; } - const numsStateArr = this.state.inviteNumbers; + const numsStateArr= this.state.inviteNumbers; const emailsStateArr = this.state.inviteEmails; const usersStateArr = this.state.inviteUsers; const groupStateArr = this.state.inviteGroups; @@ -774,24 +774,42 @@ class EventSignupNew extends Component { let numbersArr = []; let usersArr = []; let groupsArr = []; + + let newAccountIds = []; + let newEmailsArr = []; + let newNumsArr = []; + let newGroupArr = []; + if (numsStateArr.length > 0) { numsStateArr.map(function (v, k) { numbersArr.push(v.number); + if(v.isRemove===undefined) { + newNumsArr.push(v.number); + } }); } if (emailsStateArr.length > 0) { emailsStateArr.map(function (v, k) { emailsArr.push(v.email); + if(v.isRemove==undefined) { + newEmailsArr.push(v.email); + } }); } if (usersStateArr.length > 0) { usersStateArr.map(function (v, k) { usersArr.push(v.accountId); + if(v.phone_id!==undefined) { + newAccountIds.push(v.accountId); + } }); } if (groupStateArr.length > 0) { groupStateArr.map(function (v, k) { groupsArr.push(v.phone_id); + if(v.isRemove==undefined) { + newGroupArr.push(v.phone_id); + } }); } @@ -875,6 +893,14 @@ class EventSignupNew extends Component { false ); } else if (this.state.eventAddFormStep === 2) { + //if event already published, no call api + if(this.state.editModeInternalUse && this.state.isPublishTs > 0){ + let step = this.state.eventAddFormStep; + step = step >= 3 ? step : step + 1; + this.setState({ eventAddFormStep: step, isLoader: false }); + return; + } + this.saveEventApiCall( action, eventId, @@ -900,29 +926,30 @@ class EventSignupNew extends Component { false ); } else if (this.state.eventAddFormStep === 3) { - console.log('notifyOnUpdate::',this.state, - action, - eventId, - "", - "", - "", - "", - [], - phase, - active, - [], - [], - [], - [], - scheduleDate, - scheduleTime, - isSendReminder, - isNotifyAdmin, - updateSchedule, - updateReminder, - scheduleTimezone, - remindBefore, - notifyOnUpdate); + if(this.state.editModeInternalUse && this.state.isPublishTs > 0){ + + } else { + emailsArr = []; + numbersArr = []; + usersArr = []; + groupsArr = []; + } + // if(!this.state.notifyOnUpdate){ + // // newAccountIds = []; + // // newEmailsArr = []; + // // newNumsArr = []; + // // newGroupArr = []; + + // emailsArr = []; + // numbersArr = []; + // usersArr = []; + // groupsArr = []; + // } + console.log('notifyOnUpdate::',usersArr, + groupsArr, + emailsArr, + numbersArr, this.state,notifyOnUpdate); + this.saveEventApiCall( action, eventId, @@ -933,10 +960,10 @@ class EventSignupNew extends Component { [], phase, active, - [], - [], - [], - [], + usersArr, + groupsArr, + emailsArr, + numbersArr, scheduleDate, scheduleTime, isSendReminder, @@ -1132,8 +1159,7 @@ class EventSignupNew extends Component { }); error = true; } else if ( - this.state.isMultiTimeSlot && - this.state.timeSlotArr.length === 1 + this.state.isMultiTimeSlot && this.state.timeSlotArr.length <=1 ) { actions.showToast({ text: t("eventSignup.validateion.selectTimeslot"), @@ -1457,6 +1483,7 @@ class EventSignupNew extends Component { if (this.state.eventId == "") { this.setState({ eventId: res.eventProfileResponseData.eventId }); } + //console.log(res.eventProfileResponseData,newProps,'DATAT'); this.nextStep(); } } diff --git a/src/layouts/EventSignupNew/subcomponents/InviteByContact.js b/src/layouts/EventSignupNew/subcomponents/InviteByContact.js index a07d303ac394661b625dc53718aebb3f3a9d7679..51485bfdc279e1a73018edf4392fe3f1cbec82ee 100644 --- a/src/layouts/EventSignupNew/subcomponents/InviteByContact.js +++ b/src/layouts/EventSignupNew/subcomponents/InviteByContact.js @@ -204,7 +204,8 @@ class InviteByContact extends Component { if (grp && grp.admins) { isAdminInSelectedGroup = grp.admins[profile.phone_id] !== undefined; } - selectedMembers = { [member.phone_id]: member }; + // selectedMembers = { [member.phone_id]: member }; + selectedMembers[member.phone_id] = member; this.setState({ meetingTitle: member.names, isAdminInSelectedGroup,