From dba4a12f0ac9115aa0d6edf449f16f8da8c49b87 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 9 Dec 2014 20:21:17 +0000 Subject: [PATCH] If selected project changes, update pricelist to match --- timesheet/js/app.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/timesheet/js/app.js b/timesheet/js/app.js index 2e6df6030c..92b813fe72 100644 --- a/timesheet/js/app.js +++ b/timesheet/js/app.js @@ -106,6 +106,12 @@ app.classes.timesheet = AppJS.extend( */ pm_id_changed: function(_egw, _widget) { + // Update price list + var ts_pricelist = _widget.getRoot().getWidgetById('pl_id'); + egw.json('projectmanager_widget::ajax_get_pricelist',[_widget.getValue()],function(value) { + ts_pricelist.set_select_options(value||{}) + }).sendRequest(true); + var ts_project = this.et2.getWidgetById('ts_project'); if (ts_project) {