sonar medium 65 left

This commit is contained in:
Cindy Chang
2024-08-01 15:49:03 +08:00
parent 405dd7f992
commit a426f22db0
8 changed files with 35 additions and 45 deletions

View File

@@ -363,14 +363,12 @@ export default {
@apply sticky top-0 left-0 z-10 bg-neutral-10 @apply sticky top-0 left-0 z-10 bg-neutral-10
} }
:deep(.p-datatable .p-datatable-thead > tr > th) { :deep(.p-datatable .p-datatable-thead > tr > th) {
@apply !border-y-0 border-neutral-500 bg-neutral-100 after:absolute after:left-0 after:w-full after:h-full after:block after:top-0 after:border-b after:border-t after:border-neutral-500 @apply !border-y-0 border-neutral-500 bg-neutral-100 after:absolute after:left-0 after:w-full after:h-full after:block after:top-0 after:border-b after:border-t after:border-neutral-500;
white-space: nowrap;
} }
:deep(.p-datatable .p-datatable-tbody > tr > td) { :deep(.p-datatable .p-datatable-tbody > tr > td) {
@apply border-neutral-500 !border-t-0 text-center @apply border-neutral-500 !border-t-0 text-center
} }
:deep(.p-datatable .p-datatable-thead > tr > th) {
white-space: nowrap;
}
:deep(.p-datatable.p-datatable-gridlines .p-datatable-tbody > tr > td) { :deep(.p-datatable.p-datatable-gridlines .p-datatable-tbody > tr > td) {
min-width: 72px; min-width: 72px;
max-width: 184px; max-width: 184px;

View File

@@ -576,7 +576,7 @@ export default {
break break
} }
break; break;
case 'Trace': // Filter Type 選 Trace 的行為 case 'Trace': { // Filter Type 選 Trace 的行為
const lowerIndex = this.$refs.filterTraceView.selectArea[0]; const lowerIndex = this.$refs.filterTraceView.selectArea[0];
const upperIndex = this.$refs.filterTraceView.selectArea[1]-1; const upperIndex = this.$refs.filterTraceView.selectArea[1]-1;
data = { data = {
@@ -586,6 +586,7 @@ export default {
is_exclude: isExclude, is_exclude: isExclude,
}; };
break; break;
}
case 'Timeframes': // Filter Type 選 Timeframes 的行為 case 'Timeframes': // Filter Type 選 Timeframes 的行為
data = { data = {
type: containmentMap[sele[6]], type: containmentMap[sele[6]],
@@ -643,7 +644,7 @@ export default {
case 'Start & End': case 'Start & End':
return this.handleStartEndSelection(sele[2]); return this.handleStartEndSelection(sele[2]);
case 'Sequence': case 'Sequence':
return !(this.listSeq.length >= 2); return this.listSeq.length < 2;
default: default:
return true; return true;
} }

View File

@@ -24,22 +24,6 @@
</div> </div>
<!-- Files Page: Search and Upload --> <!-- Files Page: Search and Upload -->
<div class="flex justify-end items-center" v-if="navViewName === 'FILES'"> <div class="flex justify-end items-center" v-if="navViewName === 'FILES'">
<!-- <form role="search">
<label for="searchFiles" class="mr-4 relative">
<input type="search" id="searchFiles" placeholder="Search" class="px-5 py-2 w-72 rounded-full text-sm align-middle duration-300 border border-neutral-500 hover:border-neutral-300 focus:outline-none focus:ring focus:border-neutral-300">
<span class="absolute top-2 bottom-1.5 right-0.5 flex justify-center items-center gap-2">
<IconSetting class="w-6 h-6 cursor-pointer"></IconSetting>
<span class="w-px h-6 block after:border after:border-neutral-300 after:content-['']"></span>
<button class="pr-2">
<IconSearch class="w-6 h-6"></IconSearch>
</button>
</span>
</label>
</form> -->
<!-- <label class="btn btn-sm btn-neutral cursor-pointer">
<input id="uploadFiles" class="hidden" type="file">
Upload
</label> -->
<div id="import_btn" class="btn btn-sm btn-neutral cursor-pointer" @click="uploadModal = true"> <div id="import_btn" class="btn btn-sm btn-neutral cursor-pointer" @click="uploadModal = true">
Import Import
<UploadModal :visible="uploadModal" @closeModal="uploadModal = $event"></UploadModal> <UploadModal :visible="uploadModal" @closeModal="uploadModal = $event"></UploadModal>
@@ -54,7 +38,6 @@
:disabled="disabledSave" @click="saveModal"> :disabled="disabledSave" @click="saveModal">
Save Save
</button> </button>
<!-- <button class="btn btn-sm btn-neutral">Download</button> -->
</div> </div>
<AcctMenu/> <AcctMenu/>
</div> </div>

View File

@@ -1,7 +1,9 @@
<template> <template>
<form role="search"> <form role="search">
<label for="searchFiles" class="mr-4 relative"> <label for="searchFiles" class="mr-4 relative" htmlFor="searchFiles">
<input type="search" id="searchFiles" placeholder="Search Activity" class="px-5 py-2 w-52 rounded-full text-sm align-middle duration-300 border bg-neutral-100 border-neutral-300 hover:border-neutral-500 focus:outline-none focus:ring focus:border-neutral-500"> <input type="search" id="searchFiles" placeholder="Search Activity" class="px-5 py-2 w-52 rounded-full text-sm align-middle
duration-300 border bg-neutral-100 border-neutral-300 hover:border-neutral-500 focus:outline-none focus:ring
focus:border-neutral-500">
<span class="absolute top-2 bottom-0.5 right-0.5 flex justify-center items-center gap-2"> <span class="absolute top-2 bottom-0.5 right-0.5 flex justify-center items-center gap-2">
<IconSetting class="w-6 h-6 cursor-pointer"></IconSetting> <IconSetting class="w-6 h-6 cursor-pointer"></IconSetting>
<span class="w-px h-6 block after:border after:border-neutral-300 after:content-['']"></span> <span class="w-px h-6 block after:border after:border-neutral-300 after:content-['']"></span>

View File

@@ -123,7 +123,6 @@ export default {
this[unit] = newValues[unit].val; this[unit] = newValues[unit].val;
const input = document.querySelector(`[data-tunit="${unit}"]`); const input = document.querySelector(`[data-tunit="${unit}"]`);
if (input) { if (input) {
// input.value = newValues[unit].val.toString().padStart(2, '0'); // 前綴要補 0
input.value = newValues[unit].val.toString(); input.value = newValues[unit].val.toString();
} }
} }
@@ -144,14 +143,18 @@ export default {
max: { max: {
handler: function(newValue, oldValue) { handler: function(newValue, oldValue) {
this.maxTotal = newValue; this.maxTotal = newValue;
this.size === 'max' && newValue !== oldValue ? this.createData() : null; if(this.size === 'max' && newValue !== oldValue) {
this.createData();
};
}, },
immediate: true, immediate: true,
}, },
min: { min: {
handler: function(newValue, oldValue) { handler: function(newValue, oldValue) {
this.minTotal = newValue; this.minTotal = newValue;
this.size === 'min' && newValue !== oldValue ? this.createData() : null; if( this.size === 'min' && newValue !== oldValue){
this.createData();
}
}, },
immediate: true, immediate: true,
}, },
@@ -192,10 +195,11 @@ export default {
let baseInputValue = event.target.value; let baseInputValue = event.target.value;
let decoratedInputValue; let decoratedInputValue;
// 讓前綴數字自動補 0 // 讓前綴數字自動補 0
isNaN(event.target.value) ? if(isNaN(event.target.value)){
event.target.value = '00' : event.target.value = '00';
// event.target.value = event.target.value.toString().padStart(2, '0'); // 前綴要補 0 } else {
event.target.value = event.target.value.toString(); event.target.value = event.target.value.toString();
}
decoratedInputValue = event.target.value.toString(); decoratedInputValue = event.target.value.toString();
// 手 key 數值大於最大值時,要等於最大值 // 手 key 數值大於最大值時,要等於最大值

View File

@@ -404,7 +404,7 @@ export async function renameModal(rename, type, id, baseName) {
// 改名成功 // 改名成功
if(isConfirmed) await rename(type, id, value); if(isConfirmed) await rename(type, id, value);
// 清空欄位 // 清空欄位
fileName = ''; // fileName = '';
} }
/** /**
* Delete File * Delete File

View File

@@ -210,7 +210,9 @@ export default {
if(!code || code === 'case_attributes') return; if(!code || code === 'case_attributes') return;
nameOccurrences[name]++; nameOccurrences[name]++;
// 重複的選項只出現一次 // 重複的選項只出現一次
nameOccurrences[name] === 2 ? noSortedRepeatedData.push(item) : false; if(nameOccurrences[name] === 2){
noSortedRepeatedData.push(item)
}
// 要按照選單的順序排序 // 要按照選單的順序排序
this.repeatedData = this.columnType.filter(column => noSortedRepeatedData.includes(column)); this.repeatedData = this.columnType.filter(column => noSortedRepeatedData.includes(column));
}else { }else {

View File

@@ -59,8 +59,8 @@ module.exports = {
}, },
'fadeout': { 'fadeout': {
'0%': { opacity: '1' }, '0%': { opacity: '1' },
'0%': { opacity: '0.5' }, '50%': { opacity: '0.5' },
'0%': { opacity: '0' }, '100%': { opacity: '0' },
}, },
'edit': { 'edit': {
'0%, 100%': { transform: 'rotate(0deg)' }, '0%, 100%': { transform: 'rotate(0deg)' },