| | |
| | | <div class="min-dur">
|
| | | <div class="title">抓拍前录像时长</div>
|
| | | <div class="entity">
|
| | | <div class="sec">{{ min_video_len }}s</div>
|
| | | <div class="sec">0s</div>
|
| | | <div class="block">
|
| | | <el-slider
|
| | | v-model="fakeObj.min"
|
| | | id="cut_min_duration"
|
| | | :min="5 / 1.2"
|
| | | :min="0"
|
| | | :max="100"
|
| | | :step="5 / 1.2"
|
| | | @input="min_len = min_video_len"
|
| | |
| | | :format-tooltip="formatTooltip"
|
| | | ></el-slider>
|
| | | </div>
|
| | | <div class="sec" style="margin: 0 20px">120s</div>
|
| | | <el-input-number
|
| | | v-model="min_len"
|
| | | @change="fakeObj.min = +(min_len / 1.2)"
|
| | | :min="5"
|
| | | :min="0"
|
| | | :step="5"
|
| | | :max="120"
|
| | | step-strictly
|
| | | size="small"
|
| | | ></el-input-number
|
| | | > s -->
|
| | |
|
| | | <el-input-number
|
| | | v-model="min_len"
|
| | | @change="fakeObj.min = +(min_len / 1.2)"
|
| | | :min="5"
|
| | | :step="5"
|
| | | :max="120"
|
| | | step-strictly
|
| | | size="small"
|
| | | ></el-input-number
|
| | | > s
|
| | | >s
|
| | | </div>
|
| | | </div>
|
| | | <div class="min-dur">
|
| | | <div class="title">抓拍后录像时长</div>
|
| | | <div class="entity">
|
| | | <div class="sec">{{ max_video_len }} s</div>
|
| | | <div class="sec">0s</div>
|
| | | <div class="block">
|
| | | <el-slider
|
| | | v-model="fakeObj.max"
|
| | | id="cut_max_duration"
|
| | | :min="5 / 1.2"
|
| | | :min="0"
|
| | | @input="max_len = max_video_len"
|
| | | :max="100"
|
| | | :step="5 / 1.2"
|
| | |
| | | :show-tooltip="true"
|
| | | ></el-slider>
|
| | | </div>
|
| | | <div class="sec" style="margin: 0 20px">120s</div>
|
| | | <el-input-number
|
| | | v-model="max_len"
|
| | | @change="fakeObj.max = +(max_len / 1.2)"
|
| | | :min="5"
|
| | | :min="0"
|
| | | :step="5"
|
| | | step-strictly
|
| | | :max="120"
|
| | |
| | | action=""
|
| | | :http-request="uploadSound"
|
| | | :show-file-list="false"
|
| | | style="bottom: -94px; left: calc(50% - 217px)"
|
| | | >
|
| | | <div class="info">
|
| | | 请将声音事件文件拖拽到此处,或<span class="info-click"
|
| | |
| | | mounted() {
|
| | | this.getDeviceInfo();
|
| | | this.getSounds();
|
| | | let _this = this;
|
| | | this.eventAudio.addEventListener("ended", () => {
|
| | | if (_this.curPlayingIndex !== null && _this.soundList.length) {
|
| | | _this.soundList[_this.curPlayingIndex].isPlay = false;
|
| | | _this.curPlayingIndex = null;
|
| | | }
|
| | | });
|
| | | const url = this.curUser.backgroundpic;
|
| | | this.activeIcons = this.curUser.useIconType - 1;
|
| | | this.universalColor = this.colorList.findIndex((x) => {
|
| | |
| | | } else {
|
| | | this.activeBg = 0;
|
| | | }
|
| | | const e = this.$refs.curPage;
|
| | | e.addEventListener("click", (e) => {
|
| | | if (this.showUpload) {
|
| | | this.showUpload = false;
|
| | | }
|
| | | });
|
| | |
|
| | | this.eventAudio.addEventListener("ended", this.endedHandle, false);
|
| | | this.$refs.curPage.addEventListener("click", this.clickHandle, false);
|
| | | },
|
| | | beforeDestroy() {
|
| | | this.$refs.curPage.removeEventListener("click");
|
| | | this.eventAudio.removeEventListener("ended", this.endedHandle, false);
|
| | | this.$refs.curPage.removeEventListener("click", this.clickHandle, false);
|
| | | },
|
| | | computed: {
|
| | | min_video_len() {
|
| | |
| | | },
|
| | | },
|
| | | methods: {
|
| | | endedHandle() {
|
| | | let _this = this;
|
| | | if (_this.curPlayingIndex !== null && _this.soundList.length) {
|
| | | _this.soundList[_this.curPlayingIndex].isPlay = false;
|
| | | _this.curPlayingIndex = null;
|
| | | }
|
| | | },
|
| | | clickHandle() {
|
| | | let _this = this;
|
| | | if (this.showUpload) {
|
| | | this.showUpload = false;
|
| | | }
|
| | | },
|
| | | formatTooltip(v) {
|
| | | return Math.round(v * 1.2);
|
| | | },
|
| | |
| | | this.getSounds();
|
| | | },
|
| | | (err) => {
|
| | | this.$message.error("声音上传失败");
|
| | | this.$message.error(err.msg);
|
| | | }
|
| | | );
|
| | | },
|
| | |
| | | .sec {
|
| | | min-width: 30px;
|
| | | line-height: 80px;
|
| | | margin-right: 10px;
|
| | |
|
| | | color: #333;
|
| | | font-size: 8px;
|
| | | }
|
| | | .block {
|
| | | flex: 1;
|
| | | margin: 0 20px 0 6px;
|
| | | margin: 0 0px 0 6px;
|
| | | }
|
| | | .el-input-number--small {
|
| | | width: 100px;
|
| | |
| | | }
|
| | |
|
| | | .upload-demo {
|
| | | top: 452px;
|
| | | left: 2px !important;
|
| | | width: 452px;
|
| | | height: 150px;
|
| | | background: #ffffff;
|
| | |
| | | /* color: var(--colorCard); */
|
| | | color: #4e94ff;
|
| | | }
|
| | | </style>
|
| | | </style> |