|
@@ -2,15 +2,15 @@
|
|
<div>
|
|
<div>
|
|
<div class="tw-bg-white tw-p-5 tw-rounded-xl tw-mb-5">
|
|
<div class="tw-bg-white tw-p-5 tw-rounded-xl tw-mb-5">
|
|
<a-switch v-model:checked="checked" @click="toggleAll" /> 全部课程
|
|
<a-switch v-model:checked="checked" @click="toggleAll" /> 全部课程
|
|
- <span class="tw-mr-4"></span>
|
|
|
|
- <a-button @click="handleDeletePrivilege" :danger="true">删除</a-button>
|
|
|
|
- <span class="tw-mr-4"></span>
|
|
|
|
- <a-button @click="showModal">添加</a-button>
|
|
|
|
|
|
+ <div class="tw-float-right tw-flex tw-gap-2">
|
|
|
|
+ <a-button @click="handleDeletePrivilege" :danger="true">删除</a-button>
|
|
|
|
+ <a-button @click="showModal">添加</a-button>
|
|
|
|
+ </div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="tw-bg-white tw-p-5 tw-rounded-xl">
|
|
<div class="tw-bg-white tw-p-5 tw-rounded-xl">
|
|
<a-table
|
|
<a-table
|
|
- row-key="id"
|
|
|
|
|
|
+ row-key="courseId"
|
|
:columns="columns"
|
|
:columns="columns"
|
|
:data-source="data"
|
|
:data-source="data"
|
|
:row-selection="rowSelection"
|
|
:row-selection="rowSelection"
|
|
@@ -35,7 +35,7 @@
|
|
ok-text="确定"
|
|
ok-text="确定"
|
|
cancel-text="取消"
|
|
cancel-text="取消"
|
|
>
|
|
>
|
|
- <a-form>
|
|
|
|
|
|
+ <a-form layout="inline">
|
|
<a-form-item label="科目名称">
|
|
<a-form-item label="科目名称">
|
|
<a-input v-model:value="userObj.name"></a-input>
|
|
<a-input v-model:value="userObj.name"></a-input>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
@@ -48,7 +48,7 @@
|
|
|
|
|
|
<a-button @click="fetchData2" class="query-btn">查询</a-button>
|
|
<a-button @click="fetchData2" class="query-btn">查询</a-button>
|
|
</a-form>
|
|
</a-form>
|
|
- <div class="tw-bg-white tw-p-5 tw-rounded-xl">
|
|
|
|
|
|
+ <div class="tw-bg-white tw-py-5 tw-rounded-xl">
|
|
<a-table
|
|
<a-table
|
|
row-key="id"
|
|
row-key="id"
|
|
:columns="columns2"
|
|
:columns="columns2"
|
|
@@ -124,7 +124,7 @@ async function fetchData() {
|
|
checked = res0.data;
|
|
checked = res0.data;
|
|
|
|
|
|
const res = await getUserPrivilegegList({
|
|
const res = await getUserPrivilegegList({
|
|
- type: PRIVI_TYPE,
|
|
|
|
|
|
+ ptype: PRIVI_TYPE,
|
|
userId,
|
|
userId,
|
|
pageSize,
|
|
pageSize,
|
|
pageNo,
|
|
pageNo,
|
|
@@ -145,7 +145,6 @@ const columns = [
|
|
{
|
|
{
|
|
title: "科目编码",
|
|
title: "科目编码",
|
|
dataIndex: "courseCode",
|
|
dataIndex: "courseCode",
|
|
- width: 150,
|
|
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: "科目名称",
|
|
title: "科目名称",
|
|
@@ -226,7 +225,7 @@ watch(() => [pageNo2, pageSize2], fetchData2);
|
|
|
|
|
|
async function fetchData2() {
|
|
async function fetchData2() {
|
|
const res = await getToAddListForUserPrivilege({
|
|
const res = await getToAddListForUserPrivilege({
|
|
- type: PRIVI_TYPE,
|
|
|
|
|
|
+ ptype: PRIVI_TYPE,
|
|
rootOrgId: store.userInfo.rootOrgId,
|
|
rootOrgId: store.userInfo.rootOrgId,
|
|
userId,
|
|
userId,
|
|
name: userObj.name,
|
|
name: userObj.name,
|