this.gridOptions.header = [ {
title: '작성자' /* 작성자 */,
dataIndx: 'createUserNm',
width: 120,
dataType: 'string',
},
{
title: '작성일' /* 작성일 */,
dataIndx: 'createDt',
width: 120,
dataType: 'string',
},
{
title: 'Order Date2',
width: '150',
dataIndx: 'updateDt',
dataType: 'date',
format: 'yy-mm-dd',
cls: 'pq-calendar pq-side-icon',
editor: {
type: 'textbox',
init: function (ui) {
var $inp = ui.$cell.find('input');
var grid = this;
var format = ui.column.format;
var vald = $inp.val();
var val = vald
? $.datepicker.formatDate(format, new Date(vald))
: '';
// initialize the editor
$inp
.attr('readonly', 'readonly')
.val(val)
.datepicker({
changeMonth: true,
changeYear: true,
dateFormat: format,
showAnim: '',
onSelect: function () {
this.firstOpen = true;
},
beforeShow: function (input, inst) {
setTimeout(function () {
$('.ui-datepicker').css('z-index', 999999999999);
});
},
onClose: function () {
this.focus();
},
});
},
},
validations: [
{
type: 'regexp',
value: '^[0-9]{2}/[0-9]{2}/[0-9]{4}$',
msg: '날짜형식에 맞게 입력하세요.',
},
],
},
];
Grid header code.
You can copy/paste just one cell for the "DataType:" header 'date', but an error occurs when you copy/paste by clicking one row. What should I do?
editModel: {
clicksToEdit: 2,
},
2) Through the code above, I can do "clicksToEdit: 2" throughout the header, but can I set "clicksToEdit" separately for each header??