Это мой код Qweb:
Код: Выделить всё
Jusqu'au mois courant:[/b][b]
Jusqu'au fin d'année:[/b]
Код: Выделить всё
$("#radio_budget_cumulee_jusque_mois_courant, #radio_budget_cumulee_jusque_fin_anneee").change(function(){
est_jusqu_mois_courant=self.$el.find('#radio_budget_cumulee_jusque_mois_courant').is(':checked')
est_jusqu_finannee=self.$el.find('#radio_budget_cumulee_jusque_fin_anneee').is(':checked')
var mod=new instance.web.Model("itk.compta.dashboard");
mod.call("itk_compta_dashboard_fct_changer_vue",[est_jusqu_mois_courant],{}).done(function(res) {
});
self.do_action({
type: 'ir.actions.client',
tag: 'reload',
});
// $radios.filter('[value=fin]').prop('checked', est_jusqu_finannee);
//$radios.filter('[value=courant]').prop('checked', est_jusqu_mois_courant);
//I tried to use this code
var $radios = $('input:radio[name=radio_budget_cumulee]');
$radios.filter('[value=fin]').attr('checked', est_jusqu_finannee);
$radios.filter('[value=courant]').attr('checked', est_jusqu_mois_courant);
// ANd i tried this code
radiobtnmois_courant = document.getElementById("radio_budget_cumulee_jusque_mois_courant");
radiobtnmois_courant.checked = false;
radiobtnfin_anneee = document.getElementById("radio_budget_cumulee_jusque_fin_anneee");
radiobtnfin_anneee.checked = true;
});
Пожалуйста, помогите?
Подробнее здесь: https://stackoverflow.com/questions/325 ... ading-page