serge-web / serge

Serious Gaming, Evolved - web interface
https://sites.google.com/deepbluec.com/serge/
Apache License 2.0
14 stars 4 forks source link

Core mapping - Admin Page #2970

Closed lebaphi closed 1 month ago

lebaphi commented 3 months ago

Fixes #2971

lebaphi commented 1 month ago

After remove properties, this property is still on the exist core/Milsym and show as ID. We should also remove the property on core/Milsym on gameplay.

When you create a new property and then create a new shape, it will be saved to the database (new shape with new property). Therefore, when you remove that property, it still exists in the shape as a property. If you want to fix this behavior, when an admin deletes a property, I think we should look up this property of each feature in the feature collection and then delete it. What do you think @IanMayo

Aah, thanks for taking the time to explain that @lebaphi .

There isn't an easy answer. But, let's separate "game design" from "game play". The properties are most likely to change during the game design phase before features are added. Features will only really be created during game play. I do not believe we have to update/fix existing features to reflect properties being added or removed. The current set of "valid" properties are only observed when creating a new feature.

Thanks @IanMayo, so I think this issue is invalid @Tristina1788

Tristina1788 commented 1 month ago

@lebaphi @IanMayo Now the tool is missing although this role has all permission

image

image

This is screencast :

https://github.com/user-attachments/assets/9cbaddc2-2f6a-4ec2-bff5-447528412fcf

lebaphi commented 1 month ago

@lebaphi @IanMayo Now the tool is missing although this role has all permission

image

image

This is screencast :

2024-07-16_15-24-20.mp4

I think you need to select an item and the toolbar will update the status @Tristina1788, each item has its own permissions but I think there are some minor issues with this. i.e.: select Red to make the Move button appear, then try moving Green (Green doesn't have Move permission).

Tristina1788 commented 1 month ago

@lebaphi @IanMayo Now the tool is missing although this role has all permission image image This is screencast : 2024-07-16_15-24-20.mp4

I think you need to select an item and the toolbar will update the status @Tristina1788, each item has its own permissions but I think there are some minor issues with this. i.e.: select Red to make the Move button appear, then try moving Green (Green doesn't have Move permission).

Yes, and how happens if user role don't have any item to select. Example I add Green force has all permission for Green ( no permission with another forcce). So when login with green, no item show to select and I can't create new item for this role. And this way it's hard for user know that he can create new item. @IanMayo How do you think?

IanMayo commented 1 month ago

Yes, and how happens if user role don't have any item to select. Example I add Green force has all permission for Green ( no permission with another forcce). So when login with green, no item show to select and I can't create new item for this role. And this way it's hard for user know that he can create new item. @IanMayo How do you think?

Thanks @Tristina1788 - having a go at reproducing it.

IanMayo commented 1 month ago

Yes, and how happens if user role don't have any item to select. Example I add Green force has all permission for Green ( no permission with another forcce). So when login with green, no item show to select and I can't create new item for this role. And this way it's hard for user know that he can create new item. @IanMayo How do you think?

Thanks @Tristina1788 - having a go at reproducing it.

Ok, I think I understand it. I've created a new issue to handle it #2996

Tristina1788 commented 1 month ago

@lebaphi Yes, we can 'Edit/Remove Feature', 'Move/Resize Feature' although user don't have this permission by this way i.e.: select Red to make the Move button appear, then try moving Green (Green doesn't have Move permission). . So we should fix it.

image

image

Tristina1788 commented 1 month ago

@lebaphi @IanMayo

image

https://github.com/user-attachments/assets/c6d44777-d22f-4aae-b2a3-d3fb96562d76

image

image

Tristina1788 commented 1 month ago

@lebaphi I see some conflicts. Please resolve them then I can check it.

Tristina1788 commented 1 month ago

@lebaphi I got error when run yarn build. Please help me check again.

image

Tristina1788 commented 1 month ago

@lebaphi @IanMayo

image

https://github.com/user-attachments/assets/7674345b-9923-4a82-b774-87eed189b80d

image

https://github.com/user-attachments/assets/4355d525-f99d-485e-b635-8b018063ca4d

lebaphi commented 1 month ago

But I still don't see our system use URL and Max Native zoom. Can you explain how it work on our system?

Hi @Tristina1788 , URL is Url Template in this link https://leafletjs.com/reference.html#tilelayer, about Max Native Zoom, I think @IanMayo can help 😄

IanMayo commented 1 month ago

But I still don't see our system use URL and Max Native zoom. Can you explain how it work on our system?

Hi @Tristina1788 , URL is Url Template in this link https://leafletjs.com/reference.html#tilelayer, about Max Native Zoom, I think @IanMayo can help 😄

@lebaphi - I'm pretty sure the URL (and maybe maximum zoom) values from the channel should replace these hard-coded values: image

lebaphi commented 1 month ago

But I still don't see our system use URL and Max Native zoom. Can you explain how it work on our system?

Hi @Tristina1788 , URL is Url Template in this link https://leafletjs.com/reference.html#tilelayer, about Max Native Zoom, I think @IanMayo can help 😄

@lebaphi - I'm pretty sure the URL (and maybe maximum zoom) values from the channel should replace these hard-coded values: image

Yep, that is what we have: image

IanMayo commented 1 month ago

Great, @lebaphi - could you take these values from the channel definition instead please?

Tristina1788 commented 1 month ago

@lebaphi @IanMayo

image

https://github.com/user-attachments/assets/b31f5d3c-64b6-4713-aff5-d8811f5798ad

Tristina1788 commented 1 month ago

@lebaphi @IanMayo

image

https://github.com/user-attachments/assets/2a62318e-d887-48de-b9ec-5cd998a12cf8

lebaphi commented 1 month ago

Now I added 'Umpire' with full permission on 'Umpire', but I can't update properties of Umpire item

Hi @Tristina1788, can you check it again on your side, maybe incognito browser? It seems to work on my side

https://github.com/user-attachments/assets/e2012593-7d97-4a77-9690-387f03e81ebd

Tristina1788 commented 1 month ago

Now I added 'Umpire' with full permission on 'Umpire', but I can't update properties of Umpire item

Hi @Tristina1788, can you check it again on your side, maybe incognito browser? It seems to work on my side

Screen.Recording.2024-07-26.at.8.36.17.PM.mov

@lebaphi I checked on incognitor and the issue still happens. Please uncheck permission for 'Red Force' with 'Move/Resize Feature' = False, 'Edit Pros' = false and check again for Umpire user.

image

Tristina1788 commented 1 month ago

@lebaphi @IanMayo I can't update force property

https://github.com/user-attachments/assets/c0d115a7-7a0d-4e66-a924-f64160a3a33d

Steps:

  1. set setting for participants of 'Umpire' role like below

image

  1. set setting for enable to update force for 'Core' renderer

image

  1. Login user 'Umpire' - Game designer, notice user can't update Force propery of a 'umpire' core shape to 'Red' / 'Blue'
Tristina1788 commented 1 month ago

@lebaphi @IanMayo

https://github.com/user-attachments/assets/cf057ad6-b9dd-4f78-a654-f804ae7a9ab5

Steps:

  1. Update permission for user only has permission 'View Spartial'

image

  1. Login to the user, try to click item on map or items list on the left to view properties. But user can't see properties of that item.

image

More details on video :

https://github.com/user-attachments/assets/0667540f-031f-4659-afb3-e2b214092e9f

lebaphi commented 1 month ago

User can't view properties although he has permission 'View Spartial'

HI @Tristina1788, user need to have 'View Props' permission to view the item's properties. Items are only visible on the mapping table when 'View Spatial' permission is set to true

Tristina1788 commented 1 month ago

ser need to have 'View Props' permission to view the item's properties. Items are only visible on the mapping table when 'View Spatial' permission is set to true

@lebaphi @IanMayo yes, I mean that. But at that time, I 'm wrong the case . Here is the video for that issue.

https://github.com/user-attachments/assets/54b2c3b1-89d4-48ab-9126-acc09d3cd2fe

Anyway, it's fixed now.

https://github.com/user-attachments/assets/5f2b6f96-b5be-48c1-99c4-50261b4d39a7