Sinar / popit_ng

Database and API implementation of Popolo standard
GNU Affero General Public License v3.0
22 stars 4 forks source link

what to pull from API be able to display Post_Role correctly on frontend #268

Open OpenHluttawInfrastructure opened 7 years ago

OpenHluttawInfrastructure commented 7 years ago

We added new fields to display “POSITION/ROLE” on the frontend. for now, if you will look at the person detail page again, like the same guy http://openhluttaw.info/en_US/person-detail/?personId=0a38ea8c39dc4fd4a5dc5504a60bfa4d, in En views it’s correctly showing “POSITION/ROLE - MP”, but nothing is showing on my side, here

And i’m sure the data for that are coming from “post_role_en”, “post_role_my” columns from our sheets. and for that person (and many others), data is already there in “post_role_my” , like “လွှတ်တော်ကိုယ်စားလှယ်“, but it’s not displaying on the frontend.

My intentions for this “POSITION/ROLE” is as obvious as to display whether this person is a “MP” or both a “MP”, and “Minister of this Ministry” etc.

OpenHluttawInfrastructure commented 7 years ago

at first i thought, its not displaying the backend's "post_role" in the frontend's “POSITION/ROLE" the At All. But no, it already does displaying, and display Correctly on Some MPs. Like this one - http://openhluttaw.info/en_US/person-detail/?personId=7c77665ab3fb4ce781e48b7b4906207d , it shows and shows correctly on the en_US side. But nothing is displaying in "ရာထူး/ တာဝန်" on My_MM side - http://openhluttaw.info/my_MM/person-detail/?personId=7c77665ab3fb4ce781e48b7b4906207d

But not displaying at all for some other persons like him - http://openhluttaw.info/en_US/person-detail/?personId=6b230aed436e4fed996f57d3c0e411a6 , he belongs to this Committee - "memberships_Pyithu_Hluttaw_Education_Promotion_Committee"

kay-wong commented 7 years ago

Fixed so that the organization names show up for the committee the person is a member of. Will rerun the rest of the membership committees updates.

Re the issue of post_roles/labes not showing up when the data is pulled, I believe it's cos the post roles/labels are not filled in in the memberships_committees spreadsheet. So they have memberships for their respective committees in Popit, but the roles/labels fields are empty. The ones that do correctly return post roles for committees, like this person, actually had that detail imported from another instance before these current Google sheet imports. http://openhluttaw.info/en_US/person-detail/?personId=7c77665ab3fb4ce781e48b7b4906207d http://api.openhluttaw.org/en/persons/7c77665ab3fb4ce781e48b7b4906207d

OpenHluttawInfrastructure commented 7 years ago

I think this is the answer "The ones that do correctly return post roles for committees, like this person, actually had that detail imported from another instance before these current Google sheet imports." to our puzzle here! :)

Because, when I checked the "memberships_committees spreadsheet" none of them have been filled with data in the post_role/lables yet. But there actually already are a lot of MPs, like this 7c77665ab3fb4ce781e48b7b4906207d guy's Role is showing.

Now i cant even recall where and how did we made these "Committee Member" data entry for the post_roles in which sheet before, but looks like it was done somehow some time ago! So therefore, i am not sure if these Post Roles are correct or not, and looks like everyone is assigned as a "Committee Member"

So, Anyway, I will fill in the "memberships_committees spreadsheet" with correct and update data, so that correct information like "Committee member" or "Chairman of the Committee" "Secretary of the Committee" shows up.