合并分支

master
blak-kong 2 years ago
commit 786d8d8a37

@ -14,7 +14,10 @@ interface Props {
facialMaskConnectStatus: any;
}
function Index() {
const echartsRef = useRef<EchartsHandle>(null);
const option: EChartOption = {
@ -25,6 +28,13 @@ function Index() {
right: "28rpx",
bottom: "17rpx",
},
// legend: {
// itemStyle: {
// decal: {
// rotation: 90
// }
// }
// },
xAxis: {
// name: '',
// nameGap: 5,
@ -251,12 +261,28 @@ function Index() {
};
const level = [8, 7, 6, 5, 4, 3, 2];
const full = () => {
let box = document.getElementById("box");
box?.classList.add('fullscreen')
}
// const quanping = () => {
// T.setPageOrientation({
// orientation: "portrait",
// });
// // taro.setPageOrientation({
// // orientation: "landscape",
// // });
// },
return (
<Block>
<View className='box'>
<View id='box' className='box'>
<Echarts
force-use-old-canvas="false"
force-use-old-canvas='false'
echarts={echarts}
option={option}
ref={echartsRef}
@ -265,7 +291,7 @@ function Index() {
style={{ width: "630rpx", height: "260rpx", zIndex: 1 }}
/>
<View className='box_background'>
<Image className='full' src={require("@/img/full-scran.png")}></Image>
<Image className='full' src={require("@/img/full-scran.png")} onClick={full}></Image>
<View className='power'></View>
{level.map((item) => (
<View className='line' key={item}>

@ -158,198 +158,6 @@ const seriesData = [
},
],
};
// const option: EChartOption = {
// grid: {
// // 让图表占满容器
// top: "28rpx",
// left: "18rpx",
// right: "28rpx",
// bottom: "17rpx",
// },
// xAxis: [
// {
// type: 'category',
// axisTick: { show: false },
// data: ['2012', '2013', '2014', '2015', '2016'],
// axisLine: {
// show: false,
// },
// axisLabel: {
// show: false,
// },
// }
// ],
// yAxis: {
// type: "value",
// min: 0,
// max: 8,
// splitNumber: 8,
// splitLine: {
// show: false,
// // lineStyle: {
// // color: "#cccccc",
// // type: [4, 2],
// // dashOffset: 4,
// // },
// },
// axisLine: {
// show: false,
// },
// axisLabel: {
// show: false,
// },
// axisTick: {
// show: false,
// },
// },
// series: [
// { barCategoryGap:'0%',
// name: 'Forest',
// type: 'bar',
// barGap: 0,
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'Steppe',
// type: 'bar',
// // label: labelOption,
// emphasis: {
// focus: 'series'
// },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'Desert',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'Wetland',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'demo1',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'demo2',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'demo3',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'demo4',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// { barCategoryGap:'0%',
// name: 'demo5',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// },
// {
// color:'red',
// barCategoryGap:'0%',
// name: 'demo6',
// type: 'bar',
// // label: labelOption,
// // emphasis: {
// // focus: 'series'
// // },
// data: [2, 4, 4, 5, 7]
// }
// ]
// // grid: {
// // // 让图表占满容器
// // top: "28rpx",
// // left: "18rpx",
// // right: "28rpx",
// // bottom: "17rpx",
// // },
// // xAxis: {
// // type: 'category',
// // // data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
// // show: false,
// // // axisLine: {
// // // show: false,
// // // },
// // },
// // yAxis: {
// // type: "value",
// // min: 0,
// // max: 50,
// // splitNumber: 10,
// // splitLine: {
// // show: false,
// // // lineStyle: {
// // // color: "#cccccc",
// // // type: [4, 2],
// // // dashOffset: 4,
// // // },
// // },
// // axisLine: {
// // show: false,
// // },
// // axisLabel: {
// // show: false,
// // },
// // axisTick: {
// // show: false,
// // },
// // },
// // series: [
// // {
// // data: [1, 6, 3, 4, 7, 6, 0,8, 0, 10, 11, 12, 13, 14,15, 16, 17, 18, 19, 20, 21,22, 23, 24, 25, 26, 27, 28,29, 30, 31, 32, 33, 34, 35,36],
// // type: 'bar',
// // barWidth:30, //设置柱子的宽度
// // barGap:'100%',
// // barCategoryGap:'0%',
// // }
// // ]
// };
const level = [8, 7, 6, 5, 4, 3, 2];
let arr = [2, 3, 4, 5, 6, 7]
return (
<Block>

@ -221,7 +221,9 @@ export default class Recording extends Component<any, any> {
if (item.id === id) {
item.detail = res.data.data;
item.detail.map((obj) => {
let updateTime = getdates(obj.updateTime);
let updateTime = obj.updateTime
? getdates(obj.updateTime)
: getdates(obj.createTime);
obj.updateTime = updateTime && updateTime.replace(/-/g, ".");
});
@ -296,7 +298,7 @@ export default class Recording extends Component<any, any> {
case 2:
this.two(item);
break;
case 3:
case 6:
this.three(item);
break;
default:
@ -322,9 +324,9 @@ export default class Recording extends Component<any, any> {
two = async (item) => {
console.log("打开第二种类型", item);
};
// 打开第种类型
// 打开第种类型
three = async (item) => {
console.log("打开第二种类型", item);
go("/recoding/pages/moisture_test_report/moisture_test_report");
};
// 打开其他类型
AllDevice = async (item) => {
@ -464,8 +466,8 @@ export default class Recording extends Component<any, any> {
>
<Image
className="products_cover"
src={item.banner}
mode="aspectFit"
src={item.logo}
mode="aspectFill"
></Image>
<View className="products_title">{item.name}</View>
</View>
@ -660,7 +662,7 @@ export default class Recording extends Component<any, any> {
{item.isMore && item.detail && (
<View>
{item.detail.map((obj) => (
<View key={obj}>
<View key={obj.id}>
<View style="height: 57rpx"></View>
<View className="month_item">
<View className="month_item_date">

Loading…
Cancel
Save