*878Opinion
TAYLOR, P. J.Ferreira appeals from a judgment denying a petition for writ of mandamus in which he sought an order commanding respondent Swoap, then Director of the State Department of Social Welfare (hereafter Director), to set aside an order and decision issued on August 7, 1973, in which the Director found Ferreira ineligible for aid to the needy disabled (ATD), as then provided by sections 13501 and 135501 of the Welfare and Institutions Code. He contends that the Director refused to follow the department’s own guidelines, based his denial on isolated statements in the record, and that he was entitled to costs and reasonable attorney’s fees, as well as interest on back payments. For the reasons set forth below, we have concluded that the judgment must be reversed.
The record reflects that on February 18, 1972, Ferreira, who' was bom October 3, 1919, applied for ATD in San Francisco. In his statement of facts regarding disability dated March 30, 1972, Ferreira indicated that he lived with his wife and four children and was unable to perform on a regular basis any of 16 enumerated housekeeping tasks. His only education was comprised of the sixth grade which he finished at age 15. Although he listed his usual occupation as “mechanical engineer” he indicated he had been self-employed as a repairman on furnaces and chimneys for approximately 20 years; his last steady employment was in 1967. On September 20, 1972, Ferreira’s application was denied on the basis of an evaluation by a state ATD review team.
*879Thereafter, Ferreira filed a timely request for a fair hearing on October 10, 1972. At the hearing held on November 20, 1972, four medical reports, summarized below, were introduced into evidence and the record was held open so that Ferreira could submit a psychiatric report.
The report of Dr. Massad, dated January 21, 1972, indicated that since 1962, Ferreira had been diagnosed as having diabetes mellitus. He had been intermittently seen at the University of California clinic since 1947, and in December 1971, was twice seen for chest pains and shortness of breath. Dr. Massad’s impression was that he suffered from arteriosclerotic heart disease (possibly class II) with angina pectoris.
The report of Dr. L. H. Smith, Jr., dated January 7, 1972, is a discharge summaiy after Ferreira’s second hospital admission on November 30, 1971, for sharp chest pains and indicated a long history of diabetes. Dr. Smith’s report ruled out a heart attack but found anginal symptoms.
The report of Dr. M. Gudenzi, a specialist in internal medicine and cardiology, dated April 3, 1972, diagnosed that Ferreira suffered from three major impairments: “1. Arteriosclerotic heart disease with coronary artery disease class II B. 2. Diabetes mellitus2 controlled with oral medications. 3. Severe depression; possible personality disorder.” Dr. Gudenzi concluded that Ferreira’s physical disorders did not at that time totally disable him from engaging in the occupation of mechanical engineer, but believed him to be “disabled from a psychiatric point of view” and recommended a psychiatric evaluation.
The report of Dr. L. Katz, a clinical psychologist, dated June 9, 1972, who administered three tests to Ferreira, indicated that he had an IQ of 83 and functions intellectually in the low average or dull normal range. While he showed moderate levels of psychopathology and depression, his responses were not overtly or significantly psychotic. Dr. Katz concluded that Ferreira at that time appeared generally capable of maintaining himself psychologically in a work setting.
The report of Dr. J. I. Gabby, a board eligible psychiatrist, dated December 5, 1972, concluded that Ferreira suffered from an underlying schizophrenic reaction and process.
*880On the basis of these reports, the referee, on March 6, 1973, issued a decision finding that Ferreira’s medical impairments totally and permanently disable him and thereby qualify him for ATD. Subsequently, the Director issued his decision dated August 7, 1973, reversing the referee and denying the application on the basis of Dr. Gudenzi’s conclusion that Ferreira’s physical condition was not severe enough to disable him and Dr. Katz’s conclusion that Ferreira was psychologically able to maintain himself in a work setting. A request for rehearing was denied on October 31, 1973, and the instant petition for a writ of mandate filed on January 17, 1974.
Ferreira first contends on appeal that the Director violated a portion of his own disability guides and standards (standard 2e), which states that disability exists where a claimant has á class II B heart disorder, has been employed in an occupation requiring hard labor, and is over 50 years of age. Although the uncontroverted evidence indicates that Ferreira came within this standard, this court (Division One) recently held that the department’s guides and standards were not rigid rules, but aids to diagnosis, internal departmental uniformity and communication (Repko v. Carleson, 48 Cal.App.3d 249, at pp. 263-264 [122 Cal.Rptr. 29]). While no petition for a hearing in the state Supreme Court was ever filed in Repko, supra, we are in accord with the reasoning and conclusion of the opinion on this question, Accordingly, there is no need to further discuss Ferreira’s first contention, and we turn to the question of whether the record supports the Director’s denial of benefits to Ferreira for the reasons stated in his decision.
The issue is framed in the guides and standards in the context found in the then applicable statute: Does the applicant have “a major physical or a major mental impairment, or a combination of both, which is verified by medical findings and appears reasonably certain to continue throughout the lifetime of the individual without substantial improvement.” (Welf. & Inst. Code, § 13501.)3
*881Welfare and Institutions Code section 10962 provides, in pertinent part: “The applicant or recipient or the affected county, within one year after receiving notice of the director’s final decision, may file a petition with the superior court, under the provisions of Section 1094.5 of the Code of Civil Procedure, praying for a review of the entire proceedings in the matter, upon questions of law involved in the case. Such review, if granted, shall be the exclusive remedy available to the applicant or recipient or county for review of the director’s decision.” “Since review of a decision by the director is limited to questions of law (§ 10962), a trial court’s function in considering the evidence is limited to determining whether the director’s findings are supported by substantial evidence in light of the whole record. (Code Civ. Proc., § 1094.5; County of Contra Costa v. Social Welfare Board (1962) 199 Cal.App.2d 468, 473. ...) The role of the trial court and of the appellate court begins and ends with a determination of whether substantial evidence, contradicted or uncontradicted, supports the conclusion of the director. [Citations.]” (Henderling v. Carleson, 36 Cal.App.3d 561, 567 [111 Cal.Rptr. 612]; see also Bertch v. Social Welfare Dept., 45 Cal.2d 524, 529 [289 P.2d 485]; Taylor v. Martin, 28 Cal.App.3d 1057, 1059 [105 Cal.Rptr. 211]; Stratton-King v. Martin, 28 Cal.App.3d 686, 690 [104 Cal.Rptr. 916]; Rosas v. Montgomery, 10 Cal.App.3d 77, 86 [88 Cal.Rptr. 907, 43 A.L.R.3d 537]; County of Contra Costa v. Social Welfare Board, 199 Cal.App.2d 468, 472-473 [18 Cal.Rptr. 573]).
The phrase “in the light of the whole record,” as found in section 1094.5 of the Code of Civil Procedure, is analogous to the expression “based upon the entire record,” as found in section 5952 of the Labor Code. With respect to the latter section, the Supreme Court has said, “In reviewing the evidence our legislative mandate and sole obligation under section 5952 is to review the entire record to determine whether the board’s conclusion was supported by substantial evidence. [Citations.]” (LeVesque v. Workmen’s Comp. App. Bd., 1 Cal.3d 627, 637 [83 Cal.Rptr. 208, 463 P.2d 432].) There, the court also noted, “The referee and appeals board ‘must accept as true the intended meaning of [evidence] both uncontradicted and unimpeached.’ (McAllister v. Workmen’s Comp. App. Bd., supra, 69 Cal.2d 408, 413 [71 Cal.Rptr. 697, 445 P.2d 313].)” (Id., at p. 639; see also Lamb v. Workmen’s Comp. Appeals Bd., 11 Cal.3d 274, 281 [113 Cal.Rptr. 162, 520 P.2d 978]; and Garza v. Workmen’s Comp. App. Bd., 3 Cal.3d 312, 317-319 [90 Cal.Rtpr. 355, 475 P.2d 451].) In Garza, the court said at page 317: “In LeVesque, supra, this court rejected prior decisions which suggested that the board’s decision would *882be sustained if supported by any evidence whatsoever, and we determined that the test of substantiality must be measured on the basis of the entire record, rather than by simply isolating evidence which supports the board and ignoring other relevant facts of record which rebut or explain that evidence. (1 Cal.3d at pp. 638-639, fn. 22.)” (See also Bixby v. Pierno, 4 Cal.3d 130, fn. 22, at p. 149 [93 Cal.Rptr. 234, 481 P.2d 242]; and 5 Witkin, Cal. Procedure (2d ed. 1971) Extraordinary Writs, § 237, p. 3988.)
Under the applicable substantial evidence test, the Director was entitled to accept and give greater weight to the psychologist’s (Dr. Katz) conclusion that Ferreira was able to maintain himself in a work setting than to the contrary conclusion about his mental condition found in the report of the internist-cardiologist (Dr. Gudenzi) and the psychiatrist (Dr. Gabby) (Repko v. Carleson, supra, at pp. 268 and 269). However, the Director here also chose to rely on the portion of Dr. Gudenzi’s report indicating that Ferreira was physically not disabled from pursuing his occupation as a mechanical engineer. As indicated above, Dr. Gudenzi came to this conclusion after Ferreira had identified his occupation as that of a previously self-employed mechanical engineer4 at the time of the examination. There is nothing in the record to show how the doctor viewed this term and whether he was aware of Ferreira’s true occupation. Thus, there is an ambiguity as to the basis for Dr. Gudenzi’s conclusion that Ferreira was not physically disabled. The entire record before the Director indicated that, in fact, Ferreira was a chimney and furnace repairman, which requires far greater exertion of hard labor than that associated with the ordinary and usual meaning of the term mechanical engineer, which implies professional training. Further, the uncontroverted fact that Ferreira had only a sixth grade education indicates he could not possibly be a mechanical engineer. Thus, the Director’s refusal of aid was based in part on two isolated conclusions from the medical record and, in view of the uncertain basis of Dr. Gudenzi’s conclusion, is not supported by substantial evidence in the light of the whole record, which strongly indicates that Ferreira may veiy well be incapable of gainful employment. While not relied upon in the administrative proceedings, the record also indicates that Ferreira was unable to perform any of the 16 simple household duties enumerated in *883the application. Even the ability to perform some household functions does not render a claimant any less entitled to ATD benefits if he is precluded from engaging in any gainful occupation (Zunino v. Carleson, 33 Cal.App.3d 36, 43 [108 Cal.Rptr. 769]). We think the judgment must be reversed and remanded to clarify the ambiguity in Dr. Gudenzi’s report.
Accordingly, Ferreira is entitled to reasonable costs and attorney’s fees below and on appeal (Welf. & Inst. Code, § 10962; Trout v. Carleson, 37 Cal.App.3d 337, 343 [112 Cal.Rptr. 282], hg. den. May 1, 1974). To the extent that he was represented during a portion of the proceedings by an attorney who was the salaried employee of a corporation that furnishes his services without cost to the client,5 Ferreira must, of course, agree to donate a proportionate amount of the award to the San Francisco Neighborhood Legal Assistance Foundation (Horn v. Swoap, 41 Cal.App.3d 375, 383-385 [116 Cal.Rptr. 113]).
Finally, we turn to the question of whether Ferreira is also entitled to prejudgment interest. The Director argues that Luna v. Carleson, 45 Cal.App.3d 670, 673 [119 Cal.Rptr. 711] (hg. den. Mar. 26, 1975), clearly held to the contrary with respect to wrongfully withheld ATD payments. The court in Luna, supra, stated at page 673: “In the absence of any showing of statutory authorization for the payment of interest, or any legal precedent therefor, we hold that the trial court erred in awarding interest.”
Ferreira, however, maintains that Civil Code section 3287 provides the necessary statutory authorization that was not considered by the court in Luna. Civil Code section 3287, subdivision (a) provides: “Every person who is entitled to recover damages certain, or capable of being made certain by calculation, and the right to recover which is vested in him upon a particular day, is entitled also to recover interest thereon from that day, except during such time as the debtor is prevented by law, or by the act of the creditor from paying the debt. This section is applicable to recovery of damages and interest from any such debtor, including the state or any county, city, city and county, municipal corporation, public district, public agency, or any political subdivision of the state.”
*884Our Supreme Court so ruled in Tripp v. Swoap, 17 Cal.3d 671, 681 [131 Cal.Rptr. 789, 552 P.2d 749], wherein Luna was disapproved (at p. 685). The court held that the claimant is entitled to prejudgment interest where, as here, the three requirements (an underlying money obligation, a certain recovery, and vesting) of Civil Code section 3287, subdivision (a), as interpreted in Mass v. Board of Education, 61 Cal.2d 612 [39 Cal.Rptr. 739, 394 P.2d 579], have been met.
Judgment reversed, with directions that further testimony be taken from Dr. Gudenzi to ascertain if his opinion was based on petitioner’s physical and mental condition, as applied to the actual facts of his employment record and work capacity. The trial court is also directed to determine the appropriate amount of attorney’s fees below and on appeal, and prejudgment interest, if applicable.
Kane, J., and Rouse, J., concurred.
Section 13550 (as amended Stats. 1967, ch. 1585, § 5, p. 3795) was amended by Statutes 1971, chapter 578, section 38, page 1169, effective August 13, 1971, operative October 1, 1971, and together with section 13501 was repealed by Statutes 1973, chapter 1216, section 55, page 2923, effective December 5, 1973, and operative January 1, 1974.
Aid to the disabled is now apparently covered by “The Benton-Moscone-Bagley Citizen’s Income Security Act for Aged, Blind and Disabled Californians.” (Welf. & Inst. Code, div. 9, pt. 3, chs. 3 and 4, §§ 12000-12600.) (Stats. 1973, ch. 1216, § 37, pp. 2903-2918, effective Dec. 5, 1973, and operative Jan. 1, 1974.) The applicant’s rights appear to be preserved by section 12151, which reads as adopted, “Persons who for the month of December 1973 were recipients of aid or who had applied for and met all the eligibility conditions for aid under Chapters 3 (commencing with Section 12000), 4 (commencing with Section 12500), or 6 (commencing with Section 13500), of this part shall be eligible for benefits under this chapter during the period that they continue to meet the more liberal of the eligibility requirements in effect in December 1973 or after January 1,1974.” (Stats. 1973, ch. 1216, § 37, p. 2906, italics added.) No opinion is expressed as to the effect of subsequent amendments limiting eligibility. (See § 12151, as amended Stats. 1974, ch. 75, §§ 1, 17 and 18, pp. 163, 171, effective Mar. 14, 1974, as an emergency measure to be effective Jan. 1, 1974.)
The record also contains technical laboratory findings concerning Ferreira’s physical condition in April 1972; this report indicates an abnormally high glucose reading.
At the time here pertinent, Welfare and Institutions Code section 13501 provided, so far as pertinent: “When used in this chapter, the following words shall have the meanings ascribed to them in this section: [1] (a) ‘Needy disabled person’ means a person who meets the eligibility requirements set forth in this chapter and who is both permanently impaired and totally disabled. [U] (b) ‘Permanently impaired’ means that the individual has a major physical or a major mental impairment, or a combination of both, which is verified by medical findings and appears reasonably certain to continue throughout the lifetime of the individual without substantial improvement, [f] (c) ‘Totally disabled’ means that the impairment substantially precludes the individual from engaging in useful occupations within his competence, such as holding a job or homemaking.” (Added by Stats. 1965, ch. 1784, § 5, and repealed by Stats. 1973, ch. 1216, § 55, operative Jan. 1, 1974.)
The form completed by the doctor at the time of the examination indicated Ferreira’s , last employment was that of “Self-employed in mechanical engineering five years ago.” However, in view of the more accurate information on his disability application, Ferreira’s sixth grade education and low IQ, we do not think he could be held to the doctrine of invited error.
The record indicates that during a portion of the proceedings Ferreira was represented by the San Francisco Neighborhood Legal Assistance Foundation.