react18 PC调用电脑摄像头
\'use client\'; import React, { useEffect, useRef, useState } from \'react\'; import styles from \'./index.module.scss\'; import { Button, Iconfont } from \'@/components\'; import { i18n } from \'@/lib/i18n\';
dayjs取 本周、上周、本月、上月、本季度、上季度时间段
const weekStart = 1; // 1表示周一是一周的开始,0表示周日是一周的开始 // 获取上周的起始日期和结束日期 function getLastWeek() { const startOfWeek = dayjs().subtract(1, \"week\").day(weekStart).format(\"YYYY-MM-DD\") + \" 00:00:00\"; const endO
