提交代码

This commit is contained in:
wangchengming 2025-08-19 20:04:30 +08:00
parent af87d06d5e
commit 38f2a79e15
13 changed files with 555 additions and 37 deletions

View File

@ -42,6 +42,7 @@ import "tinymce/plugins/importcss"; //引入自定义样式的css文件
import "tinymce/plugins/accordion"; //
import "tinymce/plugins/anchor"; //
import "tinymce/plugins/fullscreen";
// import "tinymce/plugins/fomat"; //
import { uploadFile } from "@/api/qualification/myQualifications"
const emits = defineEmits(["update:modelValue"]);
@ -78,7 +79,7 @@ const props = defineProps({
},
toolbar: {
type: [String, Array, Boolean],
default: "newdocument undo redo | formatselect visualaid|cut selectall| bold italic underline strikethrough |codeformat blockformats| superscript subscript | forecolor backcolor | alignleft aligncenter alignright alignjustify | outdent indent | removeformat bullist numlist lists | image table media link |fullscreen insertdatetime visualchars visualblocks searchreplace pagebreak anchor charmap",
default: "newdocument undo redo | fontfamily fontsize | formatpainter cut selectall | bold italic underline strikethrough |codeformat blockformats| superscript subscript | forecolor backcolor | alignleft aligncenter alignright alignjustify | outdent indent | removeformat bullist numlist lists | image table media link |fullscreen insertdatetime visualchars visualblocks searchreplace pagebreak anchor charmap",
// default: "undo redo | accordion accordionremove | blocks fontfamily fontsize| bold italic underline strikethrough ltr rtl | align numlist bullist | link image | table | lineheight outdent indent| forecolor backcolor removeformat | charmap emoticons | anchor codesample",
},
readonly: {
@ -96,10 +97,338 @@ const props = defineProps({
});
const loading = ref(false);
const tinymceId = ref(
"vue-tinymce-" + +new Date() + ((Math.random() * 1000).toFixed(0) + "")
"vue-tinymce-" + +new Date() + ((Math.random() * 1000).toFixed(0) + "")
);
const baseUrl = import.meta.env.VITE_APP_BASE_API
// 使
const formatPainter = (function () {
let formatPainterActive = false;
let cachedFormats = null;
let cachedStyles = null;
let cachedAttributes = null;
let cachedClasses = null;
let lastApplyTime = 0;
let nodeChangeTimeout = null;
let editorInstance = null;
const EXCLUDED_FORMATS = ['removeformat', 'remove', 'delete', 'cut', 'paste'];
return {
init: function (editor) {
console.log('格式刷初始化');
editorInstance = editor;
//
editor.ui.registry.addButton('formatpainter', {
icon: 'paste',
tooltip: '格式刷 - 点击激活,选择文本应用格式',
onAction: function () {
console.log('格式刷按钮点击');
if (formatPainterActive) {
this.deactivate(editor);
} else {
this.activate(editor);
}
}.bind(this)
});
},
isSafeFormat: function (formatName) {
return typeof formatName === 'string' &&
formatName.trim().length > 0 &&
!EXCLUDED_FORMATS.includes(formatName);
},
//
activate: function (editor) {
const selection = editor.selection;
if (!selection.isCollapsed()) {
this.captureCurrentFormats(editor);
formatPainterActive = true;
// this.updateButtonState(true);
editor.notificationManager.open({
text: '格式刷已激活 - 选择目标文本应用格式',
type: 'info',
timeout: 2000
});
//
this.applyFormatOnMouseUpBound = this.applyFormatOnMouseUp.bind(this);
this.applyFormatOnKeyUpBound = this.applyFormatOnKeyUp.bind(this);
editor.on('mouseup', this.applyFormatOnMouseUpBound);
editor.on('keyup', this.applyFormatOnKeyUpBound);
} else {
editor.notificationManager.open({
text: '请先选择带有格式的文本',
type: 'warning'
});
return;
}
},
//
deactivate: function (editor) {
formatPainterActive = false;
// this.updateButtonState(false);
//
if (this.applyFormatOnMouseUpBound) {
editor.off('mouseup', this.applyFormatOnMouseUpBound);
}
if (this.applyFormatOnKeyUpBound) {
editor.off('keyup', this.applyFormatOnKeyUpBound);
}
//
if (nodeChangeTimeout) {
clearTimeout(nodeChangeTimeout);
nodeChangeTimeout = null;
}
},
// -
captureCurrentFormats: function (editor) {
cachedFormats = [];
cachedStyles = {};
cachedAttributes = {};
cachedClasses = [];
try {
const formatter = editor.formatter;
const selectedNode = editor.selection.getNode();
console.log('选中的节点:', selectedNode);
console.log('节点标签名:', selectedNode?.tagName);
console.log('节点类名:', selectedNode?.className);
console.log('节点样式:', selectedNode?.style?.cssText);
//
const safeCommonFormats = [
'bold', 'italic', 'underline', 'strikethrough',
'superscript', 'subscript', 'forecolor', 'backcolor',
'fontname', 'fontsize', 'alignleft', 'aligncenter',
'alignright', 'alignjustify', 'bullist', 'numlist',
'outdent', 'indent', 'blockquote', 'code',
'link', 'image'
];
let matchedFormats = 0;
safeCommonFormats.forEach(formatName => {
if (this.isSafeFormat(formatName)) {
try {
const isMatched = formatter.match(formatName);
if (isMatched) {
console.log(`格式匹配: ${formatName}`);
matchedFormats++;
cachedFormats.push({
name: formatName,
attributes: {},
styles: {},
classes: []
});
}
} catch (e) {
console.warn(`检查格式 ${formatName} 时出错:`, e);
}
}
});
console.log(`总共匹配了 ${matchedFormats} 种格式`);
//
if (selectedNode && selectedNode.style) {
console.log('开始获取内联样式...');
let styleCount = 0;
for (let i = 0; i < selectedNode.style.length; i++) {
const prop = selectedNode.style[i];
if (prop && selectedNode.style[prop]) {
cachedStyles[prop] = selectedNode.style[prop];
styleCount++;
}
}
console.log(`获取了 ${styleCount} 个内联样式`);
}
//
if (selectedNode && selectedNode.className) {
console.log('开始获取类名...');
cachedClasses = selectedNode.className.split(' ')
.filter(cls => cls && cls.trim())
.map(cls => cls.trim());
console.log(`获取了 ${cachedClasses.length} 个类名:`, cachedClasses);
}
//
console.log('=== 捕获的格式信息 ===');
console.log('格式:', cachedFormats.map(f => f.name));
console.log('样式:', Object.keys(cachedStyles));
console.log('属性:', Object.keys(cachedAttributes));
console.log('类名:', cachedClasses);
console.log('=== 格式信息输出完成 ===');
//
console.log('cachedFormats 类型:', Array.isArray(cachedFormats) ? '数组' : typeof cachedFormats);
console.log('cachedFormats 长度:', cachedFormats.length);
console.log('cachedStyles 类型:', typeof cachedStyles);
console.log('cachedStyles 键数量:', Object.keys(cachedStyles).length);
} catch (error) {
console.error('捕获格式时出错:', error);
console.error('错误堆栈:', error.stack);
}
},
//
applyFormatOnMouseUp: function () {
if (formatPainterActive) {
if (nodeChangeTimeout) {
clearTimeout(nodeChangeTimeout);
}
nodeChangeTimeout = setTimeout(() => {
this.applyFormatIfNeeded(editorInstance);
}, 300);
}
},
//
applyFormatOnKeyUp: function () {
if (formatPainterActive) {
if (nodeChangeTimeout) {
clearTimeout(nodeChangeTimeout);
}
nodeChangeTimeout = setTimeout(() => {
this.applyFormatIfNeeded(editorInstance);
}, 200);
}
},
//
applyFormatIfNeeded: function (editor) {
const now = Date.now();
if (now - lastApplyTime < 500) {
console.log('时间间隔太短,跳过');
return;
}
if (formatPainterActive && !editor.selection.isCollapsed()) {
lastApplyTime = now;
try {
setTimeout(() => {
this.applyFormats(editor);
this.deactivate(editor);
}, 100);
} catch (error) {
console.error('应用格式时出错:', error);
this.deactivate(editor);
}
} else {
console.log('不满足应用条件:', {
active: formatPainterActive,
collapsed: editor.selection.isCollapsed()
});
}
},
//
applyFormats: function (editor) {
if ((!cachedFormats || cachedFormats.length === 0) &&
(!cachedStyles || Object.keys(cachedStyles).length === 0)) {
return;
}
try {
const bookmark = editor.selection.getBookmark();
const selectedNode = editor.selection.getNode();
console.log('应用格式数量:', cachedFormats?.length || 0);
console.log('应用样式数量:', Object.keys(cachedStyles || {}).length);
//
if (cachedFormats && cachedFormats.length > 0) {
cachedFormats.forEach(format => {
if (this.isSafeFormat(format.name)) {
try {
editor.formatter.apply(format.name);
} catch (e) {
console.warn('应用格式失败:', format.name, e);
}
}
});
}
//
if (cachedStyles && selectedNode && selectedNode.style) {
Object.keys(cachedStyles).forEach(prop => {
try {
selectedNode.style[prop] = cachedStyles[prop];
} catch (e) {
console.warn('应用样式失败:', prop, e);
}
});
}
editor.selection.moveToBookmark(bookmark);
editor.notificationManager.open({
text: '格式已成功应用',
type: 'success',
timeout: 1500
});
console.log('格式应用完成');
} catch (error) {
console.error('应用格式时出错:', error);
}
},
// //
// updateButtonState: function (isActive) {
// console.log(':', isActive ? '' : '');
// setTimeout(() => {
// try {
// const buttons = document.querySelectorAll('.tox-tbtn');
// console.log(':', buttons.length);
// buttons.forEach((button, index) => {
// const icon = button.querySelector('.tox-icon');
// const ariaLabel = button.getAttribute('aria-label') || '';
// if ((icon && icon.innerHTML.includes('paste')) ||
// ariaLabel.includes('')) {
// console.log(` (${index}):`, ariaLabel);
// if (isActive) {
// button.classList.add('format-painter-active');
// button.style.boxShadow = '0 0 0 2px #2196f3';
// console.log('');
// } else {
// button.classList.remove('format-painter-active');
// button.style.boxShadow = '';
// console.log('');
// }
// }
// });
// } catch (error) {
// console.warn(':', error);
// }
// }, 50);
// }
};
})();
// init
const init = reactive({
selector: "#" + tinymceId.value, //id,
@ -133,15 +462,43 @@ const init = reactive({
editimage_toolbar: "rotateleft rotateright | flipv fliph | editimage imageoptions",
//
font_family_formats:
"Arial=arial,helvetica,sans-serif; 宋体=SimSun; 微软雅黑=Microsoft Yahei; Impact=impact,chicago;", //
font_size_formats: "11px 12px 14px 16px 18px 24px 36px 48px 64px 72px", //
//
'微软雅黑=Microsoft YaHei,微软雅黑,Microsoft JhengHei,sans-serif;' +
'宋体=SimSun,宋体,serif;' +
'黑体=SimHei,黑体,sans-serif;' +
'楷体=KaiTi,楷体,serif;' +
'仿宋=FangSong,仿宋,serif;' +
'新宋体=NSimSun,新宋体,serif;' +
'华文细黑=STXihei,华文细黑,sans-serif;' +
'华文楷体=STKaiti,华文楷体,serif;' +
'华文宋体=STSong,华文宋体,serif;' +
'华文仿宋=STFangsong,华文仿宋,serif;' +
//
'Andale Mono=andale mono,times;' +
'Arial=arial,helvetica,sans-serif;' +
'Arial Black=arial black,avant garde;' +
'Book Antiqua=book antiqua,palatino;' +
'Comic Sans MS=comic sans ms,sans-serif;' +
'Courier New=courier new,courier;' +
'Georgia=georgia,palatino;' +
'Helvetica=helvetica;' +
'Impact=impact,chicago;' +
'Symbol=symbol;' +
'Tahoma=tahoma,arial,helvetica,sans-serif;' +
'Terminal=terminal,monaco;' +
'Times New Roman=times new roman,times;' +
'Trebuchet MS=trebuchet ms,geneva;' +
'Verdana=verdana,geneva;' +
'Webdings=webdings;' +
'Wingdings=wingdings,zapf dingbats;', //
font_size_formats: "8px 10px 12px 14px 16px 18px 24px 36px 48px 64px 72px", //
image_caption: true,
editimage_cors_hosts: ["picsum.photos"],
noneditable_class: "mceNonEditable",
toolbar_mode: "wrap", // floating / sliding / scrolling / wrap
//
content_style:
"body { font-family:Helvetica,Arial,sans-serif; font-size:16px }p {margin:3px; line-height:24px;}",
'body { font-family: Microsoft YaHei, Helvetica Neue, Arial, sans-serif; font-size: 16px; }',
image_advtab: true,
importcss_append: true,
paste_webkit_styles: "all",
@ -157,8 +514,40 @@ const init = reactive({
// autoresize_overflow_padding: 16,
min_height: props.minHeight,
content_css: "/tinymce/skins/content/default/content.css", //csscsscss
// setup: function (editor) {
// },
setup: function (editor) {
console.log('编辑器setup开始');
//
formatPainter.init(editor);
//
editor.addShortcut('ctrl+shift+c', '复制格式', function () {
console.log('快捷键 Ctrl+Shift+C 触发');
if (!editor.selection.isCollapsed()) {
formatPainter.captureCurrentFormats(editor);
editor.notificationManager.open({
text: '格式已复制',
type: 'success',
timeout: 1500
});
}
});
editor.addShortcut('ctrl+shift+v', '应用格式', function () {
console.log('快捷键 Ctrl+Shift+V 触发');
if (!editor.selection.isCollapsed()) {
formatPainter.applyFormats(editor);
}
});
//
editor.on('blur', function () {
console.log('编辑器失去焦点');
formatPainter.deactivate(editor);
});
console.log('编辑器setup完成');
},
//
images_upload_handler: async (blobInfo, progress) => {
return new Promise(async (resolve, reject) => {
@ -217,7 +606,7 @@ const init = reactive({
//
init_instance_callback: function (editor) {
console.log('初始化内容', props.value)
if (props.value) {
if (props.value) {
editor.setContent(props.value); //
emits('update:modelValue', editor.getContent()) //
}
@ -341,4 +730,9 @@ defineExpose({
.tinymce.ui.FloatPanel {
z-index: 99;
}
.format-painter-active {
background-color: #e3f2fd !important;
border: 2px solid #2196f3 !important;
}
</style>

View File

@ -88,7 +88,7 @@
<el-text v-if="scope.row.state == 9" type="danger" class="dangerText">驳回</el-text>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="100">
<el-table-column label="操作" fixed="right" align="center" width="130">
<template #default="scope">
<el-button type="primary" v-if="scope.row.state == 1 && scope.row.node == 2" text
v-hasPermi="['labelManage:adminApproval:approval']" class="replayTextBtn"
@ -96,6 +96,9 @@
<el-button type="primary" text class="replayTextBtn" v-else
v-hasPermi="['labelManage:adminApproval:detail']"
@click="handleView(scope.row)">查看</el-button>
<el-button type="primary" text class="deleteTextBtn"
v-hasPermi="['qualification:lableApplyDelete']"
@click="handleDetele(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
@ -110,7 +113,7 @@ import { useRouter } from 'vue-router'
import Breadcrumb from '@/components/Breadcrumb'
import importIcon from '@/assets/images/ImportIcon.png'
import { customerDeptTreeSelect, listUser } from "@/api/system/user"
import { getUserLabelPageList } from "@/api/labelManage/labelManage"
import { getUserLabelPageList, deleteBusUserLabel } from "@/api/labelManage/labelManage"
const { proxy } = getCurrentInstance()
const { bus_label } = proxy.useDict("bus_label")
@ -215,6 +218,16 @@ const resetQuery = () => {
handleQuery()
}
//
const handleDetele = (record) => {
const rowId = record.id
proxy.$modal.confirm('是否确认删除该项数据项?').then(function () {
return deleteBusUserLabel(rowId)
}).then(() => {
getBusUserLabelPageList();
proxy.$modal.msgSuccess("删除成功")
}).catch(() => { })
}
const handleView = (record) => {
router.push('/labelManage/adminApprovalDetail/' + record.id)
}

View File

@ -82,7 +82,7 @@
<el-text v-if="scope.row.state == 9" type="danger" class="dangerText">驳回</el-text>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" align="center" width="100">
<el-table-column label="操作" fixed="right" align="center" width="130">
<template #default="scope">
<el-button type="primary" v-if="scope.row.state == 1 && scope.row.node == 1" text
v-hasPermi="['labelManage:labelEscApproval:approval']" class="replayTextBtn"
@ -90,6 +90,9 @@
<el-button type="primary" text class="replayTextBtn" v-else
v-hasPermi="['labelManage:labelEscApproval:detail']"
@click="handleView(scope.row)">查看</el-button>
<el-button type="primary" text class="deleteTextBtn"
v-hasPermi="['qualification:lableApplyDelete']"
@click="handleDetele(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
@ -103,7 +106,7 @@ import { onMounted, ref } from 'vue'
import { useRouter } from 'vue-router'
import Breadcrumb from '@/components/Breadcrumb'
import { customerDeptTreeSelect, listUser } from "@/api/system/user"
import { getUserLabelPageList } from "@/api/labelManage/labelManage"
import { getUserLabelPageList, deleteBusUserLabel } from "@/api/labelManage/labelManage"
const { proxy } = getCurrentInstance()
const { bus_label } = proxy.useDict("bus_label")
@ -207,7 +210,16 @@ const resetQuery = () => {
proxy.resetForm("queryRef")
handleQuery()
}
//
const handleDetele = (record) => {
const rowId = record.id
proxy.$modal.confirm('是否确认删除该项数据项?').then(function () {
return deleteBusUserLabel(rowId)
}).then(() => {
getBusUserLabelPageList();
proxy.$modal.msgSuccess("删除成功")
}).catch(() => { })
}
const handleView = (record) => {
router.push('/labelManage/labelEscApprovalDetail/' + record.id)
}

View File

@ -68,9 +68,9 @@
<a class="replayTextBtn" :href="href">查看</a>
</el-button>
</router-link>
<el-divider direction="vertical" class="verticalLine" v-if="scope.row.state == 1" />
<el-button type="primary" text class="deleteTextBtn" v-if="scope.row.state == 1"
v-hasPermi="['qualification:lableApplyDelete']" @click="handleDetele(scope.row)">删除</el-button>
<el-divider direction="vertical" class="verticalLine" v-hasPermi="['qualification:lableApplyDelete']" />
<el-button type="primary" text class="deleteTextBtn" v-hasPermi="['qualification:lableApplyDelete']"
@click="handleDetele(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>

View File

@ -72,7 +72,7 @@
<a class="replayTextBtn" :href="href">查看</a>
</el-button>
</router-link>
<el-divider direction="vertical" class="verticalLine" />
<el-divider direction="vertical" class="verticalLine" v-hasPermi="['qualification:qualificationDelete']" />
<el-button type="primary" text class="deleteTextBtn"
v-hasPermi="['qualification:qualificationDelete']" @click="handleDetele(scope.row)">删除</el-button>
</template>

View File

@ -94,7 +94,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -126,7 +126,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -185,7 +185,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -260,7 +260,21 @@
<el-form-item label="急救证到期日期" prop="beforeCondition.firstCollectionExpireDate">
<el-date-picker v-model="ruleForm.beforeCondition.firstCollectionExpireDate"
type="date" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
placeholder="请选择急救证到期日期" style="width: 60%;" />
placeholder="请选择急救证到期日期" style="width: 60%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证初领日期" prop="beforeCondition.collectionDate">
<el-date-picker v-model="ruleForm.beforeCondition.collectionDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证初领日期"
style="width: 60%;" @change="handleCollectionDateChange" />
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 60%;" readonly />
</el-form-item>
</el-col>
<el-col :span="8" v-if="ruleForm.beforeCondition.hasQualified.length > 0">

View File

@ -307,6 +307,27 @@
placeholder="请选择急救证到期日期" style="width: 60%;" disabled />
</el-form-item>
</el-col>
<el-col :span="12" v-if="beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证初领日期">
<el-date-picker v-model="beforeCondition.collectionDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证初领日期"
style="width: 60%;" disabled />
</el-form-item>
</el-col>
<el-col :span="12" v-if="beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证复审日期">
<el-date-picker v-model="beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 60%;" disabled />
</el-form-item>
</el-col>
<el-col :span="8" v-if="beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证" prop="beforeCondition.certificatePhoto">
<img :src="beforeConditionInfo.certificatePhoto.split('.').pop() == 'pdf' ? pdfIcon : baseUrl + beforeConditionInfo.certificatePhoto"
class="avatar viewFile"
@click.stop="handleCardPreview(beforeConditionInfo.certificatePhoto)" />
</el-form-item>
</el-col>
<el-col :span="8" v-if="beforeConditionInfo.hasQualified.includes('SH')">
<el-form-item label="SH资质" prop="beforeCondition.shFile">
<img :src="beforeConditionInfo.shFile.split('.').pop() == 'pdf' ? pdfIcon : baseUrl + beforeConditionInfo.shFile"

View File

@ -93,7 +93,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -125,7 +125,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -184,7 +184,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -259,7 +259,21 @@
<el-form-item label="急救证到期日期" prop="beforeCondition.firstCollectionExpireDate">
<el-date-picker v-model="ruleForm.beforeCondition.firstCollectionExpireDate"
type="date" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
placeholder="请选择急救证到期日期" style="width: 60%;" />
placeholder="请选择急救证到期日期" style="width: 60%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证初领日期" prop="beforeCondition.collectionDate">
<el-date-picker v-model="ruleForm.beforeCondition.collectionDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证初领日期"
style="width: 60%;" @change="handleCollectionDateChange" />
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 60%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8" v-if="ruleForm.beforeCondition.hasQualified.length > 0">

View File

@ -39,9 +39,10 @@
<a class="replayTextBtn" :href="href">查看</a>
</el-button>
</router-link>
<el-divider direction="vertical" class="verticalLine" v-if="scope.row.state == 1" />
<el-button type="primary" text class="deleteTextBtn" v-if="scope.row.state == 1"
v-hasPermi="['qualification:lableApplyDelete']" @click="handleDetele(scope.row)">删除</el-button>
<el-divider direction="vertical" class="verticalLine"
v-hasPermi="['qualification:lableApplyDelete']" />
<el-button type="primary" text class="deleteTextBtn" v-hasPermi="['qualification:lableApplyDelete']"
@click="handleDetele(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>

View File

@ -40,7 +40,7 @@
<a class="replayTextBtn" :href="href">查看</a>
</el-button>
</router-link>
<el-divider direction="vertical" class="verticalLine" />
<el-divider direction="vertical" class="verticalLine" v-hasPermi="['qualification:qualificationDelete']" />
<el-button type="primary" text class="deleteTextBtn"
v-hasPermi="['qualification:qualificationDelete']"
@click="handleDetele(scope.row)">删除</el-button>

View File

@ -74,7 +74,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly />
</el-form-item>
</el-col>
<el-col :span="8">
@ -105,7 +105,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -161,7 +161,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -233,9 +233,23 @@
<el-form-item label="急救证到期日期" prop="beforeCondition.firstCollectionExpireDate">
<el-date-picker v-model="ruleForm.beforeCondition.firstCollectionExpireDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择急救证到期日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证初领日期" prop="beforeCondition.collectionDate">
<el-date-picker v-model="ruleForm.beforeCondition.collectionDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证初领日期"
style="width: 100%;" @change="handleCollectionDateChange" />
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" readonly />
</el-form-item>
</el-col>
<el-col :span="8" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证" prop="beforeCondition.certificatePhoto">
<myFileUpload ref="certificatePhotoRef" @set-form-file="handleSetCertificatePhoto" />

View File

@ -307,6 +307,27 @@
placeholder="请选择急救证到期日期" style="width: 60%;" disabled />
</el-form-item>
</el-col>
<el-col :span="12" v-if="beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证初领日期">
<el-date-picker v-model="beforeCondition.collectionDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证初领日期"
style="width: 60%;" disabled />
</el-form-item>
</el-col>
<el-col :span="12" v-if="beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证复审日期">
<el-date-picker v-model="beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 60%;" disabled />
</el-form-item>
</el-col>
<el-col :span="8" v-if="beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证" prop="beforeCondition.certificatePhoto">
<img :src="beforeConditionInfo.certificatePhoto.split('.').pop() == 'pdf' ? pdfIcon : baseUrl + beforeConditionInfo.certificatePhoto"
class="avatar viewFile"
@click.stop="handleCardPreview(beforeConditionInfo.certificatePhoto)" />
</el-form-item>
</el-col>
<el-col :span="8" v-if="beforeConditionInfo.hasQualified.includes('SH')">
<el-form-item label="SH资质" prop="beforeCondition.shFile">
<img :src="beforeConditionInfo.shFile.split('.').pop() == 'pdf' ? pdfIcon : baseUrl + beforeConditionInfo.shFile"

View File

@ -74,7 +74,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -105,7 +105,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -161,7 +161,7 @@
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="8">
@ -233,7 +233,21 @@
<el-form-item label="急救证到期日期" prop="beforeCondition.firstCollectionExpireDate">
<el-date-picker v-model="ruleForm.beforeCondition.firstCollectionExpireDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择急救证到期日期"
style="width: 100%;" />
style="width: 100%;" readonly/>
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证初领日期" prop="beforeCondition.collectionDate">
<el-date-picker v-model="ruleForm.beforeCondition.collectionDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证初领日期"
style="width: 100%;" @change="handleCollectionDateChange" />
</el-form-item>
</el-col>
<el-col :span="12" v-if="ruleForm.beforeCondition.hasQualified.length > 0">
<el-form-item label="电工证复审日期" prop="beforeCondition.reviewDate">
<el-date-picker v-model="ruleForm.beforeCondition.reviewDate" type="date"
format="YYYY-MM-DD" value-format="YYYY-MM-DD" placeholder="请选择电工证复审日期"
style="width: 100%;" readonly />
</el-form-item>
</el-col>
<el-col :span="8" v-if="ruleForm.beforeCondition.hasQualified.length > 0">