Merge branch 'main' of https://git.dbnt.co.kr/DBNT/geoinfo_eGov_work
commit
93b56a1744
|
|
@ -711,6 +711,7 @@ function fn_grid_refresh(){
|
|||
fn_isMsg();
|
||||
fn_onLoad();
|
||||
fn_MakeDataArray();
|
||||
fn_ConvertGridData(); // DB에서 값없음(-999); 화면에서 갑없음(-); kendo grid에서 값 없음(null) 처리
|
||||
fn_kendoGrid();
|
||||
fn_setGridCombo();
|
||||
|
||||
|
|
@ -754,7 +755,20 @@ function fn_grid_refresh(){
|
|||
});
|
||||
/* 탭 & 엔터키 이동 끝 */
|
||||
}
|
||||
/**
|
||||
* DB에서 값없음(-999); 화면에서 갑없음(-); kendo grid에서 값 없음(null) 처리
|
||||
*/
|
||||
function fn_ConvertGridData() {
|
||||
if (!Array.isArray(gridData)) return;
|
||||
|
||||
gridData.forEach(item => {
|
||||
if (item.sampleGs == -999) item.sampleGs = null;
|
||||
if (item.sampleWc == -999) item.sampleWc = null;
|
||||
if (item.sampleLl == -999) item.sampleLl = null;
|
||||
if (item.samplePi == -999) item.samplePi = null;
|
||||
if (item.sampleRd == -999) item.sampleRd = null;
|
||||
});
|
||||
}
|
||||
function fn_kendoGrid() {
|
||||
var nullTypeString = 'test';
|
||||
|
||||
|
|
@ -801,12 +815,12 @@ function fn_grid_refresh(){
|
|||
sampleDepthTo: { type: "number" },
|
||||
sampleSamplingMethod: { type: "string" },
|
||||
sampleShape: { type: "string" },
|
||||
sampleWc: { type: "number", defaultValue: "-"},
|
||||
sampleGs: { type: "number", defaultValue: "-"},
|
||||
sampleLl: { type: "number", defaultValue: "-" },
|
||||
samplePi: { type: "number", defaultValue: "-" },
|
||||
sampleWc: { type: "number", defaultValue: null},
|
||||
sampleGs: { type: "number", defaultValue: null},
|
||||
sampleLl: { type: "number", defaultValue: null },
|
||||
samplePi: { type: "number", defaultValue: null },
|
||||
sampleDesc: { type: "string" },
|
||||
sampleRd: { type: "number", defaultValue: "-" },
|
||||
sampleRd: { type: "number", defaultValue: null },
|
||||
sampleUscs: { type: "string" },
|
||||
sampleCode: { type: "string", editable: false },
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,8 +52,12 @@ function numericEditor(container, options, isHyphenAllowed = false) {
|
|||
|
||||
|
||||
function numericEditor2(container, options, isHyphenAllowed = false) {
|
||||
var input = kendoJQuery('<input type="test" name="' + options.field + '" class="k-textbox" style="width:100%; text-align:right;" />');
|
||||
|
||||
let rawVal = options.model[options.field];
|
||||
if (rawVal === -999) {
|
||||
options.model.set(options.field, null);
|
||||
rawVal = null;
|
||||
}
|
||||
var input = kendoJQuery('<input type="text" name="' + options.field + '" data-bind="value:' + options.field + '" class="k-textbox" style="width:100%; text-align:right;" />');
|
||||
input.appendTo(container)
|
||||
.val(options.model[options.field])
|
||||
|
||||
|
|
@ -66,6 +70,12 @@ function numericEditor2(container, options, isHyphenAllowed = false) {
|
|||
this.value = val.slice(0, -1);
|
||||
}
|
||||
})
|
||||
.on("focus", function () {
|
||||
if (this.value === "") {
|
||||
this.value = "-";
|
||||
}
|
||||
this.select();
|
||||
})
|
||||
|
||||
// 2. ↑ ↓ 키로 값 증가/감소
|
||||
.on("keydown", function (e) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue