liquid_feedback_frontend

diff model/member.lua @ 1843:b01d9920371b

merge
author jbe
date Thu Feb 03 15:57:22 2022 +0100 (2022-02-03)
parents 446d2798f424
children
line diff
     1.1 --- a/model/member.lua	Thu Feb 03 15:54:23 2022 +0100
     1.2 +++ b/model/member.lua	Thu Feb 03 15:57:22 2022 +0100
     1.3 @@ -837,6 +837,19 @@
     1.4    return self.__units_with_polling_right_hash[unit_id] and true or false
     1.5  end
     1.6  
     1.7 +function Member.object:get_single_unit_id()
     1.8 +  populate_units_with_voting_right_hash(self)
     1.9 +  local single_unit_id
    1.10 +  local count = 0
    1.11 +  for unit_id in pairs(self.__units_with_voting_right_hash) do
    1.12 +    single_unit_id = unit_id
    1.13 +    count = count + 1
    1.14 +  end
    1.15 +  if count == 1 then
    1.16 +    return single_unit_id
    1.17 +  end
    1.18 +end
    1.19 +
    1.20  function Member.object:get_delegatee_member(unit_id, area_id, issue_id)
    1.21    local selector = Member:new_selector()
    1.22    if unit_id then

Impressum / About Us