g1 issueshttps://code.gramener.com/cto/g1/-/issues2018-02-05T04:32:12Zhttps://code.gramener.com/cto/g1/-/issues/4$.template() can render multiple languages2018-02-05T04:32:12ZS Anand$.template() can render multiple languagesScripts with different types have different meanings
- `type="text/html"` renders as HTML in-place
- `type="text/plain"` renders as text, i.e. set the innerText, not innerHTML
- `type="text/markdown"` - Markdown
- `type="text/vega"` - [...Scripts with different types have different meanings
- `type="text/html"` renders as HTML in-place
- `type="text/plain"` renders as text, i.e. set the innerText, not innerHTML
- `type="text/markdown"` - Markdown
- `type="text/vega"` - [Vega](https://vega.github.io/vega/)
- `type="text/vega-lite"` - [Vega-lite](https://vega.github.io/vega-lite/)
- `type="text/plotly"` - [Plotly](https://ecomfe.github.io/)
- `type="text/echarts"` - [echarts](https://github.com/ecomfe/echarts)
- `type="text/mermaid"`- [mermaid graph](https://mermaidjs.github.io/)
- `type="text/flowchart"` - [flowchart](http://flowchart.js.org/)
- `type="text/js-sequence"` - [js-sequence](https://bramp.github.io/js-sequence-diagrams/)
- etc.
Implementation:
- Each works as a plugin that can be registered independently, and can be extended. text/html will use `_.template` for example.
- To allow use of `</script>` tags for code examples, the container can be `<template>` instead of `<script>`https://code.gramener.com/cto/g1/-/issues/10Implement a formhandler treemap2018-07-16T11:29:40ZS AnandImplement a formhandler treemaphttps://code.gramener.com/cto/g1/-/issues/11Implement a FormHandler sunburst2018-07-16T11:29:11ZS AnandImplement a FormHandler sunbursthttps://code.gramener.com/cto/g1/-/issues/12Implement a FormHandler Sankey2018-07-16T11:29:06ZS AnandImplement a FormHandler Sankeyhttps://code.gramener.com/cto/g1/-/issues/13Implement a FormHandler network chart2018-07-16T11:28:56ZS AnandImplement a FormHandler network charthttps://code.gramener.com/cto/g1/-/issues/16Implement a FormHandler matrix - Spec Creation2019-03-05T10:35:21ZS AnandImplement a FormHandler matrix - Spec CreationFor scenarios like:
- https://learn.gramener.com/codogram/#contribution/
- https://learn.gramener.com/groups#matrix
Accept a sparse node-link structure.For scenarios like:
- https://learn.gramener.com/codogram/#contribution/
- https://learn.gramener.com/groups#matrix
Accept a sparse node-link structure.https://code.gramener.com/cto/g1/-/issues/27Create an interactive areaplot comparison chart2018-03-22T05:24:34ZS AnandCreate an interactive areaplot comparison chartThis extension to area charts helps identify changes across any 2 time periods. This makes it easier to tell a story
![area-compare](/uploads/80845e5969c4e831e312b93b9da55bde/area-compare.gif)This extension to area charts helps identify changes across any 2 time periods. This makes it easier to tell a story
![area-compare](/uploads/80845e5969c4e831e312b93b9da55bde/area-compare.gif)https://code.gramener.com/cto/g1/-/issues/30Detect type of value for column highlighting -- use metadata from server2018-04-16T10:27:39ZTejeshDetect type of value for column highlighting -- use metadata from serverhttps://code.gramener.com/cto/g1/-/issues/32Create Gramex UI components2020-09-08T18:57:13ZS AnandCreate Gramex UI components# Dashboard ML
We want a markup language to define dashboards.
## It must extend HTML
For example:
```html
<div class="container">
<div class="g-filters">
- col type="date": Date
- col type="select": City
</div>
</div>
``...# Dashboard ML
We want a markup language to define dashboards.
## It must extend HTML
For example:
```html
<div class="container">
<div class="g-filters">
- col type="date": Date
- col type="select": City
</div>
</div>
```
This is like the web components approach. This will allow us to seamlessly mix HTML (which is fully extensible) and progressively add components.
## Each component may add additional CSS, JS, libraries
This should be a JavaScript library on npm that runs on the browser and node.js that manipulates the original HTML into a revised HTML (including CSS, JS).
The library controls the output of the entire page. Where required, it:
- adds links to JS / CSS / font / image / ... libraries
- adds snippets of HTML / CSS / JS at the appropriate locations
## This should include a Markdown component
For example:
```html
<div class="g-markdown">
# Heading
Text is unindented first.
```yaml
Code fences are supported
```
```vegam
// ... including arbitrary extensions
```
</div>
```
Another example:
```html
<div class="filters bg-white shadow pt-2 pb-2">
<div class="g-filters">
// example
[
{'on': 'filter-time', 'type': 'daterange'},
{'on': 'filter-status', 'type': 'select', 'name': 'status', 'value': 'Status'},
{'on': 'filter-users', 'type': 'select', 'name': 'user.id', 'value': 'User Name'},
{'on': 'filter-uri', 'type': 'select', 'name': 'uri', 'value': 'Page Name'},
{'on': 'filter-ip', 'type': 'select', 'name': 'ip', 'value': 'IP'}
]
</div>
</div>
```
## This should have a set of components we use in Gramex
- [ ] Markdown
- [ ] Filters
- [ ] Charts
Anything that can be done reasonably easily in Bootstrap is lower priority
## Next steps
Actions for @pratap.vardhan
- [ ] Define a spec for markdown, filters and charts Mon 2-Apr-2018
- [ ] Implement a prototype for all three Wed 4-Apr-2018 (assuming no Republic)
- [ ] Productionization https://code.gramener.com/cto/g1/-/issues/39Editor2018-04-16T05:58:17ZTejeshEditor### Summary
To build editor capability similar to [ui toast](http://ui.toast.com/)
### Benefits
Lets non-developers use g1 components and build charts### Summary
To build editor capability similar to [ui toast](http://ui.toast.com/)
### Benefits
Lets non-developers use g1 components and build chartshttps://code.gramener.com/cto/g1/-/issues/43Sanddance facets2018-04-25T12:38:46ZS AnandSanddance facets```js
var barchart = g1.sanddance({
layout: 'grid'
width: 100,
height: 100,
// Group by category, which is a number from 0 - 3
group: function(d) { return d.category },
facets: [
{x: 0, y: 0, width: 100, height: 20},
...```js
var barchart = g1.sanddance({
layout: 'grid'
width: 100,
height: 100,
// Group by category, which is a number from 0 - 3
group: function(d) { return d.category },
facets: [
{x: 0, y: 0, width: 100, height: 20},
{x: 0, y: 25, width: 100, height: 20},
{x: 0, y: 50, width: 100, height: 20},
{x: 0, y: 75, width: 100, height: 20},
],
data: data
})
d3.selectAll('circle')
.data(data)
.call(barchart)
```
... should create something like this:
![image](/uploads/9d579860345aa8e8b41ce444c3fb4125/image.png)Elango BharathiElango Bharathihttps://code.gramener.com/cto/g1/-/issues/45create label and positional annotation component2018-04-29T05:12:57ZTejeshcreate label and positional annotation componentsample spec
```js
var chart = g1.createChart('scatterplot', data, options)
chart.annotate(position, text, styles)
chart.label(data, {
label: {
col_name: [...],
//example
Continent: ['Asia', 'Europe'],
ID: ['AND', 'ARB'...sample spec
```js
var chart = g1.createChart('scatterplot', data, options)
chart.annotate(position, text, styles)
chart.label(data, {
label: {
col_name: [...],
//example
Continent: ['Asia', 'Europe'],
ID: ['AND', 'ARB']
},
highlight: true,
auto: false
})
```
src: https://blog.datawrapper.de/weeklychart-biocapacity/
![image](/uploads/2cd992ce4538eb92ae519e8b45ca3ffe/image.png)https://code.gramener.com/cto/g1/-/issues/49showcase g1 features demo on UAT2018-06-18T04:18:33ZTejeshshowcase g1 features demo on UATdeploy g1 demo tests on uat which could be used by developers to understand/refer how to use g1 features.deploy g1 demo tests on uat which could be used by developers to understand/refer how to use g1 features.TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/50Implement a time slider component2019-03-05T03:02:19ZTejeshImplement a time slider componenthttps://code.gramener.com/cto/g1/-/issues/53FormHandler Table - Feature to disable column options2019-02-05T10:18:58ZBhanu Kbhanu.kamapantula@gramener.comFormHandler Table - Feature to disable column optionsCurrently, column options are enabled by default
![fh-table-column-options](/uploads/951039e00889a78d3dafbce5132e1f2d/fh-table-column-options.png)
It would be good to have an option to disable it.Currently, column options are enabled by default
![fh-table-column-options](/uploads/951039e00889a78d3dafbce5132e1f2d/fh-table-column-options.png)
It would be good to have an option to disable it.1.51TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/55data reactive mapviewer2018-08-15T14:22:58ZTejeshdata reactive mapviewer- [ ] Integrate mapviewer with urlfilter. This adds support for sliders, dropdowns and input filters.
- [ ] On change of dataset by `urlfilter` or `g1.datafilter`, the layers rendered with corresponding data must redraw themselves eff...- [ ] Integrate mapviewer with urlfilter. This adds support for sliders, dropdowns and input filters.
- [ ] On change of dataset by `urlfilter` or `g1.datafilter`, the layers rendered with corresponding data must redraw themselves efficientlyTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/56Add interactive demo docs - Mapviewer, Formhandler Table2018-09-02T05:35:58ZTejeshAdd interactive demo docs - Mapviewer, Formhandler Table* [x] Must be formatted like [UI components docs](https://learn.gramener.com/guide/uicomponents/)
* [x] Mapviewer docs
* [ ] Formhandler Table* [x] Must be formatted like [UI components docs](https://learn.gramener.com/guide/uicomponents/)
* [x] Mapviewer docs
* [ ] Formhandler TableTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/57formhandler table modal doesnot appear sometimes (needs page refresh to make ...2018-07-16T11:28:23ZTejeshformhandler table modal doesnot appear sometimes (needs page refresh to make it work)TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/58$.highlight example doesn't work2018-06-12T06:20:49ZKarmanya Aggarwal$.highlight example doesn't workFrom the readme.md, even fixing the broken tags in the example doesn't work.From the readme.md, even fixing the broken tags in the example doesn't work.https://code.gramener.com/cto/g1/-/issues/61Componentize ScrollyTelling2018-06-17T16:33:36ZTejeshComponentize ScrollyTellingconfig driven steps with G1 sanddance could be used to build a standard data story quickly.
*Benefits*:
Each project can start having its own data story if they find any insights through built dashboard
*Competitors*:
[ArcGIS](https:...config driven steps with G1 sanddance could be used to build a standard data story quickly.
*Benefits*:
Each project can start having its own data story if they find any insights through built dashboard
*Competitors*:
[ArcGIS](https://www.esri.com/arcgis-blog/products/story-maps/mapping/how-to-cascade/) has scrollytelling maps component completely driven via UI (no code).https://code.gramener.com/cto/g1/-/issues/72formhandler: view option for charts2018-07-16T11:25:09ZPratap Vardhanpratap.vardhan@gramener.comformhandler: view option for charts### Summary
With _by option #71 added.
User will have flexibility to construct large number of usecases from formhandler interface. Currently, table view is the default.
It would be useful to have view dropdown on options to select ...### Summary
With _by option #71 added.
User will have flexibility to construct large number of usecases from formhandler interface. Currently, table view is the default.
It would be useful to have view dropdown on options to select chart type.
- After selecting a chart, ex scatterplot, chart options like x, y, size, color, will be automatically selected from dimensions and metrics in naive order.
- User can modify chart options from a modal popup, to select x, y etc.
- url parameters preserve chart options
- For now, charts with minimal/flat options will be supported
- End URL should be shareable/embeddablehttps://code.gramener.com/cto/g1/-/issues/73g1.datafilter must support groupby2018-07-16T11:30:43ZTejeshg1.datafilter must support groupby### Summary
Inline with issues #71 and #72### Summary
Inline with issues #71 and #72https://code.gramener.com/cto/g1/-/issues/76Update forms / Bootstrap fields based on URLs2018-07-03T07:03:19ZS AnandUpdate forms / Bootstrap fields based on URLsIf the URL is `?state=A&district=B&...`, then `$('.my-form').update(url)` should update the inputs (include select, textarea, Bootstrap dropdowns, etc) with matching keys to have the associated values.
For example,
```
<form class="my-...If the URL is `?state=A&district=B&...`, then `$('.my-form').update(url)` should update the inputs (include select, textarea, Bootstrap dropdowns, etc) with matching keys to have the associated values.
For example,
```
<form class="my-form">
<select name="state">...</select>
<input name="district">
</form>
```
... should change to show the state as A and the district as Bhttps://code.gramener.com/cto/g1/-/issues/78Implement a formhandler Tree View2018-12-19T16:08:43ZTejeshImplement a formhandler Tree ViewReferences:
https://docs.webix.com/desktop__treetable.html
https://frappe.io/datatable - Tree View section
https://gramener.invisionapp.com/d/main#/console/13753225/303473425/preview - BMGF project design linkReferences:
https://docs.webix.com/desktop__treetable.html
https://frappe.io/datatable - Tree View section
https://gramener.invisionapp.com/d/main#/console/13753225/303473425/preview - BMGF project design linkhttps://code.gramener.com/cto/g1/-/issues/79Formhandler Plugin mechanism - Datacomb2018-07-16T11:23:46ZTejeshFormhandler Plugin mechanism - DatacombPlugin Mixin to include functionality easily at almost any level.
To start with https://github.com/cmpolis/datacombPlugin Mixin to include functionality easily at almost any level.
To start with https://github.com/cmpolis/datacombhttps://code.gramener.com/cto/g1/-/issues/80g1 datafilter to support PUT, POST, DELETE like requests2018-07-16T10:57:12ZTejeshg1 datafilter to support PUT, POST, DELETE like requestsThe user must be able to download the modified dataset to any exportable format like Excel, Json, HTML etc.,
Mayebe a non-priority issue
Benefits:
* [ ] https://frappe.io/datatable has an inline data editor.
* [ ] If g1 formhandler...The user must be able to download the modified dataset to any exportable format like Excel, Json, HTML etc.,
Mayebe a non-priority issue
Benefits:
* [ ] https://frappe.io/datatable has an inline data editor.
* [ ] If g1 formhandler table has #72 implemented, this gives capability to answer "What if" questions through a visualisation
* [ ] Tejesh can write tests for `Add:`, `Edit:` features. (using node server itself, without gramex server)https://code.gramener.com/cto/g1/-/issues/82Create a dropdown component for filters2019-06-28T06:54:49ZS AnandCreate a dropdown component for filters- [x] Create a $.dropdown() that supports basic dropdown capability
- [x] Extend for multi-select
- [ ] Integrate with FilterHandler for multiple filters
- [ ] Integrate with FilterHandler for heirarchical filters- [x] Create a $.dropdown() that supports basic dropdown capability
- [x] Extend for multi-select
- [ ] Integrate with FilterHandler for multiple filters
- [ ] Integrate with FilterHandler for heirarchical filters1.51https://code.gramener.com/cto/g1/-/issues/83Equals not working in column dropdown in FormHandler table2019-02-27T06:09:46ZNaveen ManukondaEquals not working in column dropdown in FormHandler table- When we search with equals in first page it is working good.
- When we click on second page equals as we had only one search result again we need to click on first page for getting the result. If we have only one search result can we r...- When we search with equals in first page it is working good.
- When we click on second page equals as we had only one search result again we need to click on first page for getting the result. If we have only one search result can we redirect to 1 page in the table.
- Can we clear the filters without updating the URL?
- Please refer to below gif.![formhabdler_table](/uploads/7ae8c6e09d5ba35a3e0918a04e47f17e/formhabdler_table.gif)1.51TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/87$.filterhandler()2019-05-10T06:19:56ZPragnya Reddypragnya.reddy@gramener.com$.filterhandler()### Summary
Create dropdowns with unique values from data.
### Benefits
Gives user ability to generate dropdowns for usage in dashboard using simple config.
### Usage
```html
$('.product-list').filterhandler({
url: 'filters',
co...### Summary
Create dropdowns with unique values from data.
### Benefits
Gives user ability to generate dropdowns for usage in dashboard using simple config.
### Usage
```html
$('.product-list').filterhandler({
url: 'filters',
cols: ['product', 'city']
})
```
This should create two dropdowns with unique values from the columns product and city.
Extending along with the above, `$.filterhandler()` should be able to handle NavBar filters. Navbar filters include daterangepicker, multi/single select dropdowns, dropdowns that filter down items based on parent dropdowns.
The NavBar filters should have easy extension hooks to operate individually updating URL params or only on click on `<form>` Apply button.
The navBar filters component should have overridable template for "Applied filters" boxes with clear button for each value per UI control or clear all applied filters for same UI control
TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/88Show "ALL ROWS" option in dropdown2018-08-13T02:42:52ZTejeshShow "ALL ROWS" option in dropdown![image](/uploads/e5366e680fa9d507df6d2036feb7bb7a/image.png)
raised by @sarad.gurram![image](/uploads/e5366e680fa9d507df6d2036feb7bb7a/image.png)
raised by @sarad.gurramhttps://code.gramener.com/cto/g1/-/issues/89Retain order of columns when `*` is used for column name in config2019-04-22T09:19:19ZTejeshRetain order of columns when `*` is used for column name in configTejesh to write tests to confirm this happens only when `*` is used, and order is retained if `*` is not used.
raised by @sarad.gurramTejesh to write tests to confirm this happens only when `*` is used, and order is retained if `*` is not used.
raised by @sarad.gurramhttps://code.gramener.com/cto/g1/-/issues/92FormHandler Table: master issue2019-04-09T05:59:51ZS AnandFormHandler Table: master issueThese were tested on g1 0.9.0 using this configuration:
```yaml
url:
formhandler:
pattern: /users
handler: FormHandler
kwargs:
url: users.xlsx
id: user
```
- [x] If a table has few rows, allow column dropdown ...These were tested on g1 0.9.0 using this configuration:
```yaml
url:
formhandler:
pattern: /users
handler: FormHandler
kwargs:
url: users.xlsx
id: user
```
- [x] If a table has few rows, allow column dropdown to go below page. Currently it gets chopped off
![image](/uploads/a9c8da00eddf7429dd6404a06a9f3dfa/image.png)
- [x] After delete action, the row is not deleted in the UI, but it is deleted in the backend. Reloading the page refreshes and shows that the row has been deleted.
- [x] In case of an error on the AJAX submission (e.g. a delete action, add action, etc), there error message clears the table. Instead, the error message should be shown above the table. Ideally, this should be a re-usable function. Other custom actions should be able to just call `.alert(msg)` and re-use the same alerting mechanism
- [ ] If $.formhandler does not find jQuery, Bootstrap, etc, show a visible one-time dismissable warning that can be turned off by default
- [ ] Allow exporting as JSON, CSV (in addition to XLSX). This helps users right-click and copy-paste the URL into applications.
![proxy](/uploads/aac9f1f4976f067762a149e85cd698e2/proxy.gif)
- [ ] Deleting an empty primary key in Excel deletes all rows.
![proxy](/uploads/df82ed66aa08ff1b23334fbe1cab5711/proxy.gif)
- [ ] If all rows in table are deleted, we cannot add rows. Maybe because it loses information on what columns exist.
![proxy](/uploads/141c8140da4fbafc742edd03aa491ef5/proxy.gif)
- [ ] Make Add and Edit easier. On Add / Edit:
- [x] move focus to first input `$('input', ...).focus()`. I want to directly start typing
- [ ] give me a cancel option in red `.btn-danger`
- [x] make the Save button green `.btn-success`
- [x] don't allow both add and edit to happen at the same time
- [x] allow shortcut (Enter) to save
- [ ] TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/99$.dropdown, multiple:true causes url to be incompatible with FormHandler filters2018-10-22T04:38:54ZKarmanya Aggarwal$.dropdown, multiple:true causes url to be incompatible with FormHandler filtersBootstrap-select and $.dropdown return a comma seperated string of multiple values -
currently urlfilter/$.dropdown appends this string as is to the url as opposed to splitting it into key=value pairs that FormHandler expects.Bootstrap-select and $.dropdown return a comma seperated string of multiple values -
currently urlfilter/$.dropdown appends this string as is to the url as opposed to splitting it into key=value pairs that FormHandler expects.https://code.gramener.com/cto/g1/-/issues/101Mapviewer: choropleth must support option of refetching and merging datasets2018-10-05T18:24:51ZTejeshMapviewer: choropleth must support option of refetching and merging datasetsUsecase: When geojson files is same but external dataset changes, developer wants to Refresh colors of map only (without rebuilding the whole vector layer)
raised by @bharath.r as part of ceasefire projectUsecase: When geojson files is same but external dataset changes, developer wants to Refresh colors of map only (without rebuilding the whole vector layer)
raised by @bharath.r as part of ceasefire projectTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/109formhandler table copy/pasteFromClipboard feature2018-11-14T11:37:46ZTejeshformhandler table copy/pasteFromClipboard featureTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/110edit mode for formhandler table for data: option (non-gramex endpoints)2019-02-07T10:43:22ZTejeshedit mode for formhandler table for data: option (non-gramex endpoints)TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/113Multi-column support2018-12-14T05:16:55ZBhanu Kbhanu.kamapantula@gramener.comMulti-column supportTejesh: alter table to create new columns if the data source is `FormHandler` endpoint else add to `JSON` objectTejesh: alter table to create new columns if the data source is `FormHandler` endpoint else add to `JSON` objectTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/117Support multiple datasets2019-02-07T10:43:07ZPragnya Reddypragnya.reddy@gramener.comSupport multiple datasets`$.formhandler` should render multiple tables when `data-src` returns multiple datasets`$.formhandler` should render multiple tables when `data-src` returns multiple datasetsTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/124Data convertor utility2019-02-28T06:49:13ZBhanu Kbhanu.kamapantula@gramener.comData convertor utilityAn utility to convert/transform data structures from one way to another is much needed.
Use case: I've a CSV that can I use to create a bar chart. Using the same for a sunburst layout will need data structure manipulation, a skill restr...An utility to convert/transform data structures from one way to another is much needed.
Use case: I've a CSV that can I use to create a bar chart. Using the same for a sunburst layout will need data structure manipulation, a skill restricted to developers.
Impact on: chart interface. Non developers will be able to create suitable data structures for different charts.
Even for a larger data community this is a useful feature as currently none exist.https://code.gramener.com/cto/g1/-/issues/125Implement a FormHandler form editor2019-02-07T10:42:47ZS AnandImplement a FormHandler form editorAllow users to design a form that updates a single row. Use this to
- edit rows
- as a modal, a separate section, or as an iframe
- rapidly flip between rows using submit / keyboard navigation
- learn from data already typed to ease the...Allow users to design a form that updates a single row. Use this to
- edit rows
- as a modal, a separate section, or as an iframe
- rapidly flip between rows using submit / keyboard navigation
- learn from data already typed to ease the process of filling the form
- support automated columns (e.g. updated time, editor)https://code.gramener.com/cto/g1/-/issues/129g1.urlfilter does not work for checkboxes2020-06-22T08:16:39ZTejeshg1.urlfilter does not work for checkboxes```html
<li class="state_dropdown" filter-name="state_level" data-val="Odisha">
<label class="custom-control custom-checkbox h5 mb-0 text-nowrap cursor-pointer">
<input type="checkbox" class="custom-control-input urlfilter" d...```html
<li class="state_dropdown" filter-name="state_level" data-val="Odisha">
<label class="custom-control custom-checkbox h5 mb-0 text-nowrap cursor-pointer">
<input type="checkbox" class="custom-control-input urlfilter" data-mode="toggle" data-target="#" checked>
<span class="custom-control-label"></span>
<span class="custom-control-description sm2">Odisha</span>
</label>
</li>
```
is expected to update url and also, toggle the state of checkbox. It does neither.
g1.urlfilter's `e.preventDefault` intrudes bootstrap checkbox events.
Possible solutions:
Apply preventDefault only for anchor tags.
```js
if(e.target.tagName.toLowerCase() === 'a') {
e.preventDefault()
}
```
raised by @naveen.manukonda1.52TejeshTejesh2019-07-31https://code.gramener.com/cto/g1/-/issues/135CaptureHanlder should support SVG output2019-01-23T04:03:44ZSundeep Reddy MalluCaptureHanlder should support SVG output### Summary
We need CaptureHandler to export HIGH resolution images. Add SVG export capability in CaptureHandler
### Benefits
Visual outputs that are exported from Visual story board are currently of low resolution. Taking print copie...### Summary
We need CaptureHandler to export HIGH resolution images. Add SVG export capability in CaptureHandler
### Benefits
Visual outputs that are exported from Visual story board are currently of low resolution. Taking print copies of these is resulting in images being blurred. We need SVG output format that can allow us to render HIGH resolution images. This allows for easier printing and circulation of Visual Storyboard content.
### Usage
Print outs of Visual properties become much readable and shareable.https://code.gramener.com/cto/g1/-/issues/136G1.capture utility to download png screenshots2019-01-23T06:08:30ZTejeshG1.capture utility to download png screenshotsHTML2Canvas if used as a frontend alternative for capturehandler, benefits by:
* Need not reload complete dashboard to download png of a single chart on dashboard
* faster than puppeteer
* can capture charts at detailed interaction leve...HTML2Canvas if used as a frontend alternative for capturehandler, benefits by:
* Need not reload complete dashboard to download png of a single chart on dashboard
* faster than puppeteer
* can capture charts at detailed interaction levels (without having to capture complete application state in url)
* can use g1.capture in project deployments where gramex capturehandler can't be packaged offline.TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/138Mapviewer Mismatch label is not hiding on "mismatch: false"2019-01-23T12:24:57ZBharat Rbharath.r@gramener.comMapviewer Mismatch label is not hiding on "mismatch: false""mismatch: false", should hide the label on the map
This is not working properly."mismatch: false", should hide the label on the map
This is not working properly.Bharat Rbharath.r@gramener.comBharat Rbharath.r@gramener.comhttps://code.gramener.com/cto/g1/-/issues/142g1.formhandler table must show unique items in header dropdown for quick filt...2019-02-27T06:09:46ZTejeshg1.formhandler table must show unique items in header dropdown for quick filtering, like Excel![image](/uploads/27d5c68392f0b1d6c6f2ed40f7a55da5/image.png)
raised by @sindhura.ch for bmgf admin panel
Table only with sort minus filters & dropdowns![image](/uploads/27d5c68392f0b1d6c6f2ed40f7a55da5/image.png)
raised by @sindhura.ch for bmgf admin panel
Table only with sort minus filters & dropdowns1.51TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/144Mapviewer automated tests fail on selenium2019-02-04T07:41:20ZS AnandMapviewer automated tests fail on selenium### Summary
### Steps to reproduce
Run `npm run test-chrome` and `npm run test-firefox` after [installing the relevant webdrivers](https://www.seleniumhq.org/download/).
### What is the current *bug* behavior?
Chrome fails. Some of...### Summary
### Steps to reproduce
Run `npm run test-chrome` and `npm run test-firefox` after [installing the relevant webdrivers](https://www.seleniumhq.org/download/).
### What is the current *bug* behavior?
Chrome fails. Some of the errors are:
```
⨯ ok
not ok 569 test/test-mapviewer-data-mismatch.html
⨯ g1.mapviewer test if popup is added to the marker
not ok 603 should be truthy
not ok 604 should be truthy
not ok 605 should be truthy
not ok 606 should be truthy
not ok 607 should be truthy
...
```
Firefox fails. Some of the errors are:
```
⨯ ok
not ok 317 test/test-formhandler-editable.html
⨯ ok
not ok 569 test/test-mapviewer-data-mismatch.html
⨯ $().template() with type=text/vdom animates nodes
not ok 678 x < 95 # This is because Firefox does not support SVG animation via CSS
```TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/146FormHandler table should support search in columns, like in excel2019-02-27T06:09:46ZBhanu Kbhanu.kamapantula@gramener.comFormHandler table should support search in columns, like in excelapart from filtering via unique values (#142) columns in table should support inline searchapart from filtering via unique values (#142) columns in table should support inline search1.51TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/149$.formhandler table filters are not case-sensitive2019-02-15T05:46:52ZVenkata Krishna Reddy$.formhandler table filters are not case-sensitive![eeeeeg](/uploads/e0d54ba50a0c8f54db43ca4524202006/eeeeeg.gif)![eeeeeg](/uploads/e0d54ba50a0c8f54db43ca4524202006/eeeeeg.gif)https://code.gramener.com/cto/g1/-/issues/150g1.formhandler - pick rows for edits2019-02-12T18:10:57ZTejeshg1.formhandler - pick rows for editscurrently edit mode highlights all rows for editing, this is slow on DOM and will be taxing for users with limited hardware configuration
a) if we add selectpicker class for a select element in edit mode, it takes forever and blocks an...currently edit mode highlights all rows for editing, this is slow on DOM and will be taxing for users with limited hardware configuration
a) if we add selectpicker class for a select element in edit mode, it takes forever and blocks any further browsing as it applies for all rows. ex: we've 4 select elements in a row and 300 odd rows.
raised by @bhanu.k1.52TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/151g1.formhandler unique value filtering - handling more than 100 unique values ...2019-02-19T13:53:12ZTejeshg1.formhandler unique value filtering - handling more than 100 unique values per column- If there are more than limit: values (default: 100), show up to limit items. Mention that "Only first {limit} items shown"- If there are more than limit: values (default: 100), show up to limit items. Mention that "Only first {limit} items shown"https://code.gramener.com/cto/g1/-/issues/152data-target='pushState' not working as expected in g1 0.14.02019-04-23T03:47:52ZNaveen Manukondadata-target='pushState' not working as expected in g1 0.14.0```html
<div class="d-md-flex justify-content-md-between custom-w-1">
<div class="align-self-end">
<ul class="nav h1 mb-0 border-success border border-top-0 border-left-0 border-right-0">
<li class="nav-item ">
<a class=...```html
<div class="d-md-flex justify-content-md-between custom-w-1">
<div class="align-self-end">
<ul class="nav h1 mb-0 border-success border border-top-0 border-left-0 border-right-0">
<li class="nav-item ">
<a class="nav-link active urlfilter sm4 pb-2 text-secondary font-weight-bold pl-0 border-secondary border border-top-0 border-left-0 border-right-0 border-2" href="?view=summary" data-target="pushState">Summary <span class="d-block"> View</span></a>
</li>
<li class="nav-item">
<a class="nav-link sm4 pb-2 text-success font-weight-bold pr-0 urlfilter" href="?view=comparative" data-target="pushState"><span class="comparative-tab">Comparative</span> <span class="d-block"> View</span></a>
</li>
</ul>
</div>
</div>
```
When we click on Comparative View my page is reloading in latest **g1** version(0.14.0), Expected: Page reload must not happen because `data-target="pushState"`
It is working fine in **g1** version(0.13.1)1.54TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/154Document FormHandler table issues2019-03-15T05:50:57ZS AnandDocument FormHandler table issues- [x] `link: false` or `link: function () { return false }` in a column should disable the link
- [x] `link: "?col=value"` supports custom filtering. For example, click on `name` column to filter by `?dir=<%- row.path %>`
- [ ] How can w...- [x] `link: false` or `link: function () { return false }` in a column should disable the link
- [x] `link: "?col=value"` supports custom filtering. For example, click on `name` column to filter by `?dir=<%- row.path %>`
- [ ] How can we add classes to specific column headers? (e.g. `text-right` only on numeric classes)
- [ ] How can we open links in a new window? Can we add a link class?
- [ ] How can we use FormHandler table with a JSON dataset (not a FormHandler URL)?
- [ ] How can we create a grid instead of a table?
- [ ] How can we customize just the grid cells?
- [ ] How can we customize just a few columns?
- [ ] How can we create editable tables with dropdown values, and customize their appearance?
- [ ] How can we create editable tables with checkboxes or radio buttons?
- [ ] How can we add custom actions?
- [ ] Show examples of theming (see https://www.smashingmagazine.com/2019/02/complex-web-tables/)https://code.gramener.com/cto/g1/-/issues/155Formhandler - show _count, _limit, _offset also as filters.2019-03-04T03:51:04ZTejeshFormhandler - show _count, _limit, _offset also as filters.On changing pageSize, there is no way to clear the filter. Showing `_limit=` also in filters will help.
Same problem when applied filter `"Europe"`, goto page 2 and clear `"Europe"` filter.....Still shows _offset=1, no way to clear the ...On changing pageSize, there is no way to clear the filter. Showing `_limit=` also in filters will help.
Same problem when applied filter `"Europe"`, goto page 2 and clear `"Europe"` filter.....Still shows _offset=1, no way to clear the filter.
Other solution is to, On click of "clear all filters", remove `_offset=`https://code.gramener.com/cto/g1/-/issues/157Formhandler Excel export options must enable downloading of entire dataset2019-03-12T05:50:13ZTejeshFormhandler Excel export options must enable downloading of entire datasetraised by @anvesh.dasariraised by @anvesh.dasarihttps://code.gramener.com/cto/g1/-/issues/158url.update should support a `replace` parameter2019-03-28T12:01:01ZKarmanya Aggarwalurl.update should support a `replace` parametercurrently with url.update we can add a key to the hash/query params, or update a key if it already exists. we cannot remove a key if it already exists, unless we explicitly call it with a del parameter, which only deletes.
Thus we shoul...currently with url.update we can add a key to the hash/query params, or update a key if it already exists. we cannot remove a key if it already exists, unless we explicitly call it with a del parameter, which only deletes.
Thus we should have a `replace` parameter which can
- add a key if it currently doesn't exist
- remove a key if it exists in hash/search but not in the update object
- update a key if it exists in both hash/search and update object with different values
```?a=1&b=1.update({b:2}, 'replace') -> ?b=2```
places this would be useful eg - if we have a formhandler url in a vega spec or something similar, and want to update it on hashchange to the new hash, we currently have to hardcode a version of the url in code and update it on hashchange.https://code.gramener.com/cto/g1/-/issues/160Mapviewer: cachedata function fails when data contains nested structure2019-03-31T06:20:50ZTejeshMapviewer: cachedata function fails when data contains nested structure`JSON.stringify, avoid TypeError: Converting circular structure to JSON`
https://stackoverflow.com/questions/11616630/json-stringify-avoid-typeerror-converting-circular-structure-to-json`JSON.stringify, avoid TypeError: Converting circular structure to JSON`
https://stackoverflow.com/questions/11616630/json-stringify-avoid-typeerror-converting-circular-structure-to-jsonTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/161g1.formhandler refactor2019-05-08T02:28:20ZTejeshg1.formhandler refactor1. define hierarchy of hooks, make sure it is consistent
2. Examples & documentation
3. Refactor to develop faster1. define hierarchy of hooks, make sure it is consistent
2. Examples & documentation
3. Refactor to develop fasterTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/162G1.datafilter does not filter undefined values2019-04-20T13:59:22ZTejeshG1.datafilter does not filter undefined values1.55TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/163Column filter is displaying multiple times in header when we hide the filter2019-05-08T02:28:28ZAkash BarlaColumn filter is displaying multiple times in header when we hide the filter![Column_hiding_issue](/uploads/5876b231e885375373c38129a3ed27fe/Column_hiding_issue.gif)![Column_hiding_issue](/uploads/5876b231e885375373c38129a3ed27fe/Column_hiding_issue.gif)TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/164Unable to deselect the selected sorted option2019-05-08T02:28:37ZAkash BarlaUnable to deselect the selected sorted option![sort_deselect](/uploads/a7bd6a42973c618f863c80da2cc68eb5/sort_deselect.gif)![sort_deselect](/uploads/a7bd6a42973c618f863c80da2cc68eb5/sort_deselect.gif)TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/165FormHandler input checkbox option is not working2019-05-02T06:06:28ZJPjaiprakash.siyyadri@gramener.comFormHandler input checkbox option is not workingThe requirement is to edit and show column data, which has yes or no values, as input type checkbox.
If it is yes the option should be checked else uncheckedThe requirement is to edit and show column data, which has yes or no values, as input type checkbox.
If it is yes the option should be checked else uncheckedhttps://code.gramener.com/cto/g1/-/issues/166FormHandler Export downloading2019-05-02T08:10:54ZJPjaiprakash.siyyadri@gramener.comFormHandler Export downloadingThe export option should download the data in the same column order as we are showing in the table with title as column namesThe export option should download the data in the same column order as we are showing in the table with title as column namesTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/167G1.formhandler editable table not working for radio/checkbox type input elements2019-05-09T10:21:26ZJPjaiprakash.siyyadri@gramener.comG1.formhandler editable table not working for radio/checkbox type input elementsPossible solutions:
Wrap all editable input elements inside a `<form>` tagPossible solutions:
Wrap all editable input elements inside a `<form>` tagTejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/170Async sub-templates fail sometimes2019-06-04T04:23:11ZS AnandAsync sub-templates fail sometimes@tejesh.p please see https://code.gramener.com/cto/g1/-/jobs/115982
The test case related to "$().template() loaded static async sub templates" fails -- though it passes sometimes (on the server).
Maybe because we're checking before th...@tejesh.p please see https://code.gramener.com/cto/g1/-/jobs/115982
The test case related to "$().template() loaded static async sub templates" fails -- though it passes sometimes (on the server).
Maybe because we're checking before the sub-template has loaded? Could you please explore the test case?TejeshTejeshhttps://code.gramener.com/cto/g1/-/issues/173Move g1.formhandler table , g1.mapviewer modules into separate repos2019-06-26T01:52:32ZTejeshMove g1.formhandler table , g1.mapviewer modules into separate reposWe want to break up g1 into independent repositories. This will popularize g1 components because:
- People prefer libraries with a single purpose
- They are more likely to use it (and contribute back) since the learning curve is less
A...We want to break up g1 into independent repositories. This will popularize g1 components because:
- People prefer libraries with a single purpose
- They are more likely to use it (and contribute back) since the learning curve is less
Approach:
- `mapviewer`: mapviewer.js, leaflet-utils.js
- `urlfilter`: url.js, urlfilter.js, urlchange.js, ajaxchain.js
- `some template library`: template.js
- `sanddance`: sanddance.js
- `g1`: Gramex specific components:
- datafilter.js
- formhandler.js
- translate.js
- ... and other components which we may re-package later
- dropdown.js
- scale.js
- types.js
- highlight.js
- search.js
- fuzzysearch.js
- TODO: Find out how to handle dependencies, e.g. event.js.
Note: g1 will continue to import these libraries and function as before -- fully backward compatible.
### Approach for mapviewer
- Create a repo: github.com/gramener/mapviewer
- Create an npm package called [mapviewer](https://www.npmjs.com/package/mapviewer) via this repo. This should export an ES6 module (src/mapviewer.js) and UMD module (dist/mapviewer.js) via package.json
- Migrate test cases
- Refactor g1 to use import the mapviewer package as an ES6 module
https://code.gramener.com/cto/g1/-/issues/174g1.formhandler editable table to support multi-select in dropdowns2019-07-31T08:51:03ZTejeshg1.formhandler editable table to support multi-select in dropdownsExpose option for more low level spec to support various third-party dropdown components.Expose option for more low level spec to support various third-party dropdown components.https://code.gramener.com/cto/g1/-/issues/175FormHandler filters are not working with multiple tables in a single page2020-02-04T07:11:19ZBharat Rbharath.r@gramener.comFormHandler filters are not working with multiple tables in a single page**FormHandler filters are not working with multiple tables in a single page**
- When applying filters to one table it is applying to all tables by default
- And namespaces are applying only when the namespace is coming from the URL
**S...**FormHandler filters are not working with multiple tables in a single page**
- When applying filters to one table it is applying to all tables by default
- And namespaces are applying only when the namespace is coming from the URL
**Suggested FIX:**
- When a `namespace` is given to table any filter in the url should apply along with the `namespace`
For Ex.
```
$('.fh_table').formHandler({
namespace: 'name'
})
```
The url for the filters of the above snippet should be `?name:key=value`Bharat Rbharath.r@gramener.comBharat Rbharath.r@gramener.comhttps://code.gramener.com/cto/g1/-/issues/176add a new row with empty data for g1.formhandler2019-12-05T11:15:48ZPratap Vardhanpratap.vardhan@gramener.comadd a new row with empty data for g1.formhandler### Summary
We can't add a new row with empty data for g1.formhandler
### Steps to reproduce
- Create a csv with columns alone and hook it up with formhandler### Summary
We can't add a new row with empty data for g1.formhandler
### Steps to reproduce
- Create a csv with columns alone and hook it up with formhandler