Giter Club home page Giter Club logo

cognicity-rem's People

Contributors

abrahamq avatar matthewberryman avatar mehrdadgit avatar ojha-url avatar tomasholderness avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

petabencana

cognicity-rem's Issues

blank page in Safari desktop

Sort areas based on number of reports?

While using pagination fixes the issue of selected area not showing up sometimes in the first few rows, wouldn't it be more useful to sort areas based on reports?
Sorting by name could be secondary.

Investigate using Canvas rendering by default in Leaflet

Canvas rendering is much faster in browser than SVG.

  • Leaflet 1.0 may use this by default, in earlier versions like 0.7 it had to be enabled.
  • Investigate using explicit canvas layers to render, hide and show updates to flood extents data

syntax error

aurelia-testing.js:1 Uncaught SyntaxError: Unexpected token <

Semarang map display issues

I've tried tweaking the map extents in 6d9ba70 to better centre and focus on Semarang in initial map display. However on first load it does this two step process of using the map extents I specify (with some cut off by table), but then zooms in and cuts off the bottom of Semarang:

screenshot 2018-11-21 11 50 41

Then on selecting regions, sometimes these are cut off at the bottom (as shown) or entirely off the bottom of the screen. Resizing the browser window fixes this particular issue but then both issues show up on page reload.

screenshot 2018-11-21 11 51 01

OS: macOS 10.14.2
Browsers: Chrome beta 71.0.3578.62, Firefox Developer Edition 64.0b11 (64-bit)

Review need for reports module

_V3 CogniCity removed reports module as part of UI/UX improvements for public map, but there may be a case of integrating this back into the REM.

  • Requires discussion

need to bundle auth0-lock to support testing

Currently auth0-lock is being brought in with a script tag on index.html, but this means that karma can't bring it in during testing, failing with:

Chrome 56.0.2924 (Mac OS X 10.10.5) the app says hello FAILED ReferenceError: Auth0Lock is not defined at new App (/Users/abrahamq/Documents/urop/cognicity-rem/scripts/app-bundle.js:214:23) at Object.<anonymous> (/Users/abrahamq/Documents/urop/cognicity-rem/test/unit/app.spec.js:6:14)

I think the solution is to bundle auth0-lock with our app. There's an npm module https://www.npmjs.com/package/auth0-lock, but I couldn't get it to work? There's no dist/ or build folder in the npm module and the docs seem to point at having to build the module but npm install fails.

REM Login issue

Hi all,

We have a problem when you logged in to REM, sometimes Auth0 recognized you as basic user (View Only) although you're not.

Here's an example with BPBD account:

BPBD account - View Only
image

but then after several tries - Full Access

image

The same thing also happens with my own account.

Temporary solution to gain full access:

  1. Login to REM
  2. Close tab
  3. Open REM page again
  4. Click 'Peta' (Map)

Semarang graphic display issue

graphic display color seems inconsistance.
action: coloring the RW map on 4 different flood criterias (red, orange, yellow, purple).
REM editing shows:

screen shot 2018-11-22 at 11 27 03 am

public map shows:

screen shot 2018-11-22 at 11 21 57 am

both using dev version

type error

Uncaught TypeError: Cannot read property '__useDefault' of undefined
    at a (vendor-bundle.js:7)
    at vendor-bundle.js:7
    at Object.execCb (vendor-bundle.js:3)
    at y.check (vendor-bundle.js:3)
    at y.<anonymous> (vendor-bundle.js:3)
    at vendor-bundle.js:2
    at vendor-bundle.js:3
    at each (vendor-bundle.js:2)
    at y.emit (vendor-bundle.js:3)
    at y.check (vendor-bundle.js:3)
    at y.enable (vendor-bundle.js:3)
    at y.init (vendor-bundle.js:3)
    at f (vendor-bundle.js:2)
    at Object.completeLoad (vendor-bundle.js:3)
    at HTMLScriptElement.onScriptLoad (vendor-bundle.js:3)
a @ vendor-bundle.js:7
(anonymous) @ vendor-bundle.js:7
execCb @ vendor-bundle.js:3
check @ vendor-bundle.js:3
(anonymous) @ vendor-bundle.js:3
(anonymous) @ vendor-bundle.js:2
(anonymous) @ vendor-bundle.js:3
each @ vendor-bundle.js:2
emit @ vendor-bundle.js:3
check @ vendor-bundle.js:3
enable @ vendor-bundle.js:3
init @ vendor-bundle.js:3
f @ vendor-bundle.js:2
completeLoad @ vendor-bundle.js:3
onScriptLoad @ vendor-bundle.js:3

IE not supported

I can't load the page in IE. I am having trouble with the VM so I can't screenie or copy and paste the error but it did suggest it was having trouble with polyfill and suggested using fetch, so I will give that a shot.

Login fails in Firefox

