예제 #1
0
    def input_validation(self):
        super().input_validation()
        inputError =  self.form["inputError"]
        if(DataValidator.isNull(self.form["subjectName"])):
            inputError["subjectName"] = " subjectName can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["subjectDescription"])):
            inputError["subjectDescription"] = "subjectDescription can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["dob"])):
            inputError["dob"] = "dob can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["course_ID"])):
            inputError["course_ID"] = "course_ID can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["courseName"])):
            inputError["courseName"] = "courseName can not be null"
            self.form["error"] = True

        # if(DataValidator.isNull(self.form["college_ID"])):
        #     inputError["college_ID"] = "college_ID can not be null"
        #     self.form["error"] = True

        # if(DataValidator.isNull(self.form["collegeName"])):
        #     inputError["collegeName"] = "college_Name can not be null"
        #     self.form["error"] = True

        return self.form["error"]        
예제 #2
0
 def input_validation(self):
     super().input_validation()
     inputError = self.form["inputError"]
     if (DataValidator.isNull(self.form["name"])):
         inputError["name"] = "Name can not be null"
         self.form["error"] = True
     if (DataValidator.isNull(self.form["description"])):
         inputError["description"] = "Description can not be null"
         self.form["error"] = True
     return self.form["error"]
예제 #3
0
 def input_validation(self):
     super().input_validation()
     inputError = self.form["inputError"]
     if (DataValidator.isNull(self.form["name"])):
         inputError["name"] = "Name can not be null"
         self.form["error"] = True
     else:
         if DataValidator.isaplhacheck(self.form['name']):
             inputError['name'] = "Name contains only alphabets"
             self.form['error'] = True
     if (DataValidator.isNull(self.form["description"])):
         inputError["description"] = "Description can not be null"
         self.form["error"] = True
     return self.form["error"]
예제 #4
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["firstName"])):
            inputError["firstName"] = "Name can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["lastName"])):
            inputError["lastName"] = "lastName can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["email"])):
            inputError["email"] = "email can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["password"])):
            inputError["password"] = "******"
            self.form["error"] = True

        

        if (DataValidator.isNull(self.form["address"])):
            inputError["address"] = "address can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["gender"])):
            inputError["gender"] = "gender can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["dob"])):
            inputError["dob"] = "dob can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["college_ID"])):
            inputError["college_ID"] = "college_ID can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["subject_ID"])):
            inputError["subject_ID"] = "subject_ID can not be null"
            self.form["error"] = True

       

        if (DataValidator.isNull(self.form["course_ID"])):
            inputError["course_ID"] = "course_ID can not be null"
            self.form["error"] = True

        
        return self.form["error"]
예제 #5
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["newPassword"])):
            inputError["newPassword"] = "******"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["oldPassword"])):
            inputError["oldPassword"] = "******"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["confirmPassword"])):
            inputError["confirmPassword"] = "******"
            self.form["error"] = True
        return self.form["error"]
예제 #6
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["firstName"])):
            inputError["firstName"] = " First_Name can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["lastName"])):
            inputError["lastName"] = "Last_Name can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["dob"])):
            inputError["dob"] = "dob can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["mobileNumber"])):
            inputError["mobileNumber"] = "Mobile_Number can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["email"])):
            inputError["email"] = "email_id can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["college_ID"])):
            inputError["college_ID"] = "college_ID can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeName"])):
            inputError["collegeName"] = "college_Name can not be null"
            self.form["error"] = True

        return self.form["error"]
예제 #7
0
    def input_validation(self):
        super().input_validation()
        inputError =  self.form["inputError"]
        if(DataValidator.isNull(self.form["examTime"])):
            inputError["examTime"] = " examTime can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["examDate"])):
            inputError["examDate"] = "examDate can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["subject_ID"])):
            inputError["subject_ID"] = "subject_ID can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["subjectName"])):
            inputError["subjectName"] = "subjectName can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["course_ID"])):
            inputError["course_ID"] = "course_ID can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["courseName"])):
            inputError["courseName"] = "courseName can not be null"
            self.form["error"] = True

        if(DataValidator.isNull(self.form["semester"])):
            inputError["semester"] = "semester can not be null"
            self.form["error"] = True

        return self.form["error"]        
예제 #8
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["collegeName"])):
            inputError["collegeName"] = "Name can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["collegeName"]):
                inputError["collegeName"] = "Name contains only alphabets"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeAddress"])):
            inputError["collegeAddress"] = "Address can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["collegeAddress"]):
                inputError["collegeAddress"] = "Name contains only alphabets"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeState"])):
            inputError["collegeState"] = "State can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["collegeState"]):
                inputError["collegeState"] = "Name contains only alphabets"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeCity"])):
            inputError["collegeCity"] = "City can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["collegeCity"]):
                inputError["collegeCity"] = "city contains only alphabets"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["collegePhoneNumber"])):
            inputError["collegePhoneNumber"] = "Phone Number can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isphonecheck(self.form["collegePhoneNumber"]):
                inputError["collegePhoneNumber"] = "Invalid Phone Number"
                self.form["error"] = True

        return self.form["error"]
