39 lines
1.5 KiB
JavaScript
39 lines
1.5 KiB
JavaScript
const SOCKETMANAGER = require('./js/v2/slackSocket');
|
|
const { BitcoinModel, Bitcoin } = require('./js/v2/bitcoin');
|
|
const { EventModel, EventView } = require('./js/v2/events');
|
|
const { FxModel, FxView } = require('./js/v2/fx');
|
|
const { TrainModel, TrainView } = require('./js/v2/train');
|
|
const PasswordView = require('./js/v2/password');
|
|
const WView = require('./js/v2/weatherV2');
|
|
|
|
// module.exports = EventModel;
|
|
// module.exports = EventView;
|
|
|
|
(function (w) {
|
|
/* navigator.geolocation.getCurrentPosition((show_weather) => {
|
|
w.weather = new WeatherSlim({model: new WeatherModel({geo:show_weather})});
|
|
});*/
|
|
|
|
const webSocketModel = new SOCKETMANAGER();
|
|
|
|
const btcModel = new BitcoinModel();
|
|
webSocketModel.setBTC(btcModel);
|
|
|
|
w.contractEnds = new EventView({ 'model': new EventModel({ 'event': new Date(2019, 5, 28), 'label': 'Contract Ends:' }) });
|
|
|
|
w.bitcoin = new Bitcoin({ 'model': btcModel });
|
|
|
|
w.fx = new FxView({ 'model': new FxModel() });
|
|
|
|
w.dbqglqView = new TrainView({ 'model': new TrainModel({ 'from': 'dbe', 'to': 'glq' }) });
|
|
w.glqdbeView = new TrainView({ 'model': new TrainModel({ 'from': 'glq', 'to': 'dbe' }) });
|
|
w.glqhymView = new TrainView({ 'model': new TrainModel({ 'from': 'glq', 'to': 'hym' }) });
|
|
w.hymglqView = new TrainView({ 'model': new TrainModel({ 'from': 'hym', 'to': 'glq' }) });
|
|
|
|
// console.log(PasswordView);
|
|
w.passwords = new PasswordView();
|
|
|
|
w.wview = new WView({ 'el': document.getElementById('weather') });
|
|
webSocketModel.turnOn();
|
|
})(window);
|