Remove export permission (if you can view you can export)
This commit is contained in:
parent
c518cbc20d
commit
db0797345c
4 changed files with 0 additions and 40 deletions
|
|
@ -85,7 +85,6 @@ func RoleAdd(c *fiber.Ctx) error {
|
|||
role.RestoreMember = (c.FormValue("restore_member") == "on")
|
||||
role.PurgeMember = (c.FormValue("purge_member") == "on")
|
||||
role.ConvertMemberToContact = (c.FormValue("convert_member_to_contact") == "on")
|
||||
role.ExportMember = (c.FormValue("export_member") == "on")
|
||||
|
||||
// Contact permissions
|
||||
role.ShowContact = (c.FormValue("show_contact") == "on")
|
||||
|
|
@ -96,7 +95,6 @@ func RoleAdd(c *fiber.Ctx) error {
|
|||
role.RestoreContact = (c.FormValue("restore_contact") == "on")
|
||||
role.PurgeContact = (c.FormValue("purge_contact") == "on")
|
||||
role.ConvertContactToMember = (c.FormValue("convert_contact_to_member") == "on")
|
||||
role.ExportContact = (c.FormValue("export_contact") == "on")
|
||||
|
||||
if len(errors) == 0 {
|
||||
result := db.Create(&role)
|
||||
|
|
@ -160,7 +158,6 @@ func RoleEdit(c *fiber.Ctx) error {
|
|||
role.RestoreMember = (c.FormValue("restore_member") == "on")
|
||||
role.PurgeMember = (c.FormValue("purge_member") == "on")
|
||||
role.ConvertMemberToContact = (c.FormValue("convert_member_to_contact") == "on")
|
||||
role.ExportMember = (c.FormValue("export_member") == "on")
|
||||
|
||||
// Contact permissions
|
||||
role.ShowContact = (c.FormValue("show_contact") == "on")
|
||||
|
|
@ -171,7 +168,6 @@ func RoleEdit(c *fiber.Ctx) error {
|
|||
role.RestoreContact = (c.FormValue("restore_contact") == "on")
|
||||
role.PurgeContact = (c.FormValue("purge_contact") == "on")
|
||||
role.ConvertContactToMember = (c.FormValue("convert_contact_to_member") == "on")
|
||||
role.ExportContact = (c.FormValue("export_contact") == "on")
|
||||
|
||||
if len(errors) == 0 {
|
||||
result := db.Save(&role)
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@ type Role struct {
|
|||
RestoreMember bool
|
||||
PurgeMember bool
|
||||
ConvertMemberToContact bool
|
||||
ExportMember bool
|
||||
ShowContact bool
|
||||
CreateContact bool
|
||||
EditContact bool
|
||||
|
|
@ -22,5 +21,4 @@ type Role struct {
|
|||
RestoreContact bool
|
||||
PurgeContact bool
|
||||
ConvertContactToMember bool
|
||||
ExportContact bool
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,10 +58,6 @@
|
|||
<td>Convertir membres en contacts</td>
|
||||
<td>{% if Role.ConvertMemberToContact %}Oui{% else %}Non{% endif %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Exporter membres (CSV)</td>
|
||||
<td>{% if Role.ExportMember %}Oui{% else %}Non{% endif %}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
|
@ -106,10 +102,6 @@
|
|||
<td>Convertir contacts en membres</td>
|
||||
<td>{% if Role.ConvertContactToMember %}Oui{% else %}Non{% endif %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Exporter contacts (CSV)</td>
|
||||
<td>{% if Role.ExportContact %}Oui{% else %}Non{% endif %}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -154,19 +154,6 @@
|
|||
</label>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<input
|
||||
type="checkbox"
|
||||
class="form-check-input me-2"
|
||||
id="export_member"
|
||||
name="export_member"
|
||||
{% if Role.ExportMember %}checked{% endif %}
|
||||
>
|
||||
<label for="export_member" class="form-label">
|
||||
Exporter membres (CSV)
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="mb-3 mt-4">
|
||||
<b>Permissions - Contacts</b>
|
||||
</div>
|
||||
|
|
@ -275,19 +262,6 @@
|
|||
</label>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<input
|
||||
type="checkbox"
|
||||
class="form-check-input me-2"
|
||||
id="export_contact"
|
||||
name="export_contact"
|
||||
{% if Role.ExportContact %}checked{% endif %}
|
||||
>
|
||||
<label for="export_contact" class="form-label">
|
||||
Exporter contacts (CSV)
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="mt-3">
|
||||
<button class="btn btn-primary" type="submit">
|
||||
<i class="me-1 bi-floppy"></i>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue