Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

This is my file i am facing error #8

Open
Sivasankar967 opened this issue Jul 25, 2023 · 0 comments
Open

This is my file i am facing error #8

Sivasankar967 opened this issue Jul 25, 2023 · 0 comments

Comments

@Sivasankar967
Copy link

Sivasankar967 commented Jul 25, 2023

this my error
VM691:1 Warning: Cannot update during an existing state transition (such as within render or another component's constructor). Render methods should be a pure function of props and state; constructor side-effects are an anti-pattern, but can be moved to componentWillMount.

Actually i am facing error in this.setState()

class TemplateTab extends React.Component {
constructor(props) {
super(props);
this.state = {
tabName: "",
key: this.props.activeKey,
searchData: "",
getDetails: "",
onchangeEmailIntegraionValue: "",
userId: "",
popoverDate: "",
modalSize: "",
integrationModalTitle: "",
integrationComponent: "",
savaBtnTxt: "",
CancelBtnText: "",
modalTitle: "",
dynamicParentClass: "",
modalClass: "",
showModal: "",
close: "",
closeBtnTxt: "",
saveBtnTxt: "",
save: "",
title: "",
fname: "",
editOrAdd: "",
tabId: "",
newkey: "0",
canId: "",
tab: this.props.tab,
SearchValue: "",
searchError: false,
SearchErrorMsg: "",
tabSearch: this.props.tabSearch,
startIndex: 0,
ToggleShow: "",
EmailDetails: {
startIndex: 0,
maxIndex: 20,
pageIndex: 0,
candidateState: "new_candidates",
status: false,
titleCount: 0,
carry: 0,
countState: true,
followUpDate:"",
skills: "",
title: "",
experience: "",
education: "",
location: "",
adminCandidateCilentSubmission: "",
adminCandidateStatus: "",
recruiterOwnedBy: "",
availability: "",
jobSearchStatus: "",
lastTitle: "",
lastLocation: "",
recruiterNotes: "",
subscriptions: "",
lastActivity: "",
loginTime: "",
requestStatus: ""
},
disabled: false,
clearSelected: false,
searchforCandidate: false,
WinWidth: window.innerWidth,
sendStatus: "",
campaignStatus:false,
btnName:"Create List",
templateType:"plainEmail",
operation:"",
optionsChecked:[],
subTabActiveKey:0,
userRemoveBtnLoading:false,
userRemoveModal:false,
subTabActiveName:'all'
};
}

getCanId = canId => {
let dis_status = this.props.clikedId ? this.props.clikedId: "";
if (this.props.activeKey === 2 && (this.props.subTabKey === 0 || this.props.subTabKey === 4 || this.props.subTabKey === 5 || this.props.subTabKey === 6) ) {
let AdminCandidate = { newUserListId: canId };
this.setState ({
disabled: dis_status.length != 0 ? false : true,
canId: canId,
AdminCandidate
});
}
console.log("res",canId)

@Sivasankar967 Sivasankar967 changed the title This is my file i am facing error with 336line This is my file i am facing error Jul 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant