Jump to content


Problem with the setRelation dropdown.

enterprise setRelation dropdown

  • Please log in to reply
2 replies to this topic

#1 dhouwen

dhouwen

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 04 February 2020 - 12:08 PM

Hi Folks!

 

I have a problem with the setRelation dropdown.
 
I'm using the Enterprise version and i need to have the possibility to save an empty value.
$crud->setRelation('officeCode', 'offices', 'city')

Example:

 

When i'm check this example (non enterprise version) there is an option to choose for an empty value.

https://www.groceryc...ement/bootstrap

 

Whem i'm check the same enterprise example i don't have this empty option.

https://www.groceryc...abase-relation/

 

Does anyone knows how i get this empty value option in the enterprise version?

 

Thanks!

 



#2 Soreno

Soreno

    Member

  • Members
  • PipPip
  • 14 posts

Posted 04 February 2020 - 08:47 PM

Hello, dhouwen.

It depends on settings of your database field. If that field has NOT NULL constraint you will not have empty option in your GC.



#3 dhouwen

dhouwen

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 04 February 2020 - 09:39 PM

Hi there,

 

Thanks for your reply. This is my field setting, still no empty function. Any idea?

`test` TEXT CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL;






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users