
275 Kan. 145 (2003)
62 P.3d 228
ERIC AND RYAN MONTOY, et al., Appellants,
v.
STATE OF KANSAS, et al., Appellees.
No. 88,440
Supreme Court of Kansas
Opinion filed January 24, 2003.
*146 Alan L. Rupe, of Husch & Eppenberger, LLC, of Wichita, argued the cause, and Dwight D. Fischer, and Alisa A. Nickel, of the same firm, and John S. Robb, of Somers, Robb and Robb, of Newton, were with him on the briefs for appellants.
Dan Biles, of Gates, Biles, Shields & Ryan, P.A., of Overland Park, argued the cause, and William Scott Hesse, assistant attorney general, was with him on the brief for appellees.
The opinion of the court was delivered by
DAVIS, J.:
In this constitutional challenge to the Kansas scheme of financing public education, numerous students representing African-American, Hispanic, and disabled groups, along with two large school districts, sued the State of Kansas, the Governor, the chairperson of the Kansas State Board of Education (State Board), and the Commissioner of the Kansas State Department of Education. In three separate counts, the plaintiffs alleged (1) a violation of the requirement that the legislature provide for the suitable finance of the educational interests of the State under Kan. Const. art. 6, § 6(b); (2) a violation of equal rights protection under the Kansas Constitution; and (3) a violation of substantive due process rights under the Kansas Constitution. The district court sua sponte *147 granted judgment to the defendants, concluding that the plaintiffs failed to present legally sufficient claims.
In their appeal, the plaintiffs claim (1) that the district court erred by excluding certain claims on the grounds that they were outside the pleadings; (2) that the district court erred by failing to treat the dismissal of their case as a dismissal based upon a motion for summary judgment; and (3) that contrary to the findings of the district court, their claims are legally sufficient. We conclude the district court prematurely granted judgment and remand the case for further proceedings.

