修复已知问题
This commit is contained in:
@@ -1,42 +0,0 @@
|
||||
import {useEffect} from "react";
|
||||
import {Image, Space} from '@nutui/nutui-react-taro'
|
||||
import Taro from '@tarojs/taro'
|
||||
|
||||
const BestSellers = (props: any) => {
|
||||
const reload = () => {
|
||||
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
reload()
|
||||
}, [])
|
||||
|
||||
return (
|
||||
<div className={'px-2 mb-4'}>
|
||||
<div className={'flex flex-col justify-between items-center rounded-lg px-3'}>
|
||||
{props.data?.map((item, index) => {
|
||||
return (
|
||||
<div key={index} className={'flex bg-white rounded-lg w-full p-3 mb-3'}
|
||||
onClick={() => Taro.navigateTo({url: '/hjm/query?id=' + item.id})}>
|
||||
<Image src={item.image} mode={'scaleToFill'}
|
||||
radius="10%" width="80" height="80"/>
|
||||
<div className={'mx-3 flex flex-col'}>
|
||||
<Space direction={'vertical'}>
|
||||
<div className={'car-no text-lg font-bold'}>{item.code}</div>
|
||||
<div className={'flex text-xs text-gray-500'}>快递公司:<span
|
||||
className={'text-gray-700'}>{item.parentOrganization}</span></div>
|
||||
<div className={'flex text-xs text-gray-500'}>保险状态:<span className={'text-green-600'}>{item.insuranceStatus}</span>
|
||||
</div>
|
||||
<div className={'flex text-xs text-gray-500'}>绑定操作员:<span
|
||||
className={'text-gray-700'}>{item.driver}</span></div>
|
||||
</Space>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
})}
|
||||
</div>
|
||||
<div style={{height: '170px'}}></div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
export default BestSellers
|
||||
@@ -1,4 +0,0 @@
|
||||
export default definePageConfig({
|
||||
navigationBarTitleText: '报险记录',
|
||||
navigationStyle: 'custom'
|
||||
})
|
||||
@@ -1,59 +0,0 @@
|
||||
import {useEffect, useState} from "react";
|
||||
import Taro from '@tarojs/taro'
|
||||
import {ArrowLeft} from '@nutui/icons-react-taro'
|
||||
import {NavBar, InfiniteLoading} from '@nutui/nutui-react-taro'
|
||||
import {HjmCar} from "@/api/hjm/hjmCar/model";
|
||||
import BestSellers from "./BestSellers";
|
||||
|
||||
/**
|
||||
* 文章终极列表
|
||||
* @constructor
|
||||
*/
|
||||
const Index = () => {
|
||||
const [statusBarHeight, setStatusBarHeight] = useState<number>()
|
||||
const [list, setList] = useState<HjmCar[]>([])
|
||||
|
||||
const reload = () => {
|
||||
// 获取车辆列表
|
||||
setList([])
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
Taro.getSystemInfo({
|
||||
success: (res) => {
|
||||
setStatusBarHeight(res.statusBarHeight)
|
||||
},
|
||||
})
|
||||
reload()
|
||||
}, [])
|
||||
|
||||
|
||||
return (
|
||||
<>
|
||||
<NavBar
|
||||
fixed={true}
|
||||
style={{marginTop: `${statusBarHeight}px`}}
|
||||
onBackClick={() => {
|
||||
}}
|
||||
left={
|
||||
<>
|
||||
<ArrowLeft size={18} onClick={() => {Taro.navigateBack()}} />
|
||||
{/*<SearchBar shape="round" maxLength={5} style={{paddingLeft: '1px'}}/>*/}
|
||||
{/*<div className={'flex flex-col text-center justify-center items-center'}>*/}
|
||||
{/* <Filter size={14}/>*/}
|
||||
{/* <div className={'text-xs text-gray-600 whitespace-nowrap'}>筛选</div>*/}
|
||||
{/*</div>*/}
|
||||
</>
|
||||
}
|
||||
>
|
||||
<span>报险记录</span>
|
||||
</NavBar>
|
||||
<InfiniteLoading
|
||||
className={'w-full fixed left-0 top-24'}
|
||||
>
|
||||
<BestSellers data={list}/>
|
||||
</InfiniteLoading>
|
||||
</>
|
||||
)
|
||||
}
|
||||
export default Index
|
||||
@@ -1,5 +1,5 @@
|
||||
import {useEffect, useState} from "react";
|
||||
import {Image, Tag} from '@nutui/nutui-react-taro'
|
||||
import {Image} from '@nutui/nutui-react-taro'
|
||||
import {ConfigProvider} from '@nutui/nutui-react-taro'
|
||||
import Taro from '@tarojs/taro'
|
||||
|
||||
@@ -15,6 +15,7 @@ import {uploadFile} from "@/api/system/file";
|
||||
|
||||
function Index() {
|
||||
const [isUpdate, setIsUpdate] = useState<boolean>(false)
|
||||
const [submitText, setSubmitText] = useState<string>('提交')
|
||||
|
||||
const [FormData, setFormData] = useState<UserVerify>({
|
||||
userId: undefined,
|
||||
@@ -37,6 +38,9 @@ function Index() {
|
||||
if (data) {
|
||||
setIsUpdate(true);
|
||||
setFormData(data)
|
||||
if(data.status == 2){
|
||||
setSubmitText('重新提交')
|
||||
}
|
||||
} else {
|
||||
setFormData({
|
||||
type: 0
|
||||
@@ -146,7 +150,7 @@ function Index() {
|
||||
onFinish={(values) => submitSucceed(values)}
|
||||
onFinishFailed={(errors) => submitFailed(errors)}
|
||||
footer={
|
||||
FormData.status != 1 && (
|
||||
FormData.status != 1 && FormData.status != 0 && (
|
||||
<div
|
||||
style={{
|
||||
display: 'flex',
|
||||
@@ -156,7 +160,7 @@ function Index() {
|
||||
>
|
||||
<Button nativeType="submit" block type={'info'}
|
||||
disabled={FormData.status != 2 && FormData.status != undefined}>
|
||||
提交
|
||||
{submitText}
|
||||
</Button>
|
||||
</div>
|
||||
)
|
||||
@@ -288,7 +292,7 @@ function Index() {
|
||||
label={'审核状态'}
|
||||
name="status"
|
||||
>
|
||||
<Tag plain>{FormData.statusText}</Tag>
|
||||
<span className={'text-gray-500'}>{FormData.statusText}</span>
|
||||
</Form.Item>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user