fix(icc add hls)

This commit is contained in:
wang_yp 2025-08-13 20:56:49 +08:00
parent 5364d1eace
commit e3ffeb34d7
5 changed files with 43 additions and 30 deletions

View File

@ -117,7 +117,7 @@ const BTable = (props: any) => {
searchCallback && searchCallback(dats) searchCallback && searchCallback(dats)
}} }}
formDatas={searchConfig} /> formDatas={searchConfig} />
<Button onClick={() => { <Button type="primary" onClick={() => {
searchFormRef.current?.submit() searchFormRef.current?.submit()
}}></Button> }}></Button>
<Button onClick={() => { <Button onClick={() => {
@ -125,7 +125,6 @@ const BTable = (props: any) => {
searchFormRef.current?.submit() searchFormRef.current?.submit()
}}></Button> }}></Button>
</Space> </Space>
: null} : null}
</> </>
) )

View File

@ -16,7 +16,7 @@ export const FormSelect = (v: FormDatas) => {
}, [v.selectUrl, v.selectList]); }, [v.selectUrl, v.selectList]);
return ( return (
<Form.Item <Form.Item
key={v.name} key={v.label}
label={v.label} label={v.label}
name={v.name} name={v.name}
rules={v.rules} rules={v.rules}
@ -24,7 +24,7 @@ export const FormSelect = (v: FormDatas) => {
<Select placeholder={v.placeholder} mode={v.model} <Select placeholder={v.placeholder} mode={v.model}
style={{ width: "100%" ,minWidth:"200px"}} > style={{ width: "100%" ,minWidth:"200px"}} >
{list?.map((item: any, index) => { {list?.map((item: any, index) => {
return <Option key={item.identity} value={item.identity}> return <Option key={JSON.stringify(item)} value={item.identity}>
{item[v.keys ?? "name"]} {item[v.keys ?? "name"]}
</Option> </Option>
})} })}

View File

@ -5,12 +5,12 @@ import { EventTypeConfig } from "@/service/user_config";
import { ColumnsType } from "antd/es/table"; import { ColumnsType } from "antd/es/table";
export const searchConfig = [ export const searchConfig = [
{ {
type: FormType.select, type: FormType.select,
label: "", label: "",
name: "type_identity", name: "type_identity",
placeHolder:"事件类型", placeHolder: "事件类型",
keys:"type_name", keys: "type_name",
value: "", value: "",
selectUrl: EventTypeConfig.LIST, selectUrl: EventTypeConfig.LIST,
}, },
@ -45,12 +45,12 @@ export const defaultConfig = [
value: "", value: "",
rules: [{ required: true, message: "请输入事件地点!" }], rules: [{ required: true, message: "请输入事件地点!" }],
}, },
{ {
type: FormType.select, type: FormType.select,
label: "事件类型", label: "事件类型",
name: "type_identity", name: "type_identity",
value: "", value: "",
keys:"type_name", keys: "type_name",
selectUrl: EventTypeConfig.LIST, selectUrl: EventTypeConfig.LIST,
rules: [{ required: true, message: "请输入事件地点!" }], rules: [{ required: true, message: "请输入事件地点!" }],
}, },
@ -82,7 +82,7 @@ export const defaultConfig = [
value: "", value: "",
mode: "", mode: "",
selectUrl: SourceConfig.Searchs, selectUrl: SourceConfig.Searchs,
keys:"content", keys: "content",
rules: [{ required: false, message: "请选择负责人!" }], rules: [{ required: false, message: "请选择负责人!" }],
}, },
{ {
@ -92,7 +92,7 @@ export const defaultConfig = [
value: "", value: "",
rules: [{ required: true, message: "请输入负责人电话!" }], rules: [{ required: true, message: "请输入负责人电话!" }],
}, },
{ {
type: FormType.fetchList, type: FormType.fetchList,
label: "参与人员选择", label: "参与人员选择",
@ -106,17 +106,18 @@ export const defaultConfig = [
type: FormType.select, type: FormType.select,
label: "事件等级", label: "事件等级",
name: "level", name: "level",
value: 1, value: "1",
placeHolder: "事件等级",
selectList: [ selectList: [
{ {
name: "普通", name: "普通",
id: 1, identity: "1",
}, { }, {
name: "紧急", name: "紧急",
id: 2, identity: "2",
}, { }, {
name: "特级", name: "特级",
id: 3, identity: "3",
} }
], ],
rules: [{ required: true, message: "请输入事件等级!" }], rules: [{ required: true, message: "请输入事件等级!" }],

View File

@ -10,7 +10,10 @@ const User = (props: Store) => {
const { usrStore } = props; const { usrStore } = props;
// 获取列表数据 // 获取列表数据
useEffect(() => { useEffect(() => {
usrStore.getlist().then(()=>{ getList({})
}, [usrStore, usrStore.isRefresh]);
const getList = (params) => {
usrStore.getlist(params).then(() => {
const list = usrStore.list const list = usrStore.list
for (let index = 0; index < list.length; index++) { for (let index = 0; index < list.length; index++) {
const element = list[index]; const element = list[index];
@ -19,8 +22,7 @@ const User = (props: Store) => {
element.thing_type_ids = element.thing_type.map((item) => item.type_identity) element.thing_type_ids = element.thing_type.map((item) => item.type_identity)
} }
}); });
}, [usrStore, usrStore.isRefresh]); };
return ( return (
<div className="contentBox"> <div className="contentBox">
<BTable <BTable
@ -30,13 +32,13 @@ const User = (props: Store) => {
btnText="添加人员" btnText="添加人员"
dataSource={usrStore.list} dataSource={usrStore.list}
searchConfig={searchConfig} searchConfig={searchConfig}
config={defaultConfig}
searchCallback={(values) => { searchCallback={(values) => {
usrStore.getlist(values); getList(values);
}} }}
deleteCallback={(record) => { deleteCallback={(record) => {
usrStore.deleteItem(record); usrStore.deleteItem(record);
}} }}
config={defaultConfig}
/> />
</div> </div>
); );

View File

@ -26,6 +26,26 @@ export const defaultConfig = [
name: "tel", name: "tel",
value: "", value: "",
rules: [{ required: true, message: "联系电话不能为空" }] rules: [{ required: true, message: "联系电话不能为空" }]
},
{
type: FormType.treeSelect,
label: "所属单位",
name: "company_identity",
treeCheckbox: false,
selectUrl: CompanyConfig.LIST,
value: "",
keys: "company_id",
rules: [{ required: true, message: "所属单位不能为空" }],
},
{
type: FormType.treeSelect,
label: "所属科室",
name: "dep_identity",
treeCheckbox: false,
selectUrl: CompanyConfig.LIST,
value: "",
keys: "company_id",
rules: [],
}, },
{ {
type: FormType.treeSelect, type: FormType.treeSelect,
@ -54,16 +74,7 @@ export const defaultConfig = [
value: [], value: [],
rules: [{ required: true, message: "请选择默认数据" }], rules: [{ required: true, message: "请选择默认数据" }],
}, },
{
type: FormType.treeSelect,
label: "所属单位",
name: "company_identity",
treeCheckbox: false,
selectUrl: CompanyConfig.LIST,
value: "",
keys: "company_id",
rules: [{ required: true, message: "所属单位不能为空" }],
},
{ {
type: FormType.select, type: FormType.select,