[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6ACMN93ZWMYCACE4A29ZHDT":3,"skill-same:01M6ACMN93ZWMYCACE4A29ZHDT":60},{"skillNo":4,"name":5,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":26,"repositoryHtmlUrl":27,"repositoryHomepageUrl":28,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":6,"updatedAt":31,"install":32,"resources":45},"01M6ACMN93ZWMYCACE4A29ZHDT","coding-standards",null,"apache\u002Fofbiz-plugins","apache","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F47359?v=4","01M6AC83E6K4FDKK7HZ8WNMQKE","The Apache Software Foundation","01M6ACMJJ1Q4WYATY4GXZ2FAVD",178,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fcoding-standards\u002FSKILL.md",[],[18],"coding standards","2026-11-10 10:12:30",false,"\u003C!--\nLicensed to the Apache Software Foundation (ASF) under one\nor more contributor license agreements.  See the NOTICE file\ndistributed with this work for additional information\nregarding copyright ownership.  The ASF licenses this file\nto you under the Apache License, Version 2.0 (the\n\"License\"); you may not use this file except in compliance\nwith the License.  You may obtain a copy of the License at\n\nhttp:\u002F\u002Fwww.apache.org\u002Flicenses\u002FLICENSE-2.0\n\nUnless required by applicable law or agreed to in writing,\nsoftware distributed under the License is distributed on an\n\"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\nKIND, either express or implied.  See the License for the\nspecific language governing permissions and limitations\nunder the License.\n-->\n\n---\nname: coding-standards\ndescription:\n- Writing or reviewing Java, Groovy, or XML changes in OFBiz.\n- Choosing naming conventions for components, entities, services, or classes.\n- Deciding whether logic belongs in XML actions vs. Groovy.\n- Applying UtilValidate, UtilMisc, EntityQuery, or UI-label (i18n) patterns.\n---\n\n# Skill: coding-standards\n## Goal\nEnsure all OFBiz contributions meet production-grade standards for clarity, maintainability, and architectural alignment.\n\n## Triggers\n**ALWAYS** read this skill when:\n- Writing any code (Java, Groovy, XML, CSS).\n- Reviewing PRs or auditing existing code for OFBiz alignment.\n- Using OFBiz utility libraries for validation and map creation.\n- Preparing a pull request or implementing new features.\n\n## General Rules\n1. **Explain the WHY**: Code shows *what* happens. Comments must explain *why* (e.g., explaining a workaround for a legacy constraint).\n2. **No Internal Monologue**: Delete \"thinking out loud\" or \"maybe this works\" comments.\n3. **Guard against Technical Debt**: Avoid `\u002F\u002F TODO` without a tracking reference.\n4. **Remove Debug Code**: Clean up `System.out.println`, `println`, or excessive `Debug.logInfo` before completion.\n\n## OFBiz Specific Standards\n1. **XML Actions**: Keep logic flat. If it requires complex loops or nesting, move to Groovy.\n2. **Naming Conventions**:\n    - **Components**: `kebab-case` (e.g., `order-management`).\n    - **Entities\u002FServices**: `UpperCamelCase` for entities, `lowerCamelCase` for services.\n    - **Java\u002FGroovy**: `lowerCamelCase` for methods\u002Fvariables, `UpperCamelCase` for classes.\n3. **Documentation**:\n    - **Services**: Every service MUST have a `\u003Cdescription>` in `services.xml`.\n    - **Java\u002FGroovy**: Use Javadoc\u002FGroovydoc for public methods and complex logic.\n4. **Utility Libraries**:\n    - **Validation**: ALWAYS use `UtilValidate.isEmpty()` or `isNotEmpty()`.\n    - **Maps\u002FLists**: Use `UtilMisc.toMap(...)` and `UtilMisc.toList(...)` for concise creation.\n    - **Logging**: Use `Debug.logInfo(...)`, `Debug.logError(...)` with a `MODULE` tag.\n    - Use `.filterByDate()` for all date-effective entities (e.g., `ProductPrice`, `StatusItem`).\n    - Prefer `EntityQuery` over `delegator.findOne(...)`.\n    - Prefer shared OFBiz\u002Fdomain helpers such as `PartyHelper`, `UtilDateTime`, `ObjectType`, and existing component helpers over local formatting or conversion helpers.\n    - If service XML already types a parameter as `Timestamp`, `BigDecimal`, `Double`, `Long`, or `Integer`, use the value directly in Groovy\u002FJava service logic instead of re-parsing or re-casting it at the service boundary.\n5. **Internationalization (i18n)**:\n    - Never hardcode user-facing strings. Use `uiLabelMap.LabelKey`.\n\n## Guardrails\n- **Consistency**: Follow the existing indentation and naming conventions of the component you are editing.\n- **Transactional Integrity**: Respect OFBiz service boundaries; don't commit transactions manually.\n\n## Examples\n**Example: Clean documentation**\n```java\n\u002F\u002F Check if the product is active based on current system time.\n\u002F\u002F We use filterByDate to ensure we only get valid price records.\nGenericValue price = EntityQuery.use(delegator).from(\"ProductPrice\")\n        .where(\"productId\", productId)\n        .filterByDate()\n        .queryFirst();\n```\n\n## See Also\n- `prepush-readiness` — the mechanical checks (Checkstyle, CodeNarc, compilation) that enforce a subset of these standards before a push.\n- `manage-contribution-workflow` — branching, testing, commit, and PR conventions once the code itself is ready.\n",{},"trunk","6c6c27710443de03e9247605d33a2e2f5bc3d1e2","ai-agent-skills\u002Fcoding-standards",222,"https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins","https:\u002F\u002Fofbiz.apache.org\u002F","https:\u002F\u002Fgithub.com\u002Fapache","https:\u002F\u002Fwww.apache.org\u002F","2026-11-10 15:50:39",{"source":7,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add apache\u002Fofbiz-plugins --skill coding-standards",{"tool":38,"command":39},"bunx","bunx skills add apache\u002Fofbiz-plugins --skill coding-standards",{"tool":41,"command":42},"pnpm","pnpm dlx skills add apache\u002Fofbiz-plugins --skill coding-standards","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fcoding-standards\u002FSKILL.md",true,[46,52,56],{"path":47,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":50,"sourceHtmlUrl":51},"ADR-FORMAT.md","REFERENCE","参考文档",2733,"https:\u002F\u002Fgithub.com\u002Ffmal\u002Fdotfiles\u002Fblob\u002Fmaster\u002F.agents\u002Fskills\u002Fdomain-modeling\u002FADR-FORMAT.md",{"path":53,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":54,"sourceHtmlUrl":55},"DOMAIN-AWARENESS.md",2025,"https:\u002F\u002Fgithub.com\u002Ffmal\u002Fdotfiles\u002Fblob\u002Fmaster\u002F.agents\u002Fskills\u002Fdomain-modeling\u002FDOMAIN-AWARENESS.md",{"path":57,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":58,"sourceHtmlUrl":59},"GLOSSARY-FORMAT.md",2300,"https:\u002F\u002Fgithub.com\u002Ffmal\u002Fdotfiles\u002Fblob\u002Fmaster\u002F.agents\u002Fskills\u002Fdomain-modeling\u002FGLOSSARY-FORMAT.md",[61,68,75,82,89,96],{"skillNo":62,"name":63,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":19},"01M6ACQSN90YKJZ92MQ52D9R8H","prepush-readiness","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fprepush-readiness\u002FSKILL.md",[],[67],"prepush readiness",{"skillNo":69,"name":70,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":19},"01M6ACQPR1WRA751V4DXVC3AHF","manage-webapps","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fmanage-webapps\u002FSKILL.md",[],[74],"manage webapps",{"skillNo":76,"name":77,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":19},"01M6ACQMCX8Z7NY2CE08NCV6ND","manage-themes","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fmanage-themes\u002FSKILL.md",[],[81],"manage themes",{"skillNo":83,"name":84,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M6ACQHYN20AFWF6TKK4RGQ8A","manage-tests","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fmanage-tests\u002FSKILL.md",[],[88],"manage tests",{"skillNo":90,"name":91,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":19},"01M6ACQFRMW7R45YD3HRAXPGWF","manage-templates","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fmanage-templates\u002FSKILL.md",[],[95],"manage templates",{"skillNo":97,"name":98,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":19},"01M6ACQCSSDZQMD8VX2K3WRR93","manage-strategies","https:\u002F\u002Fgithub.com\u002Fapache\u002Fofbiz-plugins\u002Fblob\u002Ftrunk\u002Fai-agent-skills\u002Fmanage-strategies\u002FSKILL.md",[],[102],"manage strategies"]