From 471988e97c28ba5458c8a34ccdbf092b4a1c287c Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 18 十二月 2025 12:04:46 +0800
Subject: [PATCH] 2025-12-18
---
src/utils/option.js | 563 +++++++++++++++++++++++++++++++-------------------------
1 files changed, 310 insertions(+), 253 deletions(-)
diff --git a/src/utils/option.js b/src/utils/option.js
index 75e5645..8d52262 100644
--- a/src/utils/option.js
+++ b/src/utils/option.js
@@ -1,11 +1,7 @@
-import zhCN from '@/locales/zh-CN/model.js'
-import enUS from '@/locales/en-US/model.js'
import nortable from '@/assets/img/normaltable.jpg'
-import mainsubtable from '@/assets/img/mainsubtable.jpg'
-import treepage from '@/assets/img/treepage.jpg'
+import customImg from '@/assets/img/custom.jpg'
+import newpage from '@/assets/img/newpage.jpg'
import rolemanage from '@/assets/img/rolemanage.jpg'
-
-const _dict = sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS
// 琛ㄥ崟鏍¢獙瑙勫垯
export const formRule = {
@@ -15,7 +11,6 @@
formMessage: '鏈�澶欯max涓瓧绗︺��', // 鏂囨湰琛ㄥ崟鏈�澶ф彁绀�
numbermsg: '璇疯緭鍏ユ暟瀛楋紒',
lettermsg: '璇疯緭鍏ュ瓧姣嶏紒',
- letternummsg: '璇疯緭鍏ユ暟瀛楁垨瀛楁瘝锛�',
funcname: '璇疯緭鍏ユ暟瀛椼�佸瓧姣嶃�佹眽瀛椾互鍙奯'
},
field: { // 瀛楁鍚�
@@ -49,30 +44,22 @@
export const sysTemps = [
{
title: '鍩虹琛ㄦ牸',
- type: 'CommonTable',
+ type: 'BaseTable',
url: nortable,
baseconfig: '',
isSystem: true
},
{
- title: '涓诲瓙琛ㄨ〃鏍�',
- type: 'CommonTable',
- url: mainsubtable,
- baseconfig: '',
- isSystem: true,
- isSubtable: true
- },
- {
- title: '鏍戝舰椤甸潰',
- type: 'TreePage',
- url: treepage,
+ title: '鑷畾涔�',
+ type: 'CustomPage',
+ url: customImg,
baseconfig: '',
isSystem: true
},
{
- title: '鏃ュ巻',
- type: 'CalendarPage',
- url: treepage,
+ title: '澶栭儴椤甸潰',
+ type: 'NewPage',
+ url: newpage,
baseconfig: '',
isSystem: true
},
@@ -80,68 +67,102 @@
title: '瑙掕壊鏉冮檺鍒嗛厤',
type: 'RolePermission',
url: rolemanage,
- isSystem: true,
- hidden: true
+ isSystem: true
}
]
+
+// 鍥捐〃鑹茬郴
+export const chartColors = ['rgb(91, 143, 249)', 'rgb(90, 216, 166)', 'rgb(93, 112, 146)', 'rgb(246, 189, 22)', 'rgb(232, 100, 82)', 'rgb(109, 200, 236)', 'rgb(148, 95, 185)', 'rgb(205, 221, 253)', 'rgb(248, 208, 203)', 'rgb(145, 213, 255)', 'rgb(211, 173, 247)']
// 鏃ユ湡榛樿鍊奸�夋嫨鑼冨洿
export const dateOptions = {
date: [
- {value: '', text: _dict['model.empty']},
- {value: '0', text: '褰撳ぉ'},
- {value: 1, text: '鏄ㄥぉ'},
- {value: 2, text: '鍓嶅ぉ'},
- {value: 3, text: '鍓嶄笁澶�'},
- {value: 7, text: '鍓嶄竷澶�'},
- {value: 30, text: '鍓�30澶�'},
- {value: -1, text: '鏄庡ぉ'},
- {value: -2, text: '鍚庡ぉ'}
+ {value: '', text: '绌�'},
+ {value: '0', text: '浠婂ぉ'},
+ {value: '1', text: '鏄ㄥぉ'},
+ {value: '2', text: '鍓嶅ぉ'},
+ {value: '3', text: '鍓嶄笁澶�'},
+ {value: '7', text: '鍓嶄竷澶�'},
+ {value: '30', text: '鍓�30澶�'},
+ {value: '90', text: '鍓�90澶�'},
+ {value: '7300', text: '鍓�20骞�'},
+ {value: '-1', text: '鏄庡ぉ'},
+ {value: '-2', text: '鍚庡ぉ'},
+ {value: '-3', text: '鍚庝笁澶�'},
+ {value: '-7', text: '鍚庝竷澶�'},
+ {value: '-30', text: '鍚�30澶�'},
+ {value: '-90', text: '鍚�90澶�'},
+ {value: '-180', text: '鍚庡崐骞�'},
+ {value: '-365', text: '鍚�1骞�'},
+ {value: '-1095', text: '鍚�3骞�'},
+ {value: '-1825', text: '鍚�5骞�'},
+ {value: '-3650', text: '鍚�10骞�'},
+ {value: '-7300', text: '鍚�20骞�'},
],
dateweek: [
- {value: '', text: _dict['model.empty']},
+ {value: '', text: '绌�'},
{value: '0', text: '鏈懆'},
- {value: 1, text: '涓婂懆'},
- {value: 3, text: '鍓嶄笁鍛�'},
- {value: 7, text: '鍓嶄竷鍛�'},
- {value: -1, text: '涓嬪懆'}
+ {value: '1', text: '涓婂懆'},
+ {value: '3', text: '鍓嶄笁鍛�'},
+ {value: '7', text: '鍓嶄竷鍛�'},
+ {value: '-1', text: '涓嬪懆'}
],
datemonth: [
- {value: '', text: _dict['model.empty']},
+ {value: '', text: '绌�'},
{value: '0', text: '鏈湀'},
- {value: 1, text: '涓婃湀'},
- {value: 3, text: '鍓嶄笁鏈�'},
- {value: 7, text: '鍓嶄竷鏈�'},
- {value: -1, text: '涓嬫湀'}
+ {value: '1', text: '涓婃湀'},
+ {value: '3', text: '鍓嶄笁鏈�'},
+ {value: '7', text: '鍓嶄竷鏈�'},
+ {value: '-1', text: '涓嬫湀'}
],
daterange: [
- {value: '', text: _dict['model.empty']},
+ {value: '', text: '绌�'},
{value: '[0, 0]', text: '浠婂ぉ'},
{value: '[1, 1]', text: '鏄ㄥぉ'},
{value: '[3, 0]', text: '杩戜笁澶�'},
{value: '[7, 0]', text: '杩戜竷澶�'},
{value: '[30, 0]', text: '杩�30澶�'},
+ {value: '[90, 0]', text: '杩�90澶�'},
{value: '[7, -7]', text: '鍓嶅悗涓冨ぉ'},
{value: '[30, -30]', text: '鍓嶅悗30澶�'},
{value: '[90, -90]', text: '鍓嶅悗90澶�'},
+ {value: '[180, -180]', label: '鍓嶅悗180澶�'},
+ {value: '[365, -365]', label: '鍓嶅悗365澶�'},
{value: '[-1, -1]', text: '鏄庡ぉ'},
- {value: '[-2, -2]', text: '鍚庡ぉ'}
+ {value: '[-2, -2]', text: '鍚庡ぉ'},
+ {value: 'week', text: '鏈懆'},
+ {value: 'month', text: '鏈湀'},
+ {value: 'lastMonth', text: '涓婃湀'},
+ {value: 'year', text: '鏈勾'},
+ {value: 'lastYear', text: '涓婂勾'},
],
datetime: [
- {value: '', text: _dict['model.empty']},
- {value: '0', text: '鐜板湪'},
- {value: 1, text: '鏄ㄥぉ'},
- {value: 3, text: '鍓嶄笁澶�'},
- {value: 7, text: '鍓嶄竷澶�'},
- {value: 30, text: '鍓�30澶�'},
- {value: -1, text: '鏄庡ぉ'},
- {value: -2, text: '鍚庡ぉ'}
+ {value: '', text: '绌�'},
+ {value: '0', text: '褰撳墠'},
+ {value: '1', text: '鏄ㄥぉ'},
+ {value: '3', text: '鍓嶄笁澶�'},
+ {value: '7', text: '鍓嶄竷澶�'},
+ {value: '30', text: '鍓�30澶�'},
+ {value: '90', text: '鍓�90澶�'},
+ {value: '7300', text: '鍓�20骞�'},
+ {value: '-1', text: '鏄庡ぉ'},
+ {value: '-2', text: '鍚庡ぉ'},
+ {value: '-3', text: '鍚庝笁澶�'},
+ {value: '-7', text: '鍚庝竷澶�'},
+ {value: '-30', text: '鍚�30澶�'},
+ {value: '-90', text: '鍚�90澶�'},
+ {value: '-180', text: '鍚庡崐骞�'},
+ {value: '-365', text: '鍚�1骞�'},
+ {value: '-1095', text: '鍚�3骞�'},
+ {value: '-1825', text: '鍚�5骞�'},
+ {value: '-3650', text: '鍚�10骞�'},
+ {value: '-7300', text: '鍚�20骞�'},
]
}
// 鍖归厤瑙勫垯
export const matchReg = {
- text: [{
+ class1: [{
value: 'like',
text: 'like'
}, {
@@ -150,25 +171,43 @@
}, {
value: '=',
text: '='
- }],
- multiselect: [{
- value: 'like',
- text: 'like'
}, {
- value: 'not like',
- text: 'not like'
+ value: '>',
+ text: '>'
+ }, {
+ value: '<',
+ text: '<'
+ }, {
+ value: '>=',
+ text: '>='
+ }, {
+ value: '<=',
+ text: '<='
}],
- select: [{
+ class2: [{
value: '=',
text: '='
}, {
+ value: '>',
+ text: '>'
+ }, {
+ value: '<',
+ text: '<'
+ }, {
+ value: '>=',
+ text: '>='
+ }, {
+ value: '<=',
+ text: '<='
+ }],
+ class3: [{
value: 'like',
text: 'like'
}, {
value: 'not like',
text: 'not like'
}],
- date: [{
+ class4: [{
value: '>=',
text: '>='
}, {
@@ -178,21 +217,21 @@
value: '=',
text: '='
}],
- datemonth: [{
+ class5: [{
value: 'between',
text: 'between'
}],
- daterange: [{
+ class6: [{
value: 'between',
text: 'between'
+ }, {
+ value: '=',
+ text: '='
}]
}
// 鎸夐挳鍥炬爣闆�
export const btnIcons = [{
- value: '',
- text: 'unset'
-}, {
value: 'plus',
text: 'plus'
}, {
@@ -252,6 +291,21 @@
}, {
value: 'unlock',
text: 'unlock'
+}, {
+ value: 'right',
+ text: 'right'
+}, {
+ value: 'left',
+ text: 'left'
+}, {
+ value: 'double-right',
+ text: 'double-right'
+}, {
+ value: 'double-left',
+ text: 'double-left'
+}, {
+ value: 'search',
+ text: 'search'
}]
// 鎸夐挳棰滆壊闆�
@@ -303,6 +357,45 @@
}, {
value: 'border-dgreen',
text: '鐧藉簳娣辩豢妗�'
+}, {
+ value: 'border-purple',
+ text: '鐧藉簳绱'
+}]
+
+// 鎸夐挳棰滆壊闆�
+export const modalClasses = [{
+ value: 'primary',
+ text: '钃濊壊'
+}, {
+ value: 'yellow',
+ text: '榛勮壊'
+}, {
+ value: 'orange',
+ text: '姗欒壊'
+}, {
+ value: 'danger',
+ text: '绾㈣壊'
+}, {
+ value: 'green',
+ text: '缁胯壊'
+}, {
+ value: 'purple',
+ text: '绱壊'
+}, {
+ value: 'border-primary',
+ text: '鐧藉簳钃濇'
+}, {
+ value: 'border-yellow',
+ text: '鐧藉簳榛勬'
+}, {
+ value: 'border-orange',
+ text: '鐧藉簳姗欐'
+}, {
+ value: 'border-danger',
+ text: '鐧藉簳绾㈡'
+}, {
+ value: 'border-green',
+ text: '鐧藉簳缁挎'
}, {
value: 'border-purple',
text: '鐧藉簳绱'
@@ -411,16 +504,16 @@
'blue-8': '#0050b3',
'blue-9': '#003a8c',
'blue-10': '#002766',
- 'geekblue-1': '#f0f5ff',
- 'geekblue-2': '#d6e4ff',
- 'geekblue-3': '#adc6ff',
- 'geekblue-4': '#85a5ff',
- 'geekblue-5': '#597ef7',
- 'geekblue-6': '#2f54eb',
- 'geekblue-7': '#1d39c4',
- 'geekblue-8': '#10239e',
- 'geekblue-9': '#061178',
- 'geekblue-10': '#030852',
+ 'geekblue-1': '#f0f6ff',
+ 'geekblue-2': '#dee9ff',
+ 'geekblue-3': '#b5ccff',
+ 'geekblue-4': '#8cadff',
+ 'geekblue-5': '#638aff',
+ 'geekblue-6': '#3860f4',
+ 'geekblue-7': '#2544cf',
+ 'geekblue-8': '#162ca8',
+ 'geekblue-9': '#0a1882',
+ 'geekblue-10': '#060e5c',
'purple-1': '#f9f0ff',
'purple-2': '#efdbff',
'purple-3': '#d3adf7',
@@ -441,6 +534,7 @@
'magenta-8': '#9e1068',
'magenta-9': '#780650',
'magenta-10': '#520339',
+ 'transparent': 'transparent',
'gray-1': '#f5f5f5',
'gray-2': '#f0f0f0',
'gray-3': '#d9d9d9',
@@ -590,6 +684,7 @@
value: 'Gray',
label: '涓�ц壊',
children: [
+ { value: 'transparent', label: 'transparent' },
{ value: 'gray-2', label: 'gray-2' },
{ value: 'gray-4', label: 'gray-4' },
{ value: 'gray-6', label: 'gray-6' },
@@ -601,94 +696,47 @@
export const minkeIconSystem = {
direction: [
- 'step-backward',
- 'step-forward',
- 'fast-backward',
- 'fast-forward',
- 'shrink',
- 'arrows-alt',
- 'down',
- 'up',
- 'left',
- 'right',
- 'caret-up',
- 'caret-down',
- 'caret-left',
- 'caret-right',
- 'up-circle',
- 'down-circle',
- 'left-circle',
- 'right-circle',
- 'double-right',
- 'double-left',
- 'vertical-left',
- 'vertical-right',
- 'vertical-align-top',
- 'vertical-align-middle',
- 'vertical-align-bottom',
- 'forward',
- 'backward',
- 'rollback',
- 'enter',
- 'retweet',
- 'swap',
- 'swap-left',
- 'swap-right',
'arrow-up',
'arrow-down',
'arrow-left',
'arrow-right',
+ 'down',
+ 'up',
+ 'left',
+ 'right',
+ 'download',
+ 'upload',
+ 'step-backward',
+ 'step-forward',
+ 'double-right',
+ 'double-left',
+ 'rollback',
+ 'enter',
+ 'retweet',
+ 'swap',
'play-circle',
- 'up-square',
- 'down-square',
- 'left-square',
- 'right-square',
'login',
'logout',
- 'menu-fold',
- 'menu-unfold',
- 'border-bottom',
- 'border-horizontal',
- 'border-inner',
- 'border-outer',
- 'border-left',
- 'border-right',
- 'border-top',
- 'border-verticle',
- 'pic-center',
- 'pic-left',
- 'pic-right',
- 'radius-bottomleft',
- 'radius-bottomright',
- 'radius-upleft',
- 'radius-upright',
+ 'search',
'fullscreen',
- 'fullscreen-exit'
+ 'fullscreen-exit',
],
hint: [
- 'question',
- 'question-circle',
'plus',
'plus-circle',
- 'pause',
'pause-circle',
'minus',
'minus-circle',
- 'plus-square',
- 'minus-square',
- 'info',
+ 'question',
+ 'question-circle',
'info-circle',
- 'exclamation',
'exclamation-circle',
'close',
'close-circle',
- 'close-square',
'check',
'check-circle',
- 'check-square',
'clock-circle',
'warning',
- 'issues-close',
'stop'
],
edit: [
@@ -698,33 +746,14 @@
'scissor',
'delete',
'snippets',
- 'diff',
'highlight',
- 'align-center',
- 'align-left',
- 'align-right',
- 'bg-colors',
- 'bold',
- 'italic',
- 'underline',
- 'strikethrough',
'redo',
'undo',
'zoom-in',
'zoom-out',
- 'font-colors',
- 'font-size',
- 'line-height',
'dash',
- 'small-dash',
'sort-ascending',
- 'sort-descending',
- 'drag',
- 'ordered-list',
- 'unordered-list',
- 'radius-setting',
- 'column-width',
- 'column-height'
+ 'sort-descending'
],
data: [
'area-chart',
@@ -733,66 +762,12 @@
'dot-chart',
'line-chart',
'radar-chart',
- 'heat-map',
'fall',
'rise',
'stock',
- 'box-plot',
- 'fund',
- 'sliders'
- ],
- trademark: [
- 'android',
- 'apple',
- 'windows',
- 'ie',
- 'chrome',
- 'github',
- 'aliwangwang',
- 'dingding',
- 'weibo-square',
- 'weibo-circle',
- 'taobao-circle',
- 'html5',
- 'weibo',
- 'twitter',
- 'wechat',
- 'youtube',
- 'alipay-circle',
- 'taobao',
- 'skype',
- 'qq',
- 'medium-workmark',
- 'gitlab',
- 'medium',
- 'linkedin',
- 'google-plus',
- 'dropbox',
- 'facebook',
- 'codepen',
- 'code-sandbox',
- 'amazon',
- 'google',
- 'codepen-circle',
- 'alipay',
- 'ant-design',
- 'ant-cloud',
- 'aliyun',
- 'zhihu',
- 'slack',
- 'slack-square',
- 'behance',
- 'behance-square',
- 'dribbble',
- 'dribbble-square',
- 'instagram',
- 'yuque',
- 'alibaba',
- 'yahoo',
- 'reddit',
- 'sketch'
],
normal: [
+ 'user',
'account-book',
'alert',
'api',
@@ -800,42 +775,22 @@
'audio',
'bank',
'bell',
- 'book',
+ 'scan',
'bug',
- 'bulb',
- 'calculator',
- 'build',
'calendar',
'camera',
- 'car',
- 'carry-out',
'cloud',
- 'code',
'compass',
- 'contacts',
- 'container',
- 'control',
'credit-card',
- 'crown',
'customer-service',
'dashboard',
+ 'ellipsis',
+ 'more',
'database',
'dislike',
'environment',
- 'experiment',
'eye-invisible',
'eye',
- 'file-add',
- 'file-excel',
- 'file-exclamation',
- 'file-image',
- 'file-markdown',
- 'file-pdf',
- 'file-ppt',
- 'file-text',
- 'file-unknown',
- 'file-word',
- 'file-zip',
'file',
'filter',
'fire',
@@ -843,41 +798,143 @@
'folder-add',
'folder',
'folder-open',
- 'frown',
- 'funnel-plot',
- 'gift',
- 'hdd',
'heart',
'home',
'hourglass',
'idcard',
- 'insurance',
- 'interaction',
- 'layout',
'like',
'lock',
'mail',
- 'medicine-box',
- 'meh',
'message',
'mobile',
'phone',
'picture',
'red-envelope',
+ 'setting',
+ 'tool',
'smile',
'star',
'thunderbolt',
- 'trophy',
'unlock',
'barcode',
'key',
'man',
'woman',
+ 'team',
'poweroff',
- 'search',
'shopping-cart',
- 'link'
+ 'link',
+ 'aim',
+ 'apartment',
+ 'appstore-add',
+ 'audio-mute',
+ 'audit',
+ 'bars',
+ 'block',
+ 'book',
+ 'bulb',
+ 'border',
+ 'number',
+ 'branches',
+ 'build',
+ 'calculator',
+ 'car',
+ 'carry-out',
+ 'ci',
+ 'clear',
+ 'cloud-download',
+ 'cloud-server',
+ 'cloud-sync',
+ 'cloud-upload',
+ 'cluster',
+ 'code',
+ 'coffee',
+ 'comment',
+ 'compress',
+ 'control',
+ 'copyright',
+ 'crown',
+ 'delete-column',
+ 'delete-row',
+ 'delivered-procedure',
+ 'deployment-unit',
+ 'desktop',
+ 'disconnect',
+ 'dollar',
+ 'euro',
+ 'expand',
+ 'export',
+ 'file-add',
+ 'file-done',
+ 'file-image',
+ 'file-pdf',
+ 'file-ppt',
+ 'file-text',
+ 'file-unknown',
+ 'file-word',
+ 'file-zip',
+ 'fork',
+ 'frown',
+ 'funnel-plot',
+ 'gateway',
+ 'gif',
+ 'gift',
+ 'global',
+ 'gold',
+ 'import',
+ 'laptop',
+ 'loading',
+ 'medicine-box',
+ 'meh',
+ 'menu',
+ 'paper-clip',
+ 'partition',
+ 'pay-circle',
+ 'printer',
+ 'pushpin',
+ 'qrcode',
+ 'reload',
+ 'rest',
+ 'robot',
+ 'rotate-left',
+ 'rotate-right',
+ 'safety-certificate',
+ 'save',
+ 'send',
+ 'shake',
+ 'share-alt',
+ 'shop',
+ 'shopping',
+ 'sound',
+ 'sync',
+ 'tag',
+ 'tags',
+ 'trademark',
+ 'trophy',
+ 'usb',
+ 'user-add',
+ 'user-delete',
+ 'user-switch',
+ 'video-camera',
+ 'wifi',
+ 'table',
+ 'apple',
+ 'dingding',
+ 'weibo',
+ 'wechat',
+ 'taobao',
+ 'qq',
+ 'alipay',
]
}
-export const queryTableSql = 'select TbName,Remark from (select TbName,Remark from sDataDictb where appkey= @appkey@ and Deleted=0 union select a.TbName,Remark from (select TbName,Remark from sDataDictb where appkey= \'\' and Deleted=0 ) a left join (select TbName from sDataDictb where appkey= @appkey@ and Deleted=0 ) b on a.TbName=b.TbName where b.TbName is null ) t'
+export const queryTableSql = 'select top 999999 TbName,Remark from (select TbName,Remark from sDataDictb where appkey= @appkey@ and Deleted=0 union select a.TbName,Remark from (select TbName,Remark from sDataDictb where appkey= \'\' and Deleted=0 ) a left join (select TbName from sDataDictb where appkey= @appkey@ and Deleted=0 ) b on a.TbName=b.TbName where b.TbName is null ) t order by TbName'
+
+export const queryPrintSql = `select ID,Images,PrintTempNO+PrintTempName as PN from sPrintTemplate
+ where appkey= @appkey@ and Deleted=0 and typechartwo='web_print'
+ union select ID,Images,a.PrintTempNO+PrintTempName as PN
+ from (select * from sPrintTemplate where appkey= '' and Deleted=0 and typechartwo='web_print') a
+ left join (select PrintTempNO from sPrintTemplate where appkey= @appkey@ and Deleted=0 ) b
+ on a.PrintTempNO=b.PrintTempNO
+ left join (select Srcid from sPrintTemplate_Log where appkey='' and apicode= @appkey@ and Deleted=0 ) c
+ on a.ID=c.Srcid where b.PrintTempNO is null and c.Srcid is null`
\ No newline at end of file
--
Gitblit v1.8.0