提交 7f49d813 authored 作者: 钟是志's avatar 钟是志

辅导员备注修改

上级 6a4933ed
......@@ -100,9 +100,6 @@ function AuditButton(props) {
token: getToken()
};
payload = callbackSubmitData(payload);
console.log(payload);
setVisible(false);
setShowProcessModal(payload);
return false;
......
......@@ -131,10 +131,7 @@ export default function SelectPerson(props) {
const deleteSg = (x, index, e) => {
// 阻止事件冒泡
e.stopPropagation();
console.log(sgUsers);
let sgNew = [...sgUsers];
console.log(x);
debugger;
sgNew = sgNew.filter(g => {
return x.businessKey !== g.businessKey;
});
......
......@@ -872,6 +872,7 @@ export default class ZdyTable extends Component {
}
let styles = {};
// console.log(cell.content);
if (cell.content && cell.content.styles) {
try {
styles = JSON.parse(cell.content.styles);
......@@ -895,6 +896,7 @@ export default class ZdyTable extends Component {
key={j}
data-cell-id={cell.uuid || 'no_uuid_' + Math.random()
.slice(0, 6)}
data-com-name={cell.content?.comName || 'empty'}
style={{
overflow: 'auto',
textAlign:
......
......@@ -96,7 +96,6 @@ export default class TableList extends React.Component {
showHeader={this.props.showHeader}
get={this.props.get}
isHiddenPage={this.props.isHiddenPage != null ? this.props.isHiddenPage : false}
loading={this.props.loading}
pageSize={this.props.pageSize || 10}
value={{...this.state}}
notShowBack={true}
......
......@@ -116,7 +116,7 @@ export default class NormalTable extends Component {
if (pagination && pagination.total) {
pagination.showTotal = (total, range) => `共${total}条  `;
}
// console.log(rowKey);
return (
<Table
dataSource={dataSource}
......
......@@ -6,7 +6,6 @@ export default function countWidth({
if (json.twidth) {
// 列表宽度配置项 在 组件的 扩展的配置里面
showDiv = json.twidth;
console.log(showDiv);
return showDiv;
}
if (document.getElementsByClassName('ant-layout-content')?.length) {
......
import React, { useState, useEffect, useMemo, useCallback } from 'react';
import React, { useState, useEffect, useMemo, useCallback, memo, useRef } from 'react';
import { Steps } from 'antd';
import ZdyTable from '@/webPublic/one_stop_public/Table';
const { Step } = Steps;
export default function StepDiy(props) {
const Child = memo((props) => {
const { value, json, partFormProps } = props;
const diyProps = useMemo(() => {
const diyProps = useMemo(
() => {
let b = {};
if (value && typeof value === 'object') {
b = {
......@@ -29,11 +30,14 @@ export default function StepDiy(props) {
} else {
return b;
}
}, [json.otherProps, value]);
},
[json.otherProps, value],
);
const [current, setCurrent] = useState(diyProps?.StepsProps?.current || 0);
const partFormKey = useMemo(() => {
const partFormKey = useMemo(
() => {
if (typeof current !== 'undefined') {
let item = diyProps.Step.find((g, index) => {
return index === current;
......@@ -43,26 +47,30 @@ export default function StepDiy(props) {
}
}
return undefined;
}, [current]);
},
[current],
);
useEffect(() => {
useEffect(
() => {
if (diyProps?.StepsProps?.current !== current) {
setCurrent(diyProps?.StepsProps?.current);
}
}, [diyProps?.StepsProps?.current]);
// console.log(partFormProps.form.getFieldsValue());
},
[diyProps?.StepsProps?.current],
);
return (
<div style={diyProps.outSideDivStyle}>
<Steps {...diyProps.StepsProps} current={current}>
{Array.isArray(diyProps.Step) &&
diyProps.Step.map(g => {
diyProps.Step.map((g) => {
return <Step {...g} key={g.title} />;
})}
</Steps>
{Array.isArray(diyProps.Step) &&
diyProps.Step.filter(g => !!g.formKey).map((g, index) => {
diyProps.Step.filter((g) => !!g.formKey).map((g, index) => {
return (
<div key={g.formKey} style={{ display: partFormKey === g.formKey ? 'block' : 'none' }}>
<ZdyTable
......@@ -70,6 +78,7 @@ export default function StepDiy(props) {
currentFormTitle={'Steps组件的子表单' + g.formKey}
key={g.formKey}
currentFormKey={g.formKey}
form={props.form}
{...partFormProps?.datas[g.formKey]}
/>
</div>
......@@ -77,4 +86,16 @@ export default function StepDiy(props) {
})}
</div>
);
});
export default function StepDiy(props){
const { value, json, partFormProps, form } = props;
const js = useRef();
useEffect(() => {
js.current = json;
}, []);
if (!js.current) {
return null;
}
return <Child json={js.current} value={value} partFormProps={partFormProps} form={form} />;
}
......@@ -90,8 +90,6 @@ const { MonthPicker, WeekPicker } = DatePicker;
*/
const { TextArea } = Input;
const { Option } = Select;
const { RangePicker } = DatePicker;
const { TabPane } = Tabs;
const giveRender = (column = {}) => {
if (!column?.render) {
......@@ -1648,16 +1646,9 @@ export default class TableCom extends Component {
init: init,
formCode: this.props.formCode,
formId: this.props.formId,
form: this.props.form,
mapData: mapData,
sqlData: sqlData,
defaultValues: defaultValues,
// currentFormTitle={
// this.props.getCurrentFormTitle ? this.props.getCurrentFormTitle(fk) : null
// }
// key={fk}
// currentFormKey={fk}
// {...datas[fk]}
};
}
......@@ -1682,6 +1673,7 @@ export default class TableCom extends Component {
key={fk}
currentFormKey={fk}
{...datas[fk]}
form={this.props.form}
/>
</>
);
......@@ -3671,6 +3663,7 @@ ${obj[dataColumn.base52]}
disabled={disabled}
uuid={uuid}
partFormProps={this.partFormProps}
form={this.props.form}
/>,
);
break;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论