fix(lauange)
This commit is contained in:
parent
d36b600624
commit
9e51070215
|
@ -68,7 +68,7 @@ const AliUpload = (props: UploadFileProps) => {
|
||||||
<Upload
|
<Upload
|
||||||
listType="picture-card"
|
listType="picture-card"
|
||||||
fileList={files}
|
fileList={files}
|
||||||
action={`${Config.baseUrl}/v1/public/fts/upload`}
|
action={`http://127.0.0.1:12216/v1/public/fts/upload`}
|
||||||
onPreview={handlePreview}
|
onPreview={handlePreview}
|
||||||
maxCount={props.maxCount ?? 4}
|
maxCount={props.maxCount ?? 4}
|
||||||
onChange={handleChange}
|
onChange={handleChange}
|
||||||
|
|
|
@ -28,7 +28,7 @@ export const FormTreeSelect = (v: FormDatas) => {
|
||||||
value: "identity",
|
value: "identity",
|
||||||
children: "children"
|
children: "children"
|
||||||
}}
|
}}
|
||||||
treeCheckable={v.treeCheckbox}
|
multiple
|
||||||
showSearch
|
showSearch
|
||||||
style={{ width: '100%' }}
|
style={{ width: '100%' }}
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
|
|
|
@ -8,9 +8,9 @@ export const items = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/user",
|
key: "/user",
|
||||||
label: `用户管理`,
|
label: `员工管理`,
|
||||||
icon: <UserSwitchOutlined />,
|
icon: <UserSwitchOutlined />,
|
||||||
children: [{ key: "/user/list", label: `用户管理` }],
|
children: [{ key: "/user/list", label: `员工管理` }],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/source",
|
key: "/source",
|
||||||
|
@ -26,7 +26,7 @@ export const items = [
|
||||||
label: `权限管理`,
|
label: `权限管理`,
|
||||||
icon: <PaperClipOutlined />,
|
icon: <PaperClipOutlined />,
|
||||||
children: [
|
children: [
|
||||||
{ label: `企业管理`, key: "/permi/company" },
|
{ label: `单位管理`, key: "/permi/company" },
|
||||||
{ label: `部门管理`, key: "/permi/dep" },
|
{ label: `部门管理`, key: "/permi/dep" },
|
||||||
{ label: `角色管理`, key: "/permi/role" },
|
{ label: `角色管理`, key: "/permi/role" },
|
||||||
{ label: `菜单管理`, key: "/permi/menu" },
|
{ label: `菜单管理`, key: "/permi/menu" },
|
||||||
|
|
|
@ -1,33 +0,0 @@
|
||||||
// import { TreeSelect, TreeSelectProps } from "antd";
|
|
||||||
// import { useEffect, useState } from "react";
|
|
||||||
|
|
||||||
const VideoSelect = (props) => {
|
|
||||||
// const { changes } = props;
|
|
||||||
// const [value, setValue] = useState<string>();
|
|
||||||
// useEffect(() => {}, []);
|
|
||||||
|
|
||||||
// const onLoadData: TreeSelectProps["loadData"] = async ({ id }) => {};
|
|
||||||
|
|
||||||
// const onChange = (newValue: string) => {
|
|
||||||
// if (newValue.length > 4) return;
|
|
||||||
// setValue(newValue);
|
|
||||||
// changes(newValue);
|
|
||||||
// };
|
|
||||||
// return (
|
|
||||||
// <div>
|
|
||||||
// <TreeSelect
|
|
||||||
// treeDataSimpleMode
|
|
||||||
// multiple
|
|
||||||
// treeCheckable
|
|
||||||
// style={{ width: "100%" }}
|
|
||||||
// value={value}
|
|
||||||
// dropdownStyle={{ maxHeight: 400, overflow: "auto" }}
|
|
||||||
// placeholder="Please select"
|
|
||||||
// onChange={onChange}
|
|
||||||
// loadData={onLoadData}
|
|
||||||
// />
|
|
||||||
// </div>
|
|
||||||
// );
|
|
||||||
};
|
|
||||||
|
|
||||||
export default VideoSelect;
|
|
|
@ -71,6 +71,7 @@ const Source = (props: Store) => {
|
||||||
};
|
};
|
||||||
const getContent = (list, index) => {
|
const getContent = (list, index) => {
|
||||||
setLoading(true);
|
setLoading(true);
|
||||||
|
console.log(index)
|
||||||
sourceStore.geContent(list, index, 20).then((res) => {
|
sourceStore.geContent(list, index, 20).then((res) => {
|
||||||
res.forEach((element) => {
|
res.forEach((element) => {
|
||||||
element.key = element.identity;
|
element.key = element.identity;
|
||||||
|
@ -181,6 +182,7 @@ const Source = (props: Store) => {
|
||||||
|
|
||||||
const onChange: PaginationProps["onChange"] = (page) => {
|
const onChange: PaginationProps["onChange"] = (page) => {
|
||||||
setPage(page);
|
setPage(page);
|
||||||
|
console.log(page)
|
||||||
getContent(selectKey, page);
|
getContent(selectKey, page);
|
||||||
cancel();
|
cancel();
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,12 +1,11 @@
|
||||||
import Config from "@/util/config";
|
|
||||||
import { Button, message, Upload, UploadProps } from "antd";
|
import { Button, message, Upload, UploadProps } from "antd";
|
||||||
|
|
||||||
const Uploads = () => {
|
const Uploads = () => {
|
||||||
const props: UploadProps = {
|
const props: UploadProps = {
|
||||||
name: "file",
|
name: "file",
|
||||||
action: `${Config.baseUrl}/public/fts/uploadthree`,
|
action: `http://127.0.0.1:12216/v1/public/fts/uploadFore`,
|
||||||
headers: {
|
headers: {
|
||||||
authorization: "authorization-text",
|
authorization: window.localStorage.getItem("token")??''
|
||||||
},
|
},
|
||||||
onChange(info: any) {
|
onChange(info: any) {
|
||||||
if (info.file.status === "done" && info.file.response.code !== 200) {
|
if (info.file.status === "done" && info.file.response.code !== 200) {
|
||||||
|
|
|
@ -110,15 +110,20 @@ export const columns: ColumnsType<UserDataType> = [
|
||||||
dataIndex: "tel",
|
dataIndex: "tel",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "所属部门",
|
title: "所属部门",
|
||||||
dataIndex: "",
|
render: (render) => (
|
||||||
|
<span>{render.dep[0]?.dep_name}</span>
|
||||||
|
),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "所属单位",
|
title: "所属单位",
|
||||||
dataIndex: "",
|
render: (render) => (
|
||||||
|
<span>{render.company[0]?.name}</span>
|
||||||
|
),
|
||||||
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "角色",
|
title: "角色",
|
||||||
dataIndex: "",
|
dataIndex: "",
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
|
@ -90,6 +90,7 @@ class BaseStore<B> implements BaseStoreInterface<B> {
|
||||||
if (!res?.data?.record) {
|
if (!res?.data?.record) {
|
||||||
runInAction(() => {
|
runInAction(() => {
|
||||||
this.list = data;
|
this.list = data;
|
||||||
|
this.total = res.data.count
|
||||||
})
|
})
|
||||||
this.listStatus = false;
|
this.listStatus = false;
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { action, makeObservable, observable } from "mobx";
|
import { action, makeObservable, observable, runInAction } from "mobx";
|
||||||
import BaseStore from "./baseStore";
|
import BaseStore from "./baseStore";
|
||||||
import { UserDataType } from "@/model/userModel";
|
import { UserDataType } from "@/model/userModel";
|
||||||
import SourceConfig from "@/service/source_config";
|
import SourceConfig from "@/service/source_config";
|
||||||
|
@ -38,8 +38,8 @@ class SourceStore extends BaseStore<UserDataType> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
let res = await base.put(SourceConfig.EDIT, {
|
let res = await base.put(SourceConfig.EDIT, {
|
||||||
list:list,
|
list: list,
|
||||||
id_card:idcard,
|
id_card: idcard,
|
||||||
})
|
})
|
||||||
if (res.code !== 200) {
|
if (res.code !== 200) {
|
||||||
message.error(res.msg)
|
message.error(res.msg)
|
||||||
|
@ -54,7 +54,10 @@ class SourceStore extends BaseStore<UserDataType> {
|
||||||
message.error(res.msg)
|
message.error(res.msg)
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
this.total = res.data.count;
|
runInAction(() => {
|
||||||
|
this.total = res.data.count;
|
||||||
|
})
|
||||||
|
|
||||||
return res.data.record;
|
return res.data.record;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,6 @@ import BaseStore from "./baseStore";
|
||||||
import { UserDataType, UserInfos } from "@/model/userModel";
|
import { UserDataType, UserInfos } from "@/model/userModel";
|
||||||
import { message } from "antd";
|
import { message } from "antd";
|
||||||
import { UserConfig } from "@/service/user_config";
|
import { UserConfig } from "@/service/user_config";
|
||||||
import { json } from "stream/consumers";
|
|
||||||
|
|
||||||
class UserStore extends BaseStore<UserDataType> {
|
class UserStore extends BaseStore<UserDataType> {
|
||||||
_userinfo: UserInfos = {}; // 用户信息
|
_userinfo: UserInfos = {}; // 用户信息
|
||||||
|
|
Loading…
Reference in New Issue