Commit 7e9869a0 by Denglingling

调整【消耗确认】<FlatList>对应的“keyExtractor”的取值

parent 6df041fe
......@@ -46,12 +46,6 @@ class ConsumDetailsPage extends Component {
// specification: '3g,Ytg-DG-SZGT',
// serial_number: '2001202001001774',
// select: false
// },{
// "id": "1",
// item_name: '人工髋关节假体-JS-HB ||| T2',
// specification: '3g,Ytg-DG-SZGT',
// serial_number: '2001202001001774',
// select: false
// }
],
allConOption: [], // 所有数据(未筛选过的)
......@@ -86,7 +80,6 @@ class ConsumDetailsPage extends Component {
surgery_collect_number: orderId
}
let detailResult = await requestEquipDetails(global_domain_config, params)
console.log('detailResult-----',detailResult)
if(detailResult.error_code === 0) {
let {lines} = detailResult.data
// 需要过滤已提过消耗的数据 raised_consume="Y"
......@@ -97,15 +90,13 @@ class ConsumDetailsPage extends Component {
show('当前明细数据为空,请重现选择订单')
} else {
let {subDetOption} = this.props // 【器械消耗】已存在的明细
// console.log('subDetOption-----', subDetOption)
subDetOption.length && subDetOption.forEach((item, index) => {
lines.length && lines.forEach((chItem, chInd) => {
lines.length && lines.forEach((chItem, chInd) => {
chItem.id = chInd + ''
subDetOption.length && subDetOption.forEach((item) => {
if(chItem.serial_number == item.serial_number) {
// chItem.sale_price = item.sale_price
chItem.local_add_price = item.local_add_price
chItem.select = true
}
chItem.id = chInd + ''
})
})
}
......@@ -170,13 +161,11 @@ class ConsumDetailsPage extends Component {
// 取消选择
handleCelSelCheck(item, index) {
// console.log('取消===cel:', item, index)
this.changeIsSelected(index, false)
}
// 确定选择
handleSubSelectedCheck(item, index) {
// console.log('确定===sub:', item, index)
this.changeIsSelected(index, true)
}
......@@ -190,7 +179,6 @@ class ConsumDetailsPage extends Component {
this.setState({
conDetaOption
},() => {
// console.log('conDetaOption---修改-', conDetaOption)
let tempArr = []
conDetaOption.forEach(item => {
if(item.select) {
......@@ -205,7 +193,6 @@ class ConsumDetailsPage extends Component {
// 已选回调函数
detailsCallbak(subOpt) {
// console.log('----回调:',subOpt)
let tempOption = [...this.state.conDetaOption]
// 获取当前已选值
tempOption = tempOption.map(item => {
......@@ -235,13 +222,11 @@ class ConsumDetailsPage extends Component {
// 点击 已选
handleSubSelected(show) {
// console.warn('已选:666!!')
this.handleCloseSelectModal(true)
}
// 点击 确定耗材
handleSubmit() {
// console.warn('确定耗材', this.props.navigation.navigate)
this.handleCloseSelectModal(false)
let {localSelectOption} = this.state
if(!localSelectOption.length) {
......@@ -268,7 +253,6 @@ class ConsumDetailsPage extends Component {
<View style={list_common_item.ser_img_box}>
<Image source={require('../../../images/search_icon.png')} style={icon_style}/>
</View>
<TouchableOpacity
activeOpacity={.8}
style={styles.ser_scanit_box}
......@@ -276,7 +260,6 @@ class ConsumDetailsPage extends Component {
>
<Image source={require('../../../images/scan_2.png')} style={icon_style} />
</TouchableOpacity>
</View>
)
}
......@@ -319,7 +302,6 @@ class ConsumDetailsPage extends Component {
<Image style={icon_style} source={require('../../../images/radio_no.png')} />
</TouchableOpacity>
}
</View>
<View style={styles.sub_list_rig}>
<Text style={styles.rig_tit}>
......@@ -354,7 +336,6 @@ class ConsumDetailsPage extends Component {
<Text style={list_common_item.rig_tip}>{'确定耗材'}</Text>
</TouchableOpacity>
</View>
<DetailsModel
show={ selectShowPopup }
closeModal={(show) => this.handleCloseSelectModal(show)}
......@@ -389,11 +370,8 @@ class ConsumDetailsPage extends Component {
<HeadBackItem title={title} navigation={navigation} />
<View style={styles.cu_dl_main}>
{ this.renderSearchItem() }
{ this.renderContItem() }
{this.renderLodingItem()}
</View>
{this.renderFooterBtnItem()}
</SafeAreaView>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment