[ create a new paste ] login | about

Link: http://codepad.org/baQewaaA    [ raw code | fork ]

Plain Text, pasted on Aug 29:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
<apex:page controller="CashVeriController" showHeader="false" standardStylesheets="false" sidebar="false" applyHtmlTag="false" applyBodyTag="false" docType="html-5.0">

    <html xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" lang="en">
    <head>
        <meta charset="utf-8" />
        
        <title>Salesforce Lightning Design System Trailhead Module</title>
        
        <meta http-equiv="x-ua-compatible" content="ie=edge" />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
        
            <apex:stylesheet value="{!URLFOR($Resource.SLDS203, 'assets/styles/salesforce-lightning-design-system-vf.css')}" />
            <apex:stylesheet value="{!URLFOR($Resource.SLDS203,' assets/styles/salesforce-lightning-design-system.min.css')}" />
            <apex:stylesheet value="{!URLFOR($Resource.SLDS203, 'assets/styles/salesforce-lightning-design-system-vf.min.css')}" />
            <apex:stylesheet value="{!URLFOR($Resource.SLDS203, 'assets/styles/salesforce-lightning-design-system.css')}" />
            <apex:stylesheet value="{!URLFOR($Resource.SLDS203, 'assets/styles/salesforce-lightning-design-system-ltng.css')}" />
            <apex:stylesheet value="{!URLFOR($Resource.SLDS203, 'assets/styles/salesforce-lightning-design-system-ltng.min.css')}" />
        
        <!-- BOOTSTRAP -->
        
        <apex:stylesheet value="//maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css"/>
        <apex:includeScript value="//code.jquery.com/jquery-2.1.4.min.js"/> 
        <apex:includeScript value="//maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"/>
        <apex:stylesheet value="{!$Resource.CCVer}" />
        
        <!-- BOOTSTRAP -->
        
        <apex:stylesheet value="{!URLFOR($Resource.TEST_SLDS203, 'assets/styles/salesforce-lightning-design-system-vf.min.css')}" />
        <!-- ALWAYS REMEMBER TO REPLACE THE STATIC RESOURCE (eg : SLDS203) WITH PROPER RESOURCE (eg : TEST_SLDS203) TO MAKE IT WORK -->


    <!-- audio file for button clicks -->
    <audio id="audio" src="{!URLFOR($Resource.Beep)}" autostart="false" ></audio>
    <!-- audio file for button clicks -->

    </head>

    <body id="bootstrapOverrides">

        <div id="topHeader" class="pstestsstuff">   <!-- CUSTOM SCOPING CLASS GOES HERE, IMPLEMENTED -->
        <div style="font-size: 3em; height:20px"></div>
            <h1  style="font-size: 2.7em; height:30px" class="slds-text-heading--medium slds-truncate">Cash Verification 1 – Welcome USER</h1>
             <div class="myapp">
              <div class="slds">
               <div class="slds-page-header">
                <div class="slds-grid">
                 <div class="slds-col slds-has-flexi-truncate">
                  <div class="slds-grid">
                   <div class="slds-grid slds-type-focus slds-no-space">
                    <h1 style="color:black ; font-size: 3.3em" class="slds-text-heading--medium slds-truncate">Enter Amount</h1>
                   </div>
                  </div>
                 </div>
                </div>
               </div>
              </div>
             </div>
            <!-- / PRIMARY CONTENT WRAPPER -->
            
            <div style="height:18px; width:100%">
                            <!-- SPACER 1 -->
            </div>
            
            <apex:form id="frm">
            
            <apex:pageMessages />
            
            <apex:actionstatus id="GetRecordsStatus">
                <apex:facet name="start">
                    <div class="waitingSearchDiv" id="el_loading" style="background-color: #fbfbfb; height: 100%;opacity:0.65;width:100%;">
                        <div class="slds-spinner_container">
                            <div class="slds-spinner--brand slds-spinner slds-spinner--medium" aria-hidden="false" role="alert">
                                <div class="slds-spinner__dot-a"></div>
                                <div class="slds-spinner__dot-b"></div>
                            </div>
                        </div>
                    </div>
                </apex:facet>
            </apex:actionstatus>
            <apex:outputPanel rendered="{!(!saveCashRecFlag)}">
                <div class="slds-card">
                    <div class="slds-card__header slds-grid">
                        <div class="slds-media slds-media--center slds-has-flexi-truncate">
                            <div class="slds-media__body">
                                <h2 style="font-size: 2.5em ; color: black" class="slds-text-heading--small slds-truncate">Scan Barcode</h2>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="slds-card__body ">
                    <div align="center">
                        <table width="100%">
                            <tr>
                                <td style="text-align: right; vertical-align: middle; padding: 2px 4px 2px;">
                                    <apex:inputText style="margin-top: 7px ; height: 40px ; color: black ; font-size: 22px; width:150px" value="{!barcodeKey}"/>
                                </td>
                                <td style="font-size: 5.5em ; color:black ; vertical-align: middle; margin-left:10px; padding: 2px 4px 2px;">
                                    <apex:commandButton id="btnSave" style="height: 40px ; font-size: 15px" styleClass="slds-button slds-button--neutral" value="Enter Barcode ID and Get GIFT Record" action="{!findEnvelope}" reRender="frm" status="GetRecordsStatus" />
                                </td>
                            </tr>
                        </table>
                    </div>
                    <apex:outputPanel id="listPanel">
                        <table class="slds-table slds-table--bordered slds-table--cell-buffer ">
                            <thead>
                                <tr style="font-size: 1.5em ; color: black" class="slds-text-heading--label">
                                    <th scope="col" title="Barcode ID">
                                        <div style="color:black" class="slds-truncate">Barcode ID</div>
                                    </th>
                                    <th scope="col" title="Verifier 1 Amount">
                                        <div style="color:black" class="slds-truncate">Verifier 1 Amount</div>
                                    </th>
                                    <th scope="col" title="Verifier 1 Status">
                                        <div style="color:black" class="slds-truncate">Verifier 1 Status</div>
                                    </th>
                                    <th scope="col" title="Date">
                                        <div style="color:black" class="slds-truncate">Date</div>
                                    </th>
                                </tr>
                            </thead>
                            <tbody>
                                <apex:repeat value="{!processedTransactionList}" var="cash">
                                <tr>
                                    <td scope="row" data-label="Barcode ID">
                                        <apex:outputField styleClass="slds-input" value="{!cash.Envelope__r.Barcode_ID__c}"/>
                                    </td>
                                    <td scope="row" data-label="Verifier 1 Amount">
                                        <apex:outputField styleClass="slds-input" value="{!cash.Verifier_1_Amount__c}"/>
                                    </td>
                                    <td scope="row" data-label="Verifier 1 Status">
                                        <apex:outputField styleClass="slds-input" value="{!cash.Verifier_1_Exception__c}"/>
                                    </td>
                                </tr>
                                </apex:repeat>
                            </tbody>
                        </table>
                    </apex:outputPanel>
                </div>
            </apex:outputPanel>
            
            <apex:outputPanel rendered="{!saveCashRecFlag}">
               
                        <div style="height:38px; width:100%">
                            <!-- SPACER 1 -->
                        </div>
  
            <div id="gridOfDivs" class="slds-grid slds-theme--default"> <!-- HOLDS 3 COLUMNS --> <!--  -->
                <div id="column" class="slds-col" style="width:8%"> <!-- FIRST COLUMN, HOLDS STATIC AMOUNT BUTTONS -->
                
                        <div style="height:28px; width:100%">
                            <!-- SPACER 1 -->
                        </div>
                    <div class="slds-align--absolute-center"> <!-- slds-align--absolute-center CENTERS THE ELEMENT IN ITS CONTAINER -->
                        <button type="button" id="lightbluebutton5" onclick="show_amt_leftbutton(10)" style="height:65px" class="button slds-size--3-of-5">10</button>
                    </div>
                        <div style="height:25px; width:100%">
                            <!-- SPACER 2 -->
                        </div>
                    <div class="slds-align--absolute-center">
                        <button type="button" id="lightbluebutton5" onclick="show_amt_leftbutton(50)" style="height:65px" class="button slds-size--3-of-5">50</button>
                    </div>
                        <div style="height:25px; width:100%">
                            <!-- SPACER 3 -->
                        </div>
                    <div class="slds-align--absolute-center">
                        <button type="button" id="lightbluebutton5" onclick="show_amt_leftbutton(100)" style="height:65px" class="button slds-size--3-of-5">100</button>
                    </div>
                        <div style="height:25px; width:100%">
                            <!-- SPACER 4 -->
                        </div>
                    <div class="slds-align--absolute-center">
                        <button type="button" id="lightbluebutton5" onclick="show_amt_leftbutton(500)" style="height:65px" class="button slds-size--3-of-5">500</button>
                    </div>
                        <div style="height:25px; width:100%">
                            <!-- SPACER 5 -->
                        </div>
                    <div class="slds-align--absolute-center">
                        <button type="button" id="lightbluebutton5" onclick="show_amt_leftbutton(1000)" style="height:65px" class="button slds-size--3-of-5">1000</button>
                    </div>
                        <div style="height:25px; width:100%">
                            <!-- SPACER 6 -->
                        </div>
                        
                </div>
                
                <div id="column" class="slds-col slds-theme--shade" style="width:25%"> <!-- SECOND COLUMN, HOLDS THE ACTUAL CALCULATOR BUTTONS + DISPLAY -->
                    <div style="height:19.666px; width:100%"> <!-- INNER DIV SPACER 1 -->
                    </div>
                        <div style="text-align:center ; width:100%" class="slds-theme--shade">
                        <p class="headerss" style="font-size: 3em">Amount</p>
                        </div>              
                    <div class="slds-theme--shade slds-size--1-of-1"> <!--  -->
                    
                            <div style="height:19.666px; width:100%"> <!-- INNER DIV SPACER 1 -->
                            </div>
                        <div class="slds-grid">
                                <div style="width:30px"> <!-- TEXTBOX SPACER 1 --> </div>
                            <div id="amount_screen" style="font-size: 3.1em ; height:42px ; color:black ; background:white" class="slds-box slds-theme--default slds-size--5-of-6 slds-align--absolute-center">
                                <!-- box, numbers go here -->
                                <!-- VERY IMPORTANT, THIS IS THE OUTPUT OF CLICKING BUTTONS -->
                                <!-- VERY IMPORTANT, THIS IS THE OUTPUT OF CLICKING BUTTONS -->
                                <!-- VERY IMPORTANT, THIS IS THE OUTPUT OF CLICKING BUTTONS -->
                                <!-- VERY IMPORTANT, THIS IS THE OUTPUT OF CLICKING BUTTONS -->
                                <!-- VERY IMPORTANT, THIS IS THE OUTPUT OF CLICKING BUTTONS -->
                            </div>
                                <div style="width:30px"> <!-- TEXTBOX SPACER 2 --> </div>
                        </div>
                            <div style="height:25.666px; width:100%"> <!-- INNER DIV SPACER 2 -->
                            </div>
                        <div class="slds-grid">
                                <div style="width:15px"> <!-- LINE 1 BUTTON SPACER 1 --> </div>
                            <div onclick="show_amt(7)" class="slds-col button bluebutton1 slds-align--absolute-center">7</div>
                                <div style="width:15px"> <!-- LINE 1 BUTTON SPACER 2 --> </div>
                            <div onclick="show_amt(8)" class="slds-col button bluebutton1 slds-align--absolute-center">8</div>
                                <div style="width:15px"> <!-- LINE 1 BUTTON SPACER 3 --> </div>
                            <div onclick="show_amt(9)" class="slds-col button bluebutton1 slds-align--absolute-center">9</div>
                                <div style="width:15px"> <!-- LINE 1 BUTTON SPACER 4 --> </div>
                        </div>
                            <div style="height:10.666px; width:100%"> <!-- INNER DIV SPACER 3 -->
                            </div>
                        <div class="slds-grid">
                                <div style="width:15px"> <!-- LINE 2 BUTTON SPACER 1 --> </div>
                            <div onclick="show_amt(4)" class="slds-col button bluebutton1 slds-align--absolute-center">4</div>
                                <div style="width:15px"> <!-- LINE 2 BUTTON SPACER 2 --> </div>
                            <div onclick="show_amt(5)" class="slds-col button bluebutton1 slds-align--absolute-center">5</div>
                                <div style="width:15px"> <!-- LINE 2 BUTTON SPACER 3 --> </div>
                            <div onclick="show_amt(6)" class="slds-col button bluebutton1 slds-align--absolute-center">6</div>
                                <div style="width:15px"> <!-- LINE 2 BUTTON SPACER 4 --> </div>
                        </div>
                            <div style="height:10.666px; width:100%"> <!-- INNER DIV SPACER 4 -->
                            </div>
                        <div class="slds-grid">
                                <div style="width:15px"> <!-- LINE 3 BUTTON SPACER 1 --> </div>
                            <div onclick="show_amt(1)" class="slds-col button bluebutton1 slds-align--absolute-center">1</div>
                                <div style="width:15px"> <!-- LINE 3 BUTTON SPACER 2 --> </div>
                            <div onclick="show_amt(2)" class="slds-col button bluebutton1 slds-align--absolute-center">2</div>
                                <div style="width:15px"> <!-- LINE 3 BUTTON SPACER 3 --> </div>
                            <div onclick="show_amt(3)" class="slds-col button bluebutton1 slds-align--absolute-center">3</div>
                                <div style="width:15px"> <!-- LINE 3 BUTTON SPACER 4 --> </div>
                        </div>
                            <div style="height:10.666px; width:100%"> <!-- INNER DIV SPACER 5 -->
                            </div>
                        <div class="slds-grid">
                                <div style="width:15px"> <!-- LINE 4 BUTTON SPACER 1 --> </div>
                            <div onclick="dot_amt()" class="slds-col button bluebutton1 slds-align--absolute-center">. </div>
                                <div style="width:15px"> <!-- LINE 4 BUTTON SPACER 2 --> </div>
                            <div onclick="show_amt(0)" class="slds-col button bluebutton1 slds-align--absolute-center">0</div>
                                <div style="width:15px"> <!-- LINE 4 BUTTON SPACER 3 --> </div>
                            <div id="yellowbutton" onclick="clr_amt()" class="slds-col button slds-align--absolute-center">C</div>
                                <div style="width:15px"> <!-- LINE 4 BUTTON SPACER 4 --> </div>
                        </div>
                            <div style="height:10.666px; width:100%"> <!-- INNER DIV SPACER 6 -->
                            </div>
                        
                    </div>
                        <div style="height:10.666px; width:100%">
                        </div>
                </div>
                
                <div id="column" class="slds-col slds-theme--default" style="width:10%"> <!-- THIRD COLUMN, HOLDS THE ACTION BUTTONS -->
                
                        <div style="height:114px">
                        </div>
                    <div class="slds-align--absolute-center">
                        <button type="button" id="redbutton" style="height:84px ; color:white" class="button slds-size--2-of-3 slds-p-around--small" data-toggle="modal" data-target="#myModal">Exception</button>
                        
    <!-- Modal --><!-- Modal --><!-- Modal --><!-- Modal --><!-- Modal -->
                        <div class="modal fade" id="myModal" role="dialog">
                        <div class="modal-dialog">

                        <!-- Modal content-->
                        <div class="modal-content">
                            <div class="modal-header modalHeadCSS">
                                <button type="button" class="close" data-dismiss="modal">&times;</button>
                                <h4 class="modal-title">Common Exceptions</h4>
                            </div>
                            <div class="modal-body modalBodyCSS">
                                <div>
                                        <div style="height:1.666px; width:100%">
                                        </div>
                                    <div class="slds-grid">
                                    <div class="slds-col">
                                        <div class="center bank">
                                            <input type="radio" name="radio" class="simpleradio"/>
                                            <label for="radio1">Envelope with cash missing.</label>
                                        </div>
        
                                        <div class="center bank">
                                            <input type="radio" name="radio" class="simpleradio"/>
                                            <label for="radio2">Cash greater than written amount.</label>
                                        </div>              

                                        <div class="center bank">   
                                            <input type="radio" name="radio" class="simpleradio"/>
                                            <label for="radio3">Cash less than written amount.</label>
                                        </div>

                                        <div class="center bank">   
                                            <input type="radio" name="radio" class="simpleradio"/>
                                            <label for="radio4">Others...</label>
                                        </div>
                                        <div>If Others Specify :</div>
                                        <div id="amount_screen" style="height:42px ; color:black ; background:white" class="slds-box slds-theme--default slds-size--1-of-1">
                                        </div>              
                                    </div>
                                    <div class="slds-col">
                                        <div class="slds-align--absolute-center">
                                            <button type="button" id="redbutton" style="font-size: 1.4em ; height:64px" class="button slds-size--2-of-3 slds-p-around--small">Cancel</button>
                                        </div>
                                       <div style="height: 40px"></div>
                                        <div class="slds-align--absolute-center">
                                            <button type="button" id="greenbutton" style="font-size: 1.4em ; height:64px" class="button slds-size--2-of-3 slds-p-around--small">Save</button>
                                        </div>
                                    </div>
                                    </div>
                                </div>
                            </div>
                            <div class="modal-footer modalFooterCSS">
                                <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
                            </div>
                        </div>
                
                        </div>
                        </div>
    <!-- Modal --><!-- Modal --><!-- Modal --><!-- Modal --><!-- Modal -->
                        
                    </div>
                        <div style="height:37px">
                        </div>
                        <div style="height:37px">
                        </div>
                    <div class="slds-align--absolute-center">
