Problems with Hebrew in datepicker - datepicker

I am using datepicker and I want it to work in Hebrew.
I found this: https://jqueryui.com/datepicker/#localization
but I don't want the user to choose a language. I want ths datepicker to work only in Hebrew.
How can I do that?
I tried this:
$.datepicker.setDefaults($.datepicker.regional['he']);
i got an answer from Sooriya Dasanayake but now I am trying to add date range and that doesn't work:
from = $( "#from" ).datepicker({
defaultDate: "+4w",
changeMonth: true,
numberOfMonths: 3,
showButtonPanel: true,
showOn: "button",
showAnim:"blind",
onSelect: function( selectedDate ) {
$( "#from" ).datepicker( $.datepicker.regional[ "en-GB" ] );
$( "#locale" ).change(function() {
$( "#from" ).datepicker( "option",
$.datepicker.regional[ $( this ).val() ] );
})
}
})
.on( "change", function() {
to.datepicker( "option", "minDate", getDate( this ) );
}),
to = $( "#to" ).datepicker({
changeMonth: true,
numberOfMonths: 3,
showButtonPanel: true,
showOn: "button",
showAnim:"blind",
onSelect: function( selectedDate ) {
$( "#to" ).datepicker( $.datepicker.regional[ "en-GB" ] );
$( "#locale" ).change(function() {
$( "#to" ).datepicker( "option",
$.datepicker.regional[ $( this ).val() ] );
})
}
})
.on( "change", function() {
from.datepicker( "option", "maxDate", getDate( this ) );
});
function getDate( element ) {
var date;
try {
date = $.datepicker.parseDate( dateFormat, element.value );
} catch( error ) {
date = null;
}
return date;
}
});

Try this..
jQuery(function($){
$.datepicker.regional['he'] = {
closeText: 'סגור',
prevText: '<הקודם',
nextText: 'הבא>',
currentText: 'היום',
monthNames: ['ינואר','פברואר','מרץ','אפריל','מאי','יוני',
'יולי','אוגוסט','ספטמבר','אוקטובר','נובמבר','דצמבר'],
monthNamesShort: ['ינו','פבר','מרץ','אפר','מאי','יוני',
'יולי','אוג','ספט','אוק','נוב','דצמ'],
dayNames: ['ראשון','שני','שלישי','רביעי','חמישי','שישי','שבת'],
dayNamesShort: ['א\'','ב\'','ג\'','ד\'','ה\'','ו\'','שבת'],
dayNamesMin: ['א\'','ב\'','ג\'','ד\'','ה\'','ו\'','שבת'],
weekHeader: 'Wk',
dateFormat: 'dd/mm/yy',
firstDay: 0,
isRTL: true,
showMonthAfterYear: false,
yearSuffix: ''};
$.datepicker.setDefaults($.datepicker.regional['he']);
});

Related

ag-grid data for detailCellRendererParams not displaying

I'm trying to add a nested grid inside an existing grid. I'm very new at this, and although I'm able to display the grid, I cannot seem to display the data. When I do console.log(params), I have all my data, but no matter what I try, I cannot display the data. I think the problem is with my getDetailRowData, and what I'm passing to the successCallback function. Any ideas?
this is my component ts file
import { Component, OnInit } from '#angular/core';
import { ReportService } from 'src/app/services/report.service';
import { Report } from 'src/app/models/report';
import { agThemeSgBootstrap } from "#sg-bootstrap/ag-grid";
import {GridOptions, Module} from 'ag-grid-community';
import { DatePipe } from '#angular/common';
#Component({
selector: 'app-report',
templateUrl: './report.component.html',
styleUrls: ['./report.component.scss']
})
export class ReportComponent implements OnInit {
apiUrl: any;
reports : Report[];
gridOptions: GridOptions;
dateValue = new Date();
maxDate = new Date();
private detailCellRendererParams;
private columnDefs;
// public modules: Module[] = AllModules;
constructor(private reportService : ReportService, private datePipe: DatePipe) {
this.columnDefs = [
{headerName: 'Report Name', field: 'reportName', cellRenderer: 'agGroupCellRenderer',
resizable: true,
valueGetter: params => { return `${params.data.reportName}.dat` }},
{headerName: 'Sent to FIS', field: 'sentToFis',resizable: false,
valueGetter: params => { return params.data.sentToFis === true ? "Yes" : "No" } },
{headerName: 'File Size', field: 'contentLength', resizable: true,
valueGetter: params => { return `${this.formatBytes(params.data.contentLength)}` }},
{headerName: 'Last Modified', field: 'lastModified', resizable: true,
valueGetter: params => { return this.datePipe.transform(params.data.lastModified, "yyyy-MM-dd HH:mm:ss") }},
];
this.detailCellRendererParams = {
detailGridOptions: {
columnDefs: [
{headerName: 'ADSL Path', field: 'adslPath', resizable: true,
valueGetter: params => { return params.data.adlsFullPath}},
{headerName: 'Version', field: 'version', resizable: true,
valueGetter: params => { return params.data.sentToFis}},
{headerName: 'Source', field: 'source', resizable: true,
valueGetter: params => { return params.data.adlsFullPath}},
],
},
getDetailRowData: function(params) {
params.successCallback(params.data.children);
console.log(params.data);
}
}
}
ngOnInit() {
this.callReportService(new Date())
}
reportDateChange(value: Date) {
let currentValue = this.datePipe.transform(this.dateValue, "yyyyMMdd")
let newSelectedValue = this.datePipe.transform(value, "yyyyMMdd")
if (currentValue != newSelectedValue) {
if (this.gridOptions.api) {
this.gridOptions.api.showLoadingOverlay();
}
this.callReportService(value)
this.dateValue = value;
}
}
callReportService(value: Date) {
this.reportService.getReportsForDate(value).subscribe(x=> {
this.reports = x;
this.gridOptions.api.sizeColumnsToFit();
})
}
ngAfterContentInit() {
let agOpt = { ...{
animateRows: true,
enableRangeSelection: true,
defaultColDef: {
editable: false,
enableValue: false,
enableRowGroup: false,
enablePivot: true,
filter: true,
sortable: true
},
statusBar: {
statusPanels: [{
statusPanel: 'agTotalRowCountComponent',
align: 'left'
},
{
statusPanel: 'agFilteredRowCountComponent'
},
{
statusPanel: 'agSelectedRowCountComponent'
},
{
statusPanel: 'agAggregationComponent'
},
],
}
}, ...agThemeSgBootstrap }
this.gridOptions = { ...this.gridOptions, ...agOpt }
}
onGridReady(params) {
params.api.setDomLayout("autoHeight");
params.api.sizeColumnsToFit();
}
onGridSizeChanged(params) {
params.api.sizeColumnsToFit();
}
ngAfterViewInit() {
this.dateValue = new Date()
}
formatBytes(bytes, decimals = 2) {
if (bytes === 0) return '0 Bytes';
const k = 1024;
const dm = decimals < 0 ? 0 : decimals;
const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
const i = Math.floor(Math.log(bytes) / Math.log(k));
return parseFloat((bytes / Math.pow(k, i)).toFixed(dm)) + ' ' + sizes[i];
}
}
my html file
<div class="container-fluid">
<div class="col-xs-12 col-12 col-md-3 form-group row">
<label for="reportDate" class="col-form-label">Report Date:</label>
<div class="col-sm-4 col-md-7">
<input id="reportDate"
class="form-control"
#dp="bsDatepicker"
(bsValueChange)="reportDateChange($event)"
[maxDate]="maxDate"
bsDatepicker
[bsValue]="dateValue" [bsConfig]="{ isAnimated: true, adaptivePosition: true, dateInputFormat: 'YYYY-MM-DD', containerClass: 'theme-red' }"/>
</div>
</div>
<div class="row">
<div class="col">
<ag-grid-angular
style="width: 100%; height: 300px;"
class="ag-theme-sg-bootstrap"
[gridOptions]="gridOptions"
[masterDetail]="true"
[detailCellRendererParams]="detailCellRendererParams"
[rowData]="reports"
[columnDefs]="columnDefs"
(gridReady)="onGridReady($event)"
(gridSizeChanged)="onGridSizeChanged($event)">
</ag-grid-angular>
</div>
</div>
</div>

Why are so many documents getting fetched in Meteor?