Firefox 51.0.1 (64-bit) on OSX 10.11.6

------------------------------------------------
Inner Error:
Message: Auth0Lock is not defined
Inner Error Stack:
App@https://rem-dev.petabencana.id/scripts/app-bundle.js:214:7
invoke@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12420:14
invoke@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12379:155
invoke@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12643:16
get@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12096:27
get@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12582:14
ensureViewModel/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24085:58
tryCatcher@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:3373:16
[15]</module.exports/Promise.prototype._settlePromiseFromHandler@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:2590:13
[15]</module.exports/Promise.prototype._settlePromise@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:2647:13
[15]</module.exports/Promise.prototype._settlePromise0@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:2692:5
[15]</module.exports/Promise.prototype._settlePromises@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:2771:13
[1]</Async.prototype._drainQueue@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:163:13
[1]</Async.prototype._drainQueues@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:173:5
Async/this.drainQueues@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:47:9

End Inner Error Stack
------------------------------------------------

    AggregateError@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:15462:13
    invoke@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12645:15
    get@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12096:27
    get@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:12582:14
    ensureViewModel/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24085:58
From previous event:
    ensureViewModel@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24078:16
    createController@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24054:14
    _createControllerAndSwap@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24033:14
    compose@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24113:16
    compose@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:24381:14
    setRoot@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:13352:14
    configure/<@https://rem-dev.petabencana.id/scripts/app-bundle.js:425:14
From previous event:
    configure@https://rem-dev.petabencana.id/scripts/app-bundle.js:424:5
    config/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11927:9
From previous event:
    config@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11922:14
    handleApp@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11913:12
    run/</</<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11946:13
From previous event:
    run/</<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11944:16
From previous event:
    run/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11943:14
From previous event:
    run@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11939:12
    @https://rem-dev.petabencana.id/scripts/vendor-bundle.js:11966:3
    newContext/context.execCb@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5891:24
    newContext/Module.prototype.check@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5079:43
    newContext/Module.prototype.enable@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5371:17
    newContext/context.enable@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5752:21
    newContext/Module.prototype.enable/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5356:25
    bind/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:4332:20
    each@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:4257:31
    newContext/Module.prototype.enable@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5308:17
    newContext/Module.prototype.init@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:4984:21
    localRequire/<@https://rem-dev.petabencana.id/scripts/vendor-bundle.js:5655:25  vendor-bundle.js:1395:13```

        

incorrect menu + do not merge dev

Hi. Just noting there's a bug in dev in which after you login (now using universal auth0 thanks to @mehrdadgit's work) it still has the pre-login menu (with option to login "Masuk", rather than options for map "Peta" and logout "Keluar"). Neither of us know our way around aurelia routing well enough (yet) in order to fix it, but in light of other discussions around a rewrite of REM (and using Cognito) it doesn't seem worth fixing this bug. Also just flagging that dev now should not be merged into master as we've gone with two different auth0 ways of doing the login and merging dev -> master would break prod without some corresponding config changes.

need to update the basemap with the updated map on mapbox/OSM

during the training we receive a complain about our basemap (when reporting) which currently shows less updated info from the original OSM/mapbox web

screen shot 2018-12-10 at 2 55 13 pm

screen shot 2018-12-10 at 2 56 02 pm

perhaps as we limited our PB map scale to be zoomed in max in 100 m while OSM web up to 20 m?

build broken - syntax issue in environment.js

Starting 'buildJavaScript'...
[09:00:37] gulp-notify: [Error running Gulp] Error: /Users/matthew/code/cognicity-rem-v3/src/environment.js: Unexpected token, expected , (5:2)
Finished 'buildJavaScript'
Starting 'writeBundles'...
Tracing api...
commonJs.convert: COULD NOT CONVERT: /Users/matthew/code/cognicity-rem-v3/src/environment.js, so skipping it. Error was: Error: Line 1: Unexpected token

Multiple rows selected

To recreate, occurs when:

  • 'x' area is selected in 'a' district (using map or clicking on table row)
  • select any area in 'b' district (map / table)
  • on returning to 'a' district (using table), 'x' area row is not cleared / remains selected
  • or using map, if 'y' area is clicked on in 'a' district, both 'x' and 'y' rows will be selected (however flood state update option is enabled only for 'y')

Options:

  • seems like something to do with filtering areas based on district
  • manually setting $isSelected property value of au-table row to false breaks browser - endlessly triggers clicks on layer (not sure why! - perhaps it is continuously polled by aurelia using a getter)

Don't use new method for Leaflet functions

Leaflet has internal factory functions that return an instance. This is the leaflet design pattern, and so we should refactor to avoid use of new.

i.e.
var map = L.map();
not,
var map = new L.Map();

Map legend doesn't work

expected behavior:

  • clicking check box items in legend changes their visibility on the map

current behavior:

  • no change on map

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.