Commit ce1c575fe6af89a66be705cb661739ffb8affa83

Authored by apple
1 parent e7202f14e2
Exists in master

validation on upload file

Showing 2 changed files with 35 additions and 17 deletions   Show diff stats
pages/registration.html
1 <div class="header"> 1 <div class="header">
2 <div> 2 <div>
3 <!-- <img src="images/LOGO.png" class="logojalsa"><span class="jalsaheadr" style="">2018</span> --> 3 <!-- <img src="images/LOGO.png" class="logojalsa"><span class="jalsaheadr" style="">2018</span> -->
4 <!-- <img src="images/SartupJalsa_Logo.png" style="width:200px;position:relative;"> --> 4 <!-- <img src="images/SartupJalsa_Logo.png" style="width:200px;position:relative;"> -->
5 </div> 5 </div>
6 <div class="clearfix"></div> 6 <div class="clearfix"></div>
7 </div> 7 </div>
8 <!-- CLOSE HEADER --> 8 <!-- CLOSE HEADER -->
9 <form name="applicantForm"> 9 <form name="applicantForm">
10 <div class="col-xs-12 col-md-8 col-md-offset-2"> 10 <div class="col-xs-12 col-md-8 col-md-offset-2">
11 <div class="form-all"> 11 <div class="form-all">
12 <h4 class="title">General Information</h4> 12 <h4 class="title">General Information</h4>
13 <!-- <table style="width: 100%;"> 13 <!-- <table style="width: 100%;">
14 <tr> 14 <tr>
15 <td> 15 <td>
16 <div class="step-one-form" > --> 16 <div class="step-one-form" > -->
17 <!-- form step 1 --> 17 <!-- form step 1 -->
18 <div class="col-xs-12 col-md-8 col-md-offset-2 input-wrapper" > 18 <div class="col-xs-12 col-md-8 col-md-offset-2 input-wrapper" >
19 <div class="form-group"> 19 <div class="form-group">
20 <label>Name: *</label> 20 <label>Name: *</label>
21 <input type="name" class="form-control" ng-model="data.name" required> 21 <input type="name" class="form-control" ng-model="data.name" required>
22 </div> 22 </div>
23 <div class="form-group"> 23 <div class="form-group">
24 <label>Startup Name: *</label> 24 <label>Startup Name: *</label>
25 <input type="text" class="form-control" ng-model="data.startupName" required> 25 <input type="text" class="form-control" ng-model="data.startupName" required>
26 </div> 26 </div>
27 <div class="form-group"> 27 <div class="form-group">
28 <label>Phone No: *</label> 28 <label>Phone No: *</label>
29 <input type="number" class="form-control" ng-model="data.number" required> 29 <input type="number" class="form-control" ng-model="data.number" required>
30 <!-- <label class="error-message f-family" id="invalidNumber">Please enter only numeric value.</label> -->
30 </div> 31 </div>
31 <div class="form-group"> 32 <div class="form-group">
32 <label>Email: *</label> 33 <label>Email: *</label>
33 <input type="email" class="form-control" ng-model="data.email" required> 34 <input type="email" class="form-control" ng-model="data.email" required>
34 </div> 35 </div>
35 <div class="form-group"> 36 <div class="form-group">
36 <label>City:</label> 37 <label>City:</label>
37 <input type="text" class="form-control" ng-model="data.city" readonly> 38 <input type="text" class="form-control" ng-model="data.city" readonly>
38 </div> 39 </div>
39 <div class="form-group"> 40 <div class="form-group">
40 <label>Website:</label> 41 <label>Website:</label>
41 <input type="text" class="form-control" ng-model="data.website"> 42 <input type="text" class="form-control" ng-model="data.website">
42 </div> 43 </div>
43 <div class="form-group"> 44 <div class="form-group">
44 <label>Founding Year: *</label> 45 <label>Founding Year: *</label>
45 <input type="text" class="form-control" ng-model="data.founder" required> 46 <input type="text" class="form-control" ng-model="data.founder" required>
46 </div> 47 </div>
47 <div class="form-group"> 48 <div class="form-group">
48 <label>Business Types: *</label> 49 <label>Business Types: *</label>
49 <select class="form-control" ng-model="data.business" required> 50 <select class="form-control" ng-model="data.business" required>
50 <option name="business" selected disabled value="">Choose business type</option> 51 <option name="business" selected disabled value="">Choose business type</option>
51 <option value="B2B">B2B</option> 52 <option value="B2B">B2B</option>
52 <option value="B2C">B2C</option> 53 <option value="B2C">B2C</option>
53 </select> 54 </select>
54 </div> 55 </div>
55 <div class="form-group"> 56 <div class="form-group">
56 <label>Stage: *</label> 57 <label>Stage: *</label>
57 <select class="form-control" ng-model="data.stage" required> 58 <select class="form-control" ng-model="data.stage" required>
58 <option name="stage" selected disabled value="">Choose Startup Stage</option> 59 <option name="stage" selected disabled value="">Choose Startup Stage</option>
59 <option value="Idea">Idea</option> 60 <option value="Idea">Idea</option>
60 <option value="Prototype">Prototype</option> 61 <option value="Prototype">Prototype</option>
61 </select> 62 </select>
62 </div> 63 </div>
63 <div class="form-group"> 64 <div class="form-group">
64 <label>Sector: *</label> 65 <label>Sector: *</label>
65 <select class="form-control" ng-model="data.sector" ng-change="GetValue()" required> 66 <select class="form-control" ng-model="data.sector" ng-change="GetValue()" required>
66 <option name="sector" selected disabled value="">Choose sector</option> 67 <option name="sector" selected disabled value="">Choose sector</option>
67 <option value="Agriculture">Agriculture</option> 68 <option value="Agriculture">Agriculture</option>
68 <option value="Healthcare">Healthcare</option> 69 <option value="Healthcare">Healthcare</option>
69 <option value="e-Governance">e-Governance</option> 70 <option value="e-Governance">e-Governance</option>
70 <option value="Retail">Retail</option> 71 <option value="Retail">Retail</option>
71 <option value="Food and Beverages">Food and Beverages</option> 72 <option value="Food and Beverages">Food and Beverages</option>
72 <option value="Hardware">Hardware</option> 73 <option value="Hardware">Hardware</option>
73 <option value="Software">Software</option> 74 <option value="Software">Software</option>
74 <option value="Media and Entertainment">Media and Entertainment</option> 75 <option value="Media and Entertainment">Media and Entertainment</option>
75 <option value="AI">AI</option> 76 <option value="AI">AI</option>
76 <option value="AR&VR">AR&VR</option> 77 <option value="AR&VR">AR&VR</option>
77 <option value="Automobile">Automobile</option> 78 <option value="Automobile">Automobile</option>
78 <option value="Other">Other</option> 79 <option value="Other">Other</option>
79 </select> 80 </select>
80 </div> 81 </div>
81 <div class="form-group" ng-if="ngShowhide"> 82 <div class="form-group" ng-if="ngShowhide">
82 <input type="text" class="form-control" ng-model="data.sectorType" placeholder="Other Sector Name"> 83 <input type="text" class="form-control" ng-model="data.sectorType" placeholder="Other Sector Name">
83 </div> 84 </div>
84 <div class="form-group"> 85 <div class="form-group">
85 <label>Introduction: *</label> 86 <label>Introduction: *</label>
86 <textarea type="text" class="form-control" ng-model="data.intro" placeholder="Give us a brief introduction in two lines" rows="3" required></textarea> 87 <textarea type="text" class="form-control" ng-model="data.intro" placeholder="Give us a brief introduction in two lines" rows="3" required></textarea>
87 </div> 88 </div>
88 <div class="form-group"> 89 <div class="form-group">
89 <label>Revenue: *</label> 90 <label>Revenue: *</label>
90 <textarea type="text" class="form-control" ng-model="data.revenue" placeholder="Are you generating any revenue? If yes, then mention your numbers" rows="3" required></textarea> 91 <textarea type="text" class="form-control" ng-model="data.revenue" placeholder="Are you generating any revenue? If yes, then mention your numbers" rows="3" required></textarea>
91 </div> 92 </div>
92 <div class="form-group"> 93 <div class="form-group">
93 <label>Previous Investments: *</label> 94 <label>Previous Investments: *</label>
94 <textarea type="text" class="form-control" ng-model="data.investment" placeholder="Did you receive any previous investment? If yes, then mention the investment amount and the equity you diluted?" rows="3" required></textarea> 95 <textarea type="text" class="form-control" ng-model="data.investment" placeholder="Did you receive any previous investment? If yes, then mention the investment amount and the equity you diluted?" rows="3" required></textarea>
95 </div> 96 </div>
96 <div class="form-group"> 97 <div class="form-group">
97 <label>Coupon Code:</label> 98 <label>Coupon Code:</label>
98 <input type="text" class="form-control" placeholder="If you have a coupon code then apply here"ng-model="data.referalToken"> 99 <input type="text" class="form-control" placeholder="If you have a coupon code then apply here"ng-model="data.referalToken">
99 <!-- <input type="text" class="form-control" ng-model="data.referalToken" style="position: relative;" ng-required="referalToken" ng-change="changeReferalIconColor(data.referalToken)"> 100 <!-- <input type="text" class="form-control" ng-model="data.referalToken" style="position: relative;" ng-required="referalToken" ng-change="changeReferalIconColor(data.referalToken)">
100 <i class="material-icons coupen-approved" ng-if="tokencheck == true">check</i> 101 <i class="material-icons coupen-approved" ng-if="tokencheck == true">check</i>
101 <i class="material-icons coupen-approved" style="color:red;" ng-if="tokencheck == false">close</i> 102 <i class="material-icons coupen-approved" style="color:red;" ng-if="tokencheck == false">close</i>
102 <button type="button" ng-click="tokenCall(data.referalToken)" class="pull-right apply-coupen-btn">Apply</button> --> 103 <button type="button" ng-click="tokenCall(data.referalToken)" class="pull-right apply-coupen-btn">Apply</button> -->
103 </div> 104 </div>
104 <div class="form-group"> 105 <div class="form-group">
105 <label>Attach Pitch Deck: *</label> 106 <label>Attach Pitch Deck: *</label>
106 <input type="file" class="form-control-file" ng-model="data.uploadFile" id="filePicker" accept=".png, .jpg, .jpeg, .pdf, .ppt"> 107 <input type="file" class="form-control-file" valid-file ng-model="data.uploadFile" required id="filePicker" accept=".png, .jpg, .jpeg, .pdf, .ppt">
107 <span ng-show="fileSelect" class=form-group-text>Please Select a File</span> 108 <span ng-show="fileSelect" class=form-group-text>Please Select a File</span>
108 </div> 109 </div>
109 <div class=form-group-text> 110 <div class=form-group-text>
110 Fields marked with "<b>*</b>" are mandatory. 111 Fields marked with "<b>*</b>" are mandatory.
111 </div> 112 </div>
112 </div> 113 </div>
114 <div class="clearfix"></div>
115 <div class="text-center">
116 <input type="submit" class="btn submit-button-form" ng-disabled="applicantForm.$invalid" value="Submit" ng-click="submit()">
117 </div>
118 </div>
113 <!-- <div class="col-xs-12 col-md-6 input-wrapper" > 119 <!-- <div class="col-xs-12 col-md-6 input-wrapper" >
114 <div id="snackbar">Error ! Please fill in all fields.</div> 120 <div id="snackbar">Error ! Please fill in all fields.</div>
115 <div class="icon-circle-c"> 121 <div class="icon-circle-c">
116 <i class="material-icons" style="line-height: 31px;">person</i> 122 <i class="material-icons" style="line-height: 31px;">person</i>
117 </div> 123 </div>
118 <input type="text" class="text-input" required ng-model="data.name" placeholder="Name *" id="myBtn" name="name" ng-change="entername(data.name); firstNamekeyPress(data.name)"> 124 <input type="text" class="text-input" required ng-model="data.name" placeholder="Name *" id="myBtn" name="name" ng-change="entername(data.name); firstNamekeyPress(data.name)">
119 </div> 125 </div>
120 <div class="col-xs-12 col-md-6 input-wrapper" > 126 <div class="col-xs-12 col-md-6 input-wrapper" >
121 <div id="snackbar">Error ! Please fill in all fields.</div> 127 <div id="snackbar">Error ! Please fill in all fields.</div>
122 <div class="icon-circle-d"> 128 <div class="icon-circle-d">
123 <i class="material-icons" style="line-height: 30px;">email</i> 129 <i class="material-icons" style="line-height: 30px;">email</i>
124 </div> 130 </div>
125 <input type="email" name="email" ng-pattern="/^[^\s@]+@[^\s@]+\.[^\s@]+$/" class="text-input" required class="" ng-model="data.email" ng-blur="emailcheck(data.email)" ng-focus="removeError()" placeholder="Email Address *" ng-change="enteremail(data.email); emailkeyPress(data.email)"> 131 <input type="email" name="email" ng-pattern="/^[^\s@]+@[^\s@]+\.[^\s@]+$/" class="text-input" required class="" ng-model="data.email" ng-blur="emailcheck(data.email)" ng-focus="removeError()" placeholder="Email Address *" ng-change="enteremail(data.email); emailkeyPress(data.email)">
126 <label class="error-message f-family" id="invalidEmail">Please enter a valid email address.</label> 132 <label class="error-message f-family" id="invalidEmail">Please enter a valid email address.</label>
127 </div> 133 </div>
128 <div class="col-xs-12 col-md-6 input-wrapper"> 134 <div class="col-xs-12 col-md-6 input-wrapper">
129 <div class="icon-circle-f"> 135 <div class="icon-circle-f">
130 <i class="material-icons" style="line-height: 30px;">location_city</i> 136 <i class="material-icons" style="line-height: 30px;">location_city</i>
131 </div> 137 </div>
132 <select ng-model="data.city" ng-change="selectcity(data.city); citykeyPress(data.city)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required> 138 <select ng-model="data.city" ng-change="selectcity(data.city); citykeyPress(data.city)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required>
133 <option name="city" selected disabled value="">{{data.city}}</option> 139 <option name="city" selected disabled value="">{{data.city}}</option>
134 <option value="Ahmedabad">Ahmedabad</option> 140 <option value="Ahmedabad">Ahmedabad</option>
135 <option value="Bengaluru">Bengaluru</option> 141 <option value="Bengaluru">Bengaluru</option>
136 <option value="Chennai">Chennai</option> 142 <option value="Chennai">Chennai</option>
137 <option value="Delhi">Delhi</option> 143 <option value="Delhi">Delhi</option>
138 <option value="Hyderabad">Hyderabad</option> 144 <option value="Hyderabad">Hyderabad</option>
139 <option value="Jaipur">Jaipur</option> 145 <option value="Jaipur">Jaipur</option>
140 <option value="Kanpur">Kanpur</option> 146 <option value="Kanpur">Kanpur</option>
141 <option value="Kolkata">Kolkata</option> 147 <option value="Kolkata">Kolkata</option>
142 <option value="Mumbai">Mumbai</option> 148 <option value="Mumbai">Mumbai</option>
143 </select> 149 </select>
144 </div> 150 </div>
145 <div class="col-xs-12 col-md-6 input-wrapper" > 151 <div class="col-xs-12 col-md-6 input-wrapper" >
146 <div class="icon-circle-e"> 152 <div class="icon-circle-e">
147 <i class="material-icons" style="line-height: 30px;">phone</i> 153 <i class="material-icons" style="line-height: 30px;">phone</i>
148 </div> 154 </div>
149 <input type="phone" name="phone" ng-pattern="/^\d*(?:\.\d{1,2})?$/" maxlength="10" class="text-input" required class="" ng-model="data.number" ng-blur="numbercheck(data.number)" ng-focus="removeNoError()" placeholder="Mobile No.*" ng-change="enternumber(data.number); phonekeyPress(data.number)"> 155 <input type="phone" name="phone" ng-pattern="/^\d*(?:\.\d{1,2})?$/" maxlength="10" class="text-input" required class="" ng-model="data.number" ng-blur="numbercheck(data.number)" ng-focus="removeNoError()" placeholder="Mobile No.*" ng-change="enternumber(data.number); phonekeyPress(data.number)">
150 <label class="error-message f-family" id="invalidNumber">Please enter only numeric value.</label> 156 <label class="error-message f-family" id="invalidNumber">Please enter only numeric value.</label>
151 </div> 157 </div>
152 <div class="col-xs-12 col-md-6 input-wrapper"> 158 <div class="col-xs-12 col-md-6 input-wrapper">
153 <div class="icon-circle-i"> 159 <div class="icon-circle-i">
154 <i class="material-icons" style="line-height: 30px;">perm_identity</i> 160 <i class="material-icons" style="line-height: 30px;">perm_identity</i>
155 </div> 161 </div>
156 <input type="text" class="text-input" ng-model="data.companyName" placeholder="Company Name *" ng-change="enternumber(data.companyName); companykeyPress(data.companyName)" required> 162 <input type="text" class="text-input" ng-model="data.companyName" placeholder="Company Name *" ng-change="enternumber(data.companyName); companykeyPress(data.companyName)" required>
157 </div> 163 </div>
158 <div class="col-xs-12 col-md-6 input-wrapper"> 164 <div class="col-xs-12 col-md-6 input-wrapper">
159 <div class="icon-circle-n"> 165 <div class="icon-circle-n">
160 <i class="material-icons" style="line-height: 30px;">web</i> 166 <i class="material-icons" style="line-height: 30px;">web</i>
161 </div> 167 </div>
162 <input name="website" class="text-input" ng-model="data.website" placeholder="Website link" ng-change="enterwebsite(data.website); revenuekeyPress(data.website)"></input> 168 <input name="website" class="text-input" ng-model="data.website" placeholder="Website link" ng-change="enterwebsite(data.website); revenuekeyPress(data.website)"></input>
163 </div> 169 </div>
164 <div class="col-xs-12 col-md-6 input-wrapper"> 170 <div class="col-xs-12 col-md-6 input-wrapper">
165 <div class="icon-circle-y"> 171 <div class="icon-circle-y">
166 <i class="material-icons" style="line-height: 30px;">assignment</i> 172 <i class="material-icons" style="line-height: 30px;">assignment</i>
167 </div> 173 </div>
168 <select ng-model="data.stage" ng-change="selectechnology(data.stage); fundkeyPress(data.stage)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required> 174 <select ng-model="data.stage" ng-change="selectechnology(data.stage); fundkeyPress(data.stage)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required>
169 <option name="stage" selected disabled value="">Choose Startup Stage *</option> 175 <option name="stage" selected disabled value="">Choose Startup Stage *</option>
170 <option value="Idea">Idea</option> 176 <option value="Idea">Idea</option>
171 <option value="Prototype">Prototype</option> 177 <option value="Prototype">Prototype</option>
172 </select> 178 </select>
173 </div> 179 </div>
174 <div class="col-xs-12 col-md-6 input-wrapper"> 180 <div class="col-xs-12 col-md-6 input-wrapper">
175 <div class="icon-circle-q"> 181 <div class="icon-circle-q">
176 <i class="material-icons" style="line-height: 30px;">business</i> 182 <i class="material-icons" style="line-height: 30px;">business</i>
177 </div> 183 </div>
178 <select ng-model="data.business" ng-change="selectechnology(data.business); ideakeyPress(data.business)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required> 184 <select ng-model="data.business" ng-change="selectechnology(data.business); ideakeyPress(data.business)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required>
179 <option name="business" selected disabled value="">Type of business *</option> 185 <option name="business" selected disabled value="">Type of business *</option>
180 <option value="B2B">B2B</option> 186 <option value="B2B">B2B</option>
181 <option value="B2C">B2C</option> 187 <option value="B2C">B2C</option>
182 <option value="Other">Other</option> 188 <option value="Other">Other</option>
183 </select> 189 </select>
184 </div> 190 </div>
185 <div class="col-xs-12 col-md-12 f-family line-adjust"> 191 <div class="col-xs-12 col-md-12 f-family line-adjust">
186 <strong>How many founders/teammates will be attending pitch session? *</strong> 192 <strong>How many founders/teammates will be attending pitch session? *</strong>
187 <p class="line-space" ></p> 193 <p class="line-space" ></p>
188 </div> 194 </div>
189 <div class="col-xs-12 col-md-12 input-wrapper" > 195 <div class="col-xs-12 col-md-12 input-wrapper" >
190 <div class="icon-circle-o"> 196 <div class="icon-circle-o">
191 <i class="material-icons" style="line-height: 30px;">confirmation_number</i> 197 <i class="material-icons" style="line-height: 30px;">confirmation_number</i>
192 </div> 198 </div>
193 <select ng-model="data.founder" ng-change="selectfounder(data.founder); discountkeyPress(data.founder)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required> 199 <select ng-model="data.founder" ng-change="selectfounder(data.founder); discountkeyPress(data.founder)" style="background-color: #fff; border-radius: 0; font-size: 12px; height: 44px;" required>
194 <option name="founder" selected disabled value="">Choose</option> 200 <option name="founder" selected disabled value="">Choose</option>
195 <option value="1">1</option> 201 <option value="1">1</option>
196 <option value="2">2</option> 202 <option value="2">2</option>
197 <option value="3">3</option> 203 <option value="3">3</option>
198 <option value="more than 3">more than 3</option> 204 <option value="more than 3">more than 3</option>
199 </select> 205 </select>
200 </div> --> 206 </div> -->
201 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust"> 207 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust">
202 <strong>In which city is your startup registered at?</strong> 208 <strong>In which city is your startup registered at?</strong>
203 <p class="line-space" ></p> 209 <p class="line-space" ></p>
204 </div> --> 210 </div> -->
205 <!-- <div class="col-xs-12 col-md-12 input-wrapper"> 211 <!-- <div class="col-xs-12 col-md-12 input-wrapper">
206 <div class="icon-circle-m"> 212 <div class="icon-circle-m">
207 <i class="material-icons" style="line-height: 30px;">assessment</i> 213 <i class="material-icons" style="line-height: 30px;">assessment</i>
208 </div> 214 </div>
209 <input type="text" class="text-input" ng-model="data.cityRegister" placeholder="Your Answer.." ng-change="entertechnology(data.cityRegister); annualkeyPress(data.cityRegister)"> 215 <input type="text" class="text-input" ng-model="data.cityRegister" placeholder="Your Answer.." ng-change="entertechnology(data.cityRegister); annualkeyPress(data.cityRegister)">
210 </div> --> 216 </div> -->
211 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust"> 217 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust">
212 <strong>Give us a brief introduction about your startup. *</strong> 218 <strong>Give us a brief introduction about your startup. *</strong>
213 <p class="line-space" >Kindly write a powerful Twitter Pitch (characters limit - 200).</p> 219 <p class="line-space" >Kindly write a powerful Twitter Pitch (characters limit - 200).</p>
214 </div> 220 </div>
215 <div class="col-xs-12 col-md-12 input-wrapper"> 221 <div class="col-xs-12 col-md-12 input-wrapper">
216 <div class="icon-circle-x"> 222 <div class="icon-circle-x">
217 <i class="material-icons" style="line-height: 30px;">line_weight</i> 223 <i class="material-icons" style="line-height: 30px;">line_weight</i>
218 </div> 224 </div>
219 <textarea name="intro" class="text-input textarea" ng-model="data.intro" placeholder="Your Answer.." maxlength="200" ng-change="enterproblem(data.intro); startupNamekeyPress(data.intro)" required></textarea> 225 <textarea name="intro" class="text-input textarea" ng-model="data.intro" placeholder="Your Answer.." maxlength="200" ng-change="enterproblem(data.intro); startupNamekeyPress(data.intro)" required></textarea>
220 </div> 226 </div>
221 <div class="col-xs-12 col-md-12 f-family line-adjust"> 227 <div class="col-xs-12 col-md-12 f-family line-adjust">
222 <strong>Who are your customers? *</strong> 228 <strong>Who are your customers? *</strong>
223 <p class="line-space" >We are looking for a simple and clear answer of who you are selling to (characters limit - 512).</p> 229 <p class="line-space" >We are looking for a simple and clear answer of who you are selling to (characters limit - 512).</p>
224 </div> 230 </div>
225 <div class="col-xs-12 col-md-12 input-wrapper"> 231 <div class="col-xs-12 col-md-12 input-wrapper">
226 <div class="icon-circle-k"> 232 <div class="icon-circle-k">
227 <i class="material-icons" style="line-height: 30px;">help</i> 233 <i class="material-icons" style="line-height: 30px;">help</i>
228 </div> 234 </div>
229 <textarea name="customer" class="text-input textarea" ng-model="data.customer" placeholder="Your Answer.." maxlength="512" ng-change="entersolution(data.customer); websitekeyPress(data.customer)" required></textarea> 235 <textarea name="customer" class="text-input textarea" ng-model="data.customer" placeholder="Your Answer.." maxlength="512" ng-change="entersolution(data.customer); websitekeyPress(data.customer)" required></textarea>
230 </div> --> 236 </div> -->
231 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust"> 237 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust">
232 <strong>What problem you are solving for them? *</strong> 238 <strong>What problem you are solving for them? *</strong>
233 <p class="line-space" >We want to understand how clearly you know the pain point, and how big of a problem it is for the customers.</p> 239 <p class="line-space" >We want to understand how clearly you know the pain point, and how big of a problem it is for the customers.</p>
234 </div> 240 </div>
235 <div class="col-xs-12 col-md-12 input-wrapper f-family"> 241 <div class="col-xs-12 col-md-12 input-wrapper f-family">
236 <div class="icon-circle-p"> 242 <div class="icon-circle-p">
237 <i class="material-icons" style="line-height: 30px;">business_center</i> 243 <i class="material-icons" style="line-height: 30px;">business_center</i>
238 </div> 244 </div>
239 <textarea name="problem" class="text-input textarea" ng-model="data.problem" placeholder="Your Answer.." ng-change="enterbusiness(data.problem); businesskeyPress(data.problem)" required> 245 <textarea name="problem" class="text-input textarea" ng-model="data.problem" placeholder="Your Answer.." ng-change="enterbusiness(data.problem); businesskeyPress(data.problem)" required>
240 </textarea> 246 </textarea>
241 </div> --> 247 </div> -->
242 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust"> 248 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust">
243 <strong>Link your pitch deck presentation. *</strong> 249 <strong>Link your pitch deck presentation. *</strong>
244 <p class="line-space" > Kindly upload the link to your pitch deck (Dropbox/Google Drive, if on google drive make the link open to all).</p> 250 <p class="line-space" > Kindly upload the link to your pitch deck (Dropbox/Google Drive, if on google drive make the link open to all).</p>
245 </div> 251 </div>
246 <div class="col-xs-12 col-md-12 input-wrapper f-family"> 252 <div class="col-xs-12 col-md-12 input-wrapper f-family">
247 <div class="icon-circle-h"> 253 <div class="icon-circle-h">
248 <i class="material-icons" style="line-height: 30px;">web</i> 254 <i class="material-icons" style="line-height: 30px;">web</i>
249 </div> 255 </div>
250 <input name="link" class="text-input" ng-pattern="/^(http[s]?:\/\/){0,1}(www\.){0,1}[a-zA-Z0-9\.\-]+\.[a-zA-Z]{2,5}[\.]{0,1}/" ng-blur="emailcheck(data.link)" ng-focus="removeError()" ng-model="data.link" placeholder="link" ng-change="enterbusiness(data.link); linkedInkeyPress(data.link)" required> 256 <input name="link" class="text-input" ng-pattern="/^(http[s]?:\/\/){0,1}(www\.){0,1}[a-zA-Z0-9\.\-]+\.[a-zA-Z]{2,5}[\.]{0,1}/" ng-blur="emailcheck(data.link)" ng-focus="removeError()" ng-model="data.link" placeholder="link" ng-change="enterbusiness(data.link); linkedInkeyPress(data.link)" required>
251 <label class="error-message f-family" id="invalidEmail">Please enter a valid link.</label> 257 <label class="error-message f-family" id="invalidEmail">Please enter a valid link.</label>
252 </div> --> 258 </div> -->
253 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust"> 259 <!-- <div class="col-xs-12 col-md-12 f-family line-adjust">
254 <strong>Coupon Code.</strong> 260 <strong>Coupon Code.</strong>
255 <p class="line-space" >Only applicable for venue partner ecosystem</p> 261 <p class="line-space" >Only applicable for venue partner ecosystem</p>
256 </div> 262 </div>
257 <div class="col-xs-12 input-wrapper"> 263 <div class="col-xs-12 input-wrapper">
258 <div class="referel-icon" style="z-index: 999;"> 264 <div class="referel-icon" style="z-index: 999;">
259 <i class="material-icons" style="line-height: 30px;">code</i> 265 <i class="material-icons" style="line-height: 30px;">code</i>
260 </div> 266 </div>
261 <input class="text-input" ng-model="data.referalToken" placeholder="Enter Coupon code" style="position: relative;" ng-required="referalToken" ng-change="changeReferalIconColor(data.referalToken)"> 267 <input class="text-input" ng-model="data.referalToken" placeholder="Enter Coupon code" style="position: relative;" ng-required="referalToken" ng-change="changeReferalIconColor(data.referalToken)">
262 <i class="material-icons coupen-approved" ng-if="tokencheck == true">check</i> 268 <i class="material-icons coupen-approved" ng-if="tokencheck == true">check</i>
263 <i class="material-icons coupen-approved" style="color:red;" ng-if="tokencheck == false">close</i> 269 <i class="material-icons coupen-approved" style="color:red;" ng-if="tokencheck == false">close</i>
264 <button type="button" ng-click="tokenCall(data.referalToken)" class="pull-right apply-coupen-btn">Apply</button> 270 <button type="button" ng-click="tokenCall(data.referalToken)" class="pull-right apply-coupen-btn">Apply</button>
265 </div> --> 271 </div> -->
266 <div class="clearfix"></div> 272 <!-- <div class="clearfix"></div> -->
267 <!-- </div> --> 273 <!-- </div> -->
268 <!-- close step-one-form --> 274 <!-- close step-one-form -->
269 <!-- </td> 275 <!-- </td>
270 </tr> 276 </tr>
271 </table> --> 277 </table> -->
272 <div class="text-center"> 278 <!-- <div class="text-center">
273 <input type="submit" class="btn submit-button-form" ng-disabled="applicantForm.$invalid" value="Submit" ng-click="submit()"> 279 <input type="submit" class="btn submit-button-form" ng-disabled="applicantForm.$invalid || filePicker" value="Submit" ng-click="submit()">
274 </div> 280 </div>
275 </div> 281 </div> -->
276 <!-- CLOSE form-all --> 282 <!-- CLOSE form-all -->
277 <!-- </div> --> 283 <!-- </div> -->
278 <!-- <div class="clearfix"></div> 284 <!-- <div class="clearfix"></div>
279 <div class="text-center"> 285 <div class="text-center">
280 <input type="submit" class="btn submit-button-form" ng-disabled="applicantForm.$invalid" value="Submit" ng-click="submit()"> 286 <input type="submit" class="btn submit-button-form" ng-disabled="applicantForm.$invalid" value="Submit" ng-click="submit()">
281 </div> --> 287 </div> -->
282 </div> 288 </div>
283 <div class="text-center">
284 <input type="submit" class="btn submit-button-form" value="Submit" ng-click="click()">
285 </div>
286 <!-- col-xs-12 col-md-8 col-md-offset-2 --> 289 <!-- col-xs-12 col-md-8 col-md-offset-2 -->
287 <!-- <footer> 290 <!-- <footer>
288 <img id="footer" class="img-responsive banner"> 291 <img id="footer" class="img-responsive banner">
289 <center class="footer"><a class="footer-link" href="http://www.viithiisys.com/" target="_blank"></a> 292 <center class="footer"><a class="footer-link" href="http://www.viithiisys.com/" target="_blank"></a>
290 </center> 293 </center>
291 </footer> --> 294 </footer> -->
292 </form> 295 </form>
293 <!-- CLOSE FORM --> 296 <!-- CLOSE FORM -->
294 <!-- </div> CLOSE CHECK VIEW --> 297 <!-- </div> CLOSE CHECK VIEW -->
295 <span ng-show="span == true"> 298 <span ng-show="span == true">
296 <span id="chennai"></span> 299 <span id="chennai"></span>
297 <span id="mumbai"></span> 300 <span id="mumbai"></span>
298 <span id="hyderabad"></span> 301 <span id="hyderabad"></span>
299 <span id="kolkata"></span> 302 <span id="kolkata"></span>
300 <span id="delhi"></span> 303 <span id="delhi"></span>
301 <span id="ahmedabad"></span> 304 <span id="ahmedabad"></span>
302 <span id="bengaluru"></span> 305 <span id="bengaluru"></span>
303 <span id="jaipur"></span>kanpur 306 <span id="jaipur"></span>kanpur
304 <span id="kanpur"></span> 307 <span id="kanpur"></span>
1 // create the module and name it scotchApp 1 // create the module and name it scotchApp
2 var scotchApp = angular.module('scotchApp', ['ngRoute','angular-google-analytics']); 2 var scotchApp = angular.module('scotchApp', ['ngRoute','angular-google-analytics']);
3 3
4 // configure our routes 4 // configure our routes
5 scotchApp.config(function($routeProvider,$locationProvider) { 5 scotchApp.config(function($routeProvider,$locationProvider) {
6 6
7 // use the HTML5 History API 7 // use the HTML5 History API
8 // $locationProvider.html5Mode({ 8 // $locationProvider.html5Mode({
9 // enabled: true, 9 // enabled: true,
10 // requireBase: false 10 // requireBase: false
11 // }); 11 // });
12 //$locationProvider.hashPrefix('!'); 12 //$locationProvider.hashPrefix('!');
13 $routeProvider 13 $routeProvider
14 // route for the Home page 14 // route for the Home page
15 .when('/', { 15 .when('/', {
16 templateUrl: 'pages/Home.html', 16 templateUrl: 'pages/Home.html',
17 controller: 'mainController' 17 controller: 'mainController'
18 }) 18 })
19 19
20 // route for the caricatures page 20 // route for the caricatures page
21 .when('/caricatures', { 21 .when('/caricatures', {
22 templateUrl: 'pages/caricatures.html', 22 templateUrl: 'pages/caricatures.html',
23 controller: 'mainController' 23 controller: 'mainController'
24 }) 24 })
25 25
26 // route for the paymentVerify page 26 // route for the paymentVerify page
27 .when('/pendingPayment/:id', { 27 .when('/pendingPayment/:id', {
28 templateUrl: 'pages/verify.html', 28 templateUrl: 'pages/verify.html',
29 controller: 'verifyController' 29 controller: 'verifyController'
30 }) 30 })
31 31
32 // route for the registration page 32 // route for the registration page
33 .when('/registration', { 33 .when('/registration', {
34 templateUrl: 'pages/registration.html', 34 templateUrl: 'pages/registration.html',
35 controller: 'registrationController' 35 controller: 'registrationController'
36 }) 36 })
37 37
38 //route for the ambassador page 38 //route for the ambassador page
39 // .when('/startupJalsaPromocode', { 39 // .when('/startupJalsaPromocode', {
40 // templateUrl: 'pages/ambassador.html', 40 // templateUrl: 'pages/ambassador.html',
41 // controller: 'ambassadorController' 41 // controller: 'ambassadorController'
42 // }) 42 // })
43 43
44 // route for the confirmation page 44 // route for the confirmation page
45 .when('/confirmation', { 45 .when('/confirmation', {
46 templateUrl: 'pages/confirmation.html', 46 templateUrl: 'pages/confirmation.html',
47 controller: 'registrationController' 47 controller: 'registrationController'
48 }) 48 })
49 49
50 .otherwise({ 50 .otherwise({
51 redirectTo: '/' 51 redirectTo: '/'
52 }); 52 });
53 53
54 }); 54 });
55 55
56 scotchApp.config(['AnalyticsProvider', function (AnalyticsProvider) { 56 scotchApp.config(['AnalyticsProvider', function (AnalyticsProvider) {
57 // Add configuration code as desired 57 // Add configuration code as desired
58 AnalyticsProvider.setAccount('UA-106416759-1'); //UU-XXXXXXX-X should be your tracking code 58 AnalyticsProvider.setAccount('UA-106416759-1'); //UU-XXXXXXX-X should be your tracking code
59 59
60 // Track all routes (default is true). 60 // Track all routes (default is true).
61 AnalyticsProvider.trackPages(true); 61 AnalyticsProvider.trackPages(true);
62 62
63 // Track all URL query params (default is false). 63 // Track all URL query params (default is false).
64 AnalyticsProvider.trackUrlParams(true); 64 AnalyticsProvider.trackUrlParams(true);
65 65
66 }]).run(['Analytics', function(Analytics) { }]); 66 }]).run(['Analytics', function(Analytics) { }]);
67 67
68 scotchApp.constant("BASE_URL", "http://35.154.24.158:4001/v1") 68 scotchApp.constant("BASE_URL", "http://35.154.24.158:4001/v1")
69 //scotchApp.constant("BASE_URL", "http://0.0.0.0:4001/v1") 69 //scotchApp.constant("BASE_URL", "http://0.0.0.0:4001/v1")
70 70
71 scotchApp.directive('validFile',function(){
72 return {
73 require:'ngModel',
74 link:function(scope,el,attrs,ngModel){
75 //change event is fired when file is selected
76 el.bind('change',function(){
77 scope.$apply(function(){
78 ngModel.$setViewValue(el.val());
79 ngModel.$render();
80 })
81 })
82 }
83 }
84 })
85
71 // create the controller and inject Angular's $scope 86 // create the controller and inject Angular's $scope
72 scotchApp.controller('mainController', function($scope, $http, $window, $location, $route, $rootScope, BASE_URL, Analytics) { 87 scotchApp.controller('mainController', function($scope, $http, $window, $location, $route, $rootScope, BASE_URL, Analytics) {
73 $scope.data = { 88 $scope.data = {
74 show: true, 89 show: true,
75 hide: false 90 hide: false
76 }; 91 };
77 window.onload = function(){ 92 window.onload = function(){
78 var element = document.getElementById("defaultcountry"); 93 var element = document.getElementById("defaultcountry");
79 element.classList.add("btn-active"); 94 element.classList.add("btn-active");
80 //document.getElementById("ahmedabad").src = "images/Ahmedabad_1.png"; 95 //document.getElementById("ahmedabad").src = "images/Ahmedabad_1.png";
81 } 96 }
82 97
83 var chennai = new Date("Sept 19, 2018 12:00:00").getTime(); 98 var chennai = new Date("Sept 19, 2018 12:00:00").getTime();
84 // Update the count down every 1 second 99 // Update the count down every 1 second
85 var x = setInterval(function() { 100 var x = setInterval(function() {
86 // Get todays date and time 101 // Get todays date and time
87 var now = new Date().getTime(); 102 var now = new Date().getTime();
88 // Find the distance between now an the count down date 103 // Find the distance between now an the count down date
89 var distance = chennai - now; 104 var distance = chennai - now;
90 // Time calculations for days, hours, minutes and seconds 105 // Time calculations for days, hours, minutes and seconds
91 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 106 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
92 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 107 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
93 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 108 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
94 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 109 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
95 $scope.timer = days + "d " + hours + "h " 110 $scope.timer = days + "d " + hours + "h "
96 + minutes + "m " + seconds + "s " 111 + minutes + "m " + seconds + "s "
97 // Output the result in an element with id="demo" 112 // Output the result in an element with id="demo"
98 document.getElementById("chennai").innerHTML = days + "d " + hours + "h " 113 document.getElementById("chennai").innerHTML = days + "d " + hours + "h "
99 + minutes + "m " + seconds + "s "; 114 + minutes + "m " + seconds + "s ";
100 // If the count down is over, write some text 115 // If the count down is over, write some text
101 if (distance < 0) { 116 if (distance < 0) {
102 clearInterval(x); 117 clearInterval(x);
103 document.getElementById("chennai").innerHTML = "EXPIRED"; 118 document.getElementById("chennai").innerHTML = "EXPIRED";
104 } 119 }
105 }, 1000); 120 }, 1000);
106 121
107 var hyderabad = new Date("Sept 22, 2018 14:00:00").getTime(); 122 var hyderabad = new Date("Sept 22, 2018 14:00:00").getTime();
108 // Update the count down every 1 second 123 // Update the count down every 1 second
109 var x = setInterval(function() { 124 var x = setInterval(function() {
110 // Get todays date and time 125 // Get todays date and time
111 var now = new Date().getTime(); 126 var now = new Date().getTime();
112 // Find the distance between now an the count down date 127 // Find the distance between now an the count down date
113 var distance = hyderabad - now; 128 var distance = hyderabad - now;
114 // Time calculations for days, hours, minutes and seconds 129 // Time calculations for days, hours, minutes and seconds
115 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 130 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
116 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 131 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
117 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 132 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
118 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 133 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
119 $scope.timer = days + "d " + hours + "h " 134 $scope.timer = days + "d " + hours + "h "
120 + minutes + "m " + seconds + "s " 135 + minutes + "m " + seconds + "s "
121 // Output the result in an element with id="demo" 136 // Output the result in an element with id="demo"
122 document.getElementById("hyderabad").innerHTML = days + "d " + hours + "h " 137 document.getElementById("hyderabad").innerHTML = days + "d " + hours + "h "
123 + minutes + "m " + seconds + "s "; 138 + minutes + "m " + seconds + "s ";
124 // If the count down is over, write some text 139 // If the count down is over, write some text
125 if (distance < 0) { 140 if (distance < 0) {
126 clearInterval(x); 141 clearInterval(x);
127 document.getElementById("hyderabad").innerHTML = "EXPIRED"; 142 document.getElementById("hyderabad").innerHTML = "EXPIRED";
128 } 143 }
129 }, 1000); 144 }, 1000);
130 145
131 var mumbai = new Date("Sept 26, 2018 14:00:00").getTime(); 146 var mumbai = new Date("Sept 26, 2018 14:00:00").getTime();
132 // Update the count down every 1 second 147 // Update the count down every 1 second
133 var x = setInterval(function() { 148 var x = setInterval(function() {
134 // Get todays date and time 149 // Get todays date and time
135 var now = new Date().getTime(); 150 var now = new Date().getTime();
136 // Find the distance between now an the count down date 151 // Find the distance between now an the count down date
137 var distance = mumbai - now; 152 var distance = mumbai - now;
138 // Time calculations for days, hours, minutes and seconds 153 // Time calculations for days, hours, minutes and seconds
139 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 154 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
140 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 155 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
141 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 156 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
142 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 157 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
143 $scope.timer = days + "d " + hours + "h " 158 $scope.timer = days + "d " + hours + "h "
144 + minutes + "m " + seconds + "s " 159 + minutes + "m " + seconds + "s "
145 // Output the result in an element with id="demo" 160 // Output the result in an element with id="demo"
146 document.getElementById("mumbai").innerHTML = days + "d " + hours + "h " 161 document.getElementById("mumbai").innerHTML = days + "d " + hours + "h "
147 + minutes + "m " + seconds + "s "; 162 + minutes + "m " + seconds + "s ";
148 // If the count down is over, write some text 163 // If the count down is over, write some text
149 if (distance < 0) { 164 if (distance < 0) {
150 clearInterval(x); 165 clearInterval(x);
151 document.getElementById("mumbai").innerHTML = "EXPIRED"; 166 document.getElementById("mumbai").innerHTML = "EXPIRED";
152 } 167 }
153 }, 1000); 168 }, 1000);
154 169
155 var kolkata = new Date("Oct 3, 2018 14:00:00").getTime(); 170 var kolkata = new Date("Oct 3, 2018 14:00:00").getTime();
156 // Update the count down every 1 second 171 // Update the count down every 1 second
157 var x = setInterval(function() { 172 var x = setInterval(function() {
158 // Get todays date and time 173 // Get todays date and time
159 var now = new Date().getTime(); 174 var now = new Date().getTime();
160 // Find the distance between now an the count down date 175 // Find the distance between now an the count down date
161 var distance = kolkata - now; 176 var distance = kolkata - now;
162 // Time calculations for days, hours, minutes and seconds 177 // Time calculations for days, hours, minutes and seconds
163 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 178 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
164 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 179 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
165 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 180 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
166 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 181 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
167 $scope.timer = days + "d " + hours + "h " 182 $scope.timer = days + "d " + hours + "h "
168 + minutes + "m " + seconds + "s " 183 + minutes + "m " + seconds + "s "
169 // Output the result in an element with id="demo" 184 // Output the result in an element with id="demo"
170 document.getElementById("kolkata").innerHTML = days + "d " + hours + "h " 185 document.getElementById("kolkata").innerHTML = days + "d " + hours + "h "
171 + minutes + "m " + seconds + "s "; 186 + minutes + "m " + seconds + "s ";
172 // If the count down is over, write some text 187 // If the count down is over, write some text
173 if (distance < 0) { 188 if (distance < 0) {
174 clearInterval(x); 189 clearInterval(x);
175 document.getElementById("kolkata").innerHTML = "EXPIRED"; 190 document.getElementById("kolkata").innerHTML = "EXPIRED";
176 } 191 }
177 }, 1000); 192 }, 1000);
178 193
179 var jaipur = new Date("Oct 5, 2018 14:00:00").getTime(); 194 var jaipur = new Date("Oct 5, 2018 14:00:00").getTime();
180 // Update the count down every 1 second 195 // Update the count down every 1 second
181 var x = setInterval(function() { 196 var x = setInterval(function() {
182 // Get todays date and time 197 // Get todays date and time
183 var now = new Date().getTime(); 198 var now = new Date().getTime();
184 // Find the distance between now an the count down date 199 // Find the distance between now an the count down date
185 var distance = jaipur - now; 200 var distance = jaipur - now;
186 // Time calculations for days, hours, minutes and seconds 201 // Time calculations for days, hours, minutes and seconds
187 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 202 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
188 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 203 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
189 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 204 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
190 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 205 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
191 $scope.timer = days + "d " + hours + "h " 206 $scope.timer = days + "d " + hours + "h "
192 + minutes + "m " + seconds + "s " 207 + minutes + "m " + seconds + "s "
193 // Output the result in an element with id="demo" 208 // Output the result in an element with id="demo"
194 document.getElementById("jaipur").innerHTML = days + "d " + hours + "h " 209 document.getElementById("jaipur").innerHTML = days + "d " + hours + "h "
195 + minutes + "m " + seconds + "s "; 210 + minutes + "m " + seconds + "s ";
196 // If the count down is over, write some text 211 // If the count down is over, write some text
197 if (distance < 0) { 212 if (distance < 0) {
198 clearInterval(x); 213 clearInterval(x);
199 document.getElementById("jaipur").innerHTML = "EXPIRED"; 214 document.getElementById("jaipur").innerHTML = "EXPIRED";
200 } 215 }
201 }, 1000); 216 }, 1000);
202 217
203 var delhi = new Date("Oct 8, 2018 14:00:00").getTime(); 218 var delhi = new Date("Oct 8, 2018 14:00:00").getTime();
204 // Update the count down every 1 second 219 // Update the count down every 1 second
205 var x = setInterval(function() { 220 var x = setInterval(function() {
206 // Get todays date and time 221 // Get todays date and time
207 var now = new Date().getTime(); 222 var now = new Date().getTime();
208 // Find the distance between now an the count down date 223 // Find the distance between now an the count down date
209 var distance = delhi - now; 224 var distance = delhi - now;
210 // Time calculations for days, hours, minutes and seconds 225 // Time calculations for days, hours, minutes and seconds
211 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 226 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
212 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 227 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
213 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 228 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
214 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 229 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
215 $scope.timer = days + "d " + hours + "h " 230 $scope.timer = days + "d " + hours + "h "
216 + minutes + "m " + seconds + "s " 231 + minutes + "m " + seconds + "s "
217 // Output the result in an element with id="demo" 232 // Output the result in an element with id="demo"
218 document.getElementById("delhi").innerHTML = days + "d " + hours + "h " 233 document.getElementById("delhi").innerHTML = days + "d " + hours + "h "
219 + minutes + "m " + seconds + "s "; 234 + minutes + "m " + seconds + "s ";
220 // If the count down is over, write some text 235 // If the count down is over, write some text
221 if (distance < 0) { 236 if (distance < 0) {
222 clearInterval(x); 237 clearInterval(x);
223 document.getElementById("delhi").innerHTML = "EXPIRED"; 238 document.getElementById("delhi").innerHTML = "EXPIRED";
224 } 239 }
225 }, 1000); 240 }, 1000);
226 241
227 var kanpur = new Date("Oct 10, 2018 14:00:00").getTime(); 242 var kanpur = new Date("Oct 10, 2018 14:00:00").getTime();
228 // Update the count down every 1 second 243 // Update the count down every 1 second
229 var x = setInterval(function() { 244 var x = setInterval(function() {
230 // Get todays date and time 245 // Get todays date and time
231 var now = new Date().getTime(); 246 var now = new Date().getTime();
232 // Find the distance between now an the count down date 247 // Find the distance between now an the count down date
233 var distance = kanpur - now; 248 var distance = kanpur - now;
234 // Time calculations for days, hours, minutes and seconds 249 // Time calculations for days, hours, minutes and seconds
235 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 250 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
236 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 251 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
237 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 252 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
238 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 253 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
239 $scope.timer = days + "d " + hours + "h " 254 $scope.timer = days + "d " + hours + "h "
240 + minutes + "m " + seconds + "s " 255 + minutes + "m " + seconds + "s "
241 // Output the result in an element with id="demo" 256 // Output the result in an element with id="demo"
242 document.getElementById("kanpur").innerHTML = days + "d " + hours + "h " 257 document.getElementById("kanpur").innerHTML = days + "d " + hours + "h "
243 + minutes + "m " + seconds + "s "; 258 + minutes + "m " + seconds + "s ";
244 // If the count down is over, write some text 259 // If the count down is over, write some text
245 if (distance < 0) { 260 if (distance < 0) {
246 clearInterval(x); 261 clearInterval(x);
247 document.getElementById("kanpur").innerHTML = "EXPIRED"; 262 document.getElementById("kanpur").innerHTML = "EXPIRED";
248 } 263 }
249 }, 1000); 264 }, 1000);
250 265
251 var ahmedabad = new Date("Oct 12, 2018 14:00:00").getTime(); 266 var ahmedabad = new Date("Oct 12, 2018 14:00:00").getTime();
252 // Update the count down every 1 second 267 // Update the count down every 1 second
253 var x = setInterval(function() { 268 var x = setInterval(function() {
254 // Get todays date and time 269 // Get todays date and time
255 var now = new Date().getTime(); 270 var now = new Date().getTime();
256 // Find the distance between now an the count down date 271 // Find the distance between now an the count down date
257 var distance = ahmedabad - now; 272 var distance = ahmedabad - now;
258 // Time calculations for days, hours, minutes and seconds 273 // Time calculations for days, hours, minutes and seconds
259 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 274 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
260 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 275 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
261 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 276 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
262 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 277 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
263 $scope.timer = days + "d " + hours + "h " 278 $scope.timer = days + "d " + hours + "h "
264 + minutes + "m " + seconds + "s " 279 + minutes + "m " + seconds + "s "
265 // Output the result in an element with id="demo" 280 // Output the result in an element with id="demo"
266 document.getElementById("ahmedabad").innerHTML = days + "d " + hours + "h " 281 document.getElementById("ahmedabad").innerHTML = days + "d " + hours + "h "
267 + minutes + "m " + seconds + "s "; 282 + minutes + "m " + seconds + "s ";
268 // If the count down is over, write some text 283 // If the count down is over, write some text
269 if (distance < 0) { 284 if (distance < 0) {
270 clearInterval(x); 285 clearInterval(x);
271 document.getElementById("ahmedabad").innerHTML = "EXPIRED"; 286 document.getElementById("ahmedabad").innerHTML = "EXPIRED";
272 } 287 }
273 }, 1000); 288 }, 1000);
274 289
275 var bengaluru = new Date("Oct 13, 2018 14:00:00").getTime(); 290 var bengaluru = new Date("Oct 13, 2018 14:00:00").getTime();
276 // Update the count down every 1 second 291 // Update the count down every 1 second
277 var x = setInterval(function() { 292 var x = setInterval(function() {
278 // Get todays date and time 293 // Get todays date and time
279 var now = new Date().getTime(); 294 var now = new Date().getTime();
280 // Find the distance between now an the count down date 295 // Find the distance between now an the count down date
281 var distance = bengaluru - now; 296 var distance = bengaluru - now;
282 // Time calculations for days, hours, minutes and seconds 297 // Time calculations for days, hours, minutes and seconds
283 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 298 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
284 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 299 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
285 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 300 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
286 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 301 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
287 $scope.timer = days + "d " + hours + "h " 302 $scope.timer = days + "d " + hours + "h "
288 + minutes + "m " + seconds + "s " 303 + minutes + "m " + seconds + "s "
289 // Output the result in an element with id="demo" 304 // Output the result in an element with id="demo"
290 document.getElementById("bengaluru").innerHTML = days + "d " + hours + "h " 305 document.getElementById("bengaluru").innerHTML = days + "d " + hours + "h "
291 + minutes + "m " + seconds + "s "; 306 + minutes + "m " + seconds + "s ";
292 // If the count down is over, write some text 307 // If the count down is over, write some text
293 if (distance < 0) { 308 if (distance < 0) {
294 clearInterval(x); 309 clearInterval(x);
295 document.getElementById("bengaluru").innerHTML = "EXPIRED"; 310 document.getElementById("bengaluru").innerHTML = "EXPIRED";
296 } 311 }
297 }, 1000); 312 }, 1000);
298 313
299 var dharamsala = new Date("Dec 14, 2018 14:00:00").getTime(); 314 var dharamsala = new Date("Dec 14, 2018 14:00:00").getTime();
300 // Update the count down every 1 second 315 // Update the count down every 1 second
301 var x = setInterval(function() { 316 var x = setInterval(function() {
302 // Get todays date and time 317 // Get todays date and time
303 var now = new Date().getTime(); 318 var now = new Date().getTime();
304 // Find the distance between now an the count down date 319 // Find the distance between now an the count down date
305 var distance = dharamsala - now; 320 var distance = dharamsala - now;
306 // Time calculations for days, hours, minutes and seconds 321 // Time calculations for days, hours, minutes and seconds
307 var days = Math.floor(distance / (1000 * 60 * 60 * 24)); 322 var days = Math.floor(distance / (1000 * 60 * 60 * 24));
308 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); 323 var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
309 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60)); 324 var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
310 var seconds = Math.floor((distance % (1000 * 60)) / 1000); 325 var seconds = Math.floor((distance % (1000 * 60)) / 1000);
311 $scope.timer = days + "d " + hours + "h " 326 $scope.timer = days + "d " + hours + "h "
312 + minutes + "m " + seconds + "s " 327 + minutes + "m " + seconds + "s "
313 // Output the result in an element with id="demo" 328 // Output the result in an element with id="demo"
314 document.getElementById("dharamsala").innerHTML = days + "d " + hours + "h " 329 document.getElementById("dharamsala").innerHTML = days + "d " + hours + "h "
315 + minutes + "m " + seconds + "s "; 330 + minutes + "m " + seconds + "s ";
316 // If the count down is over, write some text 331 // If the count down is over, write some text
317 if (distance < 0) { 332 if (distance < 0) {
318 clearInterval(x); 333 clearInterval(x);
319 document.getElementById("dharamsala").innerHTML = "EXPIRED"; 334 document.getElementById("dharamsala").innerHTML = "EXPIRED";
320 } 335 }
321 }, 1000); 336 }, 1000);
322 337
323 $scope.infoForm = false; /*THIS CODE FOR HIDE STEP 2 FORM*/ 338 $scope.infoForm = false; /*THIS CODE FOR HIDE STEP 2 FORM*/
324 $scope.space = false; /*THIS CODE FOR HIDE STEP 2 FORM*/ 339 $scope.space = false; /*THIS CODE FOR HIDE STEP 2 FORM*/
325 // $scope.Textshow = "yes" 340 // $scope.Textshow = "yes"
326 $scope.max = 100; 341 $scope.max = 100;
327 $scope.formPage = false; 342 $scope.formPage = false;
328 $scope.current = 0; 343 $scope.current = 0;
329 $scope.payingAmnt = 0; 344 $scope.payingAmnt = 0;
330 $scope.data = {}; 345 $scope.data = {};
331 $scope.discountAmount = 0; 346 $scope.discountAmount = 0;
332 // $scope.data.quantity = "1"; 347 // $scope.data.quantity = "1";
333 $scope.check = false; 348 $scope.check = false;
334 $scope.numberCheck = false; 349 $scope.numberCheck = false;
335 $scope.paymentResult = {}; 350 $scope.paymentResult = {};
336 var data = { 351 var data = {
337 "amount": $scope.payingAmnt, 352 "amount": $scope.payingAmnt,
338 "currency": "INR", 353 "currency": "INR",
339 "status": "pending" 354 "status": "pending"
340 } 355 }
341 356
342 $scope.showval = true; 357 $scope.showval = true;
343 $scope.hideval = false; 358 $scope.hideval = false;
344 $scope.showvalue = false; 359 $scope.showvalue = false;
345 $scope.hidevalue = false; 360 $scope.hidevalue = false;
346 $scope.isShowHide = function (value) { 361 $scope.isShowHide = function (value) {
347 console.log(value) 362 console.log(value)
348 var element = document.getElementById("defaultcountry"); 363 var element = document.getElementById("defaultcountry");
349 element.classList.remove("btn-active"); 364 element.classList.remove("btn-active");
350 365
351 if (value == "INDIA") { 366 if (value == "INDIA") {
352 console.log("value",value) 367 console.log("value",value)
353 $scope.showval = true; 368 $scope.showval = true;
354 $scope.hideval = false; 369 $scope.hideval = false;
355 $scope.showvalue = false; 370 $scope.showvalue = false;
356 $scope.hidevalue = false; 371 $scope.hidevalue = false;
357 } 372 }
358 else if (value == "SRI LANKA") { 373 else if (value == "SRI LANKA") {
359 console.log("value1",value) 374 console.log("value1",value)
360 $scope.showval = false; 375 $scope.showval = false;
361 $scope.hideval = true; 376 $scope.hideval = true;
362 $scope.showvalue = false; 377 $scope.showvalue = false;
363 $scope.hidevalue = false; 378 $scope.hidevalue = false;
364 } 379 }
365 else if (value == "BANGLADESH") { 380 else if (value == "BANGLADESH") {
366 console.log("value2",value) 381 console.log("value2",value)
367 $scope.showval = false; 382 $scope.showval = false;
368 $scope.hideval = false; 383 $scope.hideval = false;
369 $scope.showvalue = true; 384 $scope.showvalue = true;
370 $scope.hidevalue = false; 385 $scope.hidevalue = false;
371 } 386 }
372 else { 387 else {
373 console.log("value3",value) 388 console.log("value3",value)
374 $scope.showval = false; 389 $scope.showval = false;
375 $scope.hideval = false; 390 $scope.hideval = false;
376 $scope.showvalue = false; 391 $scope.showvalue = false;
377 $scope.hidevalue = true; 392 $scope.hidevalue = true;
378 } 393 }
379 } 394 }
380 395
381 // $scope.apply = function() { 396 // $scope.apply = function() {
382 // //Analytics.trackEvent('register', 'click', 'Registration'); 397 // //Analytics.trackEvent('register', 'click', 'Registration');
383 // $location.path("/caricatures") 398 // $location.path("/caricatures")
384 // } 399 // }
385 400
386 // $scope.data.city = ''; 401 // $scope.data.city = '';
387 $scope.watch = function(value){ 402 $scope.watch = function(value){
388 console.log(value) 403 console.log(value)
389 //document.getElementById("ahmedabad").src = ""; 404 //document.getElementById("ahmedabad").src = "";
390 // console.log("cllll",value) 405 // console.log("cllll",value)
391 $scope.data.city = value; 406 $scope.data.city = value;
392 // if($scope.data.city == "Chennai"){ 407 // if($scope.data.city == "Chennai"){
393 // console.log("cllll1",value) 408 // console.log("cllll1",value)
394 // $window.location.href = 'http://35.154.24.158:8007'; 409 // $window.location.href = 'http://35.154.24.158:8007';
395 // }else{ 410 // }else{
396 // console.log("cllll2",value) 411 // console.log("cllll2",value)
397 localStorage.setItem("city" ,value); 412 localStorage.setItem("city" ,value);
398 //$location.path('/registration').search({city: value}); 413 //$location.path('/registration').search({city: value});
399 // $location.path('/registration/'+value+''); 414 // $location.path('/registration/'+value+'');
400 $location.path('/registration'); 415 $location.path('/registration');
401 //$state.go('registration', { 'city': value}) 416 //$state.go('registration', { 'city': value})
402 // } 417 // }
403 } 418 }
404 419
405 $scope.select = function(url){ 420 $scope.select = function(url){
406 console.log("cllll") 421 console.log("cllll")
407 window.open(url) 422 window.open(url)
408 } 423 }
409 424
410 $scope.stagekeyPress = function() { 425 $scope.stagekeyPress = function() {
411 $('.icon-circle-a').css('background-color', 'rgb(25, 104, 157)'); 426 $('.icon-circle-a').css('background-color', 'rgb(25, 104, 157)');
412 } 427 }
413 $scope.sectorkeyPress = function() { 428 $scope.sectorkeyPress = function() {
414 $('.icon-circle-b').css('background-color', 'rgb(25, 104, 157)'); 429 $('.icon-circle-b').css('background-color', 'rgb(25, 104, 157)');
415 } 430 }
416 431
417 $scope.productLaunchkeyPress = function() { 432 $scope.productLaunchkeyPress = function() {
418 $('.icon-circle-ab').css('background-color', 'rgb(25, 104, 157)'); 433 $('.icon-circle-ab').css('background-color', 'rgb(25, 104, 157)');
419 } 434 }
420 435
421 $scope.launchPeriodkeyPress = function() { 436 $scope.launchPeriodkeyPress = function() {
422 $('.icon-circle-abc').css('background-color', 'rgb(25, 104, 157)'); 437 $('.icon-circle-abc').css('background-color', 'rgb(25, 104, 157)');
423 } 438 }
424 439
425 $scope.industrykeyPress = function(quantity) { 440 $scope.industrykeyPress = function(quantity) {
426 console.log("fghj",quantity) 441 console.log("fghj",quantity)
427 $('.icon-circle-abcdefg').css('background-color', 'rgb(25, 104, 157)'); 442 $('.icon-circle-abcdefg').css('background-color', 'rgb(25, 104, 157)');
428 } 443 }
429 444
430 $scope.industryNamekeyPress = function(firstName) { 445 $scope.industryNamekeyPress = function(firstName) {
431 console.log("lastName==", firstName); 446 console.log("lastName==", firstName);
432 if (firstName == undefined) { 447 if (firstName == undefined) {
433 $('.icon-circle-o').css('background-color', 'rgb(102, 102, 102)'); 448 $('.icon-circle-o').css('background-color', 'rgb(102, 102, 102)');
434 } else { 449 } else {
435 $('.icon-circle-o').css('background-color', 'rgb(25, 104, 157)'); 450 $('.icon-circle-o').css('background-color', 'rgb(25, 104, 157)');
436 } 451 }
437 } 452 }
438 453
439 $scope.amountkeyPress = function() { 454 $scope.amountkeyPress = function() {
440 $('.icon-circle-bc').css('background-color', 'rgb(25, 104, 157)'); 455 $('.icon-circle-bc').css('background-color', 'rgb(25, 104, 157)');
441 } 456 }
442 457
443 $scope.firstNamekeyPress = function(name) { 458 $scope.firstNamekeyPress = function(name) {
444 console.log("lastName==", name); 459 console.log("lastName==", name);
445 if (name == undefined) { 460 if (name == undefined) {
446 $('.icon-circle-c').css('background-color', 'rgb(102, 102, 102)'); 461 $('.icon-circle-c').css('background-color', 'rgb(102, 102, 102)');
447 } else { 462 } else {
448 $('.icon-circle-c').css('background-color', 'rgb(25, 104, 157)'); 463 $('.icon-circle-c').css('background-color', 'rgb(25, 104, 157)');
449 } 464 }
450 } 465 }
451 466
452 $scope.emailkeyPress = function(email) { 467 $scope.emailkeyPress = function(email) {
453 console.log("email", email); 468 console.log("email", email);
454 if (email == undefined) { 469 if (email == undefined) {
455 $('.icon-circle-d').css('background-color', 'rgb(102, 102, 102)'); 470 $('.icon-circle-d').css('background-color', 'rgb(102, 102, 102)');
456 } else { 471 } else {
457 $('.icon-circle-d').css('background-color', 'rgb(25, 104, 157)'); 472 $('.icon-circle-d').css('background-color', 'rgb(25, 104, 157)');
458 } 473 }
459 } 474 }
460 475
461 $scope.phonekeyPress = function(number) { 476 $scope.phonekeyPress = function(number) {
462 console.log("number", number); 477 console.log("number", number);
463 if (number == undefined || number == '') { 478 if (number == undefined || number == '') {
464 $('.icon-circle-e').css('background-color', 'rgb(102, 102, 102)'); 479 $('.icon-circle-e').css('background-color', 'rgb(102, 102, 102)');
465 } else { 480 } else {
466 $('.icon-circle-e').css('background-color', 'rgb(25, 104, 157)'); 481 $('.icon-circle-e').css('background-color', 'rgb(25, 104, 157)');
467 } 482 }
468 } 483 }
469 484
470 $scope.citykeyPress = function(city) { 485 $scope.citykeyPress = function(city) {
471 console.log("city", city); 486 console.log("city", city);
472 if (city == undefined) { 487 if (city == undefined) {
473 $('.icon-circle-f').css('background-color', 'rgb(102, 102, 102)'); 488 $('.icon-circle-f').css('background-color', 'rgb(102, 102, 102)');
474 } else { 489 } else {
475 $('.icon-circle-f').css('background-color', 'rgb(25, 104, 157)'); 490 $('.icon-circle-f').css('background-color', 'rgb(25, 104, 157)');
476 } 491 }
477 } 492 }
478 493
479 $scope.startupNamekeyPress = function(q) { 494 $scope.startupNamekeyPress = function(q) {
480 if (q == undefined) { 495 if (q == undefined) {
481 $('.icon-circle-x').css('background-color', 'rgb(102, 102, 102)'); 496 $('.icon-circle-x').css('background-color', 'rgb(102, 102, 102)');
482 } else { 497 } else {
483 $('.icon-circle-x').css('background-color', 'rgb(25, 104, 157)'); 498 $('.icon-circle-x').css('background-color', 'rgb(25, 104, 157)');
484 } 499 }
485 } 500 }
486 501
487 $scope.linkedInkeyPress = function(technology) { 502 $scope.linkedInkeyPress = function(technology) {
488 if (technology == undefined || technology == '') { 503 if (technology == undefined || technology == '') {
489 $('.icon-circle-h').css('background-color', 'rgb(102, 102, 102)'); 504 $('.icon-circle-h').css('background-color', 'rgb(102, 102, 102)');
490 } else { 505 } else {
491 $('.icon-circle-h').css('background-color', 'rgb(25, 104, 157)'); 506 $('.icon-circle-h').css('background-color', 'rgb(25, 104, 157)');
492 } 507 }
493 } 508 }
494 $scope.companykeyPress = function(problem) { 509 $scope.companykeyPress = function(problem) {
495 if (problem == undefined) { 510 if (problem == undefined) {
496 $('.icon-circle-i').css('background-color', 'rgb(102, 102, 102)'); 511 $('.icon-circle-i').css('background-color', 'rgb(102, 102, 102)');
497 } else { 512 } else {
498 $('.icon-circle-i').css('background-color', 'rgb(25, 104, 157)'); 513 $('.icon-circle-i').css('background-color', 'rgb(25, 104, 157)');
499 } 514 }
500 } 515 }
501 $scope.productNamekeyPress = function(solution) { 516 $scope.productNamekeyPress = function(solution) {
502 if (solution == undefined) { 517 if (solution == undefined) {
503 $('.icon-circle-j').css('background-color', 'rgb(102, 102, 102)'); 518 $('.icon-circle-j').css('background-color', 'rgb(102, 102, 102)');
504 } else { 519 } else {
505 $('.icon-circle-j').css('background-color', 'rgb(25, 104, 157)'); 520 $('.icon-circle-j').css('background-color', 'rgb(25, 104, 157)');
506 } 521 }
507 } 522 }
508 $scope.businesskeyPress = function(business) { 523 $scope.businesskeyPress = function(business) {
509 if (business == undefined) { 524 if (business == undefined) {
510 $('.icon-circle-p').css('background-color', 'rgb(102, 102, 102)'); 525 $('.icon-circle-p').css('background-color', 'rgb(102, 102, 102)');
511 } else { 526 } else {
512 $('.icon-circle-p').css('background-color', 'rgb(25, 104, 157)'); 527 $('.icon-circle-p').css('background-color', 'rgb(25, 104, 157)');
513 } 528 }
514 } 529 }
515 530
516 $scope.websitekeyPress = function(prototype) { 531 $scope.websitekeyPress = function(prototype) {
517 if (prototype == undefined || prototype == '') { 532 if (prototype == undefined || prototype == '') {
518 $('.icon-circle-k').css('background-color', 'rgb(102, 102, 102)'); 533 $('.icon-circle-k').css('background-color', 'rgb(102, 102, 102)');
519 } else { 534 } else {
520 $('.icon-circle-k').css('background-color', 'rgb(25, 104, 157)'); 535 $('.icon-circle-k').css('background-color', 'rgb(25, 104, 157)');
521 } 536 }
522 } 537 }
523 538
524 $scope.employeekeyPress = function(market) { 539 $scope.employeekeyPress = function(market) {
525 if (market == undefined || market == '') { 540 if (market == undefined || market == '') {
526 $('.icon-circle-l').css('background-color', 'rgb(102, 102, 102)'); 541 $('.icon-circle-l').css('background-color', 'rgb(102, 102, 102)');
527 } else { 542 } else {
528 $('.icon-circle-l').css('background-color', 'rgb(25, 104, 157)'); 543 $('.icon-circle-l').css('background-color', 'rgb(25, 104, 157)');
529 } 544 }
530 } 545 }
531 546
532 $scope.annualkeyPress = function(risk) { 547 $scope.annualkeyPress = function(risk) {
533 if (risk == undefined || risk == '') { 548 if (risk == undefined || risk == '') {
534 $('.icon-circle-m').css('background-color', 'rgb(102, 102, 102)'); 549 $('.icon-circle-m').css('background-color', 'rgb(102, 102, 102)');
535 } else { 550 } else {
536 $('.icon-circle-m').css('background-color', 'rgb(25, 104, 157)'); 551 $('.icon-circle-m').css('background-color', 'rgb(25, 104, 157)');
537 } 552 }
538 } 553 }
539 554
540 $scope.revenuekeyPress = function(team) { 555 $scope.revenuekeyPress = function(team) {
541 if (team == undefined) { 556 if (team == undefined) {
542 $('.icon-circle-n').css('background-color', 'rgb(102, 102, 102)'); 557 $('.icon-circle-n').css('background-color', 'rgb(102, 102, 102)');
543 } else { 558 } else {
544 $('.icon-circle-n').css('background-color', 'rgb(25, 104, 157)'); 559 $('.icon-circle-n').css('background-color', 'rgb(25, 104, 157)');
545 } 560 }
546 } 561 }
547 562
548 $scope.descriptionkeyPress = function(pitch) { 563 $scope.descriptionkeyPress = function(pitch) {
549 if (pitch == undefined) { 564 if (pitch == undefined) {
550 $('.icon-circle-z').css('background-color', 'rgb(102, 102, 102)'); 565 $('.icon-circle-z').css('background-color', 'rgb(102, 102, 102)');
551 } else { 566 } else {
552 $('.icon-circle-z').css('background-color', 'rgb(25, 104, 157)'); 567 $('.icon-circle-z').css('background-color', 'rgb(25, 104, 157)');
553 } 568 }
554 } 569 }
555 570
556 $scope.discountkeyPress = function(discount) { 571 $scope.discountkeyPress = function(discount) {
557 if (discount == undefined) { 572 if (discount == undefined) {
558 $('.icon-circle-o').css('background-color', 'rgb(102, 102, 102)'); 573 $('.icon-circle-o').css('background-color', 'rgb(102, 102, 102)');
559 } else { 574 } else {
560 $('.icon-circle-o').css('background-color', 'rgb(25, 104, 157)'); 575 $('.icon-circle-o').css('background-color', 'rgb(25, 104, 157)');
561 } 576 }
562 } 577 }
563 578
564 $scope.removeNooError = function() { 579 $scope.removeNooError = function() {
565 $('#invalidIdea').css('display', 'block'); 580 $('#invalidIdea').css('display', 'block');
566 $('#noExist').css('display', 'none'); 581 $('#noExist').css('display', 'none');
567 }; 582 };
568 583
569 $scope.ideakeyPress = function(financial) { 584 $scope.ideakeyPress = function(financial) {
570 console.log("financial", financial); 585 console.log("financial", financial);
571 if (financial == undefined) { 586 if (financial == undefined) {
572 $('.icon-circle-q').css('background-color', 'rgb(102, 102, 102)'); 587 $('.icon-circle-q').css('background-color', 'rgb(102, 102, 102)');
573 } else { 588 } else {
574 $('.icon-circle-q').css('background-color', 'rgb(25, 104, 157)'); 589 $('.icon-circle-q').css('background-color', 'rgb(25, 104, 157)');
575 } 590 }
576 } 591 }
577 592
578 $scope.fundkeyPress = function(financial) { 593 $scope.fundkeyPress = function(financial) {
579 console.log("financial", financial); 594 console.log("financial", financial);
580 if (financial == undefined) { 595 if (financial == undefined) {
581 $('.icon-circle-y').css('background-color', 'rgb(102, 102, 102)'); 596 $('.icon-circle-y').css('background-color', 'rgb(102, 102, 102)');
582 } else { 597 } else {
583 $('.icon-circle-y').css('background-color', 'rgb(25, 104, 157)'); 598 $('.icon-circle-y').css('background-color', 'rgb(25, 104, 157)');
584 } 599 }
585 } 600 }
586 601
587 $scope.changeReferalIconColor = function(referalToken){ 602 $scope.changeReferalIconColor = function(referalToken){
588 if (referalToken == undefined || referalToken == '') { 603 if (referalToken == undefined || referalToken == '') {
589 $('.referel-icon').css('background-color', 'rgb(102, 102, 102)'); 604 $('.referel-icon').css('background-color', 'rgb(102, 102, 102)');
590 }else { 605 }else {
591 $('.referel-icon').css('background-color', 'rgb(25, 104, 157)'); 606 $('.referel-icon').css('background-color', 'rgb(25, 104, 157)');
592 } 607 }
593 } 608 }
594 609
595 }); 610 });
596 611
597 scotchApp.controller('registrationController', function($q, $scope, $http, $location, $rootScope,$route,BASE_URL) { 612 scotchApp.controller('registrationController', function($q, $scope, $http, $location, $rootScope,$route,BASE_URL) {
598 $scope.data = {}; 613 $scope.data = {};
599 $scope.check = false; 614 $scope.check = false;
600 $scope.numberCheck = false; 615 $scope.numberCheck = false;
601 $scope.infoForm = false; /*THIS CODE FOR HIDE STEP 2 FORM*/ 616 $scope.infoForm = false; /*THIS CODE FOR HIDE STEP 2 FORM*/
602 $scope.space = false; /*THIS CODE FOR HIDE STEP 2 FORM*/ 617 $scope.space = false; /*THIS CODE FOR HIDE STEP 2 FORM*/
603 $scope.max = 100; 618 $scope.max = 100;
604 $scope.formPage = false; 619 $scope.formPage = false;
605 $scope.current = 0; 620 $scope.current = 0;
606 $scope.payingAmnt = 0; 621 $scope.payingAmnt = 0;
607 $scope.discountAmount = 0; 622 $scope.discountAmount = 0;
608 // $scope.data.quantity = "1"; 623 // $scope.data.quantity = "1";
609 $scope.check = false; 624 $scope.check = false;
610 $scope.numberCheck = false; 625 $scope.numberCheck = false;
611 $scope.paymentResult = {}; 626 $scope.paymentResult = {};
612 var data = { 627 var data = {
613 "amount": $scope.payingAmnt, 628 "amount": $scope.payingAmnt,
614 "currency": "INR", 629 "currency": "INR",
615 "status": "pending" 630 "status": "pending"
616 } 631 }
617 632
618 $scope.removeError = function() { 633 $scope.removeError = function() {
619 $('#invalidEmail').css('display', 'none'); 634 $('#invalidEmail').css('display', 'none');
620 $('#alreadyExist').css('display', 'none'); 635 $('#alreadyExist').css('display', 'none');
621 }; 636 };
622 637
623 $scope.emailcheck = function(val) { 638 $scope.emailcheck = function(val) {
624 if (val == undefined) { 639 if (val == undefined) {
625 $('#invalidEmail').css('display', 'block'); 640 $('#invalidEmail').css('display', 'block');
626 } else { 641 } else {
627 $('#alreadyExist').css('display', 'block'); 642 $('#alreadyExist').css('display', 'block');
628 } 643 }
629 }; 644 };
630 645
631 $scope.removeNoError = function() { 646 $scope.removeNoError = function() {
632 $('#invalidNumber').css('display', 'none'); 647 $('#invalidNumber').css('display', 'none');
633 $('#alreadyExist').css('display', 'none'); 648 $('#alreadyExist').css('display', 'none');
634 }; 649 };
635 650
636 $scope.numbercheck = function(val) { 651 $scope.numbercheck = function(val) {
637 if (val == undefined) { 652 if (val == undefined) {
638 $('#invalidNumber').css('display', 'block'); 653 $('#invalidNumber').css('display', 'block');
639 } else { 654 } else {
640 $('#alreadyExist').css('display', 'block'); 655 $('#alreadyExist').css('display', 'block');
641 } 656 }
642 }; 657 };
643 658
644 // $scope.$on('city', function (event, value) { 659 // $scope.$on('city', function (event, value) {
645 $scope.data.city = localStorage.getItem("city"); 660 $scope.data.city = localStorage.getItem("city");
646 // console.log("HERE===",$scope.data.city ); 661 // console.log("HERE===",$scope.data.city );
647 // }); 662 // });
663
648 var handleFileSelect = function(evt) { 664 var handleFileSelect = function(evt) {
649 var files = evt.target.files; 665 var files = evt.target.files;
650 var file = files[0]; 666 var file = files[0];
651 667
652 if (files && file) { 668 if (files && file) {
653 var reader = new FileReader(); 669 var reader = new FileReader();
654 670
655 reader.onload = function(readerEvt) { 671 reader.onload = function(readerEvt) {
656 var binaryString = readerEvt.target.result; 672 var binaryString = readerEvt.target.result;
657 $scope.base64textString = btoa(binaryString); 673 $scope.base64textString = btoa(binaryString);
658 //console.log("base64textarea",$scope.base64textString) 674 //console.log("base64textarea",$scope.base64textString)
659 $scope.data.uploadFile = file.name; 675 $scope.data.uploadFile = file.name;
660 }; 676 $scope.fileSelect = false;
677 if($scope.data.uploadFile == null){
678 $scope.fileSelect = true;
679 }else{
680 $scope.fileSelect = false;
681 };
682 }
661 683
662 reader.readAsBinaryString(file); 684 reader.readAsBinaryString(file);
663 } 685 }
664 }; 686 };
665 if (window.File && window.FileReader && window.FileList && window.Blob) { 687 if (window.File && window.FileReader && window.FileList && window.Blob) {
666 document.getElementById('filePicker').addEventListener('change', handleFileSelect, false); 688 document.getElementById('filePicker').addEventListener('change', handleFileSelect, false);
667 } 689 }
668 690
669 $scope.ngShowhide = false; 691 $scope.ngShowhide = false;
670 $scope.GetValue = function(){ 692 $scope.GetValue = function(){
671 console.log("====$scope.value===",$scope.data.sector) 693 console.log("====$scope.value===",$scope.data.sector)
672 if($scope.data.sector == "Other"){ 694 if($scope.data.sector == "Other"){
673 $scope.ngShowhide = true; 695 $scope.ngShowhide = true;
674 }else{ 696 }else{
675 $scope.ngShowhide = false; 697 $scope.ngShowhide = false;
676 } 698 }
677 } 699 }
678 700
679 // $rootScope.tokenCall = function(val) { 701 // $rootScope.tokenCall = function(val) {
680 // console.log('val-------->', val); 702 // console.log('val-------->', val);
681 // if (val == undefined) { 703 // if (val == undefined) {
682 // $('#invalidToken').css('display', 'block'); 704 // $('#invalidToken').css('display', 'block');
683 // } else { 705 // } else {
684 // val = val.toUpperCase(); 706 // val = val.toUpperCase();
685 // if((val == "IITH99" && $scope.data.city != "Hyderabad") || (val == "IITM99" && $scope.data.city != "Chennai") || (val == "IITD99" && $scope.data.city != "Delhi") || (val == "IITB99" && $scope.data.city != "Mumbai") || (val == "IITK99" && $scope.data.city != "Kanpur") || (val == "IIMC99" && $scope.data.city != "Kolkata") || (val == "IIMA99" && $scope.data.city != "Ahmedabad") || (val == "JAI40" && $scope.data.city != "Jaipur")){ 707 // if((val == "IITH99" && $scope.data.city != "Hyderabad") || (val == "IITM99" && $scope.data.city != "Chennai") || (val == "IITD99" && $scope.data.city != "Delhi") || (val == "IITB99" && $scope.data.city != "Mumbai") || (val == "IITK99" && $scope.data.city != "Kanpur") || (val == "IIMC99" && $scope.data.city != "Kolkata") || (val == "IIMA99" && $scope.data.city != "Ahmedabad") || (val == "JAI40" && $scope.data.city != "Jaipur")){
686 // $scope.tokencheck = false; 708 // $scope.tokencheck = false;
687 // return; 709 // return;
688 // } 710 // }
689 // $http.get(BASE_URL + '/ambassadors?filter={"where": {"referalToken": "' + val + '"}}') 711 // $http.get(BASE_URL + '/ambassadors?filter={"where": {"referalToken": "' + val + '"}}')
690 // .then(function(searchResult) { 712 // .then(function(searchResult) {
691 // console.log("searchResult",searchResult) 713 // console.log("searchResult",searchResult)
692 // if (searchResult.data.length == 0) { 714 // if (searchResult.data.length == 0) {
693 // $scope.tokencheck = false; 715 // $scope.tokencheck = false;
694 // $scope.discountAmount = 0; 716 // $scope.discountAmount = 0;
695 // } else { 717 // } else {
696 // console.log("===searchResult.data[0].discount===",searchResult.data[0].discount); 718 // console.log("===searchResult.data[0].discount===",searchResult.data[0].discount);
697 // $scope.discountpercentage = searchResult.data[0].discount; 719 // $scope.discountpercentage = searchResult.data[0].discount;
698 // console.log("===searchResultdiscountpercentage===",$scope.discountpercentage); 720 // console.log("===searchResultdiscountpercentage===",$scope.discountpercentage);
699 // $scope.tokencheck = true; 721 // $scope.tokencheck = true;
700 // } 722 // }
701 // },function(err){ 723 // },function(err){
702 // console.log(err) 724 // console.log(err)
703 // }); 725 // });
704 726
705 // } 727 // }
706 // }; 728 // };
707 $scope.click = function(){ 729 $scope.click = function(){
708 $http({ 730 $http({
709 method: 'GET', 731 method: 'GET',
710 url: "https://securegw.paytm.in/theia/processTransaction", 732 url: "https://securegw.paytm.in/theia/processTransaction",
711 headers: {} 733 headers: {}
712 }).then(function mySuccess(result) { 734 }).then(function mySuccess(result) {
713 console.log("rslt",result) 735 console.log("rslt",result)
714 }); 736 });
715 } 737 }
716 738
717 $scope.submit = function() { 739 $scope.submit = function() {
718 740
719 $scope.fileSelect = false;
720 if($scope.data.uploadFile == null){
721 $scope.fileSelect = true;
722 }else{
723 $scope.fileSelect = false;
724 $scope.ticketAmnt = 500;
725 // if($scope.tokencheck == false){ 741 // if($scope.tokencheck == false){
726 // $scope.data.referalToken = null; 742 // $scope.data.referalToken = null;
727 // } 743 // }
728 // if ($scope.data.name == undefined || $scope.data.email == undefined || $scope.data.number == undefined) { 744 // if ($scope.data.name == undefined || $scope.data.email == undefined || $scope.data.number == undefined) {
729 // var x = document.getElementById("snackbar") 745 // var x = document.getElementById("snackbar")
730 // setTimeout(function(){ x.className = x.className.replace("show", ""); }, 3000); 746 // setTimeout(function(){ x.className = x.className.replace("show", ""); }, 3000);
731 // }else if($scope.data.name != undefined && $scope.data.email != undefined && $scope.data.number != undefined) { 747 // }else if($scope.data.name != undefined && $scope.data.email != undefined && $scope.data.number != undefined) {
732 $scope.infoForm = true; 748 $scope.infoForm = true;
749 $scope.ticketAmnt = 500;
733 $scope.detail = {}; 750 $scope.detail = {};
734 $scope.data.phone = "+91"+$scope.data.number; 751 $scope.data.phone = "+91"+$scope.data.number;
735 // if($scope.data.referalToken == null){ 752 // if($scope.data.referalToken == null){
736 // $scope.data.referalToken = "N.A." 753 // $scope.data.referalToken = "N.A."
737 // } 754 // }
738 // var file =document.getElementById('filePicker').files[0]; 755 // var file =document.getElementById('filePicker').files[0];
739 // console.log("file",filePicker) 756 // console.log("file",filePicker)
740 // var image = BASE_URL+'/containers/applicants/download/' 757 // var image = BASE_URL+'/containers/applicants/download/'
741 // var imagePath = file.name; 758 // var imagePath = file.name;
742 // $scope.data.uploadFile = image + imagePath; 759 // $scope.data.uploadFile = image + imagePath;
743 // console.log($scope.data.uploadFile) 760 // console.log($scope.data.uploadFile)
744 // var fd = new FormData() 761 // var fd = new FormData()
745 // fd.append('filePicker',$scope.data); 762 // fd.append('filePicker',$scope.data);
746 // var deferred = $q.defer(); 763 // var deferred = $q.defer();
747 // $http({ 764 // $http({
748 // method:'POST', 765 // method:'POST',
749 // url: BASE_URL+'/containers/applicants/upload', 766 // url: BASE_URL+'/containers/applicants/upload',
750 // data:fd, 767 // data:fd,
751 // transformRequest:angular.identity, 768 // transformRequest:angular.identity,
752 // headers:{'Content-Type':undefined} 769 // headers:{'Content-Type':undefined}
753 // }) 770 // })
754 // .success(function(result){ 771 // .success(function(result){
755 // deferred.resolve(result); 772 // deferred.resolve(result);
756 $http({ 773 $http({
757 method: 'POST', 774 method: 'POST',
758 url: BASE_URL+'/applicants', 775 url: BASE_URL+'/applicants',
759 data: $scope.data, 776 data: $scope.data,
760 headers: {} 777 headers: {}
761 }).then(function mySuccess(result) { 778 }).then(function mySuccess(result) {
762 console.log("=====result=====",result) 779 console.log("=====result=====",result)
763 $scope.detail = result; 780 $scope.detail = result;
764 data.applicantId = result.data.id; 781 data.applicantId = result.data.id;
765 $scope.userId = result.data.id; 782 $scope.userId = result.data.id;
766 console.log("=====data=====",data) 783 console.log("=====data=====",data)
767 var amount = $scope.ticketAmnt * 100 784 var amount = $scope.ticketAmnt * 100
768 if($scope.tokencheck == true){ 785 if($scope.tokencheck == true){
769 var amount = $scope.ticketAmnt 786 var amount = $scope.ticketAmnt
770 console.log("====$scope.discountpercentage====",$scope.discountpercentage); 787 console.log("====$scope.discountpercentage====",$scope.discountpercentage);
771 console.log("resultcity===",$scope.data.city) 788 console.log("resultcity===",$scope.data.city)
772 if($scope.discountpercentage == "100") { 789 if($scope.discountpercentage == "100") {
773 $scope.discountpercentage = "99.8"; 790 $scope.discountpercentage = "99.8";
774 console.log("$scope.discountpercentage====",$scope.discountpercentage) 791 console.log("$scope.discountpercentage====",$scope.discountpercentage)
775 } 792 }
776 console.log("====$scope.discountpercentage====",$scope.discountpercentage); 793 console.log("====$scope.discountpercentage====",$scope.discountpercentage);
777 $scope.percDiscount = $scope.discountpercentage/100; 794 $scope.percDiscount = $scope.discountpercentage/100;
778 console.log("====$scope.percDiscount====",$scope.percDiscount); 795 console.log("====$scope.percDiscount====",$scope.percDiscount);
779 console.log("====amount=====",amount); 796 console.log("====amount=====",amount);
780 $scope.discountAmount = amount * $scope.percDiscount; 797 $scope.discountAmount = amount * $scope.percDiscount;
781 console.log("finalAmount====>",$scope.discountAmount) 798 console.log("finalAmount====>",$scope.discountAmount)
782 } 799 }
783 var taxAmount = $scope.ticketAmnt - $scope.discountAmount 800 var taxAmount = $scope.ticketAmnt - $scope.discountAmount
784 console.log("$scope.taxTotal----",taxAmount) 801 console.log("$scope.taxTotal----",taxAmount)
785 $scope.payingAmnt = taxAmount; 802 $scope.payingAmnt = taxAmount;
786 console.log("====$scope.payingAmnt====",$scope.payingAmnt) 803 console.log("====$scope.payingAmnt====",$scope.payingAmnt)
787 $scope.payingAmnt = $scope.payingAmnt.toFixed() 804 $scope.payingAmnt = $scope.payingAmnt.toFixed()
788 data.amount = $scope.payingAmnt; 805 data.amount = $scope.payingAmnt;
789 console.log("data.amount==",data.amount) 806 console.log("data.amount==",data.amount)
790 if($scope.detail != null){ 807 if($scope.detail != null){
791 $http({ 808 $http({
792 method: 'POST', 809 method: 'POST',
793 url: BASE_URL+'/payments', 810 url: BASE_URL+'/payments',
794 data: data, 811 data: data,
795 headers: {} 812 headers: {}
796 }).then(function mySuccess(paymentResult) { 813 }).then(function mySuccess(paymentResult) {
797 $scope.paymentResult = paymentResult; 814 $scope.paymentResult = paymentResult;
798 }, function myError(error) { 815 }, function myError(error) {
799 }); 816 });
800 } 817 }
801 var i = 0; 818 var i = 0;
802 $scope.payingAmnt = $scope.payingAmnt * 100; 819 $scope.payingAmnt = $scope.payingAmnt * 100;
803 var options = { 820 var options = {
804 //"key": "rzp_test_YwHsVFiDIQ2WUQ", 821 //"key": "rzp_test_YwHsVFiDIQ2WUQ",
805 "key": "rzp_live_mkmCb4FkstuWaS", 822 "key": "rzp_live_mkmCb4FkstuWaS",
806 "amount": $scope.payingAmnt, 823 "amount": $scope.payingAmnt,
807 824
808 "name": "Startup Jalsa", 825 "name": "Startup Jalsa",
809 "description":"amount", 826 "description":"amount",
810 "currency": "INR", 827 "currency": "INR",
811 "status": "done", 828 "status": "done",
812 829
813 "prefill": { 830 "prefill": {
814 "email": $scope.detail.email, 831 "email": $scope.detail.email,
815 "contact": $scope.detail.phone 832 "contact": $scope.detail.phone
816 }, 833 },
817 834
818 "theme": { 835 "theme": {
819 "color": "#2196f3 ", 836 "color": "#2196f3 ",
820 "image_padding":"NO" 837 "image_padding":"NO"
821 }, 838 },
822 "modal": { 839 "modal": {
823 "ondismiss": function(){ 840 "ondismiss": function(){
824 } 841 }
825 }, 842 },
826 "handler": function (response){ 843 "handler": function (response){
827 createPayment(response); 844 createPayment(response);
828 } 845 }
829 }; 846 };
830 var rzp1 = new Razorpay(options); 847 var rzp1 = new Razorpay(options);
831 rzp1.open(); 848 rzp1.open();
832 $scope.paymentResponse = {}; 849 $scope.paymentResponse = {};
833 function createPayment(response){ 850 function createPayment(response){
834 console.log("response12333333",response) 851 console.log("response12333333",response)
835 $scope.paymentResponse.razorPaymentId = response.razorpay_payment_id; 852 $scope.paymentResponse.razorPaymentId = response.razorpay_payment_id;
836 $scope.paymentResponse.razorOrderId = $scope.paymentResult.data.razorOrderId; 853 $scope.paymentResponse.razorOrderId = $scope.paymentResult.data.razorOrderId;
837 $scope.paymentResponse.amount = data.amount; 854 $scope.paymentResponse.amount = data.amount;
838 $scope.paymentResponse.currency = "INR"; 855 $scope.paymentResponse.currency = "INR";
839 $scope.paymentResponse.status = $scope.paymentResult.data.status; 856 $scope.paymentResponse.status = $scope.paymentResult.data.status;
840 console.log("$scope.paymentResponse.amount=====",$scope.paymentResponse.amount) 857 console.log("$scope.paymentResponse.amount=====",$scope.paymentResponse.amount)
841 $http({ 858 $http({
842 method: 'PUT', 859 method: 'PUT',
843 url: BASE_URL+'/payments/'+$scope.paymentResult.data.id, 860 url: BASE_URL+'/payments/'+$scope.paymentResult.data.id,
844 data: $scope.paymentResponse, 861 data: $scope.paymentResponse,
845 headers: {} 862 headers: {}
846 }).then(function mySuccess(searchResult) { 863 }).then(function mySuccess(searchResult) {
847 console.log("searchResult",searchResult) 864 console.log("searchResult",searchResult)
848 $location.path("/confirmation") 865 $location.path("/confirmation")
849 }, function myError(error) { 866 }, function myError(error) {
850 }); 867 });
851 } 868 }
852 //} 869 //}
853 870
854 }, function myError(error) { 871 }, function myError(error) {
855 872
856 }); 873 });
857
858 }
859 874
860 // }) 875 // })
861 876
862 //} 877 //}
863 878
864 } 879 }
865 880
866 }); 881 });
867 882
868 scotchApp.controller('ambassadorController', function($scope, $http, $location, $route,BASE_URL) { 883 scotchApp.controller('ambassadorController', function($scope, $http, $location, $route,BASE_URL) {
869 $scope.data = {}; 884 $scope.data = {};
870 $scope.check = false; 885 $scope.check = false;
871 $scope.numberCheck = false; 886 $scope.numberCheck = false;
872 887
873 $scope.submit = function() { 888 $scope.submit = function() {
874 console.log($scope.data.name) 889 console.log($scope.data.name)
875 var randomNumber = ""+Math.random(); 890 var randomNumber = ""+Math.random();
876 var nameSpliced = $scope.data.name.slice(0,5); 891 var nameSpliced = $scope.data.name.slice(0,5);
877 var numberSpliced = randomNumber.slice(2,4);; 892 var numberSpliced = randomNumber.slice(2,4);;
878 $scope.data.referalToken = nameSpliced+numberSpliced; 893 $scope.data.referalToken = nameSpliced+numberSpliced;
879 $scope.data.referalToken = $scope.data.referalToken.toUpperCase(); 894 $scope.data.referalToken = $scope.data.referalToken.toUpperCase();
880 console.log("dsdfs",numberSpliced); 895 console.log("dsdfs",numberSpliced);
881 $http({ 896 $http({
882 method: 'POST', 897 method: 'POST',
883 url: BASE_URL + '/ambassadors', 898 url: BASE_URL + '/ambassadors',
884 data: $scope.data, 899 data: $scope.data,
885 headers: {} 900 headers: {}
886 }).then(function mySuccess(result) { 901 }).then(function mySuccess(result) {
887 console.log("result", result) 902 console.log("result", result)
888 $scope.detail = result; 903 $scope.detail = result;
889 $('#myModal').modal('show'); 904 $('#myModal').modal('show');
890 $scope.data.name = ''; 905 $scope.data.name = '';
891 $scope.data.email = ''; 906 $scope.data.email = '';
892 $scope.data.mobile = ''; 907 $scope.data.mobile = '';
893 //$scope.data.discount = ''; 908 //$scope.data.discount = '';
894 909
895 }, function myError(error) { 910 }, function myError(error) {
896 console.log(error) 911 console.log(error)
897 console.log(error.data.error.message) 912 console.log(error.data.error.message)