diff --git a/src/App.vue b/src/App.vue index ff121a2..5bb4f10 100644 --- a/src/App.vue +++ b/src/App.vue @@ -4,7 +4,7 @@ import { onMounted } from 'vue'; import appBridge from '@/assets/js/appBridge'; import utils from '@/assets/js/common'; -onMounted(async () => { +onMounted(async() => { if (utils.getParameter('digitalYiliToken')) { // 隐藏/显示 header appBridge.setHeaderShown(false); diff --git a/src/components/YLPicker.vue b/src/components/YLPicker.vue index a172ec1..1e98e52 100644 --- a/src/components/YLPicker.vue +++ b/src/components/YLPicker.vue @@ -167,8 +167,8 @@ const getMaxDateLimit = computed(() => { props.format ); const tempStr = '0000-12-31 23:59:59'; - const result = - props.maxDate.length !== 0 && thisMax.length > props.maxDate.length + const result + = props.maxDate.length !== 0 && thisMax.length > props.maxDate.length ? thisMax.slice(0, props.maxDate.length) + tempStr.slice(props.maxDate.length) : thisMax; return result.slice(0, props.format.length); @@ -191,8 +191,8 @@ function onChange({ selectedValues, columnIndex }) { renderMinuteColumns, renderSecondColumns ]; - updateColumns[columnIndex] && - updateColumns[columnIndex](changeValue, getMinDateLimit.value, getMaxDateLimit.value, false); + updateColumns[columnIndex] + && updateColumns[columnIndex](changeValue, getMinDateLimit.value, getMaxDateLimit.value, false); } // 渲染全部列 diff --git a/src/fonts/demo.css b/src/fonts/demo.css index 0e97475..7df7d71 100644 --- a/src/fonts/demo.css +++ b/src/fonts/demo.css @@ -4,11 +4,11 @@ src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834'); src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834#iefix') - format('embedded-opentype'), + format('embedded-opentype'), url('https://at.alicdn.com/t/font_985780_km7mi63cihi.woff?t=1545807318834') format('woff'), url('https://at.alicdn.com/t/font_985780_km7mi63cihi.ttf?t=1545807318834') format('truetype'), url('https://at.alicdn.com/t/font_985780_km7mi63cihi.svg?t=1545807318834#iconfont') - format('svg'); + format('svg'); src: url('//at.alicdn.com/t/c/font_4841764_vat2jbvw3q.woff2?t=1741575060989') format('woff2'), url('//at.alicdn.com/t/c/font_4841764_vat2jbvw3q.woff?t=1741575060989') format('woff'), diff --git a/src/fonts/moblie/demo.css b/src/fonts/moblie/demo.css index 18e8077..12ec742 100644 --- a/src/fonts/moblie/demo.css +++ b/src/fonts/moblie/demo.css @@ -4,11 +4,11 @@ src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834'); src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834#iefix') - format('embedded-opentype'), + format('embedded-opentype'), url('https://at.alicdn.com/t/font_985780_km7mi63cihi.woff?t=1545807318834') format('woff'), url('https://at.alicdn.com/t/font_985780_km7mi63cihi.ttf?t=1545807318834') format('truetype'), url('https://at.alicdn.com/t/font_985780_km7mi63cihi.svg?t=1545807318834#iconfont') - format('svg'); + format('svg'); } .logo { diff --git a/src/utils/request.js b/src/utils/request.js index e138fe5..16fd215 100644 --- a/src/utils/request.js +++ b/src/utils/request.js @@ -42,10 +42,10 @@ service.interceptors.request.use( service.interceptors.response.use( (response) => { if ( - response.status === 200 || - response.status === 201 || - response.status === 202 || - response.status === 204 + response.status === 200 + || response.status === 201 + || response.status === 202 + || response.status === 204 ) { if (response.config.method === 'put') { // message.success('保存中...'); diff --git a/src/views/Design/Index.vue b/src/views/Design/Index.vue index 17e4447..0b18fdb 100644 --- a/src/views/Design/Index.vue +++ b/src/views/Design/Index.vue @@ -50,8 +50,8 @@ { // 上下移动 const optionMove = (action) => { switch (action.action) { - case 'up': - if (activeIndex.value === 0) { - moveShow.value = false; - return false; - } - // 向上移动 - element.value.splice(activeIndex.value - 1, 0, element.value.splice(activeIndex.value, 1)[0]); - activeIndex.value -= 1; - break; - case 'down': - if (activeIndex.value === element.value.length - 1) { - moveShow.value = false; - return false; - } - element.value.splice(activeIndex.value + 1, 0, element.value.splice(activeIndex.value, 1)[0]); - activeIndex.value += 1; - break; + case 'up': + if (activeIndex.value === 0) { + moveShow.value = false; + return false; + } + // 向上移动 + element.value.splice(activeIndex.value - 1, 0, element.value.splice(activeIndex.value, 1)[0]); + activeIndex.value -= 1; + break; + case 'down': + if (activeIndex.value === element.value.length - 1) { + moveShow.value = false; + return false; + } + element.value.splice(activeIndex.value + 1, 0, element.value.splice(activeIndex.value, 1)[0]); + activeIndex.value += 1; + break; } }; diff --git a/src/views/Design/components/ActionCompoents/QuestionAction.vue b/src/views/Design/components/ActionCompoents/QuestionAction.vue index a58d814..712c8e4 100644 --- a/src/views/Design/components/ActionCompoents/QuestionAction.vue +++ b/src/views/Design/components/ActionCompoents/QuestionAction.vue @@ -233,8 +233,8 @@ const getSkipTypeText = (skipType) => { const ls = []; logics.map((item) => { if ( - item.skip_type === skipType && - item.question_index === activeQuestion.value.question_index + item.skip_type === skipType + && item.question_index === activeQuestion.value.question_index ) { ls.push(item); } @@ -250,13 +250,13 @@ const getSkipTypeText = (skipType) => { const questionSetting = (type) => { switch (type) { - case 'before': - questionBeforeShow.value = true; + case 'before': + questionBeforeShow.value = true; - break; - case 'after': - questionBeforeShow.value = true; - break; + break; + case 'after': + questionBeforeShow.value = true; + break; } skipType.value = type === 'before' ? 1 : 0; }; diff --git a/src/views/Design/components/ActionCompoents/components/QuestionItemAction/RateQuestionAction.vue b/src/views/Design/components/ActionCompoents/components/QuestionItemAction/RateQuestionAction.vue index 4c3be6e..4b9a9e8 100644 --- a/src/views/Design/components/ActionCompoents/components/QuestionItemAction/RateQuestionAction.vue +++ b/src/views/Design/components/ActionCompoents/components/QuestionItemAction/RateQuestionAction.vue @@ -108,9 +108,9 @@ function isSurplus() { return false; } else { return ( - parseFloat(((localConfig.value.max - localConfig.value.min) * 1000).toFixed(4, 10)) % - parseFloat((localConfig.value.score_interval * 1000).toFixed(4, 10)) === - 0 + parseFloat(((localConfig.value.max - localConfig.value.min) * 1000).toFixed(4, 10)) + % parseFloat((localConfig.value.score_interval * 1000).toFixed(4, 10)) + === 0 ); } } diff --git a/src/views/Design/components/Questions/MartrixQuestion.vue b/src/views/Design/components/Questions/MartrixQuestion.vue index f371bd1..c65b646 100644 --- a/src/views/Design/components/Questions/MartrixQuestion.vue +++ b/src/views/Design/components/Questions/MartrixQuestion.vue @@ -16,14 +16,14 @@ const { element } = defineProps<{ element: MatrixSurveyQuestion }>(); */ const tableInputTypeMapping = (/** regx?: any */) => { switch (element.question_type) { - case 8: - return 'text'; - case 9: - return 'radio'; - case 10: - return 'checkbox'; - default: - return 'radio'; + case 8: + return 'text'; + case 9: + return 'radio'; + case 10: + return 'checkbox'; + default: + return 'radio'; } }; diff --git a/src/views/Design/components/Questions/paging/Paging.vue b/src/views/Design/components/Questions/paging/Paging.vue index 57eb0e1..62d9592 100644 --- a/src/views/Design/components/Questions/paging/Paging.vue +++ b/src/views/Design/components/Questions/paging/Paging.vue @@ -11,8 +11,7 @@ class="iconfont active-icon" :style="{ marginRight: isLastPage ? '0' : '16px' }" @click="activePage" - > + > diff --git a/src/views/Survey/views/Create/Index.vue b/src/views/Survey/views/Create/Index.vue index 8a4b592..9c72ccd 100644 --- a/src/views/Survey/views/Create/Index.vue +++ b/src/views/Survey/views/Create/Index.vue @@ -457,14 +457,14 @@ const questionEvent = (item) => { options: item.json.options.length > 0 ? item.json.options.map((item) => { - return item.map((it) => { - return { - ...it, - // 主键生成 - id: uuidv4() - }; - }); - }) + return item.map((it) => { + return { + ...it, + // 主键生成 + id: uuidv4() + }; + }); + }) : [] }) ); @@ -597,7 +597,7 @@ const previewQuestion = () => { router.push({ name: 'preview', query: { ...route.query } }); }; -onMounted(async () => { +onMounted(async() => { await getQuestionDetail(); });