Compare commits
No commits in common. "V1.0" and "master" have entirely different histories.
BIN
dist_1.zip
BIN
dist_1.zip
Binary file not shown.
@ -21,7 +21,8 @@ export default {
|
|||||||
this.$store.dispatch('user/setUrlToken', token).then(() => {
|
this.$store.dispatch('user/setUrlToken', token).then(() => {
|
||||||
this.$router.push('/')
|
this.$router.push('/')
|
||||||
})
|
})
|
||||||
} else {
|
}
|
||||||
|
else {
|
||||||
this.$router.push('/login')
|
this.$router.push('/login')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
@ -172,7 +172,7 @@ export function deteleLog(data) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 获取网络抓包信息
|
// 获取网络抓包信息
|
||||||
export function getPacketCaptureInfo(data) {
|
export function getPacketCaptureInfo(data){
|
||||||
return request({
|
return request({
|
||||||
url: '/pcap/status',
|
url: '/pcap/status',
|
||||||
method: 'get',
|
method: 'get',
|
||||||
@ -180,7 +180,7 @@ export function getPacketCaptureInfo(data) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 开始抓包
|
// 开始抓包
|
||||||
export function startPacketCapture(data) {
|
export function startPacketCapture(data){
|
||||||
return request({
|
return request({
|
||||||
url: '/pcap/start',
|
url: '/pcap/start',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
@ -188,7 +188,7 @@ export function startPacketCapture(data) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 停止抓包
|
// 停止抓包
|
||||||
export function stopPacketCapture(data) {
|
export function stopPacketCapture(data){
|
||||||
return request({
|
return request({
|
||||||
url: '/pcap/stop',
|
url: '/pcap/stop',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
@ -196,7 +196,7 @@ export function stopPacketCapture(data) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 删除抓包文件
|
// 删除抓包文件
|
||||||
export function deletePacketCapture(data) {
|
export function deletePacketCapture(data){
|
||||||
return request({
|
return request({
|
||||||
url: '/pcap/delete',
|
url: '/pcap/delete',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
|
|||||||
@ -29,7 +29,7 @@ export default {
|
|||||||
// message: 'Switch Language Success',
|
// message: 'Switch Language Success',
|
||||||
// type: 'success'
|
// type: 'success'
|
||||||
// })
|
// })
|
||||||
window.location.reload()
|
window.location.reload();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -43,8 +43,8 @@ export default {
|
|||||||
upDateMsg: 'Firmware is being upgraded, please wait for a while。'
|
upDateMsg: 'Firmware is being upgraded, please wait for a while。'
|
||||||
},
|
},
|
||||||
table: {
|
table: {
|
||||||
DNS1: 'Preferred DNS Server',
|
DNS1:"Preferred DNS Server",
|
||||||
DNS2: 'Alternate DNS Server',
|
DNS2:"Alternate DNS Server",
|
||||||
productName: 'Product Name',
|
productName: 'Product Name',
|
||||||
productMode: 'Product Model',
|
productMode: 'Product Model',
|
||||||
serialNumber: 'Serial Number',
|
serialNumber: 'Serial Number',
|
||||||
@ -112,7 +112,7 @@ export default {
|
|||||||
chooseFile: 'Upgrade File',
|
chooseFile: 'Upgrade File',
|
||||||
microphoneSwitch: 'Microphone Switch',
|
microphoneSwitch: 'Microphone Switch',
|
||||||
factorySettingsTips:
|
factorySettingsTips:
|
||||||
'The default IP address of the device in the factory state is 192.168.1.108. After the restoration, you need to log in again.',
|
'The default IP address of the device in the factory state is 192.168.1.101. After the restoration, you need to log in again.',
|
||||||
fileUpload: 'File uploading...',
|
fileUpload: 'File uploading...',
|
||||||
fileSave: 'Saving...',
|
fileSave: 'Saving...',
|
||||||
routerRestartIng: 'Device Rebooting...',
|
routerRestartIng: 'Device Rebooting...',
|
||||||
@ -205,7 +205,7 @@ export default {
|
|||||||
lsssCode: 'Failed to update the firmware, because the file version is too low.', // 644code
|
lsssCode: 'Failed to update the firmware, because the file version is too low.', // 644code
|
||||||
EnableCalling: 'Whether or not to enable calling',
|
EnableCalling: 'Whether or not to enable calling',
|
||||||
CallButton0: 'SIP Username (Button 1)',
|
CallButton0: 'SIP Username (Button 1)',
|
||||||
CallButton1: 'SIP Username (Button 2)'
|
CallButton1: 'SIP Username (Button 2)',
|
||||||
},
|
},
|
||||||
theme: {
|
theme: {
|
||||||
change: 'Change Theme',
|
change: 'Change Theme',
|
||||||
|
|||||||
@ -36,11 +36,11 @@ export default {
|
|||||||
changePassword: '修改密码',
|
changePassword: '修改密码',
|
||||||
changePasswordTip: '监测到密码过弱或者密码已过期,请先修改密码后登录',
|
changePasswordTip: '监测到密码过弱或者密码已过期,请先修改密码后登录',
|
||||||
changePasswordMsg: '密码过期,请先修改密码后登录!',
|
changePasswordMsg: '密码过期,请先修改密码后登录!',
|
||||||
upDateMsg: '固件正在升级,请稍等一段时间。'
|
upDateMsg: '固件正在升级,请稍等一段时间。',
|
||||||
},
|
},
|
||||||
table: {
|
table: {
|
||||||
DNS1: '首选DNS服务器',
|
DNS1:"首选DNS服务器",
|
||||||
DNS2: '备用DNS服务器',
|
DNS2:"备用DNS服务器",
|
||||||
productName: '产品名称',
|
productName: '产品名称',
|
||||||
productMode: '型号',
|
productMode: '型号',
|
||||||
serialNumber: '序列号',
|
serialNumber: '序列号',
|
||||||
@ -104,7 +104,7 @@ export default {
|
|||||||
chooseFile: '选择文件',
|
chooseFile: '选择文件',
|
||||||
microphoneSwitch: '内置麦克风开关',
|
microphoneSwitch: '内置麦克风开关',
|
||||||
factorySettingsTips:
|
factorySettingsTips:
|
||||||
'出厂状态默认设备IP地址为192.168.1.108,恢复完成后需重新登录。',
|
'出厂状态默认设备IP地址为192.168.1.101,恢复完成后需重新登录。',
|
||||||
routerRestartTips: '设备即将重启,是否确认继续!',
|
routerRestartTips: '设备即将重启,是否确认继续!',
|
||||||
fileUpload: '文件上传中...',
|
fileUpload: '文件上传中...',
|
||||||
fileSave: '正在保存...',
|
fileSave: '正在保存...',
|
||||||
@ -197,7 +197,7 @@ export default {
|
|||||||
lsssCode: '固件升级失败,此固件升级文件的版本号低于当前版本。', // 644code
|
lsssCode: '固件升级失败,此固件升级文件的版本号低于当前版本。', // 644code
|
||||||
EnableCalling: '是否启用呼叫',
|
EnableCalling: '是否启用呼叫',
|
||||||
CallButton0: 'SIP用户名称 (按键1)',
|
CallButton0: 'SIP用户名称 (按键1)',
|
||||||
CallButton1: 'SIP用户名称 (按键2)'
|
CallButton1: 'SIP用户名称 (按键2)',
|
||||||
},
|
},
|
||||||
theme: {
|
theme: {
|
||||||
change: '换肤',
|
change: '换肤',
|
||||||
|
|||||||
@ -73,12 +73,12 @@
|
|||||||
>
|
>
|
||||||
<el-form-item label=" ">
|
<el-form-item label=" ">
|
||||||
<el-radio v-model="formSIPData.sip" label="on">{{
|
<el-radio v-model="formSIPData.sip" label="on">{{
|
||||||
$t("table.open")
|
$t("table.open")
|
||||||
}}
|
}}
|
||||||
</el-radio>
|
</el-radio>
|
||||||
<el-radio v-model="formSIPData.sip" label="off">{{
|
<el-radio v-model="formSIPData.sip" label="off">{{
|
||||||
$t("table.close")
|
$t("table.close")
|
||||||
}}
|
}}
|
||||||
</el-radio>
|
</el-radio>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.deviceID')">
|
<el-form-item :label="$t('table.deviceID')">
|
||||||
@ -105,10 +105,10 @@
|
|||||||
<svg-icon :icon-class="sip2PasswordType === 'password' ? 'eye' : 'eye-open'" />
|
<svg-icon :icon-class="sip2PasswordType === 'password' ? 'eye' : 'eye-open'" />
|
||||||
</span>
|
</span>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formSIPData.sipCallFunc === 'on'" :label="$t('table.CallButton0')">
|
<el-form-item :label="$t('table.CallButton0')" v-if="formSIPData.sipCallFunc === 'on'">
|
||||||
<el-input v-model="formSIPData.sipCallUsername0" />
|
<el-input v-model="formSIPData.sipCallUsername0" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formSIPData.sipCallFunc === 'on'" :label="$t('table.CallButton1')">
|
<el-form-item :label="$t('table.CallButton1')" v-if="formSIPData.sipCallFunc === 'on'">
|
||||||
<el-input v-model="formSIPData.sipCallUsername1" />
|
<el-input v-model="formSIPData.sipCallUsername1" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
@ -176,29 +176,29 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.WAN_IP_Type')">
|
<el-form-item :label="$t('table.WAN_IP_Type')">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="formONVIFData.wanType"
|
v-model="formONVIFData.wanType"
|
||||||
style="width:350px;"
|
style="width:350px;"
|
||||||
@change="selectChangeNet"
|
@change="selectChangeNet"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in NetType"
|
v-for="item in NetType"
|
||||||
:key="item.key"
|
:key="item.key"
|
||||||
:label="item.label"
|
:label="item.label"
|
||||||
:value="item.key"
|
:value="item.key"
|
||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formONVIFData.wanType === '1'" :label="$t('table.WAN_IP_DomainName')">
|
<el-form-item :label="$t('table.WAN_IP_DomainName')" v-if="formONVIFData.wanType === '1'">
|
||||||
<el-input v-model="formONVIFData.wanDomainName" />
|
<el-input v-model="formONVIFData.wanDomainName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formONVIFData.wanType === '0'" :label="$t('table.WAN_IP_Address')">
|
<el-form-item :label="$t('table.WAN_IP_Address')" v-if="formONVIFData.wanType === '0'">
|
||||||
<el-input v-model="formONVIFData.wanIP" />
|
<el-input v-model="formONVIFData.wanIP" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.WAN_Port')">
|
<el-form-item :label="$t('table.WAN_Port')">
|
||||||
<el-input v-model="formONVIFData.wanOnvifPort" type="number" :min="0" :max="65535" />
|
<el-input v-model="formONVIFData.wanOnvifPort" type="number" :min="0" :max="65535"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="$t('table.WAN_RTSP_Port')">
|
<el-form-item :label="$t('table.WAN_RTSP_Port')">
|
||||||
<el-input v-model="formONVIFData.wanRTSPPort" type="number" :min="0" :max="65535" />
|
<el-input v-model="formONVIFData.wanRTSPPort" type="number" :min="0" :max="65535"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-button
|
<el-button
|
||||||
@ -216,6 +216,7 @@
|
|||||||
import { deviceInfo, deviceEdit } from '@/api/index.js'
|
import { deviceInfo, deviceEdit } from '@/api/index.js'
|
||||||
import { encryptData, decryptData } from '@/utils/encryption/entrypt'
|
import { encryptData, decryptData } from '@/utils/encryption/entrypt'
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Agreement',
|
name: 'Agreement',
|
||||||
data() {
|
data() {
|
||||||
@ -238,11 +239,11 @@ export default {
|
|||||||
NetType: [
|
NetType: [
|
||||||
{
|
{
|
||||||
label: this.$t('table.WAN_IP_Address'),
|
label: this.$t('table.WAN_IP_Address'),
|
||||||
key: '0'
|
key:"0",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: this.$t('table.WAN_IP_DomainName'),
|
label: this.$t('table.WAN_IP_DomainName'),
|
||||||
key: '1'
|
key:"1",
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
selectIndex: '0',
|
selectIndex: '0',
|
||||||
@ -265,9 +266,9 @@ export default {
|
|||||||
sipUsername: '',
|
sipUsername: '',
|
||||||
sipPassword: '',
|
sipPassword: '',
|
||||||
sipPassword2: '',
|
sipPassword2: '',
|
||||||
sipCallFunc: 'off',
|
sipCallFunc:'off',
|
||||||
sipCallUsername0: '',
|
sipCallUsername0:'',
|
||||||
sipCallUsername1: ''
|
sipCallUsername1:'',
|
||||||
},
|
},
|
||||||
formONVIFData: {
|
formONVIFData: {
|
||||||
onvif: '',
|
onvif: '',
|
||||||
@ -284,7 +285,7 @@ export default {
|
|||||||
wanOnvifPort: '',
|
wanOnvifPort: '',
|
||||||
wanRTSPPort: '',
|
wanRTSPPort: '',
|
||||||
wanDomainName: '',
|
wanDomainName: '',
|
||||||
wanType: '0'
|
wanType:"0",
|
||||||
},
|
},
|
||||||
|
|
||||||
sipPasswordType: 'password',
|
sipPasswordType: 'password',
|
||||||
@ -456,7 +457,8 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
} else if (this.selectIndex === '1') {
|
}
|
||||||
|
else if (this.selectIndex === '1') {
|
||||||
param = {
|
param = {
|
||||||
...this.formSIPData
|
...this.formSIPData
|
||||||
}
|
}
|
||||||
@ -485,12 +487,13 @@ export default {
|
|||||||
}
|
}
|
||||||
param.sipPassword = encryptData(param.sipPassword)
|
param.sipPassword = encryptData(param.sipPassword)
|
||||||
param.sipPassword2 = encryptData(param.sipPassword2)
|
param.sipPassword2 = encryptData(param.sipPassword2)
|
||||||
} else if (this.selectIndex === '0') {
|
}
|
||||||
|
else if (this.selectIndex === '0') {
|
||||||
param = {
|
param = {
|
||||||
...this.formONVIFData
|
...this.formONVIFData
|
||||||
}
|
}
|
||||||
if (this.formONVIFData.wanDomainName !== '') {
|
if(this.formONVIFData.wanDomainName !== ''){
|
||||||
if (!wanDName.test(param.wanDomainName)) {
|
if(!wanDName.test(param.wanDomainName)){
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
message: this.$i18n.t('table.isRight7')
|
message: this.$i18n.t('table.isRight7')
|
||||||
@ -498,8 +501,8 @@ export default {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.formONVIFData.wanIP !== '') {
|
if(this.formONVIFData.wanIP !== ''){
|
||||||
if (!ipv4Regex.test(param.wanIP)) {
|
if(!ipv4Regex.test(param.wanIP)){
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
message: this.$i18n.t('table.isRight4')
|
message: this.$i18n.t('table.isRight4')
|
||||||
@ -507,28 +510,30 @@ export default {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.formONVIFData.wanOnvifPort !== '') {
|
if(this.formONVIFData.wanOnvifPort !== ''){
|
||||||
const l = Number(this.formONVIFData.wanOnvifPort)
|
const l = Number(this.formONVIFData.wanOnvifPort);
|
||||||
if (l > 0 && l < 65536) {
|
if(l > 0 && l < 65536){
|
||||||
|
|
||||||
} else {
|
}
|
||||||
|
else {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
message: this.$i18n.t('table.isRight5')
|
message: this.$i18n.t('table.isRight5')
|
||||||
})
|
})
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.formONVIFData.wanRTSPPort !== '') {
|
if(this.formONVIFData.wanRTSPPort !== ''){
|
||||||
const l = Number(this.formONVIFData.wanRTSPPort)
|
const l = Number(this.formONVIFData.wanRTSPPort);
|
||||||
if (l > 0 && l < 65536) {
|
if(l > 0 && l < 65536){
|
||||||
|
|
||||||
} else {
|
}
|
||||||
|
else {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
message: this.$i18n.t('table.isRight6')
|
message: this.$i18n.t('table.isRight6')
|
||||||
})
|
})
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!param.onvifUsername) {
|
if (!param.onvifUsername) {
|
||||||
@ -598,12 +603,12 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
IPV4Single(ip) {
|
IPV4Single(ip){
|
||||||
// 判断地址是否有效
|
// 判断地址是否有效
|
||||||
const IPV4 = /^((25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(25[0-5]|2[0-4]\d|[01]?\d\d?)$/
|
const IPV4 = /^((25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(25[0-5]|2[0-4]\d|[01]?\d\d?)$/;
|
||||||
// 输出 校验通过:true 校验出错:false
|
// 输出 校验通过:true 校验出错:false
|
||||||
return IPV4.test(ip)
|
return IPV4.test(ip)
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -109,12 +109,12 @@ export default {
|
|||||||
aoVol: 0, // 音频输出音量(录音音量)
|
aoVol: 0, // 音频输出音量(录音音量)
|
||||||
dhcp: 'on',
|
dhcp: 'on',
|
||||||
|
|
||||||
playStatus: '', // 播放状态
|
playStatus: '',// 播放状态
|
||||||
dns0: '', // dns1
|
dns0: '',// dns1
|
||||||
dns1: '', // dns2
|
dns1: '',// dns2
|
||||||
wanDomainName: '', // Wan域名
|
wanDomainName: '',// Wan域名
|
||||||
wanIP: '', // wan IP
|
wanIP: '',// wan IP
|
||||||
wanInfo: ''// wan信息
|
wanInfo: '',// wan信息
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -131,11 +131,12 @@ export default {
|
|||||||
this.formData.dns0 = res.data.dns0 || ''
|
this.formData.dns0 = res.data.dns0 || ''
|
||||||
this.formData.dns1 = res.data.dns1 || ''
|
this.formData.dns1 = res.data.dns1 || ''
|
||||||
this.formData.wanIP = res.data.wanIP || ''
|
this.formData.wanIP = res.data.wanIP || ''
|
||||||
if (res.data.wanDomainName !== undefined) {
|
if(res.data.wanDomainName !== undefined){
|
||||||
this.formData.wanDomainName = res.data.wanDomainName || ''
|
this.formData.wanDomainName = res.data.wanDomainName || ''
|
||||||
console.log('AAA', res)
|
console.log('AAA', res)
|
||||||
}
|
}
|
||||||
this.formData.wanInfo = `${this.formData.wanDomainName} (${this.formData.wanIP})`
|
this.formData.wanInfo = `${this.formData.wanDomainName} (${this.formData.wanIP})`
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this.$message.error(res.message)
|
this.$message.error(res.message)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -23,27 +23,27 @@
|
|||||||
<!-- <el-button type="primary" style="margin-top: 48px;" @click="factorySetting">
|
<!-- <el-button type="primary" style="margin-top: 48px;" @click="factorySetting">
|
||||||
{{ $t('table.factorySettings') }}
|
{{ $t('table.factorySettings') }}
|
||||||
</el-button> -->
|
</el-button> -->
|
||||||
<!-- <div class="formbox">-->
|
<div class="formbox">
|
||||||
<!-- <div class="formbox-l">{{ $t('table.NetworkPacketCapture') }}</div>-->
|
<div class="formbox-l">{{ $t('table.NetworkPacketCapture') }}</div>
|
||||||
<!-- <el-button type="primary" v-if="DataDB.status === 0 || DataDB.status === 2" @click.stop="StartPacketCapture(1)">-->
|
<el-button type="primary" v-if="DataDB.status === 0 || DataDB.status === 2" @click.stop="StartPacketCapture(1)">
|
||||||
<!-- {{ $t('table.StartPacketCapture') }}-->
|
{{ $t('table.StartPacketCapture') }}
|
||||||
<!-- </el-button>-->
|
</el-button>
|
||||||
<!-- <el-button type="danger" v-else @click.stop="StartPacketCapture(0)">-->
|
<el-button type="danger" v-else @click.stop="StartPacketCapture(0)">
|
||||||
<!-- {{ $t('table.StopPacketCapture') }}-->
|
{{ $t('table.StopPacketCapture') }}
|
||||||
<!-- </el-button>-->
|
</el-button>
|
||||||
<!-- <el-button type="primary" @click.stop="DownloadFile" :disabled="DataDB.status !== 2">-->
|
<el-button type="primary" @click.stop="DownloadFile" :disabled="DataDB.status !== 2">
|
||||||
<!-- {{ $t('table.Download') }}-->
|
{{ $t('table.Download') }}
|
||||||
<!-- </el-button>-->
|
</el-button>
|
||||||
<!-- <el-button type="primary" @click.stop="DeletePacketCaptureRecords" :disabled="DataDB.status !== 2">-->
|
<el-button type="primary" @click.stop="DeletePacketCaptureRecords" :disabled="DataDB.status !== 2">
|
||||||
<!-- {{ $t('table.Delete') }}-->
|
{{ $t('table.Delete') }}
|
||||||
<!-- </el-button>-->
|
</el-button>
|
||||||
<!-- <span v-if="DataDB.status === 1" class="SpanBox1">-->
|
<span v-if="DataDB.status === 1" class="SpanBox1">
|
||||||
<!-- {{ $t('table.CapturingPacket') }}-->
|
{{ $t('table.CapturingPacket') }}
|
||||||
<!-- </span>-->
|
</span>
|
||||||
<!-- <span v-else-if="DataDB.status === 2" class="SpanBox1">-->
|
<span v-else-if="DataDB.status === 2" class="SpanBox1">
|
||||||
<!-- {{ $t('table.PacketCaptureHasBeenStopped') }}-->
|
{{ $t('table.PacketCaptureHasBeenStopped') }}
|
||||||
<!-- </span>-->
|
</span>
|
||||||
<!-- </div>-->
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@ -61,14 +61,14 @@ export default {
|
|||||||
name: 'FactorySetting',
|
name: 'FactorySetting',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
DataDB: {
|
DataDB:{
|
||||||
status: 0,
|
status:0,
|
||||||
file: ''
|
file:'',
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getPacketInfo()
|
this.getPacketInfo();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
factorySetting() {
|
factorySetting() {
|
||||||
@ -138,48 +138,49 @@ export default {
|
|||||||
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
StartPacketCapture(Flag) {
|
StartPacketCapture(Flag){
|
||||||
if (Flag === 1) {
|
if(Flag === 1){
|
||||||
startPacketCapture({}).then(res => {
|
startPacketCapture({}).then(res => {
|
||||||
setTimeout(() => {
|
setTimeout(()=>{
|
||||||
this.getPacketInfo()
|
this.getPacketInfo();
|
||||||
}, 300)
|
}, 300);
|
||||||
})
|
});
|
||||||
} else if (Flag === 0) {
|
}
|
||||||
|
else if(Flag === 0){
|
||||||
stopPacketCapture({}).then(res => {
|
stopPacketCapture({}).then(res => {
|
||||||
setTimeout(() => {
|
setTimeout(()=>{
|
||||||
this.getPacketInfo()
|
this.getPacketInfo();
|
||||||
}, 300)
|
}, 300);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
getPacketInfo() {
|
getPacketInfo(){
|
||||||
getPacketCaptureInfo({}).then(res => {
|
getPacketCaptureInfo({}).then(res => {
|
||||||
const data = res.data
|
const data = res.data;
|
||||||
this.DataDB.status = data.status
|
this.DataDB.status = data.status;
|
||||||
this.DataDB.file = data.file
|
this.DataDB.file = data.file;
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
|
|
||||||
})
|
});
|
||||||
},
|
},
|
||||||
DeletePacketCaptureRecords() {
|
DeletePacketCaptureRecords(){
|
||||||
const data = {
|
const data = {
|
||||||
name: this.DataDB.file
|
name: this.DataDB.file,
|
||||||
}
|
};
|
||||||
// console.log(data);
|
// console.log(data);
|
||||||
deletePacketCapture(data).then(res => {
|
deletePacketCapture(data).then(res => {
|
||||||
this.DataDB.status = 0
|
this.DataDB.status = 0;
|
||||||
this.$message.success(this.$i18n.t('table.Delete') + this.$i18n.t('table.success'))
|
this.$message.success(this.$i18n.t('table.Delete') + this.$i18n.t('table.success'))
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
|
|
||||||
})
|
});
|
||||||
},
|
},
|
||||||
DownloadFile() {
|
DownloadFile(){
|
||||||
if (this.DataDB.file === '') {
|
if(this.DataDB.file === ''){
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
const URL = '/prod-api/pcap/' + this.DataDB.file
|
const URL = '/prod-api/pcap/' + this.DataDB.file;
|
||||||
window.open(URL)
|
window.open(URL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -15,7 +15,7 @@
|
|||||||
<h3 class="title">
|
<h3 class="title">
|
||||||
IP Speaker
|
IP Speaker
|
||||||
</h3>
|
</h3>
|
||||||
<!-- <img src="@/assets/login/logo_white.svg" alt="">-->
|
<!-- <img src="@/assets/login/logo_white.svg" alt="">-->
|
||||||
<h3 class="title">
|
<h3 class="title">
|
||||||
{{ $t('login.title') }}
|
{{ $t('login.title') }}
|
||||||
</h3>
|
</h3>
|
||||||
|
|||||||
@ -33,9 +33,9 @@
|
|||||||
{{ $t("table.check") }}
|
{{ $t("table.check") }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="text"
|
type="text"
|
||||||
size="mini"
|
size="mini"
|
||||||
@click="download(scope.row.name)"
|
@click="download(scope.row.name)"
|
||||||
>
|
>
|
||||||
{{ $t("table.Download") }}
|
{{ $t("table.Download") }}
|
||||||
</el-button>
|
</el-button>
|
||||||
@ -196,10 +196,10 @@ export default {
|
|||||||
clearInterval(this.timer)
|
clearInterval(this.timer)
|
||||||
this.timer = null
|
this.timer = null
|
||||||
},
|
},
|
||||||
download(name) {
|
download(name){
|
||||||
const URL = '/prod-api/log/download/' + name
|
const URL = '/prod-api/log/download/' + name;
|
||||||
window.open(URL)
|
window.open(URL);
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -92,8 +92,8 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
formData: {
|
formData: {
|
||||||
dns0: '',
|
dns0:'',
|
||||||
dns1: '',
|
dns1:'',
|
||||||
name: '',
|
name: '',
|
||||||
model: '',
|
model: '',
|
||||||
mac: '',
|
mac: '',
|
||||||
@ -133,7 +133,8 @@ export default {
|
|||||||
this.formData.aoVol = parseInt(res.data.aoVol) || 0
|
this.formData.aoVol = parseInt(res.data.aoVol) || 0
|
||||||
this.formData.dns0 = res.data.dns0 || ''
|
this.formData.dns0 = res.data.dns0 || ''
|
||||||
this.formData.dns1 = res.data.dns1 || ''
|
this.formData.dns1 = res.data.dns1 || ''
|
||||||
} else {
|
}
|
||||||
|
else {
|
||||||
this.$message.error(res.message)
|
this.$message.error(res.message)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -145,7 +146,7 @@ export default {
|
|||||||
const ipv4Regex = /^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/
|
const ipv4Regex = /^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/
|
||||||
const idRegex = /^(?:[2-9]\d{0,3}|1\d{0,3}|9999)$/
|
const idRegex = /^(?:[2-9]\d{0,3}|1\d{0,3}|9999)$/
|
||||||
const subnetRegex = /^(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])(\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])){3}$/
|
const subnetRegex = /^(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])(\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])){3}$/
|
||||||
// const dnsRegex = /^(?!-)[A-Za-z0-9-]{1,63}(?<!-)(\.(?!-)[A-Za-z0-9-]{1,63}(?<!-))*$/
|
const dnsRegex = /^(?!-)[A-Za-z0-9-]{1,63}(?<!-)(\.(?!-)[A-Za-z0-9-]{1,63}(?<!-))*$/;
|
||||||
// 终端Id
|
// 终端Id
|
||||||
if (!param.id) {
|
if (!param.id) {
|
||||||
this.$message({
|
this.$message({
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user