From 7a9718a6fa0e8f46cf3832bc6055c16dee2898c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=B9=20=E6=9F=8F?= Date: Wed, 9 Aug 2023 13:36:09 +0000 Subject: [PATCH] flow function add --- frontend/src/components/ActionSelect.vue | 4 +- frontend/src/components/ActionSetting.vue | 83 +++++++++++++++++++++ frontend/src/pages/testQursar.vue | 91 +++++++++++++++++++++-- frontend/src/router/routes.ts | 5 ++ 4 files changed, 173 insertions(+), 10 deletions(-) create mode 100644 frontend/src/components/ActionSetting.vue diff --git a/frontend/src/components/ActionSelect.vue b/frontend/src/components/ActionSelect.vue index 9228315..9bf184a 100644 --- a/frontend/src/components/ActionSelect.vue +++ b/frontend/src/components/ActionSelect.vue @@ -20,8 +20,8 @@ export default { { name: 'content', label: '内容', field: 'content', sortable: true } ] const rows = reactive([]) - onMounted( () => { - api.get('http://127.0.0.1:8000/api/kintone/1').then(res =>{ + onMounted(async () => { + await api.get('http://127.0.0.1:8000/api/kintone/2').then(res =>{ res.data.forEach((item) => { rows.push({name:item.name,desc:item.desc,content:item.content}); diff --git a/frontend/src/components/ActionSetting.vue b/frontend/src/components/ActionSetting.vue new file mode 100644 index 0000000..c1af22e --- /dev/null +++ b/frontend/src/components/ActionSetting.vue @@ -0,0 +1,83 @@ + + diff --git a/frontend/src/pages/testQursar.vue b/frontend/src/pages/testQursar.vue index 80ca0fc..d475877 100644 --- a/frontend/src/pages/testQursar.vue +++ b/frontend/src/pages/testQursar.vue @@ -1,13 +1,88 @@ - - diff --git a/frontend/src/router/routes.ts b/frontend/src/router/routes.ts index 0b5f767..d5bc374 100644 --- a/frontend/src/router/routes.ts +++ b/frontend/src/router/routes.ts @@ -11,6 +11,11 @@ const routes: RouteRecordRaw[] = [ component: () => import('layouts/MainLayout.vue'), children: [{ path: '', component: () => import('pages/RuleEditor.vue') }], }, + { + path: '/test/', + component: () => import('layouts/MainLayout.vue'), + children: [{ path: '', component: () => import('pages/testQursar.vue') }], + }, // Always leave this as last one, // but you can also remove it