Computed Field not showing I want to use the computed field in my drupal 8 website to calculate the charges for a parking system where I calculate the charge for a vehicle by taking the date of collection minus the date of parking, multiplying by the charge per day. total-charges=(collection-paking)*charge-per-day. However, even before I do the calculation, I tested to see if the computed field is working by assigning the $value='hello' and the assign the $disply_output=$value but its not being displayed in the content of the node together with other fields. Other things done to try to resolve this issue




Change the data type from varchar to text to int and others
Change the settings in the 'manage display' option of the content type. From toggling sanitize on an off, change display of the computed field from above to inline, etc
Resave the node by clicking edit and then saving the node, and even creating a new node of that content type after adding the content field.


Still not working.

After googling, most common solution, which works for drupal 7 guys is to uncheck the option to save the field in the database. But I dont see that option in drupal 8 so that I can uncheck it. Because I do not want to store the value in the database since It changes everyday a vehicle is not collected, so all I want is to calculate the value on the fly and charge the vehicle owner when collecting the vehicle.
How do I make the computed field even display a simple 'Hello World'?
I think it must be a bug, since the computed module is in alpha for drupal 8 at the time of this writing. With the help of Matt, we were able to print a simple 'hello' message by manually creating a new node. This new node will have access to the new computed field. I was using the devel module to generate content for nodes, which for some reason did not have access to the computed field. So if you are experiencing the same problem, set up your computed field, and then manually create a node, or edit and resave a node your previously created manually. That worked for me.