
142 Wis.2d 843 (1987)
419 N.W.2d 340
LUECK'S HOME IMPROVEMENT, INC., and Carl Lueck, Intervenors-Plaintiffs-Appellants and Cross-Respondents,
STATE of Wisconsin, Plaintiff,
v.
SEAL TITE NATIONAL, INC., a domestic corporation, Herbert C. Kesler, Richard J. Salm and David G. Werner, individually and as officers of said corporation, Defendants-Respondents and Cross-Appellants.
No. 86-1871.
Court of Appeals of Wisconsin.
Submitted on briefs September 9, 1987.
Decided December 30, 1987.
*844 For the intervenors-plaintiffs-appellants and cross-respondents the cause was submitted on the briefs of Christopher R. Kindt and Nolan, Engler, Yakes & Bauer, S.C., of Oshkosh.
On behalf of the State there were briefs by Bronson C. La Follette, attorney general, and David J. Gilles, assistant attorney general.
For the defendants-respondents and cross-appellants there were briefs by Gary L. Antoniewicz and *845 Leslie F. Kramer and Antoniewicz, Gregg & Rona, S.C., of Madison.
Before Gartzke, P.J., Dykman and Sundby, JJ.
SUNDBY, J.
Lueck's Home Improvement, Inc., appeals an order denying reconsideration of the denial of its claim for restitution[1] from Seal Tite National, Inc., under a stipulation between Seal Tite and the state and an order pursuant to secs. 100.18(11)(d) and 553.54(2)(a), Stats. The issue is whether the trial court abused its discretion in denying Lueck's claim because its itemized schedule of returnable supplies, inventory and equipment was not timely filed under the restitution order. Because the trial court erroneously concluded that the restitution order constituted a contract and failed to exercise its discretion to allow or deny Lueck's claim, we reverse and remand. We reject Seal Tite's claim on its cross-appeal that the trial court abused its discretion in allowing Lueck to intervene to appeal its order and affirm that part of the order allowing Lueck's intervention.

I.

BACKGROUND OF THE CASE
This is a regulatory action by the Wisconsin office of the commissioner of securities (OCS) for alleged violations of the fraudulent advertising law, sec. 100.18(1), Stats., and the franchise investment law, ch. 553, Stats. Seal Tite waived the filing of a complaint *846 and stipulated with the OCS to make restitution to its franchisees. Pursuant to the stipulation a restitution order was entered in the circuit court. Under the order, Seal Tite offered to franchisees, including Lueck, restitution for distribution fees and returnable supplies, inventory and equipment. Franchisees accepting restitution were required to return to the OCS a letter indicating acceptance, a signed affidavit summarizing the claim and an itemized schedule of returnable property.[2] The OCS was to determine the restitution to be paid by Seal Tite and notify the court of the amount. Seal Tite had thirty days to object to any claim.
Lueck timely accepted restitution and submitted its affidavit stating its claim. The affidavit did not include a schedule itemizing the returnable supplies, inventory and equipment. After the time for accepting restitution expired under the order, the OCS reported to the court the total amount of restitution due all franchisees. The reported figure included all of Lueck's claim.
Subsequently, on September 10, 1985, the OCS requested that Lueck submit within ten days its *847 itemization of returnable property. On September 13 Seal Title objected to Lueck's claim because Lueck did not timely comply with the itemization requirement in the order. Lueck filed the itemization with the OCS on September 19.
The trial court denied Lueck's claim for inventory, supplies and equipment, concluding "that the claim as timely filed was fatally defective under the rules of the restitution offer agreed to by the parties, and could not be subsequently corrected by unilateral action of the OCS, and must be denied." The court held that the consent order created contractual obligations and that the time limits were mandatory.

II.

RESTITUTION CLAIMS INVOKE COURT'S EQUITABLE POWERS
[1, 2]
Restitution under secs. 100.18(11)(d) and 553.54(2)(a), Stats., invokes the court's equitable powers. State v. Excel Management Services, 111 Wis. 2d 479, 490, 331 N.W.2d 312, 317 (1983). We review decisions in equity for abuse of discretion. Production Cr. Ass'n v. Jacobson, 131 Wis. 2d 550, 555, 388 N.W.2d 655, 657 (Ct. App. 1986).
We will find an abuse of discretion if the trial court failed to exercise its discretion. Oostburg Bank v. United Savings, 130 Wis. 2d 4, 11-12, 386 N.W.2d 53, 57 (1986). A discretionary ruling based on an error of law is an abuse of discretion. St. Michael's Church v. Admin. Dept., 137 Wis. 2d 326, 338, 404 N.W.2d 114, 119 (Ct. App. 1987).


*848 III.

RESTITUTION IS NOT GOVERNED BY CONTRACT PRINCIPLES
The trial court erroneously concluded that the restitution order was a contract between Seal Tite and its franchisees.
[3]
The trial court relied on the fact that the restitution program had been "negotiated between the parties and accepted by the court." This is factually inaccurate. Lueck was not a party to the stipulation negotiated between Seal Tite and the OCS.[3] In any event, a restitution consent order is not a contract. Although stipulations of settlement have occasionally been referred to as contracts, they are not governed by contract law. Burmeister v. Vondrachek, 86 Wis. 2d 650, 664, 273 N.W.2d 242, 248, (1979).[4] "We reject the *849 argument ... that a decree entered upon consent is to be treated as a contract and not as a judicial act." United States v. Swift & Co., 286 U.S. 106, 115 (1932). In Swift the court recognized the power of a court to modify an injunction prohibiting monopolistic practices, even though the injunction had been entered as a consent decree.
[T]he ... authority to adopt a consent decree comes only from the statute which the decree is intended to enforce. Frequently of course the terms arrived at by the parties are accepted without change by the adopting court. But just as the adopting court is free to reject agreed-upon terms as not in furtherance of statutory objectives, so must it be free to modify the terms of a consent decree when a change ... brings those terms in conflict with statutory objectives.
System Federation No. 91 v. Wright, 364 U.S. 642, 651 (1961).
[4]
The trial court failed to appreciate that its equitable powers permitted it to allow Lueck's claim despite Lueck's failure to comply with the filing requirements of the restitution order. Once equity jurisdiction attaches, the court should continue to *850 exercise its jurisdiction "in an effort to do complete justice between the parties." Excel Management, 111 Wis. 2d at 491, 331 N.W.2d at 318. See J. Jeffries, Protection for Consumers Against Unfair and Deceptive Business, 57 Marq. L. Rev. 559, 600 (1974) (concept of restitution is grounded on traditional equitable principle that once equity jurisdiction attaches the court may grant full and complete relief).
Because the trial court proceeded on an incorrect legal theory, it did not exercise its discretion under proper equitable principles. We reverse and remand for the court to exercise its discretion. We may not exercise the discretion vested in the trial court. In re Cherokee Park Plat, 133 Wis. 2d 112, 125, 334 N.W.2d 580, 587 (Ct. App. 1983).

IV.

SEAL TITE'S CROSS-APPEAL
[5]
Seal Tite cross-appeals the trial court's order allowing Lueck to intervene for the purpose of bringing this appeal. We conclude that the trial court did not abuse its discretion in allowing Lueck to intervene in order to appeal the trial court's order. A party aggrieved by a judgment or order may appeal it. Mutual Service Cas. Ins. Co. v. Koenigs, 110 Wis. 2d 522, 526, 329 N.W.2d 157, 159 (1983); Tierney v. Lacenski, 114 Wis. 2d 298, 302, 338 N.W.2d 522, 524 (Ct. App. 1983). A person may be a party aggrieved even though he or she was not a party to the action. Miller v. Lighter, 21 Wis. 2d 401, 403, 124 N.W.2d 460, 461 (1963). Lueck was aggrieved by the denial of its claim.
*851 By the Court.Order affirmed in part, reversed in part and cause remanded.
DYKMAN, J. (dissenting).
The majority gives two reasons for reversing the trial court's order. The first is that the trial court relied upon an unproven fact, and the second is that the trial court erred by concluding the parties' consent decree was a contract.
I dissent because the factual inaccuracy relied upon by the majority does not exist, because the trial court did not err by referring to the consent decree as a contract, and because the trial court's use of the word "contract" is not relevant to an inquiry into whether it abused its discretion by refusing Lueck's request to participate in the consent decree on his terms.