Excluded claims
We first consider whether the district court erred in excluding consideration of certain claims of the plaintiffs. The district court explained its exclusion as follows:
"Plaintiffs have raised several new issues that were not contained in their pleadings. Kansas law requires that a challenge to the constitutionality of a statute be specifically raised in the pleadings. Missionary Baptist Convention v. Wimberly Chapel Baptist Church, 170 Kan. 684 (1951). Plaintiffs had the opportunity to amend their pleading to include these new issues prior to the Court ordered deadline of November 11, 2000. Plaintiffs failed to do so. The issues raised by Plaintiffs that the Court will not consider because they were not properly pled are: (1) Plaintiffs' constitutional challenge to K.S.A. § 72-8801 et seq. (Capital Outlay); (2) Plaintiffs' constitutional challenge to K.S.A. § 72-961 et seq. (Special Education Excess Costs); and (3) Plaintiffs' claim that the SDFQPA [School District Finance and Quality Performance Act] violates Article 6, § 2(a) of the Kansas Constitution (as being an encroachment on the `general supervision' responsibility of the State Board of Education). Plaintiffs failed to properly raise these issues or amend their petition to include these issues. Therefore, this Court will not permit these claims to be raised at this point in the case."
While Missionary Baptist Convention v. Wimberly Chapel Baptist Church, 170 Kan. 684, 228 P.2d 540 (1951), excluded consideration of constitutional claims raised for the first time on appeal, the district court's reliance upon the holding in Missionary Baptist is inappropriate in this case. Missionary Baptist is a case where the excluded constitutional issues surfaced the first time before the appellate court, not the district court. The constitutionality of the statutes involved in Missionary Baptist was neither raised in the *148 pleadings nor presented by the parties to the action at any stage of the proceedings before the district court. 170 Kan. at 687-88. Unlike Missionary Baptist, the plaintiffs' constitutional issues in this case were raised by the plaintiffs before the district court. Thus, this court's decision in Missionary Baptist fails to provide authority for excluding consideration of the plaintiffs' challenges to the capital outlay provisions, the special education provisions, and the encroachment on the general supervision responsibility of the State Board. Other reasons for exclusion of the plaintiffs' additional claims before the district court and advanced by the district court and the defendants in this appeal are considered herein.
In Count I of their petition, the plaintiffs alleged a violation of Kan. Const. Art. 6, § 6(b), which requires the legislature to "make suitable provision for finance of the educational interests of the state." Under this count, the petition made the constitutionality of the School District Finance and Quality Performance Act (SDFQPA), K.S.A. 72-6405 et seq., the issue before the trial court. The district court rejected the plaintiffs' three additional constitutional claims, capital outlay provisions, the special education excess cost provisions, and the encroachment on the general supervision responsibility of the State Board on the basis that these matters were not specifically pled by the plaintiffs. The question presented is whether consistent with notice pleading, the claims of the plaintiffs are broad enough to include the additional constitutional claims.
Since the adoption of the Kansas Rules of Civil Procedure, Kansas courts have followed the rules of notice pleading. K.S.A. 60-208(a)(1) requires a "short and plain statement of the claim showing that the pleader is entitled to relief." A rule of liberal construction applies when judging whether a claim has been stated. The purpose of the petition is to give notice of the substance of the plaintiffs' claims. Discovery will more easily and effectively fill the gaps. See Fowler v. Criticare Home Health Services, Inc., 27 Kan. App. 2d 869, 873-75, 10 P.3d 8 (2000), aff'd 271 Kan. 715, 26 P.3d 69 (2001). We note in this case that while discovery was nearing completion, it was not complete. On appeal, the plaintiffs argue that outstanding discovery related to the three additional *149 issues they asked the district court to consider. Ordinarily, a summary disposition of a pending case before the district court should not be granted until discovery is complete. See Bell v. Kansas City, Kansas, Housing Authority, 268 Kan. 208, 220, 992 P.2d 1233 (1999).
Based upon the record before us, including matters considered by the district court in a memorandum filed by the plaintiffs and the defendants' response, and the defendants' pretrial questionnaire, the three issues of capital outlay, special education excess costs, and encroachment on the general supervision responsibility of the State Board were sufficiently raised and should have been considered by the trial court in its resolution of this case. The plaintiff's petition focused on the SDFQPA in particular. However, while the petition focused on SDFQPA, it alleged a violation of the suitability requirement. Under the liberal interpretation of the pleadings required by our rules of notice pleading, relying on discovery to fill in any gaps, we conclude that the trial court erred in refusing to consider the three excluded issues.
We acknowledge that the district court's deadline for amending the pleadings had passed. However, it is clear that the plaintiffs sought to include their three additional constitutional claims before the district court. A final pretrial conference order was not entered in this case. K.S.A. 2001 Supp. 60-216(c)(3) provides that the district court should consider at any pretrial conference "the necessity or desirability of amendments to the pleadings." See Brown v. United Methodist Homes for the Aged, 249 Kan. 124, 141-42, 815 P.2d 72 (1991). Once a pretrial order is made pursuant to K.S.A. 2001 Supp. 60-216, it supercedes the pleadings and controls the subsequent course of the action. Herrell v. Maddux, 217 Kan. 192, 193, 535 P.2d 935 (1975).
The spirit of our present rules of civil procedure permits a pleader to shift the theory of his or her case as the facts develop, as long as he or she has fairly informed his or her opponent of the transaction or the aggregate of the operative facts involved in the litigation. Griffith v. Stout Remodeling, Inc., 219 Kan. 408 Syl ¶ 3, 548 P.3d 1238 (1976). The determination of whether a party's claim is a late shift in the thrust of the case which prejudices the *150 opponent is left to the sound discretion of the trial court. Where such exercise of discretion is questioned on appeal, we must determine whether the opposing party was taken by surprise and, if so, whether it resulted in substantial prejudice to that party. Boydston v. Kansas Board of Regents, 242 Kan. 94, Syl. ¶ 1, 744 P.2d 806 (1987).
We do not believe that consideration of the additional constitutional claims would cause the defendants surprise or unfair prejudice. Even if accomplished through amendment by a final pretrial conference order allowing the plaintiffs to advance their three claims, we find such an amendment would cause no surprise or unfair prejudice to the defendants. See Johnson v. Board of Pratt County Comm'rs, 21 Kan. App. 2d 76, 90-91, 897 P.2d 169 (1995). We conclude that it was error for the district court to exclude consideration of the plaintiffs' three additional constitutional claims.

Summary Judgment Procedure
The plaintiffs claim that the order entered was a summary judgment without any of the procedural safeguards set forth in K.S.A. 60-256. The plaintiffs complained to the district court that its memorandum decision was entered without the benefit of Supreme Court Rule 141 (2002 Kan. Ct. R. Annot. 189), and the procedure set forth in K.S.A. 60-256. In addressing this contention, the district court noted:
"The Court's [m]emorandum [d]ecision and order was not based on a motion for summary judgment. The parties submitted briefs to the Court to determine whether Plaintiffs' claims were legally sufficient as a matter of law. Therefore, the rules set forth for summary judgment did not have to be followed.
"There is no question Plaintiffs understood that they were submitting briefs for the Court to determine the legal sufficiency of their claims. Not only did the Court order them to file a brief, but they argued that a briefing schedule should be established to determine these issues. Plaintiffs had ample opportunity to present and argue the legal sufficiency of their claims."
The trial court ordered the parties to file briefs to determine various legal issues in advance of trial. While the trial court later declared such legal issues in advance of trial included the legal *151 sufficiency of the plaintiff's claims, there is no indication that the case was to be disposed of based upon the briefs submitted. Based upon the responses of the parties, the parties were asked to identify in advance of trial the legal issues involved in the trial of the case. Both parties attempted to identify those issues for the court. Had the plaintiffs been informed by the court that it would consider their submission to determine the legal sufficiency of the plaintiffs' claims, rather than to determine what legal issues it would be faced with upon trial of the case, the plaintiffs may have approached their task differently.
Nevertheless, the district court disposed of the case based upon the legal insufficiency of the plaintiffs' claims and we, therefore, consider its ultimate ruling. While the trial court may not have based its memorandum decision and order on a motion for summary judgment, the order disposing of the case was a judgment within the definition of K.S.A. 60-254 as a final determination of the rights of the parties in this action. A judge of a court of general jurisdiction, as the trial judge in this case, possesses the inherent power to summarily dispose of litigation where there remains no genuine issue as to any material fact. See Missouri Medical Ins. Co. v. Wong, 234 Kan. 811, 816, 676 P.2d 113 (1984); Green v. Kaesler-Allen Lumber Co., 197 Kan. 788, 790, 420 P.2d 1019 (1966). The judgment entered in this case was based upon the trial court's inherent power to dispose of litigation on its own motion as a matter of law.
Before such a judgment is entered, this court has stated that "[i]t may be said that . . . the same conditions must exist as would justify a summary judgment on motion of a party." Green, 197 Kan. at 790. We further noted:
"Summary disposition of an action may logically follow a pretrial conference when proper pretrial proceedings disclose the lack of a disputed issue of material fact and the facts so established indicate an unequivocal right to a judgment in favor of a party.

