Yes, restaurants should be closed and only taking To-Go orders. However, if you look at CA.gov it does not say you are not allowed to go work. Pulled from CA.gov It says;
"Reducing social contact can help slow the spread of this coronavirus and keep our communities healthy. Staying home is the best way to protect yourself and others.
Everyone in California is required to stay home except to get food, care for a relative or friend, get necessary health care, or go to an essential job. If you go out, keep at least 6 feet of distance. Learn more."
expanded version
"The California State Public Health Officer and Director of the California Department of Public Health is ordering all individuals living in the State of California to stay home or at their place of residence, except as needed to maintain continuity of operation of the federal critical infrastructure sectors, critical government services, schools, childcare, and construction, including housing construction. "
You are allowed to go to work and construction is still ongoing in CA...I'm a developer, I should know lol.
So please stop spreading misinformation, there's already enough of that on social media. People need to do themselves a favor and READ.