pull/12749/head
elenatorro 7 years ago
parent 9f8f97e36f
commit 9e673767eb

@ -0,0 +1,4 @@
module.exports = exports = {
PublicClient: require('./lib/clients/public.js.babel'),
AuthenticatedClient: require('./lib/clients/authenticated.js.babel')
};

@ -1,4 +1,4 @@
const PublicClient = require('./public.js');
const PublicClient = require('./public.js.babel');
class AuthenticatedClient extends PublicClient {
getConfig (callback) {

@ -1,4 +0,0 @@
module.exports = exports = {
PublicClient: require('./lib/clients/public.js'),
AuthenticatedClient: require('./lib/clients/authenticated.js')
};

@ -1,4 +1,4 @@
const Carto = require('../../../../../../javascripts/cartodb3/carto-node/index.js');
const Carto = require('../../../../../../javascripts/carto-node/index.js.babel');
const BASE_URL = 'https://matallo.carto.com';

@ -54,7 +54,7 @@ module.exports = cdb.core.View.extend({
canChangeEmail: this._getField('can_change_email'),
email: this._getField('email'),
isInsideOrg: this._userModel.isInsideOrg(),
organization: this._getField('organization'),
organization: this._userModel.organization,
isLoggedWithGoogle: this._getField('logged_with_google'),
isAuthUsernamePasswordEnabled: this._userModel.isAuthUsernamePasswordEnabled(),
shouldDisplayOldPassword: this._getField('should_display_old_password'),

@ -1,7 +1,7 @@
var $ = require('jquery-cdb-v3');
var _ = require('underscore-cdb-v3');
var cdb = require('cartodb.js-v3');
var Carto = require('../../../core/javascripts/cartodb3/carto-node/index');
var Carto = require('../../../core/javascripts/carto-node/index.js.babel');
var AccountMainView = require('./account_main_view');
var UserNotificationView = require('../common/user_notification/user_notification_view');
var UserNotificationModel = require('../common/user_notification/user_notification_model');

@ -1,7 +1,7 @@
var $ = require('jquery-cdb-v3');
var _ = require('underscore-cdb-v3');
var cdb = require('cartodb.js-v3');
var Carto = require('../../../core/javascripts/cartodb3/carto-node/index');
var Carto = require('../../../core/javascripts/carto-node/index.js.babel');
var Router = require('./router');
var MainView = require('./main_view_static');
var ChangePrivacyDialog = require('../common/dialogs/change_privacy/change_privacy_view');

@ -1,7 +1,7 @@
var $ = require('jquery-cdb-v3');
var _ = require('underscore-cdb-v3');
var cdb = require('cartodb.js-v3');
var Carto = require('../../../core/javascripts/cartodb3/carto-node/index');
var Carto = require('../../../core/javascripts/carto-node/index.js.babel');
var ProfileMainView = require('./profile_main_view');
var UserNotificationView = require('../common/user_notification/user_notification_view');
var UserNotificationModel = require('../common/user_notification/user_notification_model');

@ -1,4 +1,4 @@
const Carto = require('../cartodb3/carto-node/index');
const Carto = require('../../core/javascripts/carto-node/index.js.babel');
const PACKAGE = require('../../../../package.json');
const version = PACKAGE.version;

@ -161,6 +161,13 @@ describe('account/account_form_view', function () {
describe('is inside org', function () {
beforeEach(function () {
this.user.isInsideOrg = function () { return true; };
this.user.organization = new cdb.core.Model({
name: 'carto'
});
this.user.organization.owner = new cdb.core.Model({
email: EMAIL
});
});
describe('.render', function () {
@ -204,6 +211,15 @@ describe('account/account_form_view', function () {
describe('is org owner', function () {
beforeEach(function () {
this.user.isOrgOwner = function () { return true; };
this.user.organization = new cdb.core.Model({
id: 1,
name: 'carto'
});
this.user.organization.owner = new cdb.core.Model({
email: 'owner@cartao.com'
});
});
describe('.render', function () {

@ -32,11 +32,11 @@ module.exports = {
}
},
{
test: /\.js$/,
test: /\.js(\.babel)?$/,
loader: 'babel-loader',
include: [
path.resolve(path.resolve('.'), 'lib/assets/javascripts/cartodb3/carto-node'),
path.resolve(path.resolve('.'), 'lib/assets/test/spec/cartodb3/carto-node'),
path.resolve(path.resolve('.'), 'lib/assets/javascripts/carto-node'),
path.resolve(path.resolve('.'), 'lib/assets/test/spec/carto-node'),
path.resolve(path.resolve('.'), 'node_modules/tangram-cartocss'),
path.resolve(path.resolve('.'), 'node_modules/tangram.cartodb')
],

@ -25,10 +25,10 @@ module.exports = {
module: {
rules: [
{
test: /\.js$/,
test: /\.js(\.babel)?$/,
loader: 'babel-loader',
include: [
path.resolve(__dirname, '../lib/assets/javascripts/cartodb3/carto-node')
path.resolve(__dirname, '../lib/assets/core/javascripts/carto-node')
],
options: {
presets: ['es2015'],

Loading…
Cancel
Save