. . . .
"This court has now laid down a definite yardstick for the granting of such judgments. Generally, it must appear conclusively that there remains no genuine issue as to a material fact and that one of the parties is entitled to judgment as a *152 matter of law. A mere surmise or belief on the part of the trial court, no matter how reasonably entertained, that a party cannot prevail upon a trial will not justify a summary judgment where there remains a dispute as to a material fact which is not clearly shown to be sham, frivolous or so unsubstantial that it would obviously be futile to try it. A party against whom a summary judgement is being considered must be given the benefit of all reasonable inferences that may be drawn from the facts under consideration. [Citations omitted.]" (Emphasis added.) 197 Kan. at 790-91.
Missouri Medical reiterated and reinforced the principles set forth in Green and sustained a judgment where discovery had been completed, a thorough pretrial conference had been held, and all of the basic facts had been developed. We concluded that there remained no genuine issue of material fact and that the plaintiff was entitled to judgment as a matter of law. 234 Kan. at 816. The same, however, may not be concluded in this case.
The judgment entered by the district court in this case fails to address the factual allegations of the plaintiffs except to say that all allegations of the plaintiffs are without merit and resolved by our recent decision in U.S.D. 229 v. State, 256 Kan. 232, 885 P.2d 1170 (1994). As more fully discussed below, giving the plaintiffs the benefit of all reasonable inferences that may be drawn from the record, we conclude that there remain genuine issues of material fact not shown to be a sham, frivolous, or so unsubstantial that it would be futile to try the case. See Green, 197 Kan. at 790.
In Count I involving the suitability of school finance, the plaintiffs assert that state law no longer contains educational goals or standards and that the State Board has not issued any regulations containing academic standards or objective criteria against which to measure the education Kansas children receive. The 10 goals quoted by U.S.D. 229 are no longer part of the statute. L. 1995, ch. 263, sec. 1. What remains is a statutory requirement that the State Board adopt an accreditation system that is "based upon improvement in performance that reflects higher academic standards and is measurable." K.S.A. 2001 Supp. 72-6439(a). While the amendment to K.S.A. 72-6439(a) may not represent a serious shift in the goals of public education in the state of Kansas, we believe that the suitability analysis required by U.S.D. 229 is more rigorous than presumed by the district court.
*153 U.S.D. 229 relied on the legislature to promulgate standards but asserted that the ultimate question on suitability must be one for the court. Accreditation is a "base," but U.S.D. 229 also quoted the following caveat from the district court in that case:
"`[T]he issue of suitability is not stagnant; past history teaches that this issue must be closely monitored. Previous school finance legislation, when initially attacked upon enactment or modification, was determined constitutional. Then, under-funding and inequitable distribution of finances lead to judicial determination that the legislation no longer complied with constitutional provisions.'" 256 Kan. at 258.
U.S.D. 229, quoting the district court, noted that "`while the issues raised by Plaintiffs raise serious policy questions, the arguments do not compel a determination that the financing is not "suitable" at the present time.'" 256 Kan. at 258. We conclude that this case is sufficiently removed in time from our decision in U.S.D. 229 so as to preclude summary application of U.S.D. 229 to dispose of the plaintiffs' claims.
In this case, the plaintiffs assert the following facts are disputed in the memorandum to determine legal issues in advance of trial:
"[T]he state law no longer contains educational goals or standards;
"the BOE has not issued any regulations containing academic standards or objective criteria against which to measure the education Kansas children receive;
"the amount of Base State Aid Per Pupil (BSAPP) has not kept up with inflation. For FY 2003, the BOE requested approximately $635 million in additional educational funding;
"school districts are still required to raise capital outlay expenses locally, and the four mill levy limit has been removed, allowing wealthier districts even greater access to capital outlay expenditures than poorer districts and thus increasing funding disparities; [s]ee K.S.A. 72-8801. In Mock, this Court specifically held that Article 6(b) of the Constitution, in its direction to the legislature to provide suitable financing, makes the state responsible for capital expenses. Mock, supra at 501. See also Wyoming v. Campbell County School District, et al., 19 P.3d 518, 557 (Wyo. 2001) (capital construction financing system based upon a school district's assessed valuation necessarily depends on local wealth creating unconstitutional disparities in educational opportunities.);
"the school finance formula provides widely differing amounts of revenue to different districts;
"the number of minority students in the plaintiff school districts has increased dramatically;