Factual Inaccuracy
The majority finds that Lueck was not a party to the stipulation negotiated between Seal Tite and the state. However, the trial court found:
1. The underlying action is a regulatory action brought by the State on behalf of all interested parties who elected to accept the State's representation of their interest (emphasis in original).
2. Lueck accepted that representation.
I do not consider it significant that Lueck's agent agreed to the stipulation, rather than Lueck himself. Nor is it significant that Lueck considered and accepted the stipulated order rather than negotiating the agreement himself. We are required to accept a trial court's findings of fact unless they are clearly erroneous. In re Marriage of Laribee v. Laribee, 138 Wis. 2d *852 46, 54, 405 N.W.2d. 679, 683 (Ct. App. 1987). I would do so and therefore I reject the majority's first reason for reversing the trial court's order.

Trial Court's Reference to "Contract"
Another reason the majority gives for reversing the trial court's order is that the trial court referred to the parties' stipulation and its order as a contract. The difficulty with this conclusion is that it is drawn from cases examining stipulations of settlement made pursuant to sec. 807.05, Stats., which provides:
No agreement, stipulation, or consent between the parties or their attorneys, in respect to the proceedings in an action or special proceeding shall be binding unless made in court and entered in the minutes or recorded by the reporter or made in writing and subscribed by the party to be bound thereby or the party's attorney.
We made this clear in Adelmeyer v. Wis. Elec. Power Co., 135 Wis. 2d 367, 371, 400 N.W.2d 473, 474-75 (Ct. App. 1986), where we said:
In Burmeister v. Vondrachek, 86 Wis. 2d 650, 664, 273 N.W.2d 242, 248 (1979), the supreme court stated with respect to stipulations entered into pursuant to sec. 807.05, Stats:
Finally, although these stipulations of settlement have occasionally been referred to as contracts, they are not governed by contract law. Such stipulations may be enforced by the court and may only be avoided with the court's approval.

*853 The reason for the rule is found in the holdings of both the state and federal courts that the statute is in the nature of a statute of frauds. (Citations omitted.)
The majority does not explain how a statute of frauds requiring agreements to be in writing or made in open court transforms a consent decree, and a circuit court order implementing that decree, into unenforceable suggestions. Even if sec. 807.05, Stats., could apply, the majority does not consider the rules applicable to setting aside stipulations. The proper test, even under the majority's analysis, is whether the trial court, in a reasonable exercise of discretion, could have concluded that Lueck failed to show that the consent order was agreed to because of fraud, mistake or misrepresentation. Burmeister, 86 Wis. 2d at 664, 273 N.W.2d at 248.
The trial court recognized that the state of Wisconsin and Seal Tite had entered an agreement for the benefit of Lueck and nine other Seal Tite distributors, all of whom had causes of action against Seal Tite under sec. 100.18(11)(b)2.[1] The bargains struck by the state and Seal Tite were complex, and reflected Seal Tite's concerns as well as those of the distributors.
*854 The stipulation and order did not bind any distributor unless the distributor agreed to be bound. A distributor who agreed received substantial benefits by doing so but waived other benefits and rights that non-accepting distributors retained. The trial court recognized this "quid pro quo" nature of the agreement when it considered whether Lueck could choose a plan not agreed to which benefited it to a greater extent than other distributors and operated to the detriment of Seal Tite. The court also recognized the inherent unfairness of accepting Lueck's incomplete and unsubstantiated claim after the time had expired for Seal Tite to challenge Lueck's claim.
Consent decrees, authorized by secs. 100.18(11)(e), Stats., and 553.54(4), Stats.,[2] are required by those *855 statutes to be in writing. They therefore automatically satisfy the statute of frauds found in sec. 807.05, Stats. Both secs. 100.18(11)(e) and 553.54(4) refer to written assurances by alleged trade practice and franchise law violators, acceptance of the assurances by the state, and the legal consequences that can result from violations of these assurances. Sections 100.18(11)(e) and 553.54(4) use the language of contract law and contemplate that agreements made between the state and alleged violators will be enforceable. I therefore conclude that the trial court did not err by referring to the consent decree negotiated by the parties as a contract.