예제 #9
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["rollNumber"])):
            inputError["rollNumber"] = "roll Number can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["name"])):
            inputError["name"] = "name can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["physics"])):
            inputError["physics"] = "physics can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["chemistry"])):
            inputError["chemistry"] = "chemistry can not be null"
            self.form["error"] = True
        if (DataValidator.isNull(self.form["maths"])):
            inputError["maths"] = "maths can not be null"
            self.form["error"] = True
        if (DataValidator.isNull(self.form["student_ID"])):
            inputError["student_ID"] = "student_ID can not be null"
            self.form["error"] = True

        return self.form["error"]
예제 #10
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["collegeName"])):
            inputError["collegeName"] = "Name can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeAddress"])):
            inputError["collegeAddress"] = "Address can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeState"])):
            inputError["collegeState"] = "State can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["collegeCity"])):
            inputError["collegeCity"] = "City can not be null"
            self.form["error"] = True
        if (DataValidator.isNull(self.form["collegePhoneNumber"])):
            inputError["collegePhoneNumber"] = "PhoneNumber can not be null"
            self.form["error"] = True

        return self.form["error"]
예제 #11
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["firstName"])):
            inputError["firstName"] = "Name can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form['firstName']):
                inputError['firstName'] = "First Name contains only alphabets"
                self.form['error'] = True

        if (DataValidator.isNull(self.form["lastName"])):
            inputError["lastName"] = "Last Name can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form['lastName']):
                inputError['lastName'] = "Last Name contains only alphabet"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["login_id"])):
            inputError["login_id"] = "Login can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isemail(self.form['login_id']):
                inputError['login_id'] = "Please Enter Email Address"
                self.form['error'] = True

        if (DataValidator.isNull(self.form["password"])):
            inputError["password"] = "******"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["confirmpassword"])):
            inputError["confirmpassword"] = "******"
            self.form["error"] = True

        if (DataValidator.isNotNull(self.form["confirmpassword"])):
            if (self.form["password"] != self.form["confirmpassword"]):
                inputError["confirmpassword"] = "******"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["dob"])):
            inputError["dob"] = "DOB can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["address"])):
            inputError["address"] = "Address can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["mobilenumber"])):
            inputError["mobilenumber"] = "Mobile Number can not be null"
            self.form["error"] = True
        else:
            if DataValidator.ismobilecheck(self.form['mobilenumber']):
                inputError['mobilenumber'] = "Invalid Mobile Number"
                self.form['error'] = True

        if (DataValidator.isNull(self.form["gender"])):
            inputError['gender'] = "Please Select Gender"
            self.form['error'] = True

        if (DataValidator.isNull(self.form["role_Id"])):
            inputError['role_Id'] = "Please Select Role"
            self.form['error'] = True

        return self.form["error"]
예제 #12
0
    def input_validation(self):
        super().input_validation()
        inputError = self.form["inputError"]
        if (DataValidator.isNull(self.form["firstName"])):
            inputError["firstName"] = " First Name can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["firstName"]):
                inputError["firstName"] = "Name contains only alphabets"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["lastName"])):
            inputError["lastName"] = "Last Name can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["lastName"]):
                inputError["lastName"] = "Name contains only alphabets"
                self.form["error"] = True
        if (DataValidator.isNull(self.form["collegeName"])):
            inputError["collegeName"] = "Last Name can not be null"
            self.form["error"] = True
        else:
            if DataValidator.isaplhacheck(self.form["collegeName"]):
                inputError["collegeName"] = "Name contains only alphabets"
                self.form["error"] = True
        if (DataValidator.isNull(self.form["dob"])):
            inputError["dob"] = "DOB can not be null"
            self.form["error"] = True

        if (DataValidator.isNull(self.form["mobileNumber"])):
            inputError["mobileNumber"] = "Mobile Number can not be null"
            self.form["error"] = True
        else:
            if DataValidator.ismobilecheck(self.form["mobileNumber"]):
                inputError[
                    "mobileNumber"] = "Mobile number contains only digits"
                self.form["error"] = True

        if (DataValidator.isNull(self.form["email"])):
            inputError["email"] = "Email ID can not be null"
            self.form["error"] = True
        else:
            if (DataValidator.isemail(self.form['email'])):
                inputError['email'] = "Please Enter Email Address"
                self.form['error'] = True

        if (DataValidator.isNull(self.form["college_ID"])):
            inputError["college_ID"] = "Please select College name"
            self.form["error"] = True

        return self.form["error"]