Agent skill

Crud Page

by lin-97 in lin-97/gi-demo

在本模板项目中创建或修改 CRUD 列表页、表格列、搜索区、表单弹窗。使用 GiPageLayout、useTable、GiButton、a-table、GiForm、useDict 时加载本技能。

Apache-2.0Auto-check passed

Install Crud Page

skills CLI
$ npx skills add lin-97/gi-demo --skill crud-page -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install lin-97/gi-demo crud-page --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/lin-97/gi-demo.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/crud-page .claude/skills/crud-page && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
crud-page
GitHub stars
188
Token cost
~1.3k tokens
SKILL.md length
112 words
Files
1
Skills in repo
3
Repo updated
First seen
Licence
Apache-2.0

At a glance

在本模板项目中创建或修改 CRUD 列表页、表格列、搜索区、表单弹窗。使用 GiPageLayout、useTable、GiButton、a-table、GiForm、useDict 时加载本技能。

  • SKILL.md covers 标准页面结构, useTable 用法, GiButton 预设类型 and 表格列(TSX), plus 5 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Crud Page is an agent skill from lin-97/gi-demo. 在本模板项目中创建或修改 CRUD 列表页、表格列、搜索区、表单弹窗。使用 GiPageLayout、useTable、GiButton、a-table、GiForm、useDict 时加载本技能。

Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

The repository describes itself as: A Vue3 Admin Template. The licence is Apache-2.0.

Example prompts

  • “/crud-page”

What it can do on your machine

Read from SKILL.md and the folder at commit d1e310a. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are typescript and vue).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Crud Page loads about 1.3k tokens when it runs. Until then it costs about 27 tokens; SKILL.md has 112 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~27
When it runs · the whole SKILL.md, loaded when a task matches
~1.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from lin-97/gi-demo at commit d1e310a, republished under its Apache-2.0 licence (© lin-97). 112 words, ~1,296 tokens.