<!--                        <button type="button" id="greenbutton" style="height:84px" class="button slds-size--2-of-3 slds-p-around--small" onclick="MakeTransaction2('static_amount')">Enter</button> -->
                        <button type="button" id="greenbutton" style="height:84px" class="button slds-size--2-of-3 slds-p-around--small" onclick="JSCalltoController(static_amount)">Enter</button>
                    </div>              
                        <div style="height:27px">
                        </div>
                        
                </div>
            </div>
           
          
            <apex:actionFunction oncomplete="JSSetFlag" action="{!MakeTransaction}" name="JSCalltoController" rerender="myHiddenField">
                <apex:param name="static_amount" assignTo="{!VFPAmount1}" value="" />
            </apex:actionFunction>

             
             
            </apex:outputPanel>
        
            </apex:form>
            
        </div>
        <!-- END REQUIRED SLDS WRAPPER -->

        <!-- START JAVASCRIPT -->
        <script>
        
        var NumberedString;
        
        function JSSetFlag()
        {
            saveCashRecFlag = false;
        }
        
        function CallActionFunc()
        {
            //NumberedString = Math.floor(static_amount); //floor automatically converts string to number
            //NumberedString = Math.floor("static_amount"); //floor automatically converts string to number
            //NumberedString = parseInt("static_amount", 10); // you want to use radix 10
            //NumberedString = parseInt(static_amount, 10); // you want to use radix 10
            JSCalltoController(); 
        }
        
        var static_cheque = "";
        var static_amount = "";
        
            function show_amt_leftbutton(a)
            {
                static_amount = "";
                document.getElementById("amount_screen").innerHTML = a;
                var sound = document.getElementById("audio");
                sound.play();
            }
            
            function show_amt(a)
            {
                static_amount = ""+static_amount+a;
                document.getElementById("amount_screen").innerHTML = static_amount;
                var sound = document.getElementById("audio");
                sound.play();
            }
            
            function clr_amt(a)
            {
                static_amount = "";
                document.getElementById("amount_screen").innerHTML = static_amount;
                var sound = document.getElementById("audio");
                sound.play();
            }
            
            function dot_amt()
            {
                static_amount = ""+static_amount+".";
                document.getElementById("amount_screen").innerHTML = static_amount;
                var sound = document.getElementById("audio");
                sound.play();
            }
        </script>
        <!-- END JAVASCRIPT -->
    </body>
    </html>
    </apex:page>


Create a new paste based on this one


Comments: