basic version of ValidationMixin, register page getting more functional
This commit is contained in:
26
front-ui/app/models/userRegistration.js
Normal file
26
front-ui/app/models/userRegistration.js
Normal file
@@ -0,0 +1,26 @@
|
||||
var Backbone = require('backbone');
|
||||
var Globals = require('../globals');
|
||||
|
||||
var UserRegistration = Backbone.Model.extend({
|
||||
|
||||
initialize: function() {
|
||||
$.ajaxPrefilter(
|
||||
function(options, originalOptions, jqXHR) {
|
||||
options.xhrFields = {
|
||||
withCredentials: true
|
||||
}
|
||||
}
|
||||
);
|
||||
},
|
||||
|
||||
url: Globals.ApiUrl + '/user',
|
||||
defaults: {
|
||||
first_name : '',
|
||||
last_name : '',
|
||||
email : '',
|
||||
password: '',
|
||||
password_confirmation: ''
|
||||
}
|
||||
});
|
||||
|
||||
module.exports = UserRegistration;
|
||||
Reference in New Issue
Block a user