| | |
| | | @click.stop="goEdit(item)"> |
| | | 编辑 |
| | | </up-button> |
| | | <up-button class="action-btn" |
| | | <up-button v-if="!isSystemTemplate(item)" |
| | | class="action-btn" |
| | | size="small" |
| | | type="error" |
| | | plain |
| | |
| | | buildTypeLabelMap, |
| | | fetchApprovalTemplateTypes, |
| | | getTemplateTypeLabel, |
| | | isSystemApprovalTemplate, |
| | | } from "../../_utils/approvalTemplateType.js"; |
| | | |
| | | const EDIT_STORAGE_KEY = "oa_approve_template_edit_row"; |
| | |
| | | |
| | | const businessTypeText = type => |
| | | getTemplateTypeLabel(type, typeLabelMap.value); |
| | | |
| | | const isSystemTemplate = isSystemApprovalTemplate; |
| | | |
| | | const loadTemplateTypes = () => |
| | | fetchApprovalTemplateTypes() |
| | |
| | | |
| | | const handleDelete = item => { |
| | | if (!item?.id) return; |
| | | if (isSystemTemplate(item)) { |
| | | uni.showToast({ title: "系统内置模板不可删除", icon: "none" }); |
| | | return; |
| | | } |
| | | const name = item.templateName || "该模板"; |
| | | uni.showModal({ |
| | | title: "删除确认", |