Download SKILL.mdSave it as .claude/skills/crud-page/SKILL.md (or your agent's skills folder).
name
crud-page
description
在本模板项目中创建或修改 CRUD 列表页、表格列、搜索区、表单弹窗。使用 GiPageLayout、useTable、GiButton、a-table、GiForm、useDict 时加载本技能。

CRUD 列表页开发

标准页面结构

vue
<template>
  <GiPageLayout margin collapsed>
    <template #left><!-- 可选:树/分类 --></template>

    <a-row justify="space-between" class="g-row-tool">
      <a-space wrap>
        <GiButton type="add" @click="onAdd" />
        <GiButton type="delete" @click="onBatchDelete" />
      </a-space>
      <a-space wrap>
        <!-- 搜索表单项 -->
        <GiButton type="search" @click="search" />
        <GiButton type="reset" @click="reset" />
      </a-space>
    </a-row>

    <a-table
      class="g-table"
      row-key="id"
      :loading="loading"
      :data="tableData"
      :columns="tableColumns"
      :bordered="{ cell: true }"
      :scroll="{ x: '100%', y: '100%', minWidth: 1200 }"
      :pagination="pagination"
      :row-selection="{ type: 'checkbox', showCheckedAll: true }"
      :selected-keys="selectedKeys"
      @select="select"
      @select-all="selectAll"
    />

    <XxxFormModal ref="XxxFormModalRef" @save-success="search" />
  </GiPageLayout>
</template>

<script setup lang="tsx">
defineOptions({ name: 'ModuleName' })
</script>

useTable 用法

ts
import type * as T from '@/apis/system/user'
import { baseAPI } from '@/apis/system/user'
import { useDict, useTable } from '@/hooks'

const { dictData } = useDict(['STATUS'] as const)

const queryParams = reactive({ status: '', username: '' })

const {
  loading,
  tableData,
  pagination,
  selectedKeys,
  search,
  select,
  selectAll,
  fixed, // 操作列 fixed: 'right'(小屏自动取消)
  onDelete,
  onBatchDelete,
  refresh
} = useTable({
  listAPI: (page) => baseAPI.getList({ ...page, ...queryParams }),
  deleteAPI: (ids) => baseAPI.delete({ ids }),
  immediate: true,
  rowKey: 'id', // 默认 id
  crossPageSelect: false // 跨页多选时设为 true
})

要点:

  • search() 会重置到第 1 页并清空选中
  • refresh() 保持当前页刷新
  • listAPI 参数为 { page, size },需展开到接口
  • 空字符串查询条件建议转 undefined 再传 API

GiButton 预设类型

add | edit | delete | search | reset | upload | import | export

列表工具栏与操作列统一使用 GiButton,操作列常用 size="mini"。

表格列(TSX)

使用 lang="tsx",从 @arco-design/web-vue 引入 TableColumnData:

tsx
const tableColumns: TableColumnData[] = [
  {
    title: '序号',
    width: 68,
    align: 'center',
    render: ({ rowIndex }) => <span>{rowIndex + 1}</span>
  },
  { title: '名称', dataIndex: 'name', ellipsis: true, tooltip: true },
  {
    title: '状态',
    width: 100,
    align: 'center',
    render: ({ record }) => (
      <GiCellStatus status={record.status} />
    )
  },
  {
    title: '操作',
    width: 160,
    align: 'center',
    fixed: 'right', // 或绑定 useTable 的 fixed
    render: ({ record }) => (
      <Space>
        <GiButton type="edit" size="mini" onClick={() => onEdit(record as T.ListItem)} />
        <Popconfirm content="确定删除?" onBeforeOk={() => onDelete(record as T.ListItem)}>
          <GiButton type="delete" size="mini" />
        </Popconfirm>
      </Space>
    )
  }
]

常用单元格组件:GiCellAvatar、GiCellGender、GiCellStatus(从 @/components/GiCell 引入或在 TSX 中直接使用)。

GiPageLayout

属性/插槽说明
#left左侧栏(部门树、字典类型列表等)
#header顶栏(少用)
margin外边距模式
collapsed显示折叠按钮
size左侧宽度,如 "280px"

左栏选中后通过事件同步右侧列表,参考 dict/index.vue 的 onDictTypeRefresh。

表单弹窗(Modal + GiForm)

vue
<a-modal v-model:visible="visible" :title="title" :mask-closable="false"
  @before-ok="save" @close="close">
  <GiForm ref="GiFormRef" :model-value="form" :columns="formColumns"
    @update:model-value="Object.assign(form, $event)" />
</a-modal>
ts
import type { FormColumnItem } from '@/components/index'
import { useResetReactive } from '@/hooks'

const [form, resetForm] = useResetReactive({ id: '', name: '', status: '1' as Status })
const GiFormRef = useTemplateRef<InstanceType<typeof GiForm>>('GiFormRef')

const add = () => {
  detailId.value = ''
  visible.value = true
}
const edit = async (id: string) => {
  visible.value = true
  detailId.value = id
  Object.assign(form, (await baseAPI.getDetail({ id })).data)
}
const close = () => {
  GiFormRef.value?.formRef?.resetFields()
  resetForm()
}
const save = async () => {
  const valid = await GiFormRef.value?.formRef?.validate()
  if (valid) return false
  // await baseAPI.add(form) 或 baseAPI.update(form)
  emit('save-success')
  return true
}

defineExpose({ add, edit })

formColumns 常用 type:input、select、tree-select、radio-group、switch、textarea。校验可用 required、rules;正则见 @/utils/regexp。

字典下拉

ts
const { dictData } = useDict(['STATUS'] as const)
// 模板:<a-select :options="dictData.STATUS" />

表格增强方案选型

需求方案
内置斑马纹/全屏/列设置GiTable
继续用 a-table + 工具栏/列设置GiTableSetting 包裹(见 views/table/custom3)
简单列表a-table + useTable(系统模块主流)

检查清单

  • defineOptions({ name }) 已设置
  • row-key="id" 与 useTable 的 rowKey 一致
  • 删除走 onDelete / onBatchDelete 或自定义 Popconfirm + API
  • 弹窗 defineExpose({ add, edit }),父组件 useTemplateRef 调用
  • 保存成功后 emit('save-success') 并触发 search

© lin-97, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/crud-page of lin-97/gi-demo.

Open the folder on GitHubat commit d1e310a

Compare with similar skills

Crud Page next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Crud Page compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Crud Page this skilllin-97/gi-demo188—~1.3kAutomated safety check: PassApache-2.0
Crudzhe-qi/clhoria-template193—~552Automated safety check: PassMIT
Crudwujun728/jun_java_plugin239—~2.8kAutomated safety check: PassNone
Pangolin CRUD Endpointsfosrl/pangolin23k—~461Automated safety check: PassCustom licence
Fa Crud Page Generatorfantastic-admin/basic3.4k—~1.1kAutomated safety check: PassMIT
Crud AutomatorElsiKora/NestJS-Crud-Automator261—~6.7kAutomated safety check: PassMIT

Similar skills

  • Crud

    zhe-qi/clhoria-template

    创建或修改 CRUD 模块。当需要创建新的增删改查 API、修改现有路由模块、添加新字段、新增接口、或用户请求"创建/修改 XX 管理"时使用

    193 GitHub stars~552 tokensUpdated 2 mo ago
    Backend & APIsAuto-check passed
  • Crud

    wujun728/jun_java_plugin

    一键生成完整业务模块代码(SQL/Entity/DAO/XML/Repository/Service/Controller/Mapper/POJO),用于创建新的业务功能

    239 GitHub stars~2.8k tokensUpdated 4 mo ago
    DatabasesAuto-check passed
  • Use whenever asked to add, create, or scaffold a CRUD endpoint, router, or entity in this repo's server (create/list/get/update/delete handlers, new…

    23k GitHub stars~461 tokensUpdated today
    Backend & APIsAuto-check passed
  • Fa Crud Page Generator

    fantastic-admin/basic

    为 Fantastic-admin 框架生成完整的 CRUD 业务模块,遵循框架标准模块结构和内建 Fa 组件体系,使用 FaForm/FaFormItem 生成新增/编辑表单,产出列表页、详情/编辑页、DetailForm 表单组件、API 模块、fake mock 数据、可选路由。用户说:'帮我做一个商品管理页面'、'搭一个用户列表,能搜索分页新增编辑删除'、'生成订单模块'、'新建 XX…

    3.4k GitHub stars~1.1k tokensUpdated 11 days ago
    Frontend & DesignAuto-check passed
  • Crud Automator

    ElsiKora/NestJS-Crud-Automator

    Design, audit, document, refactor, and implement NestJS CRUD Automator resources using @elsikora/nestjs-crud-automator.

    261 GitHub stars~6.7k tokensUpdated 17 days ago
    Backend & APIsAuto-check passed
  • Crud Di

    ArtisanCloud/PowerX

    PowerX CRUD 依赖注入规则(Deps 单入口、构造注入、跨传输复用). An agent skill from ArtisanCloud/PowerX.

    378 GitHub stars~1.3k tokensUpdated yesterday
    Backend & APIsAuto-check passed

More from lin-97/gi-demo

  • API Mock

    lin-97/gi-demo

    在本模板项目中新增或修改 API 接口、类型定义与 vite-plugin-mock 模拟数据。涉及 getBaseApi、http、baseAPI、mock 目录、分页响应格式时使用。

    188 GitHub stars~824 tokensUpdated 4 mo ago
    Auto-check: notes
  • Project

    lin-97/gi-demo

    后台管理模板的项目总览与前端强制规范。涵盖 Vue 3 + Arco Design + Gi 组件库、目录结构、自动导入、CRUD/API 约定与代码风格。在当前仓库内开发、新增页面、查阅架构或不确定项目规范时使用。

    188 GitHub stars~1.4k tokensUpdated 4 mo ago
    Auto-check: notes

Questions about Crud Page

What does Crud Page do?

在本模板项目中创建或修改 CRUD 列表页、表格列、搜索区、表单弹窗。使用 GiPageLayout、useTable、GiButton、a-table、GiForm、useDict 时加载本技能。. Crud Page is an agent skill from lin-97/gi-demo.

How do I install Crud Page in Claude Code?

Run `npx skills add lin-97/gi-demo --skill crud-page -a claude-code`. Or copy the skill folder (.agents/skills/crud-page in lin-97/gi-demo) into .claude/skills/crud-page in your project. Claude Code loads it when a task matches its description.

How do I install Crud Page in Codex?

Run `npx skills add lin-97/gi-demo --skill crud-page -a codex`. Or copy the skill folder (.agents/skills/crud-page in lin-97/gi-demo) into .agents/skills/crud-page in your project. Codex loads it when a task matches its description.

Can I use Crud Page in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add lin-97/gi-demo --skill crud-page -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/crud-page, .gemini/skills/crud-page, .github/skills/crud-page and .opencode/skills/crud-page in your project.

What does Crud Page need to run?

SKILL.md names no scripts, command-line tools or credentials: Crud Page is instructions for the agent only.

Does Crud Page access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Crud Page safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Crud Page use?

Crud Page is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Crud Page use?

About 1.3k tokens (SKILL.md is roughly 5.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Crud Page?

Skills that share tags, products or a category with Crud Page: Crud (zhe-qi/clhoria-template, 193 stars), Crud (wujun728/jun_java_plugin, 239 stars), Pangolin CRUD Endpoints (fosrl/pangolin, 23k stars) and Fa Crud Page Generator (fantastic-admin/basic, 3.4k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Crud Page?

lin-97 (a GitHub user) maintains it in lin-97/gi-demo, which has 188 GitHub stars. The repository holds 3 skills in this directory. The repository was last updated on June 12, 2026.

Source: lin-97/gi-demo on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.