Skip to Content Skip to Menu

Field default value

  • timstohr
  • timstohr
  • OFFLINE
  • Posts: 1091
  • Thanks: 56
  • Karma: 9
3 years 4 months ago #325696 by timstohr
Field default value was created by timstohr
Hi Kyle.
I have fields which are basically my access level control (eg give Employee the right to access CRM etc...). The fields themselves work perfectly.
I would like to set it so that if the value is left empty, then it should enter the value 2 (which is No for me).

At the same time, I want to be able to import users and set the value of the user to 1 during the import or leave it blank .

Lets make it easier. I want the field to have either value 1 or value 2. If no value inputted, then it should be value 2...

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • OFFLINE
  • Posts: 48541
  • Thanks: 8290
  • Karma: 1445
3 years 4 months ago #325703 by krileon
Replied by krileon on topic Field default value
Field default only applies to registrations and only if the field is displayed on registration. There isn't a way to set a default outside that scenario. For profile edit I recommend just marking the field as required so they have to select a value. To ensure some sort of default you'd need to use CB Auto Actions and a Field action, but where you enforce it would be up to you (e.g. could be after registration if you don't want the field displayed on registration). As for imports you should be able to just specify the value in your CSV import file.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum