Browse Source

remove logs

gh-pages
kevmodrome 6 years ago
parent
commit
3d7bde554d
No known key found for this signature in database GPG Key ID: E8F9CD141E63BF38
  1. 2
      packages/standard-components/src/DataGrid/Component.svelte
  2. 2
      packages/standard-components/src/DataGrid/valueSetters.js

2
packages/standard-components/src/DataGrid/Component.svelte

@ -22,10 +22,8 @@
let columnDefs let columnDefs
onMount(async () => { onMount(async () => {
console.log(datasource)
const jsonModel = await _bb.api.get(`/api/models/${datasource.modelId}`) const jsonModel = await _bb.api.get(`/api/models/${datasource.modelId}`)
const { schema } = await jsonModel.json() const { schema } = await jsonModel.json()
console.log(schema)
if (!isEmpty(datasource)) { if (!isEmpty(datasource)) {
data = await fetchData(datasource) data = await fetchData(datasource)
columnDefs = Object.keys(schema).map(key => { columnDefs = Object.keys(schema).map(key => {

2
packages/standard-components/src/DataGrid/valueSetters.js

@ -1,8 +1,6 @@
// https://www.ag-grid.com/javascript-grid-value-setters/ // https://www.ag-grid.com/javascript-grid-value-setters/
// These handles values and makes sure they adhere to the data type provided by the model // These handles values and makes sure they adhere to the data type provided by the model
export const number = (params) => { export const number = (params) => {
console.log('Params: ', params)
console.log('New Value: ', parseFloat(params.newValue))
params.data[params.colDef.field] = parseFloat(params.newValue); params.data[params.colDef.field] = parseFloat(params.newValue);
return true; return true;
} }
Loading…
Cancel
Save