Merge branch 'master-dev' into feature-Beta-dev-renpy

This commit is contained in:
任珮宇 2024-01-25 16:19:47 +08:00
commit 3291baf499
11 changed files with 188 additions and 170 deletions

View File

@ -2,11 +2,11 @@
<div> <div>
<a-input-search <a-input-search
v-model="textVals" v-model="textVals"
placeholder="请先选择用户" placeholder="Please select the user first"
readOnly readOnly
unselectable="on" unselectable="on"
@search="onSearchDepUser"> @search="onSearchDepUser">
<a-button slot="enterButton" :disabled="disabled">选择用户</a-button> <a-button slot="enterButton" :disabled="disabled">Select user</a-button>
</a-input-search> </a-input-search>
<j-select-user-by-dep-modal <j-select-user-by-dep-modal
ref="selectModal" ref="selectModal"
@ -120,7 +120,7 @@
this.$refs.selectModal.showModal() this.$refs.selectModal.showModal()
}, },
selectOK(rows) { selectOK(rows) {
console.log("当前选中用户", rows) console.log("Currently selected user", rows)
if (!rows) { if (!rows) {
this.storeVals = '' this.storeVals = ''
this.textVals = '' this.textVals = ''

View File

@ -6,28 +6,28 @@
<a-form layout="inline" @keyup.enter.native="searchQuery"> <a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24"> <a-row :gutter="24">
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="消息标题"> <a-form-item label="Message header">
<a-input placeholder="请输入消息标题" v-model="queryParam.esTitle"></a-input> <a-input placeholder="Please enter the message title" v-model="queryParam.esTitle"></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="发送内容"> <a-form-item label="Send content">
<a-input placeholder="请输入发送内容" v-model="queryParam.esContent"></a-input> <a-input placeholder="Please enter the content to send" v-model="queryParam.esContent"></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<template v-if="toggleSearchStatus"> <template v-if="toggleSearchStatus">
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="接收人"> <a-form-item label="receiver">
<a-input placeholder="请输入接收人" v-model="queryParam.esReceiver"></a-input> <a-input placeholder="Please enter the recipient" v-model="queryParam.esReceiver"></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
</template> </template>
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button> <a-button type="primary" @click="searchQuery" icon="search">Search</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button> <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">Reset</a-button>
<a @click="handleToggleSearch" style="margin-left: 8px"> <a @click="handleToggleSearch" style="margin-left: 8px">
{{ toggleSearchStatus ? '收起' : '展开' }} {{ toggleSearchStatus ? 'Pack up' : 'unfold' }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/> <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a> </a>
</span> </span>
@ -39,20 +39,20 @@
<!-- 操作按钮区域 --> <!-- 操作按钮区域 -->
<div class="table-operator"> <div class="table-operator">
<a-button @click="handleAdd" v-show="show" type="primary" icon="plus">新增</a-button> <a-button @click="handleAdd" v-show="show" type="primary" icon="plus">ADD</a-button>
<a-button type="primary" v-show="show" icon="download" @click="handleExportXls('消息')">导出</a-button> <a-button type="primary" v-show="show" icon="download" @click="handleExportXls('消息')">Export</a-button>
<a-upload v-show="show" name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" <a-upload v-show="show" name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"
@change="handleImportExcel"> @change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button> <a-button type="primary" icon="import">Import</a-button>
</a-upload> </a-upload>
<a-dropdown v-if="selectedRowKeys.length > 0"> <a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay"> <a-menu slot="overlay">
<a-menu-item key="1" @click="batchDel"> <a-menu-item key="1" @click="batchDel">
<a-icon type="delete"/> <a-icon type="delete"/>
删除 Delete
</a-menu-item> </a-menu-item>
</a-menu> </a-menu>
<a-button style="margin-left: 8px"> 批量操作 <a-button style="margin-left: 8px"> Batch operation
<a-icon type="down"/> <a-icon type="down"/>
</a-button> </a-button>
</a-dropdown> </a-dropdown>
@ -61,9 +61,9 @@
<!-- table区域-begin --> <!-- table区域-begin -->
<div> <div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ <i class="anticon anticon-info-circle ant-alert-icon"></i> Selected <a style="font-weight: 600">{{
selectedRowKeys.length }}</a> selectedRowKeys.length }}</a>item
<a style="margin-left: 24px" @click="onClearSelected">清空</a> <a style="margin-left: 24px" @click="onClearSelected">Clear</a>
</div> </div>
<a-table <a-table
@ -84,17 +84,17 @@
</span> </span>
<span slot="action" slot-scope="text, record"> <span slot="action" slot-scope="text, record">
<a href="javascript:;" @click="handleDetail(record)">详情</a> <a href="javascript:;" @click="handleDetail(record)">Details</a>
<a-divider type="vertical"/> <a-divider type="vertical"/>
<a-dropdown> <a-dropdown>
<a class="ant-dropdown-link">更多<a-icon type="down"/></a> <a class="ant-dropdown-link">More<a-icon type="down"/></a>
<a-menu slot="overlay"> <a-menu slot="overlay">
<a-menu-item v-show="show"> <a-menu-item v-show="show">
<a @click="handleEdit(record)">编辑</a> <a @click="handleEdit(record)">Edit</a>
</a-menu-item> </a-menu-item>
<a-menu-item> <a-menu-item>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)"> <a-popconfirm title="Are you sure to delete it?" @confirm="() => handleDelete(record.id)">
<a>删除</a> <a>Delete</a>
</a-popconfirm> </a-popconfirm>
</a-menu-item> </a-menu-item>
</a-menu> </a-menu>
@ -124,7 +124,7 @@
}, },
data() { data() {
return { return {
description: '消息管理页面', description: 'Message management page',
// //
show: false, show: false,
// //
@ -140,43 +140,43 @@
} }
}, },
{ {
title: '消息标题', title: 'Message header',
align: "center", align: "center",
dataIndex: 'esTitle' dataIndex: 'esTitle'
}, },
{ {
title: '发送内容', title: 'Send content',
align: "center", align: "center",
dataIndex: 'esContent', dataIndex: 'esContent',
scopedSlots: {customRender: 'esContent'}, scopedSlots: {customRender: 'esContent'},
}, },
{ {
title: '接收人', title: 'receiver',
align: "center", align: "center",
dataIndex: 'esReceiver' dataIndex: 'esReceiver'
}, },
{ {
title: '发送次数', title: 'Transmission times',
align: "center", align: "center",
dataIndex: 'esSendNum' dataIndex: 'esSendNum'
}, },
{ {
title: '发送状态', title: 'Send state',
align: 'center', align: 'center',
dataIndex: 'esSendStatus_dictText' dataIndex: 'esSendStatus_dictText'
}, },
{ {
title: '发送时间', title: 'Send time',
align: "center", align: "center",
dataIndex: 'esSendTime' dataIndex: 'esSendTime'
}, },
{ {
title: '发送方式', title: 'Send mode',
align: 'center', align: 'center',
dataIndex: 'esType_dictText' dataIndex: 'esType_dictText'
}, },
{ {
title: '操作', title: 'Operation',
dataIndex: 'action', dataIndex: 'action',
align: "center", align: "center",
scopedSlots: {customRender: 'action'}, scopedSlots: {customRender: 'action'},

View File

@ -7,33 +7,33 @@
<a-row :gutter="24"> <a-row :gutter="24">
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="模板CODE"> <a-form-item label="TEMPLATE CODE">
<a-input placeholder="请输入模板CODE" v-model="queryParam.templateCode"></a-input> <a-input placeholder="Please enter the template CODE" v-model="queryParam.templateCode"></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="模板内容"> <a-form-item label="TEMPLATE Content">
<a-input placeholder="请输入模板内容" v-model="queryParam.templateContent"></a-input> <a-input placeholder="Please enter the template content" v-model="queryParam.templateContent"></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<template v-if="toggleSearchStatus"> <template v-if="toggleSearchStatus">
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="模板标题"> <a-form-item label="TEMPLATE Title">
<a-input placeholder="请输入模板标题" v-model="queryParam.templateName"></a-input> <a-input placeholder="Please enter the template title" v-model="queryParam.templateName"></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<a-form-item label="模板类型"> <a-form-item label="TEMPLATE Type">
<j-dict-select-tag placeholder="请选择模板类型" v-model="queryParam.templateType" dictCode="msgType"></j-dict-select-tag> <j-dict-select-tag placeholder="Please check the template type" v-model="queryParam.templateType" dictCode="msgType"></j-dict-select-tag>
</a-form-item> </a-form-item>
</a-col> </a-col>
</template> </template>
<a-col :md="6" :sm="8"> <a-col :md="6" :sm="8">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button> <a-button type="primary" @click="searchQuery" icon="search">Search</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button> <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">Reset</a-button>
<a @click="handleToggleSearch" style="margin-left: 8px"> <a @click="handleToggleSearch" style="margin-left: 8px">
{{ toggleSearchStatus ? '收起' : '展开' }} {{ toggleSearchStatus ? 'Pack up' : 'unfold' }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/> <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a> </a>
</span> </span>
@ -45,11 +45,11 @@
<!-- 操作按钮区域 --> <!-- 操作按钮区域 -->
<div class="table-operator"> <div class="table-operator">
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button> <a-button @click="handleAdd" type="primary" icon="plus">ADD</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('消息模板')">导出</a-button> <a-button type="primary" icon="download" @click="handleExportXls('消息模版')">Export</a-button>
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"
@change="handleImportExcel"> @change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button> <a-button type="primary" icon="import">Import</a-button>
</a-upload> </a-upload>
<!-- <a-dropdown v-if="selectedRowKeys.length > 0"> <!-- <a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay"> <a-menu slot="overlay">
@ -67,9 +67,9 @@
<!-- table区域-begin --> <!-- table区域-begin -->
<div> <div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ <i class="anticon anticon-info-circle ant-alert-icon"></i> Selected <a style="font-weight: 600">{{
selectedRowKeys.length }}</a> selectedRowKeys.length }}</a>item
<a style="margin-left: 24px" @click="onClearSelected">清空</a> <a style="margin-left: 24px" @click="onClearSelected">Clear</a>
</div> </div>
<a-table <a-table
@ -91,26 +91,26 @@
<span slot="action" slot-scope="text, record"> <span slot="action" slot-scope="text, record">
<a @click="handleMyEdit(record)">编辑</a> <a @click="handleMyEdit(record)">Edit</a>
<a-divider type="vertical"/> <a-divider type="vertical"/>
<a-dropdown> <a-dropdown>
<a class="ant-dropdown-link">更多 <a-icon type="down"/></a> <a class="ant-dropdown-link">More <a-icon type="down"/></a>
<a-menu slot="overlay"> <a-menu slot="overlay">
<a-menu-item> <a-menu-item>
<a @click="handleUse(record)">应用</a> <a @click="handleUse(record)">Use</a>
</a-menu-item> </a-menu-item>
<a-menu-item> <a-menu-item>
<a @click="handleNotUse(record)">停用</a> <a @click="handleNotUse(record)">NotUse</a>
</a-menu-item> </a-menu-item>
<a-menu-item> <a-menu-item>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record)"> <a-popconfirm title="Are you sure to delete it?" @confirm="() => handleDelete(record)">
<a>删除</a> <a>Delete</a>
</a-popconfirm> </a-popconfirm>
</a-menu-item> </a-menu-item>
<a-menu-item> <a-menu-item>
<a @click="handleTest(record)">发送测试</a> <a @click="handleTest(record)">Send test</a>
</a-menu-item> </a-menu-item>
</a-menu> </a-menu>
</a-dropdown> </a-dropdown>
@ -148,7 +148,7 @@
}, },
data() { data() {
return { return {
description: '消息模板管理页面', description: 'Message template Management page',
// //
columns: [ columns: [
{ {
@ -162,48 +162,48 @@
} }
}, },
{ {
title: '模板CODE', title: 'templateCode',
align: "center", align: "center",
dataIndex: 'templateCode' dataIndex: 'templateCode'
}, },
{ {
title: '模板标题', title: 'templateTitle',
align: "center", align: "center",
dataIndex: 'templateName' dataIndex: 'templateName'
}, },
{ {
title: '模板内容', title: 'templateContent',
align: "center", align: "center",
dataIndex: 'templateContent', dataIndex: 'templateContent',
scopedSlots: {customRender: 'templateContent'}, scopedSlots: {customRender: 'templateContent'},
}, },
{ {
title: '模板类型', title: 'templateType',
align: "center", align: "center",
dataIndex: 'templateType', dataIndex: 'templateType',
customRender: function (text) { customRender: function (text) {
if(text=='1') { if(text=='1') {
return "文本"; return "TEXT";
} }
if(text=='2') { if(text=='2') {
return "富文本"; return "Rich text";
} }
} }
}, },
{ {
title: '是否应用', title: 'useStatus',
align: "center", align: "center",
dataIndex: 'useStatus', dataIndex: 'useStatus',
customRender: function (text) { customRender: function (text) {
if(text=='1') { if(text=='1') {
return ""; return "YES";
}else{ }else{
return '' return 'NO'
} }
} }
}, },
{ {
title: '操作', title: 'action',
dataIndex: 'action', dataIndex: 'action',
align: "center", align: "center",
scopedSlots: {customRender: 'action'}, scopedSlots: {customRender: 'action'},
@ -226,7 +226,7 @@
methods: { methods: {
handleTest(record){ handleTest(record){
this.$refs.testModal.open(record); this.$refs.testModal.open(record);
this.$refs.testModal.title = "发送测试"; this.$refs.testModal.title = "Send test";
}, },
//update-begin-author:taoyan date:2022-7-8 for: //update-begin-author:taoyan date:2022-7-8 for:
updateUseStatus(record, useStatus){ updateUseStatus(record, useStatus){
@ -251,7 +251,7 @@
}, },
handleMyEdit(record){ handleMyEdit(record){
if(record.useStatus == '1'){ if(record.useStatus == '1'){
this.$message.warning('此模板已被应用,禁止编辑!'); this.$message.warning('This template has been applied and editing is prohibited!');
}else{ }else{
this.handleEdit(record); this.handleEdit(record);
} }
@ -260,11 +260,11 @@
handleDelete: function (record) { handleDelete: function (record) {
if(!this.url.delete){ if(!this.url.delete){
this.$message.error("请设置url.delete属性!") this.$message.error("Please set the url.delete property!")
return return
} }
if(record.useStatus=='1'){ if(record.useStatus=='1'){
this.$message.error("该模板已被应用禁止删除!") this.$message.error("The template is prohibited from being deleted by the application!")
return return
} }
let id = record.id; let id = record.id;

View File

@ -15,70 +15,70 @@
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="消息标题"> label="Message header">
<a-input placeholder="请输入消息标题" v-decorator="['esTitle', {}]"/> <a-input placeholder="Please enter the message title" v-decorator="['esTitle', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送内容"> label="Send content">
<a-input placeholder="请输入发送内容" v-decorator="['esContent', {}]"/> <a-input placeholder="Please enter the content to send" v-decorator="['esContent', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送所需参数"> label="Send required parameters">
<a-input placeholder="请输入发送所需参数Json格式" v-decorator="['esParam', {}]"/> <a-input placeholder="Please enter the required parameters in Json format" v-decorator="['esParam', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="接收人"> label="receiver">
<a-input placeholder="请输入接收人" v-decorator="['esReceiver', {}]"/> <a-input placeholder="Please enter the recipient" v-decorator="['esReceiver', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送方式"> label="Sending mode">
<j-dict-select-tag :triggerChange="true" dictCode="msgType" v-decorator="[ 'esType', {}]" placeholder="请选择发送方式"> <j-dict-select-tag :triggerChange="true" dictCode="msgType" v-decorator="[ 'esType', {}]" placeholder="Please select a sending method">
</j-dict-select-tag> </j-dict-select-tag>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送时间"> label="Sending time">
<a-date-picker showTime format='YYYY-MM-DD HH:mm:ss' v-decorator="[ 'esSendTime', {}]"/> <a-date-picker showTime format='YYYY-MM-DD HH:mm:ss' v-decorator="[ 'esSendTime', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送状态"> label="Sending state">
<j-dict-select-tag :triggerChange="true" dictCode="msgSendStatus" v-decorator="[ 'esSendStatus', {}]" placeholder="请选择发送状态"> <j-dict-select-tag :triggerChange="true" dictCode="msgSendStatus" v-decorator="[ 'esSendStatus', {}]" placeholder="Please select Send status">
</j-dict-select-tag> </j-dict-select-tag>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送次数"> label="Transmission times">
<a-input-number v-decorator="[ 'esSendNum', {}]"/> <a-input-number v-decorator="[ 'esSendNum', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="发送失败原因"> label="Cause of sending failure">
<a-input v-decorator="['esResult', {}]"/> <a-input v-decorator="['esResult', {}]"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="备注"> label="remark">
<a-input v-decorator="['remark', {}]"/> <a-input v-decorator="['remark', {}]"/>
</a-form-item> </a-form-item>
</a-form> </a-form>
</a-spin> </a-spin>
<div v-show="!disableSubmit"> <div v-show="!disableSubmit">
<a-button style="margin-right: .8rem" @confirm="handleCancel">取消</a-button> <a-button style="margin-right: .8rem" @confirm="handleCancel">Cancel</a-button>
<a-button @click="handleOk" type="primary" :loading="confirmLoading">提交</a-button> <a-button @click="handleOk" type="primary" :loading="confirmLoading">Submit</a-button>
</div> </div>
</a-drawer> </a-drawer>
</template> </template>
@ -92,7 +92,7 @@
name: "SysMessageModal", name: "SysMessageModal",
data() { data() {
return { return {
title: "操作", title: "Operation",
visible: false, visible: false,
model: {}, model: {},
labelCol: { labelCol: {

View File

@ -6,70 +6,67 @@
:confirmLoading="confirmLoading" :confirmLoading="confirmLoading"
@ok="handleOk" @ok="handleOk"
@cancel="handleCancel" @cancel="handleCancel"
cancelText="关闭"> cancelText="Cancel">
<a-spin :spinning="confirmLoading"> <a-spin :spinning="confirmLoading">
<a-form :form="form"> <a-form :form="form">
<a-row :gutter="{ xs: 8, sm: 16, md: 24, lg: 32 }"> <a-row class="form-row" :gutter="24" >
<a-col :span="12"> <a-col :span="24">
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板CODE" label="Template Code"
style="margin-right: -35px"
> >
<a-input <a-input
:disabled="disable" :disabled="disable"
placeholder="请输入模板编码" placeholder="Please enter the template code"
v-decorator="['templateCode', validatorRules.templateCode ]" v-decorator="['templateCode', validatorRules.templateCode ]"
/> />
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="12"> <a-col :span="24">
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板类型"> label="Template type">
<j-dict-select-tag @change="handleChangeTemplateType" :triggerChange="true" dictCode="msgType" v-decorator="['templateType', validatorRules.templateType ]" placeholder="请选择模板类型"> <j-dict-select-tag @change="handleChangeTemplateType" :triggerChange="true" dictCode="msgType" v-decorator="['templateType', validatorRules.templateType ]" placeholder="Please select a template type">
</j-dict-select-tag> </j-dict-select-tag>
</a-form-item> </a-form-item>
</a-col> </a-col>
</a-row> </a-row>
<a-row class="form-row" :gutter="24" > <a-row class="form-row" :gutter="24" >
<a-col :span="24" pull="2"> <a-col :span="24">
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板标题" label="Template title">
style="margin-left: -15px">
<a-input <a-input
placeholder="请输入模板标题" placeholder="Please enter the template title"
v-decorator="['templateName', validatorRules.templateName]" v-decorator="['templateName', validatorRules.templateName]"
style="width: 122%" style="width: 100%"
/> />
</a-form-item> </a-form-item>
</a-col> </a-col>
</a-row> </a-row>
<a-row class="form-row" :gutter="24" > <a-row class="form-row" :gutter="24" >
<a-col :span="24" pull="2"> <a-col :span="24">
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="是否应用" label="useStatus"
style="margin-left: -15px"> style="margin-left: -15px">
<j-switch v-decorator="['useStatus', validatorRules.useStatus]" :options="['1', '0']"></j-switch> <j-switch v-decorator="['useStatus', validatorRules.useStatus]" :options="['1', '0']"></j-switch>
</a-form-item> </a-form-item>
</a-col> </a-col>
</a-row> </a-row>
<a-row class="form-row" :gutter="24"> <a-row class="form-row" :gutter="24">
<a-col :span="24" pull="4"> <a-col :span="24">
<a-form-item <a-form-item
v-show="!useEditor" v-show="!useEditor"
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板内容" label="Template content">
style="margin-left: 4px;width: 126%"> <a-textarea placeholder="Please enter the template content" v-decorator="['templateContent', validatorRules.templateContent ]" :autosize="{ minRows: 8, maxRows: 8 }"/>
<a-textarea placeholder="请输入模板内容" v-decorator="['templateContent', validatorRules.templateContent ]" :autosize="{ minRows: 8, maxRows: 8 }"/>
</a-form-item> </a-form-item>
</a-col> </a-col>
</a-row> </a-row>
@ -79,7 +76,7 @@
v-show="useEditor" v-show="useEditor"
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板内容" label="Template content"
style="margin-left: 4px;width: 126%"> style="margin-left: 4px;width: 126%">
<j-editor v-model="templateEditorContent"></j-editor> <j-editor v-model="templateEditorContent"></j-editor>
</a-form-item> </a-form-item>
@ -106,7 +103,7 @@
}, },
data() { data() {
return { return {
title: "操作", title: "Operation",
visible: false, visible: false,
disable: true, disable: true,
model: {}, model: {},
@ -121,11 +118,11 @@
confirmLoading: false, confirmLoading: false,
form: this.$form.createForm(this), form: this.$form.createForm(this),
validatorRules: { validatorRules: {
templateCode: {rules: [{required: true, message: '请输入模板CODE!' },{validator: this.validateTemplateCode}]}, templateCode: {rules: [{required: true, message: 'Please enter the template Code!' },{validator: this.validateTemplateCode}]},
templateName: {rules: [{required: true, message: '请输入模板标题!'}]}, templateName: {rules: [{required: true, message: 'Please enter the template title!'}]},
templateContent: {rules: []}, templateContent: {rules: []},
useStatus:{rules: []}, useStatus:{rules: []},
templateType: {rules: [{required: true, message: '请输入模板类型!'}]}, templateType: {rules: [{required: true, message: 'Please enter the template type!'}]},
}, },
url: { url: {
add: "/sys/message/sysMessageTemplate/add", add: "/sys/message/sysMessageTemplate/add",

View File

@ -6,43 +6,43 @@
:confirmLoading="confirmLoading" :confirmLoading="confirmLoading"
@ok="handleOk" @ok="handleOk"
@cancel="handleCancel" @cancel="handleCancel"
cancelText="关闭"> cancelText="Cancel">
<a-spin :spinning="confirmLoading"> <a-spin :spinning="confirmLoading">
<a-form> <a-form>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板标题"> label="Template title">
<a-input disabled v-model="templateName"/> <a-input disabled v-model="templateName"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="模板内容"> label="Template content">
<a-textarea disabled v-model="templateContent" :autosize="{ minRows: 5, maxRows: 8 }"/> <a-textarea disabled v-model="templateContent" :autosize="{ minRows: 5, maxRows: 8 }"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="测试数据"> label="Test data">
<a-textarea placeholder="请输入json格式测试数据" v-model="testData" :autosize="{ minRows: 5, maxRows: 8 }"/> <a-textarea placeholder="Please enter the test data in json format" v-model="testData" :autosize="{ minRows: 5, maxRows: 8 }"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="消息类型"> label="Message type">
<j-dict-select-tag <j-dict-select-tag
v-model="msgType" v-model="msgType"
type="radio" type="radio"
placeholder="请选择消息类型" placeholder="Please select a message type"
dictCode="messageType"/> dictCode="messageType"/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item
:labelCol="labelCol" :labelCol="labelCol"
:wrapperCol="wrapperCol" :wrapperCol="wrapperCol"
label="消息接收方"> label="Message receiver">
<j-select-user-by-dep placeholder="请选择消息接收方" v-model="receiver"></j-select-user-by-dep> <j-select-user-by-dep placeholder="Please select a message recipient" v-model="receiver"></j-select-user-by-dep>
</a-form-item> </a-form-item>
</a-form> </a-form>
</a-spin> </a-spin>
@ -60,7 +60,7 @@
}, },
data() { data() {
return { return {
title: "操作", title: "Operation",
visible: false, visible: false,
model: {}, model: {},
labelCol: { labelCol: {

View File

@ -26,7 +26,7 @@
<!-- 左侧图表 --> <!-- 左侧图表 -->
<div class="beta-gamma-spectrum-sample"> <div class="beta-gamma-spectrum-sample">
<beta-gamma-chart-container> <beta-gamma-chart-container>
<template slot="title"> Beta-Gamma Spectrum: Sample </template> <template slot="title"> Beta-Gamma Spectrum: {{ currSpectrum }} </template>
<beta-gamma-spectrum-chart <beta-gamma-spectrum-chart
ref="betaGammaChartRef" ref="betaGammaChartRef"
:histogramDataList="histogramDataList" :histogramDataList="histogramDataList"
@ -191,6 +191,7 @@ export default {
this.SampleType = SampleType this.SampleType = SampleType
return { return {
currSpectrum: '',
// analyseCurrentSpectrum: {}, // analyseCurrentSpectrum: {},
qcFlags: {}, qcFlags: {},
@ -386,6 +387,11 @@ export default {
if (val === 'qc' && !this.sampleDetail.qc) { if (val === 'qc' && !this.sampleDetail.qc) {
this.$message.warning('No qc spectrum file!') this.$message.warning('No qc spectrum file!')
} else { } else {
if (val == 'sample') this.currSpectrum = 'Sample'
if (val == 'gasBg') this.currSpectrum = 'Gas'
if (val == 'detBg') this.currSpectrum = 'Det'
if (val == 'qc') this.currSpectrum = 'QC'
const { const {
betaOriginalData, betaOriginalData,
betaProjectedData, betaProjectedData,

View File

@ -340,6 +340,7 @@ export default {
// Beta-Gamma Spectrum: Sample // Beta-Gamma Spectrum: Sample
handleChange(index) { handleChange(index) {
this.active = index this.active = index
this.handleUnzoom()
// v-show(Unzoom)resize0, resize // v-show(Unzoom)resize0, resize
if (this.active == 0) { if (this.active == 0) {

View File

@ -65,6 +65,7 @@ export default {
zoom: this.zoom, zoom: this.zoom,
maxZoom: this.maxZoom, maxZoom: this.maxZoom,
minZoom: this.minZoom, minZoom: this.minZoom,
extent: [-20037508.34 - 3500000, -20037508.34 , 20037508.34 + 3500000, 20037508.34],
}) })
this.map = new Map({ this.map = new Map({

View File

@ -26,30 +26,30 @@ export default {
props: { props: {
list: { list: {
type: Array, type: Array,
required: true required: true,
}, },
currList: { currList: {
type: Array, type: Array,
required: true required: true,
}, },
orgList: { orgList: {
type: Array, type: Array,
required: true required: true,
}, },
markerType: { markerType: {
type: Number, type: Number,
default: 1 default: 1,
}, },
radius: { radius: {
type: Number type: Number,
} },
}, },
data() { data() {
return { return {
currStationInfo: {}, currStationInfo: {},
isGettingInfo: false, isGettingInfo: false,
columns: {}, columns: {},
popupTitle: '' popupTitle: '',
} }
}, },
mounted() { mounted() {
@ -59,7 +59,7 @@ export default {
this.changeCircleRadius() this.changeCircleRadius()
}) })
this.getStationInfo = debounce(stationInfo => { this.getStationInfo = debounce((stationInfo) => {
// //
if (this.isHover) { if (this.isHover) {
this._getStationInfo(stationInfo) this._getStationInfo(stationInfo)
@ -69,13 +69,14 @@ export default {
methods: { methods: {
initCircles() { initCircles() {
const circleRadius = this.getRadius() * 2 const circleRadius = this.getRadius() * 2
console.log('this.list', this.list)
this.list this.list
.filter( .filter(
stationInfo => (stationInfo) =>
stationInfo.stationType !== MarkerType.NuclearFacility && stationInfo.stationType !== MarkerType.NRL stationInfo.stationType !== MarkerType.NuclearFacility && stationInfo.stationType !== MarkerType.NRL
) )
.forEach(stationInfo => { .forEach((stationInfo) => {
this.map.addOverlay(this.getCircle(stationInfo, circleRadius)) this.map.addOverlay(this.getCircle(stationInfo, circleRadius))
}) })
}, },
@ -92,17 +93,17 @@ export default {
element: circleDiv, element: circleDiv,
id: `circle_${stationType}_${stationId}`, id: `circle_${stationType}_${stationId}`,
positioning: 'center-center', positioning: 'center-center',
className: 'circle-overlay' className: 'circle-overlay',
}) })
}, },
// //
changeCircleRadius() { changeCircleRadius() {
const overlays = this.map.getOverlays().getArray() const overlays = this.map.getOverlays().getArray()
const circleOverlays = overlays.filter(item => item.id.indexOf('circle') == 0) // id const circleOverlays = overlays.filter((item) => item.id.indexOf('circle') == 0) // id
const circleRadius = this.getRadius() * 2 const circleRadius = this.getRadius() * 2
circleOverlays.forEach(circle => { circleOverlays.forEach((circle) => {
const circleEle = circle.getElement() const circleEle = circle.getElement()
circleEle.style.width = circleRadius + 'px' circleEle.style.width = circleRadius + 'px'
circleEle.style.height = circleRadius + 'px' circleEle.style.height = circleRadius + 'px'
@ -111,10 +112,7 @@ export default {
// //
getRadius() { getRadius() {
const metersPerUnit = this.map const metersPerUnit = this.map.getView().getProjection().getMetersPerUnit()
.getView()
.getProjection()
.getMetersPerUnit()
const distance = (this.radius * 1000) / metersPerUnit const distance = (this.radius * 1000) / metersPerUnit
const resolution = this.map.getView().getResolution() const resolution = this.map.getView().getResolution()
@ -123,7 +121,7 @@ export default {
// marker // marker
initMarkers() { initMarkers() {
this.list.forEach(stationInfo => { this.list.forEach((stationInfo) => {
this.map.addOverlay(this.getMarker(stationInfo)) this.map.addOverlay(this.getMarker(stationInfo))
}) })
}, },
@ -153,18 +151,19 @@ export default {
position: fromLonLat([lon, lat]), position: fromLonLat([lon, lat]),
element: img, element: img,
id: `marker_${stationInfo.stationType}_${stationInfo.stationId}`, id: `marker_${stationInfo.stationType}_${stationInfo.stationId}`,
positioning: 'center-center' positioning: 'center-center',
}) })
}, },
// //
initRipples() { initRipples() {
this.currList this.currList
.filter((stationInfo) => stationInfo.status !== 'Unoperating')
// .filter( // .filter(
// stationInfo => // stationInfo =>
// stationInfo.stationType !== MarkerType.NuclearFacility && stationInfo.stationType !== MarkerType.NRL // stationInfo.stationType !== MarkerType.NuclearFacility && stationInfo.stationType !== MarkerType.NRL
// ) // )
.forEach(stationInfo => { .forEach((stationInfo) => {
this.map.addOverlay(this.getRipple(stationInfo)) this.map.addOverlay(this.getRipple(stationInfo))
}) })
}, },
@ -172,15 +171,15 @@ export default {
getRipple({ lon, lat, stationId, stationType, quality }) { getRipple({ lon, lat, stationId, stationType, quality }) {
const rippleDiv = document.createElement('div') const rippleDiv = document.createElement('div')
rippleDiv.className = 'custom-ripple' rippleDiv.className = 'custom-ripple'
if (quality == "excellent") { if (quality == 'excellent') {
rippleDiv.innerHTML = ` <div class="inner-ripple-excellent-1"></div> rippleDiv.innerHTML = ` <div class="inner-ripple-excellent-1"></div>
<div class="inner-ripple-excellent-2"></div> <div class="inner-ripple-excellent-2"></div>
` `
} else if (quality == "good") { } else if (quality == 'good') {
rippleDiv.innerHTML = ` <div class="inner-ripple-good-1"></div> rippleDiv.innerHTML = ` <div class="inner-ripple-good-1"></div>
<div class="inner-ripple-good-2"></div> <div class="inner-ripple-good-2"></div>
` `
} else if(quality == "bad"){ } else if (quality == 'bad') {
rippleDiv.innerHTML = ` <div class="inner-ripple-bad-1"></div> rippleDiv.innerHTML = ` <div class="inner-ripple-bad-1"></div>
<div class="inner-ripple-bad-2"></div> <div class="inner-ripple-bad-2"></div>
` `
@ -191,7 +190,7 @@ export default {
element: rippleDiv, element: rippleDiv,
id: `ripple_${stationType}_${stationId}`, id: `ripple_${stationType}_${stationId}`,
positioning: 'center-center', positioning: 'center-center',
className: 'ripple-overlay' className: 'ripple-overlay',
}) })
}, },
@ -200,7 +199,7 @@ export default {
this.popupOverlay = new Overlay({ this.popupOverlay = new Overlay({
element: this.$refs.mapPopupRef, element: this.$refs.mapPopupRef,
positioning: 'top-center', positioning: 'top-center',
id: POPUP_OVERLAY_ID id: POPUP_OVERLAY_ID,
}) })
this.map.addOverlay(this.popupOverlay) this.map.addOverlay(this.popupOverlay)
}, },
@ -220,15 +219,16 @@ export default {
try { try {
const { success, result, message } = await getAction('/jeecg-station-operation/stationOperation/findInfo', { const { success, result, message } = await getAction('/jeecg-station-operation/stationOperation/findInfo', {
stationId: stationInfo.stationId, stationId: stationInfo.stationId,
type: stationInfo.stationType type: stationInfo.stationType,
}) })
if (success) { if (success) {
result.lon = decimalToDms(result.lon || result.longitude) result.lon = decimalToDms(result.lon || result.longitude)
result.lat = decimalToDms(result.lat || result.latitude, false) result.lat = decimalToDms(result.lat || result.latitude, false)
let params = this.currList.find(item => { let params =
return item.stationId === result.stationId this.currList.find((item) => {
}) || {} return item.stationId === result.stationId
}) || {}
this.currStationInfo = { ...result, ...params } this.currStationInfo = { ...result, ...params }
} else { } else {
this.$message.error(message) this.$message.error(message)
@ -243,7 +243,7 @@ export default {
// //
closeMapPopup() { closeMapPopup() {
this.popupOverlay.setPosition(null) this.popupOverlay.setPosition(null)
} },
}, },
watch: { watch: {
list() { list() {
@ -257,19 +257,22 @@ export default {
}, },
currList: { currList: {
handler(newVal, oldVal) { handler(newVal, oldVal) {
this.orgList.forEach(item => { this.orgList.forEach((item) => {
var layer = this.map.getOverlays().getArray().find(layer=> { var layer = this.map
return layer.id === `ripple_${item.stationType}_${item.stationId}`; .getOverlays()
}); .getArray()
.find((layer) => {
return layer.id === `ripple_${item.stationType}_${item.stationId}`
})
if (layer) { if (layer) {
this.map.removeOverlay(layer); this.map.removeOverlay(layer)
} }
}) })
this.initRipples() this.initRipples()
}, },
deep:true deep: true,
} },
} },
} }
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@ -362,7 +365,12 @@ export default {
width: 100%; width: 100%;
height: 100%; height: 100%;
border-radius: 50%; border-radius: 50%;
background-image: radial-gradient(circle, transparent 10%, rgba(187, 138, 18, 0.2) 30%, rgba(187, 138, 18, 0.5) 60%); background-image: radial-gradient(
circle,
transparent 10%,
rgba(187, 138, 18, 0.2) 30%,
rgba(187, 138, 18, 0.5) 60%
);
animation: rippleEffect @duration linear 0s infinite; animation: rippleEffect @duration linear 0s infinite;
} }
@ -373,7 +381,12 @@ export default {
height: 100%; height: 100%;
border-radius: 50%; border-radius: 50%;
transform: scale(0); transform: scale(0);
background-image: radial-gradient(circle, transparent 10%, rgba(187, 138, 18, 0.2) 30%, rgba(187, 138, 18, 0.5) 60%); background-image: radial-gradient(
circle,
transparent 10%,
rgba(187, 138, 18, 0.2) 30%,
rgba(187, 138, 18, 0.5) 60%
);
animation: rippleEffect @duration linear @delay infinite; animation: rippleEffect @duration linear @delay infinite;
} }
.inner-ripple-bad-1 { .inner-ripple-bad-1 {

View File

@ -548,8 +548,8 @@ export default {
// //
onMarkerClick(stationInfo) { onMarkerClick(stationInfo) {
const { stationType } = stationInfo const { stationType, status } = stationInfo
if (stationType !== 'NRL' && stationType !== 'Nuclear Facility') { if (stationType !== 'NRL' && stationType !== 'Nuclear Facility' && status !== 'Unoperating') {
this.$refs.mapPane.handleOpenAnalyzeModal(stationInfo) this.$refs.mapPane.handleOpenAnalyzeModal(stationInfo)
} }
}, },