My application is fetching a huge number of documents from the server in Meteor. I've tried optimizing the Live Query to reduce this, but I'm still getting several thousand documents per hour when the collection.find().count() is just 13.
Subscription:
Template.calendar.onCreated( function() {
var self = this;
self.ready = new ReactiveVar();
PostSubs = new SubsManager();
self.autorun(function() {
var handle = PostSubs.subscribe('meals');
self.ready.set(handle.ready());
});
});
Publication:
Meteor.publish('meals', function() {
return Meals.find({
userId : this.userId,
start : {
$gte : moment().subtract(2, 'w').format("YYYY-MM-DD"),
$lte : moment().add(2,'w').format("YYYY-MM-DD")
}
});
return this.ready();
});
Usage in context:
Template.calendar.onRendered(() => {
$( '#meals-calendar' ).fullCalendar({
defaultView: 'basicWeek',
firstDay: 1,
height: 200,
editable: true,
events( start, end, timezone, callback ) {
let data = Meals.find().fetch().map( ( event ) => {
return event;
});
if ( data ) {
callback( data );
}
},
eventRender( event, element ) {
element.find( '.fc-content' ).html(
`<strong>${ event.title }</strong>`
);
},
dayClick( date ) {
Session.set( 'eventModal', { type: 'add', date: date.format() } );
$( '#add-edit-event-modal' ).modal( 'show' );
$('#title').focus();
},
eventClick( event ) {
Session.set( 'eventModal', { type: 'edit', event: event._id } );
$( '#add-edit-event-modal' ).modal( 'show' );
},
eventDrop( event, delta, revert ) {
let date = event.start.format();
let update = {
_id: event._id,
start: date
};
Meteor.call( 'editEvent', update, ( error ) => {
if ( error ) {
Bert.alert( error.reason, 'danger' );
}
});
},
});
Tracker.autorun( () => {
Meals.find().fetch();
$( '#meals-calendar' ).fullCalendar( 'refetchEvents' );
});
});

autoComplete (jquery.auto-complete.js) categories with label metadata

