|
@@ -135,14 +135,30 @@ class CurrencyDetail extends Component {
|
|
|
billGroupList: nextProps.formData,
|
|
|
})
|
|
|
}
|
|
|
- // if (nextProps.isDetail != this.props.isDetail) {
|
|
|
- // const billGroupList = analysisFormData(response.data, isDetail)
|
|
|
- // this.props.onDataLoadComplete &&
|
|
|
- // this.props.onDataLoadComplete(billGroupList)
|
|
|
- // this.setState({
|
|
|
- // billGroupList: billGroupList,
|
|
|
- // })
|
|
|
- // }
|
|
|
+ /*if (nextProps.isDetail != this.props.isDetail) {
|
|
|
+ const { billGroupList } = this.state
|
|
|
+ if (billGroupList) {
|
|
|
+ billGroupList.forEach(billGroup => {
|
|
|
+ let showBillFields = billGroup.showBillFields
|
|
|
+ let hideBillFields = billGroup.hideBillFields
|
|
|
+ if (showBillFields) {
|
|
|
+ showBillFields.forEach(showField => {
|
|
|
+ showField.readOnly = nextProps.isDetail
|
|
|
+ showField.allowBlank = nextProps.isDetail
|
|
|
+ })
|
|
|
+ }
|
|
|
+ if (hideBillFields) {
|
|
|
+ hideBillFields.forEach(hideField => {
|
|
|
+ hideField.readOnly = nextProps.isDetail
|
|
|
+ hideField.allowBlank = nextProps.isDetail
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
+ this.setState({
|
|
|
+ billGroupList: billGroupList,
|
|
|
+ })
|
|
|
+ }*/
|
|
|
return true
|
|
|
}
|
|
|
|