This commit is contained in:
tx 2024-11-11 09:12:17 +08:00
parent 39ed2e9ae2
commit af1d91c901
5 changed files with 28 additions and 13 deletions

View File

@ -1,5 +1,10 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET" />
<application
@ -9,6 +14,9 @@
android:roundIcon="@mipmap/ic_launcher_round"
android:allowBackup="false"
android:theme="@style/AppTheme">
<meta-data
android:name="com.amap.api.v2.apikey"
android:value="812efd3a950ba3675f928630302c6463" />
<activity
android:name=".MainActivity"
android:label="@string/app_name"

10
package-lock.json generated
View File

@ -8,7 +8,7 @@
"name": "BikeApp_demo",
"version": "0.0.1",
"dependencies": {
"@react-navigation/bottom-tabs": "^6.6.1",
"@react-navigation/bottom-tabs": "^6.4.0",
"@react-navigation/native": "^6.1.18",
"axios": "^1.7.7",
"react": "18.2.0",
@ -3290,11 +3290,11 @@
}
},
"node_modules/@react-navigation/bottom-tabs": {
"version": "6.6.1",
"resolved": "https://registry.npmmirror.com/@react-navigation/bottom-tabs/-/bottom-tabs-6.6.1.tgz",
"integrity": "sha512-9oD4cypEBjPuaMiu9tevWGiQ4w/d6l3HNhcJ1IjXZ24xvYDSs0mqjUcdt8SWUolCvRrYc/DmNBLlT83bk0bHTw==",
"version": "6.4.0",
"resolved": "https://registry.npmmirror.com/@react-navigation/bottom-tabs/-/bottom-tabs-6.4.0.tgz",
"integrity": "sha512-90CapiXjiWudbCiki9e6fOr/CECQRguIxv5OD7IBfbAMGX5GGiJpX8aqiHAz2DxpAz31v4JZcUr945+lFhXBfA==",
"dependencies": {
"@react-navigation/elements": "^1.3.31",
"@react-navigation/elements": "^1.3.6",
"color": "^4.2.3",
"warn-once": "^0.1.0"
},

View File

@ -10,7 +10,7 @@
"test": "jest"
},
"dependencies": {
"@react-navigation/bottom-tabs": "^6.6.1",
"@react-navigation/bottom-tabs": "^6.4.0",
"@react-navigation/native": "^6.1.18",
"axios": "^1.7.7",
"react": "18.2.0",

View File

@ -6,13 +6,16 @@ import Slider from "./slider";
import MiniMap from './MiniMap';
import { useNavigation } from '@react-navigation/native';
const NormaIndex: React.FC = () => {
const navigation = useNavigation(); // 获取导航实例
const [count, setCount] = useState(0);
const [data, setData] = useState(null);
const translateX = useRef(new Animated.Value(0)).current;
const bgColor = useRef(new Animated.Value(0)).current;
const handleImagePress = () => {
navigation.navigate('VehicleSettings'); // 跳转到车辆设置页面
const navigation = useNavigation();
const handlePress = () => {
navigation.navigate('deviceList'); // 确保 'deviceList' 是正确的页面名称
};
const panResponder = useRef(
PanResponder.create({
@ -139,13 +142,16 @@ const NormaIndex: React.FC = () => {
</View>
</View>
<MiniMap />
<TouchableOpacity onPress={handleImagePress}>
{/* <TouchableOpacity onPress={handlePress}>
<Image
source={{ uri: 'https://lxnapi.ccttiot.com/bike/img/static/ucYQHQ2Ep4odL8JpbtfT' }}
style={styles.otherSet}
/>
</TouchableOpacity>
</TouchableOpacity> */}
<Image
source={{ uri: 'https://lxnapi.ccttiot.com/bike/img/static/ucYQHQ2Ep4odL8JpbtfT' }}
style={styles.otherSet}
/>
<View style={styles.otherSet}>
<Image source={{ uri: 'https://lxnapi.ccttiot.com/bike/img/static/ulDHhC4MrH3FO0AeTqVg' }} style={styles.otherImg} />
<Image source={{ uri: 'https://lxnapi.ccttiot.com/bike/img/static/u849NsNxdtzxhUkUJnfW' }} style={styles.otherImg} />

View File

@ -0,0 +1 @@