测试bug修改

master
wangxi 3 years ago
parent 61a366c493
commit 7d7c9dd28a

@ -176,7 +176,12 @@ const CourseList: React.FC = () => {
hideInTable: true,
hideInForm: false,
hideInSearch: true,
renderText: (val: string) => `${val} 分钟`,
render: (text: React.ReactNode, _: any, index: number) => {
return(
<div>{text}</div>
)
},
// renderText: (val: string) => `${val} 分钟`,
formItemProps: {
// 参照 https://ant.design/components/form-cn/#Rule
rules: [
@ -276,7 +281,7 @@ const CourseList: React.FC = () => {
maxCount={1}
multiple={false}
file={()=>{
// location.pathname
// location.pathname
}}
>
<Button icon={<UploadOutlined />}></Button>
@ -624,13 +629,14 @@ const CourseList: React.FC = () => {
//const url = values?.upload[0]?.url?.replace('/dsideal_yy/html/','') || values?.upload[0]?.response?.url;
//console.log('url', url)
console.log('values编辑',values)
await handleUpdate({
...values,
attachment_filesize: attachment_json?.size || 0, // Bit 字节
course_id: currentRow?.course_id,
attachment_json: `{"img":"", "name":"${values.attachment_json.file.name}", "url": "${values.attachment_json?.url}", "size": "${values.attachment_json?.size}"}`
});
await handleUpdate({
...values,
attachment_json: `{"img":"", "name": "${values.attachment_json.file.name}", "url": "down/Syzx/${uuid?.substr(0, 2)}/${uuid}.mp4"}`,
attachment_filesize: values.attachment_json?.size || 0, // Bit 字节
course_id: currentRow?.course_id,
// attachment_json:JSON.stringify(values.attachment_json)
// attachment_json: `{"img":"", "name":"${values.attachment_json.file.name}", "url": "${values.attachment_json?.url}", "size": "${values.attachment_json?.size}"}`
});
handleUpdateModalVisible(false); // 隐藏编辑窗口
actionRef.current?.reloadAndRest?.();
console.log(values);

Loading…
Cancel
Save