Commit cb88768c authored by 陈浩玮's avatar 陈浩玮

调整

parent eea69e87
...@@ -69,6 +69,7 @@ ...@@ -69,6 +69,7 @@
</a-space> </a-space>
</template> </template>
</a-drawer> </a-drawer>
<slot name="children"></slot>
</div> </div>
</template> </template>
......
<template> <template>
<div> <my-table url="/api/v1/users" rowKey="userId" ref="table">
<my-table url="/api/v1/users" rowKey="userId" ref="table"> <template #search="{ query }">
<template #search="{ query }"> <my-form-item label="归属部门">
<my-form-item label="归属部门"> <OrganizationTree v-model="query.orgId" />
<OrganizationTree v-model="query.orgId" /> </my-form-item>
</my-form-item> <my-form-item label="账号">
<my-form-item label="账号"> <a-input placeholder="Basic usage" v-model="query.loginId" />
<a-input placeholder="Basic usage" v-model="query.loginId" /> </my-form-item>
</my-form-item> </template>
</template> <template #buttons>
<template #buttons> <a-button type="primary" @click="onAdd">新增</a-button>
<a-button type="primary" @click="onAdd">新增</a-button> </template>
<a-table-column title="账号" data-index="loginId" />
<a-table-column title="姓名" data-index="userName" />
<a-table-column title="职称" data-index="userTitleName" />
<a-table-column title="移动电话" data-index="mobilePhone" />
<a-table-column title="固定电话" data-index="fixedPhone" />
<a-table-column title="电子邮箱" data-index="userEmail" />
<a-table-column title="是否锁定" data-index="isLockedName" />
<a-table-column title="操作">
<template #default="row">
<ActionButton :buttons="buttons" :row="row" />
</template> </template>
</a-table-column>
<a-table-column title="账号" data-index="loginId" /> <template #children>
<a-table-column title="姓名" data-index="userName" /> <Form ref="form" />
<a-table-column title="职称" data-index="userTitleName" /> </template>
<a-table-column title="移动电话" data-index="mobilePhone" /> </my-table>
<a-table-column title="固定电话" data-index="fixedPhone" />
<a-table-column title="电子邮箱" data-index="userEmail" />
<a-table-column title="是否锁定" data-index="isLockedName" />
<a-table-column title="操作">
<template #default="row">
<ActionButton :buttons="buttons" :row="row" />
</template>
</a-table-column>
</my-table>
<Form ref="form" />
</div>
</template> </template>
<script> <script>
import Form from './form.vue'; import Form from './form.vue';
......
<template> <template>
<Drawer ref="drawerRef" v-model="visible"> <Drawer ref="drawerRef" v-model="visible" title="用户配置">
<a-form-model layout="vertical" :model="form" :rules="rules" ref="DrawerForm"> <!-- <a-form-model layout="vertical" :model="form" :rules="rules" ref="DrawerForm">
<a-form-model-item label="名称" prop="jobName"> <a-form-model-item label="名称" prop="jobName">
<a-input v-model="form.jobName" :disabled="isView" /> <a-input v-model="form.jobName" :disabled="isView" />
</a-form-model-item> </a-form-model-item>
<a-form-model-item label="描述" prop="jobDescription"> <a-form-model-item label="描述" prop="jobDescription">
<a-textarea v-model="form.jobDescription" :disabled="isView" :rows="4" /> <a-textarea v-model="form.jobDescription" :disabled="isView" :rows="4" />
</a-form-model-item> </a-form-model-item>
</a-form-model> -->
<a-steps :current="current">
<a-step v-for="item in steps" :key="item.title" :title="item.title" />
</a-steps>
<a-form-model layout="vertical" :model="form" :rules="rules" ref="DrawerForm">
<a-form-model-item label="名称" prop="jobName">
<a-input v-model="form.jobName" :disabled="isView" />
</a-form-model-item>
</a-form-model> </a-form-model>
<template #footer>
<a-button type="primary" @click="prev" v-if="current > 0"> 上一步 </a-button>
<a-button type="primary" @click="next" v-if="current < 2"> 下一步 </a-button>
</template>
</Drawer> </Drawer>
</template> </template>
...@@ -27,12 +40,31 @@ export default { ...@@ -27,12 +40,31 @@ export default {
{ required: true, message: 'Please select Activity zone', trigger: 'change' }, { required: true, message: 'Please select Activity zone', trigger: 'change' },
], ],
}, },
current: 0,
steps: [
{
title: '基本信息',
},
{
title: '证件设置',
},
{
title: '岗位设置',
},
],
}; };
}, },
methods: { methods: {
open() { open() {
this.visible = true; this.visible = true;
}, },
next() {
this.current++;
},
prev() {
this.current--;
},
add() { add() {
return JobsApi.addJobs({ ...this.form }); return JobsApi.addJobs({ ...this.form });
}, },
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment