[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[EP-tech] How to allow edit specific metadata for certain user?
- Subject: [EP-tech] How to allow edit specific metadata for certain user?
- From: drn at ecs.soton.ac.uk (David R Newman)
- Date: Thu, 3 Feb 2022 12:12:37 +0000
- In-reply-to: <EMEW3|3217c36872953e85354e9ac3b7ff38a7y12C2U14eprints-tech-bounces|ecs.soton.ac.uk|CAANJ=pi9dM_a8=3eu9gu815oGyTbcT68yRQ69bjJawi4UYm_gQ@mail.gmail.com>
- References: <CAANJ=pi9dM_a8=3eu9gu815oGyTbcT68yRQ69bjJawi4UYm_gQ@mail.gmail.com> <CAANJ=pi9dM_a8=3eu9gu815oGyTbcT68yRQ69bjJawi4UYm_gQ@mail.gmail.com> <EMEW3|3217c36872953e85354e9ac3b7ff38a7y12C2U14eprints-tech-bounces|ecs.soton.ac.uk|CAANJ=pi9dM_a8=3eu9gu815oGyTbcT68yRQ69bjJawi4UYm_gQ@mail.gmail.com> <05677206-0e82-df57-29ff-c451dcd731f9@ecs.soton.ac.uk>
Hi Izwan,
If you just want to limit this field to be editable in the workflow to
editors and admins you can put the field in an if statement like the
following into
EPRINTS_PATH/archives/ARCHIVE_NAME/cfg/workflows/eprint/default.xml:
<epc:if test="$STAFF_ONLY = 'TRUE'" >
? <field ref="item_status" />
</epc:if>
If you need some more complex restriction you may need to do something like:
<epc:if test="$current_user{usertype} = 'admin' or
$current_user{usertype} = 'local_admin' or $current_user{usertype} =
'editor'">
<epc:if test="$current_user{username} = 'joe.bloggs'">
Where the part in {} is the name of the field within the user record you
want to match.? I am not sure if you can do partial matches of a string
without taking a closer look of the available comparator operators you
have available in EPC.
Regards
David Newman
On 03/02/2022 11:54, MOHD.IZWAN SALIM via Eprints-tech wrote:
> *CAUTION:* This e-mail originated outside the University of Southampton.
> Dear all
>
> I create a specific metadata - Item Status : Processing | Binding | Shelve
>
> I would like o specific?this metadata editing for only certain users.
>
> Can I achieve that with the Roles function?
>
> Regards
>
> *Izwan*
> Librarian
> UiTM Institutional Repository
> <https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fir.uitm.edu.my%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C0827ed0d996e44da355b08d9e70e7790%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637794871578812170%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=H2G%2Fo5zLdTqOFONwxqjZLCzCFCm%2FR%2Fl%2BwParNmLqhRk%3D&reserved=0>
>
> *PENAFIAN: *E-mel ini dan apa-apa fail yang dihantar bersama-samanya
> ("Mesej") adalah dihasratkan hanya untuk kegunaan penerima yang
> dinyatakan di atas dan mungkin mengandungi maklumat yang tidak umum,
> bermilik, istimewa, sulit dan dikecualikan dari penzahiran di bawah
> undang-undang yang terpakai termasuklah Akta Rahsia Rasmi 1972. BACA
> SELANJUTNYA...
> <https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmail.uitm.edu.my%2Findex.php%2Fcomponent%2Fcontent%2Farticle%3Fid%3D2%26Itemid%3D103&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C0827ed0d996e44da355b08d9e70e7790%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637794871578812170%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=ZbkfATIcTTHxEUdTOZRCbuCKiNarHgwRwQVWfyctk1o%3D&reserved=0>
>
> ------------------------------------------------------------------------
> *DISCLAIMER :*/This e-mail and any files transmitted with it
> ("Message") is intended only for the use of the recipient(s) named
> above and may contain information that is non-public, proprietary,?
> privileged,? confidential? and? exempt? from disclosure under
> applicable law including the Official Secrets Act 1972. /READ MORE...
> <https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmail.uitm.edu.my%2Findex.php%2Fcomponent%2Fcontent%2Farticle%3Fid%3D2%26Itemid%3D103&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C0827ed0d996e44da355b08d9e70e7790%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637794871578812170%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=ZbkfATIcTTHxEUdTOZRCbuCKiNarHgwRwQVWfyctk1o%3D&reserved=0>
>
> *** Options:http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech
> *** Archive:https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.eprints.org%2Ftech.php%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C0827ed0d996e44da355b08d9e70e7790%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637794871578812170%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=%2F%2FMiNQ2tXT%2BhcuJgkAAUNoghuSuadoekqYaw5D%2Bjrtc%3D&reserved=0
> *** EPrints community wiki:https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwiki.eprints.org%2F&data=04%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C0827ed0d996e44da355b08d9e70e7790%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637794871578812170%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=dSGr2ij9cUyyIl0qiXZ7KBiNnb0XLuRv7et7l9X4Dgw%3D&reserved=0
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ecs.soton.ac.uk/pipermail/eprints-tech/attachments/20220203/44823f7d/attachment-0001.html