Mandatorian
NW Mandatorian
Campos obligatorios configurables por tipo de documento — niccoweb.com Configurable mandatory fields per document type — niccoweb.com
Por tipo de documentoPer document type
Cada campo puede ser obligatorio en unos tipos de documento y no en otros — 6 tipos de venta y 6 de compra, todos independientes.Each field can be mandatory for some document types and not others — 6 sales types and 6 purchase types, all independent.
Por momentoPer moment
El chequeo se puede activar solo al liberar, solo al contabilizar, o ambos — por separado para ventas y compras.The check can run only on release, only on posting, or both — independently for sales and purchases.
Sin tocar ALNo AL changes needed
Añadir un nuevo campo obligatorio es una fila más en una lista de configuración, no una nueva validación programada.Adding a new mandatory field is one more row in a setup list, not a new coded validation.
Eventos estándarStandard events
Se apoya en los 4 eventos nativos de liberar/contabilizar venta y compra; no modifica ninguna tabla base.Built on the 4 native release/post events for sales and purchases; no base table is modified.
Cabecera y líneasHeader and lines
Valida tanto la cabecera del documento como cada una de sus líneas, no solo el encabezado.Validates both the document header and every one of its lines, not just the header.
Lookup de camposField lookup
La tabla y el campo se eligen con el lookup estándar de BC, sin escribir nombres internos a mano.Table and field are picked with BC's standard lookup, with no internal names typed by hand.
Interruptor maestroMaster switch
El campo "Active" en Mandatory Setup desactiva todas las validaciones de un solo clic.The "Active" field on Mandatory Setup turns every check off with a single click.
Matriz por filaPer-row matrix
El mismo campo puede ser obligatorio en Pedido pero no en Cotización: cada fila tiene su propia matriz de casillas.The same field can be mandatory on an Order but not on a Quote: each row has its own matrix of checkboxes.
- 1Abre la página Mandatory Setup desde el buscador de Business Central.Open the Mandatory Setup page from Business Central's search.
- 2Activa Active y los chequeos que necesites: Sales Release, Sales Post, Purchase Release, Purchase Post.Turn on Active and the checks you need: Sales Release, Sales Post, Purchase Release, Purchase Post.
- 3En la lista de campos de venta o compra (embebida en la misma página), añade una fila por cada tabla + campo a volver obligatorio usando el lookup.In the sales or purchase field list (embedded on the same page), add one row per table + field to make mandatory, using the lookup.
- 4Marca las casillas de los tipos de documento donde ese campo debe ser obligatorio (Pedido, Cotización, Factura, Nota de Crédito, etc.).Tick the document types where that field must be mandatory (Order, Quote, Invoice, Credit Memo, etc.).
- 1Los usuarios trabajan con sus documentos de venta o compra con normalidad.Users work with their sales or purchase documents as usual.
- 2Al liberar o contabilizar, si el chequeo correspondiente está activo, NW Mandatorian revisa cabecera y líneas.On release or posting, if the matching check is active, NW Mandatorian reviews the header and the lines.
- 3Si falta un campo obligatorio para ese tipo de documento, BC muestra el mensaje estándar "El campo X debe tener un valor" y detiene la acción.If a field required for that document type is missing, BC shows the standard "Field X must have a value" message and stops the action.
- 4Si todos los campos configurados están completos, el documento se libera o contabiliza sin interrupciones.If every configured field is filled in, the document releases or posts without interruption.
NW Mandatory Field:Each of these 12 document types has its own column in NW Mandatory Field:
VentaSales
CompraPurchase
| Evento / Event | Objeto estándarStandard Object | Se activa al...Triggered when... |
|---|---|---|
OnBeforePostSalesDoc | Codeunit "Sales-Post" | Contabilizar un documento de ventaPosting a sales document |
OnBeforeReleaseSalesDoc | Codeunit "Release Sales Document" | Liberar un documento de ventaReleasing a sales document |
OnBeforePostPurchaseDoc | Codeunit "Purch.-Post" | Contabilizar un documento de compraPosting a purchase document |
OnBeforeReleasePurchaseDoc | Codeunit "Release Purchase Document" | Liberar un documento de compraReleasing a purchase document |
Mandatory Setup (¿Active? ¿el chequeo de esa acción está encendido?); si no, sale sin validar nada.Each event first checks Mandatory Setup (Active? is the check for that action switched on?); if not, it exits without validating anything.
| TipoType | NombreName | ID | DescripciónDescription |
|---|---|---|---|
| TablaTable | NW Mandatory Field | 60900 | Una fila por tabla + campo a volver obligatorio, con una casilla por tipo de documento de venta y compraOne row per table + field to make mandatory, with one checkbox per sales and purchase document type |
| TablaTable | Mandatory Setup | 60901 | Registro único de configuración: interruptor maestro y 4 chequeos (Release/Post × Venta/Compra)Single setup record: master switch and 4 checks (Release/Post × Sales/Purchase) |
| PáginaPage | Mandatory Setup | 60901 | Página de configuración principal; embebe las dos listas de campos obligatoriosMain setup page; embeds both mandatory-field lists |
| PáginaPage | NW Mandatory Sale Field List | 60900 | Lista de campos obligatorios para venta, filtrada a Sales Header / Sales LineMandatory field list for sales, filtered to Sales Header / Sales Line |
| PáginaPage | NW Mandatory Purch. Field List | 60902 | Lista de campos obligatorios para compra, filtrada a Purchase Header / Purchase LineMandatory field list for purchases, filtered to Purchase Header / Purchase Line |
| Codeunit | NW Mandatory Management | 60900 | Suscriptor de los 4 eventos; valida cabecera y líneas contra la configuraciónSubscriber for the 4 events; validates header and lines against the setup |
| CampoField | DescripciónDescription |
|---|---|
Active | Interruptor maestro: si está apagado, ningún chequeo se ejecuta sin importar lo demás.Master switch: if off, no check runs regardless of anything else. |
Sales Release | Valida los campos obligatorios al liberar un documento de venta.Validates mandatory fields when releasing a sales document. |
Sales Post | Valida los campos obligatorios al contabilizar un documento de venta.Validates mandatory fields when posting a sales document. |
Purchase Release | Valida los campos obligatorios al liberar un documento de compra.Validates mandatory fields when releasing a purchase document. |
Purchase Post | Valida los campos obligatorios al contabilizar un documento de compra.Validates mandatory fields when posting a purchase document. |
- ✓Business Central versión 26.0 o posterior (runtime AL 15.0).version 26.0 or higher (AL runtime 15.0).
- ✓Permisos para crear y editar registros en Mandatory Setup y NW Mandatory Field.Permissions to create and edit records in Mandatory Setup and NW Mandatory Field.
- ✓Tener claro qué tablas y campos —estándar o personalizados— deben volverse obligatorios y en qué documentos.Knowing which tables and fields — standard or custom — must become mandatory, and on which documents.
Comentarios
Publicar un comentario