[{"data":1,"prerenderedAt":323},["ShallowReactive",2],{"/docs/base/jobs-base/server-exports/training":3,"/docs/base/jobs-base/server-exports/training-surround":309,"/docs/base/jobs-base/server-exports/training-implemented-suggestions":322},{"id":4,"title":5,"body":6,"description":298,"extension":299,"head":300,"implementedSuggestions":300,"meta":301,"navigation":302,"path":304,"schemaOrg":300,"seo":305,"sitemap":306,"stem":307,"__hash__":308},"docs/1.docs/base/2.jobs-base/4.server-exports/2.training.md","Training",{"type":7,"value":8,"toc":291},"minimark",[9,14,18,26,33,119,187,197,203,206,266,272,276,279,287],[10,11,13],"h2",{"id":12},"supported-server-integration-boundary","Supported server integration boundary",[15,16,17],"p",{},"Training catalogue and record mutations are intentionally kept inside the server-authoritative app\nworkflow. External server resources can verify the same Boss Menu permissions and tablet restriction\nused by the app before exposing related functionality.",[19,20,22],"h3",{"id":21},"hasjobpermissionplayerid-permission-jobname",[23,24,25],"code",{},"hasJobPermission(playerId, permission, jobName?)",[15,27,28,29,32],{},"Checks the actor's current grade permission, including the global ",[23,30,31],{},"ALL"," permission.",[34,35,41],"pre",{"className":36,"code":37,"filename":38,"language":39,"meta":40,"style":40},"language-lua shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","local canViewTrainingRecords = exports[\"sky_jobs_base\"]:hasJobPermission(\n    source,\n    1003, -- Config.Training.permissions.viewRecords by default\n    \"police\"\n)\n","server.lua","lua","",[23,42,43,81,87,101,113],{"__ignoreMap":40},[44,45,48,52,56,59,62,65,69,71,74,78],"span",{"class":46,"line":47},"line",1,[44,49,51],{"class":50},"sMK4o","local",[44,53,55],{"class":54},"sTEyZ"," canViewTrainingRecords ",[44,57,58],{"class":50},"=",[44,60,61],{"class":54}," exports[",[44,63,64],{"class":50},"\"",[44,66,68],{"class":67},"sfazB","sky_jobs_base",[44,70,64],{"class":50},[44,72,73],{"class":54},"]:",[44,75,77],{"class":76},"s2Zo4","hasJobPermission",[44,79,80],{"class":54},"(\n",[44,82,84],{"class":46,"line":83},2,[44,85,86],{"class":54},"    source,\n",[44,88,90,94,97],{"class":46,"line":89},3,[44,91,93],{"class":92},"sbssI","    1003",[44,95,96],{"class":54},", ",[44,98,100],{"class":99},"sHwdD","-- Config.Training.permissions.viewRecords by default\n",[44,102,104,107,110],{"class":46,"line":103},4,[44,105,106],{"class":50},"    \"",[44,108,109],{"class":67},"police",[44,111,112],{"class":50},"\"\n",[44,114,116],{"class":46,"line":115},5,[44,117,118],{"class":54},")\n",[120,121,122,138],"table",{},[123,124,125],"thead",{},[126,127,128,132,135],"tr",{},[129,130,131],"th",{},"Argument",[129,133,134],{},"Type",[129,136,137],{},"Description",[139,140,141,157,172],"tbody",{},[126,142,143,149,154],{},[144,145,146],"td",{},[23,147,148],{},"playerId",[144,150,151],{},[23,152,153],{},"number",[144,155,156],{},"Online player source whose authoritative job and grade are checked",[126,158,159,164,169],{},[144,160,161],{},[23,162,163],{},"permission",[144,165,166],{},[23,167,168],{},"number | string",[144,170,171],{},"Training permission ID or a standard Jobs Base permission key",[126,173,174,179,184],{},[144,175,176],{},[23,177,178],{},"jobName",[144,180,181],{},[23,182,183],{},"string?",[144,185,186],{},"Optional exact job requirement",[15,188,189,193,194],{},[190,191,192],"strong",{},"Returns:"," ",[23,195,196],{},"boolean",[19,198,200],{"id":199},"istabletapprestrictedforplayerplayerid-appkey",[23,201,202],{},"isTabletAppRestrictedForPlayer(playerId, appKey)",[15,204,205],{},"Checks the Boss Menu tablet-app restriction for a player grade.",[34,207,209],{"className":36,"code":208,"filename":38,"language":39,"meta":40,"style":40},"local hidden = exports[\"sky_jobs_base\"]:isTabletAppRestrictedForPlayer(source, \"training\")\nif hidden then\n    return\nend\n",[23,210,211,245,256,261],{"__ignoreMap":40},[44,212,213,215,218,220,222,224,226,228,230,233,236,238,241,243],{"class":46,"line":47},[44,214,51],{"class":50},[44,216,217],{"class":54}," hidden ",[44,219,58],{"class":50},[44,221,61],{"class":54},[44,223,64],{"class":50},[44,225,68],{"class":67},[44,227,64],{"class":50},[44,229,73],{"class":54},[44,231,232],{"class":76},"isTabletAppRestrictedForPlayer",[44,234,235],{"class":54},"(source, ",[44,237,64],{"class":50},[44,239,240],{"class":67},"training",[44,242,64],{"class":50},[44,244,118],{"class":54},[44,246,247,251,253],{"class":46,"line":83},[44,248,250],{"class":249},"s7zQu","if",[44,252,217],{"class":54},[44,254,255],{"class":249},"then\n",[44,257,258],{"class":46,"line":89},[44,259,260],{"class":249},"    return\n",[44,262,263],{"class":46,"line":103},[44,264,265],{"class":249},"end\n",[15,267,268,193,270],{},[190,269,192],{},[23,271,196],{},[10,273,275],{"id":274},"no-public-training-mutation-export","No public Training mutation export",[15,277,278],{},"Course, session, enrollment, result, qualification, and audit mutations are not public exports. This\nkeeps identity resolution, state transitions, cooldowns, permissions, and database transactions on\none canonical path.",[280,281,284],"callout",{"color":282,"icon":283},"success","i-lucide-shield-check",[15,285,286],{},"Server exports cannot be called directly by a FiveM client, but an integrating server resource must\nstill validate any client-facing event before it calls an export. Never treat a source, job,\nidentifier, grade, or permission supplied in a client payload as trusted.",[288,289,290],"style",{},"html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}",{"title":40,"searchDepth":47,"depth":83,"links":292},[293,297],{"id":12,"depth":83,"text":13,"children":294},[295,296],{"id":21,"depth":89,"text":25},{"id":199,"depth":89,"text":202},{"id":274,"depth":83,"text":275},"Server-side access checks for integrations that accompany the Jobs Base Training App.","md",null,{},{"icon":303},"i-lucide-graduation-cap","/docs/base/jobs-base/server-exports/training",{"title":5,"description":298},{"loc":304},"1.docs/base/2.jobs-base/4.server-exports/2.training","bbp80fG5HldTWgV-gy8PkNgjhSyh1Ys1o2Vy7lJBMP0",[310,316],{"title":311,"path":312,"stem":313,"description":314,"icon":315,"children":-1},"Emergency Dispatch","/docs/base/jobs-base/server-exports/emergency-dispatch","1.docs/base/2.jobs-base/4.server-exports/1.emergency-dispatch","Public server-side exports for creating, checking, and removing Emergency Dispatch incidents.","i-lucide-siren",{"title":317,"path":318,"stem":319,"children":-1,"description":320,"icon":321},"Client Events","/docs/base/jobs-base/client-events","1.docs/base/2.jobs-base/5.client-events","Client-side events provided by sky_jobs_base that other resources can listen to.","i-lucide-radio",[],1786395271368]