advpl-mvc-avancado

Community

Customizar MVC padrão sem quebrar validações

AuthorJoniPraia
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This skill solves the problem of safely extending TOTVS Protheus MVC standard screens by injecting grids, triggers, validations, and behavior without corrupting the original routine.

Core Features & Use Cases

  • Add child grids to standard MVC screens via PE STRU: Customize routines (e.g., CNTA300, MATA070, MATA440, MATA460, FINA040) by adding a new grid tied to the existing master grid.
  • Cascading triggers with safe navigation: Recalculate values across parent/child grids using triggers, including required use of FWSaveRows/FWRestRows to prevent row-position bugs.
  • Preserve original validations: Extend validation logic by capturing and chaining existing bLinePost (so you don’t break TOTVS behavior).
  • Structured error messaging: Use SetErrorMessage to surface validation feedback in the standard MVC UI flow.
  • Integrate MATXFIS inside MVC triggers: Perform fiscal calculations inside MVC triggers while preventing context leakage by using MaFisEnd() and related MATXFIS lifecycle correctly.
  • Contextual behavior by status and call stack: Control editability using status blocks (e.g., SetOnlyView/SetOnlyQuery/SetNoInsertLine) and adjust validation based on FwIsInCallStack.

Quick Start

Use the advpl-mvc-avancado skill to add a custom child grid to a standard routine (such as CNTA300) using its corresponding *STRU Punto de Entrada, with cascaded triggers that recalculate child rows safely and preserve the original validation behavior.

Dependency Matrix

Required Modules

None required

Components

references

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: advpl-mvc-avancado
Download link: https://github.com/JoniPraia/plugadvpl/archive/main.zip#advpl-mvc-avancado

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.