Reference to "Contract" Irrelevant
I also conclude that whether the trial court referred to the parties' agreement as a "contract" is not dispositive. The reason for the trial court's decision was:
The Court's equitable powers to "fashion relief for those injured persons," State v. Excel Management Services (1983), 111 Wis. 2d 479, does not extend to honoring claims filed untimely or incompletely, pursuant to an agreement negotiated by the parties and approved by the Court.
The trial court recognized that it had equitable powers, but declined to exercise these powers because it considered it unjust or unfair to permit Lueck to be paid any amount he chose to claim, without verification, *856 and without an opportunity for Seal Tite to protest.
It is inequitable for a party to agree to a negotiated settlement, and then assert that it need not abide with the terms of the settlement to the detriment of another party to the settlement. That was the trial court's holding. A proper exercise of discretion can be described as "reasoned decision-making."Bahr v. Bahr, 107 Wis. 2d 72, 82, 318 N.W.2d 391, 397 (1982) (emphasis in Bahr). We know what the trial court did, and why it did so. The reason for the trial court's decision is rational. There is no abuse of discretion.
NOTES
[1]  The court's memorandum decision of January 16, 1986 directed Seal Tite to prepare an appropriate order denying Lueck's claim. This was never done because Lueck filed its motion for reconsideration and intervention. Thus Lueck's appeal from the order denying its motion for reconsideration is timely.
[2]  The form affidavit stated:

I have attached a schedule which itemizes with particularity the supplies, inventory and equipment on hand that I regard as reusable and that I am willing to resell to Seal Tite National, Inc. The amounts that I paid to Seal Tite for such materials and the dates thereof are also set forth on the attachment. A summary of the amounts due me is as follows:


a) Supplies        $___________
b) Inventory       $___________
c) Equipment       $___________

[3]  The dissent claims this is factually inaccurate. However, the record shows that the state served Seal Tite with a summons but not a complaint. Seal Tite and its officers by stipulation with the state agreed to the entry of an order (and any judgment entered pursuant to such order) pursuant to which they would make an offer of restitution to named franchisees. Lueck was not a party to the stipulation or order. Lueck elected to participate in the restitution program only after it was in place as a result of the negotiations between the state and Seal Tite.
[4]  Contrary to the dissent's suggestion, this case is not controlled by sec. 807.05, Stats. Our statement that stipulations of settlement are not governed by contract law is generic. In United States v. Swift & Co., 286 U.S. 106, 115 (1932), the Court made clear that when an order is entered pursuant to the consent of the parties to be bound thereby it is a judicial act, subject to the court's continuing jurisdiction to modify the order. The Court stated:

The result is all one whether the decree has been entered after litigation or by consent. In either event, a court does not abdicate its power to revoke or modify its mandate if satisfied that what it has been doing has been turned through changing circumstances into an instrument of wrong.
Id. at 114-15 (citation omitted).
The dissent is apparently concerned that Seal Tite will lose its bargain, its "quid pro quo," if Lueck's claim is allowed. However, its concern is premature. Our mandate does not direct the trial court to allow Lueck's claim, merely to consider whether Lueck's Failure to strictly comply with the filing requirements of the order has made it inequitable to Seal Tite to allow the claim.
[1]  Section 100.18(11)(b)2., Stats., provides:

Any person suffering pecuniary loss because of violation of this section by any other person may sue in any court of competent jurisdiction and shall recover such pecuniary loss, together with costs, including reasonable attorney fees. Any person suffering pecuniary loss because of a violation by any other person or any injunction issued under this section may sue for damages therefor in any court of competent jurisdiction and shall recover twice the amount of such pecuniary loss, together with costs, including reasonable attorney fees.
[2]  Section 100.18(11)(e), Stats., provides:

In lieu of instituting or continuing an action pursuant to this section, the department or the department of justice may accept a written assurance of discontinuance of any act or practice alleged to be a violation of this section from the person who has engaged in such act or practice. The acceptance of such assurance by either the department or the department of justice shall be deemed acceptance by the other state officials enumerated in par. (d) if the terms of the assurance so provide. An assurance entered into pursuant to this section shall not be considered evidence of a violation of this section, provided that violation of such an assurance shall be treated as a violation of this section, and shall be subjected to all the penalties and remedies provided therefor.
Section 553.54(4), Stats., provides:
In lieu of instituting or continuing an action pursuant to this section, the commissioner or the department of justice may accept a written assurance of discontinuance of any act or practice alleged to be a violation of this chapter from the person who has engaged in such act or practice. The acceptance of such assurance by either the commissioner or the department shall be deemed acceptance by other state officials if the terms of the assurance so provide. An assurance entered into pursuant to this subsection shall not be considered evidence of a violation of this chapter, however, a violation of such an assurance constitutes a violation of this chapter and shall be subject to all penalties and remedies provided therefor.
