update text
This commit is contained in:
parent
306de9d9bf
commit
d1d7e6e7a4
6 changed files with 29 additions and 23 deletions
|
|
@ -88,7 +88,7 @@ const Index: React.FC<kFProps> = ({ dispatch, getChunkList, doc_id, isShowCreate
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="chunk 内容"
|
label="chunk 内容"
|
||||||
name="content_ltks"
|
name="content_ltks"
|
||||||
rules={[{ required: true, message: 'Please input name!' }]}
|
rules={[{ required: true, message: 'Please input value!' }]}
|
||||||
>
|
>
|
||||||
<Input.TextArea />
|
<Input.TextArea />
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,7 @@ const Index: React.FC<kFProps> = ({ kFModel, dispatch, getKfList, kb_id }) => {
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="文件名"
|
label="文件名"
|
||||||
name="name"
|
name="name"
|
||||||
rules={[{ required: true, message: 'Please input name!' }]}
|
rules={[{ required: true, message: 'Please input value!' }]}
|
||||||
>
|
>
|
||||||
<Input />
|
<Input />
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
|
|
|
||||||
|
|
@ -78,6 +78,23 @@ const Index: React.FC<chunkProps> = ({ kSearchModel, chunkModel, dispatch, kb_id
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
useEffect(() => {
|
||||||
|
dispatch({
|
||||||
|
type: 'kSearchModel/updateState',
|
||||||
|
payload: {
|
||||||
|
loading: false,
|
||||||
|
doc_ids: [],
|
||||||
|
question: ""
|
||||||
|
}
|
||||||
|
});
|
||||||
|
dispatch({
|
||||||
|
type: 'kSearchModel/getKfList',
|
||||||
|
payload: {
|
||||||
|
kb_id
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
}, [])
|
||||||
const switchChunk = (item: any, available_int: boolean) => {
|
const switchChunk = (item: any, available_int: boolean) => {
|
||||||
const { chunk_id, doc_id } = item
|
const { chunk_id, doc_id } = item
|
||||||
dispatch({
|
dispatch({
|
||||||
|
|
@ -97,16 +114,6 @@ const Index: React.FC<chunkProps> = ({ kSearchModel, chunkModel, dispatch, kb_id
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
if (kb_id) {
|
|
||||||
dispatch({
|
|
||||||
type: 'kSearchModel/getKfList',
|
|
||||||
payload: {
|
|
||||||
kb_id
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}, [kb_id])
|
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
getChunkList()
|
getChunkList()
|
||||||
|
|
@ -144,12 +151,11 @@ const Index: React.FC<chunkProps> = ({ kSearchModel, chunkModel, dispatch, kb_id
|
||||||
onChange={handleSelectChange}
|
onChange={handleSelectChange}
|
||||||
style={{ width: 300, marginBottom: 20 }}
|
style={{ width: 300, marginBottom: 20 }}
|
||||||
options={d_list}
|
options={d_list}
|
||||||
value={doc_ids}
|
|
||||||
fieldNames={{ label: 'name', value: 'id' }}
|
fieldNames={{ label: 'name', value: 'id' }}
|
||||||
mode='multiple'
|
mode='multiple'
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Input.TextArea autoSize={{ minRows: 6, maxRows: 6 }} placeholder="搜索" style={{ width: 300 }} allowClear value={question} onChange={handleInputChange} />
|
<Input.TextArea autoSize={{ minRows: 6, maxRows: 6 }} placeholder="搜索" style={{ width: 300 }} allowClear onChange={handleInputChange} />
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div className={styles.pageContainer}>
|
<div className={styles.pageContainer}>
|
||||||
|
|
|
||||||
|
|
@ -79,9 +79,9 @@ const View: FC<LoginProps> = ({
|
||||||
{...formItemLayout}
|
{...formItemLayout}
|
||||||
name="email"
|
name="email"
|
||||||
label="Email"
|
label="Email"
|
||||||
rules={[{ required: true, message: 'Please input your name' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
>
|
>
|
||||||
<Input size='large' placeholder="Please input your name" />
|
<Input size='large' placeholder="Please input value" />
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
{
|
{
|
||||||
title === 'register' && <Form.Item
|
title === 'register' && <Form.Item
|
||||||
|
|
@ -97,9 +97,9 @@ const View: FC<LoginProps> = ({
|
||||||
{...formItemLayout}
|
{...formItemLayout}
|
||||||
name="password"
|
name="password"
|
||||||
label="Password"
|
label="Password"
|
||||||
rules={[{ required: true, message: 'Please input your name' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
>
|
>
|
||||||
<Input size='large' placeholder="Please input your name" />
|
<Input size='large' placeholder="Please input value" />
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
{
|
{
|
||||||
title === 'login' && <Form.Item
|
title === 'login' && <Form.Item
|
||||||
|
|
|
||||||
|
|
@ -71,7 +71,7 @@ const Index: FC<CPwModalProps> = ({ settingModel, dispatch }) => {
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="旧密码"
|
label="旧密码"
|
||||||
name="password"
|
name="password"
|
||||||
rules={[{ required: true, message: 'Please input your password!' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
>
|
>
|
||||||
<Input.Password />
|
<Input.Password />
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
|
|
|
||||||
|
|
@ -76,7 +76,7 @@ const Index: FC<SSModalProps> = ({ settingModel, dispatch }) => {
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="embedding 模型"
|
label="embedding 模型"
|
||||||
name="embd_id"
|
name="embd_id"
|
||||||
rules={[{ required: true, message: 'Please input your password!' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
initialValue={tenantIfo.embd_id}
|
initialValue={tenantIfo.embd_id}
|
||||||
|
|
||||||
>
|
>
|
||||||
|
|
@ -93,7 +93,7 @@ const Index: FC<SSModalProps> = ({ settingModel, dispatch }) => {
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="chat 模型"
|
label="chat 模型"
|
||||||
name="llm_id"
|
name="llm_id"
|
||||||
rules={[{ required: true, message: 'Please input your password!' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
initialValue={tenantIfo.llm_id}
|
initialValue={tenantIfo.llm_id}
|
||||||
|
|
||||||
>
|
>
|
||||||
|
|
@ -110,7 +110,7 @@ const Index: FC<SSModalProps> = ({ settingModel, dispatch }) => {
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="image2text 模型"
|
label="image2text 模型"
|
||||||
name="img2txt_id"
|
name="img2txt_id"
|
||||||
rules={[{ required: true, message: 'Please input your password!' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
initialValue={tenantIfo.img2txt_id}
|
initialValue={tenantIfo.img2txt_id}
|
||||||
|
|
||||||
>
|
>
|
||||||
|
|
@ -127,7 +127,7 @@ const Index: FC<SSModalProps> = ({ settingModel, dispatch }) => {
|
||||||
<Form.Item<FieldType>
|
<Form.Item<FieldType>
|
||||||
label="speech2text 模型"
|
label="speech2text 模型"
|
||||||
name="asr_id"
|
name="asr_id"
|
||||||
rules={[{ required: true, message: 'Please input your password!' }]}
|
rules={[{ required: true, message: 'Please input value' }]}
|
||||||
initialValue={tenantIfo.asr_id}
|
initialValue={tenantIfo.asr_id}
|
||||||
|
|
||||||
>
|
>
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue