- This feature can be merged to master and ship to production when it's ready.
This file contains hidden or 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
| **************************** | |
| * Upload to Nitro MDM * | |
| **************************** | |
| % Total % Received % Xferd Average Speed Time Time Time Current | |
| Dload Upload Total Spent Left Speed | |
| 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 | |
| 100 17.3M 0 0 100 17.3M 0 16.8M 0:00:01 0:00:01 --:--:-- 16.8M | |
| 100 17.3M 0 94 100 17.3M 61 11.4M 0:00:01 0:00:01 --:--:-- 11.4M | |
| { |
This file contains hidden or 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
| **************************** | |
| * Upload to Nitro MDM * | |
| **************************** | |
| % Total % Received % Xferd Average Speed Time Time Time Current | |
| Dload Upload Total Spent Left Speed | |
| 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 | |
| 78 17.3M 0 0 78 13.5M 0 32.1M --:--:-- --:--:-- --:--:-- 32.1M | |
| 100 17.3M 0 0 100 17.3M 0 8737k 0:00:02 0:00:02 --:--:-- 8742k | |
| 100 17.3M 0 85 100 17.3M 34 7192k 0:00:02 0:00:02 --:--:-- 7190k |
This file contains hidden or 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
| require 'descriptive_statistics' # https://github.com/thirtysixthspan/descriptive_statistics | |
| require 'csv' | |
| csv_text = File.read('/Users/greg/Downloads/1528750652_5118.csv'); | |
| csv = CSV.parse(csv_text, :headers => true); | |
| start_date = Date.parse("2018-06-04") | |
| end_date = Date.parse("2018-06-09") | |
| date_range = start_date..end_date |
This file contains hidden or 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
| Rpush.embed # to deliver push notifications in the Rails console on notification save | |
| # Selecting the mobile device that'll receive the notification: | |
| greg = User.find_by(login: "greg.blake"); | |
| devices = greg.mobile_devices; | |
| @mobile_device = greg.mobile_devices.last; | |
| # Sending a notification to the device | |
| n = Rpush::Apns2::Notification.new; | |
| n.app = @mobile_device.app; |
This file contains hidden or 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
| $ tail -f development.log | grep media_gallery | |
| # Before this PR, `all_media_gallery_info` was called on every request, because caching had not yet been implemented. | |
| # The `time_duration_seconds` stays roughly the same on every request. | |
| MediaAlbum Load (1.1ms) SELECT `media_albums`.* FROM `media_albums` WHERE `media_albums`.`media_gallery_id` = 3 AND `media_albums`.`default` = 1 LIMIT 1 | |
| MediaAlbum Load (0.9ms) SELECT `media_albums`.* FROM `media_albums` WHERE `media_albums`.`media_gallery_id` = 3 | |
| [media_gallery] '/api/v1/media_galleries/' time_duration_seconds=0.894 | |
| MediaAlbum Load (0.9ms) SELECT `media_albums`.* FROM `media_albums` WHERE `media_albums`.`media_gallery_id` = 3 AND `media_albums`.`default` = 1 LIMIT 1 | |
| MediaAlbum Load (1.0ms) SELECT `media_albums`.* FROM `media_albums` WHERE `media_albums`.`media_gallery_id` = 3 | |
| [media_gallery] '/api/v1/media_galleries/' time_duration_seconds=0.743 | |
| MediaAlbum Load (1.3ms) SELECT `media_albums`.* FROM `media_albums` WHERE `media_albums`.`media_ga |
This file contains hidden or 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
| 16:30 $ git diff /Users/greg/code/nitro-web/components/connect/app/views/connect/rooms/_form.html.erb | |
| diff --git a/components/connect/app/views/connect/rooms/_form.html.erb b/components/connect/app/views/connect/rooms/_form.html.erb | |
| index a85a953896..9621acddd8 100644 | |
| --- a/components/connect/app/views/connect/rooms/_form.html.erb | |
| +++ b/components/connect/app/views/connect/rooms/_form.html.erb | |
| @@ -1,6 +1,6 @@ | |
| <div class="row"> | |
| <div class="nitro-form"> | |
| - <%= nitro_form_for @connect_room, url: connect.room_path(@connect_room), html: { class: "form-horizontal" } do |f| %> | |
| + <%= nitro_form_for @connect_room, url: url, html: { class: "form-horizontal" } do |f| %> |
This file contains hidden or 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
| 10:02 $ NODE_ENV=production node_modules/@powerhome/nitro_react/node_modules/.bin/webpack --config webpack.config.js | |
| module.js:529 | |
| throw err; | |
| ^ | |
| Error: Cannot find module '/Users/greg/code/nitro-web/webpack.config.js' | |
| at Function.Module._resolveFilename (module.js:527:15) | |
| at Function.Module._load (module.js:476:23) | |
| at Module.require (module.js:568:17) | |
| at require (internal/module.js:11:18) |
This file contains hidden or 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
| irb(main):002:0> GalleryMetric::Influx.gallery_views(start_date: (Date.today - 30.days), end_date: Date.today, territory_ids: Territory.pluck(:id)) | |
| => [{"name"=>"media_gallery_viewed", "tags"=>{"estimate_appointment_id"=>"", "user_id"=>"39973"}, "values"=>[{"time"=>"2018-09-02T00:00:00Z", "count"=>88, "sum"=>59572.02978897095}]}, {"name"=>"media_gallery_viewed", "tags"=>{"estimate_appointment_id"=>"", "user_id"=>"40263"}, "values"=>[{"time"=>"2018-09-02T00:00:00Z", "count"=>3, "sum"=>5.068565011024475}]}, {"name"=>"media_gallery_viewed", "tags"=>{"estimate_appointment_id"=>"10998817", "user_id"=>"38138"}, "values"=>[{"time"=>"2018-09-02T00:00:00Z", "count"=>1, "sum"=>3.566429018974304}]}, {"name"=>"media_gallery_viewed", "tags"=>{"estimate_appointment_id"=>"10998841", "user_id"=>"7731"}, "values"=>[{"time"=>"2018-09-02T00:00:00Z", "count"=>2, "sum"=>366.0380080938339}]}, {"name"=>"media_gallery_viewed", "tags"=>{"estimate_appointment_id"=>"10998844", "user_id"=>"37"}, "values"=>[{"time"=>"2018-09-02T00:00:00Z |