*154 "a substantial gap exists between the performance of minorities and whites, and between students in the free and reduced lunch programs and those not in these programs, on state standardized tests;
"the 2001 legislature changed the finance formula to allow school boards to raise a greater proportion of funds with local taxes creating disparities in educational opportunity;
"the plaintiff school districts must raise money locally through the `local option budget' (`LOB') or the capital outlay fund to meet the minimum school accreditation requirements;
"the LOB was originally capped at 25% of the general fund budget of the local school district, and was designed to decrease as the base state aid per pupil increased, in an attempt to achieve parity statewide over time. In the 1993 legislative session, this equalizing method was abandoned and the LOB was allowed to increase as the BSAPP increased;
"the plaintiff school districts raise less money per pupil with each mill levy than wealthier districts;
"increased reliance on local taxes has resulted in a less advantageous education in the plaintiff school districts than in wealthier districts;
"although it purports to be based on the cost of educating children in the various school districts, the school finance formula is based on political decisions, because neither the legislature nor the BOE has gathered information about the actual costs of education in the various districts;
"the Kansas legislature has recognized that there are inherent inadequacies and inequities in the SDFQPA. L. 2001, Ch. 215, § 10(a);
"young people nowadays need additional technological skills to compete favorably in the global society."
The judgment entered by the district court contains no findings of fact to support its sua sponte judgment for the defendants. We reject the district court's legal conclusion that U.S.D. 229 alone supports its judgment. Based upon its decision, the district court did not see the need to address the factual allegations of the plaintiffs. Generally, however, when we review such a judgment we, as well as the trial court, are required to resolve all facts and inferences which may reasonably be drawn from the evidence in favor of the party against whom the ruling is sought. Mitchell v. City of Wichita, 270 Kan. 56, 59, 12 P.3d 402 (2000). We do not believe that the plaintiffs' factual allegations are a sham, frivolous, or so unsubstantial that it would be futile to try the case we now consider. The issues raised in this case require the district court to determine either on the basis of uncontroverted facts or on facts *155 determined by trial whether the school financing provisions complained of are now constitutional.
There is a point where the legislature's funding of education may be so low that regardless of what the State says about accreditation, it would be impossible to find that the legislature has made "suitable provision for finance of the educational interests of the state." Kan. Const. art. 6, § 6. U.S.D. 229 suggested base criteria for determining suitability. The district court must make a finding, after giving the plaintiffs the opportunity to substantiate their claims, that the legislature has provided suitable provisions for financing the educational interests of the State before judgment may be entered for the defendants regarding the plaintiffs' unsuitability claim. Presently, the statute requires an accreditation system which is "based upon improvements in performance that reflects higher academic standards and is measurable." K.S.A. 2001 Supp. 72-6439(a).
In Count II involving a claim of denial of equal protection, the plaintiffs advance a number of allegations. For example, they alleged that the minority students in the plaintiff school districts have increased dramatically, that a substantial gap exists between the performance of minorities and whites, and that a substantial gap exists between the performance standards of students in the free and reduced lunch programs and those not in these programs. Upon remand, these factual allegations will have to be addressed by the parties as well as by the district court in order for a final judgment to be entered. The same may be said for the factual allegations by the plaintiffs in Count III regarding their claim that they have been denied substantive due process of law.
When this court is called upon to review a trial court decision, we must acknowledge the wisdom of the Kansas Code of Civil Procedure in requiring that the controlling facts be set forth in a final judgment rendered by a district court. See K.S.A. 2001 Supp. 60-252; K.S.A. 2001 Supp. 60-256. Moreover, Supreme Court Rule 141, while only dealing with summary judgment, further emphasizes the necessity that such judgments be entered only where there remains no genuine issue of material fact and a party is entitled to judgment as a matter of law. In light of our decision, we *156 may not ignore the plaintiffs' factual allegations. When we consider the record as a whole and apply the standard we are required to apply, we conclude that there remain in dispute genuine issues of material fact which do not support the summary disposition of the district court. We, therefore, reverse the judgment of the district court and remand for further proceedings.
Reversed and remanded.
NUSS, J., not participating.
BRAZIL, S. J., assigned.
