-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dynamo_Client_Store_web_store.war_shared_js_ccLibs_paginated.js.html
executable file
·613 lines (538 loc) · 26.4 KB
/
Dynamo_Client_Store_web_store.war_shared_js_ccLibs_paginated.js.html
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
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>JSDoc: Source: Dynamo/Client/Store/web/store.war/shared/js/ccLibs/paginated.js</title>
<script src="scripts/prettify/prettify.js"> </script>
<script src="scripts/prettify/lang-css.js"> </script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
</head>
<body>
<div id="main">
<h1 class="page-title">Source: Dynamo/Client/Store/web/store.war/shared/js/ccLibs/paginated.js</h1>
<section>
<article>
<pre class="prettyprint source"><code>/**
* @fileoverview Provides Pagination functionality that can
* be used by different components to implement pagination
* and sorting
*
*/
/*global $, window */
define('paginated', ['knockout', 'pubsub'],
function(ko, PubSub) {
"use strict";
//-------------------------------------------------------
// View Model
//-------------------------------------------------------
/**
* Creates a paginated view model.
* @private
* @name Paginated
* @property {int} itemsPerPage The number of items to display per each page.
* @property {int} blockSize the number of products to get at once.
* @property {ObservableArray} data The paginated data.
* @property {Observable(int)} currentPage The current page being displayed.
* @property {Observable(int)} totalNumber The total number of products.
* @property {Observable(String)} sortDirectiveProp The sorting property.
* @property {Observable(String)} sortDirectiveOrder The sorting order of asc or desc.
* @class Paginated The paginated view model used to implement
* pagination and sorting functionality.
*/
function Paginated() {
this.defaultSort = 'displayName';
this.targetPage = 1;
this.clearOnLoad = false;
this.itemsPerPage = 40;
this.blockSize = 40;
this.pageBatchSize = 1;
this.data = ko.observableArray();
this.pageWindowSize = 5;
this.startIndex = 0;
this.lastIndex = this.pageWindowSize - 1;
this.pageIndex = 0;
this.middlePageOffset = 0;
this.focusPage = false;
/**
* Possible sorting options. Each sorting option should have:
* id: The property name to sort by.
* displayText: The display name of the property.
* order (observable): The asc/desc ordering of the property.
*/
this.sortOptions = ko.observableArray([]);
this.currentPage = ko.observable(0);
this.totalNumber = ko.observable(0);
this.data = ko.observableArray([]);
this.sortDirectiveProp = ko.observable('displayName');
this.sortDirectiveOrder = ko.observable('asc');
this.totalNumberOfPages = ko.observable(0);
this.pageStartIndex = ko.observable();
this.pageEndIndex = ko.observable();
this.clickedPage = ko.observable(-1);
this.pages = ko.computed(this.pagesFunction, this);
this.scrollToTop = true;
this.currentPage(1);
this.totalNumber(0);
this.sortDirectiveProp(this.defaultSort);
this.sortDirectiveOrder('asc');
this.totalNumberOfPages(0);
this.clickedPage(-1);
}
/**
* Sorts the list of data. Will sort client side if possible, otherwise
* data will be loaded from the server in the appropriate order.
* @private
*/
Paginated.prototype.sort = function(sorting) {
var i, sortOrder, sortOptionId, missingData;
// if the sort order isn't reversible, don't re-sort if the sort order is the same
var a = this.sortDirectiveOrder();
var b = sorting.order();
if (sorting.notReversible && this.sortDirectiveOrder() == sorting.order()) {
return;
}
if(sorting.maintainSortOrder && sorting.maintainSortOrder === true) {
sortOrder = sorting.order();
}
else {
if (sorting.id) {
if (sorting.order() === "none" || sorting.order() === "desc") {
sortOrder = "asc";
} else {
sortOrder = "desc";
}
}
}
this.sortDirectiveOrder(sortOrder);
for (i = 0; i < this.sortOptions().length; i += 1) {
if (this.sortOptions()[i] === sorting) {
this.sortOptions()[i].order(sortOrder);
} else if(!this.sortOptions()[i].maintainSortOrder){
this.sortOptions()[i].order("none");
}
}
this.sortDirectiveProp(sorting.id);
//If client does not have all the data, clear loaded data and use
//server request to sort the data.
if(this.data().length < this.totalNumber() || sorting.serverOnly) {
this.clearOnLoad = true;
this.targetPage = 1;
this.fetchBlock(0);
return;
}
/* in case we paginated and skipped pages, check to see if any
* items in the array are undefined, if we find one, empty the array */
$.each(this.data(), function(ii, next) {
if(!next) {
missingData = true;
return false;
}
});
if(missingData) {
this.clearOnLoad = true;
this.targetPage = 1;
this.fetchBlock(0);
return;
}
//Client side sort.
this.data.sort(this.sortFunction.bind(this));
this.getPage(1);
};
/**
* Client side sort function for a list of objects
* @param {Object} a first compare value
* @param {Object} b second compare value
* @returns {integer} Returns 0 if equal, <1 if a should come first,
* or >1 if a should come second.
* @private
*/
Paginated.prototype.sortFunction = function (a, b) {
var property, ii, aValue, bValue, order;
order = this.sortDirectiveOrder() === "desc" ? -1 : 1;
property = this.sortDirectiveProp() &&
this.sortDirectiveProp().split('.');
aValue = a;
bValue = b;
for(ii = 0; ii < property.length; ii += 1) {
if($.isArray(aValue)) {
aValue = aValue[0];
}
if($.isArray(aValue)) {
aValue = aValue[0];
}
aValue = aValue && aValue[property[ii]];
if($.isArray(bValue)) {
bValue = bValue[0];
}
bValue = bValue && bValue[property[ii]];
if($.isArray(bValue)) {
bValue = bValue[0];
}
}
// If sort values are equal then default to name ascending
if(aValue === bValue ||
(typeof aValue === 'string' && aValue.toLowerCase() === bValue.toLowerCase())) {
if(a.displayName && b.displayName){
aValue = a.displayName && a.displayName.toString().toLowerCase();
bValue = b.displayName && b.displayName.toString().toLowerCase();
} else if(a.dateTime && b.dateTime){
aValue = a.dateTime && a.dateTime.toLowerCase();
bValue = b.dateTime && b.dateTime.toLowerCase();
order = 1;
}
}
if(aValue === bValue) {
return 0;
}
if(isFinite(aValue) && isFinite(bValue)) {
return (parseFloat(aValue) - parseFloat(bValue)) * order;
}
return aValue.toString().toLowerCase() > bValue.toString().toLowerCase() ? order : -1 * order;
};
/**
* Function to create a list of pages to display.
* @private
*/
Paginated.prototype.pagesFunction = function() {
var numberOfPages, numberOfFullPages, numberOfPartialPages, pages,
pageNumber, selected, focused, i, offset = 1, pageIndex;
if(this.clearOnLoad){
this.startIndex = 0;
this.lastIndex = 4;
this.adjustStartAndEndPageIndex(1);
}
if (this.totalNumber()) {
// Calculate the number of pages
numberOfFullPages =
(this.totalNumber() - (this.totalNumber() % this.itemsPerPage)) / this.itemsPerPage;
numberOfPartialPages = (this.totalNumber() % this.itemsPerPage > 0 ? 1 : 0);
numberOfPages = numberOfFullPages + numberOfPartialPages;
} else {
numberOfPages = 0;
}
this.prevTotalNumberOfPages = this.totalNumberOfPages();
this.totalNumberOfPages(numberOfPages);
// Create the objects to represent the pages
pages = [];
for (i=this.startIndex; (i <= this.lastIndex && i < this.totalNumberOfPages()); i += 1) {
pageNumber = i + 1;
// Determine whether or not this page is currently selected
selected = pageNumber === this.currentPage();
focused = (this.focusPage) ? selected : false;
pageIndex = Math.abs(pageNumber -i - offset);
offset += 1;
pages[pageIndex] =
{pageNumber: pageNumber, selected: selected, focused: focused};
}
// Ignore the page focus the first time we enter a page
if (!this.focusPage && pages.length > 0) {
this.focusPage = true;
}
return pages;
};
/**
* Adjust startIndex and lastIndex of the page slice depending on which page
* is requested to be viewed
*/
Paginated.prototype.adjustPageIndex = function(pageNumber){
// if requested last page or page greater than total number of pages,
// show the last page and previous 4, if they exist
// if not, then there exists just one slice of 5 or less pages
var pageOffset = Math.floor((this.pageWindowSize/2)), pageNumberOverflow,
startIndexBackup;
if(pageNumber >= this.totalNumberOfPages()){
if(pageNumber > this.totalNumberOfPages()){
// assign last page as the pageNumber
pageNumber = this.totalNumberOfPages();
}else{
//display last page and previous 4 pages
this.lastIndex = this.totalNumberOfPages() - 1;
if((this.lastIndex - this.startIndex) > (this.pageWindowSize - 1)){
this.startIndex = this.lastIndex - (this.pageWindowSize - 1);
}
}
}else{
// when requested page is the last page of a displayed 5 page slice
// requested page becomes middle page & displays 2 previous and 2 next
if(this.lastIndex + 1 === pageNumber){
//if only one page in the next slice of 5 pages
if(this.lastIndex + 2 === this.totalNumberOfPages()){
this.startIndex = ((this.lastIndex - pageOffset - 1) >= 0) ?
(this.lastIndex - pageOffset - 1) : 0;
// if one+ page in the next slice of 5 pages
}else{
this.startIndex = ((this.lastIndex - pageOffset) >= 0) ?
(this.lastIndex - pageOffset) : 0;
}
this.lastIndex = ((this.lastIndex + pageOffset) <
this.totalNumberOfPages()) ? (this.lastIndex + pageOffset) :
this.totalNumberOfPages() ;
}else{
//When requested page is the first page of a displayed 5 page slice,
//requested page becomes middle page and displays 2 previous and 2 next
if(this.startIndex !== 0 && this.startIndex + 1 == pageNumber){
startIndexBackup = this.startIndex;
this.startIndex = (this.startIndex - pageOffset) > 0 ?
(this.startIndex - pageOffset) : 0;
pageNumberOverflow = this.totalNumberOfPages() -
(this.startIndex + this.pageWindowSize - 1);
this.lastIndex = pageNumberOverflow >= 0 ?
(this.startIndex + this.pageWindowSize - 1) : this.totalNumberOfPages();
} else {
//when all the products on the page out of the last 5 slice are deleted
if(this.prevTotalNumberOfPages != this.totalNumberOfPages()){
if(this.totalNumberOfPages() - this.targetPage < this.pageWindowSize){
this.lastIndex = this.totalNumberOfPages() -1 ;
this.startIndex = ((this.lastIndex - this.pageWindowSize) >= 0) ?
(this.lastIndex - this.pageWindowSize) : this.startIndex;
}
}
}
}
}
};
/*
* Adjust the start and last index of the currently viewed page
*/
Paginated.prototype.adjustStartAndEndPageIndex = function(pageNumber){
// Determine the ending index of the items on this page
this.pageEndIndex(pageNumber * this.itemsPerPage);
if(this.totalNumber()){
if (this.pageEndIndex() > this.totalNumber()) {
this.pageEndIndex(this.totalNumber());
}
}
this.pageStartIndex((pageNumber - 1) * this.itemsPerPage);
};
/**
* Initialize startIndex and EndIndex for a given page slice when loaded for
* the first time
*/
Paginated.prototype.initializeIndex = function(){
this.startIndex = 0;
this.lastIndex = this.pageWindowSize -1;
this.clickedPage(1);
};
/**
* Gets the specified page of results. Will fetch needed results if they
* are not already loaded.
* @param {int} pageNumber the page number of results to get.
* @private
*/
Paginated.prototype.getPage = function(pageNumber) {
var i;
var pageChangeTimeout = setTimeout(function() {$.Topic(PubSub.topicNames.PAGINATION_PAGE_CHANGE).publish();}, 0);
//added for recording the page views
if(pageNumber !== this.currentPage() && pageNumber !== this.targetPage) {
$.Topic(PubSub.topicNames.RECORD_PAGINATION_PAGE_CHANGE).publish();
}
this.clickedPage(pageNumber);
if(this.totalNumberOfPages() > 1 ){
this.adjustPageIndex(pageNumber);
}
this.adjustStartAndEndPageIndex(pageNumber);
// Populate all missing items on the page
//this.pageStartIndex((pageNumber - 1) * this.itemsPerPage);
if(pageNumber !== this.currentPage()) {
this.targetPage = pageNumber;
}
if(this.clearOnLoad) {
if(pageNumber !== this.currentPage()) {
this.targetPage = pageNumber;
}
this.fetchBlock(this.pageStartIndex());
this.clickedPage(pageNumber);
return;
}
for (i = this.pageStartIndex(); i < this.pageEndIndex(); i += 1) {
if (typeof this.data()[i] === 'undefined') {
if(pageNumber !== this.currentPage()) {
this.targetPage = pageNumber;
}
this.fetchBlock(this.pageStartIndex());
return;
}
}
this.currentPage(pageNumber);
};
/**
* Gets the first page of results.
*/
Paginated.prototype.getFirstPage = function() {
this.initializeIndex();
this.getPage(1);
};
/**
* Gets the first page of results.
*/
Paginated.prototype.getLastPage = function() {
this.getPage(this.totalNumberOfPages());
};
/**
* Changes the page to the specified page.
* @param {Object} data containing a pageNumber property specifying
* the page to load.
*/
Paginated.prototype.changePage = function(data) {
this.getPage(data.pageNumber);
};
/**
* Decrements the current page by one.
*/
Paginated.prototype.decrementPage = function() {
if(this.currentPage() > this.startIndex+1 ){
this.getPage(this.currentPage()-1);
}
};
/**
* Increments the current page by one.
* @private
*/
Paginated.prototype.incrementPage = function() {
if(this.currentPage() < this.totalNumberOfPages()) {
this.getPage(this.currentPage() +1);
}
};
/**
* Success function for successfully loading a list of data.
* @param {Object} result The result containing a list of data.
* and associated metadata.
* @private
*/
Paginated.prototype.clearData = function() {
this.data([]);
this.prevTotalNumber = this.totalNumber();
this.totalNumber(null);
};
/**
* Responsible for adding data to the list of loaded data. This needs to
* be called by the implementing class.
* @param {Array} pagedData The data to add to the list of loaded data.
* @param {int} total The total number of data records that could possibly
* be loaded.
* @param {int} startIndex The starting index of the loaded data.
* @private
*/
Paginated.prototype.addData = function(pagedData, total, startIndex) {
var dataSet, endIndex, ii;
//this if condition is to cover the case where all the items on the last page are deleted
if(this.pageStartIndex() >0 && (total < 0 || total === startIndex)){
total = this.prevTotalNumber - this.blockSize >= 0 ? (this.prevTotalNumber - this.blockSize) : 0;
this.removeLastPage();
}else{
total = total< 0 ? 0 : total;
}
this.totalNumber(total);
endIndex = startIndex + this.blockSize * this.pageBatchSize;
if(endIndex > total) {
endIndex = total;
}
if(this.clearOnLoad) {
dataSet = [];
this.initializeIndex();
} else {
dataSet = this.data();
}
if(pagedData) {
for(ii = 0; ii < pagedData.length; ii += 1) {
dataSet[ii + startIndex] = pagedData[ii];
}
}
if(this.clearOnLoad) {
this.data(dataSet);
this.clearOnLoad = false;
} else {
this.data.valueHasMutated();
}
if(this.targetPage) {
if(this.targetPage == 1){
this.initializeIndex();
}
this.adjustStartAndEndPageIndex(this.targetPage);
//Scroll to the top and switch page.
if(this.scrollToTop === true) {
$(window).scrollTop(0);
}
this.currentPage(this.targetPage);
if(this.scrollToTop === true) {
$(window).scrollTop(0);
}
this.targetPage = null;
} else if (endIndex < this.pageEndIndex()) {
this.pageEndIndex(endIndex);
}
};
/**
* Load products using the current sorting order and starting from the
* specified starting index.
* @param {int} startingIndex the index of the first record to load.
*/
Paginated.prototype.fetchBlock = function(startingIndex) {
throw "Function Not Implemented!";
};
/**
* Function to load the list of products.
* @private
*/
Paginated.prototype.load = function(delayClear, page) {
if(delayClear) {
this.clearOnLoad = true;
} else {
this.clearData();
if(page){
this.totalNumberOfPages(page);
this.currentPage(page);
}
}
this.getPage(page || this.currentPage() || 1);
};
/**
* Function to remove all products in the last page
*/
Paginated.prototype.removeLastPage = function() {
this.clearOnLoad = false;
this.startIndex = (this.startIndex - 1) >= 0 ? this.startIndex - 1 : this.startIndex;
this.getPage(this.currentPage() - 1);
};
/**
* reset the sort properties to a default state
*/
Paginated.prototype.sortReset = function() {
this.sortDirectiveProp(this.defaultSort);
this.sortDirectiveOrder('asc');
$.each(this.sortOptions(), function(ii, value) {
if(value.id === this.defaultSort) {
value.order('asc');
} else {
value.order('none');
}
});
};
return Paginated;
});
</code></pre>
</article>
</section>
</div>
<nav>
<h2><a href="index.html">Index</a></h2><h3>Modules</h3><ul><li><a href="module-ccKoErrorWrapper.html">ccKoErrorWrapper</a></li><li><a href="module-ccKoExtensions.html">ccKoExtensions</a></li></ul><h3>Classes</h3><ul><li><a href="Address.html">Address</a></li><li><a href="CartViewModel.html">CartViewModel</a></li><li><a href="DynamicProperty.html">DynamicProperty</a></li><li><a href="EventDispatcher.html">EventDispatcher</a></li><li><a href="GiftCardViewModel.html">GiftCardViewModel</a></li><li><a href="GiftProductListingViewModel.html">GiftProductListingViewModel</a></li><li><a href="ko.bindingHandlers.background.html">background</a></li><li><a href="ko.bindingHandlers.carouselSwipe.html">carouselSwipe</a></li><li><a href="ko.bindingHandlers.ccForm.html">ccForm</a></li><li><a href="ko.bindingHandlers.ccLink.html">ccLink</a></li><li><a href="ko.bindingHandlers.ccValidation.html">ccValidation</a></li><li><a href="ko.bindingHandlers.checkbox.html">checkbox</a></li><li><a href="ko.bindingHandlers.chosen.html">chosen</a></li><li><a href="ko.bindingHandlers.contextResourcesNamespace.html">contextResourcesNamespace</a></li><li><a href="ko.bindingHandlers.currency.html">currency</a></li><li><a href="ko.bindingHandlers.datepicker.html">datepicker</a></li><li><a href="ko.bindingHandlers.datepopover.html">datepopover</a></li><li><a href="ko.bindingHandlers.draggable.html">draggable</a></li><li><a href="ko.bindingHandlers.droppable.html">droppable</a></li><li><a href="ko.bindingHandlers.fade.html">fade</a></li><li><a href="ko.bindingHandlers.hover.html">hover</a></li><li><a href="ko.bindingHandlers.imageSource.html">imageSource</a></li><li><a href="ko.bindingHandlers.imageZoom.html">imageZoom</a></li><li><a href="ko.bindingHandlers.localeText.html">localeText</a></li><li><a href="ko.bindingHandlers.makeAccess.html">makeAccess</a></li><li><a href="ko.bindingHandlers.modal.html">modal</a></li><li><a href="ko.bindingHandlers.modalTabbingContraint.html">modalTabbingContraint</a></li><li><a href="ko.bindingHandlers.onRender.html">onRender</a></li><li><a href="ko.bindingHandlers.popeditor.html">popeditor</a></li><li><a href="ko.bindingHandlers.popover.html">popover</a></li><li><a href="ko.bindingHandlers.productImageSource.html">productImageSource</a></li><li><a href="ko.bindingHandlers.propertyEditor.html">propertyEditor</a></li><li><a href="ko.bindingHandlers.radio.html">radio</a></li><li><a href="ko.bindingHandlers.richTextEditor.html">richTextEditor</a></li><li><a href="ko.bindingHandlers.scrollAffix.html">scrollAffix</a></li><li><a href="ko.bindingHandlers.select2.html">select2</a></li><li><a href="ko.bindingHandlers.select2Tags.html">select2Tags</a></li><li><a href="ko.bindingHandlers.selectable.html">selectable</a></li><li><a href="ko.bindingHandlers.slickList.html">slickList</a></li><li><a href="ko.bindingHandlers.slide.html">slide</a></li><li><a href="ko.bindingHandlers.slider.html">slider</a></li><li><a href="ko.bindingHandlers.spectrum.html">spectrum</a></li><li><a href="ko.bindingHandlers.tagsInput.html">tagsInput</a></li><li><a href="ko.bindingHandlers.textCheck.html">textCheck</a></li><li><a href="ko.bindingHandlers.timepicker.html">timepicker</a></li><li><a href="ko.bindingHandlers.triggerMessage.html">triggerMessage</a></li><li><a href="ko.bindingHandlers.validatableTarget.html">validatableTarget</a></li><li><a href="ko.bindingHandlers.validatableValue.html">validatableValue</a></li><li><a href="ko.bindingHandlers.widgetLocaleText.html">widgetLocaleText</a></li><li><a href="koValidation.alphaNumeric.html">alphaNumeric</a></li><li><a href="koValidation.alphaNumericNoSpaces.html">alphaNumericNoSpaces</a></li><li><a href="koValidation.alphaNumericNoSpacesWithSeperators.html">alphaNumericNoSpacesWithSeperators</a></li><li><a href="koValidation.alphaNumericWithSeperators.html">alphaNumericWithSeperators</a></li><li><a href="koValidation.bool.html">bool</a></li><li><a href="koValidation.creditcard.html">creditcard</a></li><li><a href="koValidation.cvv.html">cvv</a></li><li><a href="koValidation.endmonth.html">endmonth</a></li><li><a href="koValidation.endyear.html">endyear</a></li><li><a href="koValidation.importFileName.html">importFileName</a></li><li><a href="koValidation.laterDate.html">laterDate</a></li><li><a href="koValidation.match.html">match</a></li><li><a href="koValidation.mediaZipFileName.html">mediaZipFileName</a></li><li><a href="koValidation.number.html">number</a></li><li><a href="koValidation.observablePattern.html">observablePattern</a></li><li><a href="koValidation.password.html">password</a></li><li><a href="koValidation.price.html">price</a></li><li><a href="koValidation.propertyIdAlreadyInUse.html">propertyIdAlreadyInUse</a></li><li><a href="koValidation.propertyNameAlreadyInUse.html">propertyNameAlreadyInUse</a></li><li><a href="koValidation.restrictSlashCharacters.html">restrictSlashCharacters</a></li><li><a href="koValidation.startmonth.html">startmonth</a></li><li><a href="koValidation.startyear.html">startyear</a></li><li><a href="koValidation.uniqueTrimmed.html">uniqueTrimmed</a></li><li><a href="koValidation.uniqueTrimmedCaseInsensitive.html">uniqueTrimmedCaseInsensitive</a></li><li><a href="koValidation.url.html">url</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.addTemplate.html">addTemplate</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.ccDate.html">ccDate</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.ccDateTime.html">ccDateTime</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.ccNumber.html">ccNumber</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.disabled.html">disabled</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.element.html">element</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.embeddedAssistance.html">embeddedAssistance</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.inTabFlow.html">inTabFlow</a></li><li><a href="module-ccKoExtensions-ko.bindingHandlers.setContextVariable.html">setContextVariable</a></li><li><a href="NavStateViewModel.html">NavStateViewModel</a></li><li><a href="OrderHistoryViewModel.html">OrderHistoryViewModel</a></li><li><a href="OrderViewModel.html">OrderViewModel</a></li><li><a href="ParentOrganisation.html">ParentOrganisation</a></li><li><a href="ProductListingSearchViewModel.html">ProductListingSearchViewModel</a></li><li><a href="ProductListingViewModel.html">ProductListingViewModel</a></li><li><a href="ProductViewModel.html">ProductViewModel</a></li><li><a href="PubSub.topicNames.html">topicNames</a></li><li><a href="resetCVV.html">resetCVV</a></li><li><a href="resetPaymentDetails.html">resetPaymentDetails</a></li><li><a href="SearchRestClient.html">SearchRestClient</a></li><li><a href="UserViewModel.html">UserViewModel</a></li><li><a href="WidgetViewModel.html">WidgetViewModel</a></li><li><a href="WishlistContentViewModel.html">WishlistContentViewModel</a></li></ul><h3>Namespaces</h3><ul><li><a href="ko.bindingHandlers.html">bindingHandlers</a></li><li><a href="ko.extenders.html">extenders</a></li><li><a href="koValidation.html">koValidation</a></li></ul><h3>Global</h3><ul><li><a href="global.html#CCEETagProcessor">CCEETagProcessor</a></li><li><a href="global.html#isValidDeterminewhetherornotthepaymentdetailsobjectisvalidbasedonthevalidityofitscomponentparts.Thiswillnotcauseerrormessagestobedisplayedforanyobservablevaluesthatareunchangedandhaveneverreceivedfocusontherelatedformfield(s).">isValid
Determine whether or not the payment details object is valid
based on the validity of its component parts. This will not
cause error messages to be displayed for any observable values
that are unchanged and have never received focus on the
related form field(s).</a></li><li><a href="global.html#validatePaymentDetailsForceallrelevantmemberobservablestoperformtheirvalidationnow&displaytheerrors(ifany)">validatePaymentDetails
Force all relevant member observables to perform their
validation now & display the errors (if any)</a></li></ul>
</nav>
<br clear="both">
<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.3.0</a> on Mon Oct 10 2016 10:49:02 GMT+0100 (BST)
</footer>
<script> prettyPrint(); </script>
<script src="scripts/linenumber.js"> </script>
</body>
</html>