From: www-data Date: Sun, 2 Jan 2022 21:43:32 +0000 (+0100) Subject: Fixe budget nouveau. Be able to add a new budget X-Git-Url: https://git.ebersold.fr/?a=commitdiff_plain;h=98021ef7059efb015624032642abbc3492527ff1;p=www%2Fsyndic.git Fixe budget nouveau. Be able to add a new budget --- diff --git a/app/compta/api_budget.php b/app/compta/api_budget.php index 0f4ca6f..e09f1a6 100644 --- a/app/compta/api_budget.php +++ b/app/compta/api_budget.php @@ -24,7 +24,6 @@ class Budget extends Api { select bu_id, p.per_string, bu_desc from Budget as b JOIN Period as p on b.bu_period_id = p.per_id order by p.per_string; __EOF; $res = $this->doQueryI($q); - error_log("getBudgets ".$this->db." Calls ".$res["total_matches"]); return $res['records']; } /** diff --git a/app/compta/views/budget_nouveau.php b/app/compta/views/budget_nouveau.php index 80bb354..0c6e3c9 100644 --- a/app/compta/views/budget_nouveau.php +++ b/app/compta/views/budget_nouveau.php @@ -57,13 +57,14 @@ requirejs(["require", "exports" , "cpt/Dialog" , "cpt/services" , "cpt/budget"], function (req,exp,ts,xj,xf,dlg,srv,myApp) { - console.log("starting Budget nouveau application..."); - var Budget = myApp.Budget.Budget; - $('panel-budgets').addClassName('hidden'); -Prototype.Event.observe($("btBuApply"), "click", function () { - console.log("btBuApply pushed"); + console.log("starting Budget nouveau application..."); + var Budget = new myApp.Budget.DlgBudget("budget", + "/app/compta/forms.php?panel=exercice", + "/app/compta/index.php"); + $('panel-budgets').addClassName('hidden'); + Prototype.Event.observe($("btBuApply"), "click", function () { Budget.addBudget($("budget_anne").value,$('budget_desc').value); - }); + }); });