修复banner指定设备显示问题

This commit is contained in:
al 2025-01-21 19:46:46 +08:00
parent 6169e8f89e
commit 6b24152029
1 changed files with 2 additions and 3 deletions

View File

@ -1,7 +1,6 @@
import {
Text,
View,
Dimensions,
TouchableOpacity,
Image as NativeImage,
Alert,
@ -18,10 +17,10 @@ import Banner from "../../../components/Banner";
import requireAPI from "../../../utils/requireAPI";
import * as Linking from "expo-linking";
import { goToPage } from "../../../utils/tools";
import { Platform } from "react-native";
export default function HostList() {
const navigation = useNavigation();
const tailwind = useTailwind();
const screenWidth = Dimensions.get("window").width;
const [hostList, setHostList] = useState([]);
const [bannerList, setBannerList] = useState([]);
useEffect(() => {
@ -56,7 +55,7 @@ export default function HostList() {
const _data = await requireAPI(
"POST",
"/api/activity_banner/list",
null,
{ body: { device_type: Platform.OS === "android" ? 0 : 1 } },
true
);
if (_data.ret === -1) {