added improvements on set proces and minor other improvements
This commit is contained in:
@@ -36,11 +36,16 @@ let $bam = {
|
||||
let fds = bool(ix.fds, false), id = ix.taID, m = [];
|
||||
m.push({ lbl: $bct.smd, fnc: () => { $bam.smd(id); } });
|
||||
m.push({ lbl: $bct.ati, fnc: () => { $bam.ati(id); } });
|
||||
if (bool(ix.IsManual, false) === true) {
|
||||
m.push({ lbl: $bct.mbc, fnc: () => { $bam.mbc(id); } });
|
||||
m.push({ lbl: $bct.mbd, fnc: () => { $bam.mbd(id); } });
|
||||
}
|
||||
return $('#topbar').ocmsmenu(m);
|
||||
}, eM : (r, re, opt) => {
|
||||
let m = [];
|
||||
if ($fis.isAuth('fds_bam', 2) === true) {
|
||||
m.push({ lbl: $bct.upl, fnc: $bam.ubs});
|
||||
m.push({ lbl: $bct.mbe, fnc: $bam.mbe});
|
||||
}
|
||||
if (bool(r, false) === true) {
|
||||
m.push({ lbl: $bct.rel, fnc: $bam.renderLst });
|
||||
@@ -312,6 +317,32 @@ let $bam = {
|
||||
}
|
||||
}
|
||||
});
|
||||
}, mbe: () => {
|
||||
$bam.manForm({});
|
||||
}, mbc: (taid) => {
|
||||
$ocms.postXT({
|
||||
url: $ocms.url('bam/mget'), data: { taid: taid }, success: (dta) => {
|
||||
$bam.manForm(dta || {});
|
||||
}
|
||||
});
|
||||
}, mbd: (taid) => {
|
||||
if (confirm($bct.mbdc)) {
|
||||
$ocms.postXT({
|
||||
url: $ocms.url('bam/mdel'), data: { taid: taid }, success: () => {
|
||||
$bam.renderLst();
|
||||
}
|
||||
});
|
||||
}
|
||||
}, manForm: (dta) => {
|
||||
let flds = $bcol.man.clone().applyValues(dta || {});
|
||||
$ocms.dlgform(flds, {
|
||||
title: (ne(dta.taID, '') !== '') ? $bct.mbc : $bct.mbe,
|
||||
url: $ocms.url('bam/man'),
|
||||
typedvalues: true,
|
||||
success: () => {
|
||||
$bam.renderLst();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user