|
|
@@ -8,6 +8,9 @@ import NotiFrequency from './components/NotiFrequency.vue'
|
|
|
import ShipmentRange from './components/ShipmentRange.vue'
|
|
|
import NotiMethods from './components/NotiMethods.vue'
|
|
|
import submitsucessful from './images/submit_successful.png'
|
|
|
+import { useRouter } from 'vue-router'
|
|
|
+
|
|
|
+const router = useRouter()
|
|
|
interface CheckboxItem {
|
|
|
value: string
|
|
|
label: string
|
|
|
@@ -17,11 +20,11 @@ interface Props {
|
|
|
TitleType: String
|
|
|
}
|
|
|
const MilestoneOceanListInit = ref<CheckboxItem[]>([])
|
|
|
-const MilestoneOceanListChecked = ref()
|
|
|
+const MilestoneOceanListChecked = ref([])
|
|
|
const MilestoneAirListInit = ref<CheckboxItem[]>([])
|
|
|
-const MilestoneAirListChecked = ref()
|
|
|
+const MilestoneAirListChecked = ref([])
|
|
|
const ContainerOceanListInit = ref<CheckboxItem[]>([])
|
|
|
-const ContainerOceanListChecked = ref()
|
|
|
+const ContainerOceanListChecked = ref([])
|
|
|
const props = defineProps<Props>()
|
|
|
let savesubscribeobj: any = {}
|
|
|
const RulesActive = ref([
|
|
|
@@ -31,13 +34,18 @@ const RulesActive = ref([
|
|
|
'NotificationMethod'
|
|
|
])
|
|
|
const OceanCheckList = ref()
|
|
|
+const OceanCheckListCode = ref()
|
|
|
const AirCheckList = ref()
|
|
|
+const AirCheckListCode = ref()
|
|
|
const ContainerOceanList = ref()
|
|
|
+const ContainerOceanCode = ref()
|
|
|
const IsFirstActive = ref(true)
|
|
|
const IsTwoActive = ref(true)
|
|
|
const IsThreeActive = ref(true)
|
|
|
const IsFourActive = ref(true)
|
|
|
const UnableSaveVisible = ref(false)
|
|
|
+const SaveVisibleError = ref(false)
|
|
|
+const SaveVisibleDetected = ref(false)
|
|
|
const SaveedVisible = ref(false)
|
|
|
const DelayedDeparturedList = ref()
|
|
|
const DelayedAirdList = ref()
|
|
|
@@ -56,6 +64,9 @@ const DelayedDataInitAir = ref()
|
|
|
const OceanETDInit = ref()
|
|
|
const AirETDInit = ref()
|
|
|
const ShipmentRangeMil = ref()
|
|
|
+const ShipmentRangeCon = ref()
|
|
|
+const ShipmentRangeDep = ref()
|
|
|
+const ShipmentRangeETD = ref()
|
|
|
|
|
|
const MonitoringList = ref()
|
|
|
const getInitMonitoring = () => {
|
|
|
@@ -76,9 +87,11 @@ onMounted(() => {
|
|
|
Initdata()
|
|
|
})
|
|
|
// 初始赋值
|
|
|
+const editTableidtwo = ref('')
|
|
|
const Initdata = () => {
|
|
|
if (sessionStorage.getItem('editTableid') != null) {
|
|
|
const editTableid = sessionStorage.getItem('editTableid')
|
|
|
+ editTableidtwo.value = sessionStorage.getItem('editTableid')
|
|
|
const editTablerules_type = sessionStorage.getItem('editTablerules_type')
|
|
|
$api
|
|
|
.EditMonitoringTable({
|
|
|
@@ -92,12 +105,82 @@ const Initdata = () => {
|
|
|
MethodsDataMil.value = res.data.Milestone_Update
|
|
|
ShipmentRangeMil.value = res.data.Milestone_Update
|
|
|
MilestoneOceanListInit.value = res.data.Milestone_Update.OceanCheckBoxList
|
|
|
+ OceanCheckListCode.value = []
|
|
|
MilestoneOceanListChecked.value = res.data.Milestone_Update.OceanCheckedList
|
|
|
- OceanCheckList.value = res.data.Milestone_Update.OceanCheckedList
|
|
|
+ OceanCheckListCode.value = res.data.Milestone_Update.OceanCheckedList
|
|
|
+ OceanCheckList.value = []
|
|
|
+ // 遍历选中的value值,找到对应的label值
|
|
|
+ MilestoneOceanListChecked.value.forEach((value) => {
|
|
|
+ const option = MilestoneOceanListInit.value.find((item) => item.value === value)
|
|
|
+ if (option) {
|
|
|
+ OceanCheckList.value.push(option.label)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ AirCheckListCode.value = []
|
|
|
MilestoneAirListInit.value = res.data.Milestone_Update.AirCheckBoxList
|
|
|
MilestoneAirListChecked.value = res.data.Milestone_Update.AirCheckedList
|
|
|
- AirCheckList.value = res.data.Milestone_Update.AirCheckedList
|
|
|
+ AirCheckListCode.value = res.data.Milestone_Update.AirCheckedList
|
|
|
+ AirCheckList.value = []
|
|
|
+ // 遍历选中的value值,找到对应的label值
|
|
|
+ MilestoneAirListChecked.value.forEach((value) => {
|
|
|
+ const option = MilestoneAirListInit.value.find((item) => item.value === value)
|
|
|
+ if (option) {
|
|
|
+ AirCheckList.value.push(option.label)
|
|
|
+ }
|
|
|
+ })
|
|
|
createListMilestone.value = res.data.Milestone_Update.shipment_details
|
|
|
+ } else if (editTablerules_type == 'Container_Status_Update') {
|
|
|
+ ContainerOceanCode.value = []
|
|
|
+ ContainerOceanListInit.value = res.data.Container_Status_Update.CtnrCheckBoxList
|
|
|
+ ContainerOceanListChecked.value = res.data.Container_Status_Update.CtnrCheckedList
|
|
|
+ ContainerOceanCode.value = res.data.Container_Status_Update.CtnrCheckedList
|
|
|
+ ContainerOceanList.value = []
|
|
|
+ // 遍历选中的value值,找到对应的label值
|
|
|
+ ContainerOceanListChecked.value.forEach((value) => {
|
|
|
+ const option = ContainerOceanListInit.value.find((item) => item.value === value)
|
|
|
+ if (option) {
|
|
|
+ ContainerOceanList.value.push(option.label)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ FrequencyDataCon.value = res.data.Container_Status_Update
|
|
|
+ MethodsDataCon.value = res.data.Container_Status_Update
|
|
|
+ ShipmentRangeCon.value = res.data.Container_Status_Update
|
|
|
+ } else if (editTablerules_type == 'Departure/Arrival_Delay') {
|
|
|
+ let OceanObj: any = {}
|
|
|
+ OceanObj.atd_etd = res.data['Departure/Arrival_Delay'].ocean_atd_sub_etd
|
|
|
+ OceanObj.atd_etd_unit = res.data['Departure/Arrival_Delay'].ocean_atd_sub_etd_unit
|
|
|
+ OceanObj.ata_eta = res.data['Departure/Arrival_Delay'].ocean_ata_sub_eta
|
|
|
+ OceanObj.ata_eta_unit = res.data['Departure/Arrival_Delay'].ocean_ata_sub_eta_unit
|
|
|
+ DelayedDataInit.value = OceanObj
|
|
|
+ let AirObj: any = {}
|
|
|
+ AirObj.atd_etd = res.data['Departure/Arrival_Delay'].air_atd_sub_etd
|
|
|
+ AirObj.atd_etd_unit = res.data['Departure/Arrival_Delay'].air_atd_sub_etd_unit
|
|
|
+ AirObj.ata_eta = res.data['Departure/Arrival_Delay'].air_ata_sub_eta
|
|
|
+ AirObj.ata_eta_unit = res.data['Departure/Arrival_Delay'].air_ata_sub_eta_unit
|
|
|
+ DelayedDataInitAir.value = AirObj
|
|
|
+ FrequencyDataDep.value = res.data['Departure/Arrival_Delay']
|
|
|
+ MethodsDataDep.value = res.data['Departure/Arrival_Delay']
|
|
|
+ ShipmentRangeDep.value = res.data['Departure/Arrival_Delay']
|
|
|
+ } else if (editTablerules_type == 'ETD/ETA_Change') {
|
|
|
+ let OceanChange: any = {}
|
|
|
+ OceanChange.ETDradio = res.data['ETD/ETA_Change'].ocean_etd_change
|
|
|
+ OceanChange.etd_old_sub_new = res.data['ETD/ETA_Change'].ocean_etd_old_sub_new
|
|
|
+ OceanChange.etd_old_sub_new_unit = res.data['ETD/ETA_Change'].ocean_etd_old_sub_new_unit
|
|
|
+ OceanChange.ETAradio = res.data['ETD/ETA_Change'].ocean_eta_change
|
|
|
+ OceanChange.eta_old_sub_new = res.data['ETD/ETA_Change'].ocean_eta_old_sub_new
|
|
|
+ OceanChange.eta_old_sub_new_unit = res.data['ETD/ETA_Change'].ocean_eta_old_sub_new_unit
|
|
|
+ OceanETDInit.value = OceanChange
|
|
|
+ let AirChange: any = {}
|
|
|
+ AirChange.ETDradio = res.data['ETD/ETA_Change'].air_etd_change
|
|
|
+ AirChange.etd_old_sub_new = res.data['ETD/ETA_Change'].air_etd_old_sub_new
|
|
|
+ AirChange.etd_old_sub_new_unit = res.data['ETD/ETA_Change'].air_etd_old_sub_new_unit
|
|
|
+ AirChange.ETAradio = res.data['ETD/ETA_Change'].air_eta_change
|
|
|
+ AirChange.eta_old_sub_new = res.data['ETD/ETA_Change'].air_eta_old_sub_new
|
|
|
+ AirChange.eta_old_sub_new_unit = res.data['ETD/ETA_Change'].air_eta_old_sub_new_unit
|
|
|
+ AirETDInit.value = AirChange
|
|
|
+ FrequencyDataETD.value = res.data['ETD/ETA_Change']
|
|
|
+ MethodsDataETD.value = res.data['ETD/ETA_Change']
|
|
|
+ ShipmentRangeETD.value = res.data['ETD/ETA_Change']
|
|
|
}
|
|
|
}
|
|
|
})
|
|
|
@@ -106,45 +189,16 @@ const Initdata = () => {
|
|
|
sessionStorage.removeItem('editTablerules_type')
|
|
|
}, 1000)
|
|
|
}
|
|
|
- // ContainerOceanListInit.value = val.CtnrCheckBoxList
|
|
|
- // ContainerOceanListChecked.value = val.CtnrCheckedList
|
|
|
- // ContainerOceanList.value = val.CtnrCheckedList
|
|
|
- // let OceanObj: any = {}
|
|
|
- // OceanObj.atd_etd = val.ocean_atd_sub_etd
|
|
|
- // OceanObj.atd_etd_unit = val.ocean_atd_sub_etd_unit
|
|
|
- // OceanObj.ata_eta = val.ocean_ata_sub_eta
|
|
|
- // OceanObj.ata_eta_unit = val.ocean_ata_sub_eta_unit
|
|
|
- // DelayedDataInit.value = OceanObj
|
|
|
- // let AirObj: any = {}
|
|
|
- // AirObj.atd_etd = val.air_atd_sub_etd
|
|
|
- // AirObj.atd_etd_unit = val.air_atd_sub_etd_unit
|
|
|
- // AirObj.ata_eta = val.air_ata_sub_eta
|
|
|
- // AirObj.ata_eta_unit = val.air_ata_sub_eta_unit
|
|
|
- // DelayedDataInitAir.value = AirObj
|
|
|
- // let OceanChange: any = {}
|
|
|
- // OceanChange.ETDradio = val.ocean_etd_change
|
|
|
- // OceanChange.etd_old_sub_new = val.ocean_etd_old_sub_new
|
|
|
- // OceanChange.etd_old_sub_new_unit = val.ocean_etd_old_sub_new_unit
|
|
|
- // OceanChange.ETAradio = val.ocean_eta_change
|
|
|
- // OceanChange.eta_old_sub_new = val.ocean_eta_old_sub_new
|
|
|
- // OceanChange.eta_old_sub_new_unit = val.ocean_eta_old_sub_new_unit
|
|
|
- // OceanETDInit.value = OceanChange
|
|
|
- // let AirChange: any = {}
|
|
|
- // AirChange.ETDradio = val.air_etd_change
|
|
|
- // AirChange.etd_old_sub_new = val.air_etd_old_sub_new
|
|
|
- // AirChange.etd_old_sub_new_unit = val.air_etd_old_sub_new_unit
|
|
|
- // AirChange.ETAradio = val.air_eta_change
|
|
|
- // AirChange.eta_old_sub_new = val.air_eta_old_sub_new
|
|
|
- // AirChange.eta_old_sub_new_unit = val.air_eta_old_sub_new_unit
|
|
|
- // AirETDInit.value = AirChange
|
|
|
}
|
|
|
|
|
|
// 给tag list赋值
|
|
|
-const ChangeCheckOceanRules = (val: any) => {
|
|
|
+const ChangeCheckOceanRules = (val: any, value: any) => {
|
|
|
OceanCheckList.value = val
|
|
|
+ OceanCheckListCode.value = value
|
|
|
}
|
|
|
-const ChangeContainerRules = (val: any) => {
|
|
|
+const ChangeContainerRules = (val: any, value: any) => {
|
|
|
ContainerOceanList.value = val
|
|
|
+ ContainerOceanCode.value = value
|
|
|
}
|
|
|
// delayed赋值
|
|
|
const ChangeDeayedRules = (val: any) => {
|
|
|
@@ -185,8 +239,9 @@ const ChangeAirRules = (val: any) => {
|
|
|
delete savesubscribeobj.air_ata_sub_eta_unit
|
|
|
}
|
|
|
}
|
|
|
-const ChangeCheckAirRules = (val: any) => {
|
|
|
+const ChangeCheckAirRules = (val: any, value: any) => {
|
|
|
AirCheckList.value = val
|
|
|
+ AirCheckListCode.value = value
|
|
|
}
|
|
|
|
|
|
//选择create new rules
|
|
|
@@ -478,24 +533,56 @@ const closeAirETD = (val: any) => {
|
|
|
AirETD.value.closeETD(val)
|
|
|
}
|
|
|
|
|
|
-const emits = defineEmits(['SavedAddedRules'])
|
|
|
-// 不保存修改的折叠面板
|
|
|
-
|
|
|
// 保存subscribe配置
|
|
|
const missingmessage = ref('')
|
|
|
// 保存成功调用接口
|
|
|
const SaveSuceessful = () => {
|
|
|
$api
|
|
|
.MonitoringSave({
|
|
|
- ...savesubscribeobj
|
|
|
+ ...savesubscribeobj,
|
|
|
+ is_similar_rule: false,
|
|
|
+ id: editTableidtwo.value
|
|
|
+ })
|
|
|
+ .then((res: any) => {
|
|
|
+ if (res.code === 200) {
|
|
|
+ console.log(res.data)
|
|
|
+ if(res.data.msg == 'Update Successful') {
|
|
|
+ SaveedVisible.value = true
|
|
|
+ setTimeout(() => {
|
|
|
+ SaveedVisible.value = false
|
|
|
+ sessionStorage.setItem('activeTab', 'Monitoring Settings')
|
|
|
+ router.push({
|
|
|
+ path: '/SystemSettings',
|
|
|
+ query: {}
|
|
|
+ })
|
|
|
+ }, 3000)
|
|
|
+ } else if(res.data.msg == 'Similar Rule Detected') {
|
|
|
+ SaveVisibleDetected.value = true
|
|
|
+ } else if(res.data.msg == 'Unable to Save')
|
|
|
+ SaveVisibleError.value = true
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+const HandelSaveVisibleDetected = () => {
|
|
|
+ SaveVisibleDetected.value = false
|
|
|
+ $api
|
|
|
+ .MonitoringSave({
|
|
|
+ ...savesubscribeobj,
|
|
|
+ is_similar_rule: true,
|
|
|
+ id: editTableidtwo.value
|
|
|
})
|
|
|
.then((res: any) => {
|
|
|
if (res.code === 200) {
|
|
|
- SaveedVisible.value = true
|
|
|
- setTimeout(() => {
|
|
|
- SaveedVisible.value = false
|
|
|
- emits('SavedAddedRules', res.data.addedRules, savesubscribeobj.rules_type)
|
|
|
- }, 3000)
|
|
|
+ SaveedVisible.value = true
|
|
|
+ setTimeout(() => {
|
|
|
+ SaveedVisible.value = false
|
|
|
+ sessionStorage.setItem('activeTab', 'Monitoring Settings')
|
|
|
+ router.push({
|
|
|
+ path: '/SystemSettings',
|
|
|
+ query: {}
|
|
|
+ })
|
|
|
+ }, 3000)
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
@@ -507,22 +594,23 @@ const Savesubscribe = () => {
|
|
|
if (
|
|
|
OceanCheckList.value == undefined ||
|
|
|
AirCheckList.value == undefined ||
|
|
|
+ OceanCheckList.value.length == 0 ||
|
|
|
+ AirCheckList.value.length == 0 ||
|
|
|
MilFrequencyList.value.length == 0 ||
|
|
|
MilMethodsList.value.length == 0 ||
|
|
|
createObj.Transportstr == '' ||
|
|
|
createObj.Timestr == ''
|
|
|
) {
|
|
|
- console.log(createObj)
|
|
|
if (createObj.Transportstr == '') {
|
|
|
missingmessage.value += 'Transport Mode, '
|
|
|
}
|
|
|
if (createObj.Timestr == '') {
|
|
|
missingmessage.value += 'Time, '
|
|
|
}
|
|
|
- if (OceanCheckList.value == undefined) {
|
|
|
+ if (OceanCheckList.value == undefined || OceanCheckList.value.length == 0) {
|
|
|
missingmessage.value += 'Ocean Shipments, '
|
|
|
}
|
|
|
- if (AirCheckList.value == undefined) {
|
|
|
+ if (AirCheckList.value == undefined || AirCheckList.value.length == 0) {
|
|
|
missingmessage.value += 'Air Shipments, '
|
|
|
}
|
|
|
if (MilFrequencyList.value.length == 0) {
|
|
|
@@ -534,8 +622,8 @@ const Savesubscribe = () => {
|
|
|
missingmessage.value = missingmessage.value.substring(0, missingmessage.value.length - 2)
|
|
|
UnableSaveVisible.value = true
|
|
|
} else {
|
|
|
- savesubscribeobj.ocean_milestone = OceanCheckList.value
|
|
|
- savesubscribeobj.air_milestone = AirCheckList.value
|
|
|
+ savesubscribeobj.ocean_milestone = OceanCheckListCode.value
|
|
|
+ savesubscribeobj.air_milestone = AirCheckListCode.value
|
|
|
str =
|
|
|
'Ocean Milestones: ' +
|
|
|
OceanCheckList.value.join(',') +
|
|
|
@@ -549,10 +637,11 @@ const Savesubscribe = () => {
|
|
|
savesubscribeobj.rules_type = 'Container_Status_Update'
|
|
|
if (
|
|
|
ContainerOceanList.value == undefined ||
|
|
|
+ ContainerOceanList.value.length == 0 ||
|
|
|
ConFrequencyList.value.length == 0 ||
|
|
|
ConMethodsList.value.length == 0
|
|
|
) {
|
|
|
- if (ContainerOceanList.value == undefined) {
|
|
|
+ if (ContainerOceanList.value == undefined || ContainerOceanList.value.length == 0) {
|
|
|
missingmessage.value += 'Ocean Shipments, '
|
|
|
}
|
|
|
if (ConFrequencyList.value.length == 0) {
|
|
|
@@ -564,7 +653,7 @@ const Savesubscribe = () => {
|
|
|
missingmessage.value = missingmessage.value.substring(0, missingmessage.value.length - 2)
|
|
|
UnableSaveVisible.value = true
|
|
|
} else {
|
|
|
- savesubscribeobj.ocean_ctnr_status = ContainerOceanList.value
|
|
|
+ savesubscribeobj.ocean_ctnr_status = ContainerOceanCode.value
|
|
|
str = 'Ocean Container: ' + ContainerOceanList.value.join(',')
|
|
|
savesubscribeobj.event_details = str
|
|
|
SaveSuceessful()
|
|
|
@@ -573,14 +662,16 @@ const Savesubscribe = () => {
|
|
|
savesubscribeobj.rules_type = 'Departure/Arrival_Delay'
|
|
|
if (
|
|
|
DelayedDeparturedList.value == undefined ||
|
|
|
+ DelayedDeparturedList.value.length == 0 ||
|
|
|
DelayedAirdList.value == undefined ||
|
|
|
+ DelayedAirdList.value.length == 0 ||
|
|
|
DepFrequencyList.value.length == 0 ||
|
|
|
DepMethodsList.value.length == 0
|
|
|
) {
|
|
|
- if (DelayedDeparturedList.value == undefined) {
|
|
|
+ if (DelayedDeparturedList.value == undefined || DelayedDeparturedList.value.length == 0) {
|
|
|
missingmessage.value += 'Ocean Shipments, '
|
|
|
}
|
|
|
- if (DelayedAirdList.value == undefined) {
|
|
|
+ if (DelayedAirdList.value == undefined || DelayedAirdList.value.length == 0) {
|
|
|
missingmessage.value += 'Air Shipments, '
|
|
|
}
|
|
|
if (DepFrequencyList.value.length == 0) {
|
|
|
@@ -606,10 +697,10 @@ const Savesubscribe = () => {
|
|
|
ETDFrequencyList.value.length == 0 ||
|
|
|
ETDMethodsList.value.length == 0
|
|
|
) {
|
|
|
- if (ETDOceanList.value == undefined) {
|
|
|
+ if (ETDOceanList.value == undefined || ETDOceanList.value.length == 0) {
|
|
|
missingmessage.value += 'Ocean Shipments, '
|
|
|
}
|
|
|
- if (ETDAirList.value == undefined) {
|
|
|
+ if (ETDAirList.value == undefined || ETDAirList.value.length == 0) {
|
|
|
missingmessage.value += 'Air Shipments, '
|
|
|
}
|
|
|
if (ETDFrequencyList.value.length == 0) {
|
|
|
@@ -673,7 +764,7 @@ defineExpose({
|
|
|
<el-collapse-item name="ShipmentRange">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsFourActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -694,18 +785,21 @@ defineExpose({
|
|
|
<ShipmentRange
|
|
|
ref="ShipmentRangeRef"
|
|
|
v-if="props.TitleType == 'Container'"
|
|
|
+ :ShipmentRangeData="ShipmentRangeCon"
|
|
|
@ChangeCheckRules="changecheckCreateRulesContainer"
|
|
|
@ChangeCheckTimeRules="ChangeCheckTimeRulesContainer"
|
|
|
></ShipmentRange>
|
|
|
<ShipmentRange
|
|
|
ref="ShipmentRangeRef"
|
|
|
v-if="props.TitleType == 'Departure'"
|
|
|
+ :ShipmentRangeData="ShipmentRangeDep"
|
|
|
@ChangeCheckRules="changecheckCreateRulesDeparture"
|
|
|
@ChangeCheckTimeRules="ChangeCheckTimeRulesDeparture"
|
|
|
></ShipmentRange>
|
|
|
<ShipmentRange
|
|
|
ref="ShipmentRangeRef"
|
|
|
v-if="props.TitleType == 'ETDChange'"
|
|
|
+ :ShipmentRangeData="ShipmentRangeETD"
|
|
|
@ChangeCheckRules="changecheckCreateRulesETDChange"
|
|
|
@ChangeCheckTimeRules="ChangeCheckTimeRulesETDChange"
|
|
|
></ShipmentRange>
|
|
|
@@ -720,7 +814,7 @@ defineExpose({
|
|
|
<el-collapse-item name="SelectMilestone">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsFirstActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -756,7 +850,7 @@ defineExpose({
|
|
|
<el-collapse-item name="SelectMilestone">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsFirstActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -784,7 +878,7 @@ defineExpose({
|
|
|
<el-collapse-item name="SelectMilestone">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsFirstActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -820,7 +914,7 @@ defineExpose({
|
|
|
<el-collapse-item name="SelectMilestone">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsFirstActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -856,7 +950,7 @@ defineExpose({
|
|
|
<el-collapse-item name="NotificationFrequency">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsTwoActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -900,7 +994,7 @@ defineExpose({
|
|
|
<el-collapse-item name="NotificationMethod">
|
|
|
<template #title>
|
|
|
<div class="Rules_Title">
|
|
|
- <span class="iconfont_icon">
|
|
|
+ <span class="iconfont_icon icon_dark">
|
|
|
<svg class="iconfont" aria-hidden="true">
|
|
|
<use
|
|
|
:xlink:href="IsThreeActive ? '#icon-icon_dropdown_b' : '#icon-icon_up_b'"
|
|
|
@@ -1075,6 +1169,65 @@ defineExpose({
|
|
|
<div style="text-align: center"><el-image :src="submitsucessful" /></div>
|
|
|
<div style="text-align: center; margin-top: 20px">Saved successfully</div>
|
|
|
</el-dialog>
|
|
|
+ <!-- 保存失败 -->
|
|
|
+ <el-dialog v-model="SaveVisibleError" width="480">
|
|
|
+ <div>Duplicate Rule Error.</div>
|
|
|
+ <div>This rule exactly matches an existing rule.</div>
|
|
|
+ <template #footer>
|
|
|
+ <div class="dialog-footer">
|
|
|
+ <el-button
|
|
|
+ class="el-button--danger"
|
|
|
+ @click="SaveVisibleError = false"
|
|
|
+ style="width: 100px"
|
|
|
+ >
|
|
|
+ OK
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ <template #header>
|
|
|
+ <div class="cancel_header">
|
|
|
+ <span class="iconfont_icon iconfont_warning">
|
|
|
+ <svg class="iconfont icon_danger" aria-hidden="true">
|
|
|
+ <use xlink:href="#icon-icon_fail_fill_b"></use>
|
|
|
+ </svg>
|
|
|
+ </span>
|
|
|
+ Unable to Save
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
+ <!-- 三项重合提示 -->
|
|
|
+ <el-dialog v-model="SaveVisibleDetected" width="480">
|
|
|
+ <div>A similar configuration rule already exists.</div>
|
|
|
+ <div>Would you like to proceed with creating this rule?</div>
|
|
|
+ <template #footer>
|
|
|
+ <div class="dialog-footer">
|
|
|
+ <el-button
|
|
|
+ class="el-button--default"
|
|
|
+ @click="SaveVisibleDetected = false"
|
|
|
+ style="width: 100px"
|
|
|
+ >
|
|
|
+ Cancel
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ class="el-button--warning"
|
|
|
+ @click="HandelSaveVisibleDetected"
|
|
|
+ style="width: 100px"
|
|
|
+ >
|
|
|
+ Save
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ <template #header>
|
|
|
+ <div class="cancel_header">
|
|
|
+ <span class="iconfont_icon iconfont_warning">
|
|
|
+ <svg class="iconfont icon_warning" aria-hidden="true">
|
|
|
+ <use xlink:href="#icon-icon_tipsfilled_b"></use>
|
|
|
+ </svg>
|
|
|
+ </span>
|
|
|
+ Similar Rule Detected
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
</template>
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
@@ -1124,7 +1277,7 @@ defineExpose({
|
|
|
padding: 0 !important;
|
|
|
}
|
|
|
:deep(.el-collapse-item__header):hover {
|
|
|
- background-color: #fff !important;
|
|
|
+ background-color: var(--color-system-color-bg) !important;
|
|
|
border: none !important;
|
|
|
}
|
|
|
:deep(.el-collapse-item__arrow) {
|
|
|
@@ -1150,26 +1303,26 @@ defineExpose({
|
|
|
transform: rotate(0);
|
|
|
}
|
|
|
:deep(.Ocean_collapse .el-collapse-item__header) {
|
|
|
- background-color: #fff !important;
|
|
|
+ background-color: var(--color-system-color-bg) !important;
|
|
|
padding: 0 8px !important;
|
|
|
height: 40px !important;
|
|
|
}
|
|
|
:deep(.Ocean_collapse .el-collapse-item) {
|
|
|
- background-color: var(--color-dialog-header-bg);
|
|
|
+ background-color: var(--color-system-color-bg);
|
|
|
border-radius: 12px;
|
|
|
}
|
|
|
:deep(.Ocean_collapse .el-collapse-item__wrap) {
|
|
|
padding: 0 8px !important;
|
|
|
}
|
|
|
:deep(.Ocean_collapse .el-collapse-item__header.is-active) {
|
|
|
- background-color: var(--color-dialog-header-bg) !important;
|
|
|
+ background-color: var(--color-system-color-bg) !important;
|
|
|
}
|
|
|
:deep(.el-checkbox__input.is-checked + .el-checkbox__label) {
|
|
|
color: var(--color-neutral-1);
|
|
|
}
|
|
|
.Rules_buttom {
|
|
|
padding: 8px;
|
|
|
- border-top: 1px solid var(--color-border-1);
|
|
|
+ border-top: 1px solid var(--color-system-border-1);
|
|
|
}
|
|
|
.rules_button {
|
|
|
width: 100px;
|
|
|
@@ -1193,7 +1346,7 @@ defineExpose({
|
|
|
align-items: center;
|
|
|
}
|
|
|
:deep(header.el-dialog__header) {
|
|
|
- background-color: #fff;
|
|
|
+ background-color: var(--color-system-body-bg);
|
|
|
}
|
|
|
:deep(footer.el-dialog__footer) {
|
|
|
border-top: none;
|
|
|
@@ -1201,24 +1354,4 @@ defineExpose({
|
|
|
:deep(.el-collapse) {
|
|
|
margin-right: 8px;
|
|
|
}
|
|
|
-
|
|
|
-:deep(.el-radio-group) {
|
|
|
- display: block;
|
|
|
-}
|
|
|
-:deep(.el-radio) {
|
|
|
- display: flex;
|
|
|
- min-height: 32px;
|
|
|
- border: 1px solid var(--color-select-border);
|
|
|
- margin-bottom: 4px;
|
|
|
- border-radius: 6px;
|
|
|
- padding: 0 8px;
|
|
|
- margin-right: 0;
|
|
|
- height: fit-content;
|
|
|
- line-height: 32px;
|
|
|
- align-items: start;
|
|
|
- align-items: start;
|
|
|
-}
|
|
|
-:deep(.el-radio__input.is-checked + .el-radio__label) {
|
|
|
- color: var(--color-neutral-1);
|
|
|
-}
|
|
|
</style>
|