This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Backbone = require('backbone'); | |
var _ = require('underscore'); | |
var User = Backbone.Model.extend({ | |
validate: function(attrs, options) { | |
if ( !_.isString(attrs.name)) { | |
return "Имя должно быть строкой"; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Структура данных Wing Pass | |
Certificate{ | |
_id: // - Внутренний 24-х значный идентификатор | |
// документа в базе данных MongoDB. | |
// есть возможность отключить автоматическую | |
// генерацию этого id и сделать его номером | |
// карты-сертификата дорастив к нему слева 8 нолей | |
// тогда валидация уникальности сгенерированого номера |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 31.10.13. | |
*/ | |
var mongoose = require('mongoose'); | |
console.log('Версия монгус -', mongoose.version ); | |
var db = mongoose.createConnection('mongodb://localhost/learn'); | |
db.on("error", console.error.bind(console, 'connection error:' )); | |
//db.once("open", function callback () { | |
// console.log('Connected!') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 31.10.13. | |
*/ | |
var mongoose = require('mongoose'); | |
console.log('Версия монгуса -', mongoose.version); | |
var db = mongoose.createConnection('mongodb://localhost/learn'); | |
db.on("error", console.error.bind(console, "connection error:")); | |
db.once("open", function callback () { | |
console.log("Connected!") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 31.10.13. | |
*/ | |
var mongoose = require('mongoose'); | |
console.log('Версия монгус -', mongoose.version ); | |
var db = mongoose.createConnection('mongodb://localhost/learn'); | |
db.on("error", console.error.bind(console, 'connection error:' )); | |
//db.once("open", function callback () { | |
// console.log('Connected!') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 31.10.13. | |
*/ | |
var mongoose = require('mongoose'); | |
console.log('Версия монгус -', mongoose.version ); | |
var db = mongoose.createConnection('mongodb://localhost/learn'); | |
db.on("error", console.error.bind(console, 'connection error:' )); | |
//db.once("open", function callback () { | |
// console.log('Connected!') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 31.10.13. | |
*/ | |
var mongoose = require('mongoose'); | |
console.log('Версия монгуса -', mongoose.version); | |
var db = mongoose.createConnection('mongodb://localhost/learn'); | |
db.on("error", console.error.bind(console, "connection error:")); | |
db.once("open", function callback () { | |
console.log("Connected!") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 19.11.13. | |
*/ | |
/** | |
* И так, смотри у тебя есть механизм получаени ястраниц с форума кубань ру | |
* Твоя задача сводится к тому, чтобы сначала получить данные, а уже потом все данные | |
* найти разницу между всеми данными и записать эту разницу в файл. | |
* Далее смотри по тексту | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by mwmaleks on 14.01.14. | |
*/ | |
var MyModal = (function() { | |
/** | |
* sets the callBack function calls when modal is completely shown | |
* @param callBack | |
*/ | |
function onShownListener(callBack) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
55,130,32,46,9,224,14,10,98,5,194,0,136,16,64,42,41,0,104,64,75,0,152,32,35,0,44,2,112,6,192,3,0,172,103,150,64,236,0,113,19,128,182,2,185,128,33,152,184,7,176,7,96,25,193,0,109,80,145,96,33,7,192,123,92,1,141,176,128,1,102,29,128,27,89,0,121,242,224,6,224,0,137,86,158,34,68,5,224,3,162,0,42,128,73,0,194,2,1,24,2,112,16,29,196,110,33,0,230,0,66,220,96,194,0,250,225,94,2,96,225,0,76,0,102,0,82,134,110,198,78,174,158,62,126,129,33,96,97,66,145,209,177,74,2,90,230,80,34,48, | 225,0,204,0,50,100,106,246,118,0,124,250,70,166,230,150,182,14,46,238,94,190,254,193,161,17,225,254,66,48,30,174,66,188,254,147,241,113,0,202,52,205,32,45,198,237,38,102,22,214,118,25,253,217,67,121,5,145,202,17,113,73,0,234,0,180,34,173,27,6,91,93,187,189,153,3,57,195,249,163,103,66,151,30,60,80,112,144,80,192,2,176,1,122,93,210,125,44,160,215,34,52,41,141,74,191,127,160,45,64,70,169,17,24,84,45,0,11,85,171,161,18,24,2,157,29,143,83,139,134,184,253,174,165,24,71,216,206,76,165,35,194,165,45,0,131,204,204,224,120,60 |
OlderNewer