|
@@ -14,7 +14,7 @@ import Activity from "./components/Activity";
|
|
import Map from "./components/Map-l7";
|
|
import Map from "./components/Map-l7";
|
|
// import Map from "./components/Map";
|
|
// import Map from "./components/Map";
|
|
import NewMedia from "./components/NewMedia";
|
|
import NewMedia from "./components/NewMedia";
|
|
-import NewMediaTrend from "./components/NewMediaTrend"
|
|
|
|
|
|
+// import NewMediaTrend from "./components/NewMediaTrend"
|
|
|
|
|
|
import { getWeather, getData } from "../../api/bigScreen"
|
|
import { getWeather, getData } from "../../api/bigScreen"
|
|
const [TimeDate, setTimeDate] = createSignal("");
|
|
const [TimeDate, setTimeDate] = createSignal("");
|
|
@@ -33,7 +33,7 @@ function setTQ(TQ) {
|
|
|
|
|
|
function BigScreenHome() {
|
|
function BigScreenHome() {
|
|
const [HeadTitle, setHeadTitle] = createSignal();
|
|
const [HeadTitle, setHeadTitle] = createSignal();
|
|
- const [Changeindex, setChangeindex] = createSignal(true);
|
|
|
|
|
|
+ // const [Changeindex, setChangeindex] = createSignal(true);
|
|
const [proTv, setproTv] = createSignal([
|
|
const [proTv, setproTv] = createSignal([
|
|
{
|
|
{
|
|
text: "陕台频道收视率",
|
|
text: "陕台频道收视率",
|
|
@@ -52,10 +52,6 @@ function BigScreenHome() {
|
|
let $ele = undefined, mainHeight = document.body.offsetHeight * 0.925 - 124;
|
|
let $ele = undefined, mainHeight = document.body.offsetHeight * 0.925 - 124;
|
|
|
|
|
|
onMount(() => {
|
|
onMount(() => {
|
|
- setInterval(() => {
|
|
|
|
- setChangeindex(!Changeindex);
|
|
|
|
- }, 2000);
|
|
|
|
-
|
|
|
|
setTimeDate(dayjs().format('YYYY-MM-DD'));
|
|
setTimeDate(dayjs().format('YYYY-MM-DD'));
|
|
seteHeight(Math.floor($ele.offsetWidth / 16 * 9) + 70);
|
|
seteHeight(Math.floor($ele.offsetWidth / 16 * 9) + 70);
|
|
getWeather().then(r => setTQ(r.data))
|
|
getWeather().then(r => setTQ(r.data))
|
|
@@ -216,7 +212,10 @@ function BigScreenHome() {
|
|
value: d.cm_tv_overview.data.loyalty
|
|
value: d.cm_tv_overview.data.loyalty
|
|
},
|
|
},
|
|
])
|
|
])
|
|
|
|
+
|
|
|
|
+ // new window.Swiper('.selfSwiper')
|
|
})
|
|
})
|
|
|
|
+
|
|
// TODO: 浏览器获取定位权限
|
|
// TODO: 浏览器获取定位权限
|
|
// const location = navigator.geolocation || false;
|
|
// const location = navigator.geolocation || false;
|
|
// if (!location) return
|
|
// if (!location) return
|
|
@@ -346,25 +345,33 @@ function BigScreenHome() {
|
|
/>
|
|
/>
|
|
</Show>
|
|
</Show>
|
|
<div class="center" style={{ width: Math.floor($ele.offsetWidth - 20) + 'px', height: (mainHeight - 104) / 3 + 30 + 'px', "margin-bottom": "6px", "margin-top": "6px" }}>
|
|
<div class="center" style={{ width: Math.floor($ele.offsetWidth - 20) + 'px', height: (mainHeight - 104) / 3 + 30 + 'px', "margin-bottom": "6px", "margin-top": "6px" }}>
|
|
- <Show when={Changeindex && oriData.media_read_trend && oriData.media_read_trend.name}>
|
|
|
|
- <SelfPlatform
|
|
|
|
- styleCss={{ marginBottom: '6px' }}
|
|
|
|
- title={oriData.media_read_trend.name}
|
|
|
|
- list={oriData.media_read_trend.data}
|
|
|
|
- width={Math.floor($ele.offsetWidth - 20)}
|
|
|
|
- height={(mainHeight - 104) / 3}
|
|
|
|
- />
|
|
|
|
- </Show>
|
|
|
|
|
|
+ {/* <div class="swiper-container selfSwiper">
|
|
|
|
+ <div class="swiper-wrapper">
|
|
|
|
+ <div class="swiper-slide"> */}
|
|
|
|
+ <Show when={oriData.media_read_trend && oriData.media_read_trend.name}>
|
|
|
|
+ <SelfPlatform
|
|
|
|
+ styleCss={{ marginBottom: '6px' }}
|
|
|
|
+ title={oriData.media_read_trend.name}
|
|
|
|
+ list={oriData.media_read_trend.data}
|
|
|
|
+ width={Math.floor($ele.offsetWidth - 20)}
|
|
|
|
+ height={(mainHeight - 104) / 3}
|
|
|
|
+ />
|
|
|
|
+ </Show>
|
|
|
|
+ {/* </div>
|
|
|
|
+ <div class="swiper-slide">
|
|
|
|
+ <Show when={oriData.media_spread_trend && oriData.media_spread_trend.name}>
|
|
|
|
+ <NewMediaTrend
|
|
|
|
+ styleCss={{ marginBottom: '6px' }}
|
|
|
|
+ title={oriData.media_spread_trend.name}
|
|
|
|
+ list={oriData.media_spread_trend.data}
|
|
|
|
+ width={Math.floor($ele.offsetWidth - 20)}
|
|
|
|
+ height={(mainHeight - 104) / 3}
|
|
|
|
+ />
|
|
|
|
+ </Show>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div> */}
|
|
|
|
|
|
- <Show when={!Changeindex && oriData.media_spread_trend && oriData.media_spread_trend.name}>
|
|
|
|
- <NewMediaTrend
|
|
|
|
- styleCss={{ marginBottom: '6px' }}
|
|
|
|
- title={oriData.media_spread_trend.name}
|
|
|
|
- list={oriData.media_spread_trend.data}
|
|
|
|
- width={Math.floor($ele.offsetWidth - 20)}
|
|
|
|
- height={(mainHeight - 104) / 3}
|
|
|
|
- />
|
|
|
|
- </Show>
|
|
|
|
</div>
|
|
</div>
|
|
<Show when={eHeight() > 0 && oriData.media_spread && oriData.media_spread.name}>
|
|
<Show when={eHeight() > 0 && oriData.media_spread && oriData.media_spread.name}>
|
|
<NewMedia
|
|
<NewMedia
|