Instruction file imported from migoamigoea-star/ioi-docs-uploads (
.github/instructions/canvas-powerfx-formulas.instructions.md). Copyright stays with the author.
⚠️ DEPRECATED — This file has been consolidated into
.github/instructions/canvas-pa-yaml.instructions.md(Sections C through H). See that file for all Power Fx formula rules, SharePoint schemas, formula patterns, connector rules, and compliance checklists. Do not create new references to this file. Update existing cross-references to point tocanvas-pa-yaml.instructions.md.
Canvas App Power Fx Formula & SharePoint Schema Instructions
Scope: All .pa.yaml files in the IOI Domino → M365 migration project. Every Power Fx formula must use real SharePoint column names, follow IOI naming conventions, and comply with .pa.yaml Schema v3.0.
When a screenshot exists, it is a visual reference only. Do not derive final control names, field names, formulas, variables, data sources, or label text from the screenshot unless they also match the real app schema/behavior.
These rules are mandatory whenever a screen is created or modified. Do not defer formula/schema compliance to a later audit pass.
🆕 Cross-Reference:
design/IOI-CANVAS-SCREEN-SPEC.mdis the companion Screen Requirement Spec covering layout dimensions, typography, color system, container strategy, control properties, responsive patterns, validation, people integration, and PAC CLI commands. Use this instructions file for formula syntax; use the Screen Spec for screen-level design standards.
Severity levels:
- CRITICAL — Wrong column name or type will cause runtime error. Must fix before merge.
- IMPORTANT — Violates conventions, causes maintenance burden. Fix in same sprint.
- SUGGESTION — Best practice improvement. Plan for future iteration.
1. Formula Writing Rules
F1: All Formulas Start with =
- Severity: CRITICAL
- Every Power Fx expression in a
.pa.yamlproperty MUST begin with=
# CORRECT
Text: =ThisItem.Title
Visible: =varShowPanel
Fill: =gblITTheme.PrimaryColor
# WRONG — missing = prefix
Text: ThisItem.Title
F2: Use Multiline Block Scalar for Complex Formulas
- Severity: CRITICAL
- When a formula contains
#(YAML comment) or:(YAML mapping), use|-block scalar - Single-line formulas are fine for simple expressions
# SIMPLE — single line is OK
Visible: =varShowPanel
Text: ="IOI IT Support"
# COMPLEX — multiline required (contains : and multiple lines)
OnVisible: |-
=Set(gblITTheme, { PrimaryColor: RGBA(0,32,70,1) });
ClearCollect(colKPIs, { Label: "Total", Value: Text(CountRows(Filter(MainDB_IT, FormCode = "ITSSR"))) })
F3: No C-Style Escaping in Formulas
- Severity: CRITICAL
\nis NOT a newline in Power Fx — it's a literal backslash-n- Use YAML multiline block scalars (
|,|-,|+) for multi-line content - Power Fx does NOT support
\t,\r,\nescape sequences
F4: Chaining Multiple Actions with ;
- Severity: IMPORTANT
- In behavior formulas (
OnSelect,OnVisible,OnHidden), chain actions with; - Actions execute in order; next action waits for current to complete
OnSelect: |-
=Set(varLoading, true);
Patch(MainDB_IT, ThisItem, { CurrentStatus: { Value: "Approved" } });
Set(varLoading, false);
Navigate(scrSuccess, ScreenTransition.Fade)
F5: Prefer Declarative Over Imperative
- Severity: IMPORTANT
- Use formula-driven properties (auto-recalculate) instead of imperative
Set()+UpdateContext() - Only use imperative logic in
On...behavior formulas when state mutation is required
# GOOD — declarative, auto-updates when data changes
Items: =Filter(MainDB_IT, FormCode = "ITSSR" && CurrentStatus.Value = "Active")
# BAD — imperative, requires manual refresh
# OnVisible: Set(colItems, Filter(MainDB_IT, FormCode = "ITSSR" && CurrentStatus.Value = "Active"))
# Items: colItems
2. Naming Conventions
⚠️ This section is maintained in a dedicated file. For the complete, authoritative control naming reference, see:
.github/instructions/canvas-pa-yaml.instructions.md(Section A)This deprecated file covers Power Fx formula syntax and SharePoint schema only. All naming rules were updated during the 2026-06-18 universal rename (30,480 controls renamed).
N1: Control Naming — Full Convention in Dedicated File
- Severity: IMPORTANT
- The full naming convention is
<ScreenCode>_<ControlTypePrefix>_<Purpose> - Control name prefix quick reference (see dedicated file for full table):
| Prefix | Control Type(s) |
|---|---|
con |
GroupContainer, Container |
lbl |
Label, Text, ModernText |
btn |
Button, ModernButton |
gal |
Gallery, ModernGallery |
txt |
TextInput, ModernTextInput |
drp |
Dropdown, Classic/DropDown |
cmb |
ComboBox, ModernCombobox |
htm |
HtmlText, HtmlViewer |
img |
Image, ModernImage |
icn |
Icon, ModernIcon |
cmp |
CanvasComponent, Component |
dtp |
DatePicker, Classic/DatePicker |
chk |
Checkbox, ModernCheckbox |
tgl |
Toggle, ModernToggle |
frm |
Form, EditForm, ViewForm, NewForm |
Cross-reference: See
.github/instructions/canvas-pa-yaml.instructions.md(Section A) for complete examples, ScreenCode derivation rules, component rules, duplicate prevention, and reserved keywords.
N2: Variable Naming Conventions
- Severity: IMPORTANT
| Pattern | Scope | Example |
|---|---|---|
gblITTheme |
Global (Set) | Theme object with color palette |
gblReplica* |
Global (Set) | Screen context: FormCode, FormTitle, UserEmail, UserName |
gblReplicaSelectedRecord |
Global (Set) | Currently selected record |
gblIsReadOnly |
Global (Set) | View/Edit mode flag |
gblSelectedID |
Global (Set) | Currently selected item ID |
var* |
Context or Global | Screen-scoped: varLoading, varDeptFilter, varTimePeriod |
col* |
Collection | App-wide tables: colMgmtKPIs, colRecentTickets |
N3: Theme Object Structure
- Severity: IMPORTANT
- Every screen MUST set
gblITThemeinOnVisible
OnVisible: |-
=Set(gblITTheme, {
PrimaryColor: RGBA(0,32,70,1),
SecondaryColor: RGBA(80,95,118,1),
AccentColor: RGBA(37,99,235,1),
LightBg: RGBA(248,250,253,1),
Surface: RGBA(255,255,255,1),
SuccessColor: RGBA(22,163,74,1),
WarningColor: RGBA(245,158,11,1),
DangerColor: RGBA(220,38,38,1),
TextPrimary: RGBA(26,27,30,1),
TextSecondary: RGBA(68,71,78,1),
BorderColor: RGBA(196,198,207,1),
SoftBlue: RGBA(214,227,255,1),
PrimaryContainer: RGBA(27,54,93,1),
SurfaceContainerLow: RGBA(244,243,247,1),
SurfaceContainerHigh: RGBA(233,231,235,1)
})
N4: Screen Naming Convention
- Severity: IMPORTANT
- Screen names:
scr{FormCode}{ScreenType}— e.g.,scrITSSRMgmtReport,scrSHEForms - No spaces, PascalCase after prefix
2A. Connector Usage Rules
C1: Use Office365Users for Real Person Identity on Screen
- Severity: IMPORTANT
- If a field or UI element is intended to show a real person identity, prefer
Office365Usersover plain text when the connector is available. - This applies especially to:
- name
- requestor
- requested by
- submitted by
- assigned to
- approver
- reviewer
- manager
- HOD
- checked by
- verified by
- prepared by
Use the SharePoint field as the persistence source, and use Office365Users
for display enrichment, lookup, profile, manager, and photo behavior.
// Current user identity
User().FullName
User().Email
// Office 365 profile enrichment
Office365Users.MyProfile().DisplayName
Office365Users.MyProfile().Department
Office365Users.MyProfile().JobTitle
// Specific person by email/UPN
Office365Users.UserProfileV2(txtEmail.Text).displayName
Office365Users.UserProfileV2(txtEmail.Text).mail
// Manager lookup
Office365Users.ManagerV2(txtEmail.Text).displayName
// Search people for picker scenarios
Office365Users.SearchUserV2({
searchTerm: txtPersonSearch.Text,
top: 10,
isSearchTermRequired: true
}).value
C2: Do Not Treat Name/Email Text as Canonical Identity When a People Pattern Is Intended
- Severity: IMPORTANT
- If the screen is meant to show a real employee, approver, requestor, or owner,
do not rely on a disconnected plain text label when
Office365Usersor a SharePoint Person field is available. - Text-only storage columns such as
SubmittedBy_Email,Requestor_Email, orApprovedBy_Namemay be used as fallback fields, audit snapshots, or quick persistence values, but the preferred screen pattern is:- SharePoint Person field when present
- otherwise
Office365Userslookup using email/UPN - otherwise text fallback with explicit limitation
C3: Connector Responsibility Split
- Severity: IMPORTANT
- Use the correct connector for the correct job:
| Use Case | Preferred Connector / Pattern |
|---|---|
| Show current user name/email | User() or Office365Users.MyProfile() |
| Show another employee/approver/requestor | Office365Users.UserProfileV2() |
| Search people | Office365Users.SearchUserV2() |
| Show manager | Office365Users.ManagerV2() |
| Show user photo | Office365Users.UserPhotoV2() |
| Send email from app | Office365Outlook.SendEmailV2() |
| Calendar / room booking UI | Power Automate flow using Outlook calendar actions |
| List room lists / rooms | Power Automate flow using Outlook room actions |
| Meeting time suggestions | Power Automate flow using Find meeting times (V2) |
| Trigger approval workflow | Power Automate flow from Canvas app |
| Human approval action | Start and wait for an approval in Power Automate |
C4: Approvals Should Usually Run Through Power Automate, Not Screen-Only Logic
- Severity: IMPORTANT
- For production approval workflows, prefer:
Canvas App -> Flow.Run(...) -> Power Automate approval action - Use the Approvals connector and
Start and wait for an approvalinside the flow. This is the default enterprise pattern for maintainable approval logic.
Set(
varApprovalResult,
Flow_SendApproval.Run(
Text(ThisItem.ID),
ThisItem.Title,
ThisItem.CurrentApprover_Email,
txtApprovalDetails.Text
)
)
C5: Use Office365Outlook for Email Delivery
- Severity: IMPORTANT
- Use
Office365Outlook.SendEmailV2()for direct app-driven email send scenarios. - If the email is part of workflow/state transition logic, prefer Power Automate so the send is auditable and survives app closure.
- For calendar events, meeting booking, and room reservation, prefer Power
Automate with Outlook calendar actions such as
Get calendars (V2),Get room lists (V2),Get rooms in room list (V2),Find meeting times (V2), andCreate event (V4).
Office365Outlook.SendEmailV2(
txtTo.Text,
txtSubject.Text,
txtBody.Text
)
C6: If Additional Standard Connectors Are Required, Use Them Deliberately
- Severity: SUGGESTION
- When the user explicitly approves broader connector usage, standard connectors may be used where they are the right platform-native tool.
- Still prefer the simplest supported connector first:
Office365Usersfor peopleOffice365Outlookfor email- Power Automate + Approvals for approval workflow
- Do not introduce premium connectors unless explicitly approved by the user and allowed by the target app architecture.
C7: Official Source References
- Severity: SUGGESTION
- Use these Microsoft references when uncertain:
- Office 365 Users in Power Apps:
https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/connections/connection-office365-users - Office 365 Users connector reference:
https://learn.microsoft.com/en-us/connectors/office365users/ - Office 365 Outlook in Power Apps:
https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/connections/connection-office365-outlook - Office 365 Outlook connector reference:
https://learn.microsoft.com/en-us/connectors/office365/ - Approvals connector reference:
https://learn.microsoft.com/en-us/connectors/approvals/ - Trigger flows from Canvas apps:
https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/using-logic-flows - Approval workflow guidance:
https://learn.microsoft.com/en-us/power-automate/modern-approvals
- Office 365 Users in Power Apps:
- Use this local repo playbook for ready-to-apply examples:
ioicodeapp/canvas-apps/metadata/powerfx/m365-connector-patterns.md
3. SharePoint List Schema — MainDB_IT
3.1 Architecture
The IOI project uses a single wide-column table per department portal with a FormCode discriminator column. All 23+ Domino forms write to the same MainDB_IT list, with form-specific columns prefixed by form code.
IT Portal Site: https://ioioi.sharepoint.com/sites/ioi-portal-it
| List | ListId | Purpose | ItemCount |
|---|---|---|---|
MainDB_IT |
b1de9795-563e-48c3-99a3-1430234dc6e2 |
Primary data store for all IT forms | ~161 |
MainDB_IT_Ext_Support |
37a03d3f-7403-4302-97fc-0d816de938ba |
ITSSR details, ITDR activity logs | ~28 |
MainDB_IT_Ext_Assets |
be6bfd37-3fc4-4ec5-8791-ac5890d0bf3d |
Hardware inventory, server checklist | ~3 |
MainDB_IT_Ext_SAP |
b5b40011-cd99-46f9-91c0-bf8d3a7646de |
SAP change requests, transport, sign-off | ~8 |
MainDB_IT_Ext_Access |
c6bd4df6-b45f-436b-b8d3-0e38dc6049e3 |
EAF, NIR, RS, SFAR, UR, PRF approvals | ~21 |
MainDB_IT_Ext_Infra |
853be955-c0ee-4d76-a23d-47db192f1b21 |
Server reboot, DC access, events, restoration | — |
MainDB_IT_Ext_Docs |
802d2695-ef58-4dd3-ae8d-e693190a6d6d |
IOI Policy docs, IT Info broadcasts | — |
MainDB_IT_Ext_Policy |
bdf68983-9e28-439f-84c7-2c1d52850f6b |
IOIPOL policy form (ext of Ext_Docs) | — |
MainDB_IT_Attachments |
4f831663-1e5f-411f-9044-f50330793452 |
Document library for attachments | — |
MainDB_IT_CR_ApprovalRecord |
— | Change request approval audit trail | — |
MainDB_IT_JHR |
— | Johor IT portal mirror | — |
3.2 MainDB_IT — Core System Columns (All Forms)
These columns exist on EVERY record. Formulas MUST use these exact internal names.
| Internal Name | Display Name | Type | Required | Notes |
|---|---|---|---|---|
Title |
Title | Single line | Yes | Primary identifier |
ID |
ID | Number | Auto | SharePoint auto-generated item ID |
FormCode |
FormCode | Single line | Yes | Discriminator: ITSSR, EAF, HI, NIR, PRF, RS, SFAR, UR, SAPCR, SAPTR, SAPSOF, SAPAMR, SAPCA, SAPDR, SAPLoc, IAL, IOIP, ITI, ITP, ITSC, ITDR, ITDR2 |
CurrentStatus |
CurrentStatus | Choice | Yes | Must access as CurrentStatus.Value — not CurrentStatus alone |
WorkflowStage |
WorkflowStage | Number | — | Numeric workflow step |
SubmittedBy |
SubmittedBy | Person/Group | — | SharePoint Person column |
SubmittedDate |
SubmittedDate | DateTime | — | Submission timestamp |
SubmittedBy_Email |
SubmittedBy Email | Single line | — | Submitter email (text) |
SubmittedBy_Name |
SubmittedBy Name | Single line | — | Submitter display name (text) |
Requestor_Name |
Requestor Name | Person/Group | — | Requestor (Person column) |
Requestor_Email |
Requestor Email | Single line | — | Requestor email (text) |
CurrentApprover_Email |
Current Approver Email | Single line | — | Active approver email |
ApprovedBy_Email |
Approved By Email | Single line | — | Final approver email |
ApprovedBy_Name |
Approved By Name | Single line | — | Final approver name |
Subject |
Subject | Single line | — | Ticket/request subject |
Company |
Company | Choice | — | Company entity |
Department |
Department | Single line | — | Department name |
Site |
Site | Choice | — | Johor, Penang, Prai, KL, Both |
EnvironmentTag |
EnvironmentTag | Choice | — | Production, UAT, Development |
IsLocked |
IsLocked | Yes/No | — | Record lock flag |
Remarks |
Remarks | Multiple lines | — | General remarks |
Comments |
Comments | Multiple lines | — | Comments history |
CurrentAction |
CurrentAction | Single line | — | Current workflow action |
FinalStatus |
FinalStatus | Single line | — | Terminal status |
INO |
INO | Single line | — | Internal reference number |
LastModifiedBy |
LastModifiedBy | Single line | — | Last editor |
WorkflowAuditJson |
WorkflowAuditJson | Multiple lines | — | JSON audit trail |
Created |
Created | DateTime | Auto | SharePoint created timestamp |
Modified |
Modified | DateTime | Auto | SharePoint modified timestamp |
Author |
Created By | Person/Group | Auto | SharePoint Author |
Editor |
Modified By | Person/Group | Auto | SharePoint Editor |
3.3 CurrentStatus Choice Values
Formulas MUST use .Value to access Choice column values.
Active, Approved, Closed, Draft, Sent, Verified, Withdrawn,
Pending ABAPER, Pending Acceptance, Pending Approval A, Pending Approval B,
Pending Authority 1, Pending Authority 2, Pending BASIS,
Pending Department Head, Pending Director, Pending ED Approval,
Pending IT Approval, Pending IT Manager, Pending ISG, Pending Review,
In Progress, Submitted, Accepted, Completed, Denied,
Open, Rescheduled, Overdue, On Hold, Cancelled
IMPORTANT: Status values vary by form. Always use
Coalesce()to handle missing values:Coalesce(ThisRecord.CurrentStatus.Value, ThisRecord.Status.Value, "Submitted")
3.4 Form-Specific Prefix Columns (MainDB_IT)
Each form stores its unique columns in MainDB_IT with a prefix matching the FormCode.
ITSSR (IT Support Service Request)
| Column | Type | Description |
|---|---|---|
ITSSR_DateAccepted |
Date/Time | Date ticket accepted |
ITSSR_ITRemarks |
Multiple lines | IT support remarks |
ITSSR also uses:
MainDB_IT_Ext_Support(30+ columns) — see §3.5
EAF (External Access Form)
| Column | Type | Description |
|---|---|---|
EAF_Application |
Single line | Target system name |
EAF_ClientID |
Single line | SAP client or system ID |
EAF_UserGroup |
Single line | User group assignment |
EAF_HigherApproverEmail |
Single line | Escalation approver |
EAF_DDAppApprovedBy |
Single line | Department director approver |
EAF_DDAppComment |
Multiple lines | Director comment |
EAF_DDAppDate |
Date/Time | Director approval date |
EAF_DDAppStatus |
Single line | Director approval status |
EAF_DeptHeadComment |
Multiple lines | Department head comment |
EAF_DeptHeadDate |
Date/Time | Department head date |
EAF_DeptHeadEmail |
Single line | Department head email |
EAF_DeptHeadStatus |
Single line | Department head status |
EAF_IsPCN |
Yes/No | Is PCN required |
EAF_ITCompletedBy |
Single line | IT completion person |
EAF_ITCompletedDate |
Date/Time | IT completion date |
EAF_ITCompletionStatus |
Single line | IT completion status |
EAF_ITManagerApprovedBy |
Single line | IT manager approver |
EAF_ITManagerComment |
Multiple lines | IT manager comment |
EAF_ITManagerDate |
Date/Time | IT manager approval date |
EAF_ITManagerStatus |
Single line | IT manager status |
EAF_Justification |
Multiple lines | Business justification |
EAF_ReminderTo |
Single line | Reminder recipient |
EAF_SystemName |
Single line | System name |
EAF_TargetUserEmail |
Single line | Target user email |
EAF_CC |
Single line | CC recipients |
EAF_ITComment |
Multiple lines | IT admin comment |
EAF_ITConfigRemarks |
Multiple lines | IT configuration remarks |
EAF_ITConfigStatus |
Single line | IT configuration status |
HI (Hardware Inventory)
| Column | Type | Description |
|---|---|---|
HI_TagNo |
Single line | Asset tag number |
HI_AssetNo |
Single line | Asset number |
HI_Type |
Choice | Computer type |
HI_ComputerName |
Single line | Machine name |
HI_Company |
Single line | Owning company |
HI_UsedBy_Email |
Person/Group | Assigned user |
HI_Location |
Single line | Physical location |
HI_Department |
Single line | Department |
HI_SerialNo |
Single line | Serial number |
HI_PurchaseDate |
Date/Time | Purchase date |
HI_Vendor |
Single line | Vendor name |
HI_Status |
Single line | Asset status |
HI_Year |
Number | Year |
HI_Month |
Number | Month |
HI_PONumber |
Single line | PO reference |
HI_WarrantyExpiry |
Date/Time | Warranty end date |
HI_Condition |
Single line | Physical condition |
HI_Specifications |
Multiple lines | Hardware specs |
HI_PurchasePrice |
Number | Purchase cost |
NIR (Notes ID Request)
| Column | Type | Description |
|---|---|---|
NIR_FullName |
Single line | Requestor full name |
NIR_Department |
Single line | Department |
NIR_RequestType |
Single line | Request type |
NIR_HODApprovalStatus |
Single line | HOD approval status |
NIR_HODApprovedBy |
Single line | HOD approver |
NIR_HODApprovedDate |
Date/Time | HOD approval date |
NIR_NotesAdminStatus |
Single line | Notes admin status |
NIR_NotesAdminBy |
Single line | Notes admin |
NIR_NotesAdminDate |
Date/Time | Notes admin date |
NIR_ITHardwareStatus |
Single line | IT hardware status |
NIR_ITHardwareBy |
Single line | IT hardware person |
NIR_EmployeeNumber |
Single line | Employee ID |
NIR_Designation |
Single line | Job title |
NIR_PhoneExtension |
Single line | Phone ext |
NIR_ExistingEmailAddress |
Single line | Current email |
NIR_EmployeeType |
Single line | Employee type |
PRF (Program Request Form)
| Column | Type | Description |
|---|---|---|
PRF_RequestNo |
Single line | Request number |
PRF_RequestType |
Single line | Request type |
PRF_IsSAP |
Yes/No | Is SAP related |
PRF_SAPClient |
Single line | SAP client |
PRF_SAPModule |
Single line | SAP module |
PRF_Department |
Single line | Department |
PRF_Priority |
Single line | Priority level |
PRF_Deadline |
Date/Time | Target date |
PRF_PhoneExt |
Single line | Phone extension |
PRF_CCEmails |
Single line | CC email list |
PRF_Objective |
Multiple lines | Project objective |
PRF_Justification |
Multiple lines | Business justification |
PRF_CurrentProcess |
Multiple lines | Current workflow |
PRF_ExpectedOutcome |
Multiple lines | Expected results |
PRF_DeptManager_Email |
Single line | Department manager email |
PRF_ITApproved_Email |
Single line | IT approver email |
PRF_ITApprovedDate |
Date/Time | IT approval date |
RS (Reset Password)
| Column | Type | Description |
|---|---|---|
RS_UserName |
Single line | Target username |
RS_Designation |
Single line | Job title |
RS_Company |
Single line | Company |
RS_Department |
Single line | Department |
RS_Location |
Single line | Location |
RS_ResetType |
Single line | Reset type |
RS_ReasonForReset |
Multiple lines | Reason |
RS_BankTokenSerial |
Single line | Bank token serial |
RS_ExecutiveDirectorEmail |
Single line | ED email |
RS_SAPClient |
Single line | SAP client |
RS_IEPClientName |
Single line | IEP client |
RS_AssignedPICEmail |
Single line | Assigned PIC email |
RS_TargetUser_Email |
Single line | Target user email |
RS_RequestType |
Single line | Request type |
RS_NeedsEDApproval |
Yes/No | Needs ED approval |
RS_ITProcessedBy |
Single line | IT processor |
RS_ITProcessedDate |
Date/Time | IT process date |
RS_EDApprovedBy |
Single line | ED approver |
RS_EDApprovedDate |
Date/Time | ED approval date |
SFAR (Share Folder Access Request)
| Column | Type | Description |
|---|---|---|
SFAR_Company |
Single line | Company |
SFAR_Department |
Single line | Department |
SFAR_Extension |
Single line | Phone extension |
SFAR_FolderType |
Single line | Folder type |
SFAR_ServerName |
Single line | Server name |
SFAR_RequestType |
Single line | Request type |
SFAR_HODEmail |
Single line | HOD email |
SFAR_Owner |
Single line | Folder owner |
SFAR_AccessTo |
Single line | Access grantee |
SFAR_AccessToName |
Single line | Grant name |
SFAR_Purpose |
Multiple lines | Purpose |
SFAR_Justification |
Multiple lines | Justification |
SFAR_FolderPath |
Single line | Network path |
SFAR_AccessLevel |
Single line | Access level |
SFAR_ReviewedBy |
Single line | Reviewer |
SFAR_ReviewedDate |
Date/Time | Review date |
UR (User Registration)
| Column | Type | Description |
|---|---|---|
UR_RequestType |
Single line | Request type |
UR_EmployeeNumber |
Single line | Employee ID |
UR_Designation |
Single line | Job title |
UR_Company |
Single line | Company |
UR_Division |
Single line | Division |
UR_Extension |
Single line | Phone extension |
UR_EmailAddress |
Single line | |
UR_BankName |
Single line | Bank name |
UR_BankUserEmail |
Single line | Bank user email |
UR_Plant |
Single line | Plant location |
UR_UserFullName |
Single line | User full name |
UR_UserDepartment |
Single line | User department |
UR_SystemAccess |
Single line | System access list |
UR_ITAdminBy |
Single line | IT admin person |
UR_ITAdminDate |
Date/Time | IT admin date |
3.5 Extension List: MainDB_IT_Ext_Support (ITSSR Detail)
Used by ITSSR form. Link to parent via ParentID (Lookup → MainDB_IT).
| Column | Type | Description |
|---|---|---|
ParentID |
Lookup (→MainDB_IT) | Parent record link |
ParentFormCode |
Single line | Parent form code |
ParentSite |
Single line | Parent site |
ITSSR_CaseNo |
Single line | Case number |
ITSSR_ServiceType |
Choice | Service type |
ITSSR_ProblemCategory |
Choice | Problem category |
ITSSR_ProblemDescription |
Multiple lines | Problem description |
ITSSR_ReportedBy_Email |
Single line | Reporter email |
ITSSR_AssignedTo_Email |
Single line | Assignee email |
ITSSR_SupportMethod |
Choice | Support method |
ITSSR_Solution |
Multiple lines | Solution text |
ITSSR_SatisfactionRating |
Number | Rating (1-5) |
ITSSR_Department |
Single line | Department |
ITSSR_Extension |
Single line | Phone extension |
ITSSR_ServiceType2 |
Single line | Service type 2 |
ITSSR_Hardware |
Single line | Hardware type |
ITSSR_Hardware2 |
Single line | Hardware type 2 |
ITSSR_Application |
Single line | Application name |
ITSSR_Module |
Single line | Module |
ITSSR_SAPModule |
Single line | SAP module |
ITSSR_BankModule |
Single line | Bank module |
ITSSR_CC |
Single line | CC recipients |
ITSSR_ITRemarks |
Multiple lines | IT remarks |
ITSSR_DateNotified |
Single line | Notification date |
ITSSR_DateClosed |
Single line | Closure date |
ITSSR_ITName |
Single line | IT staff name |
ITSSR_ProblemCategory2 |
Single line | Category 2 |
ITSSR_COOApproval |
Single line | COO approval |
ITSSR_HWComment |
Single line | HW comment |
ITSSR_VerifiedBy |
Single line | Verifier |
ITSSR_VerificationDate |
Single line | Verification date |
ITSSR_VerificationStatus |
Single line | Verification status |
ITSSR_ManagerBy |
Single line | Manager person |
ITSSR_ManagerDate |
Single line | Manager date |
ITSSR_ManagerComment |
Multiple lines | Manager comment |
ITSSR_ManagerStatus |
Single line | Manager status |
ITSSR_COOBy |
Single line | COO person |
ITSSR_COODate |
Single line | COO date |
ITSSR_COOComment |
Multiple lines | COO comment |
ITSSR_COOStatus |
Single line | COO status |
ITSSR_RequestorComment |
Multiple lines | Requestor comment |
ITSSR_PendingDate |
Single line | Pending date |
ITSSR_OU |
Single line | Organizational unit |
ITSSR_Type2 |
Single line | Type 2 |
ITSSR_SendTo_Email |
Single line | Send-to email |
3.6 Extension List: MainDB_IT_Ext_Assets (Hardware)
| Column | Type | Description |
|---|---|---|
ParentID |
Lookup (→MainDB_IT) | Parent record link |
ParentFormCode |
Single line | Parent form code |
HI_MachineID |
Single line | Machine ID |
HI_TagNo |
Single line | Tag number |
HI_AssetNo |
Single line | Asset number |
HI_Type |
Single line | Asset type |
HI_ComputerName |
Single line | Computer name |
HI_Company |
Single line | Company |
HI_UsedBy_Email |
Person/Group | Assigned user |
HI_Location |
Single line | Location |
HI_Department |
Single line | Department |
HI_WinVersion |
Single line | Windows version |
HI_OfficeVersion |
Single line | Office version |
HI_SerialNo |
Single line | Serial number |
HI_Vendor |
Single line | Vendor |
HI_Status |
Single line | Status |
HI_Year |
Number | Year |
HI_Month |
Number | Month |
HI_Model |
Single line | Model |
HI_CPUType |
Single line | CPU type |
HI_CPUSerialNo |
Single line | CPU serial |
HI_RAMSize |
Single line | RAM size |
HI_RAMType |
Single line | RAM type |
HI_MonitorModel |
Single line | Monitor model |
HI_MonitorSize |
Single line | Monitor size |
HI_MonitorType |
Single line | Monitor type |
HI_HDDSize |
Single line | HDD size |
HI_HDDType |
Single line | HDD type |
HI_PONumber |
Single line | PO number |
HI_PurchasePrice |
Number | Purchase price |
HI_PurchaseDate |
Date/Time | Purchase date |
HI_WarrantyExpiry |
Date/Time | Warranty expiry |
HI_Condition |
Single line | Condition |
HI_Specifications |
Multiple lines | Specifications |
HI_Site |
Single line | Site |
HI_Building |
Single line | Building |
HI_Floor |
Single line | Floor |
HI_Room |
Single line | Room |
3.7 Extension List: MainDB_IT_Ext_Access (EAF/NIR/RS/SFAR/UR/PRF Approvals)
| Column | Type | Description |
|---|---|---|
ParentID |
Lookup (→MainDB_IT) | Parent record link |
ParentFormCode |
Single line | Parent form code |
EAF_Application |
Single line | Application name |
EAF_ClientID |
Single line | Client ID |
EAF_UserGroup |
Single line | User group |
EAF_HigherApproverEmail |
Single line | Higher approver |
EAF_DDAppApprovedBy |
Single line | DD approver |
EAF_DDAppComment |
Multiple lines | DD comment |
EAF_DDAppDate |
Date/Time | DD date |
EAF_DDAppStatus |
Single line | DD status |
EAF_DeptHeadComment |
Multiple lines | Dept head comment |
EAF_DeptHeadDate |
Date/Time | Dept head date |
EAF_DeptHeadEmail |
Single line | Dept head email |
EAF_DeptHeadStatus |
Single line | Dept head status |
EAF_IsPCN |
Yes/No | PCN required |
EAF_ITCompletedBy |
Single line | IT completed by |
EAF_ITCompletedDate |
Date/Time | IT completed date |
EAF_ITCompletionStatus |
Single line | IT completion status |
EAF_ITManagerApprovedBy |
Single line | IT manager |
EAF_ITManagerComment |
Multiple lines | IT manager comment |
EAF_ITManagerDate |
Date/Time | IT manager date |
EAF_ITManagerStatus |
Single line | IT manager status |
EAF_Justification |
Multiple lines | Justification |
NIR_FullName |
Single line | Full name |
NIR_Department |
Single line | Department |
NIR_RequestType |
Single line | Request type |
NIR_HODApprovalStatus |
Single line | HOD status |
NIR_HODApprovedBy |
Single line | HOD approver |
NIR_HODApprovedDate |
Date/Time | HOD date |
NIR_NotesAdminStatus |
Single line | Notes admin status |
NIR_NotesAdminBy |
Single line | Notes admin |
NIR_NotesAdminDate |
Date/Time | Notes admin date |
NIR_ITHardwareStatus |
Single line | IT HW status |
NIR_ITHardwareBy |
Single line | IT HW person |
PRF_Status1–PRF_Status4 |
Single line | Approval stages |
PRF_FinalStatus |
Single line | Final status |
PRF_DateApp1–PRF_DateApp4 |
Date/Time | Approval dates |
PRF_DeptHead |
Single line | Department head |
PRF_ISG |
Single line | ISG reviewer |
PRF_Comments1 |
Multiple lines | Comments stage 1 |
PRF_ITReason |
Multiple lines | IT reason |
3.8 Extension List: MainDB_IT_Ext_SAP
| Column | Type | Description |
|---|---|---|
ParentID |
Lookup (→MainDB_IT) | Parent record link |
ParentFormCode |
Single line | Parent form code |
SAP_TRNumber |
Single line | Transport request |
SAP_Client |
Single line | SAP client |
SAP_Plant |
Single line | SAP plant |
SAP_Module |
Single line | SAP module |
SAP_ReviewedBy |
Single line | Reviewer |
SAP_Remarks |
Multiple lines | Remarks |
SAP_ReviewedDate_dt |
Date/Time | Review date |
SAPSOF_CurrentStage |
Single line | Current stage |
SAPSOF_IsBPORequired |
Single line | BPO required |
SAPSOF_FinalDecision |
Single line | Final decision |
SAPSOF_TRNumber |
Single line | TR number |
SAPTR_Category |
Single line | Category |
SAPTR_DevCategory |
Single line | Dev category |
SAPTR_AppStatus |
Single line | Approval status |
SAPTR_ApprovedBy |
Single line | Approver |
SAPTR_ApprovedDate |
Date/Time | Approval date |
SAPCR_BPOEmail |
Single line | BPO email |
SAPCR_PMEmail |
Single line | PM email |
SAPCR_DeveloperEmail |
Single line | Developer email |
SAPCR_DirectorEmail |
Single line | Director email |
SAPAMR_TBVEmail |
Single line | To-be-verified email |
SAPAMR_TBAEmail |
Single line | To-be-approved email |
SAPAMR_TBV1Email–SAPAMR_TBV5Email |
Single line | Verifier emails |
3.9 Extension List: MainDB_IT_Ext_Infra
| Column | Type | Description |
|---|---|---|
IAL1_ServerName |
Single line | Server name |
IAL1_RebootReason |
Single line | Reboot reason |
IAL1_RebootDate |
Date/Time | Reboot date |
IAL1_RebootedBy |
Single line | Reboot person |
IAL1_DowntimeDuration |
Single line | Downtime |
IAL2_ServerRoom |
Single line | Server room |
IAL2_AccessDate |
Date/Time | Access date |
IAL2_TimeIn |
Single line | Time in |
IAL2_VisitorName |
Single line | Visitor |
IAL2_VisitorCompany |
Single line | Visitor company |
IAL2_AccessReason |
Single line | Access reason |
IAL2_AttendedByPIC |
Single line | PIC |
IAL3_EventType |
Single line | Event type |
IAL3_EventDescription |
Multiple lines | Event description |
IAL3_EventStartDate |
Date/Time | Start date |
IAL3_EventEndDate |
Date/Time | End date |
IAL3_PreparedBy |
Single line | Prepared by |
IAL4_ServerName |
Single line | Server name |
IAL4_RecordType |
Single line | Record type |
IAL4_RootCause |
Multiple lines | Root cause |
IAL4_CorrectiveActions |
Multiple lines | Corrective actions |
IAL5_RestorePath |
Single line | Restore path |
IAL5_RequestedFiles |
Single line | Requested files |
IAL5_RestorationStatus |
Single line | Status |
3.10 Extension List: MainDB_IT_Ext_Docs
| Column | Type | Description |
|---|---|---|
IOIP_PolicyNo |
Single line | Policy number |
IOIP_Subject |
Single line | Policy subject |
IOIP_ReviNum |
Single line | Revision number |
IOIP_DateIssue |
Date/Time | Issue date |
IOIP_Body |
Multiple lines | Policy body |
IOIP_DocTitle |
Single line | Document title |
IOIP_FinalStatus |
Single line | Final status |
IOIP_DateArchived |
Date/Time | Archive date |
IOIP_DistributionList |
Single line | Distribution list |
IOIP_Editors |
Single line | Editors |
IOIP_Authors |
Single line | Authors |
ITI_BroadcastType |
Single line | Broadcast type |
ITI_AudienceGroups |
Single line | Audience groups |
4. Reference / Config Lists
These lists provide lookup data and configuration.
| List | Purpose | Key Columns |
|---|---|---|
user_roles_it |
IT user role assignments | Role, UserEmail, Department |
userroles |
Global role definitions | RoleName, Permissions |
userprofiles |
User profile data | Name, Email, Department, Site |
ref_departments |
Department lookup | DeptCode, DeptName, Site |
ref_companylist |
Company lookup | CompanyCode, CompanyName |
workflowauditlog |
Workflow audit trail | FormCode, RecordID, Action, Actor, Timestamp |
config_approvermatrix |
Approver routing | FormCode, Stage, ApproverEmail, Condition |
config_appsettings_{dept} |
Per-dept settings | Key, Value |
config_companies |
Company config | CompanyCode, CompanyName, Site |
config_departments |
Department config | DeptCode, DeptName, Manager |
config_employeedirectory |
Employee directory | EmployeeID, Name, Email, Dept, Ext |
config_globalaccessroles |
Global access roles | RoleName, Description |
config_globaluserroleassignments |
User↔role mapping | UserEmail, RoleName |
config_notesadminrouting |
Notes admin routing | RoutingEmail, Priority |
it_routingmatrix |
IT approval routing | FormCode, Stage, ApproverEmail |
itforms |
Form registry | FormCode, FormTitle, Department, ScreenPrefix |
approvermatrix |
Approver matrix | ApproverEmail, Role, Department |
approvalrecords |
Approval audit | RecordID, Action, Actor, Timestamp, Comment |
referencecounter_{dept} |
Auto-number sequences | Prefix, LastNumber |
routinglist_{dept} |
Per-dept routing | Stage, ApproverEmail |
routepermissions |
Route permissions | Route, Role, Permission |
sla_workingcalendar_{dept} |
SLA calendars | Date, IsWorkingDay, HolidayName |
notificationlog_{dept} |
Email notification log | Recipient, Subject, SentDate, Status |
auditlog_{dept} |
Audit log | RecordID, Action, Actor, Timestamp, Details |
opslog_{dept} |
Operations log | Entry, Timestamp, Actor |
it_m1_rs_banks |
Bank list for RS | BankCode, BankName |
it_m1_rs_sap_client |
SAP client list for RS | ClientCode, ClientName |
it_m1_rs_systemslist |
Systems list for RS | SystemCode, SystemName |
it_m1_sfar_servers |
Server list for SFAR | ServerName, IPAddress, Location |
5. Multi-Department Portal Schemas
Each department has its own SharePoint site with MainDB_{DEPT} + extension lists.
| Dept Code | Department | Site URL | Main List |
|---|---|---|---|
IT |
Information Technology | ioi-portal-it |
MainDB_IT |
HR |
Human Resources | ioi-portal-hr |
MainDB_HR |
FIN |
Finance | ioi-portal-fin |
MainDB_FIN |
ENG |
Engineering | ioi-portal-eng |
MainDB_ENG |
PRD |
Production | ioi-portal-prd |
MainDB_PRD |
STR |
Stores | ioi-portal-str |
MainDB_STR |
SHE |
Safety, Health & Environment | ioi-portal-she |
MainDB_SHE |
QA |
Quality Assurance | ioi-portal-qa |
MainDB_QA |
QC |
Quality Control | ioi-portal-qc |
MainDB_QC |
PUR |
Purchasing | ioi-portal-pur |
MainDB_PUR |
MKT |
Marketing | ioi-portal-mkt |
MainDB_MKT |
LOG |
Logistics | ioi-portal-log |
MainDB_LOG |
MTN |
Maintenance | ioi-portal-mtn |
MainDB_MTN |
EI |
Energy & Instrument | ioi-portal-ei |
MainDB_EI |
SEC |
Security | ioi-portal-sec |
MainDB_SEC |
PBI |
PBI | ioi-portal-pbi |
MainDB_PBI |
RD |
R&D | ioi-portal-rd |
MainDB_RD |
SA |
Sales | ioi-portal-sa |
MainDB_SA |
ADM |
Admin | ioi-portal-adm |
MainDB_ADM |
POM |
POM | ioi-portal-pom |
MainDB_POM |
PRC |
PRC | ioi-portal-prc |
MainDB_PRC |
6. Formula Patterns — MUST Use These Exact Patterns
F6: Filtering by FormCode
- Severity: CRITICAL
- EVERY query to MainDB_IT MUST include
FormCode = "{code}"as the FIRST filter condition - NEVER query MainDB_IT without a FormCode filter — it returns all 23+ forms' data
# CORRECT
Items: =Filter(MainDB_IT, FormCode = "ITSSR")
# CORRECT — multi-condition
Items: =Filter(MainDB_IT, FormCode = "ITSSR" && Coalesce(CurrentStatus.Value, Status.Value) = "Active")
# WRONG — returns all forms
Items: =MainDB_IT
F7: Accessing Choice Columns
- Severity: CRITICAL
- Choice columns MUST be accessed with
.Value— direct reference returns the choice object, not the text
# CORRECT
Text: =ThisItem.CurrentStatus.Value
# WRONG — returns object, not text
Text: =ThisItem.CurrentStatus
F8: Safe Column Access with Coalesce
- Severity: IMPORTANT
- Use
Coalesce()when a column might be blank to provide fallback values - This is critical because not all forms populate all columns
# CORRECT — safe fallback chain
Text: =Coalesce(ThisRecord.Subject, ThisRecord.Title, Text("ITSSR-" & ThisRecord.ID))
# CORRECT — safe status with fallback
Text: =Coalesce(ThisRecord.CurrentStatus.Value, ThisRecord.Status.Value, "Submitted")
F9: Patch — Update Existing Record
- Severity: CRITICAL
- Use
Patch(MainDB_IT, ThisItem, { ... })to update the current record - Choice columns MUST be updated as
{ Value: "NewStatus" }objects
OnSelect: |-
=Patch(MainDB_IT, ThisItem, {
CurrentStatus: { Value: "Approved" },
ApprovedBy_Email: Lower(User().Email),
ApprovedBy_Name: User().FullName,
Remarks: txtRemarks.Text
});
Notify("Record approved.", NotificationType.Success);
Back()
F10: Patch — Create New Record
- Severity: CRITICAL
- Use
Patch(MainDB_IT, Defaults(MainDB_IT), { ... })to create new records - Always include
FormCode,CurrentStatus, and required columns
OnSelect: |-
=Patch(MainDB_IT, Defaults(MainDB_IT), {
Title: txtSubject.Text,
FormCode: "ITSSR",
CurrentStatus: { Value: "Submitted" },
SubmittedBy_Email: Lower(User().Email),
SubmittedBy_Name: User().FullName,
SubmittedDate: Now(),
Department: txtDepartment.Text,
Subject: txtSubject.Text,
Requestor_Email: Lower(User().Email),
Requestor_Name: { '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser", Claims: "i:0#.f|membership|" & Lower(User().Email), DisplayName: User().FullName, Email: Lower(User().Email) }
});
Notify("Ticket created.", NotificationType.Success)
F11: LookUp — Find Single Record
- Severity: IMPORTANT
- Use
LookUp(notFirst(Filter(...))) when you need one record - More efficient and cleare
*Truncated - read the full file at https://github.com/migoamigoea-star/ioi-docs-uploads/blob/a1b8baaa6c43f0a06fd8cd7602abeebdf46a14dc/.github/instructions/canvas-powerfx-formulas.instructions.md.