Compare commits
113 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
94d33e1145 | ||
|
|
4778523436 | ||
|
|
be278fced3 | ||
|
|
2914a84a66 | ||
|
|
35e175dacf | ||
|
|
52fa2ea99a | ||
|
|
9389386ec6 | ||
|
|
4e485be0cd | ||
|
|
a7a418f6e2 | ||
|
|
0fb8ca7a14 | ||
|
|
f65c30129b | ||
|
|
76c6fda05c | ||
|
|
f25c8d4845 | ||
|
|
2598db2520 | ||
|
|
7f2b60c5ec | ||
|
|
90010b11a8 | ||
|
|
cec32cb293 | ||
|
|
6c1961d5d6 | ||
|
|
4a3d4d2111 | ||
|
|
d9d8493aa3 | ||
|
|
9d94c5d6d3 | ||
|
|
045558769d | ||
|
|
7bf102e041 | ||
|
|
fb9ca18a04 | ||
|
|
3680a904e2 | ||
|
|
9f8ffa7eca | ||
|
|
9e1954b1b2 | ||
|
|
34079491f7 | ||
|
|
2f8078f0df | ||
|
|
6f08d67402 | ||
|
|
7e9d4c18d3 | ||
|
|
d5790b8abb | ||
|
|
7006c9a415 | ||
|
|
7686ef4d97 | ||
|
|
68deff1d24 | ||
|
|
90867b3595 | ||
|
|
b943ef6fed | ||
|
|
5af1e37539 | ||
|
|
a527835756 | ||
|
|
a35732a260 | ||
|
|
bb8cd97537 | ||
|
|
990b56fee9 | ||
|
|
72d0328fa0 | ||
|
|
77937b249a | ||
|
|
6101d38b0d | ||
|
|
573b8d1ca3 | ||
|
|
8653165eed | ||
|
|
c0a0c2b0d1 | ||
|
|
fff62a9a12 | ||
|
|
2d866c6316 | ||
|
|
34af3362da | ||
|
|
7274dae657 | ||
|
|
e4f08bf9a7 | ||
|
|
de09820554 | ||
|
|
07f7d3fad3 | ||
|
|
9c6169cd6c | ||
|
|
d4c41c7a00 | ||
|
|
cbb4b02680 | ||
|
|
723ebe0f8c | ||
|
|
a135d8b92c | ||
|
|
359c95bfac | ||
|
|
a1725fca7b | ||
|
|
51853c60ee | ||
|
|
6ca52ea91a | ||
|
|
c636361aaf | ||
|
|
ab0f87f1e5 | ||
|
|
816d38948d | ||
|
|
910c3b92b3 | ||
|
|
d9c8e0231b | ||
|
|
ca19ee8d56 | ||
|
|
c354076240 | ||
|
|
ac41363f39 | ||
|
|
2c5e80a8bf | ||
|
|
ce10cf9e96 | ||
|
|
099d17c0d2 | ||
|
|
e9d640d50a | ||
|
|
b46ee5b225 | ||
|
|
d60c48d8a0 | ||
|
|
2834098a70 | ||
|
|
5a801fae69 | ||
|
|
3923b7fdf4 | ||
|
|
78925a791a | ||
|
|
1e734f8858 | ||
|
|
929cf13e1e | ||
|
|
6a0769ecdf | ||
|
|
04bf19baad | ||
|
|
64810dd590 | ||
|
|
a01eae5835 | ||
|
|
4c36721a0a | ||
|
|
52ba0d2c26 | ||
|
|
aca2511c9a | ||
|
|
fd4c4e6198 | ||
|
|
002f3c1d18 | ||
|
|
fc2093e43d | ||
|
|
e0ebd5cb4a | ||
|
|
63ca70861e | ||
|
|
205450b587 | ||
|
|
a3eb251835 | ||
|
|
74b575a122 | ||
|
|
62b3194f3b | ||
|
|
740dbf4e5a | ||
|
|
27483c8f45 | ||
|
|
b3164ca8f0 | ||
|
|
4d6fcee21a | ||
|
|
829e0acf57 | ||
|
|
cb4e8e2194 | ||
|
|
158b902b20 | ||
|
|
de51cb0ad5 | ||
|
|
90cf73d9e5 | ||
|
|
4f1faf3e84 | ||
|
|
d23ccf86e1 | ||
|
|
bd0e425174 | ||
|
|
3941105a09 |
0
.nojekyll
Normal file
8
404.html
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
<!doctype html><html lang=en class=no-js><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no"><meta name=generator content="Hugo 0.119.0"><meta name=robots content="index, follow"><link rel="shortcut icon" href=/favicons/favicon.ico><link rel=apple-touch-icon href=/favicons/apple-touch-icon-180x180.png sizes=180x180><link rel=icon type=image/png href=/favicons/favicon-16x16.png sizes=16x16><link rel=icon type=image/png href=/favicons/favicon-32x32.png sizes=32x32><link rel=icon type=image/png href=/favicons/android-36x36.png sizes=36x36><link rel=icon type=image/png href=/favicons/android-48x48.png sizes=48x48><link rel=icon type=image/png href=/favicons/android-72x72.png sizes=72x72><link rel=icon type=image/png href=/favicons/android-96x96.png sizes=96x96><link rel=icon type=image/png href=/favicons/android-144x144.png sizes=144x144><link rel=icon type=image/png href=/favicons/android-192x192.png sizes=192x192><title>404 Page not found | alguidelines.dev - Business Central Design Patterns</title><meta name=description content><meta property="og:title" content="404 Page not found"><meta property="og:description" content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta property="og:type" content="website"><meta property="og:url" content="https://alguidelines.dev/404.html"><meta property="og:image" content="https://alguidelines.dev/images/og-image-fission.png"><meta itemprop=name content="404 Page not found"><meta itemprop=description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta name=twitter:card content="summary_large_image"><meta name=twitter:image content="https://alguidelines.dev/images/og-image-fission.png"><meta name=twitter:title content="404 Page not found"><meta name=twitter:description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><link rel=preload href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css as=style><link href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css rel=stylesheet integrity><script src=https://code.jquery.com/jquery-3.6.0.min.js integrity=sha384-vtXRMe3mGCbOeY7l30aIg8H9p3GdeSe4IFlP6G8JMa7o7lXvnz3GFKzPxzJdPfGK crossorigin=anonymous></script>
|
||||||
|
<script src=https://unpkg.com/lunr@2.3.9/lunr.min.js integrity=sha384-203J0SNzyqHby3iU6hzvzltrWi/M41wOP5Gu+BiJMz5nwKykbkUx8Kp7iti0Lpli crossorigin=anonymous></script></head><body class=td-404><header><nav class="js-navbar-scroll navbar navbar-expand navbar-dark flex-column flex-md-row td-navbar"><a class=navbar-brand href=/><img src=/images/SiteLogo.png height=32px>
|
||||||
|
<span class="font-weight-bold show-desktop">alguidelines.dev - Business Central Design Patterns</span>
|
||||||
|
<span class="font-weight-bold show-mobile-inline">alguidelines.dev</span></a><div class="td-navbar-nav-scroll ml-md-auto" id=main_navbar><ul class="navbar-nav mt-2 mt-lg-0"><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=/docs/><i class='fas fa-book'></i><span>Docs</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines/discussions/ target=_blank><i class='fas fa-comments'></i><span>Discussions</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines target=_blank><i class='fab fa-github'></i><span>GitHub</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://discord.gg/4wbfNv3 target=_blank><i class='fab fa-discord'></i><span>Discord</span></a></li></ul></div><div class="navbar-nav d-none d-lg-block"><input type=search class="form-control td-search-input" placeholder=" Search this site…" aria-label="Search this site…" autocomplete=off data-offline-search-index-json-src=/offline-search-index.f57facda2998f11fdc2549a36425d2f6.json data-offline-search-base-href=/ data-offline-search-max-results=10></div></nav></header><div class="container-fluid td-default td-outer"><main role=main class=td-main><main id=main><div><h1 id=title>Not found</h1><p>Oops! This page doesn't exist. Try going back to our <a href=/>home page</a>.</p></div></main></main><footer class="bg-dark py-5 row d-print-none"><div class="container-fluid mx-sm-5"><div class=row><div class="col-6 col-sm-4 text-xs-center order-sm-2"><ul class="list-inline mb-0"><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=GitHub aria-label=GitHub><a class=text-white target=_blank rel=noopener href=https://github.com/microsoft/alguidelines aria-label=GitHub><i class="fab fa-github"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Twitter aria-label=Twitter><a class=text-white target=_blank rel=noopener href="https://twitter.com/search?q=%23bcalhelp" aria-label=Twitter><i class="fab fa-twitter"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Discord aria-label=Discord><a class=text-white target=_blank rel=noopener href=https://discord.gg/4wbfNv3 aria-label=Discord><i class="fab fa-discord"></i></a></li></ul></div><div class="col-6 col-sm-4 text-right text-xs-center order-sm-3"></div><div class="col-12 col-sm-4 text-center py-2 order-sm-2"><small class=text-white>© 2023 alguidelines.dev Project All Rights Reserved</small></div></div></div></footer></div><script src=https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js integrity=sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.min.js integrity="sha512-UR25UO94eTnCVwjbXozyeVd6ZqpaAE9naiEUBK/A+QDbfSTQFhPGj5lOR6d8tsgbBk84Ggb5A3EkjsOgPRPcKA==" crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/mermaid@8.13.4/dist/mermaid.min.js integrity="sha512-JERecFUBbsm75UpkVheAuDOE8NdHjQBrPACfEQYPwvPG+fjgCpHAz1Jw2ci9EXmd3DdfiWth3O3CQvcfEg8gsA==" crossorigin=anonymous></script>
|
||||||
|
<script src=/js/tabpane-persist.js></script>
|
||||||
|
<script src=/js/main.min.9021b54d402798091af52a2fc8b747e6c5076e5f1323b276dc25e0774fb46c2d.js integrity="sha256-kCG1TUAnmAka9SovyLdH5sUHbl8TI7J23CXgd0+0bC0=" crossorigin=anonymous></script></body></html>
|
||||||
1
CNAME
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
alguidelines.dev
|
||||||
|
|
@ -1,9 +0,0 @@
|
||||||
# Microsoft Open Source Code of Conduct
|
|
||||||
|
|
||||||
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
|
|
||||||
|
|
||||||
Resources:
|
|
||||||
|
|
||||||
- [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
|
|
||||||
- [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
|
|
||||||
- Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
|
|
||||||
21
LICENSE
|
|
@ -1,21 +0,0 @@
|
||||||
MIT License
|
|
||||||
|
|
||||||
Copyright (c) Microsoft Corporation.
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
|
||||||
in the Software without restriction, including without limitation the rights
|
|
||||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all
|
|
||||||
copies or substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
||||||
SOFTWARE
|
|
||||||
33
README.md
|
|
@ -1,33 +0,0 @@
|
||||||
# Project
|
|
||||||
|
|
||||||
> This repo has been populated by an initial template to help get you started. Please
|
|
||||||
> make sure to update the content to build a great experience for community-building.
|
|
||||||
|
|
||||||
As the maintainer of this project, please make a few updates:
|
|
||||||
|
|
||||||
- Improving this README.MD file to provide a great experience
|
|
||||||
- Updating SUPPORT.MD with content about this project's support experience
|
|
||||||
- Understanding the security reporting process in SECURITY.MD
|
|
||||||
- Remove this section from the README
|
|
||||||
|
|
||||||
## Contributing
|
|
||||||
|
|
||||||
This project welcomes contributions and suggestions. Most contributions require you to agree to a
|
|
||||||
Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us
|
|
||||||
the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
|
|
||||||
|
|
||||||
When you submit a pull request, a CLA bot will automatically determine whether you need to provide
|
|
||||||
a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions
|
|
||||||
provided by the bot. You will only need to do this once across all repos using our CLA.
|
|
||||||
|
|
||||||
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
|
|
||||||
For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
|
|
||||||
contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
|
|
||||||
|
|
||||||
## Trademarks
|
|
||||||
|
|
||||||
This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft
|
|
||||||
trademarks or logos is subject to and must follow
|
|
||||||
[Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
|
|
||||||
Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
|
|
||||||
Any use of third-party trademarks or logos are subject to those third-party's policies.
|
|
||||||
41
SECURITY.md
|
|
@ -1,41 +0,0 @@
|
||||||
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.5 BLOCK -->
|
|
||||||
|
|
||||||
## Security
|
|
||||||
|
|
||||||
Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).
|
|
||||||
|
|
||||||
If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below.
|
|
||||||
|
|
||||||
## Reporting Security Issues
|
|
||||||
|
|
||||||
**Please do not report security vulnerabilities through public GitHub issues.**
|
|
||||||
|
|
||||||
Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report).
|
|
||||||
|
|
||||||
If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).
|
|
||||||
|
|
||||||
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).
|
|
||||||
|
|
||||||
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:
|
|
||||||
|
|
||||||
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
|
|
||||||
* Full paths of source file(s) related to the manifestation of the issue
|
|
||||||
* The location of the affected source code (tag/branch/commit or direct URL)
|
|
||||||
* Any special configuration required to reproduce the issue
|
|
||||||
* Step-by-step instructions to reproduce the issue
|
|
||||||
* Proof-of-concept or exploit code (if possible)
|
|
||||||
* Impact of the issue, including how an attacker might exploit the issue
|
|
||||||
|
|
||||||
This information will help us triage your report more quickly.
|
|
||||||
|
|
||||||
If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs.
|
|
||||||
|
|
||||||
## Preferred Languages
|
|
||||||
|
|
||||||
We prefer all communications to be in English.
|
|
||||||
|
|
||||||
## Policy
|
|
||||||
|
|
||||||
Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).
|
|
||||||
|
|
||||||
<!-- END MICROSOFT SECURITY.MD BLOCK -->
|
|
||||||
25
SUPPORT.md
|
|
@ -1,25 +0,0 @@
|
||||||
# TODO: The maintainer of this repo has not yet edited this file
|
|
||||||
|
|
||||||
**REPO OWNER**: Do you want Customer Service & Support (CSS) support for this product/project?
|
|
||||||
|
|
||||||
- **No CSS support:** Fill out this template with information about how to file issues and get help.
|
|
||||||
- **Yes CSS support:** Fill out an intake form at [aka.ms/spot](https://aka.ms/spot). CSS will work with/help you to determine next steps. More details also available at [aka.ms/onboardsupport](https://aka.ms/onboardsupport).
|
|
||||||
- **Not sure?** Fill out a SPOT intake as though the answer were "Yes". CSS will help you decide.
|
|
||||||
|
|
||||||
*Then remove this first heading from this SUPPORT.MD file before publishing your repo.*
|
|
||||||
|
|
||||||
# Support
|
|
||||||
|
|
||||||
## How to file issues and get help
|
|
||||||
|
|
||||||
This project uses GitHub Issues to track bugs and feature requests. Please search the existing
|
|
||||||
issues before filing new issues to avoid duplicates. For new issues, file your bug or
|
|
||||||
feature request as a new Issue.
|
|
||||||
|
|
||||||
For help and questions about using this project, please **REPO MAINTAINER: INSERT INSTRUCTIONS HERE
|
|
||||||
FOR HOW TO ENGAGE REPO OWNERS OR COMMUNITY FOR HELP. COULD BE A STACK OVERFLOW TAG OR OTHER
|
|
||||||
CHANNEL. WHERE WILL YOU HELP PEOPLE?**.
|
|
||||||
|
|
||||||
## Microsoft Support Policy
|
|
||||||
|
|
||||||
Support for this **PROJECT or PRODUCT** is limited to the resources listed above.
|
|
||||||
8
author/index.html
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
<!doctype html><html lang=en class=no-js><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no"><meta name=generator content="Hugo 0.119.0"><link rel=alternate type=application/rss+xml href=https://alguidelines.dev/author/index.xml><meta name=robots content="index, follow"><link rel="shortcut icon" href=/favicons/favicon.ico><link rel=apple-touch-icon href=/favicons/apple-touch-icon-180x180.png sizes=180x180><link rel=icon type=image/png href=/favicons/favicon-16x16.png sizes=16x16><link rel=icon type=image/png href=/favicons/favicon-32x32.png sizes=32x32><link rel=icon type=image/png href=/favicons/android-36x36.png sizes=36x36><link rel=icon type=image/png href=/favicons/android-48x48.png sizes=48x48><link rel=icon type=image/png href=/favicons/android-72x72.png sizes=72x72><link rel=icon type=image/png href=/favicons/android-96x96.png sizes=96x96><link rel=icon type=image/png href=/favicons/android-144x144.png sizes=144x144><link rel=icon type=image/png href=/favicons/android-192x192.png sizes=192x192><title>Author | alguidelines.dev - Business Central Design Patterns</title><meta name=description content><meta property="og:title" content="Author"><meta property="og:description" content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta property="og:type" content="website"><meta property="og:url" content="https://alguidelines.dev/author/"><meta property="og:image" content="https://alguidelines.dev/images/og-image-fission.png"><meta itemprop=name content="Author"><meta itemprop=description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta name=twitter:card content="summary_large_image"><meta name=twitter:image content="https://alguidelines.dev/images/og-image-fission.png"><meta name=twitter:title content="Author"><meta name=twitter:description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><link rel=preload href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css as=style><link href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css rel=stylesheet integrity><script src=https://code.jquery.com/jquery-3.6.0.min.js integrity=sha384-vtXRMe3mGCbOeY7l30aIg8H9p3GdeSe4IFlP6G8JMa7o7lXvnz3GFKzPxzJdPfGK crossorigin=anonymous></script>
|
||||||
|
<script src=https://unpkg.com/lunr@2.3.9/lunr.min.js integrity=sha384-203J0SNzyqHby3iU6hzvzltrWi/M41wOP5Gu+BiJMz5nwKykbkUx8Kp7iti0Lpli crossorigin=anonymous></script></head><body class=td-taxonomy><header><nav class="js-navbar-scroll navbar navbar-expand navbar-dark flex-column flex-md-row td-navbar"><a class=navbar-brand href=/><img src=/images/SiteLogo.png height=32px>
|
||||||
|
<span class="font-weight-bold show-desktop">alguidelines.dev - Business Central Design Patterns</span>
|
||||||
|
<span class="font-weight-bold show-mobile-inline">alguidelines.dev</span></a><div class="td-navbar-nav-scroll ml-md-auto" id=main_navbar><ul class="navbar-nav mt-2 mt-lg-0"><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=/docs/><i class='fas fa-book'></i><span>Docs</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines/discussions/ target=_blank><i class='fas fa-comments'></i><span>Discussions</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines target=_blank><i class='fab fa-github'></i><span>GitHub</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://discord.gg/4wbfNv3 target=_blank><i class='fab fa-discord'></i><span>Discord</span></a></li></ul></div><div class="navbar-nav d-none d-lg-block"><input type=search class="form-control td-search-input" placeholder=" Search this site…" aria-label="Search this site…" autocomplete=off data-offline-search-index-json-src=/offline-search-index.f57facda2998f11fdc2549a36425d2f6.json data-offline-search-base-href=/ data-offline-search-max-results=10></div></nav></header><div class="container-fluid td-default td-outer"><main role=main class=td-main><div class=td-content><main class=taxonomy-terms-page><h1>Author</h1></main></div></main><footer class="bg-dark py-5 row d-print-none"><div class="container-fluid mx-sm-5"><div class=row><div class="col-6 col-sm-4 text-xs-center order-sm-2"><ul class="list-inline mb-0"><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=GitHub aria-label=GitHub><a class=text-white target=_blank rel=noopener href=https://github.com/microsoft/alguidelines aria-label=GitHub><i class="fab fa-github"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Twitter aria-label=Twitter><a class=text-white target=_blank rel=noopener href="https://twitter.com/search?q=%23bcalhelp" aria-label=Twitter><i class="fab fa-twitter"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Discord aria-label=Discord><a class=text-white target=_blank rel=noopener href=https://discord.gg/4wbfNv3 aria-label=Discord><i class="fab fa-discord"></i></a></li></ul></div><div class="col-6 col-sm-4 text-right text-xs-center order-sm-3"></div><div class="col-12 col-sm-4 text-center py-2 order-sm-2"><small class=text-white>© 2023 alguidelines.dev Project All Rights Reserved</small></div></div></div></footer></div><script src=https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js integrity=sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.min.js integrity="sha512-UR25UO94eTnCVwjbXozyeVd6ZqpaAE9naiEUBK/A+QDbfSTQFhPGj5lOR6d8tsgbBk84Ggb5A3EkjsOgPRPcKA==" crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/mermaid@8.13.4/dist/mermaid.min.js integrity="sha512-JERecFUBbsm75UpkVheAuDOE8NdHjQBrPACfEQYPwvPG+fjgCpHAz1Jw2ci9EXmd3DdfiWth3O3CQvcfEg8gsA==" crossorigin=anonymous></script>
|
||||||
|
<script src=/js/tabpane-persist.js></script>
|
||||||
|
<script src=/js/main.min.9021b54d402798091af52a2fc8b747e6c5076e5f1323b276dc25e0774fb46c2d.js integrity="sha256-kCG1TUAnmAka9SovyLdH5sUHbl8TI7J23CXgd0+0bC0=" crossorigin=anonymous></script></body></html>
|
||||||
1
author/index.xml
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – Author</title><link>https://alguidelines.dev/author/</link><description>Recent content in Author on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/author/index.xml" rel="self" type="application/rss+xml"/></channel></rss>
|
||||||
14
blog/index.html
Normal file
|
|
@ -0,0 +1,14 @@
|
||||||
|
<!doctype html><html lang=en class=no-js><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no"><meta name=generator content="Hugo 0.119.0"><link rel=alternate type=application/rss+xml href=https://alguidelines.dev/blog/index.xml><meta name=robots content="index, follow"><link rel="shortcut icon" href=/favicons/favicon.ico><link rel=apple-touch-icon href=/favicons/apple-touch-icon-180x180.png sizes=180x180><link rel=icon type=image/png href=/favicons/favicon-16x16.png sizes=16x16><link rel=icon type=image/png href=/favicons/favicon-32x32.png sizes=32x32><link rel=icon type=image/png href=/favicons/android-36x36.png sizes=36x36><link rel=icon type=image/png href=/favicons/android-48x48.png sizes=48x48><link rel=icon type=image/png href=/favicons/android-72x72.png sizes=72x72><link rel=icon type=image/png href=/favicons/android-96x96.png sizes=96x96><link rel=icon type=image/png href=/favicons/android-144x144.png sizes=144x144><link rel=icon type=image/png href=/favicons/android-192x192.png sizes=192x192><title>AL Guidelines Blog | alguidelines.dev - Business Central Design Patterns</title><meta name=description content><meta property="og:title" content="AL Guidelines Blog"><meta property="og:description" content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta property="og:type" content="website"><meta property="og:url" content="https://alguidelines.dev/blog/"><meta property="og:image" content="https://alguidelines.dev/images/og-image-fission.png"><meta itemprop=name content="AL Guidelines Blog"><meta itemprop=description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta name=twitter:card content="summary_large_image"><meta name=twitter:image content="https://alguidelines.dev/images/og-image-fission.png"><meta name=twitter:title content="AL Guidelines Blog"><meta name=twitter:description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><link rel=preload href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css as=style><link href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css rel=stylesheet integrity><script src=https://code.jquery.com/jquery-3.6.0.min.js integrity=sha384-vtXRMe3mGCbOeY7l30aIg8H9p3GdeSe4IFlP6G8JMa7o7lXvnz3GFKzPxzJdPfGK crossorigin=anonymous></script>
|
||||||
|
<script src=https://unpkg.com/lunr@2.3.9/lunr.min.js integrity=sha384-203J0SNzyqHby3iU6hzvzltrWi/M41wOP5Gu+BiJMz5nwKykbkUx8Kp7iti0Lpli crossorigin=anonymous></script></head><body class="td-section td-blog"><header><nav class="js-navbar-scroll navbar navbar-expand navbar-dark flex-column flex-md-row td-navbar"><a class=navbar-brand href=/><img src=/images/SiteLogo.png height=32px>
|
||||||
|
<span class="font-weight-bold show-desktop">alguidelines.dev - Business Central Design Patterns</span>
|
||||||
|
<span class="font-weight-bold show-mobile-inline">alguidelines.dev</span></a><div class="td-navbar-nav-scroll ml-md-auto" id=main_navbar><ul class="navbar-nav mt-2 mt-lg-0"><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=/docs/><i class='fas fa-book'></i><span>Docs</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines/discussions/ target=_blank><i class='fas fa-comments'></i><span>Discussions</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines target=_blank><i class='fab fa-github'></i><span>GitHub</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://discord.gg/4wbfNv3 target=_blank><i class='fab fa-discord'></i><span>Discord</span></a></li></ul></div><div class="navbar-nav d-none d-lg-block"><input type=search class="form-control td-search-input" placeholder=" Search this site…" aria-label="Search this site…" autocomplete=off data-offline-search-index-json-src=/offline-search-index.f57facda2998f11fdc2549a36425d2f6.json data-offline-search-base-href=/ data-offline-search-max-results=10></div></nav></header><div class="container-fluid td-outer"><div class=td-main><div class="row flex-xl-nowrap"><aside class="col-12 col-md-3 col-xl-2 td-sidebar d-print-none"><div id=td-sidebar-menu class=td-sidebar__inner><div id=content-mobile><form class="td-sidebar__search d-flex align-items-center"><input type=search class="form-control td-search-input" placeholder=" Search this site…" aria-label="Search this site…" autocomplete=off data-offline-search-index-json-src=/offline-search-index.f57facda2998f11fdc2549a36425d2f6.json data-offline-search-base-href=/ data-offline-search-max-results=10>
|
||||||
|
<button class="btn btn-link td-sidebar__toggle d-md-none p-0 ml-3 fas fa-bars" type=button data-toggle=collapse data-target=#td-section-nav aria-controls=td-docs-nav aria-expanded=false aria-label="Toggle section navigation"></button></form></div><div id=content-desktop></div><nav class="collapse td-sidebar-nav" id=td-section-nav><ul class="td-sidebar-nav__section pr-md-3 ul-0"><li class="td-sidebar-nav__section-title td-sidebar-nav__section without-child" id=m-blog-li><a href=/blog/ title="AL Guidelines Blog" class="align-left pl-0 active td-sidebar-link td-sidebar-link__section tree-root" id=m-blog><span class=td-sidebar-nav-active-item>Blog</span></a></li></ul></nav></div></aside><aside class="d-none d-xl-block col-xl-2 td-sidebar-toc d-print-none"><div class="td-page-meta ml-2 pb-1 pt-2 mb-0"><a href=https://github.com/microsoft/alguidelines/tree/main/content/blog/_index.md class=td-page-meta--view target=_blank rel=noopener><i class="fa fa-file-alt fa-fw"></i> View page source</a>
|
||||||
|
<a href=https://github.com/microsoft/alguidelines/edit/main/content/blog/_index.md class=td-page-meta--edit target=_blank rel=noopener><i class="fa fa-edit fa-fw"></i> Edit this page</a>
|
||||||
|
<a href="https://github.com/microsoft/alguidelines/new/main/content/blog/_index.md?filename=change-me.md&value=---%0Atitle%3A+%22Long+Page+Title%22%0AlinkTitle%3A+%22Short+Nav+Title%22%0Aweight%3A+100%0Adescription%3A+%3E-%0A+++++Page+description+for+heading+and+indexes.%0A---%0A%0A%23%23+Heading%0A%0AEdit+this+template+to+create+your+new+page.%0A%0A%2A+Give+it+a+good+name%2C+ending+in+%60.md%60+-+e.g.+%60getting-started.md%60%0A%2A+Edit+the+%22front+matter%22+section+at+the+top+of+the+page+%28weight+controls+how+its+ordered+amongst+other+pages+in+the+same+directory%3B+lowest+number+first%29.%0A%2A+Add+a+good+commit+message+at+the+bottom+of+the+page+%28%3C80+characters%3B+use+the+extended+description+field+for+more+detail%29.%0A%2A+Create+a+new+branch+so+you+can+preview+your+new+file+and+request+a+review+via+Pull+Request.%0A" class=td-page-meta--child target=_blank rel=noopener><i class="fa fa-edit fa-fw"></i> Create child page</a>
|
||||||
|
<a href="https://github.com/microsoft/alguidelines/issues/new?title=AL%20Guidelines%20Blog" class=td-page-meta--issue target=_blank rel=noopener><i class="fab fa-github fa-fw"></i> Create Issue</a>
|
||||||
|
<a href="https://github.com/microsoft/alguidelines/discussions?discussions_q=AL%20Guidelines%20Blog" class=td-page-meta--issue target=_blank rel=noopener><i class="fab fa-github fa-fw"></i> Discussions</a>
|
||||||
|
<a href=https://github.com/microsoft/alguidelines/issues/new class=td-page-meta--project-issue target=_blank rel=noopener><i class="fas fa-tasks fa-fw"></i> Create project issue</a></div><div class="taxonomy taxonomy-terms-cloud taxo-tags"><h5 class=taxonomy-title>Tag Cloud</h5><ul class=taxonomy-terms><li><a class=taxonomy-term href=https://alguidelines.dev/tags/al/ data-taxonomy-term=al><span class=taxonomy-label>AL</span><span class=taxonomy-count>37</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/api/ data-taxonomy-term=api><span class=taxonomy-label>API</span><span class=taxonomy-count>3</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/c/al/ data-taxonomy-term=c/al><span class=taxonomy-label>C/AL</span><span class=taxonomy-count>136</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/decoupling/ data-taxonomy-term=decoupling><span class=taxonomy-label>Decoupling</span><span class=taxonomy-count>2</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/extendability/ data-taxonomy-term=extendability><span class=taxonomy-label>Extendability</span><span class=taxonomy-count>3</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/interface/ data-taxonomy-term=interface><span class=taxonomy-label>Interface</span><span class=taxonomy-count>2</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/performance/ data-taxonomy-term=performance><span class=taxonomy-label>Performance</span><span class=taxonomy-count>2</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/productivity/ data-taxonomy-term=productivity><span class=taxonomy-label>Productivity</span><span class=taxonomy-count>1</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/readability/ data-taxonomy-term=readability><span class=taxonomy-label>Readability</span><span class=taxonomy-count>56</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/telemetry/ data-taxonomy-term=telemetry><span class=taxonomy-label>Telemetry</span><span class=taxonomy-count>1</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/tags/testability/ data-taxonomy-term=testability><span class=taxonomy-label>Testability</span><span class=taxonomy-count>2</span></a></li></ul></div><div class="taxonomy taxonomy-terms-cloud taxo-categories"><h5 class=taxonomy-title>Categories</h5><ul class=taxonomy-terms><li><a class=taxonomy-term href=https://alguidelines.dev/categories/best-practice/ data-taxonomy-term=best-practice><span class=taxonomy-label>Best Practice</span><span class=taxonomy-count>91</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/categories/pattern/ data-taxonomy-term=pattern><span class=taxonomy-label>Pattern</span><span class=taxonomy-count>73</span></a></li></ul></div></aside><main class="col-12 col-md-9 col-xl-8 pl-md-5 pr-md-4" role=main><a class="btn btn-lg -bg-orange td-rss-button d-none d-lg-block" href=https://alguidelines.dev/blog/index.xml target=_blank>RSS <i class="fa fa-rss ml-2"></i></a><div class=row><div class=col-12></div></div><div class="row pl-2 pt-2"><div class=col></div></div></main></div></div><footer class="bg-dark py-5 row d-print-none"><div class="container-fluid mx-sm-5"><div class=row><div class="col-6 col-sm-4 text-xs-center order-sm-2"><ul class="list-inline mb-0"><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=GitHub aria-label=GitHub><a class=text-white target=_blank rel=noopener href=https://github.com/microsoft/alguidelines aria-label=GitHub><i class="fab fa-github"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Twitter aria-label=Twitter><a class=text-white target=_blank rel=noopener href="https://twitter.com/search?q=%23bcalhelp" aria-label=Twitter><i class="fab fa-twitter"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Discord aria-label=Discord><a class=text-white target=_blank rel=noopener href=https://discord.gg/4wbfNv3 aria-label=Discord><i class="fab fa-discord"></i></a></li></ul></div><div class="col-6 col-sm-4 text-right text-xs-center order-sm-3"></div><div class="col-12 col-sm-4 text-center py-2 order-sm-2"><small class=text-white>© 2023 alguidelines.dev Project All Rights Reserved</small></div></div></div></footer></div><script src=https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js integrity=sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.min.js integrity="sha512-UR25UO94eTnCVwjbXozyeVd6ZqpaAE9naiEUBK/A+QDbfSTQFhPGj5lOR6d8tsgbBk84Ggb5A3EkjsOgPRPcKA==" crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/mermaid@8.13.4/dist/mermaid.min.js integrity="sha512-JERecFUBbsm75UpkVheAuDOE8NdHjQBrPACfEQYPwvPG+fjgCpHAz1Jw2ci9EXmd3DdfiWth3O3CQvcfEg8gsA==" crossorigin=anonymous></script>
|
||||||
|
<script src=/js/tabpane-persist.js></script>
|
||||||
|
<script src=/js/main.min.9021b54d402798091af52a2fc8b747e6c5076e5f1323b276dc25e0774fb46c2d.js integrity="sha256-kCG1TUAnmAka9SovyLdH5sUHbl8TI7J23CXgd0+0bC0=" crossorigin=anonymous></script></body></html>
|
||||||
1
blog/index.xml
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – AL Guidelines Blog</title><link>https://alguidelines.dev/blog/</link><description>Recent content in AL Guidelines Blog on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/blog/index.xml" rel="self" type="application/rss+xml"/></channel></rss>
|
||||||
8
categories/best-practice/index.html
Normal file
1507
categories/best-practice/index.xml
Normal file
8
categories/index.html
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
<!doctype html><html lang=en class=no-js><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no"><meta name=generator content="Hugo 0.119.0"><link rel=alternate type=application/rss+xml href=https://alguidelines.dev/categories/index.xml><meta name=robots content="index, follow"><link rel="shortcut icon" href=/favicons/favicon.ico><link rel=apple-touch-icon href=/favicons/apple-touch-icon-180x180.png sizes=180x180><link rel=icon type=image/png href=/favicons/favicon-16x16.png sizes=16x16><link rel=icon type=image/png href=/favicons/favicon-32x32.png sizes=32x32><link rel=icon type=image/png href=/favicons/android-36x36.png sizes=36x36><link rel=icon type=image/png href=/favicons/android-48x48.png sizes=48x48><link rel=icon type=image/png href=/favicons/android-72x72.png sizes=72x72><link rel=icon type=image/png href=/favicons/android-96x96.png sizes=96x96><link rel=icon type=image/png href=/favicons/android-144x144.png sizes=144x144><link rel=icon type=image/png href=/favicons/android-192x192.png sizes=192x192><title>Categories | alguidelines.dev - Business Central Design Patterns</title><meta name=description content><meta property="og:title" content="Categories"><meta property="og:description" content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta property="og:type" content="website"><meta property="og:url" content="https://alguidelines.dev/categories/"><meta property="og:image" content="https://alguidelines.dev/images/og-image-fission.png"><meta itemprop=name content="Categories"><meta itemprop=description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><meta name=twitter:card content="summary_large_image"><meta name=twitter:image content="https://alguidelines.dev/images/og-image-fission.png"><meta name=twitter:title content="Categories"><meta name=twitter:description content="Guidelines for when Developing AL for Microsoft Dynamics 365 Business Central"><link rel=preload href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css as=style><link href=/scss/main.min.84a617ff0c0265eb62b5cd2929c572f4ed37dc4907d0cf068be4eb2974f6d60f.css rel=stylesheet integrity><script src=https://code.jquery.com/jquery-3.6.0.min.js integrity=sha384-vtXRMe3mGCbOeY7l30aIg8H9p3GdeSe4IFlP6G8JMa7o7lXvnz3GFKzPxzJdPfGK crossorigin=anonymous></script>
|
||||||
|
<script src=https://unpkg.com/lunr@2.3.9/lunr.min.js integrity=sha384-203J0SNzyqHby3iU6hzvzltrWi/M41wOP5Gu+BiJMz5nwKykbkUx8Kp7iti0Lpli crossorigin=anonymous></script></head><body class=td-taxonomy><header><nav class="js-navbar-scroll navbar navbar-expand navbar-dark flex-column flex-md-row td-navbar"><a class=navbar-brand href=/><img src=/images/SiteLogo.png height=32px>
|
||||||
|
<span class="font-weight-bold show-desktop">alguidelines.dev - Business Central Design Patterns</span>
|
||||||
|
<span class="font-weight-bold show-mobile-inline">alguidelines.dev</span></a><div class="td-navbar-nav-scroll ml-md-auto" id=main_navbar><ul class="navbar-nav mt-2 mt-lg-0"><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=/docs/><i class='fas fa-book'></i><span>Docs</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines/discussions/ target=_blank><i class='fas fa-comments'></i><span>Discussions</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://github.com/microsoft/alguidelines target=_blank><i class='fab fa-github'></i><span>GitHub</span></a></li><li class="nav-item mr-4 mb-2 mb-lg-0"><a class=nav-link href=https://discord.gg/4wbfNv3 target=_blank><i class='fab fa-discord'></i><span>Discord</span></a></li></ul></div><div class="navbar-nav d-none d-lg-block"><input type=search class="form-control td-search-input" placeholder=" Search this site…" aria-label="Search this site…" autocomplete=off data-offline-search-index-json-src=/offline-search-index.f57facda2998f11fdc2549a36425d2f6.json data-offline-search-base-href=/ data-offline-search-max-results=10></div></nav></header><div class="container-fluid td-default td-outer"><main role=main class=td-main><div class=td-content><main class=taxonomy-terms-page><h1>Categories</h1><div class="taxonomy taxonomy-terms-cloud taxo-categories"><ul class=taxonomy-terms><li><a class=taxonomy-term href=https://alguidelines.dev/categories/best-practice/ data-taxonomy-term=best-practice><span class=taxonomy-label>Best Practice</span><span class=taxonomy-count>91</span></a></li><li><a class=taxonomy-term href=https://alguidelines.dev/categories/pattern/ data-taxonomy-term=pattern><span class=taxonomy-label>Pattern</span><span class=taxonomy-count>73</span></a></li></ul></div></main></div></main><footer class="bg-dark py-5 row d-print-none"><div class="container-fluid mx-sm-5"><div class=row><div class="col-6 col-sm-4 text-xs-center order-sm-2"><ul class="list-inline mb-0"><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=GitHub aria-label=GitHub><a class=text-white target=_blank rel=noopener href=https://github.com/microsoft/alguidelines aria-label=GitHub><i class="fab fa-github"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Twitter aria-label=Twitter><a class=text-white target=_blank rel=noopener href="https://twitter.com/search?q=%23bcalhelp" aria-label=Twitter><i class="fab fa-twitter"></i></a></li><li class="list-inline-item mx-2 h3" data-toggle=tooltip data-placement=top title=Discord aria-label=Discord><a class=text-white target=_blank rel=noopener href=https://discord.gg/4wbfNv3 aria-label=Discord><i class="fab fa-discord"></i></a></li></ul></div><div class="col-6 col-sm-4 text-right text-xs-center order-sm-3"></div><div class="col-12 col-sm-4 text-center py-2 order-sm-2"><small class=text-white>© 2023 alguidelines.dev Project All Rights Reserved</small></div></div></div></footer></div><script src=https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js integrity=sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.min.js integrity="sha512-UR25UO94eTnCVwjbXozyeVd6ZqpaAE9naiEUBK/A+QDbfSTQFhPGj5lOR6d8tsgbBk84Ggb5A3EkjsOgPRPcKA==" crossorigin=anonymous></script>
|
||||||
|
<script src=https://cdn.jsdelivr.net/npm/mermaid@8.13.4/dist/mermaid.min.js integrity="sha512-JERecFUBbsm75UpkVheAuDOE8NdHjQBrPACfEQYPwvPG+fjgCpHAz1Jw2ci9EXmd3DdfiWth3O3CQvcfEg8gsA==" crossorigin=anonymous></script>
|
||||||
|
<script src=/js/tabpane-persist.js></script>
|
||||||
|
<script src=/js/main.min.9021b54d402798091af52a2fc8b747e6c5076e5f1323b276dc25e0774fb46c2d.js integrity="sha256-kCG1TUAnmAka9SovyLdH5sUHbl8TI7J23CXgd0+0bC0=" crossorigin=anonymous></script></body></html>
|
||||||
1
categories/index.xml
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – Categories</title><link>https://alguidelines.dev/categories/</link><description>Recent content in Categories on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/categories/index.xml" rel="self" type="application/rss+xml"/></channel></rss>
|
||||||
8
categories/pattern/index.html
Normal file
4481
categories/pattern/index.xml
Normal file
208
css/prism.css
Normal file
|
|
@ -0,0 +1,208 @@
|
||||||
|
/* PrismJS 1.21.0
|
||||||
|
https://prismjs.com/download.html#themes=prism&languages=markup+css+clike+javascript+bash+c+csharp+cpp+go+java+markdown+python+scss+sql+toml+yaml&plugins=toolbar+copy-to-clipboard */
|
||||||
|
/**
|
||||||
|
* prism.js default theme for JavaScript, CSS and HTML
|
||||||
|
* Based on dabblet (http://dabblet.com)
|
||||||
|
* @author Lea Verou
|
||||||
|
*/
|
||||||
|
|
||||||
|
code[class*="language-"],
|
||||||
|
pre[class*="language-"] {
|
||||||
|
color: black;
|
||||||
|
background: none;
|
||||||
|
text-shadow: 0 1px white;
|
||||||
|
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
|
||||||
|
font-size: 1em;
|
||||||
|
text-align: left;
|
||||||
|
white-space: pre;
|
||||||
|
word-spacing: normal;
|
||||||
|
word-break: normal;
|
||||||
|
word-wrap: normal;
|
||||||
|
line-height: 1.5;
|
||||||
|
|
||||||
|
-moz-tab-size: 4;
|
||||||
|
-o-tab-size: 4;
|
||||||
|
tab-size: 4;
|
||||||
|
|
||||||
|
-webkit-hyphens: none;
|
||||||
|
-moz-hyphens: none;
|
||||||
|
-ms-hyphens: none;
|
||||||
|
hyphens: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection,
|
||||||
|
code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection {
|
||||||
|
text-shadow: none;
|
||||||
|
background: #b3d4fc;
|
||||||
|
}
|
||||||
|
|
||||||
|
pre[class*="language-"]::selection, pre[class*="language-"] ::selection,
|
||||||
|
code[class*="language-"]::selection, code[class*="language-"] ::selection {
|
||||||
|
text-shadow: none;
|
||||||
|
background: #b3d4fc;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media print {
|
||||||
|
code[class*="language-"],
|
||||||
|
pre[class*="language-"] {
|
||||||
|
text-shadow: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Code blocks */
|
||||||
|
pre[class*="language-"] {
|
||||||
|
padding: 1em;
|
||||||
|
margin: .5em 0;
|
||||||
|
overflow: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
:not(pre) > code[class*="language-"],
|
||||||
|
pre[class*="language-"] {
|
||||||
|
background: #f5f2f0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Inline code */
|
||||||
|
:not(pre) > code[class*="language-"] {
|
||||||
|
padding: .1em;
|
||||||
|
border-radius: .3em;
|
||||||
|
white-space: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.comment,
|
||||||
|
.token.prolog,
|
||||||
|
.token.doctype,
|
||||||
|
.token.cdata {
|
||||||
|
color: slategray;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.punctuation {
|
||||||
|
color: #999;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.namespace {
|
||||||
|
opacity: .7;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.property,
|
||||||
|
.token.tag,
|
||||||
|
.token.boolean,
|
||||||
|
.token.number,
|
||||||
|
.token.constant,
|
||||||
|
.token.symbol,
|
||||||
|
.token.deleted {
|
||||||
|
color: #905;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.selector,
|
||||||
|
.token.attr-name,
|
||||||
|
.token.string,
|
||||||
|
.token.char,
|
||||||
|
.token.builtin,
|
||||||
|
.token.inserted {
|
||||||
|
color: #690;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.operator,
|
||||||
|
.token.entity,
|
||||||
|
.token.url,
|
||||||
|
.language-css .token.string,
|
||||||
|
.style .token.string {
|
||||||
|
color: #9a6e3a;
|
||||||
|
/* This background color was intended by the author of this theme. */
|
||||||
|
background: hsla(0, 0%, 100%, .5);
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.atrule,
|
||||||
|
.token.attr-value,
|
||||||
|
.token.keyword {
|
||||||
|
color: #07a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.function,
|
||||||
|
.token.class-name {
|
||||||
|
color: #DD4A68;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.regex,
|
||||||
|
.token.important,
|
||||||
|
.token.variable {
|
||||||
|
color: #e90;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.important,
|
||||||
|
.token.bold {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.token.italic {
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
|
.token.entity {
|
||||||
|
cursor: help;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar > .toolbar {
|
||||||
|
position: absolute;
|
||||||
|
top: .3em;
|
||||||
|
right: .2em;
|
||||||
|
transition: opacity 0.3s ease-in-out;
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar:hover > .toolbar {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Separate line b/c rules are thrown out if selector is invalid.
|
||||||
|
IE11 and old Edge versions don't support :focus-within. */
|
||||||
|
div.code-toolbar:focus-within > .toolbar {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar > .toolbar .toolbar-item {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar > .toolbar a {
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar > .toolbar button {
|
||||||
|
background: none;
|
||||||
|
border: 0;
|
||||||
|
color: inherit;
|
||||||
|
font: inherit;
|
||||||
|
line-height: normal;
|
||||||
|
overflow: visible;
|
||||||
|
padding: 0;
|
||||||
|
-webkit-user-select: none; /* for button */
|
||||||
|
-moz-user-select: none;
|
||||||
|
-ms-user-select: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar > .toolbar a,
|
||||||
|
div.code-toolbar > .toolbar button,
|
||||||
|
div.code-toolbar > .toolbar span {
|
||||||
|
color: #bbb;
|
||||||
|
font-size: .8em;
|
||||||
|
padding: 0 .5em;
|
||||||
|
background: #f5f2f0;
|
||||||
|
background: rgba(224, 224, 224, 0.2);
|
||||||
|
box-shadow: 0 2px 0 0 rgba(0,0,0,0.2);
|
||||||
|
border-radius: .5em;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.code-toolbar > .toolbar a:hover,
|
||||||
|
div.code-toolbar > .toolbar a:focus,
|
||||||
|
div.code-toolbar > .toolbar button:hover,
|
||||||
|
div.code-toolbar > .toolbar button:focus,
|
||||||
|
div.code-toolbar > .toolbar span:hover,
|
||||||
|
div.code-toolbar > .toolbar span:focus {
|
||||||
|
color: inherit;
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
2
css/shortcodes.css
Normal file
|
|
@ -0,0 +1,2 @@
|
||||||
|
@import "shortcodes/tabbed-pane.css";
|
||||||
|
@import "shortcodes/cards-pane.css";
|
||||||
21
css/shortcodes/cards-pane.css
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
.card-deck {
|
||||||
|
max-width: 83%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card {
|
||||||
|
max-width: 80%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-body.code {
|
||||||
|
background-color: #f8f9fa;
|
||||||
|
padding: 0 0 0 1ex;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-body pre {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0 1rem 1rem 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card .highlight {
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
18
css/shortcodes/tabbed-pane.css
Normal file
|
|
@ -0,0 +1,18 @@
|
||||||
|
.td-content .highlight {
|
||||||
|
margin: 0rem 0 2rem 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-content .highlight {
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-content {
|
||||||
|
margin: 0rem;
|
||||||
|
max-width: 80%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-content pre {
|
||||||
|
border-left: 1px solid rgba(0, 0, 0, 0.125);
|
||||||
|
border-right: 1px solid rgba(0, 0, 0, 0.125);
|
||||||
|
border-bottom: 1px solid rgba(0, 0, 0, 0.125);
|
||||||
|
}
|
||||||
4
css/swagger-ui.css
Normal file
63
docs/bestpractices/api-page/index.html
Normal file
30
docs/bestpractices/begin-as-an-afterword/index.html
Normal file
46
docs/bestpractices/begin-end/index.html
Normal file
32
docs/bestpractices/binary-operator-line-start/index.html
Normal file
82
docs/bestpractices/blank-lines/index.html
Normal file
35
docs/bestpractices/case-actions/index.html
Normal file
27
docs/bestpractices/comments-spacing/index.html
Normal file
42
docs/bestpractices/customtelemetry/index.html
Normal file
29
docs/bestpractices/deleteall/index.html
Normal file
39
docs/bestpractices/end-else-pair/index.html
Normal file
92
docs/bestpractices/if-not-find-then-exit/index.html
Normal file
19
docs/bestpractices/index.html
Normal file
2375
docs/bestpractices/index.xml
Normal file
40
docs/bestpractices/istemporary-table-safeguard/index.html
Normal file
32
docs/bestpractices/keyboard-shortcuts/index.html
Normal file
28
docs/bestpractices/keyword-pairs-indentation/index.html
Normal file
35
docs/bestpractices/line-start-keywords/index.html
Normal file
28
docs/bestpractices/lonely-repeat/index.html
Normal file
30
docs/bestpractices/named-invocations/index.html
Normal file
32
docs/bestpractices/one-statement-per-line/index.html
Normal file
33
docs/bestpractices/separate-if-and-else/index.html
Normal file
50
docs/bestpractices/setloadfields/index/index.html
Normal file
29
docs/bestpractices/spacing-binary-operators/index.html
Normal file
142
docs/bestpractices/subscribercodeunits/index.html
Normal file
27
docs/bestpractices/suggested-abbreviations/index.html
Normal file
36
docs/bestpractices/unnecessary-else/index.html
Normal file
27
docs/bestpractices/unnecessary-truefalse/index.html
Normal file
36
docs/bestpractices/variable-naming/index.html
Normal file
30
docs/bestpractices/variables-declarations-order/index.html
Normal file
BIN
docs/contributing/forkandpr/ForkedRepro.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
docs/contributing/forkandpr/fork_button.jpg
Normal file
|
After Width: | Height: | Size: 6.1 KiB |
20
docs/contributing/forkandpr/index.html
Normal file
85
docs/contributing/formattingtips/index.html
Normal file
15
docs/contributing/index.html
Normal file
152
docs/contributing/index.xml
Normal file
|
|
@ -0,0 +1,152 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – Contributing</title><link>https://alguidelines.dev/docs/contributing/</link><description>Recent content in Contributing on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/docs/contributing/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: Formatting tips</title><link>https://alguidelines.dev/docs/contributing/formattingtips/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/formattingtips/</guid><description>
|
||||||
|
<h1 id="tips-and-tricks-in-terms-of-working-with-markdown-and-hugo">Tips and tricks in terms of working with MarkDown and Hugo</h1>
|
||||||
|
<h2 id="markdown-cheat-sheet">Markdown Cheat Sheet</h2>
|
||||||
|
<p>Here you can find a rather interesting Cheat Sheet regarding markdown: <a href="https://www.markdownguide.org/cheat-sheet">https://www.markdownguide.org/cheat-sheet</a></p>
|
||||||
|
<h2 id="code-fences--syntax-highlighting">Code Fences / Syntax highlighting</h2>
|
||||||
|
<p>The syntax to use codefences is with backticks. If you provide the language after the first block of backticks, github will automatically put that in decent syntax highlighting. So, A simple code fence with AL code, can simply be done by:</p>
|
||||||
|
<pre tabindex="0"><code>```AL
|
||||||
|
procedure ALGuidelinesRock()
|
||||||
|
var
|
||||||
|
Customer: Record Customer;
|
||||||
|
begin
|
||||||
|
Customer.Get(&#39;10000&#39;);
|
||||||
|
Customer.Name := &#39;waldo&#39;;
|
||||||
|
Customer.Modify(true);
|
||||||
|
end;
|
||||||
|
```
|
||||||
|
</code></pre><p>Results in:</p>
|
||||||
|
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-AL" data-lang="AL"><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">procedure</span><span style="color:#f8f8f8;text-decoration:underline"> </span>ALGuidelinesRock<span style="color:#ce5c00;font-weight:bold">()
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#ce5c00;font-weight:bold"> </span><span style="color:#204a87;font-weight:bold">var</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>Customer<span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">Record</span><span style="color:#f8f8f8;text-decoration:underline"> </span>Customer<span style="color:#000;font-weight:bold">;</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">begin</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>Customer<span style="color:#ce5c00;font-weight:bold">.</span>Get<span style="color:#ce5c00;font-weight:bold">(</span><span style="color:#4e9a06">&#39;10000&#39;</span><span style="color:#ce5c00;font-weight:bold">)</span><span style="color:#000;font-weight:bold">;</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>Customer<span style="color:#ce5c00;font-weight:bold">.</span>Name<span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#ce5c00;font-weight:bold">:=</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#4e9a06">&#39;waldo&#39;</span><span style="color:#000;font-weight:bold">;</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>Customer<span style="color:#ce5c00;font-weight:bold">.</span><span style="color:#204a87;font-weight:bold">Modify</span><span style="color:#ce5c00;font-weight:bold">(</span>true<span style="color:#ce5c00;font-weight:bold">)</span><span style="color:#000;font-weight:bold">;</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">end</span><span style="color:#000;font-weight:bold">;</span><span style="color:#f8f8f8;text-decoration:underline">
|
||||||
|
</span></span></span></code></pre></div><h2 id="diagrams-with-mermaid">Diagrams with Mermaid</h2>
|
||||||
|
<p>When providing a documentation, diagrams come in handy. <a href="https://mermaid-js.github.io/mermaid/#/">Mermaid</a> lets you create diagrams and visualizations using text and code.</p>
|
||||||
|
<p>For example the following markdown section:</p>
|
||||||
|
<pre tabindex="0"><code>```mermaid
|
||||||
|
classDiagram
|
||||||
|
Animal &lt;|-- Duck
|
||||||
|
Animal &lt;|-- Fish
|
||||||
|
Animal &lt;|-- Zebra
|
||||||
|
Animal : +int age
|
||||||
|
Animal : +String gender
|
||||||
|
Animal: +isMammal()
|
||||||
|
Animal: +mate()
|
||||||
|
class Duck{
|
||||||
|
+String beakColor
|
||||||
|
+swim()
|
||||||
|
+quack()
|
||||||
|
}
|
||||||
|
class Fish{
|
||||||
|
-int sizeInFeet
|
||||||
|
-canEat()
|
||||||
|
}
|
||||||
|
class Zebra{
|
||||||
|
+bool is_wild
|
||||||
|
+run()
|
||||||
|
}
|
||||||
|
```
|
||||||
|
</code></pre><p>Results in:</p>
|
||||||
|
<pre tabindex="0"><code class="language-mermaid" data-lang="mermaid">classDiagram
|
||||||
|
Animal &lt;|-- Duck
|
||||||
|
Animal &lt;|-- Fish
|
||||||
|
Animal &lt;|-- Zebra
|
||||||
|
Animal : +int age
|
||||||
|
Animal : +String gender
|
||||||
|
Animal: +isMammal()
|
||||||
|
Animal: +mate()
|
||||||
|
class Duck{
|
||||||
|
+String beakColor
|
||||||
|
+swim()
|
||||||
|
+quack()
|
||||||
|
}
|
||||||
|
class Fish{
|
||||||
|
-int sizeInFeet
|
||||||
|
-canEat()
|
||||||
|
}
|
||||||
|
class Zebra{
|
||||||
|
+bool is_wild
|
||||||
|
+run()
|
||||||
|
}
|
||||||
|
</code></pre><p>Can&rsquo;t wait to get started? Use the Mermaid <a href="https://mermaid.live/edit">Live Editor</a>.</p>
|
||||||
|
<h2 id="hugo-shortcodes">Hugo Shortcodes</h2>
|
||||||
|
<p>Since we&rsquo;re using &ldquo;Hugo&rdquo;, we can use it&rsquo;s shortcode. Here is a reference: <a href="https://gohugo.io/content-management/shortcodes/">https://gohugo.io/content-management/shortcodes/</a></p>
|
||||||
|
<p>It basically means we are able to use easy notations to do cool things. Let&rsquo;s point out some useful shortcodes:</p>
|
||||||
|
<h3 id="twitter">Twitter</h3>
|
||||||
|
<pre tabindex="0"><code>{{&lt; tweet user=&#34;waldo1001&#34; id=&#34;1458787011024805892&#34; &gt;}}
|
||||||
|
</code></pre><p>makes:
|
||||||
|
<blockquote class="twitter-tweet"><p lang="en" dir="ltr">&quot;Code is Poetry!&quot;<a href="https://twitter.com/hashtag/msdyn365bc?src=hash&amp;ref_src=twsrc%5Etfw">#msdyn365bc</a></p>&mdash; waldo (@waldo1001) <a href="https://twitter.com/waldo1001/status/1458787011024805892?ref_src=twsrc%5Etfw">November 11, 2021</a></blockquote>
|
||||||
|
<script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script>
|
||||||
|
</p>
|
||||||
|
<h3 id="youtube">YouTube</h3>
|
||||||
|
<pre tabindex="0"><code>{{&lt; youtube QVOMCYitLEc &gt;}}
|
||||||
|
</code></pre><p>makes:
|
||||||
|
<div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;">
|
||||||
|
<iframe src="https://www.youtube.com/embed/QVOMCYitLEc" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe>
|
||||||
|
</div>
|
||||||
|
</p>
|
||||||
|
<h3 id="figure">Figure</h3>
|
||||||
|
<pre tabindex="0"><code>{{&lt; figure src=&#34;http://www.waldo.be/wp-content/uploads/2021/11/business-central-logo.png&#34; title=&#34;Business Central&#34; &gt;}}
|
||||||
|
</code></pre><p>makes:
|
||||||
|
<figure>
|
||||||
|
<img src="http://www.waldo.be/wp-content/uploads/2021/11/business-central-logo.png"/> <figcaption>
|
||||||
|
<h4>Business Central</h4>
|
||||||
|
</figcaption>
|
||||||
|
</figure>
|
||||||
|
</p></description></item><item><title>Docs: Guide to Fork & PR</title><link>https://alguidelines.dev/docs/contributing/forkandpr/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/forkandpr/</guid><description>
|
||||||
|
<h2 id="abstract">Abstract</h2>
|
||||||
|
<p>AL Guidelines is a community project, and as such YOU are encouraged to submit corrections and new ideas. In order to get your content included, you must submit a pull request to the GitHub Repository (Located here: <a href="https://github.com/microsoft/alguidelines">https://github.com/microsoft/alguidelines</a>). All Pull Requests are subject to approval by a minimum of three admins.</p>
|
||||||
|
<p>If You are toying with an idea, but You aren&rsquo;t ready to create a document just yet, you are encouraged to create a project discussion thread here: <a href="https://github.com/microsoft/alguidelines/discussions">https://github.com/microsoft/alguidelines/discussions</a></p>
|
||||||
|
<div class="alert alert-warning" role="alert">
|
||||||
|
<h4 class="alert-heading">Warning</h4>
|
||||||
|
<p>This is a warning.
|
||||||
|
If You haven&rsquo;t worked in collaboration with &ldquo;external&rdquo; GitHub repositories before, please familiarize yourself with that process by visiting:</p>
|
||||||
|
<p><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests</a></p>
|
||||||
|
</div>
|
||||||
|
<h2 id="steps">Steps</h2>
|
||||||
|
<p>Now that You have decided that You are ready to contribute, these are the steps to take.
|
||||||
|
<div class="alert alert-info" role="alert">
|
||||||
|
<h4 class="alert-heading">Note</h4>
|
||||||
|
<p>You can read more about this process here:</p>
|
||||||
|
<p><a href="https://docs.github.com/en/get-started/quickstart/contributing-to-projects">https://docs.github.com/en/get-started/quickstart/contributing-to-projects</a></p>
|
||||||
|
</div>
|
||||||
|
</p>
|
||||||
|
<h3 id="step-1-fork">Step 1: Fork</h3>
|
||||||
|
<p>In order to work on the repository, You must <a href="https://docs.github.com/en/get-started/quickstart/fork-a-repo">Fork</a> the repository.</p>
|
||||||
|
<p>By forking the repository, You essentially create a copy into Your own account.</p>
|
||||||
|
<p>Start by going to the GitHub Repository (<a href="https://github.com/microsoft/alguidelines">https://github.com/microsoft/alguidelines</a>), and press the Fork <img src="./fork_button.jpg" alt="Fork Button" title="Fork"></p>
|
||||||
|
<p>Once You have successfully forked the repository, go to your own GitHub repository : <img src="./ForkedRepro.png" alt="Forked Repository Representation" title="Forked repository"></p>
|
||||||
|
<p>You are now able to clone your own repository to your local pc and start editing using your favorite editor. <a href="https://code.visualstudio.com/">Visual Studio Code</a> is perfectly fine for this task.</p>
|
||||||
|
<div class="alert alert-info" role="alert">
|
||||||
|
<h4 class="alert-heading">Note</h4>
|
||||||
|
<p>You can read more about forking here:</p>
|
||||||
|
<p><a href="https://docs.github.com/en/get-started/quickstart/fork-a-repo">https://docs.github.com/en/get-started/quickstart/fork-a-repo</a></p>
|
||||||
|
</div>
|
||||||
|
<h3 id="step-2-branch">Step 2: Branch</h3>
|
||||||
|
<p>While not necessarily a must, it is always good practice to create a branch off of your forked repository. That will allow you to work on multiple contributions at the same time and won&rsquo;t have to wait for pull requests to be approved before you can continue on your next contribution.</p>
|
||||||
|
<div class="alert alert-info" role="alert">
|
||||||
|
<h4 class="alert-heading">Note</h4>
|
||||||
|
<p>You can read more about Branches here:</p>
|
||||||
|
<p><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches</a></p>
|
||||||
|
</div>
|
||||||
|
<h3 id="step-3-pull-request">Step 3: Pull Request</h3>
|
||||||
|
<p>Once you are happy with your contribution, it&rsquo;s time to create a pull request to propose changes into the main project! This is the final step in producing a fork of someone else&rsquo;s project, and arguably the most important. If you&rsquo;ve made a change that you feel would benefit the community as a whole, you should definitely consider contributing back.</p>
|
||||||
|
<p>To do so, head on over to the repository on GitHub where your project lives. For this example, it would be at <code>https://www.github.com/&lt;your_username&gt;/alguidelines</code>. You&rsquo;ll see a banner indicating that your branch is one commit ahead of microsoft:main. Click <strong>Contribute</strong> and then <strong>Open a pull request.</strong></p>
|
||||||
|
<p>GitHub will bring you to a page that shows the differences between your fork and the microsoft/alguidelines repository. Click <strong>Create pull request.</strong></p>
|
||||||
|
<p>GitHub will bring you to a page where you can enter a title and a description of your changes. <em>It&rsquo;s important to provide as much useful information and a rationale for why you&rsquo;re making this pull request in the first place.</em> The project owners needs to be able to determine whether your change is as useful to everyone as you think it is. Finally, click <strong>Create pull request.</strong></p></description></item><item><title>Docs: Understanding the Approval Process</title><link>https://alguidelines.dev/docs/contributing/theapprovalprocess/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/theapprovalprocess/</guid><description>
|
||||||
|
<p>(coming soon)</p></description></item><item><title>Docs: Install Hugo</title><link>https://alguidelines.dev/docs/contributing/installhugo/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/installhugo/</guid><description>
|
||||||
|
<p>There are multiple ways to install Hugo for you to properly preview your contributions. Please select the scenario that matches your setup.</p>
|
||||||
|
<p>For the official install guide, you can visit <a href="https://gohugo.io/getting-started/installing/">https://gohugo.io/getting-started/installing/</a></p>
|
||||||
|
<div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;">
|
||||||
|
<iframe src="https://www.youtube.com/embed/G7umPCU-8xc" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" allowfullscreen title="YouTube Video"></iframe>
|
||||||
|
</div></description></item><item><title>Docs: Templates</title><link>https://alguidelines.dev/docs/contributing/templates/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/templates/</guid><description>
|
||||||
|
<p>We have created some template-files that you can simply copy and use. Look at them as &ldquo;Patterns for describing patterns&rdquo;</p>
|
||||||
|
<p>We currently offer the following templates:</p>
|
||||||
|
<ul>
|
||||||
|
<li>for <a href="https://alguidelines.dev/contributing/templates/patterns/">Patterns</a> (<a href="https://raw.githubusercontent.com/microsoft/alguidelines/main/content/docs/Contributing/Templates/Patterns/index.md">raw</a>)</li>
|
||||||
|
<li>for <a href="https://alguidelines.dev/contributing/templates/bestpractice/">Best Practice</a> (<a href="https://raw.githubusercontent.com/microsoft/alguidelines/main/content/docs/Contributing/Templates/BestPractice/index.md">raw</a>)</li>
|
||||||
|
</ul>
|
||||||
|
<p>opening the &ldquo;raw&rdquo; link, will allow for the best copy/paste result.</p></description></item></channel></rss>
|
||||||
16
docs/contributing/installhugo/index.html
Normal file
69
docs/contributing/installhugo/index.xml
Normal file
|
|
@ -0,0 +1,69 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – Install Hugo</title><link>https://alguidelines.dev/docs/contributing/installhugo/</link><description>Recent content in Install Hugo on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/docs/contributing/installhugo/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: Devcontainer with VS Code</title><link>https://alguidelines.dev/docs/contributing/installhugo/theshortcut/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/installhugo/theshortcut/</guid><description>
|
||||||
|
<h2 id="use-a-local-devcontainer">Use a local devcontainer</h2>
|
||||||
|
<p>If you don&rsquo;t want any local setup (apart from Docker Desktop), but still run your own Hugo instance, you can make use of the preconfigured devcontainer. If you want to learn more about the concept, visit <a href="https://code.visualstudio.com/docs/remote/containers">https://code.visualstudio.com/docs/remote/containers</a>. To use it, you need to take the following steps:</p>
|
||||||
|
<ol>
|
||||||
|
<li>Start <a href="https://www.docker.com/products/docker-desktop">Docker Desktop</a> and <a href="https://docs.docker.com/desktop/windows/#switch-between-windows-and-linux-containers">switch to Linux containers</a> by right-clicking on the Docker logo in the system tray and selecting &ldquo;Switch to Linux containers&hellip;&rdquo;. If you only see &ldquo;Switch to Windows containers&hellip;&rdquo;, then you are already switched to Linux containers. If anything goes wrong, check if you are on the latest version of Docker Desktop and have <a href="https://docs.docker.com/desktop/windows/wsl/#install">the WSL2 integration enabled</a>. If you have all that in place and it still doesn&rsquo;t work, check the extended installation documentation <a href="https://code.visualstudio.com/docs/remote/containers#_installation">here</a>
|
||||||
|
<div class="alert alert-info" role="alert">
|
||||||
|
<h4 class="alert-heading">Consequences of switching</h4>
|
||||||
|
When switching to Linux, you will probably see a warning that tells you that you &ldquo;will not be able to manage the Windows containers until you switch back to Windows containers&rdquo;. That means that the Docker Desktop management GUI can only show either the Windows containers or the Linux containers and if you switch to Linux, you consequently won&rsquo;t see the Windows containers until you switch back. But the Windows containers will continue to run, you won&rsquo;t loose data and you can keep using them e.g. for Business Central development, you just can&rsquo;t manage them through the Docker Desktop GUI
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
<li>Install the <a href="https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.vscode-remote-extensionpack">Remote development extension pack</a> in Visual Studio Code</li>
|
||||||
|
<li>Run the action &ldquo;Remote containers: Clone Repository in Container Volume&rdquo; and select the fork you created. If you haven&rsquo;t done that before, go through the <a href="https://alguidelines.dev/docs/contributing/forkandpr/#step-1-fork">docs</a>.</li>
|
||||||
|
<li>Wait for a bit. When you do this for the first time, it can take a couple of minutes. Next time it will be faster&hellip;</li>
|
||||||
|
<li>After a while, you will have VS Code with the cloned repository and the terminal should show something like &ldquo;Done. Press any key to close the terminal.&rdquo;</li>
|
||||||
|
<li>Run the action &ldquo;Tasks: Run task&rdquo; and select &ldquo;Start local Hugo Server&rdquo; from the list. If you don&rsquo;t see that entry, you might have to reload your VS Code window and try again</li>
|
||||||
|
<li>After Hugo has generated the site, you will get a notification that offers you to &ldquo;Open a browser&rdquo;. Click on that and you will see your local instance of the AL guidelines! Again, on the first try it will be a bit slow and sluggish, but the second one should be fast.</li>
|
||||||
|
<li>Now you can make changes and just save them. If you open the terminal, you will see a message that tells you that a change was detected and the site was rebuilt. After that, the change should automatically appear in your browser</li>
|
||||||
|
</ol>
|
||||||
|
<p>Here is a walkthrough of the full process:</p>
|
||||||
|
<video width=100% controls>
|
||||||
|
<source src="alguidelines walkthrough.mp4" type="video/mp4">
|
||||||
|
Your browser does not support the video tag.
|
||||||
|
</video>
|
||||||
|
<h2 id="use-github-codespaces">Use GitHub Codespaces</h2>
|
||||||
|
<p>What is also great about this, is that you can also use <a href="https://github.com/features/codespaces">GitHub Codespaces</a> with that setup. In that case, steps 1-5 become two clicks&hellip; Here is another full walkthrough:</p>
|
||||||
|
<video width=100% controls>
|
||||||
|
<source src="alguidelines codespace.mp4" type="video/mp4">
|
||||||
|
Your browser does not support the video tag.
|
||||||
|
</video></description></item><item><title>Docs: Manually on Windows 11</title><link>https://alguidelines.dev/docs/contributing/installhugo/manuallyonwindows11/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/installhugo/manuallyonwindows11/</guid><description>
|
||||||
|
<p>This guide will walk You thrugh installing Hugo on a Windows 11 PC. For the official install guide, You can wisit <a href="https://gohugo.io/getting-started/installing/">https://gohugo.io/getting-started/installing/</a>.</p>
|
||||||
|
<h2 id="download-binaries">Download Binaries</h2>
|
||||||
|
<p>The path of least resistance is to just download the .zip file from the official Hugo GitHub Repository <a href="https://github.com/gohugoio/hugo/releases">here</a>.</p>
|
||||||
|
<p>The theme that are used, needs the extended version of Hugo, so make sure to download the <strong>extended</strong> version by ensuring the file name starts with <code>hugo_extended...</code></p>
|
||||||
|
<div class="alert alert-info" role="alert">
|
||||||
|
<h4 class="alert-heading">info</h4>
|
||||||
|
<p>For the purpose of this install guide, we are assuming You will want to follow the &ldquo;standard&rdquo; used by Hugo for installing. We will be creating a <code>Hugo</code> folder in the root of <code>C:\</code>. That folder will have a <code>Bin</code> folder for the binaries, and a <code>Sites</code> folder for each website You are building.</p>
|
||||||
|
<p>Once You are done, You should have a folder structure that looks like this:</p>
|
||||||
|
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-text" data-lang="text"><span style="display:flex;"><span>C:\Hugo
|
||||||
|
</span></span><span style="display:flex;"><span>├── Bin # Binaries
|
||||||
|
</span></span><span style="display:flex;"><span>└┬─ Sites # Hugo Site Repositories
|
||||||
|
</span></span><span style="display:flex;"><span> └── alguidelines # Hugo Source for alguidelines.dev
|
||||||
|
</span></span></code></pre></div>
|
||||||
|
</div>
|
||||||
|
<p><img src="SelectExtended.png" alt="image"></p>
|
||||||
|
<p>After downloading the .zip file, extract the zip-file to <code>c:\Hugo\Bin</code></p>
|
||||||
|
<p><img src="Extract.png" alt="image"></p>
|
||||||
|
<p><img src="ExtractToBin.png" alt="image"></p>
|
||||||
|
<h2 id="add-hugo-to-path">Add Hugo to Path</h2>
|
||||||
|
<p>After copying the binaries to Your PC, You will need to add Hugo binaries to the <code>%PATH%</code> system environment variables.</p>
|
||||||
|
<p>To do that, search for <code>environment</code></p>
|
||||||
|
<p><img src="SearchForEnv.png" alt="image"></p>
|
||||||
|
<p>once you see the <code>Edit the system environment variables</code>, open it and select <code>Environment Variables</code></p>
|
||||||
|
<p><img src="SystemProperties.png" alt="image"></p>
|
||||||
|
<p>Once the Environment Variables screen is open, highlight the <code>Path</code> lines and press the <code>Edit...</code> button</p>
|
||||||
|
<p><img src="EnvironmentVariables.png" alt="image"></p>
|
||||||
|
<p>Now press <code>New</code> and add the <code>C:\Hugo\Bin</code> to the path. Press <code>OK</code> and <code>OK</code> to save the new <code>Path</code></p>
|
||||||
|
<p><img src="EnvironmentVariablesPath.png" alt="image"></p>
|
||||||
|
<p>Once complete. You should now be able to preview the Hugo site on <a href="http://localhost:1313">http://localhost:1313</a> by opening a command promt, and open the <code>C:\Hugo\Sites\alguidelines</code> folder and execute <code>Hugo Serve</code></p>
|
||||||
|
<p><img src="HugoServe.png" alt="image"></p></description></item><item><title>Docs: Powershell on Windows 11</title><link>https://alguidelines.dev/docs/contributing/installhugo/usingpowershellonwindows11/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/installhugo/usingpowershellonwindows11/</guid><description>
|
||||||
|
<p>It is possible to use a powershell script and Chocolatey to install and other dependencies. Execute the following script:</p>
|
||||||
|
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-powershell" data-lang="powershell"><span style="display:flex;"><span><span style="color:#204a87">Set-ExecutionPolicy</span> <span style="color:#000">Bypass</span> <span style="color:#000">-Scope</span> <span style="color:#204a87;font-weight:bold">Process</span> <span style="color:#000">-Force</span>
|
||||||
|
</span></span><span style="display:flex;"><span><span style="color:#000;font-weight:bold">[</span><span style="color:#000">System.Net.ServicePointManager</span><span style="color:#000;font-weight:bold">]::</span><span style="color:#000">SecurityProtocol</span> <span style="color:#000;font-weight:bold">=</span> <span style="color:#000;font-weight:bold">[</span><span style="color:#000">System.Net.ServicePointManager</span><span style="color:#000;font-weight:bold">]::</span><span style="color:#000">SecurityProtocol</span> <span style="color:#ce5c00;font-weight:bold">-bor</span> <span style="color:#0000cf;font-weight:bold">3072</span>
|
||||||
|
</span></span><span style="display:flex;"><span><span style="color:#204a87">Invoke-Expression</span> <span style="color:#000;font-weight:bold">((</span><span style="color:#204a87">New-Object</span> <span style="color:#000">System</span><span style="color:#000;font-weight:bold">.</span><span style="color:#000">Net</span><span style="color:#000;font-weight:bold">.</span><span style="color:#000">WebClient</span><span style="color:#000;font-weight:bold">).</span><span style="color:#000">DownloadString</span><span style="color:#000;font-weight:bold">(</span><span style="color:#4e9a06">&#39;https://community.chocolatey.org/install.ps1&#39;</span><span style="color:#000;font-weight:bold">))</span>
|
||||||
|
</span></span><span style="display:flex;"><span><span style="color:#000">choco</span> <span style="color:#000">install</span> <span style="color:#000">-y</span> <span style="color:#000">nodejs</span>
|
||||||
|
</span></span><span style="display:flex;"><span><span style="color:#000">choco</span> <span style="color:#000">install</span> <span style="color:#000">-y</span> <span style="color:#204a87">hugo-extended</span>
|
||||||
|
</span></span></code></pre></div><p>Once complete, in root of of the repository execute the following commands</p>
|
||||||
|
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-powershell" data-lang="powershell"><span style="display:flex;"><span><span style="color:#000">git</span> <span style="color:#000">submodule</span> <span style="color:#000">update</span> <span style="color:#000;font-weight:bold">-</span><span style="color:#000">-init</span> <span style="color:#000;font-weight:bold">-</span><span style="color:#000">-recursive</span> <span style="color:#000;font-weight:bold">-</span><span style="color:#000">-depth</span> <span style="color:#0000cf;font-weight:bold">1</span>
|
||||||
|
</span></span><span style="display:flex;"><span><span style="color:#000">npm</span> <span style="color:#000">install</span>
|
||||||
|
</span></span></code></pre></div></description></item></channel></rss>
|
||||||
|
After Width: | Height: | Size: 44 KiB |
|
After Width: | Height: | Size: 22 KiB |
BIN
docs/contributing/installhugo/manuallyonwindows11/Extract.png
Normal file
|
After Width: | Height: | Size: 54 KiB |
|
After Width: | Height: | Size: 10 KiB |
BIN
docs/contributing/installhugo/manuallyonwindows11/HugoServe.png
Normal file
|
After Width: | Height: | Size: 96 KiB |
|
After Width: | Height: | Size: 128 KiB |
|
After Width: | Height: | Size: 6 KiB |
|
After Width: | Height: | Size: 18 KiB |
25
docs/contributing/installhugo/manuallyonwindows11/index.html
Normal file
21
docs/contributing/installhugo/theshortcut/index.html
Normal file
28
docs/contributing/templates/bestpractice/index.html
Normal file
16
docs/contributing/templates/index.html
Normal file
41
docs/contributing/templates/index.xml
Normal file
|
|
@ -0,0 +1,41 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – Templates</title><link>https://alguidelines.dev/docs/contributing/templates/</link><description>Recent content in Templates on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/docs/contributing/templates/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: Title Here</title><link>https://alguidelines.dev/docs/contributing/templates/bestpractice/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/templates/bestpractice/</guid><description>
|
||||||
|
<!-- This is a guideline, some parts are optional (if there's no content, remove the whole paragraph). -->
|
||||||
|
<!-- The "Readability" and "Performance" tags are often used. You can, however, add multiple tags, but please do not change the Category -->
|
||||||
|
<p><em>Created by <!-- John Smith --><!--, Cronus International.--> Described by <!-- Jane Doe--><!--, Contoso, LLC--></em></p>
|
||||||
|
<h2 id="description">Description</h2>
|
||||||
|
<p>In depth description on what this Pattern is all about</p>
|
||||||
|
<ul>
|
||||||
|
<li>basic components</li>
|
||||||
|
<li>how the interact</li>
|
||||||
|
<li>steps to implement</li>
|
||||||
|
<li>considerations to take</li>
|
||||||
|
</ul>
|
||||||
|
<h2 id="bad-code">Bad code</h2>
|
||||||
|
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-al" data-lang="al"><span style="display:flex;"><span>PutCodeblocksHere<span style="color:#ce5c00;font-weight:bold">()
|
||||||
|
</span></span></span></code></pre></div><h2 id="good-code">Good code</h2>
|
||||||
|
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-al" data-lang="al"><span style="display:flex;"><span>PutCodeblocksHere<span style="color:#ce5c00;font-weight:bold">()
|
||||||
|
</span></span></span></code></pre></div></description></item><item><title>Docs: Title Here</title><link>https://alguidelines.dev/docs/contributing/templates/patterns/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/contributing/templates/patterns/</guid><description>
|
||||||
|
<!-- This is a guideline, some parts are optional (if there's no content, remove the whole paragraph). -->
|
||||||
|
<p><em>Created by <!-- John Smith --><!--, Cronus International.--> Described by <!-- Jane Doe--><!--, Contoso, LLC--></em></p>
|
||||||
|
<h2 id="abstract">Abstract</h2>
|
||||||
|
<p>Short, descriptive and easy to remember description of this pattern.</p>
|
||||||
|
<h2 id="context">Context</h2>
|
||||||
|
<p>Sets the stage where the pattern takes place. 1-2 sentences.</p>
|
||||||
|
<h2 id="problem">Problem</h2>
|
||||||
|
<p>What happens before this pattern is used? How can it go wrong? 1-5 lines.</p>
|
||||||
|
<h2 id="description">Description</h2>
|
||||||
|
<p>In depth description on what this Pattern is all about</p>
|
||||||
|
<ul>
|
||||||
|
<li>basic components</li>
|
||||||
|
<li>how the interact</li>
|
||||||
|
<li>steps to implement</li>
|
||||||
|
<li>considerations to take</li>
|
||||||
|
</ul>
|
||||||
|
<h2 id="usage">Usage</h2>
|
||||||
|
<p>If applicable: where is it used in an app. You can refer to any app, BaseApp, or a (public) ISV app.</p>
|
||||||
|
<h2 id="benefits">Benefits</h2>
|
||||||
|
<p>1-2 sentences: what did you just solve</p>
|
||||||
|
<h2 id="when-not-to-use">When not to use</h2>
|
||||||
|
<p>Usually, there are occasions where NOT to implement the pattern. List the disadvantages of this pattern here.</p>
|
||||||
|
<h2 id="list-of-references">List of references</h2>
|
||||||
|
<p>Youtube-link? BaseApp? Tweet? &hellip;</p></description></item></channel></rss>
|
||||||
32
docs/contributing/templates/patterns/index.html
Normal file
16
docs/contributing/theapprovalprocess/index.html
Normal file
20
docs/index.html
Normal file
3072
docs/index.xml
Normal file
15
docs/navpatterns/2-anti-patterns/index.html
Normal file
83
docs/navpatterns/2-anti-patterns/index.xml
Normal file
|
|
@ -0,0 +1,83 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – 2. Anti-Patterns</title><link>https://alguidelines.dev/docs/navpatterns/2-anti-patterns/</link><description>Recent content in 2. Anti-Patterns on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/docs/navpatterns/2-anti-patterns/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: Nav Upgrade</title><link>https://alguidelines.dev/docs/navpatterns/2-anti-patterns/nav-upgrade/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/2-anti-patterns/nav-upgrade/</guid><description>
|
||||||
|
<h2 id="anti-patterns-in-nav-upgrade">Anti-Patterns in NAV Upgrade</h2>
|
||||||
|
<p><em>By Carlos Raul Garcia and Bogdana Botez at Microsoft Development Center Copenhagen</em></p>
|
||||||
|
<p><a href="upgrade.png"><img src="upgrade.png" alt=" "></a></p>
|
||||||
|
<p><strong>Context</strong>: when NAV is upgraded, whether on-premises or in the cloud, developers have the chance to write upgrade code to move data across changing data structures. Writing good quality code will help successful upgrades.</p>
|
||||||
|
<h3 id="general-on-upgrade">General on upgrade</h3>
|
||||||
|
<p><strong>Problem:</strong> assuming that the upgrade table contains data.</p>
|
||||||
|
<p>If the table is empty, it means that either the upgrade has run, or there was no data in the original tenant; in both cases, the upgrade code should exit immediately.</p>
|
||||||
|
<p><strong>Solution:</strong> if using an upgrade table, always validate that the table contains data before doing anything.</p>
|
||||||
|
<h3 id="upgrade-code-can-it-be-rerun-safely">Upgrade code, can it be rerun safely?</h3>
|
||||||
|
<p><strong>Problem</strong>: if the upgrade code is not written in a way that makes it runnable twice (<a href="http://stackoverflow.com/questions/1077412/what-is-an-idempotent-operation#1077421">idempotent</a>), then several failures can happen, including something as critical as data corruption.</p>
|
||||||
|
<p>In on premise NAV installations, if something fails at upgrade, there is no way to run only the &ldquo;remaining&rdquo; tasks. You will need to run the whole upgrade again, and might end-up with data that you cannot trust.</p>
|
||||||
|
<p>What about the cloud? In Platform As A Service (PaaS), in some situations, the upgrade code needs to be run twice (for example, when moving tenants from a broken/frozen VM to a healthy one).</p>
|
||||||
|
<p><strong>Solution:</strong> Make sure each of your upgrade procedures only kicks in if it didn&rsquo;t run before.</p>
|
||||||
|
<p><strong>Examples</strong></p>
|
||||||
|
<p>The examples below have happened in real live NAV PaaS upgrade:</p>
|
||||||
|
<p><strong>Table data overwrite</strong></p>
|
||||||
|
<ul>
|
||||||
|
<li><strong>Problem</strong>: at upgrade, a new column has been added to a table and initialized with default values. In the meanwhile, during production, some of the default values are changed to production real life values. The second time the upgrade runs, those values will be overwritten with defaults, any personalization lost.</li>
|
||||||
|
<li><strong>Solution:</strong> before initializing with default values, check if non-default values exist.</li>
|
||||||
|
</ul>
|
||||||
|
<p><strong>Crash on math operations</strong></p>
|
||||||
|
<ul>
|
||||||
|
<li><strong>Problem:</strong> one tenant upgrade managed to divide by zero, by assuming a non-zero value.</li>
|
||||||
|
<li><strong>Solution:</strong> don&rsquo;t assume values can never be zero, always check before using them in divisions.</li>
|
||||||
|
</ul>
|
||||||
|
<p><strong>Use of external components</strong></p>
|
||||||
|
<ul>
|
||||||
|
<li><strong>Problem:</strong> a one-time registration through web services to an external service failed when attempting to register a second time.</li>
|
||||||
|
<li><strong>Solution:</strong> check if already registered, before attempting again.</li>
|
||||||
|
</ul>
|
||||||
|
<h3 id="parallelism">Parallelism</h3>
|
||||||
|
<p><strong>Problem</strong>: Upgrade procedures can be run in parallel, causing issues when different procedures attempt to modify the same table at the same time.</p>
|
||||||
|
<p>When modifications to the same table are being made from two or more different procedures, there is no guarantee on sequential run, or on a certain order they will be run in.</p>
|
||||||
|
<p><strong>Solution</strong>: if sequential or ordered execution is needed, make the affected upgrade procedures local and call them all, in the desired sequence, from a public upgrade procedure.</p>
|
||||||
|
<h3 id="access-to-cloud-machines">Access to cloud machines</h3>
|
||||||
|
<p><strong>Problem:</strong> dependencies on manual installation steps do not fit in the cloud.</p>
|
||||||
|
<p>If Dynamics NAV is installed on-premises, then any additional setup (like dependencies of external dlls, manual configuration steps etc.) can be done manually or semi-manually by the IT admin, at first setup and upgrade.</p>
|
||||||
|
<p>In the cloud, NAV partners don&rsquo;t have access to the machines &ndash; hence they cannot deploy and configure those external dependencies as they did in the old on-premises installations.</p>
|
||||||
|
<p><strong>Solution:</strong> Don&rsquo;t assume you will have access to PaaS or SaaS machines. Build your solution in such a way that it doesn&rsquo;t depend on executing manual configurations on the host machine.</p></description></item><item><title>Docs: Reusable Bugs</title><link>https://alguidelines.dev/docs/navpatterns/2-anti-patterns/reusable-bugs/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/2-anti-patterns/reusable-bugs/</guid><description>
|
||||||
|
<p><em>By Bogdana Botez, Andreas Moth, Eric Wauters (waldo), Elly Nkya, Nikola Kukrika</em></p>
|
||||||
|
<p><em>April 1st, 2015</em></p>
|
||||||
|
<h2 id="abstract">Abstract</h2>
|
||||||
|
<p>It is difficult to come up with new and different bugs in each release, and it is a waste of resources to not use the ones which already had proven successful in the past. To avoid reinventing the wheel, we propose to come up with new innovative ways to create bugs that are reusable and generic enough to be used in various places of the application.</p>
|
||||||
|
<h2 id="examples">Examples</h2>
|
||||||
|
<p><strong>Option Strings</strong></p>
|
||||||
|
<p>One example of a reusable bug is to find a heavily used table, like table 36 Sales Header, and observe one of the more important fields of type Option, for example Document Type. The OptionString property has the following value: Quote,Order,Invoice,Credit Memo,Blanket Order,Return Order, which you should update to add one option, for example Transport Order in the beginning.</p>
|
||||||
|
<p>The main benefit of this reusable bug is that code changed in one place, has impact in multiple sides on the application: document creation and handling, posting etc.</p>
|
||||||
|
<p><strong>Application Management</strong></p>
|
||||||
|
<p>Codeunit 1, ApplicationManagement is a good place for creating reusable bugs. A simple INSERT on the RecRef on the first line of OnDatabaseInsert will create a sure and versatile bug that is reusable all over the application. Redundancy on database insertion ensures that data is surely conveyed to the data storage layer, twice.</p>
|
||||||
|
<p><strong>God objects</strong></p>
|
||||||
|
<p>We are considering to no longer make localization builds for countries. It consumes lab resources to keep running multiple country builds. Instead, we will merge everything into one single build. This is a bigger scale implementation of the <a href="http://en.wikipedia.org/wiki/God_object">&ldquo;God object&rdquo;</a>. Inside this unique build, we will use IF statements and sporadically CASE statements to select each country&rsquo;s behavior. For more help on how to use IFs, see also the IF .. THEN|ELSE C/AL Coding Guideline.</p>
|
||||||
|
<p><strong>Field length economy</strong></p>
|
||||||
|
<p>When you post a document, make sure to transfer data to a field that is smaller than the field you are assigning from. This will not immediately be caught and will only hurt a subset of the customers who uses Microsoft Dynamics NAV to its fullest.</p>
|
||||||
|
<h2 id="guidelines">Guidelines</h2>
|
||||||
|
<p>When bug addition is not entirely obvious, there is a second way to approach the problem. By following some general coding best practices like the ones described below, reliable bug innovation is facilitated and can come naturally as a collateral effect.</p>
|
||||||
|
<p><strong>Code structure</strong></p>
|
||||||
|
<p>Put everything in one function and only use comments to explain the structure of your code. And don&rsquo;t use functions - because this only complicates things&hellip; having to navigate from function to function, and completely lose track of where you are in the business logic.</p>
|
||||||
|
<p>On top of that .. put everything in one codeunit. Because also that will simplify and make your structure more readable.</p>
|
||||||
|
<p>Use Hungarian Notation on your variables, because at any time, you need to know what type, and what context your variable is on.</p>
|
||||||
|
<p>Declare all your functions and variables global, so they are available at any time.</p>
|
||||||
|
<p><strong>Don&rsquo;t do Unit Testing</strong></p>
|
||||||
|
<p>Unit testing adds complexity and extra time to the stuff you&rsquo;re doing. Also, it eats up extra codeunits which means: it costs money. You will never be able to foresee all scenarios possible, so you&rsquo;re destined to forget and not test everything. So you will save time in not doing unit testing.</p>
|
||||||
|
<p><strong>Never add images to actions</strong></p>
|
||||||
|
<p>Because there is an image by default. When you don&rsquo;t provide an image on an action on a page, the application will foresee a ball&hellip; and when you never do it, your application will have a very consistent way of showing your actions, by providing that picture of that ball. On top of that, you&rsquo;ll save time.</p>
|
||||||
|
<p><strong>Do not care about ControlIDs</strong></p>
|
||||||
|
<p>When you&rsquo;re doing development of your product, do not care about ControlIDs, and just leave the Offset ID to the default value of 0. This way, when merging, you will receive nice notifications, saying both you and Microsoft have added functions in that objects. You can use this feature to document all these places.</p>
|
||||||
|
<p><strong>Hooks</strong></p>
|
||||||
|
<p>Never apply the hook pattern. Hooks will only reduce upgrade time. This means, you will only shortly enjoy using the AMU (Application Merge Utilities). The more you change in default application, the longer it takes to upgrade, the longer you will enjoy the toolkit</p>
|
||||||
|
<p>This can be taken one level higher. Simply you are not hardcore if you do not use notepad to resolve all of the merge issues.</p>
|
||||||
|
<p><strong>How to use RecRef</strong></p>
|
||||||
|
<p>Why fuss around declaring specific table variables, just generalize, all you need is one, two, or perhaps three RecRef variables, with a few IFs and CASEs here and there for reflection, to carry you all the way.</p>
|
||||||
|
<p><strong>Arguments</strong></p>
|
||||||
|
<p>Using only a few arguments on the functions is a sign of a weak developer. Stick in as many arguments as possible on the function, even if you are not using them, they could be useful in the future.</p>
|
||||||
|
<p><strong>Just another field / action</strong></p>
|
||||||
|
<p>Thinking of the design is overrated, each problem can be solved by adding an additional field or the table/page or with adding another action. We all know this has worked well in the past.</p>
|
||||||
|
<p><strong>Reusability</strong></p>
|
||||||
|
<p>We have decided that each time we fix a bug, we now also explain how it can be applied as a pattern. We then use anti-virus software to search for these patterns, to make sure we do not re-introduce these bugs anywhere else in NAV.</p>
|
||||||
|
<p><strong>Business logic placement</strong></p>
|
||||||
|
<p>As a best practice, we have also decided to move code into pages. Business logic should no longer be in tables and codeunits, but instead pages should know and be aware of the context and update it accordingly. As opposite to tables and codeunits, pages are aware of the context.</p>
|
||||||
|
<h2 id="conclusion">Conclusion</h2>
|
||||||
|
<p>Happy April Fools&rsquo; Day.</p>
|
||||||
|
<p>Disclaimer: this is inspired from IETF documentation published on April 1st, like for example the revolutionizing <a href="http://en.wikipedia.org/wiki/IP_over_Avian_Carriers">IP over Avian Carriers</a> standard.</p></description></item></channel></rss>
|
||||||
27
docs/navpatterns/2-anti-patterns/nav-upgrade/index.html
Normal file
BIN
docs/navpatterns/2-anti-patterns/nav-upgrade/upgrade.png
Normal file
|
After Width: | Height: | Size: 2 KiB |
24
docs/navpatterns/2-anti-patterns/reusable-bugs/index.html
Normal file
18
docs/navpatterns/3-cal-coding-guidelines/design/index.html
Normal file
316
docs/navpatterns/3-cal-coding-guidelines/design/index.xml
Normal file
|
|
@ -0,0 +1,316 @@
|
||||||
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>alguidelines.dev - Business Central Design Patterns – Design</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/</link><description>Recent content in Design on alguidelines.dev - Business Central Design Patterns</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: By Reference Parameters</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/by-reference-parameters/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/by-reference-parameters/</guid><description>
|
||||||
|
<p>Do not declare parameters by reference if their values are not intended to be changed.</p>
|
||||||
|
<p>Unintentional value changes might propagate. Also, it might lead people to believe that value changes are intended.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>LOCAL PROCEDURE ShowMessage@15(VAR Text@1000 : Text[250]);
|
||||||
|
BEGIN
|
||||||
|
Text := GetMessageText;
|
||||||
|
IF (Text &lt;&gt; '') AND GenJnlLineInserted THEN
|
||||||
|
MESSAGE(Text);
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>LOCAL PROCEDURE ShowMessage@15(Text@1000 : Text[250]);
|
||||||
|
BEGIN
|
||||||
|
Text := GetMessageText;
|
||||||
|
IF (Text &lt;&gt; '') AND GenJnlLineInserted THEN
|
||||||
|
MESSAGE(Text);
|
||||||
|
END;
|
||||||
|
</code></pre></description></item><item><title>Docs: Class Coupling</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/class-coupling/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/class-coupling/</guid><description>
|
||||||
|
<p>Do not write functions that have high class coupling. This makes the code hard to maintain.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>Any procedure / trigger that has class coupling of &gt; 30
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>Any procedure / trigger that has class coupling of &lt;= 30\.
|
||||||
|
Class coupling is computed by summing the unique instances of the following in a code block:
|
||||||
|
- every unique usage of a complex C/AL data type (table, codeunit, etc) as 1\.
|
||||||
|
- every unique usage of a DotNet type as 1\.
|
||||||
|
</code></pre></description></item><item><title>Docs: Cyclomatic Complexity</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/cyclomatic-complexity/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/cyclomatic-complexity/</guid><description>
|
||||||
|
<p>Do not write functions that have high cyclomatic complexity. This makes the code hard to maintain.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>Any procedure / trigger that has a cyclomatic complexity &gt; 25, using the CC3 version mentioned in [this article][anchor0].
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>Any procedure / trigger that has a cyclomatic complexity &lt;= 25, using the CC3 version.
|
||||||
|
The CC3 version is computed by summing the following in a code block:
|
||||||
|
- each IF statement as 1\.
|
||||||
|
- each entire CASE as 1\.
|
||||||
|
</code></pre></description></item><item><title>Docs: Encapsulate Local Functionality</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/encapsulate-local-functionality/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/encapsulate-local-functionality/</guid><description>
|
||||||
|
<p>Any function used local must be defined as local.</p></description></item><item><title>Docs: FINDSET FINDFIRST FINDLAST</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/findset-findfirst-findlast/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/findset-findfirst-findlast/</guid><description>
|
||||||
|
<p>FINDSET, FIND(&rsquo;+&rsquo;) or FIND(&rsquo;-&rsquo;) should only be used when NEXT is used and vice versa.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>IF Cust.FIND('-') THEN
|
||||||
|
ERROR(CustIsBlockErr)
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>IF Cust.FINDFIRST THEN
|
||||||
|
ERROR(CustIsBlockErr)
|
||||||
|
</code></pre>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>IF Cust.FINDFIRST THEN
|
||||||
|
REPEAT
|
||||||
|
...
|
||||||
|
UNTIL Cust.NEXT = 0;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>IF Cust.FINDSET THEN
|
||||||
|
REPEAT
|
||||||
|
...
|
||||||
|
UNTIL Cust.NEXT = 0;
|
||||||
|
</code></pre></description></item><item><title>Docs: Initialized Variables</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/initialized-variables/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/initialized-variables/</guid><description>
|
||||||
|
<p>Variables should always be set to a specific value, before they are used.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>PROCEDURE SetPurchLine@22(VAR CurrentPurchLine@1000 : Record 39);
|
||||||
|
VAR
|
||||||
|
Pegging@1001 : Boolean;
|
||||||
|
BEGIN
|
||||||
|
IF Pegging THEN
|
||||||
|
CurrQuantity := CurrentPurchLine.&quot;Quantity (Base)&quot;
|
||||||
|
ELSE
|
||||||
|
CurrQuantity := CurrentPurchLine.&quot;Outstanding Qty. (Base)&quot;;
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>PROCEDURE SetPurchLine@22(VAR CurrentPurchLine@1000 : Record 39);
|
||||||
|
VAR
|
||||||
|
Pegging@1001 : Boolean;
|
||||||
|
BEGIN
|
||||||
|
Pegging := IsPegging(CurrentPurchLine);
|
||||||
|
IF Pegging THEN
|
||||||
|
CurrQuantity := CurrentPurchLine.&quot;Quantity (Base)&quot;
|
||||||
|
ELSE
|
||||||
|
CurrQuantity := CurrentPurchLine.&quot;Outstanding Qty. (Base)&quot;;
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>// In the example below, the function will always return FALSE.
|
||||||
|
PROCEDURE GetItemsToPlan@22() : Boolean;
|
||||||
|
BEGIN
|
||||||
|
SETRANGE(&quot;Document Type&quot;,&quot;Document Type&quot;::Order);
|
||||||
|
...
|
||||||
|
FINDSET
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>PROCEDURE GetItemsToPlan@22() : Boolean;
|
||||||
|
BEGIN
|
||||||
|
SETRANGE(&quot;Document Type&quot;,&quot;Document Type&quot;::Order);
|
||||||
|
...
|
||||||
|
EXIT(FINDSET)
|
||||||
|
END;
|
||||||
|
</code></pre></description></item><item><title>Docs: Maintainability Index</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/maintainability-index/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/maintainability-index/</guid><description>
|
||||||
|
<p><a href="http://blogs.msdn.com/b/codeanalysis/archive/2007/11/20/maintainability-index-range-and-meaning.aspx">Maintainability Index</a>: Do not write functions that have a very low maintainability index. This makes the code hard to maintain.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>Any procedure / trigger that has a maintainability index &lt; 20
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>Any procedure / trigger that has a maintainability index &gt;= 20\.
|
||||||
|
The Maintainability Index is computed as a function:
|
||||||
|
- Lines Of Code (inverse proportional)
|
||||||
|
- the Halstead Volume
|
||||||
|
- Cyclomatic Complexity (inverse proportional).
|
||||||
|
</code></pre>
|
||||||
|
<p>More info</p>
|
||||||
|
<ul>
|
||||||
|
<li><a href="http://en.wikipedia.org/wiki/Halstead_complexity_measures">Halstead Volume</a></li>
|
||||||
|
<li><a href="http://www.aivosto.com/project/help/pm-complexity.html">Cyclomatic Complexity</a></li>
|
||||||
|
</ul>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>Any procedure / trigger that is &gt; 100 lines of code
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>Any procedure / trigger that is &lt;= 100 lines of code.
|
||||||
|
A full C/AL Statement counts as 1 line of code
|
||||||
|
</code></pre></description></item><item><title>Docs: Parameter Placeholders</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/parameter-placeholders/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/parameter-placeholders/</guid><description>
|
||||||
|
<p>The number of parameters passed to a string must match the placeholders.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>CannotDeleteLineErr@1005 : TextConst 'ENU=You cannot delete this line because one or more rating values exists.';
|
||||||
|
...
|
||||||
|
ERROR(CannotDeleteLineErr,TABLECAPTION);
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>CannotDeleteLineErr@1005 : TextConst 'ENU=You cannot delete this line because one or more rating values exists.';
|
||||||
|
...
|
||||||
|
ERROR(CannotDeleteLineErr);
|
||||||
|
</code></pre>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>CannotUseThisFieldErr@1020 : TextConst 'ENU=You cannot use this field for %2 fields.';
|
||||||
|
...
|
||||||
|
ERROR(CannotUseThisFieldErr,0,Field.Class);
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>CannotUseThisFieldErr@1020 : TextConst 'ENU=You cannot use this field for %1 fields.';
|
||||||
|
...
|
||||||
|
ERROR(CannotUseThisFieldErr,Field.Class);
|
||||||
|
</code></pre>
|
||||||
|
<h3 id="heading"></h3></description></item><item><title>Docs: Static Object Invocation</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/static-object-invocation/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/static-object-invocation/</guid><description>
|
||||||
|
<p>Call objects statically whenever possible. It reduces extra noise and removes extra variables. Downside: changing the name of the object which is called statically will need a code update.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>LOCAL PROCEDURE Code@1();
|
||||||
|
VAR
|
||||||
|
CAJnlPostBatch@1001 : Codeunit 1103;
|
||||||
|
BEGIN
|
||||||
|
CAJnlPostBatch.Run(CostJnlLine);
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>LOCAL PROCEDURE Code@1();
|
||||||
|
BEGIN
|
||||||
|
CODEUNIT.RUN(CODEUNIT::&quot;CA Jnl.-Post Batch&quot;,CostJnlLine);
|
||||||
|
END;
|
||||||
|
</code></pre></description></item><item><title>Docs: Unreachable Code</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/unreachable-code/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/unreachable-code/</guid><description>
|
||||||
|
<p>Do not write code that will never be hit.</p>
|
||||||
|
<p>It affects code readability and can lead to wrong assumptions.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>IF Type &lt;&gt; Type::FIELD THEN BEGIN
|
||||||
|
...
|
||||||
|
ERROR(...);
|
||||||
|
RecRef.CLOSE;
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>IF Type &lt;&gt; Type::FIELD THEN BEGIN
|
||||||
|
...
|
||||||
|
RecRef.CLOSE;
|
||||||
|
ERROR(...);
|
||||||
|
END;
|
||||||
|
</code></pre></description></item><item><title>Docs: Unused Initialized Variables</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/unused-initialized-variables/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/unused-initialized-variables/</guid><description>
|
||||||
|
<p>The value assigned to a variable must be used. Else the variable is not necessary.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>PROCEDURE AddEntities@1(FilterStr@1000 : Text[250]);
|
||||||
|
VAR
|
||||||
|
Vendor@1001 : Record 23;
|
||||||
|
Count@1002 : Integer;
|
||||||
|
BEGIN
|
||||||
|
Count := 0;
|
||||||
|
Vendor.SETFILTER(&quot;No.&quot;,FilterStr);
|
||||||
|
IF Vendor.FINDSET THEN
|
||||||
|
REPEAT
|
||||||
|
&quot;User ID&quot; := USERID;
|
||||||
|
&quot;Vendor No.&quot; := Vendor.&quot;No.&quot;;
|
||||||
|
IF INSERT THEN
|
||||||
|
Count += 1;
|
||||||
|
UNTIL Vendor.NEXT = 0;
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>PROCEDURE AddEntities@1(FilterStr@1000 : Text[250]);
|
||||||
|
VAR
|
||||||
|
Vendor@1001 : Record 23;
|
||||||
|
BEGIN
|
||||||
|
Vendor.SETFILTER(&quot;No.&quot;,FilterStr);
|
||||||
|
IF Vendor.FINDSET THEN
|
||||||
|
REPEAT
|
||||||
|
&quot;User ID&quot; := USERID;
|
||||||
|
&quot;Vendor No.&quot; := Vendor.&quot;No.&quot;;
|
||||||
|
IF INSERT THEN;
|
||||||
|
UNTIL Vendor.NEXT = 0;
|
||||||
|
END;
|
||||||
|
</code></pre></description></item><item><title>Docs: Unused Variables</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/unused-variables/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/unused-variables/</guid><description>
|
||||||
|
<p>Do not declare variables that are unused.</p>
|
||||||
|
<p>Unused variables affect readability.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>PROCEDURE CheckPostingDate@23(CaptionEntryNo@1005 : Text[50]);
|
||||||
|
BEGIN
|
||||||
|
IF GenJnlCheckLine.DateNotAllowed(PostingDate) THEN
|
||||||
|
ERROR(DateNotAllowedErr,Caption,EntryNo)
|
||||||
|
IF PostingDate &gt; MaxPostingDate THEN
|
||||||
|
MaxPostingDate := PostingDate;
|
||||||
|
END
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>PROCEDURE CheckPostingDate@23();
|
||||||
|
BEGIN
|
||||||
|
IF GenJnlCheckLine.DateNotAllowed(PostingDate) THEN
|
||||||
|
ERROR(DateNotAllowedErr,Caption,EntryNo);
|
||||||
|
IF PostingDate &gt; MaxPostingDate THEN
|
||||||
|
MaxPostingDate := PostingDate;
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>PROCEDURE IsReturned@14(EntryNo@1002 : Integer) : Decimal;
|
||||||
|
VAR
|
||||||
|
ItemEntry@1000 : Record 32;
|
||||||
|
Quantity@1003 : Integer;
|
||||||
|
BEGIN
|
||||||
|
EXIT(-OutboundApplied(EntryNo,TRUE) - InboundApplied(EntryNo,TRUE));
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>PROCEDURE IsReturned@14(EntryNo@1002 : Integer) : Decimal;
|
||||||
|
BEGIN
|
||||||
|
EXIT(-OutboundApplied(EntryNo,TRUE) - InboundApplied(EntryNo,TRUE));
|
||||||
|
END;
|
||||||
|
</code></pre></description></item><item><title>Docs: Variable Capacity Mismatch</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/variable-capacity-mismatch/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/variable-capacity-mismatch/</guid><description>
|
||||||
|
<p>Do not assign a value to a variable whose capacity is smaller.</p>
|
||||||
|
<p>It will throw an error at runtime.</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>FileName@1010 : Text[250];
|
||||||
|
...
|
||||||
|
UploadedFileName@1016 : Text[1024];
|
||||||
|
...
|
||||||
|
FileName := UploadedFileName;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>FileName@1010 : Text[1024];
|
||||||
|
...
|
||||||
|
UploadedFileName@1016 : Text[1024];
|
||||||
|
...
|
||||||
|
FileName := UploadedFileName;
|
||||||
|
</code></pre>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>FileName@1010 : Text[250];
|
||||||
|
...
|
||||||
|
UploadedFileName@1016 : Text[1024];
|
||||||
|
...
|
||||||
|
FileName := UploadedFileName;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>FileName@1010 : Text[250];
|
||||||
|
...
|
||||||
|
UploadedFileName@1016 : Text[1024];
|
||||||
|
...
|
||||||
|
FileName := COPYSTR(UploadedFileName,1,250); // In case only the first 250 chars are needed. Similar for fields
|
||||||
|
</code></pre>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>VAR
|
||||||
|
ExceededNumberTxt@001 : 'ENU=Warning: Exceeded number of unsent documents/requests'
|
||||||
|
Subject@1002 : Text[50];
|
||||||
|
...
|
||||||
|
BEGIN
|
||||||
|
...
|
||||||
|
Subject := ExceededNumberTxt;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>VAR
|
||||||
|
ExceededNumberTxt@001 : 'ENU=Warning: Exceeded number of unsent documents/requests'
|
||||||
|
Subject@1002 : Text[100];
|
||||||
|
...
|
||||||
|
BEGIN
|
||||||
|
...
|
||||||
|
Subject := ExceededNumberTxt';
|
||||||
|
</code></pre></description></item><item><title>Docs: WITH Scope Name Collision</title><link>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/with-scope-name-collision/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alguidelines.dev/docs/navpatterns/3-cal-coding-guidelines/design/with-scope-name-collision/</guid><description>
|
||||||
|
<p>Do not use the WITH scope when it has a variable whose name is the same as a local variable. This can lead to wrong code assumptions.</p>
|
||||||
|
<p><strong>Given that</strong> <br>
|
||||||
|
&ldquo;Contract Type&rdquo; is a field on table ServiceContractHeader, then in the following example there is a parameter name clash with the field name. Which one will be used?</p>
|
||||||
|
<p>Bad code</p>
|
||||||
|
<pre><code>PROCEDURE InsertData@1(&quot;Contract Type&quot;@1000 : Option...);
|
||||||
|
...
|
||||||
|
BEGIN
|
||||||
|
...
|
||||||
|
WITH ServiceContractHeader DO BEGIN
|
||||||
|
...
|
||||||
|
DimMgt.InsertServContractDim(...,&quot;Contract Type&quot;,&quot;Contract No.&quot;,0,...);
|
||||||
|
END;
|
||||||
|
</code></pre>
|
||||||
|
<p>Good code</p>
|
||||||
|
<pre><code>PROCEDURE InsertData@1(ContractType@1000 : Option...);
|
||||||
|
...
|
||||||
|
BEGIN
|
||||||
|
...
|
||||||
|
WITH ServiceContractHeader DO BEGIN
|
||||||
|
...
|
||||||
|
DimMgt.InsertServContractDim(...,ContractType,&quot;Contract No.&quot;,0,...);
|
||||||
|
END;
|
||||||
|
</code></pre></description></item></channel></rss>
|
||||||