I am able to do basic labels and categories using
http://jqueryui.com/autocomplete/#categories
but my need without using
$.widget( "custom.catcomplete", $.ui.autocomplete, {});
how i am able to do this using
jQuery( ".class" ).autoComplete({ });
https://goodies.pixabay.com/jquery/auto-complete/demo.html
However, I was wondering if its possible to attach some metadata with label. For example...
"[{ label: \"labelname1\", category: \"cat1\" },{ label: \"labelname2\", category: \"cat1\" },
{ label: \"labelname3\", category: \"cat2\" },{ label: \"labelname4\", category: \"cat2\" },
{ label: \"labelname5\", category: \"cat2\" },
];"
I want to something like :
cat1
-labelname1
-labelname2
cat2
-labelname3
-labelname4
-labelname5
Note: only use by jQuery( ".class" ).autoComplete({ });
ref : > https://goodies.pixabay.com/jquery/auto-complete/demo.html
I guess is this you are looking for:
jQuery(document).ready(function($) {
$( ".class" ).autocomplete({
source: [ { label: "labelname1", category: "cat1" }, { label: "labelname2", category: "cat2" }, { label: "labelname3", category: "cat3" } ],
select: function( event, ui ) {
$( ".class" ).val( ui.item.label );
return false;
}
})
.data( "ui-autocomplete" )._renderItem = function( ul, item ) {
return $( "<li>" )
.data( "ui-autocomplete-item", item )
.append( "<a>" + item.category + "<br>" + item.label + "</a>" )
.appendTo( ul );
};
});
I hope it helps

How to create pages with different containers using routing in ui5

I am trying to create a splitapp application using routing in ui5. My first page is a login page. Then the next page should be a splitapp which I am not able to do.
I am not able to navigate to the splitapp from login page using routing. My routing url is getting changed but the splitapp view is not getting loaded.
enter code here
// component.js
jQuery.sap.declare("sap.demo.cart.Component");
sap.ui.core.UIComponent.extend("sap.demo.cart.Component",{
metadata:{
routing:{
config:{
viewType:"JS",
viewPath:"shopcart",
targetAggregation:"pages",
clearTarget:false
},
routes:[
{
pattern: "",
name: "login",
view: "login",
viewType:"JS",
viewPath:"shopcart",
targetControl:"topMaster"
},
{
pattern: "splitApp",
name:"app",
view:"app",
targetControl:"topMaster",
clearTarget:false,
subroutes:[{
pattern: "master",
name:"master",
view:"master",
targetAggregation:"masterPages",
targetControl:"splitApp"
preservePageInSplitContainer:true
subroutes:[{
pattern:"welcome",
name:"welcome",
view:"welcome",
targetAggregation:"detailPages"
}]
}]
}
]
}
},
init: function(){
jQuery.sap.require("sap.ui.core.routing.HashChanger");
jQuery.sap.require("sap.m.routing.RouteMatchedHandler");
sap.ui.core.UIComponent.prototype.init.apply(this,arguments);
this._router = this.getRouter();
this._routerHandler = new sap.m.routing.RouteMatchedHandler(this._router);
this._router.initialize();
},
createContent:function(){
var oView = sap.ui.view({
id:"tmaster",
viewName:"shopcart.topMaster",
type:"JS",
viewData:{component: this}
});
return oView;
}
});
/*login.view*/
sap.ui.jsview("shopcart.login", {
getControllerName : function() {
return "shopcart.login";
},
createContent : function(oController) {
var opanel = new sap.m.Panel(
{
width:"100%",
height:"100%",
expandable : false,
expanded: true,
content:[
new sap.m.Panel("ologin",{
headerText:"Login",
width:"400px",
height:"300px",
content:[
new sap.m.Input("uname",{ tooltip:"Enter Username",placeholder : "Username"}),
new sap.m.Input("pwd",{ type: sap.m.InputType.Password,placeholder : "Password"}),
new sap.m.Link("fgt",{text:"Forgot Password?", press:oController.onForgot}),
new sap.m.Button("log",{text:"Login", press:[oController.onLogin, oController]}),
new sap.m.Button("clr",{text:"Clear", press:oController.onClear})
]
})
]
}).addStyleClass("logContainer");
return sap.m.Page({
content:[opanel]
});
}
});
/*login controller*/
sap.ui.controller("shopcart.login", {
onInit: function() {
this.router = sap.ui.core.UIComponent.getRouterFor(this);
},
onLogin: function(){
var uname = sap.ui.getCore().byId("uname").getValue();
var pwd = sap.ui.getCore().byId("pwd").getValue();
if(uname=="" || pwd=="")
{
// openDialog(sap.ui.core.ValueState.Error,"Login Details","Please provide both the username and password details to login");
}
else{
// app.to("idhome2");
this.router.navTo("app");
}
},
onClear:function(){
sap.ui.getCore().byId("uname").setValue("");
sap.ui.getCore().byId("pwd").setValue("");
},
onForgot:function(){
openDialog(sap.ui.core.ValueState.None,"Forgot Password","Resetting is still under construction");
}
});
/*topmaster.view*/
sap.ui.jsview("shopcart.topMaster", {
createContent : function(oController) {
return new sap.m.App("topMaster",{
});
}
});
/*app.view*/
sap.ui.jsview("shopcart.app", {
getControllerName : function() {
return "shopcart.app";
},
createContent : function(oController) {
this.setDisplayBlock(true);
return new sap.m.SplitApp("splitApp");
}
});
/*master.view*/
sap.ui.jsview("shopcart.master", {
getControllerName : function() {
return "shopcart.master";
},
createContent : function(oController) {
var olist = new sap.m.List({
mode:sap.m.ListMode.SingleSelect,
items : [ new sap.m.StandardListItem({
title : "Employee Master"
}), new sap.m.StandardListItem({
title : "Product Master"
}),new sap.m.StandardListItem({
title : "Category Master"
}),new sap.m.StandardListItem({
title : "Order Master"
}),new sap.m.StandardListItem({
title : "Operation Master"
}) ]
});
return olist;
}
});
/*welcome.view */
sap.ui.jsview("shopcart.welcome", {
getControllerName : function() {
return "shopcart.welcome";
},
createContent : function(oController) {
return new sap.m.Text({text:"Welcome to Oncall Support Maintenance Fiori Application",design:sap.ui.commons.TextViewDesign.H5});
}
});
Have a look at this code. Pay attention to the TopMaster controller and to the routing config in the Component.
jQuery.sap.require("sap.m.MessageBox");
jQuery.sap.declare("shopcart.Component");
sap.ui.core.UIComponent.extend(
"shopcart.Component",
{
metadata:{
rootView : {
viewName: "shopcart.view.TopMaster",
type: sap.ui.core.mvc.ViewType.JS
},
routing:{
config:{
viewType: "JS",
viewPath: "shopcart.view",
targetControl: "topMaster",
targetAggregation: "pages",
clearTarget: false
},
routes: [
{
pattern: "",
name: "login",
view: "Login"
},
{
pattern: "splitApp",
name: "app",
view: "App",
subroutes:[
{
pattern: "master",
name: "master",
view: "Master",
targetAggregation: "masterPages",
targetControl: "splitApp",
preservePageInSplitContainer: true,
subroutes: [
{
pattern: "welcome",
name: "welcome",
view: "Welcome",
targetControl: "splitApp",
targetAggregation: "detailPages"
}
]
}
]
}
]
}
},
init: function(){
sap.ui.core.UIComponent.prototype.init.apply(
this,
arguments
);
var oRouter = this.getRouter();
oRouter.initialize();
}
}
);
// <-- TopMaster.view.js -->
sap.ui.jsview(
"shopcart.view.TopMaster",
{
getControllerName : function() {
return "shopcart.controller.TopMaster";
},
createContent : function(oController) {
return new sap.m.App(
"topMaster"
);
}
}
);
// <-- TopMaster.controller.js -->
sap.ui.controller(
"shopcart.controller.TopMaster",
{
onInit: function() {
var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
oRouter.attachRouteMatched(this.onRouteMatched, this);
},
onRouteMatched: function(oEvent) {
var oParameters = oEvent.getParameters();
var oView = this.getView();
var oApp = sap.ui.getCore().byId("topMaster");
if (oApp.getCurrentPage().sId !== oParameters.view.sId) {
oApp.to(oParameters.view.sId);
}
}
}
);
// <-- login.view -->
sap.ui.jsview(
"shopcart.view.Login",
{
getControllerName : function() {
return "shopcart.controller.Login";
},
createContent : function(oController) {
return new sap.m.Page(
{
title: "Login",
content: [
new sap.m.Panel(
{
width:"100%",
height:"100%",
expandable : false,
expanded: true,
content:[
new sap.m.Panel(
"ologin",
{
headerText:"Login",
width:"400px",
height:"300px",
content:[
new sap.m.Input(
this.createId("uname"),
{
tooltip: "Enter Username",
placeholder: "Username"
}
),
new sap.m.Input(
this.createId("pwd"),
{
type: sap.m.InputType.Password,
placeholder: "Password"
}
),
new sap.m.Link(
this.createId("fgt"),
{
text:"Forgot Password?",
press: oController.onForgot
}
),
new sap.m.Button(
this.createId("log"),
{
text:"Login",
press:[
oController.onLogin,
oController
]
}
),
new sap.m.Button(
this.createId("clr"),
{
text:"Clear",
press:oController.onClear
}
)
]
}
)
]
}
)
.addStyleClass("logContainer")
]
}
);
}
}
);
// <-- Login.controller.js -->
sap.ui.controller(
"shopcart.controller.Login",
{
onInit: function() {
},
onLogin: function(){
var oView = this.getView();
var sUsername = oView.byId("uname").getValue();
var sPassword = oView.byId("pwd").getValue();
if( sUsername === "" || sPassword === ""){
sap.m.MessageBox.alert(
"Please provide your login details",
{
title: "Error"
}
);
}
else{
var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
oRouter.navTo("welcome");
}
},
onClear:function(){
var oView = this.getView();
oView.byId("uname").setValue(null);
oView.byId("pwd").setValue(null);
},
onForgot:function(){
sap.m.MessageBox.alert(
"Resetting is still under construction",
{
title: "Error"
}
);
}
}
);
// <-- App.view.js -->
sap.ui.jsview(
"shopcart.view.App",
{
getControllerName : function() {
return "shopcart.controller.App";
},
createContent : function(oController) {
this.setDisplayBlock(true);
return new sap.m.SplitApp(
"splitApp"
);
}
}
);
// <-- App.controller.js -->
sap.ui.controller(
"shopcart.controller.App",
{
onInit: function() {
}
}
);
// <-- Master.view.js -->
sap.ui.jsview(
"shopcart.view.Master",
{
getControllerName : function() {
return "shopcart.controller.Master";
},
createContent : function(oController) {
return new sap.m.List(
{
mode:sap.m.ListMode.SingleSelect,
items : [
new sap.m.StandardListItem(
{
title : "Employee Master"
}
),
new sap.m.StandardListItem(
{
title : "Product Master"
}
),
new sap.m.StandardListItem(
{
title : "Category Master"
}
),
new sap.m.StandardListItem(
{
title : "Order Master"
}
),
new sap.m.StandardListItem(
{
title : "Operation Master"
}
)
]
}
);
}
}
);
// <-- Master.controller.js -->
sap.ui.controller(
"shopcart.controller.Master",
{
onInit: function() {
}
}
);
// <-- Welcome.view.js -->
sap.ui.jsview(
"shopcart.view.Welcome",
{
getControllerName : function() {
return "shopcart.controller.Welcome";
},
createContent : function(oController) {
return new sap.m.Text(
{
text: "Welcome to Oncall Support Maintenance Fiori Application"
}
);
}
}
);
// <-- Welcome.controller.js -->
sap.ui.controller(
"shopcart.controller.Welcome",
{
onInit: function() {
}
}
);
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv='Content-Type' content='text/html;charset=UTF-8'/>
<link href="css/index.css" rel="stylesheet"/>
<script src="resources/sap-ui-core.js"
id="sap-ui-bootstrap"
data-sap-ui-libs="sap.ui.commons"
data-sap-ui-theme="sap_bluecrystal">
</script>
<!-- add sap.ui.table,sap.ui.ux3 and/or other libraries to 'data-sap-ui-libs' if required -->
<script>
function Login(){
**window.location.assign("dashboard.html#/dashboard");**
}
</script>
</head>
<body class="sapUiBody" role="application">
<div id="content">
<div id="content-center-alignment">
<div class="inner">
<img alt="" src="">
<input id="txtUsername" type="text" placeholder="Enter user name"></input>
<br/>
<input id="txtPassword" type="password" placeholder="Enter your password"></input>
<br/>
<button id="btnLogin" type="submit" onClick="Login();" class="button">Login</button>
</div>
</div>
</div>
</body>
</html>
just add **stared line in your index.html by doing this you can able to redirect to another view from index.html

Datatables with Jeditable, how do I setup initially in edit mode? (or always be in edit mode)

Is it possible to have the Jeditable field start off in edit mode when using the datatables plugin?
Jeditable website says the solution (not using thru Datatables) :
You can trigger the used event when your document loads. For example:
$(function() {
$("#editable").trigger("click");
How do I access it in datatables, here's my code:
var oTable;
$(function () {
oTable = $('#calendarTable').dataTable({
"bPaginate": false,
"bSort": false,
"bFilter": false,
"bInfo": false,
"aoColumns": [
null,
null,
null,
null,
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": false },
{ "bVisible": true }
]
});
//$("#editable").trigger("click");
// oTable.fnGetNodes()).editable.trigger("click");
oTable.editable("disable");
var year;
var lobid;
var officeid;
year = $('#hv_year').val();
lobid = $('#hv_lob').val();
officeid = $('#hv_office').val();
var url;
url = "save.asp";
url = url + "?year=" + year;
url = url + "&lobid=" + lobid;
url = url + "&officeid=" + officeid;
/* Apply the jEditable handlers to the table */
$('td:eq(4)', oTable.fnGetNodes()).editable(url, {
"callback": function (sValue, y) {
var aPos = oTable.fnGetPosition(this);
oTable.fnUpdate(sValue, aPos[0], aPos[1]);
},
"submitdata": function (value, settings) {
return {
"row_id": this.parentNode.getAttribute('id'),
"column": oTable.fnGetPosition(this)[2]
};
},
tooltip: 'Click to Edit',
height: "40px",
type: 'textarea',
onblur: 'ignore',
cancel: 'Cancel',
submit: 'Save',
indicator: '<img src="images/loader.gif">'
});
I think you can just chain the click:
$('td:eq(4)', oTable.fnGetNodes()).editable(url, {
"callback": function (sValue, y) {
var aPos = oTable.fnGetPosition(this);
oTable.fnUpdate(sValue, aPos[0], aPos[1]);
},
"submitdata": function (value, settings) {
return {
"row_id": this.parentNode.getAttribute('id'),
"column": oTable.fnGetPosition(this)[2]
};
},
tooltip: 'Click to Edit',
height: "40px",
type: 'textarea',
onblur: 'ignore',
cancel: 'Cancel',
submit: 'Save',
indicator: '<img src="images/loader.gif">'
}).trigger("click");