handsontable

Binding Handsontable cells to complex objects

白昼怎懂夜的黑 提交于 2019-12-24 12:40:23
问题 I'm trying to use Handsontable for some basic editing and number formatting. The data, including formatting info is fetched from the server and would look similar to this: var data = [ [ { num:'1.1', color:'red' }, { num:'2.2', color:'green' } ], [ { num:'3.4', color:'yellow' }, { num:'4.4', color:'blue' } ] ]; Now, I would like to pass this data to my Handsontable and have each cell display/edit the .num values. By using a custom renderer and editor (briefly explained here: Understanding

How to parse large data via POST query

谁说我不能喝 提交于 2019-12-24 08:30:07
问题 I am creating a webpage having Excel like features to create a Plan.For this i need to fill an initial form and click on submit button , then submit the form using ajax to a server side PHP script which inserts these records to a Mysql table. But the issue is i can only transfer 1-2 records of table using the POST Query as there is a limit to it.What should i do in this case?Is there any other way of doing it without expanding the POST query limit? My Front end code(.js) </script> buttons

Synchronize horizontal scrolling of two handsontables

微笑、不失礼 提交于 2019-12-24 07:59:07
问题 I'd like to synchronize the scrolling of two handsontables in a shiny app. I tried some attempts based on proposals given here and here. I also tried with the jquery.scrollSync library, my code is below. Nothing works. library(shiny) library(rhandsontable) ui = shinyUI(fluidPage( tags$head(tags$script(src = "http://trunk.xtf.dk/Project/ScrollSync/jquery.scrollSync.js")), sidebarLayout( sidebarPanel(), mainPanel( rHandsontableOutput("hot", width = 350), rHandsontableOutput("hot2", width = 350)

duplicate headers when using Handsontable

谁都会走 提交于 2019-12-24 04:06:32
问题 I am working with Handsontable, and the headers are shown twice. What is causing this to happen? This is my code: <script type="text/javascript"> $(document).ready(function () { var data = [ ['2009', 0, 2941, 4303, 354], ['2010', 3, 2905, 2867, 412], ['2011', 4, 2517, 4822, 552], ['2012', 2, 2422, 5399, 776] ], container = document.getElementById('example'), hot; hot = new Handsontable(container, { data: data, minSpareRows: 1, colHeaders: true, contextMenu: true, colHeaders: ['Cuenta Única',

How to add properties dynamically to each object in an javascript array

不羁的心 提交于 2019-12-24 03:23:53
问题 I am trying to loop through an array of objects to prepend a property and value to each object . The order of the tables is important because I am trying to use a handsontable view as a client to retrieve the contents of a server side mysql table. I want the handsontable view to have the same column order as the table , but I want to insert a checkbox column as the first column to allow record selection. I have a fiddle http://jsfiddle.net/kc11/juo1e4at/#base that does the loop, but I'm not

HandsOnTable - destroy and re-create not working after upgrading from 0.11.0 to 0.15.0-beta 2

感情迁移 提交于 2019-12-23 12:03:34
问题 I have code like below: HTML <div id="rangePricesGrid" class="handsontable" style="width: auto; overflow: auto"></div> Javascript: var rangePriceGrid = $('#rangePricesGrid').handsontable('getInstance'); if (rangePriceGrid != undefined) { rangePriceGrid.destroy(); if (setRangeGridOptions != undefined) rangePriceGrid = $('#rangePricesGrid').handsontable(setRangeGridOptions); } else { if (setRangeGridOptions != undefined) rangePriceGrid = $('#rangePricesGrid').handsontable(setRangeGridOptions);

Javascript Handsontable - Uncaught TypeError: Cannot read property 'insertBefore' of undefined

爱⌒轻易说出口 提交于 2019-12-23 04:09:15
问题 I'm using the handsontable library for creating neat tables. I literally copied the tutorial but the console (web developer console) gives me the following error: Uncaught TypeError: Cannot read property 'insertBefore' of undefined handsontable.full.js:4471 I link both the .css and the .js file correctly in the <head> tags. My javascript looks like this: var data = [ ["", "Ford", "Volvo", "Toyota", "Honda"], ["2016", 10, 11, 12, 13], ["2017", 20, 11, 14, 13], ["2018", 30, 15, 12, 13] ]; var

Remove the bottom margin of a handsontable

三世轮回 提交于 2019-12-20 07:44:03
问题 I am using Chrome Version 61.0.3163.100 (Official Build) (64-bit) or Safari Version 11.0 (12604.1.38.1.7) under Mac OS Sierra 10.12.6. I want to create a handsontable, whose height may exceeds the height of the screen: https://jsbin.com/bobevafana/edit?html,output I realize that there is always a bottom margin below the table, does anyone know how to remove it? var app = angular.module('app', ['ngHandsontable']); app.controller('Ctrl', ['$scope', '$filter', '$timeout', 'hotRegisterer',

How can I change the color of a changed cell in Handsontable?

馋奶兔 提交于 2019-12-20 05:23:22
问题 I am using the Handsontable plugin and when the user changes the values in the cell, it should turn yellow so they can keep track of what has been changed. In this case, yellow is class .changeInput. The tricky part is when you double click the cell to change it, this becomes a textarea and no longer a td. Any ideas? Thanks in advance. http://jsfiddle.net/PAH5J/ jQuery $("textarea.handsontableInput").change(function (){ //$(this).find(td).addClass('changeInput'); $('.htNumeric .current')

When using Handsontable how to force a selected cell into edit mode?

二次信任 提交于 2019-12-18 19:17:19
问题 Handsontable provides some nice hooks for when a cell is selected but I can't seem to figure out way to get it to allow me to force a cell into edit mode when it has been selected. I can detect the cell selection like this: Handsontable.PluginHooks.add( 'afterSelection', function( row, column ) { var current_td = this.getCell( row, column ); }); And from there I can even obtain the cell element that was selected. But from there I can't seem to trigger the cell into edit mode (where it has an