🎈 perf(样品对比): 添加loading状态

This commit is contained in:
xuan 2022-11-03 15:09:56 +08:00
parent b5de3a031b
commit 215e180003
2 changed files with 4 additions and 1 deletions

View File

@ -8,6 +8,7 @@ import { toRgb } from '@/common/bluetooth/color/colorSpace'
import styles from './index.module.scss'
import { productabsorbcontrast } from '@/api/index'
import { isObject } from '@tarojs/shared'
import { alert } from '@/common/common'
export default () => {
//搜索参数
const [searchField, setSearchField] = useState({
@ -102,6 +103,7 @@ export default () => {
})
return
}
alert.showLoading('分析中')
const query = {
...searchField,
}
@ -119,6 +121,7 @@ export default () => {
let resCont = diffarray.filter(item => item).join(',')
setResult(resCont)
}
alert.hideLoading()
}
return (
<View className={styles.body}>

View File

@ -94,7 +94,7 @@ const ShoppingCartContainer: FC<InternalContainer> = () => {
const status = dataLoadingStatus({
list: shoppingCartData.list,
total: shoppingCartData.total,
status: state.loading,
status: state.loading || true,
})
console.log('status==>', status)
return status