You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
2.2 KiB
JavaScript

import { _Report } from '{js}lap-page-module.js?v={time}';
_fullScreen();
window.BukuBesar = _Report
.qr(`
SELECT 1=1 total
`)
.debug(false)
.conf({
tahun: function (obj, e) {
if (obj.dataSum) {
obj.dataSum = {}
}
return e.getVal('tahun');
}
, anggota: function (obj, e) {
return e.getVal('anggota') != '' ? ` WHERE a.kode = '${e.getVal('anggota')}'` : ``;
}
})
.customeButton(function(){
})
.filterConf([
{
type: 'node',
temp: function () {
return div().class('col-sm-4')
.child(
div()
)
.get()
}
},
{
type: 'node',
temp: function () {
return div().class('col-sm-8')
.child(
div().text('ok')
)
.get()
}
},
{
title: 'Anggota',
type: 'select',
name: 'anggota',
row: 12,
data: _json('anggota'),
readonly: false,
action: function () {
},
}
, {
title: 'Tahun',
type: 'text',
name: 'tahun',
row: 12,
readonly: false,
info: "Inputkan tahun kemudian submit",
action: function () {
},
}
])
.filterOnLoad(function (e, status) {
/*event action*/
if (status != false) {
e.setVal('tahun', 2023);
_id('tahun').addEventListener('keyup', delay(function () {
let val = this.value.match(/(\d+)/);
let c = this;
setTimeout(function () {
c.value = val[0];
}, 0)
}, 10), false)
}
})
.head([])
.name([
{
name: 'total',
css: {
border: '1px solid #ddd',
padding: '2px 5px'
}
, custome: function (a, b, obj) {
return a;
}
}
])
.call()